react-native-screens 4.25.0-beta.1 → 4.25.0-beta.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (96) hide show
  1. package/android/src/main/java/com/swmansion/rnscreens/gamma/stack/header/StackHeaderAppBarLayout.kt +6 -14
  2. package/android/src/main/java/com/swmansion/rnscreens/gamma/stack/header/StackHeaderAppBarLayoutBehavior.kt +29 -0
  3. package/android/src/main/java/com/swmansion/rnscreens/gamma/stack/header/StackHeaderCoordinator.kt +56 -0
  4. package/android/src/main/java/com/swmansion/rnscreens/gamma/stack/header/config/StackHeaderConfig.kt +11 -0
  5. package/android/src/main/java/com/swmansion/rnscreens/gamma/stack/header/config/StackHeaderConfigProviding.kt +5 -0
  6. package/android/src/main/java/com/swmansion/rnscreens/gamma/stack/header/config/StackHeaderConfigViewManager.kt +35 -0
  7. package/android/src/main/java/com/swmansion/rnscreens/gamma/stack/header/subview/StackHeaderSubview.kt +3 -7
  8. package/android/src/main/java/com/swmansion/rnscreens/gamma/tabs/container/TabsActionOrigin.kt +26 -0
  9. package/android/src/main/java/com/swmansion/rnscreens/gamma/tabs/container/TabsContainer.kt +227 -151
  10. package/android/src/main/java/com/swmansion/rnscreens/gamma/tabs/container/TabsNavigationState.kt +60 -0
  11. package/android/src/main/java/com/swmansion/rnscreens/gamma/tabs/container/{TabsContainerDelegate.kt → TabsNavigationStateObserver.kt} +19 -14
  12. package/android/src/main/java/com/swmansion/rnscreens/gamma/tabs/container/TabsNavigationStateObserverRegistry.kt +88 -0
  13. package/android/src/main/java/com/swmansion/rnscreens/gamma/tabs/host/TabsHost.kt +40 -24
  14. package/android/src/main/java/com/swmansion/rnscreens/gamma/tabs/host/TabsHostEventEmitter.kt +11 -9
  15. package/android/src/main/java/com/swmansion/rnscreens/gamma/tabs/host/TabsHostViewManager.kt +19 -7
  16. package/android/src/main/java/com/swmansion/rnscreens/gamma/tabs/host/event/TabsHostTabSelectedEvent.kt +4 -3
  17. package/android/src/main/java/com/swmansion/rnscreens/gamma/tabs/host/event/TabsHostTabSelectionPreventedEvent.kt +3 -3
  18. package/android/src/main/java/com/swmansion/rnscreens/gamma/tabs/host/event/TabsHostTabSelectionRejectedEvent.kt +11 -10
  19. package/ios/conversion/RNSConversions-Tabs.mm +19 -0
  20. package/ios/conversion/RNSConversions.h +3 -0
  21. package/ios/tabs/bottom-accessory/RNSTabsBottomAccessoryHelper.mm +34 -5
  22. package/ios/tabs/host/RNSTabBarController.h +152 -99
  23. package/ios/tabs/host/RNSTabBarController.mm +137 -113
  24. package/ios/tabs/host/RNSTabsHostComponentView.h +7 -8
  25. package/ios/tabs/host/RNSTabsHostComponentView.mm +37 -33
  26. package/ios/tabs/host/RNSTabsHostEventEmitter.h +4 -4
  27. package/ios/tabs/host/RNSTabsHostEventEmitter.mm +5 -3
  28. package/ios/tabs/host/RNSTabsNavigationState.h +142 -27
  29. package/ios/tabs/host/RNSTabsNavigationState.mm +35 -2
  30. package/ios/tabs/host/RNSTabsNavigationStateObserverRegistry.h +62 -0
  31. package/ios/tabs/host/RNSTabsNavigationStateObserverRegistry.mm +104 -0
  32. package/lib/commonjs/components/gamma/stack/header/StackHeaderConfig.android.js +46 -1
  33. package/lib/commonjs/components/gamma/stack/header/StackHeaderConfig.android.js.map +1 -1
  34. package/lib/commonjs/components/safe-area/SafeAreaView.web.js +2 -3
  35. package/lib/commonjs/components/safe-area/SafeAreaView.web.js.map +1 -1
  36. package/lib/commonjs/components/tabs/host/TabsHost.android.js +2 -2
  37. package/lib/commonjs/components/tabs/host/TabsHost.android.js.map +1 -1
  38. package/lib/commonjs/components/tabs/host/TabsHost.ios.js +2 -2
  39. package/lib/commonjs/components/tabs/host/TabsHost.ios.js.map +1 -1
  40. package/lib/commonjs/fabric/gamma/stack/StackHeaderConfigAndroidNativeComponent.js.map +1 -1
  41. package/lib/commonjs/flags.js +1 -0
  42. package/lib/commonjs/flags.js.map +1 -1
  43. package/lib/module/components/gamma/stack/header/StackHeaderConfig.android.js +46 -1
  44. package/lib/module/components/gamma/stack/header/StackHeaderConfig.android.js.map +1 -1
  45. package/lib/module/components/safe-area/SafeAreaView.web.js +1 -1
  46. package/lib/module/components/safe-area/SafeAreaView.web.js.map +1 -1
  47. package/lib/module/components/tabs/host/TabsHost.android.js +2 -2
  48. package/lib/module/components/tabs/host/TabsHost.android.js.map +1 -1
  49. package/lib/module/components/tabs/host/TabsHost.ios.js +2 -2
  50. package/lib/module/components/tabs/host/TabsHost.ios.js.map +1 -1
  51. package/lib/module/fabric/gamma/stack/StackHeaderConfigAndroidNativeComponent.js.map +1 -1
  52. package/lib/module/flags.js +1 -0
  53. package/lib/module/flags.js.map +1 -1
  54. package/lib/typescript/components/gamma/split/SplitHost.types.d.ts +1 -1
  55. package/lib/typescript/components/gamma/split/SplitHost.types.d.ts.map +1 -1
  56. package/lib/typescript/components/gamma/stack/header/StackHeaderConfig.android.d.ts.map +1 -1
  57. package/lib/typescript/components/gamma/stack/header/StackHeaderConfig.android.types.d.ts +183 -8
  58. package/lib/typescript/components/gamma/stack/header/StackHeaderConfig.android.types.d.ts.map +1 -1
  59. package/lib/typescript/components/gamma/stack/header/StackHeaderConfig.types.d.ts +37 -0
  60. package/lib/typescript/components/gamma/stack/header/StackHeaderConfig.types.d.ts.map +1 -1
  61. package/lib/typescript/components/gamma/stack/header/android/StackHeaderSubview.android.types.d.ts +1 -1
  62. package/lib/typescript/components/gamma/stack/header/android/StackHeaderSubview.android.types.d.ts.map +1 -1
  63. package/lib/typescript/components/gamma/stack/host/StackHost.types.d.ts +1 -1
  64. package/lib/typescript/components/gamma/stack/host/StackHost.types.d.ts.map +1 -1
  65. package/lib/typescript/components/safe-area/SafeAreaView.web.d.ts +1 -1
  66. package/lib/typescript/components/safe-area/SafeAreaView.web.d.ts.map +1 -1
  67. package/lib/typescript/components/tabs/host/TabsHost.types.d.ts +27 -17
  68. package/lib/typescript/components/tabs/host/TabsHost.types.d.ts.map +1 -1
  69. package/lib/typescript/components/tabs/index.d.ts +1 -1
  70. package/lib/typescript/components/tabs/index.d.ts.map +1 -1
  71. package/lib/typescript/fabric/gamma/stack/StackHeaderConfigAndroidNativeComponent.d.ts +5 -0
  72. package/lib/typescript/fabric/gamma/stack/StackHeaderConfigAndroidNativeComponent.d.ts.map +1 -1
  73. package/lib/typescript/fabric/tabs/TabsHostAndroidNativeComponent.d.ts +4 -4
  74. package/lib/typescript/fabric/tabs/TabsHostAndroidNativeComponent.d.ts.map +1 -1
  75. package/lib/typescript/fabric/tabs/TabsHostIOSNativeComponent.d.ts +4 -4
  76. package/lib/typescript/fabric/tabs/TabsHostIOSNativeComponent.d.ts.map +1 -1
  77. package/lib/typescript/flags.d.ts +1 -0
  78. package/lib/typescript/flags.d.ts.map +1 -1
  79. package/package.json +1 -1
  80. package/src/components/gamma/split/SplitHost.types.ts +1 -1
  81. package/src/components/gamma/stack/header/StackHeaderConfig.android.tsx +72 -2
  82. package/src/components/gamma/stack/header/StackHeaderConfig.android.types.ts +183 -8
  83. package/src/components/gamma/stack/header/StackHeaderConfig.types.ts +37 -0
  84. package/src/components/gamma/stack/header/android/StackHeaderSubview.android.types.ts +1 -1
  85. package/src/components/gamma/stack/host/StackHost.types.ts +1 -1
  86. package/src/components/safe-area/SafeAreaView.web.tsx +1 -1
  87. package/src/components/tabs/host/TabsHost.android.tsx +2 -2
  88. package/src/components/tabs/host/TabsHost.ios.tsx +2 -2
  89. package/src/components/tabs/host/TabsHost.types.ts +27 -17
  90. package/src/components/tabs/index.ts +1 -1
  91. package/src/fabric/gamma/stack/StackHeaderConfigAndroidNativeComponent.ts +6 -0
  92. package/src/fabric/tabs/TabsHostAndroidNativeComponent.ts +4 -4
  93. package/src/fabric/tabs/TabsHostIOSNativeComponent.ts +4 -4
  94. package/src/flags.ts +1 -0
  95. package/android/src/main/java/com/swmansion/rnscreens/gamma/tabs/container/TabsContainerOps.kt +0 -7
  96. package/android/src/main/java/com/swmansion/rnscreens/gamma/tabs/container/TabsNavState.kt +0 -43
