@office-iss/react-native-win32 0.79.0-preview.2 → 0.80.0-preview.1

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 (294) hide show
  1. package/.flowconfig +10 -3
  2. package/CHANGELOG.json +120 -12
  3. package/CHANGELOG.md +50 -7
  4. package/IntegrationTests/ImageCachePolicyTest.js +1 -1
  5. package/IntegrationTests/LayoutEventsTest.js +1 -4
  6. package/Libraries/Alert/Alert.d.ts +4 -1
  7. package/Libraries/Alert/Alert.js +3 -0
  8. package/Libraries/Alert/RCTAlertManager.js +17 -0
  9. package/Libraries/Animated/Animated.js.flow +1 -3
  10. package/Libraries/Animated/AnimatedEvent.js +4 -3
  11. package/Libraries/Animated/AnimatedExports.js +2 -2
  12. package/Libraries/Animated/AnimatedExports.js.flow +140 -0
  13. package/Libraries/Animated/AnimatedImplementation.js +2 -123
  14. package/Libraries/Animated/Easing.js +13 -15
  15. package/Libraries/Animated/animations/Animation.js +8 -4
  16. package/Libraries/Animated/components/AnimatedFlatList.js +7 -6
  17. package/Libraries/Animated/components/AnimatedScrollView.js +48 -42
  18. package/Libraries/Animated/components/AnimatedSectionList.js +11 -7
  19. package/Libraries/Animated/createAnimatedComponent.js +105 -57
  20. package/Libraries/Animated/nodes/AnimatedNode.js +4 -3
  21. package/Libraries/Animated/nodes/AnimatedProps.js +46 -26
  22. package/Libraries/Animated/nodes/AnimatedValue.js +16 -7
  23. package/Libraries/Animated/nodes/AnimatedValueXY.js +3 -1
  24. package/Libraries/AppState/AppState.js +7 -2
  25. package/Libraries/BatchedBridge/MessageQueue.js +2 -2
  26. package/Libraries/BatchedBridge/NativeModules.js +2 -0
  27. package/Libraries/Blob/BlobManager.js +1 -0
  28. package/Libraries/Blob/FileReader.js +219 -8
  29. package/Libraries/Blob/URL.js +37 -12
  30. package/Libraries/Blob/URLSearchParams.js +106 -31
  31. package/Libraries/Blob/URLSearchParams.js.flow +12 -7
  32. package/Libraries/Components/AccessibilityInfo/AccessibilityInfo.js +1 -1
  33. package/Libraries/Components/AccessibilityInfo/AccessibilityInfo.win32.js +1 -1
  34. package/Libraries/Components/AccessibilityInfo/legacySendAccessibilityEvent.js +17 -0
  35. package/Libraries/Components/ActivityIndicator/ActivityIndicator.js +1 -0
  36. package/Libraries/Components/Button.js +1 -1
  37. package/Libraries/Components/Button.win32.js +1 -1
  38. package/Libraries/Components/DrawerAndroid/DrawerLayoutAndroid.android.js +1 -3
  39. package/Libraries/{NewAppScreen/components/Colors.js → Components/DrawerAndroid/DrawerLayoutAndroid.ios.js} +6 -10
  40. package/Libraries/Components/DrawerAndroid/DrawerLayoutAndroid.js +6 -66
  41. package/Libraries/Components/DrawerAndroid/DrawerLayoutAndroid.js.flow +18 -0
  42. package/Libraries/Components/DrawerAndroid/DrawerLayoutAndroidFallback.js +71 -0
  43. package/Libraries/Components/Keyboard/Keyboard.js +5 -3
  44. package/Libraries/Components/Keyboard/KeyboardAvoidingView.js +6 -3
  45. package/Libraries/Components/Pressable/Pressable.js +20 -4
  46. package/Libraries/Components/Pressable/Pressable.win32.js +20 -4
  47. package/Libraries/Components/ProgressBarAndroid/ProgressBarAndroid.js +25 -3
  48. package/Libraries/Components/ProgressBarAndroid/ProgressBarAndroidTypes.js +29 -20
  49. package/Libraries/Components/RefreshControl/RefreshControl.js +1 -1
  50. package/Libraries/Components/ScrollView/ScrollView.d.ts +3 -3
  51. package/Libraries/Components/ScrollView/ScrollView.js +132 -122
  52. package/Libraries/Components/StaticRenderer.js +1 -1
  53. package/Libraries/Components/Switch/Switch.d.ts +3 -0
  54. package/Libraries/Components/Switch/Switch.js +8 -4
  55. package/Libraries/Components/TextInput/AndroidTextInputNativeComponent.js +2 -1
  56. package/Libraries/Components/TextInput/RCTTextInputViewConfig.js +2 -4
  57. package/Libraries/Components/TextInput/Tests/TextInputTest.d.ts +2 -1
  58. package/Libraries/Components/TextInput/Tests/TextInputTest.js.map +1 -1
  59. package/Libraries/Components/TextInput/TextInput.d.ts +70 -33
  60. package/Libraries/Components/TextInput/TextInput.flow.js +100 -51
  61. package/Libraries/Components/TextInput/TextInput.flow.win32.js +1208 -0
  62. package/Libraries/Components/TextInput/TextInput.js +88 -1027
  63. package/Libraries/Components/TextInput/TextInput.win32.js +89 -1059
  64. package/Libraries/Components/TextInput/TextInputState.js +1 -1
  65. package/Libraries/Components/TextInput/TextInputState.win32.js +1 -1
  66. package/Libraries/{Modal/ModalInjection.js → Components/ToastAndroid/ToastAndroid.ios.js} +3 -5
  67. package/Libraries/Components/ToastAndroid/ToastAndroid.js +4 -32
  68. package/Libraries/Components/ToastAndroid/ToastAndroid.js.flow +109 -0
  69. package/Libraries/Components/ToastAndroid/ToastAndroid.win32.js +4 -32
  70. package/Libraries/Components/ToastAndroid/ToastAndroidFallback.js +45 -0
  71. package/Libraries/Components/Touchable/Tests/TouchableWin32Test.d.ts +2 -1
  72. package/Libraries/Components/Touchable/Tests/TouchableWin32Test.js.map +1 -1
  73. package/Libraries/Components/Touchable/Touchable.js +5 -5
  74. package/Libraries/Components/Touchable/Touchable.win32.js +5 -5
  75. package/Libraries/Components/Touchable/TouchableBounce.js +14 -7
  76. package/Libraries/Components/Touchable/TouchableHighlight.js +10 -7
  77. package/Libraries/Components/Touchable/TouchableNativeFeedback.js +6 -6
  78. package/Libraries/Components/Touchable/TouchableNativeFeedback.win32.js +6 -6
  79. package/Libraries/Components/Touchable/TouchableOpacity.js +13 -6
  80. package/Libraries/Components/View/View.js +18 -21
  81. package/Libraries/Components/View/View.win32.js +21 -24
  82. package/Libraries/Components/View/ViewAccessibility.js +25 -1
  83. package/Libraries/Components/View/ViewAccessibility.win32.js +9 -1
  84. package/Libraries/Components/View/ViewPropTypes.js +49 -3
  85. package/Libraries/Components/View/ViewPropTypes.win32.js +49 -3
  86. package/Libraries/Core/ReactNativeVersion.js +2 -2
  87. package/Libraries/Core/setUpReactDevTools.js +5 -5
  88. package/Libraries/Debugging/DebuggingOverlayRegistry.js +3 -3
  89. package/Libraries/EventEmitter/NativeEventEmitter.js +9 -4
  90. package/Libraries/Image/AssetSourceResolver.js +17 -4
  91. package/Libraries/Image/Image.d.ts +26 -10
  92. package/Libraries/Image/Image.js +17 -0
  93. package/Libraries/Image/Image.js.flow +5 -5
  94. package/Libraries/Image/ImageBackground.js +2 -0
  95. package/Libraries/Image/ImageInjection.js +1 -1
  96. package/Libraries/Image/ImageProps.js +22 -17
  97. package/Libraries/Image/ImageSource.js +3 -1
  98. package/Libraries/Image/ImageSourceUtils.js +4 -2
  99. package/Libraries/Image/ImageTypes.flow.js +1 -1
  100. package/Libraries/Image/Tests/ImageWin32Test.d.ts +2 -1
  101. package/Libraries/Image/Tests/ImageWin32Test.js.map +1 -1
  102. package/Libraries/Interaction/InteractionManager.d.ts +13 -0
  103. package/Libraries/Interaction/InteractionManager.js +1 -1
  104. package/Libraries/Interaction/PanResponder.js +3 -3
  105. package/Libraries/Interaction/TaskQueue.js +1 -0
  106. package/Libraries/LayoutAnimation/LayoutAnimation.js +2 -2
  107. package/Libraries/Linking/Linking.js +1 -1
  108. package/Libraries/Lists/FlatList.d.ts +2 -2
  109. package/Libraries/Lists/FlatList.js +8 -11
  110. package/Libraries/Lists/SectionList.js +39 -42
  111. package/Libraries/Lists/SectionListModern.js +25 -34
  112. package/Libraries/Lists/VirtualizedList.js +1 -0
  113. package/Libraries/Lists/VirtualizedSectionList.js +1 -0
  114. package/Libraries/LogBox/Data/LogBoxData.js +1 -1
  115. package/Libraries/LogBox/LogBoxNotificationContainer.js +1 -1
  116. package/Libraries/LogBox/UI/LogBoxInspectorSourceMapStatus.win32.js +140 -0
  117. package/Libraries/Modal/Modal.js +33 -7
  118. package/Libraries/NativeComponent/BaseViewConfig.android.js +2 -0
  119. package/Libraries/NativeComponent/BaseViewConfig.ios.js +2 -0
  120. package/Libraries/NativeComponent/BaseViewConfig.js +17 -0
  121. package/Libraries/NativeComponent/BaseViewConfig.win32.js +1 -0
  122. package/Libraries/NativeComponent/PlatformBaseViewConfig.js +2 -2
  123. package/Libraries/NativeModules/specs/NativeDevMenu.js +2 -2
  124. package/Libraries/Network/RCTNetworking.android.js +1 -1
  125. package/Libraries/Network/RCTNetworking.ios.js +1 -1
  126. package/Libraries/Network/RCTNetworking.js +17 -0
  127. package/Libraries/Network/RCTNetworking.js.flow +1 -1
  128. package/Libraries/Network/RCTNetworking.win32.js +1 -1
  129. package/Libraries/Network/XMLHttpRequest.js +781 -10
  130. package/Libraries/Performance/Systrace.js +7 -7
  131. package/Libraries/Pressability/Pressability.js +1 -1
  132. package/Libraries/Pressability/Pressability.win32.js +1 -1
  133. package/Libraries/ReactNative/AppContainer-dev.js +5 -4
  134. package/Libraries/ReactNative/AppRegistry.flow.js +49 -0
  135. package/Libraries/ReactNative/AppRegistry.js +2 -322
  136. package/Libraries/ReactNative/AppRegistry.js.flow +23 -0
  137. package/Libraries/ReactNative/AppRegistryImpl.js +316 -0
  138. package/Libraries/ReactNative/FabricUIManager.js +10 -0
  139. package/Libraries/ReactNative/ReactFabricPublicInstance/ReactFabricHostComponent.js +2 -4
  140. package/Libraries/ReactNative/ReactFabricPublicInstance/ReactFabricPublicInstance.js +1 -4
  141. package/Libraries/ReactNative/RendererImplementation.js +10 -5
  142. package/Libraries/ReactNative/getNativeComponentAttributes.js +1 -0
  143. package/Libraries/ReactNative/renderApplication.js +9 -0
  144. package/Libraries/ReactPrivate/ReactNativePrivateInterface.js +3 -3
  145. package/Libraries/ReactPrivate/ReactNativePrivateInterface.js.flow +51 -0
  146. package/Libraries/Renderer/implementations/ReactFabric-dev.js +4840 -4748
  147. package/Libraries/Renderer/implementations/ReactFabric-prod.js +4947 -4829
  148. package/Libraries/Renderer/implementations/ReactFabric-profiling.js +3998 -3888
  149. package/Libraries/Renderer/implementations/ReactNativeRenderer-dev.js +5005 -4948
  150. package/Libraries/Renderer/implementations/ReactNativeRenderer-prod.js +2744 -2652
  151. package/Libraries/Renderer/implementations/ReactNativeRenderer-profiling.js +5020 -4933
  152. package/Libraries/Renderer/shims/ReactNativeTypes.js +3 -3
  153. package/Libraries/Settings/Settings.ios.js +1 -0
  154. package/Libraries/Settings/Settings.js +13 -19
  155. package/Libraries/Settings/Settings.win32.js +19 -20
  156. package/Libraries/Settings/SettingsFallback.js +33 -0
  157. package/Libraries/StyleSheet/PlatformColorValueTypes.js +15 -0
  158. package/Libraries/StyleSheet/PlatformColorValueTypesIOS.js +6 -0
  159. package/Libraries/StyleSheet/Rect.js +1 -0
  160. package/Libraries/StyleSheet/StyleSheet.js +31 -200
  161. package/Libraries/StyleSheet/StyleSheet.js.flow +188 -0
  162. package/Libraries/StyleSheet/{StyleSheet.win32.js → StyleSheetExports.js} +2 -151
  163. package/Libraries/StyleSheet/StyleSheetExports.js.flow +112 -0
  164. package/Libraries/StyleSheet/StyleSheetTypes.d.ts +1 -1
  165. package/Libraries/StyleSheet/StyleSheetTypes.js +130 -52
  166. package/Libraries/StyleSheet/flattenStyle.js +14 -4
  167. package/Libraries/StyleSheet/private/_TransformStyle.js +49 -21
  168. package/Libraries/StyleSheet/processBackgroundImage.js +670 -214
  169. package/Libraries/Text/Text.d.ts +2 -5
  170. package/Libraries/Text/Text.js +3 -3
  171. package/Libraries/Text/Text.win32.js +3 -3
  172. package/Libraries/Text/TextNativeComponent.js +0 -4
  173. package/Libraries/Text/TextNativeComponent.win32.js +0 -4
  174. package/Libraries/Text/TextProps.js +5 -33
  175. package/Libraries/Text/TextProps.win32.js +5 -30
  176. package/Libraries/Types/CodegenTypesNamespace.d.ts +45 -0
  177. package/Libraries/{Blob/__mocks__/BlobModule.js → Types/CodegenTypesNamespace.js} +4 -6
  178. package/Libraries/Types/CoreEventTypes.d.ts +6 -1
  179. package/Libraries/Types/CoreEventTypes.js +1 -1
  180. package/Libraries/Types/CoreEventTypes.win32.js +1 -1
  181. package/Libraries/Utilities/Appearance.js +2 -0
  182. package/Libraries/Utilities/BackHandler.js +17 -0
  183. package/Libraries/Utilities/DeviceInfo.js +2 -0
  184. package/Libraries/Utilities/Dimensions.js +1 -1
  185. package/Libraries/Utilities/Dimensions.win32.js +1 -1
  186. package/Libraries/Utilities/Platform.js +17 -0
  187. package/Libraries/Utilities/PlatformTypes.js +11 -3
  188. package/Libraries/Utilities/ReactNativeTestTools.js +2 -2
  189. package/Libraries/Utilities/codegenNativeCommands.d.ts +18 -0
  190. package/Libraries/Utilities/codegenNativeComponent.d.ts +26 -0
  191. package/Libraries/WebSocket/WebSocket.js +313 -8
  192. package/Libraries/vendor/core/ErrorUtils.js +28 -2
  193. package/Libraries/vendor/emitter/EventEmitter.js +6 -2
  194. package/flow/global.js +1 -0
  195. package/index.js +51 -331
  196. package/index.win32.js +71 -352
  197. package/interface.js +0 -4
  198. package/jest/resolver.js +31 -0
  199. package/overrides.json +45 -47
  200. package/package.json +24 -24
  201. package/src/private/animated/NativeAnimatedHelper.js +21 -8
  202. package/src/private/animated/NativeAnimatedHelper.win32.js +21 -8
  203. package/src/private/animated/createAnimatedPropsHook.js +11 -16
  204. package/src/private/animated/createAnimatedPropsMemoHook.js +1 -2
  205. package/src/private/components/{SafeAreaView_INTERNAL_DO_NOT_USE.js → safeareaview/SafeAreaView_INTERNAL_DO_NOT_USE.js} +6 -6
  206. package/src/private/components/{HScrollViewNativeComponents.js → scrollview/HScrollViewNativeComponents.js} +8 -8
  207. package/src/private/components/scrollview/VScrollViewNativeComponents.js +25 -0
  208. package/src/private/{devmenu → devsupport/devmenu}/DevMenu.js +1 -1
  209. package/src/private/{inspector → devsupport/devmenu/elementinspector}/BorderBox.js +3 -3
  210. package/src/private/{inspector → devsupport/devmenu/elementinspector}/BoxInspector.js +6 -5
  211. package/src/private/{inspector → devsupport/devmenu/elementinspector}/ElementBox.js +8 -6
  212. package/src/private/{inspector → devsupport/devmenu/elementinspector}/ElementProperties.js +11 -10
  213. package/src/private/{inspector → devsupport/devmenu/elementinspector}/Inspector.js +14 -12
  214. package/src/private/{inspector → devsupport/devmenu/elementinspector}/InspectorOverlay.js +5 -4
  215. package/src/private/{inspector → devsupport/devmenu/elementinspector}/InspectorPanel.js +9 -8
  216. package/src/private/{inspector → devsupport/devmenu/elementinspector}/NetworkOverlay.js +10 -9
  217. package/src/private/{inspector → devsupport/devmenu/elementinspector}/ReactDevToolsOverlay.js +7 -7
  218. package/src/private/{inspector → devsupport/devmenu/elementinspector}/StyleInspector.js +7 -6
  219. package/src/private/{inspector → devsupport/devmenu/elementinspector}/XHRInterceptor.js +2 -2
  220. package/src/private/{inspector → devsupport/devmenu/elementinspector}/getInspectorDataForViewAtPoint.js +4 -4
  221. package/src/private/{inspector → devsupport/devmenu/elementinspector}/resolveBoxStyle.js +1 -1
  222. package/src/private/{inspector → devsupport/devmenu/perfmonitor}/PerformanceOverlay.js +6 -5
  223. package/src/private/{specs_DEPRECATED/modules → devsupport/devmenu/specs}/NativeDevMenu.js +2 -2
  224. package/src/private/{debugging → devsupport/rndevtools}/ReactDevToolsSettingsManager.android.js +1 -1
  225. package/src/private/{debugging → devsupport/rndevtools}/ReactDevToolsSettingsManager.ios.js +1 -1
  226. package/src/private/{debugging → devsupport/rndevtools}/ReactDevToolsSettingsManager.win32.js +1 -1
  227. package/src/private/{debugging → devsupport/rndevtools}/setUpFuseboxReactDevToolsDispatcher.js +1 -1
  228. package/src/private/{fusebox → devsupport/rndevtools}/specs/NativeReactDevToolsRuntimeSettingsModule.js +2 -2
  229. package/src/private/{specs_DEPRECATED/modules → devsupport/rndevtools/specs}/NativeReactDevToolsSettingsManager.js +2 -2
  230. package/src/private/featureflags/ReactNativeFeatureFlags.js +82 -80
  231. package/src/private/featureflags/ReactNativeFeatureFlagsBase.js +9 -1
  232. package/src/private/featureflags/specs/NativeReactNativeFeatureFlags.js +17 -13
  233. package/src/private/renderer/errorhandling/ErrorHandlers.js +2 -2
  234. package/src/private/specs_DEPRECATED/modules/NativeAnimatedModule.js +1 -1
  235. package/src/private/specs_DEPRECATED/modules/NativeAnimatedTurboModule.js +1 -1
  236. package/src/private/specs_DEPRECATED/modules/NativeSampleTurboModule.js +3 -0
  237. package/src/private/styles/composeStyles.js +12 -5
  238. package/src/private/types/HostComponent.js +1 -1
  239. package/src/private/types/HostInstance.js +67 -1
  240. package/src/private/webapis/dom/nodes/ReactNativeElement.js +2 -5
  241. package/src/private/webapis/dom/nodes/ReadOnlyNode.js +5 -18
  242. package/src/private/webapis/dom/nodes/internals/NodeInternals.js +6 -0
  243. package/src/private/webapis/performance/Performance.js +1 -3
  244. package/src/private/webapis/performance/PerformanceEntry.js +6 -1
  245. package/src/private/webapis/performance/internals/RawPerformanceEntry.js +3 -0
  246. package/src/private/webapis/performance/specs/NativePerformance.js +10 -1
  247. package/src/types/globals.d.ts +42 -0
  248. package/src-win/Libraries/Components/TextInput/Tests/TextInputTest.tsx +7 -7
  249. package/src-win/Libraries/Components/Touchable/Tests/TouchableWin32Test.tsx +3 -3
  250. package/src-win/Libraries/Image/Tests/ImageWin32Test.tsx +1 -1
  251. package/src-win/Libraries/Text/Text.d.ts +2 -5
  252. package/types/index.d.ts +6 -3
  253. package/types/public/ReactNativeTypes.d.ts +2 -2
  254. package/Libraries/BatchedBridge/__mocks__/MessageQueueTestConfig.js +0 -38
  255. package/Libraries/BatchedBridge/__mocks__/MessageQueueTestModule.js +0 -22
  256. package/Libraries/Blob/FileReader_new.js +0 -231
  257. package/Libraries/Blob/FileReader_old.js +0 -186
  258. package/Libraries/Blob/__mocks__/FileReaderModule.js +0 -20
  259. package/Libraries/Components/RefreshControl/__mocks__/RefreshControlMock.js +0 -32
  260. package/Libraries/Core/__mocks__/ErrorUtils.js +0 -33
  261. package/Libraries/Core/__mocks__/NativeExceptionsManager.js +0 -19
  262. package/Libraries/EventEmitter/__mocks__/NativeEventEmitter.js +0 -49
  263. package/Libraries/Events/CustomEvent.js +0 -32
  264. package/Libraries/Events/EventPolyfill.js +0 -239
  265. package/Libraries/Lists/__flowtests__/FlatList-flowtest.js +0 -118
  266. package/Libraries/Lists/__flowtests__/SectionList-flowtest.js +0 -134
  267. package/Libraries/Network/XMLHttpRequest_new.js +0 -794
  268. package/Libraries/Network/XMLHttpRequest_old.js +0 -701
  269. package/Libraries/NewAppScreen/components/DebugInstructions.js +0 -41
  270. package/Libraries/NewAppScreen/components/Header.js +0 -77
  271. package/Libraries/NewAppScreen/components/HermesBadge.js +0 -53
  272. package/Libraries/NewAppScreen/components/LearnMoreLinks.js +0 -148
  273. package/Libraries/NewAppScreen/components/ReloadInstructions.js +0 -39
  274. package/Libraries/NewAppScreen/components/logo.png +0 -0
  275. package/Libraries/NewAppScreen/index.js +0 -25
  276. package/Libraries/StyleSheet/__flowtests__/StyleSheet-flowtest.js +0 -58
  277. package/Libraries/Utilities/DeviceInfo.win32.js +0 -19
  278. package/Libraries/Utilities/__mocks__/BackHandler.js +0 -45
  279. package/Libraries/Utilities/__mocks__/GlobalPerformanceLogger.js +0 -16
  280. package/Libraries/Utilities/__mocks__/PixelRatio.js +0 -25
  281. package/Libraries/WebSocket/WebSocketEvent.js +0 -30
  282. package/Libraries/WebSocket/WebSocket_new.js +0 -325
  283. package/Libraries/WebSocket/WebSocket_old.js +0 -297
  284. package/Libraries/WebSocket/__mocks__/event-target-shim.js +0 -27
  285. package/Libraries/__flowtests__/ReactNativeTypes-flowtest.js +0 -30
  286. package/Libraries/vendor/emitter/__flowtests__/EventEmitter-flowtest.js +0 -81
  287. package/flow/jest.js +0 -1287
  288. package/jest/__tests__/setup-test.js +0 -18
  289. package/src/private/components/VScrollViewNativeComponents.js +0 -25
  290. package/src/private/utilities/ensureInstance.js +0 -21
  291. package/src/private/webapis/performance/specs/__mocks__/NativePerformanceMock.js +0 -267
  292. package/types/modules/LaunchScreen.d.ts +0 -18
  293. /package/src/private/{devmenu → devsupport/devmenu}/DevMenu.d.ts +0 -0
  294. /package/src/private/{debugging → devsupport/rndevtools}/FuseboxSessionObserver.js +0 -0
