@office-iss/react-native-win32 0.0.0-canary.298 → 0.0.0-canary.299

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 (220) hide show
  1. package/.flowconfig +5 -3
  2. package/CHANGELOG.json +28 -1
  3. package/CHANGELOG.md +16 -6
  4. package/IntegrationTests/IntegrationTestsApp.js +1 -0
  5. package/IntegrationTests/LoggingTestModule.js +16 -20
  6. package/IntegrationTests/TimersTest.js +1 -0
  7. package/IntegrationTests/WebSocketTest.js +1 -0
  8. package/Libraries/ActionSheetIOS/NativeActionSheetManager.js +1 -0
  9. package/Libraries/Alert/Alert.js +2 -2
  10. package/Libraries/Alert/NativeAlertManager.js +1 -0
  11. package/Libraries/Alert/RCTAlertManager.android.js +19 -13
  12. package/Libraries/Alert/RCTAlertManager.ios.js +9 -11
  13. package/Libraries/Alert/RCTAlertManager.js +1 -3
  14. package/Libraries/Alert/RCTAlertManager.js.flow +4 -6
  15. package/Libraries/Animated/AnimatedEvent.js +4 -3
  16. package/Libraries/Animated/AnimatedExports.js.flow +5 -0
  17. package/Libraries/Animated/AnimatedImplementation.js +44 -44
  18. package/Libraries/Animated/AnimatedMock.js +2 -2
  19. package/Libraries/Animated/NativeAnimatedModule.js +1 -0
  20. package/Libraries/Animated/NativeAnimatedTurboModule.js +1 -0
  21. package/Libraries/Animated/animations/Animation.js +6 -1
  22. package/Libraries/Animated/components/AnimatedScrollView.js +6 -5
  23. package/Libraries/Animated/components/AnimatedText.js +2 -5
  24. package/Libraries/Animated/components/AnimatedView.js +2 -1
  25. package/Libraries/Animated/createAnimatedComponent.js +2 -4
  26. package/Libraries/Animated/nodes/AnimatedProps.js +2 -7
  27. package/Libraries/AppState/NativeAppState.js +1 -0
  28. package/Libraries/Blob/NativeBlobModule.js +1 -0
  29. package/Libraries/Blob/NativeFileReaderModule.js +1 -0
  30. package/Libraries/Components/AccessibilityInfo/NativeAccessibilityInfo.js +1 -2
  31. package/Libraries/Components/AccessibilityInfo/NativeAccessibilityInfoWin32.js +1 -2
  32. package/Libraries/Components/AccessibilityInfo/NativeAccessibilityManager.js +1 -2
  33. package/Libraries/Components/ActivityIndicator/ActivityIndicatorViewNativeComponent.js +1 -2
  34. package/Libraries/Components/Button.js +7 -4
  35. package/Libraries/Components/Button.win32.js +7 -4
  36. package/Libraries/Components/Clipboard/NativeClipboard.js +1 -2
  37. package/Libraries/Components/DrawerAndroid/AndroidDrawerLayoutNativeComponent.js +1 -2
  38. package/Libraries/Components/Keyboard/NativeKeyboardObserver.js +1 -2
  39. package/Libraries/Components/Pressable/Pressable.js +8 -2
  40. package/Libraries/Components/Pressable/Pressable.win32.js +8 -8
  41. package/Libraries/Components/ProgressBarAndroid/ProgressBarAndroidNativeComponent.js +1 -2
  42. package/Libraries/Components/RefreshControl/AndroidSwipeRefreshLayoutNativeComponent.js +1 -2
  43. package/Libraries/Components/RefreshControl/PullToRefreshViewNativeComponent.js +1 -0
  44. package/Libraries/Components/SafeAreaView/RCTSafeAreaViewNativeComponent.js +1 -2
  45. package/Libraries/Components/SafeAreaView/SafeAreaView.d.ts +9 -0
  46. package/Libraries/Components/SafeAreaView/SafeAreaView.js +3 -2
  47. package/Libraries/Components/SafeAreaView/SafeAreaView.win32.js +3 -2
  48. package/Libraries/Components/ScrollView/AndroidHorizontalScrollContentViewNativeComponent.js +1 -2
  49. package/Libraries/Components/ScrollView/ScrollView.d.ts +10 -1
  50. package/Libraries/Components/ScrollView/ScrollView.js +3 -1
  51. package/Libraries/Components/Sound/NativeSoundManager.js +1 -2
  52. package/Libraries/Components/StatusBar/NativeStatusBarManagerAndroid.js +1 -2
  53. package/Libraries/Components/StatusBar/NativeStatusBarManagerIOS.js +1 -2
  54. package/Libraries/Components/StatusBar/StatusBar.d.ts +4 -0
  55. package/Libraries/Components/StatusBar/StatusBar.js +5 -0
  56. package/Libraries/Components/Switch/AndroidSwitchNativeComponent.js +1 -2
  57. package/Libraries/Components/Switch/Switch.js +2 -1
  58. package/Libraries/Components/Switch/SwitchNativeComponent.js +1 -2
  59. package/Libraries/Components/TextInput/AndroidTextInputNativeComponent.js +8 -7
  60. package/Libraries/Components/TextInput/RCTInputAccessoryViewNativeComponent.js +1 -2
  61. package/Libraries/Components/TextInput/TextInput.flow.js +1 -1
  62. package/Libraries/Components/TextInput/TextInput.js +2 -4
  63. package/Libraries/Components/TextInput/TextInput.win32.js +28 -3
  64. package/Libraries/Components/ToastAndroid/NativeToastAndroid.js +1 -2
  65. package/Libraries/Components/Touchable/Touchable.js +7 -3
  66. package/Libraries/Components/Touchable/Touchable.win32.js +7 -3
  67. package/Libraries/Components/Touchable/TouchableHighlight.js +5 -1
  68. package/Libraries/Components/Touchable/TouchableNativeFeedback.js +3 -2
  69. package/Libraries/Components/Touchable/TouchableNativeFeedback.win32.js +3 -2
  70. package/Libraries/Components/Touchable/TouchableOpacity.d.ts +1 -0
  71. package/Libraries/Components/Touchable/TouchableOpacity.js +3 -2
  72. package/Libraries/Components/UnimplementedViews/UnimplementedNativeViewNativeComponent.js +1 -2
  73. package/Libraries/Components/View/ReactNativeStyleAttributes.js +6 -15
  74. package/Libraries/Components/View/View.js +17 -18
  75. package/Libraries/Components/View/View.win32.js +16 -2
  76. package/Libraries/Components/View/ViewAccessibility.js +0 -7
  77. package/Libraries/Components/View/ViewAccessibility.win32.js +0 -7
  78. package/Libraries/Components/View/ViewPropTypes.d.ts +4 -0
  79. package/Libraries/Components/View/ViewPropTypes.js +8 -0
  80. package/Libraries/Components/View/ViewPropTypes.win32.js +8 -0
  81. package/Libraries/Core/ExceptionsManager.js +28 -15
  82. package/Libraries/Core/NativeExceptionsManager.js +1 -0
  83. package/Libraries/Core/ReactNativeVersion.js +1 -1
  84. package/Libraries/Core/SegmentFetcher/NativeSegmentFetcher.js +1 -0
  85. package/Libraries/Core/Timers/NativeTiming.js +1 -0
  86. package/Libraries/Core/checkNativeVersion.js +1 -0
  87. package/Libraries/Core/setUpReactDevTools.js +21 -4
  88. package/Libraries/Debugging/DebuggingOverlayNativeComponent.js +1 -0
  89. package/Libraries/EventEmitter/NativeEventEmitter.js +3 -3
  90. package/Libraries/Image/Image.android.js +3 -3
  91. package/Libraries/Image/ImageSource.d.ts +5 -0
  92. package/Libraries/Image/ImageViewNativeComponent.js +3 -3
  93. package/Libraries/Image/NativeImageEditor.js +1 -0
  94. package/Libraries/Image/NativeImageLoaderAndroid.js +1 -0
  95. package/Libraries/Image/NativeImageLoaderIOS.js +1 -0
  96. package/Libraries/Image/NativeImageLoaderWin32.js +1 -0
  97. package/Libraries/Image/NativeImageStoreAndroid.js +1 -0
  98. package/Libraries/Image/NativeImageStoreIOS.js +1 -0
  99. package/Libraries/Image/RelativeImageStub.js +1 -1
  100. package/Libraries/Image/TextInlineImageNativeComponent.js +3 -3
  101. package/Libraries/Interaction/InteractionManager.js +6 -1
  102. package/Libraries/Interaction/NativeFrameRateLogger.js +1 -0
  103. package/Libraries/Interaction/TaskQueue.js +14 -0
  104. package/Libraries/LayoutAnimation/LayoutAnimation.js +12 -8
  105. package/Libraries/Linking/NativeIntentAndroid.js +1 -0
  106. package/Libraries/Linking/NativeLinkingManager.js +1 -0
  107. package/Libraries/Lists/FlatList.js +5 -6
  108. package/Libraries/Lists/SectionList.js +4 -4
  109. package/Libraries/Lists/VirtualizedList.js +3 -2
  110. package/Libraries/LogBox/Data/LogBoxData.js +7 -4
  111. package/Libraries/LogBox/LogBox.js +72 -101
  112. package/Libraries/Modal/Modal.d.ts +8 -2
  113. package/Libraries/Modal/Modal.js +19 -2
  114. package/Libraries/Modal/NativeModalManager.js +1 -0
  115. package/Libraries/Modal/RCTModalHostViewNativeComponent.js +1 -0
  116. package/Libraries/NativeComponent/BaseViewConfig.android.js +6 -15
  117. package/Libraries/NativeComponent/BaseViewConfig.ios.js +6 -15
  118. package/Libraries/NativeComponent/BaseViewConfig.win32.js +6 -15
  119. package/Libraries/NativeModules/specs/NativeDevMenu.js +1 -0
  120. package/Libraries/NativeModules/specs/NativeDevSettings.js +1 -0
  121. package/Libraries/NativeModules/specs/NativeDeviceEventManager.js +1 -0
  122. package/Libraries/NativeModules/specs/NativeDialogManagerAndroid.js +1 -0
  123. package/Libraries/NativeModules/specs/NativeLogBox.js +1 -0
  124. package/Libraries/NativeModules/specs/NativeRedBox.js +1 -0
  125. package/Libraries/NativeModules/specs/NativeSourceCode.js +1 -0
  126. package/Libraries/Network/NativeNetworkingAndroid.js +1 -0
  127. package/Libraries/Network/NativeNetworkingIOS.js +1 -0
  128. package/Libraries/Network/XMLHttpRequest.js +2 -0
  129. package/Libraries/PermissionsAndroid/NativePermissionsAndroid.js +1 -0
  130. package/Libraries/PermissionsAndroid/PermissionsAndroid.js +3 -2
  131. package/Libraries/PushNotificationIOS/NativePushNotificationManagerIOS.js +1 -0
  132. package/Libraries/ReactNative/AppRegistry.flow.js +2 -2
  133. package/Libraries/ReactNative/AppRegistryImpl.js +0 -10
  134. package/Libraries/ReactNative/BridgelessUIManager.js +1 -1
  135. package/Libraries/ReactNative/NativeHeadlessJsTaskSupport.js +1 -0
  136. package/Libraries/ReactNative/NativeI18nManager.js +1 -0
  137. package/Libraries/ReactNative/NativeUIManager.js +1 -0
  138. package/Libraries/ReactNative/ReactFabricPublicInstance/ReactNativeAttributePayload.js +80 -61
  139. package/Libraries/ReactPrivate/ReactNativePrivateInterface.js +1 -1
  140. package/Libraries/ReactPrivate/ReactNativePrivateInterface.js.flow +2 -2
  141. package/Libraries/Renderer/implementations/ReactFabric-dev.js +3 -1
  142. package/Libraries/Renderer/implementations/ReactFabric-prod.js +3 -1
  143. package/Libraries/Renderer/implementations/ReactFabric-profiling.js +3 -1
  144. package/Libraries/Renderer/shims/ReactNativeTypes.js +3 -12
  145. package/Libraries/Renderer/shims/ReactNativeTypes.win32.js +3 -12
  146. package/Libraries/Settings/NativeSettingsManager.js +1 -0
  147. package/Libraries/Share/NativeShareModule.js +1 -0
  148. package/Libraries/StyleSheet/StyleSheet.js +1 -0
  149. package/Libraries/StyleSheet/processAspectRatio.js +2 -0
  150. package/Libraries/Text/Text.js +4 -6
  151. package/Libraries/Text/TextAncestor.js +3 -10
  152. package/Libraries/Text/TextAncestorContext.js +23 -0
  153. package/Libraries/Text/TextProps.js +2 -2
  154. package/Libraries/Text/TextProps.win32.js +2 -2
  155. package/Libraries/TurboModule/samples/NativeSampleTurboModule.js +1 -0
  156. package/Libraries/Types/CodegenTypesNamespace.js +1 -0
  157. package/Libraries/Utilities/HMRClient.js +12 -2
  158. package/Libraries/Utilities/NativeAppearance.js +1 -0
  159. package/Libraries/Utilities/NativeDevLoadingView.js +1 -0
  160. package/Libraries/Utilities/NativeDeviceInfo.js +1 -2
  161. package/Libraries/Utilities/NativePlatformConstantsAndroid.js +1 -0
  162. package/Libraries/Utilities/NativePlatformConstantsIOS.js +1 -0
  163. package/Libraries/Utilities/NativePlatformConstantsWin.js +1 -0
  164. package/Libraries/Utilities/Platform.android.js +1 -4
  165. package/Libraries/Utilities/Platform.ios.js +1 -4
  166. package/Libraries/Utilities/Platform.js.flow +2 -2
  167. package/Libraries/Utilities/Platform.win32.js +1 -4
  168. package/Libraries/Utilities/PlatformTypes.js +1 -1
  169. package/Libraries/Utilities/codegenNativeCommands.js +4 -2
  170. package/Libraries/Utilities/codegenNativeComponent.js +3 -3
  171. package/Libraries/Utilities/createPerformanceLogger.js +32 -0
  172. package/Libraries/Vibration/NativeVibration.js +1 -0
  173. package/Libraries/WebSocket/NativeWebSocketModule.js +1 -0
  174. package/Libraries/vendor/emitter/EventEmitter.js +6 -6
  175. package/index.js +21 -0
  176. package/index.win32.js +12 -1
  177. package/jest/setup.js +1 -0
  178. package/overrides.json +25 -25
  179. package/package.json +11 -11
  180. package/src/private/animated/createAnimatedPropsHook.js +4 -1
  181. package/src/private/animated/createAnimatedPropsMemoHook.js +2 -2
  182. package/src/private/components/virtualview/VirtualView.js +145 -0
  183. package/src/private/components/virtualview/VirtualViewNativeComponent.js +90 -0
  184. package/src/private/featureflags/ReactNativeFeatureFlags.js +43 -23
  185. package/src/private/featureflags/specs/NativeReactNativeFeatureFlags.js +9 -5
  186. package/src/private/setup/setUpPerformanceObserver.js +7 -0
  187. package/src/private/specs_DEPRECATED/components/ActivityIndicatorViewNativeComponent.js +7 -4
  188. package/src/private/specs_DEPRECATED/components/AndroidDrawerLayoutNativeComponent.js +3 -3
  189. package/src/private/specs_DEPRECATED/components/AndroidHorizontalScrollContentViewNativeComponent.js +3 -3
  190. package/src/private/specs_DEPRECATED/components/AndroidSwipeRefreshLayoutNativeComponent.js +3 -3
  191. package/src/private/specs_DEPRECATED/components/AndroidSwitchNativeComponent.js +10 -7
  192. package/src/private/specs_DEPRECATED/components/DebuggingOverlayNativeComponent.js +5 -4
  193. package/src/private/specs_DEPRECATED/components/ProgressBarAndroidNativeComponent.js +7 -4
  194. package/src/private/specs_DEPRECATED/components/PullToRefreshViewNativeComponent.js +9 -6
  195. package/src/private/specs_DEPRECATED/components/RCTInputAccessoryViewNativeComponent.js +9 -6
  196. package/src/private/specs_DEPRECATED/components/RCTModalHostViewNativeComponent.js +14 -5
  197. package/src/private/specs_DEPRECATED/components/RCTSafeAreaViewNativeComponent.js +8 -5
  198. package/src/private/specs_DEPRECATED/components/SwitchNativeComponent.js +5 -5
  199. package/src/private/specs_DEPRECATED/components/UnimplementedNativeViewNativeComponent.js +3 -3
  200. package/src/private/specs_DEPRECATED/modules/NativeDeviceInfo.js +1 -0
  201. package/src/private/specs_DEPRECATED/modules/NativeUIManager.js +9 -6
  202. package/src/private/styles/composeStyles.js +5 -12
  203. package/src/private/webapis/errors/DOMException.js +1 -1
  204. package/src/private/webapis/idlecallbacks/specs/NativeIdleCallbacks.js +4 -2
  205. package/src/private/webapis/intersectionobserver/IntersectionObserver.js +12 -7
  206. package/src/private/webapis/intersectionobserver/internals/IntersectionObserverManager.js +13 -0
  207. package/src/private/webapis/intersectionobserver/specs/NativeIntersectionObserver.js +2 -1
  208. package/src/private/webapis/performance/Performance.js +164 -61
  209. package/src/private/webapis/performance/PerformanceEntry.js +20 -16
  210. package/src/private/webapis/performance/PerformanceObserver.js +31 -27
  211. package/src/private/webapis/performance/ResourceTiming.js +108 -0
  212. package/src/private/webapis/performance/UserTiming.js +60 -8
  213. package/src/private/webapis/performance/internals/RawPerformanceEntry.js +47 -32
  214. package/src/private/webapis/performance/specs/NativePerformance.js +13 -1
  215. package/src-win/Libraries/Components/View/ViewPropTypes.d.ts +4 -0
  216. package/Libraries/BugReporting/BugReporting.js +0 -140
  217. package/Libraries/BugReporting/NativeBugReporting.js +0 -13
  218. package/Libraries/BugReporting/dumpReactTree.js +0 -151
  219. package/Libraries/BugReporting/getReactData.js +0 -187
  220. package/src/private/specs_DEPRECATED/modules/NativeBugReporting.js +0 -20