@@ -14,26 +14,6 @@ NS_ASSUME_NONNULL_BEGIN
14
14
  @class RNSTabsHostComponentView;
15
15
  @class RNSTabBarController;
16
16
 
17
- @protocol RNSTabBarControllerDelegate <NSObject>
18
-
19
- - (void)tabBarController:(nonnull RNSTabBarController *)tabBarController
20
- didUpdateStateTo:(nonnull RNSTabsNavigationState *)navState
21
- withContext:(nonnull RNSTabsNavigationStateUpdateContext *)context;
22
-
23
- - (void)tabBarController:(nonnull RNSTabBarController *)tabBarController
24
- rejectedStateUpdateTo:(nonnull RNSTabsNavigationState *)rejectedNavState
25
- currentState:(nonnull RNSTabsNavigationState *)currentNavState
26
- withReason:(RNSTabsNavigationStateRejectionReason)reasonCode;
27
-
28
- - (void)tabBarController:(nonnull RNSTabBarController *)tabBarController
29
- preventedSelectionOf:(nonnull NSString *)screenKey
30
- currentState:(nonnull RNSTabsNavigationState *)currentNavState;
31
-
32
- - (void)tabBarController:(nonnull RNSTabBarController *)tabBarController
33
- didSelectMoreTabWithCurrentState:(nonnull RNSTabsNavigationState *)currentNavState;
34
-
35
- @end
36
-
37
17
  @protocol RNSReactTransactionObserving