@@ -4,7 +4,7 @@
4
4
  * This source code is licensed under the MIT license found in the
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  *
7
- * @generated SignedSource<<3e68d888bf4d8ac71b63571a639d265b>>
7
+ * @generated SignedSource<<6667fc8e4fdd2db0b54c908155b110cf>>
8
8
  * @flow strict
9
9
  */
10
10
 
@@ -33,15 +33,12 @@ export type ReactNativeFeatureFlagsJsOnly = $ReadOnly<{
33
33
  avoidStateUpdateInAnimatedPropsMemo: Getter<boolean>,
34
34
  disableInteractionManager: Getter<boolean>,
35
35
  enableAccessToHostTreeInFabric: Getter<boolean>,
36
- enableAnimatedClearImmediateFix: Getter<boolean>,
37
- enableDOMDocumentAPI: Getter<boolean>,
38
36
  fixVirtualizeListCollapseWindowSize: Getter<boolean>,
39
37
  isLayoutAnimationEnabled: Getter<boolean>,
40
38
  scheduleAnimatedCleanupInMicrotask: Getter<boolean>,
41
39
  shouldUseAnimatedObjectForTransform: Getter<boolean>,
42
40
  shouldUseRemoveClippedSubviewsAsDefaultOnIOS: Getter<boolean>,
43
41
  shouldUseSetNativePropsInFabric: Getter<boolean>,
44
- useRefsForTextInputState: Getter<boolean>,
45
42
  }>;