@@ -15,7 +15,9 @@ import type {
15
15
  } from '../createAnimatedComponent';
16
16
 
17
17
  import RefreshControl from '../../Components/RefreshControl/RefreshControl';
18
- import ScrollView from '../../Components/ScrollView/ScrollView';
18
+ import ScrollView, {
19
+ type ScrollViewProps,
20
+ } from '../../Components/ScrollView/ScrollView';
19
21
  import flattenStyle from '../../StyleSheet/flattenStyle';
20
22
  import splitLayoutProps from '../../StyleSheet/splitLayoutProps';
21
23
  import StyleSheet from '../../StyleSheet/StyleSheet';
@@ -26,21 +28,20 @@ import useAnimatedProps from '../useAnimatedProps';
26
28
  import * as React from 'react';
27
29
  import {cloneElement, useMemo} from 'react';
28
30
 
29
- type AnimatedScrollViewProps = React.ElementConfig<typeof ScrollView>;
30
31
  type AnimatedScrollViewInstance = React.ElementRef<typeof ScrollView>;
31
32
 
32
33
  /**
33
34
  * @see https://github.com/facebook/react-native/commit/b8c8562
34
35
  */
35
36
  const AnimatedScrollView: AnimatedComponentType<
36
- AnimatedScrollViewProps,
37
+ ScrollViewProps,
37
38
  AnimatedScrollViewInstance,