38
18
 
39
19
  - (void)reactMountingTransactionWillMount;
@@ -43,21 +23,87 @@ NS_ASSUME_NONNULL_BEGIN
43
23
  @end
44
24
 
45
25
  /**
46
- * This controller is responsible for tab management & all other responsibilities coming from the fact of inheritance
47
- * from `UITabBarController`. It is limited only to the child view controllers of type `RNSTabsScreenViewController`,
48
- * however.
26
+ * UITabBarController subclass that backs `<TabsHost>` on iOS.
27
+ *
28
+ * This controller is responsible for tab management & all other responsibilities coming from the
29
+ * fact of inheritance from `UITabBarController`. It is limited only to the child view controllers
30
+ * of type `RNSTabsScreenViewController`, however.
49
31
  *
50
32
  * Updates made by this controller are synchronized by `RNSReactTransactionObserving` protocol,
51
- * i.e. if you made changes through one of signals method, unless you flush them immediately (not needed atm), they will
52
- * be executed only after react finishes the transaction (from within transaction execution block).
33
+ * i.e. if you made changes through one of signals method, unless you flush them immediately, they
34
+ * will be executed only after react finishes the transaction (from within transaction execution
35
+ * block).
36
+ *
37
+ * # Public API
38
+ *
39
+ * Methods and properties under `#pragma mark - Public API` below are the only contract
40
+ * third-party native consumers should rely on:
41
+ * - read the current navigation state via `navigationState`,
42
+ * - request a tab change via `submitSelectionOfTabsScreenWithKey:` (transition is recorded with
43
+ * `RNSTabsActionOriginProgrammaticNative`),
44
+ * - apply pending updates via `flushPendingUpdates`,
45
+ * - observe results via `addNavigationStateObserver:` / `removeNavigationStateObserver:`
46
+ * (see `RNSTabsNavigationStateObserver` in `RNSTabsNavigationState.h`).
47
+ *
48
+ * # Internal API
49
+ *
50
+ * Members under `#pragma mark - Internal API` are host-only (`RNSTabsHostComponentView`)
51
+ * implementation detail and may change without notice. Do not call from third-party code.
53
52
  */