46
43
 
47
44
  export type ReactNativeFeatureFlagsJsOnlyOverrides = OverridesFor<ReactNativeFeatureFlagsJsOnly>;
@@ -50,46 +47,50 @@ export type ReactNativeFeatureFlags = $ReadOnly<{
50
47
  ...ReactNativeFeatureFlagsJsOnly,
51
48
  commonTestFlag: Getter<boolean>,
52
49
  commonTestFlagWithoutNativeImplementation: Getter<boolean>,
50
+ animatedShouldSignalBatch: Getter<boolean>,
51
+ cxxNativeAnimatedEnabled: Getter<boolean>,
52
+ disableMainQueueSyncDispatchIOS: Getter<boolean>,
53
53
  disableMountItemReorderingAndroid: Getter<boolean>,
54
+ enableAccessibilityOrder: Getter<boolean>,
54
55
  enableAccumulatedUpdatesInRawPropsAndroid: Getter<boolean>,
55
56
  enableBridgelessArchitecture: Getter<boolean>,
56
57
  enableCppPropsIteratorSetter: Getter<boolean>,
58
+ enableCustomFocusSearchOnClippedElementsAndroid: Getter<boolean>,
59
+ enableDestroyShadowTreeRevisionAsync: Getter<boolean>,
60
+ enableDoubleMeasurementFixAndroid: Getter<boolean>,
57
61
  enableEagerRootViewAttachment: Getter<boolean>,
58
62
  enableFabricLogs: Getter<boolean>,
59
63
  enableFabricRenderer: Getter<boolean>,
64
+ enableFixForParentTagDuringReparenting: Getter<boolean>,
65
+ enableFontScaleChangesUpdatingLayout: Getter<boolean>,
60
66
  enableIOSViewClipToPaddingBox: Getter<boolean>,
61
- enableImagePrefetchingAndroid: Getter<boolean>,
62
67
  enableJSRuntimeGCOnMemoryPressureOnIOS: Getter<boolean>,
63
68
  enableLayoutAnimationsOnAndroid: Getter<boolean>,
64
69
  enableLayoutAnimationsOnIOS: Getter<boolean>,
65
- enableLongTaskAPI: Getter<boolean>,
70
+ enableMainQueueModulesOnIOS: Getter<boolean>,
66
71
  enableNativeCSSParsing: Getter<boolean>,
72
+ enableNetworkEventReporting: Getter<boolean>,
67
73
  enableNewBackgroundAndBorderDrawables: Getter<boolean>,
68
- enablePreciseSchedulingForPremountItemsOnAndroid: Getter<boolean>,
74
+ enablePreparedTextLayout: Getter<boolean>,
69
75
  enablePropsUpdateReconciliationAndroid: Getter<boolean>,
70
- enableReportEventPaintTime: Getter<boolean>,
76
+ enableResourceTimingAPI: Getter<boolean>,
71
77
  enableSynchronousStateUpdates: Getter<boolean>,
72
- enableUIConsistency: Getter<boolean>,
73
78
  enableViewCulling: Getter<boolean>,
74
79
  enableViewRecycling: Getter<boolean>,
75
80
  enableViewRecyclingForText: Getter<boolean>,
76
81
  enableViewRecyclingForView: Getter<boolean>,
77
- excludeYogaFromRawProps: Getter<boolean>,
78
- fixDifferentiatorEmittingUpdatesWithWrongParentTag: Getter<boolean>,
79
82
  fixMappingOfEventPrioritiesBetweenFabricAndReact: Getter<boolean>,
80
- fixMountingCoordinatorReportedPendingTransactionsOnAndroid: Getter<boolean>,
81
83
  fuseboxEnabledRelease: Getter<boolean>,
82
84
  fuseboxNetworkInspectionEnabled: Getter<boolean>,
83
- lazyAnimationCallbacks: Getter<boolean>,
84
- removeTurboModuleManagerDelegateMutex: Getter<boolean>,
85
- throwExceptionInsteadOfDeadlockOnTurboModuleSetupDuringSyncRenderIOS: Getter<boolean>,
85
+ incorporateMaxLinesDuringAndroidLayout: Getter<boolean>,
86
86
  traceTurboModulePromiseRejectionsOnAndroid: Getter<boolean>,
87
+ updateRuntimeShadowNodeReferencesOnCommit: Getter<boolean>,
87
88
  useAlwaysAvailableJSErrorHandling: Getter<boolean>,
88
- useEditTextStockAndroidFocusBehavior: Getter<boolean>,
89
89
  useFabricInterop: Getter<boolean>,
90
90
  useNativeViewConfigsInBridgelessMode: Getter<boolean>,
91
91
  useOptimizedEventBatchingOnAndroid: Getter<boolean>,
92
92
  useRawPropsJsiValue: Getter<boolean>,
93
+ useShadowNodeStateOnClone: Getter<boolean>,
93
94
  useTurboModuleInterop: Getter<boolean>,
94
95
  useTurboModules: Getter<boolean>,
95
96
  }>;