38
39
  > = function AnimatedScrollViewWithOrWithoutInvertedRefreshControl({
39
40
  ref: forwardedRef,
40
41
  ...props
41
42
  }: {
42
43
  ref?: React.RefSetter<AnimatedScrollViewInstance>,
43
- ...AnimatedProps<AnimatedScrollViewProps>,
44
+ ...AnimatedProps<ScrollViewProps>,
44
45
  }) {
45
46
  // (Android only) When a ScrollView has a RefreshControl and
46
47
  // any `style` property set with an Animated.Value, the CSS
@@ -111,7 +112,7 @@ const AnimatedScrollViewWithInvertedRefreshControl =
111
112
 
112
113
  // Handle animated props on `NativeDirectionalScrollView`.
113
114
  const [scrollViewAnimatedProps, scrollViewRef] = useAnimatedProps<
114
- AnimatedScrollViewProps,
115
+ ScrollViewProps,
115
116
  AnimatedScrollViewInstance,
116
117
  >(intermediatePropsForScrollView);
117
118
  const ref = useMergeRefs<AnimatedScrollViewInstance>(
@@ -10,13 +10,10 @@
10
10
 
11
11
  import type {AnimatedComponentType} from '../createAnimatedComponent';
12
12
 
13
- import Text from '../../Text/Text';
13
+ import Text, {type TextProps} from '../../Text/Text';
14
14
  import createAnimatedComponent from '../createAnimatedComponent';
15
15
  import * as React from 'react';
16
16
 
17
17
  export default (createAnimatedComponent(
18
18
  (Text: $FlowFixMe),
19
- ): AnimatedComponentType<
20
- React.ElementConfig<typeof Text>,
21
- React.ElementRef<typeof Text>,
22
- >);
19
+ ): AnimatedComponentType<TextProps, React.ElementRef<typeof Text>>);
@@ -8,6 +8,7 @@
8
8
  * @format