54
- @interface RNSTabBarController : UITabBarController <
55
- RNSReactTransactionObserving
53
+ @interface RNSTabBarController : UITabBarController <RNSReactTransactionObserving
56
54
  #if !TARGET_OS_TV
57
- ,
58
- RNSOrientationProviding
55
+ ,
56
+ RNSOrientationProviding
59
57
  #endif // !TARGET_OS_TV
60
- >
58
+ >
59
+
60
+ #pragma mark - Public API
61
+
62
+ /**
63
+ * Represents current navigation state.
64
+ *
65
+ * After each model update, the container (controller) updates the navigation state. The
66
+ * `provenance` part is incremented monotonically with each state update.
67
+ *
68
+ * The controller manages this state. It MUST NOT be overwritten by any external actor.
69
+ */
70
+ @property (nonatomic, readonly, strong, nullable) RNSTabsNavigationState *navigationState;
71
+
72
+ /**
73
+ * Request a tab change. The transition is recorded with `RNSTabsActionOriginProgrammaticNative`,
74
+ * and is built against the current `navigationState.provenance` so it is never treated as stale.
75
+ *
76
+ * The update is applied on the next `RNSReactTransactionObserving` callback, or call
77
+ * `flushPendingUpdates` to apply it immediately. If you want to execute multiple updates in
78
+ * sequence you must flush the container after each one separately.
79
+ */
80
+ - (void)submitSelectionOfTabsScreenWithKey:(nonnull NSString *)screenKey;
81
+
82
+ /**
83
+ * Apply any pending invalidations and state updates in a single coordinated pass.
84
+ * No-op when nothing is dirty.
85
+ */
86
+ - (void)flushPendingUpdates;
87
+
88
+ /**
89
+ * Register an observer for navigation state events on this container.
90
+ * Observers are held strongly; call `removeNavigationStateObserver:` before observer
91
+ * dealloc, or rely on the host calling `tearDown` on container teardown.
92
+ *
93
+ * Returns NO if the observer is already registered or if called from within an
94
+ * observer callback (modifications during emission are rejected).
95
+ */
96
+ - (BOOL)addNavigationStateObserver:(id<RNSTabsNavigationStateObserver>)observer;
97
+
98
+ /**
99
+ * Unregister a previously registered observer.
100
+ *
101
+ * Returns NO if the observer was not registered or if called from within an
102
+ * observer callback (modifications during emission are rejected).
103
+ */
104
+ - (BOOL)removeNavigationStateObserver:(id<RNSTabsNavigationStateObserver>)observer;
105
+
106
+ #pragma mark - Internal API (host-only; subject to change without notice)
61
107
 
62
108
  - (instancetype)initWithTabsHostComponentView:(nullable RNSTabsHostComponentView *)tabsHostComponentView;
63
109
 
@@ -70,52 +116,75 @@ NS_ASSUME_NONNULL_BEGIN
70
116
  @property (nonatomic, readonly, nullable) RNSTabsHostComponentView *tabsHostComponentView;
71
117
 
72
118
  /**
73
- * Tab bar appearance coordinator. If you need to update tab bar appearance avoid using this one directly. Send the
74
- * controller a signal, invalidate the tab bar appearance & either wait for the update flush or flush it manually.
119
+ * Tab bar appearance coordinator. If you need to update tab bar appearance avoid using this one
120
+ * directly. Send the controller a signal, invalidate the tab bar appearance & either wait for the
121
+ * update flush or flush it manually.
75
122
  */