@@ -117,23 +118,13 @@ export const avoidStateUpdateInAnimatedPropsMemo: Getter<boolean> = createJavaSc
117
118
  /**
118
119
  * Disables InteractionManager and replaces its scheduler with `setImmediate`.
119
120
  */
120
- export const disableInteractionManager: Getter<boolean> = createJavaScriptFlagGetter('disableInteractionManager', false);
121
+ export const disableInteractionManager: Getter<boolean> = createJavaScriptFlagGetter('disableInteractionManager', true);
121
122
 
122
123
  /**
123
124
  * Enables access to the host tree in Fabric using DOM-compatible APIs.
124
125
  */
125
126
  export const enableAccessToHostTreeInFabric: Getter<boolean> = createJavaScriptFlagGetter('enableAccessToHostTreeInFabric', false);
126
127
 
127
- /**
128
- * Enables an experimental to use the proper clearIntermediate instead of calling the wrong clearTimeout and canceling another timer.
129
- */
130
- export const enableAnimatedClearImmediateFix: Getter<boolean> = createJavaScriptFlagGetter('enableAnimatedClearImmediateFix', true);
131
-
132
- /**
133
- * Enables the DOM Document API, exposing instaces of document through `getRootNode` and `ownerDocument`, and providing access to the `documentElement` representing the root node. This flag will be short-lived, only to test the Document API specifically, and then it will be collapsed into the enableAccessToHostTreeInFabric flag.
134
- */
135
- export const enableDOMDocumentAPI: Getter<boolean> = createJavaScriptFlagGetter('enableDOMDocumentAPI', false);
136
-
137
128
  /**
138
129
  * Fixing an edge case where the current window size is not properly calculated with fast scrolling. Window size collapsed to 1 element even if windowSize more than the current amount of elements
139
130
  */
