Skip to content

Commit e4754fa

Browse files
committed
1.6.9
1 parent f5ba45c commit e4754fa

File tree

4 files changed

+1010
-832
lines changed

4 files changed

+1010
-832
lines changed

README.md

Lines changed: 59 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -1,56 +1,67 @@
11
# react.cordova-navigation_controller
22

33
## Plugin for react
4+
45
It's manager for your pages like mobile app.<br>
56

6-
#### `import Navigator from './mobile-navigation-controller';`
7+
#### `import Navigator from 'react.cordova-navigation_controller';`
78

89
<br>
910
For example:
1011
In the render function return
1112

12-
```
13-
<Navigator onRef={ref => (this.navigatorRef = ref)} >
14-
15-
16-
<MyHomePage key="home" levelPage={0} />
17-
18-
<AboutPage key="about"
19-
levelPage={1}
20-
/>
21-
22-
23-
</Navigator>
2413
```
25-
**Note: prop `levelPage` important to manage the returs (from back button) in the structure of a tree**<br><br>
14+
<Navigator onRef={ref => (this.navigatorRef = ref)} >
15+
2616
17+
<MyHomePage key="home" levelPage={0} />
2718
19+
<AboutPage key="about"
20+
levelPage={1}
21+
transitionIn={
22+
animatioPageIn:"fadeIn"
23+
,animatioPageOut:"fadeOut"
24+
}
25+
transitionOut={{
26+
animatioPageOut: "fadeOut"
27+
}}
28+
/>
2829
2930
31+
</Navigator>
32+
```
33+
34+
**Note: prop `levelPage` important to manage the returs (from back button) in the structure of a tree**<br><br>
35+
3036
To change page you get the ref and do:
31-
#### `this.navigatorRef.changePage("about");`
37+
38+
#### `this.navigatorRef.changePage("about");`
39+
3240
the option to changePage it's:
41+
3342
```
3443
this.navigatorRef.changePage(
3544
goToPage //Required
3645
,{options}// Not requred
3746
);
3847
```
39-
options => { animationIn:integer // have defult
40-
, animationOut:string // have defult
48+
49+
```
50+
options = { animatioPageIn:"fadeInLeft" // have defult
51+
, animationPageOut:"fadeOutLeft" // have defult
4152
, timeAnimationInMS:integer // defult=250(ms)
4253
, callbackFun:function
43-
, props:{...}
54+
, props:{}
4455
}
56+
```
4557

46-
*`animationIn` and `animationOut` need name animate from [here](https://daneden.github.io/animate.css/) <br>
58+
*`animationIn` and `animationOut` need name animate from [here](https://daneden.github.io/animate.css/) <br>
4759
*the animate.css includ in this package
4860

4961
## Options:
5062

5163
### Navigator props
5264

53-
5465
<table>
5566
<thead>
5667
<tr>
@@ -115,11 +126,8 @@ options => { animationIn:integer // have defult
115126
</table>
116127
*levelAction return "Out" or "In" or "SameLevel"
117128

118-
119-
120129
### Child props
121130

122-
123131
<table>
124132
<thead>
125133
<tr>
@@ -158,6 +166,20 @@ options => { animationIn:integer // have defult
158166
<td>optional</td>
159167
<td>false</td>
160168
<td>May be problematic with css "padding-left" </td>
169+
</tr>
170+
<tr>
171+
<td>transitionIn</td>
172+
<td>json</td>
173+
<td>optional</td>
174+
<td>-</td>
175+
<td></td>
176+
</tr>
177+
<tr>
178+
<td>kill</td>
179+
<td>boolean</td>
180+
<td>optional</td>
181+
<td>-</td>
182+
<td></td>
161183
</tr>
162184
<tr>
163185
<td>alwaysLive</td>
@@ -170,48 +192,53 @@ options => { animationIn:integer // have defult
170192
</tbody>
171193
</table>
172194

173-
174195
#### Check what is page now
196+
175197
```
176198
const nowPage= this.navigatorRef.nowPage;
177199
```
200+
178201
#### Get the historyPages list
202+
179203
```
180204
const historyPages= this.navigatorRef.historyPages();
181205
```
182206

183207
#### Get the listLevelPages list
208+
184209
```
185210
const listLevelPages= this.navigatorRef.listLevelPages();
186211
```
212+
187213
#### Back 1 page history
214+
188215
```
189216
this.navigatorRef.back();
190217
```
218+
191219
or
220+
192221
```
193222
this.navigatorRef.back({options...});
194223
```
224+
195225
options => { animationIn:integer // have defult , animationOut:string // have defult , timeAnimationInMS:integer // defult=250(ms) , callbackFun:function , props:{...} }
196226

227+
#### Check if the mangerPages is busy
197228

198-
#### Check if the mangerPages is busy
199229
```
200230
const navigator_busy= this.navigatorRef.busy;
201231
```
202-
*busy return boolean
203-
<br><br><br>
204-
205232

233+
\*busy return boolean
234+
<br><br><br>
206235

207236
## If you have any problem, please let us know [here](https://github.com/orchoban/react.cordova-navigation_controller/issues), and we will make an effort to resolve it soon
208-
## Feel free to editing the code yourself: go to [src/index.js](https://github.com/orchoban/react.cordova-navigation_controller/blob/master/src/index.js)
209-
210-
211237

238+
## Feel free to editing the code yourself: go to [src/index.js](https://github.com/orchoban/react.cordova-navigation_controller/blob/master/src/index.js)
212239

213240
Credit:
214241
Arik Wald
215242
<br><br>
216243
Credit animated:
217-
***animate.css -https://daneden.github.io/animate.css/***
244+
**_animate.css -https://daneden.github.io/animate.css/_**

0 commit comments

Comments
 (0)