76
123
  @property (nonatomic, readonly, strong, nonnull) RNSTabBarAppearanceCoordinator *tabBarAppearanceCoordinator;
77
124
 
78
125
  /**
79
- * Represents current navigation state.
126
+ * If true, the controller will reject any navigation state updates if the provenance of the
127
+ * update is stale.
80
128
  *
81
- * After each model update, the container (controller) updates the navigation state. The `provenance` part is
82
- * incremented monotonically with each state update.
129
+ * A navigation state update is considered stale if its provenance is older than the provenance
130
+ * of the currently active navigation state.
83
131
  *
84
- * The controller manages this state. It MUST NOT be overwritten by any external actor.
132
+ * This can happen, e.g. when an update from JS is dispatched, but before it reaches the native
133
+ * side, another update happens on UI thread, e.g. user selects another tab. For such situations,
134
+ * where to-be-applied navigation state update had been dispatched w/o full context of actual
135
+ * navigation state you can toggle this prop.
136
+ *
137
+ * If an update is rejected due to being stale, the controller will notify its observers.
85
138
  */
86
- @property (nonatomic, readonly, strong, nullable) RNSTabsNavigationState *navigationState;
139
+ @property (nonatomic, readwrite) BOOL rejectStaleNavigationStateUpdates;
87
140
 
88
141
  /**
142
+ * Tell the controller that react provided tabs have changed (count / instances) & the child
143
+ * view controllers need to be updated.
89
144
  *
90
- * If true, the controller will reject any navigation state updates
91
- * if the provenance of the update is stale.
145
+ * This also automatically raises `needsUpdateOfChildViewControllers` flag, no need to call it
146
+ * manually.
147
+ */
148
+ - (void)childViewControllersHaveChangedTo:(nonnull NSArray<RNSTabsScreenViewController *> *)childViewControllers;
149
+
150
+ /**
151
+ * Request navigation state update from the controller to the given one.
92
152
  *
93
- * A navigation state update is considered stale if its provenance is older
94
- * than the provenance of the currently active navigation state.
153
+ * Pass nil to clear any queued update.
95
154
  *
96
- * This can happen, e.g. when an update from JS is dispatched, but before it reaches the native
97
- * side, another update happens on UI thread, e.g. user selects another tab. For such
98
- * situations, where to-be-applied navigation state update had been dispatched w/o
99
- * full context of actual navigation state you can toggle this prop.
155
+ * The update is applied on the next `RNSReactTransactionObserving` callback, or call
156
+ * `flushPendingUpdates` to apply it immediately. If you want to execute multiple updates in
157
+ * sequence you must flush the container after each one separately.
100
158
  *
101
- * If an update is rejected due to being stale, the controller will notify its delegate.
159
+ * Host-only: third-party native consumers should use `submitSelectionOfTabsScreenWithKey:` instead, which
160
+ * forces `RNSTabsActionOriginProgrammaticNative`. This method allows the host to dispatch any
161
+ * origin (e.g. `RNSTabsActionOriginProgrammaticJs` for JS-driven `navStateRequest` updates).
102
162
  */
103
- @property (nonatomic, readwrite) BOOL rejectStaleNavigationStateUpdates;
163
+ - (void)setPendingNavigationStateUpdate:(nullable RNSTabsNavigationStateUpdateRequest *)stateUpdate;
164
+
165
+ /**
166
+ * Idempotent teardown. Releases observer references and any retained host references.
167
+ * Called by the host on view lifecycle end.
168
+ */
169
+ - (void)tearDown;
170
+
171
+ #pragma mark Individual flush methods (internal)
104
172
 
105
173
  /**
106
174
  * Update tab controller state with previously provided children.
107
175
  *
108
- * This method does nothing if the children have not been changed / update has not been requested before.
109
- * The requested update is performed immediately. If you do not need this, consider just raising an appropriate
110
- * invalidation signal & let the controller decide when to flush the updates.
176
+ * This method does nothing if the children have not been changed / update has not been requested
177
+ * before. The requested update is performed immediately. If you do not need this, consider just
178
+ * raising an appropriate invalidation signal & let the controller decide when to flush the
179
+ * updates.
111
180
  */
112
181
  - (void)updateChildViewControllersIfNeeded;