@@ -145,9 +136,9 @@ export const fixVirtualizeListCollapseWindowSize: Getter<boolean> = createJavaSc
145
136
  export const isLayoutAnimationEnabled: Getter<boolean> = createJavaScriptFlagGetter('isLayoutAnimationEnabled', true);
146
137
 
147
138
  /**
148
- * Changes the cleanup of`AnimatedProps` to occur in a microtask instead of synchronously during effect cleanup (for unmount) or subsequent mounts (for updates).
139
+ * Changes the cleanup of `AnimatedProps` to occur in a microtask instead of synchronously during effect cleanup (for unmount) or subsequent mounts (for updates).
149
140
  */
150
- export const scheduleAnimatedCleanupInMicrotask: Getter<boolean> = createJavaScriptFlagGetter('scheduleAnimatedCleanupInMicrotask', false);
141
+ export const scheduleAnimatedCleanupInMicrotask: Getter<boolean> = createJavaScriptFlagGetter('scheduleAnimatedCleanupInMicrotask', true);
151
142
 
152
143
  /**
153
144
  * Enables use of AnimatedObject for animating transform values.
@@ -164,11 +155,6 @@ export const shouldUseRemoveClippedSubviewsAsDefaultOnIOS: Getter<boolean> = cre
164
155
  */
165
156
  export const shouldUseSetNativePropsInFabric: Getter<boolean> = createJavaScriptFlagGetter('shouldUseSetNativePropsInFabric', true);
166
157
 
167
- /**
168
- * Enable a variant of TextInput that moves some state to refs to avoid unnecessary re-renders
169
- */
170
- export const useRefsForTextInputState: Getter<boolean> = createJavaScriptFlagGetter('useRefsForTextInputState', false);
171
-
172
158
  /**
173
159
  * Common flag for testing. Do NOT modify.
174
160
  */
