@office-iss/react-native-win32 0.0.0-canary.291 → 0.0.0-canary.292
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 -1
- package/CHANGELOG.json +16 -1
- package/CHANGELOG.md +12 -4
- package/Libraries/Alert/RCTAlertManager.js +17 -0
- package/Libraries/Animated/AnimatedEvent.js +4 -3
- package/Libraries/Animated/AnimatedExports.js.flow +2 -0
- package/Libraries/Animated/AnimatedImplementation.js +2 -2
- package/Libraries/Animated/components/AnimatedScrollView.js +48 -43
- package/Libraries/Animated/nodes/AnimatedValue.js +2 -1
- package/Libraries/BatchedBridge/MessageQueue.js +2 -2
- package/Libraries/Blob/FileReader.js +219 -8
- package/Libraries/Components/AccessibilityInfo/legacySendAccessibilityEvent.js +17 -0
- package/Libraries/Components/Button.js +1 -1
- package/Libraries/Components/Button.win32.js +1 -1
- package/Libraries/Components/DrawerAndroid/DrawerLayoutAndroid.android.js +1 -3
- package/Libraries/Components/DrawerAndroid/DrawerLayoutAndroid.ios.js +15 -0
- package/Libraries/Components/DrawerAndroid/DrawerLayoutAndroid.js +6 -66
- package/Libraries/Components/DrawerAndroid/DrawerLayoutAndroid.js.flow +18 -0
- package/Libraries/Components/DrawerAndroid/DrawerLayoutAndroidFallback.js +71 -0
- package/Libraries/Components/Keyboard/Keyboard.js +4 -2
- package/Libraries/Components/Keyboard/KeyboardAvoidingView.js +6 -3
- package/Libraries/Components/Pressable/Pressable.js +2 -0
- package/Libraries/Components/Pressable/Pressable.win32.js +2 -0
- package/Libraries/Components/ProgressBarAndroid/ProgressBarAndroid.js +12 -2
- package/Libraries/Components/RefreshControl/RefreshControl.js +1 -1
- package/Libraries/Components/ScrollView/ScrollView.js +128 -116
- package/Libraries/Components/StaticRenderer.js +1 -1
- package/Libraries/Components/TextInput/AndroidTextInputNativeComponent.js +1 -1
- package/Libraries/Components/TextInput/RCTTextInputViewConfig.js +1 -4
- package/Libraries/Components/TextInput/TextInput.flow.js +35 -43
- package/Libraries/Components/TextInput/TextInput.flow.win32.js +1184 -0
- package/Libraries/Components/TextInput/TextInput.js +65 -1005
- package/Libraries/Components/TextInput/TextInput.win32.js +67 -1037
- package/Libraries/Components/ToastAndroid/ToastAndroid.ios.js +13 -0
- package/Libraries/Components/ToastAndroid/ToastAndroid.js +4 -32
- package/Libraries/Components/ToastAndroid/ToastAndroid.js.flow +109 -0
- package/Libraries/Components/ToastAndroid/ToastAndroid.win32.js +4 -32
- package/Libraries/Components/ToastAndroid/ToastAndroidFallback.js +45 -0
- package/Libraries/Components/Touchable/Touchable.js +5 -5
- package/Libraries/Components/Touchable/Touchable.win32.js +5 -5
- package/Libraries/Components/Touchable/TouchableBounce.js +12 -6
- package/Libraries/Components/Touchable/TouchableHighlight.js +9 -6
- package/Libraries/Components/Touchable/TouchableNativeFeedback.js +4 -4
- package/Libraries/Components/Touchable/TouchableNativeFeedback.win32.js +4 -4
- package/Libraries/Components/Touchable/TouchableOpacity.js +11 -5
- package/Libraries/Components/View/ViewAccessibility.js +7 -0
- package/Libraries/Components/View/ViewAccessibility.win32.js +7 -0
- package/Libraries/Components/View/ViewPropTypes.js +1 -1
- package/Libraries/Components/View/ViewPropTypes.win32.js +1 -1
- package/Libraries/Core/ReactNativeVersion.js +1 -1
- package/Libraries/EventEmitter/NativeEventEmitter.js +4 -1
- package/Libraries/Image/Image.js +17 -0
- package/Libraries/Image/Image.js.flow +2 -2
- package/Libraries/Image/ImageInjection.js +1 -1
- package/Libraries/Image/ImageProps.js +5 -4
- package/Libraries/Image/ImageTypes.flow.js +1 -1
- package/Libraries/Lists/FlatList.js +1 -1
- package/Libraries/Lists/SectionList.js +1 -1
- package/Libraries/Lists/SectionListModern.js +2 -1
- package/Libraries/LogBox/LogBoxNotificationContainer.js +1 -1
- package/Libraries/Modal/Modal.js +3 -3
- package/Libraries/NativeComponent/BaseViewConfig.js +17 -0
- package/Libraries/NativeComponent/PlatformBaseViewConfig.js +2 -2
- package/Libraries/Network/RCTNetworking.js +17 -0
- package/Libraries/Network/XMLHttpRequest.js +781 -10
- package/Libraries/NewAppScreen/components/DebugInstructions.js +1 -1
- package/Libraries/NewAppScreen/components/Header.js +1 -1
- package/Libraries/NewAppScreen/components/HermesBadge.js +1 -1
- package/Libraries/NewAppScreen/components/LearnMoreLinks.js +3 -3
- package/Libraries/NewAppScreen/components/ReloadInstructions.js +1 -1
- package/Libraries/Performance/Systrace.js +7 -7
- package/Libraries/ReactPrivate/ReactNativePrivateInterface.js +2 -2
- package/Libraries/Settings/Settings.js +13 -19
- package/Libraries/Settings/Settings.win32.js +19 -20
- package/Libraries/Settings/SettingsFallback.js +33 -0
- package/Libraries/StyleSheet/PlatformColorValueTypes.js +15 -0
- package/Libraries/StyleSheet/Rect.js +1 -0
- package/Libraries/StyleSheet/StyleSheet.js.flow +3 -3
- package/Libraries/StyleSheet/StyleSheetTypes.js +28 -30
- package/Libraries/StyleSheet/flattenStyle.js +7 -1
- package/Libraries/Text/Text.js +3 -3
- package/Libraries/Text/Text.win32.js +3 -3
- package/Libraries/Text/TextProps.js +1 -1
- package/Libraries/Text/TextProps.win32.js +1 -1
- package/Libraries/Utilities/Appearance.js +2 -0
- package/Libraries/Utilities/BackHandler.js +17 -0
- package/Libraries/Utilities/Platform.js +17 -0
- package/Libraries/Utilities/PlatformTypes.js +2 -0
- package/Libraries/Utilities/ReactNativeTestTools.js +1 -1
- package/Libraries/WebSocket/WebSocket.js +313 -8
- package/flow/global.js +0 -2
- package/index.win32.js +5 -5
- package/overrides.json +23 -17
- package/package.json +12 -12
- package/src/private/animated/NativeAnimatedHelper.js +1 -1
- package/src/private/animated/NativeAnimatedHelper.win32.js +1 -1
- package/src/private/animated/createAnimatedPropsHook.js +2 -27
- package/src/private/components/{SafeAreaView_INTERNAL_DO_NOT_USE.js → safeareaview/SafeAreaView_INTERNAL_DO_NOT_USE.js} +6 -6
- package/src/private/components/{HScrollViewNativeComponents.js → scrollview/HScrollViewNativeComponents.js} +8 -8
- package/src/private/components/scrollview/VScrollViewNativeComponents.js +25 -0
- package/src/private/featureflags/ReactNativeFeatureFlags.js +21 -32
- package/src/private/featureflags/specs/NativeReactNativeFeatureFlags.js +5 -6
- package/src/private/inspector/BorderBox.js +1 -1
- package/src/private/inspector/BoxInspector.js +1 -1
- package/src/private/inspector/ElementBox.js +1 -1
- package/src/private/inspector/ElementProperties.js +1 -1
- package/src/private/inspector/Inspector.js +2 -2
- package/src/private/inspector/InspectorOverlay.js +1 -1
- package/src/private/inspector/InspectorPanel.js +1 -1
- package/src/private/inspector/NetworkOverlay.js +1 -1
- package/src/private/inspector/PerformanceOverlay.js +1 -1
- package/src/private/inspector/StyleInspector.js +1 -1
- package/src/private/types/HostComponent.js +1 -1
- package/src/private/types/HostInstance.js +10 -2
- package/src/private/webapis/performance/Performance.js +1 -3
- package/Libraries/Blob/FileReader_new.js +0 -231
- package/Libraries/Blob/FileReader_old.js +0 -186
- package/Libraries/Events/CustomEvent.js +0 -32
- package/Libraries/Events/EventPolyfill.js +0 -239
- package/Libraries/Network/XMLHttpRequest_new.js +0 -794
- package/Libraries/Network/XMLHttpRequest_old.js +0 -701
- package/Libraries/WebSocket/WebSocketEvent.js +0 -30
- package/Libraries/WebSocket/WebSocket_new.js +0 -325
- package/Libraries/WebSocket/WebSocket_old.js +0 -297
- package/Libraries/WebSocket/__mocks__/event-target-shim.js +0 -27
- package/src/private/components/VScrollViewNativeComponents.js +0 -25
- package/src/types/third_party/event-target-shim.d.ts +0 -392
|
@@ -23,13 +23,17 @@ import {
|
|
|
23
23
|
} from '../../StyleSheet/StyleSheet';
|
|
24
24
|
import * as React from 'react';
|
|
25
25
|
|
|
26
|
+
/**
|
|
27
|
+
* @see TextInputProps.onChange
|
|
28
|
+
*/
|
|
26
29
|
type TextInputChangeEventData = $ReadOnly<{
|
|
27
30
|
eventCount: number,
|
|
28
31
|
target: number,
|
|
29
32
|
text: string,
|
|
30
33
|
}>;
|
|
31
34
|
|
|
32
|
-
type TextInputChangeEvent =
|
|
35
|
+
export type TextInputChangeEvent =
|
|
36
|
+
NativeSyntheticEvent<TextInputChangeEventData>;
|
|
33
37
|
|
|
34
38
|
export type TextInputEvent = NativeSyntheticEvent<
|
|
35
39
|
$ReadOnly<{
|
|
@@ -52,19 +56,30 @@ type TextInputContentSizeChangeEventData = $ReadOnly<{
|
|
|
52
56
|
}>,
|
|
53
57
|
}>;
|
|
54
58
|
|
|
59
|
+
/**
|
|
60
|
+
* @see TextInputProps.onContentSizeChange
|
|
61
|
+
*/
|
|
55
62
|
export type TextInputContentSizeChangeEvent =
|
|
56
63
|
NativeSyntheticEvent<TextInputContentSizeChangeEventData>;
|
|
57
64
|
|
|
58
65
|
type TargetEvent = $ReadOnly<{
|
|
59
66
|
target: number,
|
|
67
|
+
...
|
|
60
68
|
}>;
|
|
61
69
|
|
|
62
70
|
type TextInputFocusEventData = TargetEvent;
|
|
63
71
|
|
|
72
|
+
/**
|
|
73
|
+
* @see TextInputProps.onBlur
|
|
74
|
+
*/
|
|
64
75
|
export type TextInputBlurEvent = NativeSyntheticEvent<TextInputFocusEventData>;
|
|
76
|
+
|
|
77
|
+
/**
|
|
78
|
+
* @see TextInputProps.onFocus
|
|
79
|
+
*/
|
|
65
80
|
export type TextInputFocusEvent = NativeSyntheticEvent<TextInputFocusEventData>;
|
|
66
81
|
|
|
67
|
-
type Selection = $ReadOnly<{
|
|
82
|
+
export type Selection = $ReadOnly<{
|
|
68
83
|
start: number,
|
|
69
84
|
end: number,
|
|
70
85
|
}>;
|
|
@@ -72,8 +87,12 @@ type Selection = $ReadOnly<{
|
|
|
72
87
|
type TextInputSelectionChangeEventData = $ReadOnly<{
|
|
73
88
|
...TargetEvent,
|
|
74
89
|
selection: Selection,
|
|
90
|
+
...
|
|
75
91
|
}>;
|
|
76
92
|
|
|
93
|
+
/**
|
|
94
|
+
* @see TextInputProps.onSelectionChange
|
|
95
|
+
*/
|
|
77
96
|
export type TextInputSelectionChangeEvent =
|
|
78
97
|
NativeSyntheticEvent<TextInputSelectionChangeEventData>;
|
|
79
98
|
|
|
@@ -82,8 +101,12 @@ type TextInputKeyPressEventData = $ReadOnly<{
|
|
|
82
101
|
key: string,
|
|
83
102
|
target?: ?number,
|
|
84
103
|
eventCount: number,
|
|
104
|
+
...
|
|
85
105
|
}>;
|
|
86
106
|
|
|
107
|
+
/**
|
|
108
|
+
* @see TextInputProps.onKeyPress
|
|
109
|
+
*/
|
|
87
110
|
export type TextInputKeyPressEvent =
|
|
88
111
|
NativeSyntheticEvent<TextInputKeyPressEventData>;
|
|
89
112
|
|
|
@@ -91,6 +114,7 @@ type TextInputEndEditingEventData = $ReadOnly<{
|
|
|
91
114
|
...TargetEvent,
|
|
92
115
|
eventCount: number,
|
|
93
116
|
text: string,
|
|
117
|
+
...
|
|
94
118
|
}>;
|
|
95
119
|
|
|
96
120
|
/**
|
|
@@ -103,6 +127,7 @@ type TextInputSubmitEditingEventData = $ReadOnly<{
|
|
|
103
127
|
...TargetEvent,
|
|
104
128
|
eventCount: number,
|
|
105
129
|
text: string,
|
|
130
|
+
...
|
|
106
131
|
}>;
|
|
107
132
|
|
|
108
133
|
/**
|
|
@@ -488,11 +513,7 @@ export type TextInputAndroidProps = $ReadOnly<{
|
|
|
488
513
|
underlineColorAndroid?: ?ColorValue,
|
|
489
514
|
}>;
|
|
490
515
|
|
|
491
|
-
|
|
492
|
-
...$Diff<ViewProps, $ReadOnly<{style: ?ViewStyleProp}>>,
|
|
493
|
-
...TextInputIOSProps,
|
|
494
|
-
...TextInputAndroidProps,
|
|
495
|
-
|
|
516
|
+
type TextInputBaseProps = $ReadOnly<{
|
|
496
517
|
/**
|
|
497
518
|
* Can tell `TextInput` to automatically capitalize certain characters.
|
|
498
519
|
*
|
|
@@ -776,33 +797,12 @@ export type TextInputProps = $ReadOnly<{
|
|
|
776
797
|
*/
|
|
777
798
|
onChange?: ?(e: TextInputChangeEvent) => mixed,
|
|
778
799
|
|
|
779
|
-
/**
|
|
780
|
-
* DANGER: this API is not stable and will change in the future.
|
|
781
|
-
*
|
|
782
|
-
* Callback will be called on the main thread and may result in dropped frames.
|
|
783
|
-
* Callback that is called when the text input's text changes.
|
|
784
|
-
*
|
|
785
|
-
* @platform ios
|
|
786
|
-
*/
|
|
787
|
-
unstable_onChangeSync?: ?(e: TextInputChangeEvent) => mixed,
|
|
788
|
-
|
|
789
800
|
/**
|
|
790
801
|
* Callback that is called when the text input's text changes.
|
|
791
802
|
* Changed text is passed as an argument to the callback handler.
|
|
792
803
|
*/
|
|
793
804
|
onChangeText?: ?(text: string) => mixed,
|
|
794
805
|
|
|
795
|
-
/**
|
|
796
|
-
* DANGER: this API is not stable and will change in the future.
|
|
797
|
-
*
|
|
798
|
-
* Callback will be called on the main thread and may result in dropped frames.
|
|
799
|
-
* Callback that is called when the text input's text changes.
|
|
800
|
-
* Changed text is passed as an argument to the callback handler.
|
|
801
|
-
*
|
|
802
|
-
* @platform ios
|
|
803
|
-
*/
|
|
804
|
-
unstable_onChangeTextSync?: ?(text: string) => mixed,
|
|
805
|
-
|
|
806
806
|
/**
|
|
807
807
|
* Callback that is called when the text input's content size changes.
|
|
808
808
|
* This will be called with
|
|
@@ -831,21 +831,6 @@ export type TextInputProps = $ReadOnly<{
|
|
|
831
831
|
*/
|
|
832
832
|
onKeyPress?: ?(e: TextInputKeyPressEvent) => mixed,
|
|
833
833
|
|
|
834
|
-
/**
|
|
835
|
-
* DANGER: this API is not stable and will change in the future.
|
|
836
|
-
*
|
|
837
|
-
* Callback will be called on the main thread and may result in dropped frames.
|
|
838
|
-
*
|
|
839
|
-
* Callback that is called when a key is pressed.
|
|
840
|
-
* This will be called with `{ nativeEvent: { key: keyValue } }`
|
|
841
|
-
* where `keyValue` is `'Enter'` or `'Backspace'` for respective keys and
|
|
842
|
-
* the typed-in character otherwise including `' '` for space.
|
|
843
|
-
* Fires before `onChange` callbacks.
|
|
844
|
-
*
|
|
845
|
-
* @platform ios
|
|
846
|
-
*/
|
|
847
|
-
unstable_onKeyPressSync?: ?(e: TextInputKeyPressEvent) => mixed,
|
|
848
|
-
|
|
849
834
|
/**
|
|
850
835
|
* Called when a single tap gesture is detected.
|
|
851
836
|
*/
|
|
@@ -1022,6 +1007,13 @@ export type TextInputProps = $ReadOnly<{
|
|
|
1022
1007
|
value?: ?Stringish,
|
|
1023
1008
|
}>;
|
|
1024
1009
|
|
|
1010
|
+
export type TextInputProps = $ReadOnly<{
|
|
1011
|
+
...Omit<ViewProps, 'style'>,
|
|
1012
|
+
...TextInputIOSProps,
|
|
1013
|
+
...TextInputAndroidProps,
|
|
1014
|
+
...TextInputBaseProps,
|
|
1015
|
+
}>;
|
|
1016
|
+
|
|
1025
1017
|
export interface TextInputInstance extends HostInstance {
|
|
1026
1018
|
+clear: () => void;
|
|
1027
1019
|
+isFocused: () => boolean;
|