113
182
 
114
183
  /**
115
184
  * Force update of the tab controller state with previously provided children.
116
185
  *
117
- * The requested update is performed immediately. If you do not need this, consider just raising an appropriate
118
- * invalidation signal & let the controller decide when to flush the updates.
186
+ * The requested update is performed immediately. If you do not need this, consider just raising
187
+ * an appropriate invalidation signal & let the controller decide when to flush the updates.
119
188
  */
120
189
  - (void)updateReactChildrenControllers;
121
190
 
@@ -123,8 +192,9 @@ NS_ASSUME_NONNULL_BEGIN
123
192
  * If any state update operation is pending - perform it.
124
193
  *
125
194
  * This method does nothing if the update has not been previously requested.
126
- * If needed, the requested update is performed immediately. If you do not need this, consider just raising an
127
- * appropriate invalidation signal & let the controller decide when to flush the updates.
195
+ * If needed, the requested update is performed immediately. If you do not need this, consider
196
+ * just raising an appropriate invalidation signal & let the controller decide when to flush the
197
+ * updates.
128
198
  */
129
199
  - (void)updateSelectedViewControllerIfNeeded;
130
200
 
@@ -133,8 +203,8 @@ NS_ASSUME_NONNULL_BEGIN
133
203
  *
134
204
  * To request update use `setPendingNavigationStateUpdate`.
135
205
  *
136
- * The requested update is performed immediately. If you do not need this, consider just raising an appropriate
137
- * invalidation signal & let the controller decide when to flush the updates.
206
+ * The requested update is performed immediately. If you do not need this, consider just raising
207
+ * an appropriate invalidation signal & let the controller decide when to flush the updates.
138
208
  */
139
209
  - (void)updateSelectedViewController;
140
210
 
@@ -142,16 +212,17 @@ NS_ASSUME_NONNULL_BEGIN
142
212
  * Updates the tab bar appearance basing on configuration sources (host view, tab screens).
143
213
  *
144
214
  * This method does nothing if the update has not been previously requested.
145
- * If needed, the requested update is performed immediately. If you do not need this, consider just raising an
146
- * appropriate invalidation signal & let the controller decide when to flush the updates.
215
+ * If needed, the requested update is performed immediately. If you do not need this, consider
216
+ * just raising an appropriate invalidation signal & let the controller decide when to flush the
217
+ * updates.
147
218
  */
148
219
  - (void)updateTabBarAppearanceIfNeeded;
149
220
 
150
221
  /**
151
222
  * Updates the tab bar appearance basing on configuration sources (host view, tab screens).
152
223
  *
153
- * The requested update is performed immediately. If you do not need this, consider just raising an appropriate
154
- * invalidation signal & let the controller decide when to flush the updates.
224
+ * The requested update is performed immediately. If you do not need this, consider just raising
225
+ * an appropriate invalidation signal & let the controller decide when to flush the updates.
155
226
  */
156
227
  - (void)updateTabBarAppearance;
157
228
 
@@ -159,16 +230,17 @@ NS_ASSUME_NONNULL_BEGIN
159
230
  * Updates the interface orientation based on selected tab screen and its children.
160
231
  *
161
232
  * This method does nothing if the update has not been previously requested.
162
- * If needed, the requested update is performed immediately. If you do not need this, consider just raising an
163
- * appropriate invalidation signal & let the controller decide when to flush the updates.
233
+ * If needed, the requested update is performed immediately. If you do not need this, consider
234
+ * just raising an appropriate invalidation signal & let the controller decide when to flush the
235
+ * updates.
164
236
  */
165
237
  - (void)updateOrientationIfNeeded;
166
238
 
167
239
  /**
168
240
  * Updates the interface orientation based on selected tab screen and its children.
169
241
  *
170
- * The requested update is performed immediately. If you do not need this, consider just raising an appropriate
171
- * invalidation signal & let the controller decide when to flush the updates.
242
+ * The requested update is performed immediately. If you do not need this, consider just raising
243
+ * an appropriate invalidation signal & let the controller decide when to flush the updates.
172
244
  */
173
245
  - (void)updateOrientation;
174
246
 
@@ -176,8 +248,9 @@ NS_ASSUME_NONNULL_BEGIN
176
248
  * Updates the layout direction based on property on host view.