@@ -178,21 +164,49 @@ export const commonTestFlag: Getter<boolean> = createNativeFlagGetter('commonTes
178
164
  */
179
165
  export const commonTestFlagWithoutNativeImplementation: Getter<boolean> = createNativeFlagGetter('commonTestFlagWithoutNativeImplementation', false);
180
166
  /**
181
- * Prevent FabricMountingManager from reordering mountitems, which may lead to invalid state on the UI thread
167
+ * Enables start- and finishOperationBatch on any platform.
168
+ */
169
+ export const animatedShouldSignalBatch: Getter<boolean> = createNativeFlagGetter('animatedShouldSignalBatch', false);
170
+ /**
171
+ * Use a C++ implementation of Native Animated instead of the platform implementation.
172
+ */
173
+ export const cxxNativeAnimatedEnabled: Getter<boolean> = createNativeFlagGetter('cxxNativeAnimatedEnabled', false);
174
+ /**
175
+ * Disable sync dispatch on the main queue on iOS
176
+ */
177
+ export const disableMainQueueSyncDispatchIOS: Getter<boolean> = createNativeFlagGetter('disableMainQueueSyncDispatchIOS', false);
178
+ /**
179
+ * Prevent FabricMountingManager from reordering mountItems, which may lead to invalid state on the UI thread
182
180
  */
183
181
  export const disableMountItemReorderingAndroid: Getter<boolean> = createNativeFlagGetter('disableMountItemReorderingAndroid', false);
184
182
  /**
185
- * When enabled, Andoid will accumulate updates in rawProps to reduce the number of mounting instructions for cascading rerenders.
183
+ * When enabled, the accessibilityOrder prop will propagate to native platforms and define the accessibility order.
184
+ */
185
+ export const enableAccessibilityOrder: Getter<boolean> = createNativeFlagGetter('enableAccessibilityOrder', false);
186
+ /**
187
+ * When enabled, Android will accumulate updates in rawProps to reduce the number of mounting instructions for cascading re-renders.
186
188
  */
187
189
  export const enableAccumulatedUpdatesInRawPropsAndroid: Getter<boolean> = createNativeFlagGetter('enableAccumulatedUpdatesInRawPropsAndroid', false);
188
190
  /**
189
- * Feature flag to enable the new bridgeless architecture. Note: Enabling this will force enable the following flags: `useTurboModules` & `enableFabricRenderer.
191
+ * Feature flag to enable the new bridgeless architecture. Note: Enabling this will force enable the following flags: `useTurboModules` & `enableFabricRenderer`.
190
192
  */
191
193
  export const enableBridgelessArchitecture: Getter<boolean> = createNativeFlagGetter('enableBridgelessArchitecture', false);
192
194
  /**
193
195
  * Enable prop iterator setter-style construction of Props in C++ (this flag is not used in Java).
194
196
  */
195
197
  export const enableCppPropsIteratorSetter: Getter<boolean> = createNativeFlagGetter('enableCppPropsIteratorSetter', false);
198
+ /**
199
+ * This enables the fabric implementation of focus search so that we can focus clipped elements
200
+ */
201
+ export const enableCustomFocusSearchOnClippedElementsAndroid: Getter<boolean> = createNativeFlagGetter('enableCustomFocusSearchOnClippedElementsAndroid', true);
202
+ /**
203
+ * Enables destructor calls for ShadowTreeRevision in the background to reduce UI thread work.
204
+ */
205
+ export const enableDestroyShadowTreeRevisionAsync: Getter<boolean> = createNativeFlagGetter('enableDestroyShadowTreeRevisionAsync', false);
206
+ /**
207
+ * When enabled a subset of components will avoid double measurement on Android.
208
+ */
209
+ export const enableDoubleMeasurementFixAndroid: Getter<boolean> = createNativeFlagGetter('enableDoubleMeasurementFixAndroid', false);
196
210
  /**
197
211
  * Feature flag to configure eager attachment of the root view/initialisation of the JS code.
198
212
  */
@@ -206,13 +220,17 @@ export const enableFabricLogs: Getter<boolean> = createNativeFlagGetter('enableF
206
220
  */
207
221
  export const enableFabricRenderer: Getter<boolean> = createNativeFlagGetter('enableFabricRenderer', false);
208
222
  /**
209
- * iOS Views will clip to their padding box vs border box
223
+ * This feature flag enables a fix for reparenting fix in differentiator
210
224
  */
211
- export const enableIOSViewClipToPaddingBox: Getter<boolean> = createNativeFlagGetter('enableIOSViewClipToPaddingBox', false);
225
+ export const enableFixForParentTagDuringReparenting: Getter<boolean> = createNativeFlagGetter('enableFixForParentTagDuringReparenting', false);
212
226
  /**
213
- * When enabled, Andoid will build and initiate image prefetch requests on ImageShadowNode::layout
227
+ * Enables font scale changes updating layout for measurable nodes.
214
228
  */
215
- export const enableImagePrefetchingAndroid: Getter<boolean> = createNativeFlagGetter('enableImagePrefetchingAndroid', false);
229
+ export const enableFontScaleChangesUpdatingLayout: Getter<boolean> = createNativeFlagGetter('enableFontScaleChangesUpdatingLayout', false);
230
+ /**
231
+ * iOS Views will clip to their padding box vs border box
232
+ */
233
+ export const enableIOSViewClipToPaddingBox: Getter<boolean> = createNativeFlagGetter('enableIOSViewClipToPaddingBox', false);
216
234
  /**
217
235
  * Trigger JS runtime GC on memory pressure event on iOS
218
236
  */
@@ -226,37 +244,37 @@ export const enableLayoutAnimationsOnAndroid: Getter<boolean> = createNativeFlag
226
244
  */
227
245
  export const enableLayoutAnimationsOnIOS: Getter<boolean> = createNativeFlagGetter('enableLayoutAnimationsOnIOS', true);
228
246
  /**
229
- * Enables the reporting of long tasks through `PerformanceObserver`. Only works if the event loop is enabled.
247
+ * Makes modules requiring main queue setup initialize on the main thread, during React Native init.
230
248
  */
231
- export const enableLongTaskAPI: Getter<boolean> = createNativeFlagGetter('enableLongTaskAPI', false);
249
+ export const enableMainQueueModulesOnIOS: Getter<boolean> = createNativeFlagGetter('enableMainQueueModulesOnIOS', false);
232
250
  /**
233
251
  * Parse CSS strings using the Fabric CSS parser instead of ViewConfig processing
234
252
  */
235
253
  export const enableNativeCSSParsing: Getter<boolean> = createNativeFlagGetter('enableNativeCSSParsing', false);
254
+ /**
255
+ * Enable network event reporting hooks in each native platform through `NetworkReporter`. This flag should be combined with `enableResourceTimingAPI` and `fuseboxNetworkInspectionEnabled` to enable end-to-end reporting behaviour via the Web Performance API and CDP debugging respectively.
256
+ */
257
+ export const enableNetworkEventReporting: Getter<boolean> = createNativeFlagGetter('enableNetworkEventReporting', false);
236
258
  /**
237
259
  * Use BackgroundDrawable and BorderDrawable instead of CSSBackgroundDrawable
238
260
  */
239
- export const enableNewBackgroundAndBorderDrawables: Getter<boolean> = createNativeFlagGetter('enableNewBackgroundAndBorderDrawables', false);
261
+ export const enableNewBackgroundAndBorderDrawables: Getter<boolean> = createNativeFlagGetter('enableNewBackgroundAndBorderDrawables', true);
240
262
  /**
241
- * Moves execution of pre-mount items to outside the choregrapher in the main thread, so we can estimate idle time more precisely (Android only).
263
+ * Enables caching text layout artifacts for later reuse
242
264
  */
243
- export const enablePreciseSchedulingForPremountItemsOnAndroid: Getter<boolean> = createNativeFlagGetter('enablePreciseSchedulingForPremountItemsOnAndroid', false);
265
+ export const enablePreparedTextLayout: Getter<boolean> = createNativeFlagGetter('enablePreparedTextLayout', false);
244
266
  /**
245
267
  * When enabled, Android will receive prop updates based on the differences between the last rendered shadow node and the last committed shadow node.
246
268
  */
247
269
  export const enablePropsUpdateReconciliationAndroid: Getter<boolean> = createNativeFlagGetter('enablePropsUpdateReconciliationAndroid', false);
248
270
  /**
249
- * Report paint time inside the Event Timing API implementation (PerformanceObserver).
271
+ * Enables the reporting of network resource timings through `PerformanceObserver`.
250
272
  */
251
- export const enableReportEventPaintTime: Getter<boolean> = createNativeFlagGetter('enableReportEventPaintTime', false);
273
+ export const enableResourceTimingAPI: Getter<boolean> = createNativeFlagGetter('enableResourceTimingAPI', false);
252
274
  /**
253
275
  * Dispatches state updates synchronously in Fabric (e.g.: updates the scroll position in the shadow tree synchronously from the main thread).
254
276
  */
255
277
  export const enableSynchronousStateUpdates: Getter<boolean> = createNativeFlagGetter('enableSynchronousStateUpdates', false);
256
- /**
257
- * Ensures that JavaScript always has a consistent view of the state of the UI (e.g.: commits done in other threads are not immediately propagated to JS during its execution).
258
- */
259
- export const enableUIConsistency: Getter<boolean> = createNativeFlagGetter('enableUIConsistency', false);
260
278
  /**
261
279
  * Enables View Culling: as soon as a view goes off screen, it can be reused anywhere in the UI and pieced together with other items to create new UI elements.
262
280
  */
@@ -273,58 +291,38 @@ export const enableViewRecyclingForText: Getter<boolean> = createNativeFlagGette
273
291
  * Enables View Recycling for <View> via ReactViewGroup/ReactViewManager.
274
292
  */
275
293
  export const enableViewRecyclingForView: Getter<boolean> = createNativeFlagGetter('enableViewRecyclingForView', true);
276
- /**
277
- * When enabled, rawProps in Props will not include Yoga specific props.
278
- */
279
- export const excludeYogaFromRawProps: Getter<boolean> = createNativeFlagGetter('excludeYogaFromRawProps', false);
280
- /**
281
- * Fixes a bug in Differentiator where parent views may be referenced before they're created
282
- */
283
- export const fixDifferentiatorEmittingUpdatesWithWrongParentTag: Getter<boolean> = createNativeFlagGetter('fixDifferentiatorEmittingUpdatesWithWrongParentTag', true);
284
294
  /**
285
295
  * Uses the default event priority instead of the discreet event priority by default when dispatching events from Fabric to React.
286
296
  */
287
297
  export const fixMappingOfEventPrioritiesBetweenFabricAndReact: Getter<boolean> = createNativeFlagGetter('fixMappingOfEventPrioritiesBetweenFabricAndReact', false);
288
- /**
289
- * Fixes a limitation on Android where the mounting coordinator would report there are no pending transactions but some of them were actually not processed due to the use of the push model.
290
- */
291
- export const fixMountingCoordinatorReportedPendingTransactionsOnAndroid: Getter<boolean> = createNativeFlagGetter('fixMountingCoordinatorReportedPendingTransactionsOnAndroid', false);
292
298
  /**
293
299
  * Flag determining if the React Native DevTools (Fusebox) CDP backend should be enabled in release builds. This flag is global and should not be changed across React Host lifetimes.
294
300
  */
295
301
  export const fuseboxEnabledRelease: Getter<boolean> = createNativeFlagGetter('fuseboxEnabledRelease', false);
296
302
  /**
297
- * Enable network inspection support in the React Native DevTools CDP backend. This flag is global and should not be changed across React Host lifetimes.
303
+ * Enable network inspection support in the React Native DevTools CDP backend. Requires `enableBridgelessArchitecture`. This flag is global and should not be changed across React Host lifetimes.
298
304
  */
299
305
  export const fuseboxNetworkInspectionEnabled: Getter<boolean> = createNativeFlagGetter('fuseboxNetworkInspectionEnabled', false);
300
306
  /**
301
- * Only enqueue Choreographer calls if there is an ongoing animation, instead of enqueueing every frame.
302
- */
303
- export const lazyAnimationCallbacks: Getter<boolean> = createNativeFlagGetter('lazyAnimationCallbacks', false);
304
- /**
305
- * When enabled, mutex _turboModuleManagerDelegateMutex in RCTTurboModuleManager will not be used
306
- */
307
- export const removeTurboModuleManagerDelegateMutex: Getter<boolean> = createNativeFlagGetter('removeTurboModuleManagerDelegateMutex', false);
308
- /**
309
- * Throw an exception instead of deadlocking when a TurboModule that requires main queue setup is initialized during a synchronous render on iOS.
307
+ * Set maxLines and ellipsization during Android layout creation
310
308
  */
311
- export const throwExceptionInsteadOfDeadlockOnTurboModuleSetupDuringSyncRenderIOS: Getter<boolean> = createNativeFlagGetter('throwExceptionInsteadOfDeadlockOnTurboModuleSetupDuringSyncRenderIOS', false);
309
+ export const incorporateMaxLinesDuringAndroidLayout: Getter<boolean> = createNativeFlagGetter('incorporateMaxLinesDuringAndroidLayout', true);
312
310
  /**
313
311
  * Enables storing js caller stack when creating promise in native module. This is useful in case of Promise rejection and tracing the cause.
314
312
  */
315
313
  export const traceTurboModulePromiseRejectionsOnAndroid: Getter<boolean> = createNativeFlagGetter('traceTurboModulePromiseRejectionsOnAndroid', false);
316
314
  /**
317
- * In Bridgeless mode, use the always available javascript error reporting pipeline.
315
+ * When enabled, runtime shadow node references will be updated during the commit. This allows running RSNRU from any thread without corrupting the renderer state.
318
316
  */
319
- export const useAlwaysAvailableJSErrorHandling: Getter<boolean> = createNativeFlagGetter('useAlwaysAvailableJSErrorHandling', false);
317
+ export const updateRuntimeShadowNodeReferencesOnCommit: Getter<boolean> = createNativeFlagGetter('updateRuntimeShadowNodeReferencesOnCommit', false);
320
318
  /**
321
- * If true, focusing in ReactEditText will mainly use stock Android requestFocus() behavior. If false it will use legacy custom focus behavior.
319
+ * In Bridgeless mode, use the always available javascript error reporting pipeline.
322
320
  */
323
- export const useEditTextStockAndroidFocusBehavior: Getter<boolean> = createNativeFlagGetter('useEditTextStockAndroidFocusBehavior', true);
321
+ export const useAlwaysAvailableJSErrorHandling: Getter<boolean> = createNativeFlagGetter('useAlwaysAvailableJSErrorHandling', false);
324
322
  /**
325
323
  * Should this application enable the Fabric Interop Layer for Android? If yes, the application will behave so that it can accept non-Fabric components and render them on Fabric. This toggle is controlling extra logic such as custom event dispatching that are needed for the Fabric Interop Layer to work correctly.
326
324
  */
327
- export const useFabricInterop: Getter<boolean> = createNativeFlagGetter('useFabricInterop', false);
325
+ export const useFabricInterop: Getter<boolean> = createNativeFlagGetter('useFabricInterop', true);
328
326
  /**
329
327
  * When enabled, the native view configs are used in bridgeless mode.
330
328
  */
@@ -337,6 +335,10 @@ export const useOptimizedEventBatchingOnAndroid: Getter<boolean> = createNativeF
337
335
  * Instead of using folly::dynamic as internal representation in RawProps and RawValue, use jsi::Value
338
336
  */
339
337
  export const useRawPropsJsiValue: Getter<boolean> = createNativeFlagGetter('useRawPropsJsiValue', false);
338
+ /**
339
+ * Use the state stored on the source shadow node when cloning it instead of reading in the most recent state on the shadow node family.
340
+ */
341
+ export const useShadowNodeStateOnClone: Getter<boolean> = createNativeFlagGetter('useShadowNodeStateOnClone', false);
340
342
  /**
341
343
  * In Bridgeless mode, should legacy NativeModules use the TurboModule system?
342
344
  */
@@ -96,9 +96,17 @@ export function setOverrides(
96
96
  }
97
97
 
98
98
  const reportedConfigNames: Set<string> = new Set();
99
+ const hasTurboModules =
100
+ global.RN$Bridgeless === true || global.__turboModuleProxy != null;
99
101
 
100
102
  function maybeLogUnavailableNativeModuleError(configName: string): void {
101
- if (!NativeReactNativeFeatureFlags && !reportedConfigNames.has(configName)) {
103
+ if (
104
+ !NativeReactNativeFeatureFlags &&
105
+ // Don't log more than once per config
106
+ !reportedConfigNames.has(configName) &&
107
+ // Don't log in the legacy architecture.
108
+ hasTurboModules
109
+ ) {
102
110
  reportedConfigNames.add(configName);
103
111
  console.error(
104
112
  `Could not access feature flag '${configName}' because native module method was not available`,
@@ -4,7 +4,7 @@
4
4
  * This source code is licensed under the MIT license found in the
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  *
7
- * @generated SignedSource<<0d611c17d522627c59a68d083eb6b6dc>>
7
+ * @generated SignedSource<<4bf477efaec82ad8e9e4b1bc17705fd2>>
8
8
  * @flow strict
9
9
  */
10
10
 
@@ -25,46 +25,50 @@ import * as TurboModuleRegistry from '../../../../Libraries/TurboModule/TurboMod
25
25
  export interface Spec extends TurboModule {
26
26
  +commonTestFlag?: () => boolean;
27
27
  +commonTestFlagWithoutNativeImplementation?: () => boolean;
28
+ +animatedShouldSignalBatch?: () => boolean;
29
+ +cxxNativeAnimatedEnabled?: () => boolean;
30
+ +disableMainQueueSyncDispatchIOS?: () => boolean;
28
31
  +disableMountItemReorderingAndroid?: () => boolean;
32
+ +enableAccessibilityOrder?: () => boolean;
29
33
  +enableAccumulatedUpdatesInRawPropsAndroid?: () => boolean;
30
34
  +enableBridgelessArchitecture?: () => boolean;
31
35
  +enableCppPropsIteratorSetter?: () => boolean;
36
+ +enableCustomFocusSearchOnClippedElementsAndroid?: () => boolean;
37
+ +enableDestroyShadowTreeRevisionAsync?: () => boolean;
38
+ +enableDoubleMeasurementFixAndroid?: () => boolean;
32
39
  +enableEagerRootViewAttachment?: () => boolean;
33
40
  +enableFabricLogs?: () => boolean;
34
41
  +enableFabricRenderer?: () => boolean;
42
+ +enableFixForParentTagDuringReparenting?: () => boolean;
43
+ +enableFontScaleChangesUpdatingLayout?: () => boolean;
35
44
  +enableIOSViewClipToPaddingBox?: () => boolean;
36
- +enableImagePrefetchingAndroid?: () => boolean;
37
45
  +enableJSRuntimeGCOnMemoryPressureOnIOS?: () => boolean;
38
46
  +enableLayoutAnimationsOnAndroid?: () => boolean;
39
47
  +enableLayoutAnimationsOnIOS?: () => boolean;
40
- +enableLongTaskAPI?: () => boolean;
48
+ +enableMainQueueModulesOnIOS?: () => boolean;
41
49
  +enableNativeCSSParsing?: () => boolean;
50
+ +enableNetworkEventReporting?: () => boolean;
42
51
  +enableNewBackgroundAndBorderDrawables?: () => boolean;
43
- +enablePreciseSchedulingForPremountItemsOnAndroid?: () => boolean;
52
+ +enablePreparedTextLayout?: () => boolean;
44
53
  +enablePropsUpdateReconciliationAndroid?: () => boolean;
45
- +enableReportEventPaintTime?: () => boolean;
54
+ +enableResourceTimingAPI?: () => boolean;
46
55
  +enableSynchronousStateUpdates?: () => boolean;
47
- +enableUIConsistency?: () => boolean;
48
56
  +enableViewCulling?: () => boolean;
49
57
  +enableViewRecycling?: () => boolean;
50
58
  +enableViewRecyclingForText?: () => boolean;
51
59
  +enableViewRecyclingForView?: () => boolean;
52
- +excludeYogaFromRawProps?: () => boolean;
53
- +fixDifferentiatorEmittingUpdatesWithWrongParentTag?: () => boolean;
54
60
  +fixMappingOfEventPrioritiesBetweenFabricAndReact?: () => boolean;
55
- +fixMountingCoordinatorReportedPendingTransactionsOnAndroid?: () => boolean;
56
61
  +fuseboxEnabledRelease?: () => boolean;
57
62
  +fuseboxNetworkInspectionEnabled?: () => boolean;
58
- +lazyAnimationCallbacks?: () => boolean;
59
- +removeTurboModuleManagerDelegateMutex?: () => boolean;
60
- +throwExceptionInsteadOfDeadlockOnTurboModuleSetupDuringSyncRenderIOS?: () => boolean;
63
+ +incorporateMaxLinesDuringAndroidLayout?: () => boolean;
61
64
  +traceTurboModulePromiseRejectionsOnAndroid?: () => boolean;
65
+ +updateRuntimeShadowNodeReferencesOnCommit?: () => boolean;
62
66
  +useAlwaysAvailableJSErrorHandling?: () => boolean;
63
- +useEditTextStockAndroidFocusBehavior?: () => boolean;
64
67
  +useFabricInterop?: () => boolean;
65
68
  +useNativeViewConfigsInBridgelessMode?: () => boolean;
66
69
  +useOptimizedEventBatchingOnAndroid?: () => boolean;
67
70
  +useRawPropsJsiValue?: () => boolean;
71
+ +useShadowNodeStateOnClone?: () => boolean;
68
72
  +useTurboModuleInterop?: () => boolean;
69
73
  +useTurboModules?: () => boolean;
70
74
  }
@@ -9,16 +9,16 @@
9
9
  */
10
10
 
11
11
  import type {ExtendedError} from '../../../../Libraries/Core/ExtendedError';
12
- import type {Component as ReactComponent} from 'react';
13
12
 
14
13
  import ExceptionsManager, {
15
14
  SyntheticError,
16
15
  } from '../../../../Libraries/Core/ExceptionsManager';
16
+ import * as React from 'react';
17
17
 
18
18
  type ErrorInfo = {
19
19
  +componentStack?: ?string,
20
20
  // $FlowFixMe[unclear-type] unknown props and state.
21
- +errorBoundary?: ?ReactComponent<any, any>,
21
+ +errorBoundary?: ?React.Component<any, any>,
22
22
  };
23
23
 
24
24
  function getExtendedError(
@@ -13,7 +13,7 @@ import type {TurboModule} from '../../../../Libraries/TurboModule/RCTExport';
13
13
  import shouldUseTurboAnimatedModule from '../../../../Libraries/Animated/shouldUseTurboAnimatedModule';
14
14
  import * as TurboModuleRegistry from '../../../../Libraries/TurboModule/TurboModuleRegistry';
15
15
 
16
- type EndResult = {finished: boolean, value?: number, ...};
16
+ type EndResult = {finished: boolean, value?: number, offset?: number, ...};
17
17
  type EndCallback = (result: EndResult) => void;
18
18
  type SaveValueCallback = (value: number) => void;
19
19
 
@@ -13,7 +13,7 @@ import type {TurboModule} from '../../../../Libraries/TurboModule/RCTExport';
13
13
  import shouldUseTurboAnimatedModule from '../../../../Libraries/Animated/shouldUseTurboAnimatedModule';
14
14
  import * as TurboModuleRegistry from '../../../../Libraries/TurboModule/TurboModuleRegistry';
15
15
 
16
- type EndResult = {finished: boolean, value?: number, ...};
16
+ type EndResult = {finished: boolean, value?: number, offset?: number, ...};
17
17
  type EndCallback = (result: EndResult) => void;
18
18
  type SaveValueCallback = (value: number) => void;
19
19
 
@@ -59,6 +59,9 @@ export interface Spec extends TurboModule {
59
59
  +voidFuncAssert?: () => void;
60
60
  +getObjectAssert?: (arg: Object) => Object;
61
61
  +promiseAssert?: () => Promise<void>;
62
+
63
+ // Android-only
64
+ +getImageUrl?: () => Promise<string | null>;
62
65
  }
63
66
 
64
67
  export default (TurboModuleRegistry.getEnforcing<Spec>(
@@ -4,19 +4,26 @@
4
4
  * This source code is licensed under the MIT license found in the
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  *
7
- * @flow strict
8
7
  * @format
9
8
  */
10
9
 
10
+ import type {
11
+ ImageStyle,
12
+ TextStyle,
13
+ ViewStyle,
14
+ } from '../../../Libraries/StyleSheet/StyleSheet';
15
+ import type {StyleProp} from '../../../Libraries/StyleSheet/StyleSheetTypes';
16
+
11
17
  /**
12
18
  * Combines two styles such that `style2` will override any styles in `style1`.
13
19
  * If either style is null or undefined, the other one is returned without
14
20
  * allocating an array, saving allocations and enabling memoization.
15
21
  */
16
- export default function composeStyles<T1, T2>(
17
- style1: ?T1,
18
- style2: ?T2,
19
- ): ?(T1 | T2 | $ReadOnlyArray<T1 | T2>) {
22
+ export default function composeStyles<
23
+ T: ViewStyle | ImageStyle | TextStyle,
24
+ U: T,
25
+ V: T,
26
+ >(style1: ?StyleProp<U>, style2: ?StyleProp<V>): ?StyleProp<T> {
20
27
  if (style1 == null) {
21
28
  return style2;
22
29
  }
@@ -11,6 +11,6 @@
11
11
  import type {HostInstance} from './HostInstance';
12
12
 
13
13
  export type HostComponent<Config: {...}> = component(
14
- ref: React.RefSetter<HostInstance>,
14
+ ref?: React.RefSetter<HostInstance>,
15
15
  ...Config
16
16
  );
@@ -32,19 +32,85 @@ export type MeasureLayoutOnSuccessCallback = (
32
32
  ) => void;
33
33
 
34
34
  /**
35
- * Current usages should migrate to this definition
35
+ * NativeMethods provides methods to access the underlying native component directly.
36
+ * This can be useful in cases when you want to focus a view or measure its on-screen dimensions,
37
+ * for example.
38
+ * The methods described here are available on most of the default components provided by React Native.
39
+ * Note, however, that they are not available on composite components that aren't directly backed by a
40
+ * native view. This will generally include most components that you define in your own app.
41
+ * For more information, see [Direct Manipulation](https://reactnative.dev/docs/the-new-architecture/direct-manipulation-new-architecture).
42
+ * @see https://github.com/facebook/react-native/blob/master/Libraries/Renderer/shims/ReactNativeTypes.js#L87
36
43
  */
37
44
  export interface LegacyHostInstanceMethods {
45
+ /**
46
+ * Removes focus from an input or view. This is the opposite of `focus()`.
47
+ */
38
48
  blur(): void;
49
+ /**
50
+ * Requests focus for the given input or view. The exact behavior triggered
51
+ * will depend on the platform and type of view.
52
+ */
39
53
  focus(): void;
54
+ /**
55
+ * Determines the location on screen, width, and height of the given view and
56
+ * returns the values via an async callback. If successful, the callback will
57
+ * be called with the following arguments:
58
+ *
59
+ * - x
60
+ * - y
61
+ * - width
62
+ * - height
63
+ * - pageX
64
+ * - pageY
65
+ *
66
+ * Note that these measurements are not available until after the rendering
67
+ * has been completed in native. If you need the measurements as soon as
68
+ * possible, consider using the [`onLayout`
69
+ * prop](docs/view.html#onlayout) instead.
70
+ */
40
71
  measure(callback: MeasureOnSuccessCallback): void;
72
+ /**
73
+ * Determines the location of the given view in the window and returns the
74
+ * values via an async callback. If the React root view is embedded in
75
+ * another native view, this will give you the absolute coordinates. If
76
+ * successful, the callback will be called with the following
77
+ * arguments:
78
+ *
79
+ * - x
80
+ * - y
81
+ * - width
82
+ * - height
83
+ *
84
+ * Note that these measurements are not available until after the rendering
85
+ * has been completed in native.
86
+ */
41
87
  measureInWindow(callback: MeasureInWindowOnSuccessCallback): void;
88
+ /**
89
+ * Like [`measure()`](#measure), but measures the view relative an ancestor,
90
+ * specified as `relativeToNativeComponentRef`. This means that the returned x, y
91
+ * are relative to the origin x, y of the ancestor view.
92
+ * _Can also be called with a relativeNativeNodeHandle but is deprecated._
93
+ */
42
94
  measureLayout(
43
95
  relativeToNativeNode: number | HostInstance,
44
96
  onSuccess: MeasureLayoutOnSuccessCallback,
45
97
  onFail?: () => void,
46
98
  ): void;
99
+ /**
100
+ * This function sends props straight to native. They will not participate in
101
+ * future diff process - this means that if you do not include them in the
102
+ * next render, they will remain active (see [Direct
103
+ * Manipulation](https://reactnative.dev/docs/the-new-architecture/direct-manipulation-new-architecture)).
104
+ */
47
105
  setNativeProps(nativeProps: {...}): void;
48
106
  }
49
107
 
50
108
  export type HostInstance = LegacyHostInstanceMethods;
109
+
110
+ /** @deprecated Use HostInstance instead */
111
+ export type NativeMethods = LegacyHostInstanceMethods;
112
+
113
+ /**
114
+ * @deprecated Use HostInstance instead.
115
+ */
116
+ export type NativeMethodsMixin = LegacyHostInstanceMethods;
@@ -17,10 +17,10 @@ import type {
17
17
  } from '../../../../../Libraries/Renderer/shims/ReactNativeTypes';
18
18
  import type {
19
19
  HostInstance,
20
- LegacyHostInstanceMethods,
21
20
  MeasureInWindowOnSuccessCallback,
22
21
  MeasureLayoutOnSuccessCallback,
23
22
  MeasureOnSuccessCallback,
23
+ NativeMethods,
24
24
  } from '../../../types/HostInstance';
25
25
  import type {InstanceHandle} from './internals/NodeInternals';
26
26
  import type ReactNativeDocument from './ReactNativeDocument';
@@ -60,10 +60,7 @@ const noop = () => {};
60
60
  // was slower than this method because the engine has to create an object than
61
61
  // we then discard to create a new one.
62
62
 
63
- class ReactNativeElement
64
- extends ReadOnlyElement
65
- implements LegacyHostInstanceMethods
66
- {
63
+ class ReactNativeElement extends ReadOnlyElement implements NativeMethods {
67
64
  // These need to be accessible from `ReactFabricPublicInstanceUtils`.
68
65
  __nativeTag: number;
69
66
  __internalInstanceHandle: InstanceHandle;