9
9
  */
10
10
 
11
+ import type {ViewProps} from '../../Components/View/ViewPropTypes';
11
12
  import type {AnimatedComponentType} from '../createAnimatedComponent';
12
13
 
13
14
  import View from '../../Components/View/View';
@@ -15,6 +16,6 @@ import createAnimatedComponent from '../createAnimatedComponent';
15
16
  import * as React from 'react';
16
17
 
17
18
  export default (createAnimatedComponent(View): AnimatedComponentType<
18
- React.ElementConfig<typeof View>,
19
+ ViewProps,
19
20
  React.ElementRef<typeof View>,
20
21
  >);
@@ -21,7 +21,7 @@ import type AnimatedValue from './nodes/AnimatedValue';
21
21
 
22
22
  import createAnimatedPropsHook from '../../src/private/animated/createAnimatedPropsHook';
23
23
  import composeStyles from '../../src/private/styles/composeStyles';
24
- import View from '../Components/View/View';
24
+ import {type ViewProps} from '../Components/View/ViewPropTypes';
25
25
  import useMergeRefs from '../Utilities/useMergeRefs';
26
26
  import * as React from 'react';
27
27
  import {useMemo} from 'react';
@@ -60,9 +60,7 @@ type NonAnimatedProps =
60
60
  | 'disabled'
61
61
  | 'accessibilityLabel';
62
62
  type PassThroughProps = $ReadOnly<{
63
- passthroughAnimatedPropExplicitValues?: React.ElementConfig<
64
- typeof View,
65
- > | null,
63
+ passthroughAnimatedPropExplicitValues?: ViewProps | null,
66
64
  }>;
67
65
 