177
249
  *
178
250
  * This method does nothing if the update has not been previously requested.
179
- * If needed, the requested update is performed immediately. If you do not need this, consider just raising an
180
- * appropriate invalidation signal & let the controller decide when to flush the updates.
251
+ * If needed, the requested update is performed immediately. If you do not need this, consider
252
+ * just raising an appropriate invalidation signal & let the controller decide when to flush the
253
+ * updates.
181
254
  *
182
255
  * This method is necessary only on iOS versions prior to 17.
183
256
  * On iOS 17+, use `traitOverrides.layoutDirection` on the controller directly.
@@ -187,8 +260,8 @@ NS_ASSUME_NONNULL_BEGIN
187
260
  /**
188
261
  * Updates the layout direction based on property on host view.
189
262
  *
190
- * The requested update is performed immediately. If you do not need this, consider just raising an appropriate
191
- * invalidation signal & let the controller decide when to flush the updates.
263
+ * The requested update is performed immediately. If you do not need this, consider just raising
264
+ * an appropriate invalidation signal & let the controller decide when to flush the updates.
192
265
  *
193
266
  * This method is necessary only on iOS versions prior to 17.
194
267
  * On iOS 17+, use `traitOverrides.layoutDirection` on the controller directly.
@@ -196,53 +269,33 @@ NS_ASSUME_NONNULL_BEGIN
196
269
  * This method can only be called when `parentViewController` is not nil.
197
270
  */
198
271
  - (void)updateLayoutDirectionBelowIOS17;
199
- @end
200
-
201
- #pragma mark - Signals
202
272
 
203
- /**
204
- * This extension defines various invalidation signals that you can send to the controller, to notify it that it needs
205
- * to take some action.
206
- */
207
- @interface RNSTabBarController ()
208
-
209
- /**
210
- * Tell the controller that react provided tabs have changed (count / instances) & the child view controllers need to be
211
- * updated.
212
- *
213
- * This also automatically raises `needsReactChildrenUpdate` flag, no need to call it manually.
214
- */
215
- - (void)childViewControllersHaveChangedTo:(nonnull NSArray<RNSTabsScreenViewController *> *)childViewControllers;
216
-
217
- /**
218
- * Request navigation state update from the controller to the given one.
219
- *
220
- * If you want to execute multiple updates in sequence you must flush the container after each one separately.
221
- */
222
- - (void)setPendingNavigationStateUpdate:(nullable RNSTabsNavigationState *)navState;
273
+ #pragma mark Individual invalidation flags (internal)
223
274
 
224
275
  /**
225
- * Tell the controller that react provided tabs have changed (count / instances) & the child view controllers need to be
226
- * updated.
276
+ * Tell the controller that react provided tabs have changed (count / instances) & the child
277
+ * view controllers need to be updated.
227
278
  *
228
- * Do not raise this signal only when you want to modify selected view controller. Use `setPendingNavigationStateUpdate`
229
- * instead.
279
+ * Do not raise this signal only when you want to modify selected view controller. Use
280
+ * `setPendingNavigationStateUpdate` instead.
230
281
  */
231
282
  @property (nonatomic, readwrite) bool needsUpdateOfChildViewControllers;
232
283
 
233
284
  /**
234
- * Tell the controller that some configuration regarding the tab bar apperance has changed & the appearance requires
235
- * update.
285
+ * Tell the controller that some configuration regarding the tab bar apperance has changed & the
286
+ * appearance requires update.
236
287
  */
237
288
  @property (nonatomic, readwrite) bool needsUpdateOfTabBarAppearance;
238
289
 
239
290
  /**
240
- * Tell the controller that some configuration regarding interface orientation has changed & it requires update.
291
+ * Tell the controller that some configuration regarding interface orientation has changed & it
292
+ * requires update.
241
293
  */
242
294
  @property (nonatomic, readwrite) bool needsOrientationUpdate;
243
295
 
244
296
  /**
245
- * Tell the controller that some configuration regarding layout direction has changed & it requires update.
297
+ * Tell the controller that some configuration regarding layout direction has changed & it
298
+ * requires update.
246
299
  *
247
300
  * This flag is necessary only on iOS versions prior to 17.
248
301
  * On iOS 17+, use `traitOverrides.layoutDirection` on the controller directly.