@office-iss/react-native-win32 0.0.0-canary.289 → 0.0.0-canary.290
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.
- package/.flowconfig +1 -2
- package/CHANGELOG.json +16 -1
- package/CHANGELOG.md +13 -5
- package/Libraries/Animated/Animated.js.flow +1 -3
- package/Libraries/Animated/AnimatedExports.js.flow +12 -0
- package/Libraries/Animated/components/AnimatedScrollView.js +2 -1
- package/Libraries/Animated/components/AnimatedSectionList.js +1 -1
- package/Libraries/Animated/createAnimatedComponent.js +92 -56
- package/Libraries/Animated/nodes/AnimatedProps.js +29 -26
- package/Libraries/Animated/nodes/AnimatedValueXY.js +3 -1
- package/Libraries/AppState/AppState.js +1 -1
- package/Libraries/Blob/URL.js +1 -1
- package/Libraries/Blob/URLSearchParams.js +106 -31
- package/Libraries/Blob/URLSearchParams.js.flow +12 -7
- package/Libraries/Components/AccessibilityInfo/AccessibilityInfo.js +1 -1
- package/Libraries/Components/AccessibilityInfo/AccessibilityInfo.win32.js +1 -1
- package/Libraries/Components/Keyboard/Keyboard.js +1 -1
- package/Libraries/Components/Pressable/Pressable.js +14 -3
- package/Libraries/Components/Pressable/Pressable.win32.js +14 -3
- package/Libraries/Components/ScrollView/ScrollView.d.ts +1 -1
- package/Libraries/Components/ScrollView/ScrollView.js +14 -17
- package/Libraries/Components/Switch/Switch.d.ts +3 -0
- package/Libraries/Components/Switch/Switch.js +1 -1
- package/Libraries/Components/TextInput/TextInput.d.ts +64 -33
- package/Libraries/Components/TextInput/TextInput.flow.js +15 -16
- package/Libraries/Components/TextInput/TextInput.js +34 -27
- package/Libraries/Components/TextInput/TextInput.win32.js +34 -27
- package/Libraries/Components/TextInput/TextInputState.js +1 -1
- package/Libraries/Components/TextInput/TextInputState.win32.js +1 -1
- package/Libraries/Components/Touchable/TouchableBounce.js +2 -1
- package/Libraries/Components/Touchable/TouchableHighlight.js +1 -1
- package/Libraries/Components/Touchable/TouchableNativeFeedback.js +2 -2
- package/Libraries/Components/Touchable/TouchableNativeFeedback.win32.js +2 -2
- package/Libraries/Components/Touchable/TouchableOpacity.js +2 -1
- package/Libraries/Components/View/ViewAccessibility.js +2 -1
- package/Libraries/Components/View/ViewAccessibility.win32.js +2 -1
- package/Libraries/Components/View/ViewPropTypes.js +49 -3
- package/Libraries/Components/View/ViewPropTypes.win32.js +49 -3
- package/Libraries/Core/ReactNativeVersion.js +1 -1
- package/Libraries/Debugging/DebuggingOverlayRegistry.js +3 -3
- package/Libraries/EventEmitter/NativeEventEmitter.js +4 -2
- package/Libraries/EventEmitter/__mocks__/NativeEventEmitter.js +2 -2
- package/Libraries/Image/Image.d.ts +26 -10
- package/Libraries/Image/Image.js.flow +3 -3
- package/Libraries/Image/ImageBackground.js +2 -0
- package/Libraries/Image/ImageProps.js +19 -14
- package/Libraries/Interaction/InteractionManager.d.ts +13 -0
- package/Libraries/Interaction/InteractionManager.js +1 -1
- package/Libraries/Interaction/PanResponder.js +3 -3
- package/Libraries/LayoutAnimation/LayoutAnimation.js +2 -2
- package/Libraries/Linking/Linking.js +1 -1
- package/Libraries/Lists/FlatList.js +7 -10
- package/Libraries/Lists/SectionList.js +39 -42
- package/Libraries/Lists/SectionListModern.js +22 -31
- package/Libraries/Lists/VirtualizedList.js +1 -0
- package/Libraries/Lists/VirtualizedSectionList.js +1 -0
- package/Libraries/NativeComponent/BaseViewConfig.android.js +1 -0
- package/Libraries/NativeComponent/BaseViewConfig.ios.js +1 -0
- package/Libraries/NativeComponent/BaseViewConfig.win32.js +1 -0
- package/Libraries/Network/RCTNetworking.android.js +1 -1
- package/Libraries/Network/RCTNetworking.ios.js +1 -1
- package/Libraries/Network/RCTNetworking.js.flow +1 -1
- package/Libraries/Network/RCTNetworking.win32.js +1 -1
- package/Libraries/NewAppScreen/components/DebugInstructions.js +1 -3
- package/Libraries/NewAppScreen/components/Header.js +1 -3
- package/Libraries/NewAppScreen/components/HermesBadge.js +1 -3
- package/Libraries/NewAppScreen/components/LearnMoreLinks.js +1 -3
- package/Libraries/NewAppScreen/components/ReloadInstructions.js +1 -3
- package/Libraries/Pressability/Pressability.js +1 -1
- package/Libraries/Pressability/Pressability.win32.js +1 -1
- package/Libraries/ReactNative/AppContainer-dev.js +2 -2
- package/Libraries/ReactNative/ReactFabricPublicInstance/ReactFabricHostComponent.js +2 -4
- package/Libraries/ReactNative/RendererImplementation.js +4 -0
- package/Libraries/ReactPrivate/ReactNativePrivateInterface.js +1 -1
- package/Libraries/Renderer/shims/ReactNativeTypes.js +3 -3
- package/Libraries/StyleSheet/StyleSheet.js +25 -2
- package/Libraries/StyleSheet/StyleSheet.js.flow +24 -2
- package/Libraries/StyleSheet/StyleSheetTypes.js +13 -3
- package/Libraries/StyleSheet/flattenStyle.js +7 -3
- package/Libraries/StyleSheet/private/_TransformStyle.js +3 -3
- package/Libraries/Text/Text.d.ts +2 -5
- package/Libraries/Text/TextProps.js +3 -2
- package/Libraries/Text/TextProps.win32.js +3 -2
- package/Libraries/Types/CoreEventTypes.d.ts +6 -1
- package/Libraries/Types/CoreEventTypes.js +1 -1
- package/Libraries/Types/CoreEventTypes.win32.js +1 -1
- package/Libraries/Utilities/DeviceInfo.js +2 -0
- package/Libraries/Utilities/Dimensions.js +1 -1
- package/Libraries/Utilities/Dimensions.win32.js +1 -1
- package/Libraries/Utilities/PlatformTypes.js +9 -3
- package/Libraries/Utilities/ReactNativeTestTools.js +1 -1
- package/Libraries/vendor/core/ErrorUtils.js +2 -0
- package/flow/global.js +2 -0
- package/index.js +3 -0
- package/index.win32.js +3 -0
- package/interface.js +0 -4
- package/overrides.json +19 -25
- package/package.json +13 -13
- package/src/private/animated/NativeAnimatedHelper.js +3 -1
- package/src/private/animated/NativeAnimatedHelper.win32.js +3 -1
- package/src/private/animated/createAnimatedPropsHook.js +1 -0
- package/src/private/animated/createAnimatedPropsMemoHook.js +1 -2
- package/src/private/featureflags/ReactNativeFeatureFlags.js +18 -18
- package/src/private/featureflags/specs/NativeReactNativeFeatureFlags.js +3 -3
- package/src/private/inspector/getInspectorDataForViewAtPoint.js +2 -2
- package/src/private/types/HostInstance.js +61 -3
- package/src/private/webapis/dom/nodes/ReactNativeElement.js +2 -5
- package/src-win/Libraries/Text/Text.d.ts +2 -5
- package/types/modules/LaunchScreen.d.ts +9 -1
- package/Libraries/Utilities/DeviceInfo.win32.js +0 -19
- package/flow/jest.js +0 -1289
- package/src/private/utilities/ensureInstance.js +0 -21
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
3
|
-
*
|
|
4
|
-
* This source code is licensed under the MIT license found in the
|
|
5
|
-
* LICENSE file in the root directory of this source tree.
|
|
6
|
-
*
|
|
7
|
-
* @format
|
|
8
|
-
* @flow strict
|
|
9
|
-
*/
|
|
10
|
-
|
|
11
|
-
export default function ensureInstance<T>(value: mixed, Class: Class<T>): T {
|
|
12
|
-
if (!(value instanceof Class)) {
|
|
13
|
-
// $FlowIssue[incompatible-use]
|
|
14
|
-
const className = Class.name;
|
|
15
|
-
throw new Error(
|
|
16
|
-
`Expected instance of ${className} but got ${String(value)}`,
|
|
17
|
-
);
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
return value;
|
|
21
|
-
}
|