68
66
  export type AnimatedProps<Props: {...}> = {
@@ -13,7 +13,6 @@ import type {AnimatedNodeConfig} from './AnimatedNode';
13
13
  import type {AnimatedStyleAllowlist} from './AnimatedStyle';
14
14
 
15
15
  import NativeAnimatedHelper from '../../../src/private/animated/NativeAnimatedHelper';
16
- import * as ReactNativeFeatureFlags from '../../../src/private/featureflags/ReactNativeFeatureFlags';
17
16
  import {findNodeHandle} from '../../ReactNative/RendererProxy';
18
17
  import flattenStyle from '../../StyleSheet/flattenStyle';
19
18
  import {AnimatedEvent} from '../AnimatedEvent';
@@ -58,9 +57,7 @@ function createAnimatedProps(
58
57
  // we propagate the flattened `style` object to the `props` object.
59
58
  const flatStyle = flattenStyle(value as $FlowFixMe);
60
59
  node = AnimatedStyle.from(flatStyle, allowlist?.style, value);
61
- if (ReactNativeFeatureFlags.alwaysFlattenAnimatedStyles()) {
62
- staticValue = flatStyle;
63
- }
60
+ staticValue = flatStyle;
64
61
  }
65
62
  } else if (value instanceof AnimatedNode) {
66
63
  node = value;
@@ -164,9 +161,7 @@ export default class AnimatedProps extends AnimatedNode {
164
161
  maybeNode.__replaceAnimatedNodeWithValues(mutableStyle);
165
162
  props[key] = maybeNode.__getValueForStyle(mutableStyle);
166
163
  } else {
167
- if (ReactNativeFeatureFlags.alwaysFlattenAnimatedStyles()) {
168
- props[key] = flatStaticStyle;
169
- }
164
+ props[key] = flatStaticStyle;
170
165
  }
171
166
  } else if (maybeNode instanceof AnimatedNode) {
172
167
  props[key] = maybeNode.__getValue();
@@ -10,4 +10,5 @@
10
10
 
11
11
  export * from '../../src/private/specs_DEPRECATED/modules/NativeAppState';
12
12
  import NativeAppState from '../../src/private/specs_DEPRECATED/modules/NativeAppState';
13
+
13
14
  export default NativeAppState;
@@ -10,4 +10,5 @@
10
10
 
11
11
  export * from '../../src/private/specs_DEPRECATED/modules/NativeBlobModule';
12
12
  import NativeBlobModule from '../../src/private/specs_DEPRECATED/modules/NativeBlobModule';
13
+
13
14
  export default NativeBlobModule;
@@ -10,4 +10,5 @@
10
10
 
11
11
  export * from '../../src/private/specs_DEPRECATED/modules/NativeFileReaderModule';
12
12
  import NativeFileReaderModule from '../../src/private/specs_DEPRECATED/modules/NativeFileReaderModule';
13
+
13
14
  export default NativeFileReaderModule;
@@ -9,5 +9,4 @@
9
9
  */
10
10
 
11
11
  export * from '../../../src/private/specs_DEPRECATED/modules/NativeAccessibilityInfo';
12
- import NativeAccessibilityInfo from '../../../src/private/specs_DEPRECATED/modules/NativeAccessibilityInfo';
13
- export default NativeAccessibilityInfo;
12
+ export {default} from '../../../src/private/specs_DEPRECATED/modules/NativeAccessibilityInfo';
@@ -7,5 +7,4 @@
7
7
  */
8
8
 
9
9
  export * from '../../../src/private/specs_DEPRECATED/modules/NativeAccessibilityInfoWin32';
10
- import NativeAccessibilityInfoWin32 from '../../../src/private/specs_DEPRECATED/modules/NativeAccessibilityInfoWin32';
11
- export default NativeAccessibilityInfoWin32;
10
+ export {default} from '../../../src/private/specs_DEPRECATED/modules/NativeAccessibilityInfoWin32';
@@ -9,5 +9,4 @@
9
9
  */
10
10
 
11
11
  export * from '../../../src/private/specs_DEPRECATED/modules/NativeAccessibilityManager';
12
- import NativeAccessibilityManager from '../../../src/private/specs_DEPRECATED/modules/NativeAccessibilityManager';
13
- export default NativeAccessibilityManager;
12
+ export {default} from '../../../src/private/specs_DEPRECATED/modules/NativeAccessibilityManager';
@@ -9,5 +9,4 @@
9
9
  */
10
10
 
11
11
  export * from '../../../src/private/specs_DEPRECATED/components/ActivityIndicatorViewNativeComponent';
12
- import ActivityIndicatorViewNativeComponent from '../../../src/private/specs_DEPRECATED/components/ActivityIndicatorViewNativeComponent';
13
- export default ActivityIndicatorViewNativeComponent;
12
+ export {default} from '../../../src/private/specs_DEPRECATED/components/ActivityIndicatorViewNativeComponent';
@@ -63,6 +63,7 @@ export type ButtonProps = $ReadOnly<{
63
63
  @platform tv
64
64
 
65
65
  @default false
66
+ @deprecated Use `focusable` instead
66
67
  */
67
68
  hasTVPreferredFocus?: ?boolean,
68
69
 
@@ -280,10 +281,12 @@ export type ButtonProps = $ReadOnly<{
280
281
  ```
281
282
  */
282
283
 
283
- const Touchable: typeof TouchableNativeFeedback | typeof TouchableOpacity =
284
+ const NativeTouchable:
285
+ | typeof TouchableNativeFeedback
286
+ | typeof TouchableOpacity =
284
287
  Platform.OS === 'android' ? TouchableNativeFeedback : TouchableOpacity;
285
288
 
286
- type ButtonRef = React.ElementRef<typeof Touchable>;
289
+ type ButtonRef = React.ElementRef<typeof NativeTouchable>;
287
290
 
288
291
  const Button: component(
289
292
  ref?: React.RefSetter<ButtonRef>,
@@ -361,7 +364,7 @@ const Button: component(
361
364
  : importantForAccessibility;
362
365
 
363
366
  return (
364
- <Touchable
367
+ <NativeTouchable
365
368
  accessible={accessible}
366
369
  accessibilityActions={accessibilityActions}
367
370
  onAccessibilityAction={onAccessibilityAction}
@@ -390,7 +393,7 @@ const Button: component(
390
393
  {formattedTitle}
391
394
  </Text>
392
395
  </View>
393
- </Touchable>
396
+ </NativeTouchable>
394
397
  );
395
398
  };
396
399
 
@@ -64,6 +64,7 @@ export type ButtonProps = $ReadOnly<{
64
64
  @platform tv
65
65
 
66
66
  @default false
67
+ @deprecated Use `focusable` instead
67
68
  */
68
69
  hasTVPreferredFocus?: ?boolean,
69
70
 
@@ -283,10 +284,12 @@ export type ButtonProps = $ReadOnly<{
283
284
  ```
284
285
  */
285
286
 
286
- const Touchable: typeof TouchableNativeFeedback | typeof TouchableOpacity =
287
+ const NativeTouchable:
288
+ | typeof TouchableNativeFeedback
289
+ | typeof TouchableOpacity =
287
290
  Platform.OS === 'android' ? TouchableNativeFeedback : TouchableOpacity;
288
291
 
289
- type ButtonRef = React.ElementRef<typeof Touchable>;
292
+ type ButtonRef = React.ElementRef<typeof NativeTouchable>;
290
293
 
291
294
  const Button: component(
292
295
  ref?: React.RefSetter<ButtonRef>,
@@ -369,7 +372,7 @@ const Button: component(
369
372
  : importantForAccessibility;
370
373
 
371
374
  return (
372
- <Touchable
375
+ <NativeTouchable
373
376
  accessible={accessible}
374
377
  accessibilityActions={accessibilityActions}
375
378
  onAccessibilityAction={onAccessibilityAction}
@@ -398,7 +401,7 @@ const Button: component(
398
401
  {formattedTitle}
399
402
  </Text>
400
403
  </View>
401
- </Touchable>
404
+ </NativeTouchable>
402
405
  );
403
406
  };
404
407
 
@@ -9,5 +9,4 @@
9
9
  */
10
10
 
11
11
  export * from '../../../src/private/specs_DEPRECATED/modules/NativeClipboard';
12
- import NativeClipboard from '../../../src/private/specs_DEPRECATED/modules/NativeClipboard';
13
- export default NativeClipboard;
12
+ export {default} from '../../../src/private/specs_DEPRECATED/modules/NativeClipboard';
@@ -9,5 +9,4 @@
9
9
  */
10
10
 
11
11
  export * from '../../../src/private/specs_DEPRECATED/components/AndroidDrawerLayoutNativeComponent';
12
- import AndroidDrawerLayoutNativeComponent from '../../../src/private/specs_DEPRECATED/components/AndroidDrawerLayoutNativeComponent';
13
- export default AndroidDrawerLayoutNativeComponent;
12
+ export {default} from '../../../src/private/specs_DEPRECATED/components/AndroidDrawerLayoutNativeComponent';
@@ -9,5 +9,4 @@
9
9
  */
10
10
 
11
11
  export * from '../../../src/private/specs_DEPRECATED/modules/NativeKeyboardObserver';
12
- import NativeKeyboardObserver from '../../../src/private/specs_DEPRECATED/modules/NativeKeyboardObserver';
13
- export default NativeKeyboardObserver;
12
+ export {default} from '../../../src/private/specs_DEPRECATED/modules/NativeKeyboardObserver';
@@ -8,6 +8,7 @@
8
8
  * @format
9
9
  */
10
10
 
11
+ import type {ViewStyleProp} from '../../StyleSheet/StyleSheet';
11
12
  import type {
12
13
  GestureResponderEvent,
13
14
  LayoutChangeEvent,
@@ -26,8 +27,6 @@ import useAndroidRippleForView, {
26
27
  import * as React from 'react';
27
28
  import {memo, useMemo, useRef, useState} from 'react';
28
29
 
29
- type ViewStyleProp = React.ElementConfig<typeof View>['style'];
30
-
31
30
  export type {PressableAndroidRippleConfig};
32
31
 
33
32
  export type PressableStateCallbackType = $ReadOnly<{
@@ -192,6 +191,8 @@ function Pressable({
192
191
  disabled,
193
192
  focusable,
194
193
  hitSlop,
194
+ onBlur,
195
+ onFocus,
195
196
  onHoverIn,
196
197
  onHoverOut,
197
198
  onLongPress,
@@ -263,6 +264,8 @@ function Pressable({
263
264
  delayHoverOut,
264
265
  delayLongPress,
265
266
  delayPressIn: unstable_pressDelay,
267
+ onBlur,
268
+ onFocus,
266
269
  onHoverIn,
267
270
  onHoverOut,
268
271
  onLongPress,
@@ -301,6 +304,8 @@ function Pressable({
301
304
  delayLongPress,
302
305
  disabled,
303
306
  hitSlop,
307
+ onBlur,
308
+ onFocus,
304
309
  onHoverIn,
305
310
  onHoverOut,
306
311
  onLongPress,
@@ -314,6 +319,7 @@ function Pressable({
314
319
  unstable_pressDelay,
315
320
  ],
316
321
  );
322
+
317
323
  const eventHandlers = usePressability(config);
318
324
 
319
325
  return (
@@ -8,6 +8,7 @@
8
8
  * @format
9
9
  */
10
10
 
11
+ import type {ViewStyleProp} from '../../StyleSheet/StyleSheet';
11
12
  import type {
12
13
  GestureResponderEvent,
13
14
  LayoutChangeEvent,
@@ -32,8 +33,6 @@ import {memo, useMemo, useRef, useState} from 'react';
32
33
  import type {HandledKeyboardEvent} from '../../Components/View/ViewPropTypes';
33
34
  import View from '../View/View';
34
35
 
35
- type ViewStyleProp = React.ElementConfig<typeof View>['style'];
36
-
37
36
  export type {PressableAndroidRippleConfig};
38
37
 
39
38
  export type PressableStateCallbackType = $ReadOnly<{
@@ -240,6 +239,8 @@ function Pressable({
240
239
  disabled,
241
240
  focusable,
242
241
  hitSlop,
242
+ onBlur,
243
+ onFocus,
243
244
  onHoverIn,
244
245
  onHoverOut,
245
246
  onLongPress,
@@ -248,8 +249,6 @@ function Pressable({
248
249
  onPressMove,
249
250
  onPressOut,
250
251
  // [Windows
251
- onBlur,
252
- onFocus,
253
252
  onKeyDown,
254
253
  onKeyUp,
255
254
  // Windows]
@@ -319,6 +318,8 @@ function Pressable({
319
318
  delayHoverOut,
320
319
  delayLongPress,
321
320
  delayPressIn: unstable_pressDelay,
321
+ onBlur,
322
+ onFocus,
322
323
  onHoverIn,
323
324
  onHoverOut,
324
325
  onLongPress,
@@ -348,8 +349,6 @@ function Pressable({
348
349
  }
349
350
  },
350
351
  // [Windows
351
- onBlur,
352
- onFocus,
353
352
  onKeyDown,
354
353
  onKeyUp,
355
354
  // Windows]
@@ -363,6 +362,8 @@ function Pressable({
363
362
  delayLongPress,
364
363
  disabled,
365
364
  hitSlop,
365
+ onBlur,
366
+ onFocus,
366
367
  onHoverIn,
367
368
  onHoverOut,
368
369
  onLongPress,
@@ -371,8 +372,6 @@ function Pressable({
371
372
  onPressMove,
372
373
  onPressOut,
373
374
  // [Windows
374
- onBlur,
375
- onFocus,
376
375
  onKeyDown,
377
376
  onKeyUp,
378
377
  // Windows]
@@ -382,6 +381,7 @@ function Pressable({
382
381
  unstable_pressDelay,
383
382
  ],
384
383
  );
384
+
385
385
  const eventHandlers = usePressability(config);
386
386
 
387
387
  return (
@@ -9,5 +9,4 @@
9
9
  */
10
10
 
11
11
  export * from '../../../src/private/specs_DEPRECATED/components/ProgressBarAndroidNativeComponent';
12
- import ProgressBarAndroidNativeComponent from '../../../src/private/specs_DEPRECATED/components/ProgressBarAndroidNativeComponent';
13
- export default ProgressBarAndroidNativeComponent;
12
+ export {default} from '../../../src/private/specs_DEPRECATED/components/ProgressBarAndroidNativeComponent';
@@ -9,5 +9,4 @@
9
9
  */
10
10
 
11
11
  export * from '../../../src/private/specs_DEPRECATED/components/AndroidSwipeRefreshLayoutNativeComponent';
12
- import AndroidSwipeRefreshLayoutNativeComponent from '../../../src/private/specs_DEPRECATED/components/AndroidSwipeRefreshLayoutNativeComponent';
13
- export default AndroidSwipeRefreshLayoutNativeComponent;
12
+ export {default} from '../../../src/private/specs_DEPRECATED/components/AndroidSwipeRefreshLayoutNativeComponent';
@@ -10,4 +10,5 @@
10
10
 
11
11
  export * from '../../../src/private/specs_DEPRECATED/components/PullToRefreshViewNativeComponent';
12
12
  import PullToRefreshViewNativeComponent from '../../../src/private/specs_DEPRECATED/components/PullToRefreshViewNativeComponent';
13
+
13
14
  export default PullToRefreshViewNativeComponent;
@@ -9,5 +9,4 @@
9
9
  */
10
10
 
11
11
  export * from '../../../src/private/specs_DEPRECATED/components/RCTSafeAreaViewNativeComponent';
12
- import RCTSafeAreaViewNativeComponent from '../../../src/private/specs_DEPRECATED/components/RCTSafeAreaViewNativeComponent';
13
- export default RCTSafeAreaViewNativeComponent;
12
+ export {default} from '../../../src/private/specs_DEPRECATED/components/RCTSafeAreaViewNativeComponent';
@@ -13,12 +13,21 @@ import {NativeMethods} from '../../../types/public/ReactNativeTypes';
13
13
  import {ViewProps} from '../View/ViewPropTypes';
14
14
 
15
15
  /**
16
+ * @deprecated
17
+ * Use `react-native-safe-area-context` instead. This component is deprecated and will be removed in a future release.
18
+ *
16
19
  * Renders nested content and automatically applies paddings reflect the portion of the view
17
20
  * that is not covered by navigation bars, tab bars, toolbars, and other ancestor views.
18
21
  * Moreover, and most importantly, Safe Area's paddings reflect physical limitation of the screen,
19
22
  * such as rounded corners or camera notches (aka sensor housing area on iPhone X).
20
23
  */
21
24
  declare class SafeAreaViewComponent extends React.Component<ViewProps> {}
25
+
22
26
  declare const SafeAreaViewBase: Constructor<NativeMethods> &
23
27
  typeof SafeAreaViewComponent;
28
+
29
+ /**
30
+ * @deprecated
31
+ * Use `react-native-safe-area-context` instead. This component is deprecated and will be removed in a future release.
32
+ */
24
33
  export class SafeAreaView extends SafeAreaViewBase {}
@@ -22,8 +22,9 @@ import * as React from 'react';
22
22
  * Moreover, and most importantly, Safe Area's paddings reflect physical
23
23
  * limitation of the screen, such as rounded corners or camera notches (aka
24
24
  * sensor housing area on iPhone X).
25
+ * @deprecated Use `react-native-safe-area-context` instead. This component will be removed in a future release.
25
26
  */
26
- const exported: component(
27
+ const SafeAreaView: component(
27
28
  ref?: React.RefSetter<React.ElementRef<typeof View>>,
28
29
  ...props: ViewProps
29
30
  ) = Platform.select({
@@ -31,4 +32,4 @@ const exported: component(
31
32
  default: View,
32
33
  });
33
34
 
34
- export default exported;
35
+ export default SafeAreaView;
@@ -22,8 +22,9 @@ import * as React from 'react';
22
22
  * Moreover, and most importantly, Safe Area's paddings reflect physical
23
23
  * limitation of the screen, such as rounded corners or camera notches (aka
24
24
  * sensor housing area on iPhone X).
25
+ * @deprecated Use `react-native-safe-area-context` instead. This component will be removed in a future release.
25
26
  */
26
- const exported: component(
27
+ const SafeAreaView: component(
27
28
  ref?: React.RefSetter<React.ElementRef<typeof View>>,
28
29
  ...props: ViewProps
29
30
  ) = Platform.select({
@@ -31,4 +32,4 @@ const exported: component(
31
32
  default: View,
32
33
  });
33
34
 
34
- export default exported;
35
+ export default SafeAreaView;
@@ -9,5 +9,4 @@
9
9
  */
10
10
 
11
11
  export * from '../../../src/private/specs_DEPRECATED/components/AndroidHorizontalScrollContentViewNativeComponent';
12
- import AndroidHorizontalScrollContentViewNativeComponent from '../../../src/private/specs_DEPRECATED/components/AndroidHorizontalScrollContentViewNativeComponent';
13
- export default AndroidHorizontalScrollContentViewNativeComponent;
12
+ export {default} from '../../../src/private/specs_DEPRECATED/components/AndroidHorizontalScrollContentViewNativeComponent';
@@ -10,6 +10,7 @@
10
10
  import type * as React from 'react';
11
11
  import {Constructor} from '../../../types/private/Utilities';
12
12
  import {Insets} from '../../../types/public/Insets';
13
+ import {HostInstance} from '../../../types/public/ReactNativeTypes';
13
14
  import {ColorValue, StyleProp} from '../../StyleSheet/StyleSheet';
14
15
  import {ViewStyle} from '../../StyleSheet/StyleSheetTypes';
15
16
  import {
@@ -677,7 +678,9 @@ export interface ScrollViewProps
677
678
  * It's implemented using onLayout handler attached to the content container which this ScrollView renders.
678
679
  *
679
680
  */
680
- onContentSizeChange?: ((w: number, h: number) => void) | undefined;
681
+ onContentSizeChange?:
682
+ | ((contentWidth: number, contentHeight: number) => void)
683
+ | undefined;
681
684
 
682
685
  /**
683
686
  * Fires at most once per frame during scrolling.
@@ -878,6 +881,12 @@ export class ScrollView extends ScrollViewBase {
878
881
  // Undocumented
879
882
  getInnerViewNode(): any;
880
883
 
884
+ /**
885
+ * Returns a reference to the underlying native scroll view, or null if the
886
+ * native instance is not mounted.
887
+ */
888
+ getNativeScrollRef: () => HostInstance | null;
889
+
881
890
  /**
882
891
  * @deprecated Use scrollTo instead
883
892
  */
@@ -673,7 +673,7 @@ type ScrollViewBaseProps = $ReadOnly<{
673
673
  }>;
674
674
 
675
675
  export type ScrollViewProps = $ReadOnly<{
676
- ...ViewProps,
676
+ ...Omit<ViewProps, 'experimental_accessibilityOrder'>,
677
677
  ...ScrollViewPropsIOS,
678
678
  ...ScrollViewPropsAndroid,
679
679
  ...ScrollViewBaseProps,
@@ -1480,6 +1480,7 @@ class ScrollView extends React.Component<ScrollViewProps, ScrollViewState> {
1480
1480
  // then the second tap goes to the actual interior view)
1481
1481
  const {keyboardShouldPersistTaps} = this.props;
1482
1482
  const keyboardNeverPersistTaps =
1483
+ // $FlowFixMe[sketchy-null-bool]
1483
1484
  !keyboardShouldPersistTaps || keyboardShouldPersistTaps === 'never';
1484
1485
 
1485
1486
  if (typeof e.target === 'number') {
@@ -1562,6 +1563,7 @@ class ScrollView extends React.Component<ScrollViewProps, ScrollViewState> {
1562
1563
 
1563
1564
  const {keyboardShouldPersistTaps} = this.props;
1564
1565
  const keyboardNeverPersistsTaps =
1566
+ // $FlowFixMe[sketchy-null-bool]
1565
1567
  !keyboardShouldPersistTaps || keyboardShouldPersistTaps === 'never';
1566
1568
 
1567
1569
  // Dismiss the keyboard now if we didn't become responder in capture phase
@@ -9,5 +9,4 @@
9
9
  */
10
10
 
11
11
  export * from '../../../src/private/specs_DEPRECATED/modules/NativeSoundManager';
12
- import NativeSoundManager from '../../../src/private/specs_DEPRECATED/modules/NativeSoundManager';
13
- export default NativeSoundManager;
12
+ export {default} from '../../../src/private/specs_DEPRECATED/modules/NativeSoundManager';
@@ -9,5 +9,4 @@
9
9
  */
10
10
 
11
11
  export * from '../../../src/private/specs_DEPRECATED/modules/NativeStatusBarManagerAndroid';
12
- import NativeStatusBarManagerAndroid from '../../../src/private/specs_DEPRECATED/modules/NativeStatusBarManagerAndroid';
13
- export default NativeStatusBarManagerAndroid;
12
+ export {default} from '../../../src/private/specs_DEPRECATED/modules/NativeStatusBarManagerAndroid';
@@ -9,5 +9,4 @@
9
9
  */
10
10
 
11
11
  export * from '../../../src/private/specs_DEPRECATED/modules/NativeStatusBarManagerIOS';
12
- import NativeStatusBarManagerIOS from '../../../src/private/specs_DEPRECATED/modules/NativeStatusBarManagerIOS';
13
- export default NativeStatusBarManagerIOS;
12
+ export {default} from '../../../src/private/specs_DEPRECATED/modules/NativeStatusBarManagerIOS';
@@ -35,6 +35,8 @@ export interface StatusBarPropsAndroid {
35
35
  /**
36
36
  * The background color of the status bar.
37
37
  *
38
+ * Please note that this prop has no effect on Android 15+
39
+ *
38
40
  * @platform android
39
41
  */
40
42
  backgroundColor?: ColorValue | undefined;
@@ -44,6 +46,8 @@ export interface StatusBarPropsAndroid {
44
46
  * the app will draw under the status bar. This is useful when using a
45
47
  * semi transparent status bar color.
46
48
  *
49
+ * Please note that this prop has no effect on Android 15+
50
+ *
47
51
  * @platform android
48
52
  */
49
53
  translucent?: boolean | undefined;
@@ -58,6 +58,9 @@ export type StatusBarAnimation = $Keys<{
58
58
  export type StatusBarPropsAndroid = $ReadOnly<{
59
59
  /**
60
60
  * The background color of the status bar.
61
+ *
62
+ * Please note that this prop has no effect on Android 15+
63
+ *
61
64
  * @platform android
62
65
  */
63
66
  backgroundColor?: ?ColorValue,
@@ -66,6 +69,8 @@ export type StatusBarPropsAndroid = $ReadOnly<{
66
69
  * When translucent is set to true, the app will draw under the status bar.
67
70
  * This is useful when using a semi transparent status bar color.
68
71
  *
72
+ * Please note that this prop has no effect on Android 15+
73
+ *
69
74
  * @platform android
70
75
  */
71
76
  translucent?: ?boolean,
@@ -9,5 +9,4 @@
9
9
  */
10
10
 
11
11
  export * from '../../../src/private/specs_DEPRECATED/components/AndroidSwitchNativeComponent';
12
- import AndroidSwitchNativeComponent from '../../../src/private/specs_DEPRECATED/components/AndroidSwitchNativeComponent';
13
- export default AndroidSwitchNativeComponent;
12
+ export {default} from '../../../src/private/specs_DEPRECATED/components/AndroidSwitchNativeComponent';