|
@@ -0,0 +1,188 @@
|
|
1
|
+# Navigation
|
|
2
|
+
|
|
3
|
+## Properties
|
|
4
|
+
|
|
5
|
+- Element (any)
|
|
6
|
+
|
|
7
|
+## Methods
|
|
8
|
+
|
|
9
|
+### `registerComponent(componentName: string, getComponentClassFunc: ComponentProvider): void`
|
|
10
|
+
|
|
11
|
+[source](/lib/src//Navigation.ts#52)
|
|
12
|
+
|
|
13
|
+Every navigation component in your app must be registered with a unique name.
|
|
14
|
+The component itself is a traditional React component extending React.Component.
|
|
15
|
+
|
|
16
|
+#### Arguments
|
|
17
|
+- componentName (string)
|
|
18
|
+- getComponentClassFunc (ComponentProvider)
|
|
19
|
+
|
|
20
|
+#### Returns
|
|
21
|
+- (void)
|
|
22
|
+
|
|
23
|
+### `setRoot(layout: any): Promise<any>`
|
|
24
|
+
|
|
25
|
+[source](/lib/src//Navigation.ts#59)
|
|
26
|
+
|
|
27
|
+Reset the app to a new layout
|
|
28
|
+
|
|
29
|
+#### Arguments
|
|
30
|
+- layout (any)
|
|
31
|
+
|
|
32
|
+#### Returns
|
|
33
|
+- (Promise<any>)
|
|
34
|
+
|
|
35
|
+### `setDefaultOptions(options: any): void`
|
|
36
|
+
|
|
37
|
+[source](/lib/src//Navigation.ts#66)
|
|
38
|
+
|
|
39
|
+Set default options to all screens. Useful for declaring a consistent style across the app.
|
|
40
|
+
|
|
41
|
+#### Arguments
|
|
42
|
+- options (any)
|
|
43
|
+
|
|
44
|
+#### Returns
|
|
45
|
+- (void)
|
|
46
|
+
|
|
47
|
+### `mergeOptions(componentId: string, options: any): void`
|
|
48
|
+
|
|
49
|
+[source](/lib/src//Navigation.ts#73)
|
|
50
|
+
|
|
51
|
+Change a component's navigation options
|
|
52
|
+
|
|
53
|
+#### Arguments
|
|
54
|
+- componentId (string)
|
|
55
|
+- options (any)
|
|
56
|
+
|
|
57
|
+#### Returns
|
|
58
|
+- (void)
|
|
59
|
+
|
|
60
|
+### `showModal(layout: any): Promise<any>`
|
|
61
|
+
|
|
62
|
+[source](/lib/src//Navigation.ts#80)
|
|
63
|
+
|
|
64
|
+Show a screen as a modal.
|
|
65
|
+
|
|
66
|
+#### Arguments
|
|
67
|
+- layout (any)
|
|
68
|
+
|
|
69
|
+#### Returns
|
|
70
|
+- (Promise<any>)
|
|
71
|
+
|
|
72
|
+### `dismissModal(componentId: string): Promise<any>`
|
|
73
|
+
|
|
74
|
+[source](/lib/src//Navigation.ts#87)
|
|
75
|
+
|
|
76
|
+Dismiss a modal by componentId. The dismissed modal can be anywhere in the stack.
|
|
77
|
+
|
|
78
|
+#### Arguments
|
|
79
|
+- componentId (string)
|
|
80
|
+
|
|
81
|
+#### Returns
|
|
82
|
+- (Promise<any>)
|
|
83
|
+
|
|
84
|
+### `dismissAllModals(): Promise<any>`
|
|
85
|
+
|
|
86
|
+[source](/lib/src//Navigation.ts#94)
|
|
87
|
+
|
|
88
|
+Dismiss all Modals
|
|
89
|
+
|
|
90
|
+#### Returns
|
|
91
|
+- (Promise<any>)
|
|
92
|
+
|
|
93
|
+### `push(componentId: string, layout: any): Promise<any>`
|
|
94
|
+
|
|
95
|
+[source](/lib/src//Navigation.ts#101)
|
|
96
|
+
|
|
97
|
+Push a new layout into this screen's navigation stack.
|
|
98
|
+
|
|
99
|
+#### Arguments
|
|
100
|
+- componentId (string)
|
|
101
|
+- layout (any)
|
|
102
|
+
|
|
103
|
+#### Returns
|
|
104
|
+- (Promise<any>)
|
|
105
|
+
|
|
106
|
+### `pop(componentId: string, params: any): Promise<any>`
|
|
107
|
+
|
|
108
|
+[source](/lib/src//Navigation.ts#108)
|
|
109
|
+
|
|
110
|
+Pop a component from the stack, regardless of it's position.
|
|
111
|
+
|
|
112
|
+#### Arguments
|
|
113
|
+- componentId (string)
|
|
114
|
+- params (any)
|
|
115
|
+
|
|
116
|
+#### Returns
|
|
117
|
+- (Promise<any>)
|
|
118
|
+
|
|
119
|
+### `popTo(componentId: string): Promise<any>`
|
|
120
|
+
|
|
121
|
+[source](/lib/src//Navigation.ts#115)
|
|
122
|
+
|
|
123
|
+Pop the stack to a given component
|
|
124
|
+
|
|
125
|
+#### Arguments
|
|
126
|
+- componentId (string)
|
|
127
|
+
|
|
128
|
+#### Returns
|
|
129
|
+- (Promise<any>)
|
|
130
|
+
|
|
131
|
+### `popToRoot(componentId: string): Promise<any>`
|
|
132
|
+
|
|
133
|
+[source](/lib/src//Navigation.ts#122)
|
|
134
|
+
|
|
135
|
+Pop the component's stack to root.
|
|
136
|
+
|
|
137
|
+#### Arguments
|
|
138
|
+- componentId (string)
|
|
139
|
+
|
|
140
|
+#### Returns
|
|
141
|
+- (Promise<any>)
|
|
142
|
+
|
|
143
|
+### `setStackRoot(componentId: string, layout: any): Promise<any>`
|
|
144
|
+
|
|
145
|
+[source](/lib/src//Navigation.ts#129)
|
|
146
|
+
|
|
147
|
+Sets new root component to stack.
|
|
148
|
+
|
|
149
|
+#### Arguments
|
|
150
|
+- componentId (string)
|
|
151
|
+- layout (any)
|
|
152
|
+
|
|
153
|
+#### Returns
|
|
154
|
+- (Promise<any>)
|
|
155
|
+
|
|
156
|
+### `showOverlay(layout: any): Promise<any>`
|
|
157
|
+
|
|
158
|
+[source](/lib/src//Navigation.ts#136)
|
|
159
|
+
|
|
160
|
+Show overlay on top of the entire app
|
|
161
|
+
|
|
162
|
+#### Arguments
|
|
163
|
+- layout (any)
|
|
164
|
+
|
|
165
|
+#### Returns
|
|
166
|
+- (Promise<any>)
|
|
167
|
+
|
|
168
|
+### `dismissOverlay(componentId: string): Promise<any>`
|
|
169
|
+
|
|
170
|
+[source](/lib/src//Navigation.ts#143)
|
|
171
|
+
|
|
172
|
+dismiss overlay by componentId
|
|
173
|
+
|
|
174
|
+#### Arguments
|
|
175
|
+- componentId (string)
|
|
176
|
+
|
|
177
|
+#### Returns
|
|
178
|
+- (Promise<any>)
|
|
179
|
+
|
|
180
|
+### `events(): EventsRegistry`
|
|
181
|
+
|
|
182
|
+[source](/lib/src//Navigation.ts#150)
|
|
183
|
+
|
|
184
|
+Obtain the events registry instance
|
|
185
|
+
|
|
186
|
+#### Returns
|
|
187
|
+- (EventsRegistry)
|
|
188
|
+
|