@office-iss/react-native-win32 0.69.0 → 0.70.0
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/.eslintrc.js +0 -1
- package/.flowconfig +5 -1
- package/CHANGELOG.json +241 -31
- package/CHANGELOG.md +97 -18
- package/IntegrationTests/AsyncStorageTest.js +20 -4
- package/IntegrationTests/BUCK +2 -2
- package/IntegrationTests/LayoutEventsTest.js +4 -1
- package/IntegrationTests/{launchWebSocketServer.command → launchWebSocketServer.sh} +3 -9
- package/Libraries/Alert/Alert.js +18 -4
- package/Libraries/Alert/Alert.win32.js +2 -0
- package/Libraries/Alert/NativeAlertManager.js +1 -0
- package/Libraries/Animated/Animated.js +2 -2
- package/Libraries/Animated/AnimatedEvent.js +7 -4
- package/Libraries/Animated/AnimatedImplementation.js +17 -3
- package/Libraries/Animated/AnimatedMock.js +7 -2
- package/Libraries/Animated/NativeAnimatedHelper.js +220 -95
- package/Libraries/Animated/NativeAnimatedModule.js +3 -0
- package/Libraries/Animated/NativeAnimatedTurboModule.js +3 -0
- package/Libraries/Animated/animations/SpringAnimation.js +3 -3
- package/Libraries/Animated/animations/TimingAnimation.js +3 -3
- package/Libraries/Animated/createAnimatedComponent.js +8 -1
- package/Libraries/Animated/nodes/AnimatedAddition.js +3 -1
- package/Libraries/Animated/nodes/AnimatedColor.js +50 -29
- package/Libraries/Animated/nodes/AnimatedDiffClamp.js +3 -1
- package/Libraries/Animated/nodes/AnimatedDivision.js +3 -1
- package/Libraries/Animated/nodes/AnimatedInterpolation.js +22 -21
- package/Libraries/Animated/nodes/AnimatedModulo.js +3 -1
- package/Libraries/Animated/nodes/AnimatedMultiplication.js +3 -2
- package/Libraries/Animated/nodes/AnimatedProps.js +20 -12
- package/Libraries/Animated/nodes/AnimatedStyle.js +19 -16
- package/Libraries/Animated/nodes/AnimatedSubtraction.js +3 -1
- package/Libraries/Animated/nodes/AnimatedTransform.js +5 -5
- package/Libraries/Animated/nodes/AnimatedValue.js +14 -5
- package/Libraries/Animated/nodes/AnimatedValueXY.js +28 -1
- package/Libraries/Animated/useAnimatedProps.js +1 -0
- package/Libraries/AppState/AppState.js +0 -32
- package/Libraries/BatchedBridge/MessageQueue.js +21 -15
- package/Libraries/BatchedBridge/NativeModules.js +3 -4
- package/Libraries/Blob/FileReader.js +0 -6
- package/Libraries/Components/AccessibilityInfo/AccessibilityInfo.js +0 -20
- package/Libraries/Components/AccessibilityInfo/AccessibilityInfo.win32.js +0 -20
- package/Libraries/Components/DrawerAndroid/DrawerLayoutAndroid.android.js +4 -0
- package/Libraries/Components/Keyboard/Keyboard.js +0 -11
- package/Libraries/Components/Pressable/Pressable.js +2 -0
- package/Libraries/Components/Pressable/Pressable.win32.js +2 -0
- package/Libraries/Components/SafeAreaView/RCTSafeAreaViewNativeComponent.js +1 -3
- package/Libraries/Components/SafeAreaView/SafeAreaView.js +3 -30
- package/Libraries/Components/SafeAreaView/SafeAreaView.win32.js +4 -32
- package/Libraries/Components/ScrollView/ScrollView.js +13 -11
- package/Libraries/Components/ScrollView/ScrollViewStickyHeader.js +5 -3
- package/Libraries/Components/StatusBar/StatusBar.js +10 -7
- package/Libraries/Components/TextInput/InputAccessoryView.js +14 -13
- package/Libraries/Components/TextInput/TextInput.js +12 -2
- package/Libraries/Components/Touchable/PooledClass.js +16 -4
- package/Libraries/Components/Touchable/Touchable.js +50 -1
- package/Libraries/Components/Touchable/Touchable.win32.js +972 -0
- package/Libraries/Components/Touchable/TouchableNativeFeedback.js +6 -2
- package/Libraries/Components/View/ReactNativeStyleAttributes.js +0 -7
- package/Libraries/Components/View/ViewPropTypes.js +3 -8
- package/Libraries/Components/View/ViewPropTypes.win32.js +3 -8
- package/Libraries/Components/View/ViewWin32.Props.d.ts +1 -1
- package/Libraries/Components/View/ViewWin32.Props.js.map +1 -1
- package/Libraries/Core/ExceptionsManager.js +2 -0
- package/Libraries/Core/ReactNativeVersion.js +1 -1
- package/Libraries/Core/Timers/JSTimers.js +2 -2
- package/Libraries/Core/polyfillPromise.js +0 -32
- package/Libraries/Core/setUpBatchedBridge.js +5 -1
- package/Libraries/Core/setUpPerformance.js +1 -1
- package/Libraries/EventEmitter/NativeEventEmitter.js +0 -13
- package/Libraries/Image/AssetSourceResolver.js +2 -2
- package/Libraries/Image/Image.android.js +5 -3
- package/Libraries/Image/Image.ios.js +6 -3
- package/Libraries/Image/Image.win32.js +6 -3
- package/Libraries/Image/ImageSource.js +7 -5
- package/Libraries/Inspector/ElementBox.js +2 -2
- package/Libraries/Inspector/NetworkOverlay.js +13 -8
- package/Libraries/Interaction/PanResponder.js +16 -14
- package/Libraries/Linking/Linking.js +0 -11
- package/Libraries/Lists/FlatList.js +3 -2
- package/Libraries/Lists/SectionList.js +2 -0
- package/Libraries/Lists/ViewabilityHelper.js +7 -3
- package/Libraries/Lists/VirtualizeUtils.js +33 -20
- package/Libraries/Lists/VirtualizedList.js +93 -47
- package/Libraries/Lists/VirtualizedListContext.js +1 -0
- package/Libraries/Lists/VirtualizedSectionList.js +14 -9
- package/Libraries/Lists/__tests__/VirtualizeUtils-test.js +19 -18
- package/Libraries/Lists/__tests__/VirtualizedList-test.js +10 -6
- package/Libraries/LogBox/Data/LogBoxData.js +1 -1
- package/Libraries/LogBox/Data/parseLogBoxLog.js +1 -1
- package/Libraries/LogBox/LogBox.js +3 -1
- package/Libraries/LogBox/UI/AnsiHighlight.js +2 -0
- package/Libraries/LogBox/UI/LogBoxInspectorCodeFrame.js +3 -0
- package/Libraries/LogBox/UI/LogBoxInspectorSourceMapStatus.js +0 -3
- package/Libraries/LogBox/UI/LogBoxInspectorStackFrames.js +8 -3
- package/Libraries/NativeComponent/BaseViewConfig.android.js +9 -18
- package/Libraries/NativeComponent/BaseViewConfig.ios.js +26 -12
- package/Libraries/NativeComponent/BaseViewConfig.win32.js +26 -12
- package/Libraries/Network/XMLHttpRequest.js +9 -11
- package/Libraries/Performance/PureComponentDebug.js +1 -0
- package/Libraries/PermissionsAndroid/NativePermissionsAndroid.js +9 -1
- package/Libraries/PermissionsAndroid/PermissionsAndroid.js +16 -0
- package/Libraries/Pressability/Pressability.js +26 -16
- package/Libraries/Pressability/Pressability.win32.js +26 -16
- package/Libraries/Promise.js +0 -1
- package/Libraries/ReactNative/AppRegistry.js +16 -13
- package/Libraries/ReactNative/BridgelessUIManager.js +2 -0
- package/Libraries/ReactNative/PaperUIManager.js +9 -9
- package/Libraries/ReactNative/PaperUIManager.win32.js +7 -8
- package/Libraries/ReactNative/ReactNativeFeatureFlags.js +12 -0
- package/Libraries/ReactNative/ReactNativeRuntimeDiagnostics.js +68 -0
- package/Libraries/ReactNative/getNativeComponentAttributes.js +6 -7
- package/Libraries/ReactNative/renderApplication.js +1 -1
- package/Libraries/Renderer/implementations/ReactFabric-dev.js +4443 -3615
- package/Libraries/Renderer/implementations/ReactFabric-prod.js +1496 -1170
- package/Libraries/Renderer/implementations/ReactFabric-profiling.js +1694 -1356
- package/Libraries/Renderer/implementations/ReactNativeRenderer-dev.js +4439 -3588
- package/Libraries/Renderer/implementations/ReactNativeRenderer-prod.js +1583 -1249
- package/Libraries/Renderer/implementations/ReactNativeRenderer-profiling.js +1719 -1372
- package/Libraries/Storage/AsyncStorage.js +7 -1
- package/Libraries/StyleSheet/PlatformColorValueTypes.ios.js +8 -0
- package/Libraries/StyleSheet/flattenStyle.js +1 -1
- package/Libraries/StyleSheet/processTransform.js +2 -0
- package/Libraries/StyleSheet/splitLayoutProps.js +2 -0
- package/Libraries/Text/Text.js +15 -7
- package/Libraries/Types/CoreEventTypes.js +137 -11
- package/Libraries/Types/CoreEventTypes.win32.js +147 -22
- package/Libraries/Utilities/Dimensions.js +0 -13
- package/Libraries/Utilities/Dimensions.win32.js +0 -9
- package/Libraries/Utilities/HMRClient.js +3 -3
- package/Libraries/Utilities/Platform.ios.js +0 -7
- package/Libraries/Utilities/ReactNativeTestTools.js +3 -1
- package/Libraries/Utilities/codegenNativeCommands.js +11 -2
- package/Libraries/Utilities/deepFreezeAndThrowOnMutationInDev.js +2 -0
- package/Libraries/Utilities/stringifySafe.js +3 -1
- package/Libraries/Utilities/truncate.js +1 -1
- package/Libraries/Utilities/verifyComponentAttributeEquivalence.js +2 -2
- package/Libraries/Vibration/Vibration.js +1 -1
- package/Libraries/WebSocket/WebSocket.js +1 -0
- package/Libraries/vendor/emitter/EventEmitter.js +105 -12
- package/Libraries/vendor/emitter/__flowtests__/EventEmitter-flowtest.js +73 -117
- package/flow/JSITimerInternalType.js +30 -0
- package/jest/assetFileTransformer.js +3 -2
- package/jest/setup.js +4 -0
- package/jest.config.js +0 -1
- package/overrides.json +23 -16
- package/package.json +21 -22
- package/rntypes/index.d.ts +0 -1
- package/src/Libraries/Components/View/ViewWin32.Props.ts +2 -1
- package/src/rntypes/index.d.ts +0 -1
- package/Libraries/vendor/emitter/EventSubscription.js +0 -19
- package/Libraries/vendor/emitter/_EmitterSubscription.js +0 -62
- package/Libraries/vendor/emitter/_EventEmitter.js +0 -184
- package/Libraries/vendor/emitter/_EventSubscription.js +0 -45
- package/Libraries/vendor/emitter/_EventSubscriptionVendor.js +0 -108
- package/jest/preprocessor.js +0 -40
- package/jest/preprocessor_DO_NOT_USE.js +0 -122
- package/src/Libraries/Lists/__tests__/__snapshots__/VirtualizeUtils-test.js.snap +0 -3
|
@@ -88,22 +88,23 @@ type Props = $ReadOnly<{|
|
|
|
88
88
|
|
|
89
89
|
class InputAccessoryView extends React.Component<Props> {
|
|
90
90
|
render(): React.Node {
|
|
91
|
-
if (Platform.OS
|
|
92
|
-
|
|
93
|
-
|
|
91
|
+
if (Platform.OS === 'ios') {
|
|
92
|
+
if (React.Children.count(this.props.children) === 0) {
|
|
93
|
+
return null;
|
|
94
|
+
}
|
|
94
95
|
|
|
95
|
-
|
|
96
|
+
return (
|
|
97
|
+
<RCTInputAccessoryViewNativeComponent
|
|
98
|
+
style={[this.props.style, styles.container]}
|
|
99
|
+
nativeID={this.props.nativeID}
|
|
100
|
+
backgroundColor={this.props.backgroundColor}>
|
|
101
|
+
{this.props.children}
|
|
102
|
+
</RCTInputAccessoryViewNativeComponent>
|
|
103
|
+
);
|
|
104
|
+
} else {
|
|
105
|
+
console.warn('<InputAccessoryView> is only supported on iOS.');
|
|
96
106
|
return null;
|
|
97
107
|
}
|
|
98
|
-
|
|
99
|
-
return (
|
|
100
|
-
<RCTInputAccessoryViewNativeComponent
|
|
101
|
-
style={[this.props.style, styles.container]}
|
|
102
|
-
nativeID={this.props.nativeID}
|
|
103
|
-
backgroundColor={this.props.backgroundColor}>
|
|
104
|
-
{this.props.children}
|
|
105
|
-
</RCTInputAccessoryViewNativeComponent>
|
|
106
|
-
);
|
|
107
108
|
}
|
|
108
109
|
}
|
|
109
110
|
|
|
@@ -392,6 +392,14 @@ type AndroidProps = $ReadOnly<{|
|
|
|
392
392
|
| 'off'
|
|
393
393
|
),
|
|
394
394
|
|
|
395
|
+
/**
|
|
396
|
+
* When provided it will set the color of the cursor (or "caret") in the component.
|
|
397
|
+
* Unlike the behavior of `selectionColor` the cursor color will be set independently
|
|
398
|
+
* from the color of the text selection box.
|
|
399
|
+
* @platform android
|
|
400
|
+
*/
|
|
401
|
+
cursorColor?: ?ColorValue,
|
|
402
|
+
|
|
395
403
|
/**
|
|
396
404
|
* When `false`, if there is a small amount of space available around a text input
|
|
397
405
|
* (e.g. landscape orientation on a phone), the OS may choose to have the user edit
|
|
@@ -968,6 +976,8 @@ function InternalTextInput(props: Props): React.Node {
|
|
|
968
976
|
const text =
|
|
969
977
|
typeof props.value === 'string'
|
|
970
978
|
? props.value
|
|
979
|
+
: typeof lastNativeText === 'string'
|
|
980
|
+
? lastNativeText
|
|
971
981
|
: typeof props.defaultValue === 'string'
|
|
972
982
|
? props.defaultValue
|
|
973
983
|
: '';
|
|
@@ -976,7 +986,7 @@ function InternalTextInput(props: Props): React.Node {
|
|
|
976
986
|
// that the update should be ignored and we should stick with the value
|
|
977
987
|
// that we have in JS.
|
|
978
988
|
useLayoutEffect(() => {
|
|
979
|
-
const nativeUpdate = {};
|
|
989
|
+
const nativeUpdate: {text?: string, selection?: Selection} = {};
|
|
980
990
|
|
|
981
991
|
if (lastNativeText !== props.value && typeof props.value === 'string') {
|
|
982
992
|
nativeUpdate.text = props.value;
|
|
@@ -1225,7 +1235,7 @@ function InternalTextInput(props: Props): React.Node {
|
|
|
1225
1235
|
|
|
1226
1236
|
const style =
|
|
1227
1237
|
props.multiline === true
|
|
1228
|
-
? [styles.multilineInput, props.style]
|
|
1238
|
+
? StyleSheet.flatten([styles.multilineInput, props.style])
|
|
1229
1239
|
: props.style;
|
|
1230
1240
|
|
|
1231
1241
|
const useOnChangeSync =
|
|
@@ -18,7 +18,9 @@ import invariant from 'invariant';
|
|
|
18
18
|
* the Class itself, not an instance. If any others are needed, simply add them
|
|
19
19
|
* here, or in their own files.
|
|
20
20
|
*/
|
|
21
|
-
|
|
21
|
+
/* $FlowFixMe[missing-this-annot] The 'this' type annotation(s) required by
|
|
22
|
+
* Flow's LTI update could not be added via codemod */
|
|
23
|
+
const oneArgumentPooler = function (copyFieldsFrom: any) {
|
|
22
24
|
const Klass = this; // eslint-disable-line consistent-this
|
|
23
25
|
if (Klass.instancePool.length) {
|
|
24
26
|
const instance = Klass.instancePool.pop();
|
|
@@ -29,7 +31,9 @@ const oneArgumentPooler = function (copyFieldsFrom) {
|
|
|
29
31
|
}
|
|
30
32
|
};
|
|
31
33
|
|
|
32
|
-
|
|
34
|
+
/* $FlowFixMe[missing-this-annot] The 'this' type annotation(s) required by
|
|
35
|
+
* Flow's LTI update could not be added via codemod */
|
|
36
|
+
const twoArgumentPooler = function (a1: any, a2: any) {
|
|
33
37
|
const Klass = this; // eslint-disable-line consistent-this
|
|
34
38
|
if (Klass.instancePool.length) {
|
|
35
39
|
const instance = Klass.instancePool.pop();
|
|
@@ -40,7 +44,9 @@ const twoArgumentPooler = function (a1, a2) {
|
|
|
40
44
|
}
|
|
41
45
|
};
|
|
42
46
|
|
|
43
|
-
|
|
47
|
+
/* $FlowFixMe[missing-this-annot] The 'this' type annotation(s) required by
|
|
48
|
+
* Flow's LTI update could not be added via codemod */
|
|
49
|
+
const threeArgumentPooler = function (a1: any, a2: any, a3: any) {
|
|
44
50
|
const Klass = this; // eslint-disable-line consistent-this
|
|
45
51
|
if (Klass.instancePool.length) {
|
|
46
52
|
const instance = Klass.instancePool.pop();
|
|
@@ -51,7 +57,9 @@ const threeArgumentPooler = function (a1, a2, a3) {
|
|
|
51
57
|
}
|
|
52
58
|
};
|
|
53
59
|
|
|
54
|
-
|
|
60
|
+
/* $FlowFixMe[missing-this-annot] The 'this' type annotation(s) required by
|
|
61
|
+
* Flow's LTI update could not be added via codemod */
|
|
62
|
+
const fourArgumentPooler = function (a1: any, a2: any, a3: any, a4: any) {
|
|
55
63
|
const Klass = this; // eslint-disable-line consistent-this
|
|
56
64
|
if (Klass.instancePool.length) {
|
|
57
65
|
const instance = Klass.instancePool.pop();
|
|
@@ -62,6 +70,10 @@ const fourArgumentPooler = function (a1, a2, a3, a4) {
|
|
|
62
70
|
}
|
|
63
71
|
};
|
|
64
72
|
|
|
73
|
+
/* $FlowFixMe[missing-local-annot] The type annotation(s) required by Flow's
|
|
74
|
+
* LTI update could not be added via codemod */
|
|
75
|
+
/* $FlowFixMe[missing-this-annot] The 'this' type annotation(s) required by
|
|
76
|
+
* Flow's LTI update could not be added via codemod */
|
|
65
77
|
const standardReleaser = function (instance) {
|
|
66
78
|
const Klass = this; // eslint-disable-line consistent-this
|
|
67
79
|
invariant(
|
|
@@ -21,7 +21,18 @@ import type {ColorValue} from '../../StyleSheet/StyleSheet';
|
|
|
21
21
|
import type {EdgeInsetsProp} from '../../StyleSheet/EdgeInsetsPropType';
|
|
22
22
|
import type {PressEvent} from '../../Types/CoreEventTypes';
|
|
23
23
|
|
|
24
|
-
const extractSingleTouch = nativeEvent
|
|
24
|
+
const extractSingleTouch = (nativeEvent: {
|
|
25
|
+
+changedTouches: $ReadOnlyArray<PressEvent['nativeEvent']>,
|
|
26
|
+
+force?: number,
|
|
27
|
+
+identifier: number,
|
|
28
|
+
+locationX: number,
|
|
29
|
+
+locationY: number,
|
|
30
|
+
+pageX: number,
|
|
31
|
+
+pageY: number,
|
|
32
|
+
+target: ?number,
|
|
33
|
+
+timestamp: number,
|
|
34
|
+
+touches: $ReadOnlyArray<PressEvent['nativeEvent']>,
|
|
35
|
+
}) => {
|
|
25
36
|
const touches = nativeEvent.touches;
|
|
26
37
|
const changedTouches = nativeEvent.changedTouches;
|
|
27
38
|
const hasTouches = touches && touches.length > 0;
|
|
@@ -370,6 +381,8 @@ const TouchableMixin = {
|
|
|
370
381
|
/**
|
|
371
382
|
* Clear all timeouts on unmount
|
|
372
383
|
*/
|
|
384
|
+
/* $FlowFixMe[missing-this-annot] The 'this' type annotation(s) required by
|
|
385
|
+
* Flow's LTI update could not be added via codemod */
|
|
373
386
|
componentWillUnmount: function () {
|
|
374
387
|
this.touchableDelayTimeout && clearTimeout(this.touchableDelayTimeout);
|
|
375
388
|
this.longPressDelayTimeout && clearTimeout(this.longPressDelayTimeout);
|
|
@@ -395,6 +408,8 @@ const TouchableMixin = {
|
|
|
395
408
|
/**
|
|
396
409
|
* Must return true if embedded in a native platform scroll view.
|
|
397
410
|
*/
|
|
411
|
+
/* $FlowFixMe[missing-this-annot] The 'this' type annotation(s) required by
|
|
412
|
+
* Flow's LTI update could not be added via codemod */
|
|
398
413
|
touchableHandleResponderTerminationRequest: function (): any {
|
|
399
414
|
return !this.props.rejectResponderTermination;
|
|
400
415
|
},
|
|
@@ -402,6 +417,8 @@ const TouchableMixin = {
|
|
|
402
417
|
/**
|
|
403
418
|
* Must return true to start the process of `Touchable`.
|
|
404
419
|
*/
|
|
420
|
+
/* $FlowFixMe[missing-this-annot] The 'this' type annotation(s) required by
|
|
421
|
+
* Flow's LTI update could not be added via codemod */
|
|
405
422
|
touchableHandleStartShouldSetResponder: function (): any {
|
|
406
423
|
return !this.props.disabled;
|
|
407
424
|
},
|
|
@@ -418,6 +435,8 @@ const TouchableMixin = {
|
|
|
418
435
|
* @param {SyntheticEvent} e Synthetic event from event system.
|
|
419
436
|
*
|
|
420
437
|
*/
|
|
438
|
+
/* $FlowFixMe[missing-this-annot] The 'this' type annotation(s) required by
|
|
439
|
+
* Flow's LTI update could not be added via codemod */
|
|
421
440
|
touchableHandleResponderGrant: function (e: PressEvent) {
|
|
422
441
|
const dispatchID = e.currentTarget;
|
|
423
442
|
// Since e is used in a callback invoked on another event loop
|
|
@@ -459,6 +478,8 @@ const TouchableMixin = {
|
|
|
459
478
|
/**
|
|
460
479
|
* Place as callback for a DOM element's `onResponderRelease` event.
|
|
461
480
|
*/
|
|
481
|
+
/* $FlowFixMe[missing-this-annot] The 'this' type annotation(s) required by
|
|
482
|
+
* Flow's LTI update could not be added via codemod */
|
|
462
483
|
touchableHandleResponderRelease: function (e: PressEvent) {
|
|
463
484
|
this.pressInLocation = null;
|
|
464
485
|
this._receiveSignal(Signals.RESPONDER_RELEASE, e);
|
|
@@ -467,6 +488,8 @@ const TouchableMixin = {
|
|
|
467
488
|
/**
|
|
468
489
|
* Place as callback for a DOM element's `onResponderTerminate` event.
|
|
469
490
|
*/
|
|
491
|
+
/* $FlowFixMe[missing-this-annot] The 'this' type annotation(s) required by
|
|
492
|
+
* Flow's LTI update could not be added via codemod */
|
|
470
493
|
touchableHandleResponderTerminate: function (e: PressEvent) {
|
|
471
494
|
this.pressInLocation = null;
|
|
472
495
|
this._receiveSignal(Signals.RESPONDER_TERMINATED, e);
|
|
@@ -475,6 +498,8 @@ const TouchableMixin = {
|
|
|
475
498
|
/**
|
|
476
499
|
* Place as callback for a DOM element's `onResponderMove` event.
|
|
477
500
|
*/
|
|
501
|
+
/* $FlowFixMe[missing-this-annot] The 'this' type annotation(s) required by
|
|
502
|
+
* Flow's LTI update could not be added via codemod */
|
|
478
503
|
touchableHandleResponderMove: function (e: PressEvent) {
|
|
479
504
|
// Measurement may not have returned yet.
|
|
480
505
|
if (!this.state.touchable.positionOnActivate) {
|
|
@@ -560,6 +585,8 @@ const TouchableMixin = {
|
|
|
560
585
|
* element that was blurred just prior to this. This can be overridden when
|
|
561
586
|
* using `Touchable.Mixin.withoutDefaultFocusAndBlur`.
|
|
562
587
|
*/
|
|
588
|
+
/* $FlowFixMe[missing-this-annot] The 'this' type annotation(s) required by
|
|
589
|
+
* Flow's LTI update could not be added via codemod */
|
|
563
590
|
touchableHandleFocus: function (e: Event) {
|
|
564
591
|
this.props.onFocus && this.props.onFocus(e);
|
|
565
592
|
},
|
|
@@ -572,6 +599,8 @@ const TouchableMixin = {
|
|
|
572
599
|
* This can be overridden when using
|
|
573
600
|
* `Touchable.Mixin.withoutDefaultFocusAndBlur`.
|
|
574
601
|
*/
|
|
602
|
+
/* $FlowFixMe[missing-this-annot] The 'this' type annotation(s) required by
|
|
603
|
+
* Flow's LTI update could not be added via codemod */
|
|
575
604
|
touchableHandleBlur: function (e: Event) {
|
|
576
605
|
this.props.onBlur && this.props.onBlur(e);
|
|
577
606
|
},
|
|
@@ -652,6 +681,8 @@ const TouchableMixin = {
|
|
|
652
681
|
* @sideeffects
|
|
653
682
|
* @private
|
|
654
683
|
*/
|
|
684
|
+
/* $FlowFixMe[missing-this-annot] The 'this' type annotation(s) required by
|
|
685
|
+
* Flow's LTI update could not be added via codemod */
|
|
655
686
|
_remeasureMetricsOnActivation: function () {
|
|
656
687
|
const responderID = this.state.touchable.responderID;
|
|
657
688
|
if (responderID == null) {
|
|
@@ -665,6 +696,8 @@ const TouchableMixin = {
|
|
|
665
696
|
}
|
|
666
697
|
},
|
|
667
698
|
|
|
699
|
+
/* $FlowFixMe[missing-this-annot] The 'this' type annotation(s) required by
|
|
700
|
+
* Flow's LTI update could not be added via codemod */
|
|
668
701
|
_handleQueryLayout: function (
|
|
669
702
|
l: number,
|
|
670
703
|
t: number,
|
|
@@ -691,11 +724,15 @@ const TouchableMixin = {
|
|
|
691
724
|
);
|
|
692
725
|
},
|
|
693
726
|
|
|
727
|
+
/* $FlowFixMe[missing-this-annot] The 'this' type annotation(s) required by
|
|
728
|
+
* Flow's LTI update could not be added via codemod */
|
|
694
729
|
_handleDelay: function (e: PressEvent) {
|
|
695
730
|
this.touchableDelayTimeout = null;
|
|
696
731
|
this._receiveSignal(Signals.DELAY, e);
|
|
697
732
|
},
|
|
698
733
|
|
|
734
|
+
/* $FlowFixMe[missing-this-annot] The 'this' type annotation(s) required by
|
|
735
|
+
* Flow's LTI update could not be added via codemod */
|
|
699
736
|
_handleLongDelay: function (e: PressEvent) {
|
|
700
737
|
this.longPressDelayTimeout = null;
|
|
701
738
|
const curState = this.state.touchable.touchState;
|
|
@@ -715,6 +752,8 @@ const TouchableMixin = {
|
|
|
715
752
|
* @throws Error if invalid state transition or unrecognized signal.
|
|
716
753
|
* @sideeffects
|
|
717
754
|
*/
|
|
755
|
+
/* $FlowFixMe[missing-this-annot] The 'this' type annotation(s) required by
|
|
756
|
+
* Flow's LTI update could not be added via codemod */
|
|
718
757
|
_receiveSignal: function (signal: Signal, e: PressEvent) {
|
|
719
758
|
const responderID = this.state.touchable.responderID;
|
|
720
759
|
const curState = this.state.touchable.touchState;
|
|
@@ -754,6 +793,8 @@ const TouchableMixin = {
|
|
|
754
793
|
}
|
|
755
794
|
},
|
|
756
795
|
|
|
796
|
+
/* $FlowFixMe[missing-this-annot] The 'this' type annotation(s) required by
|
|
797
|
+
* Flow's LTI update could not be added via codemod */
|
|
757
798
|
_cancelLongPressDelayTimeout: function () {
|
|
758
799
|
this.longPressDelayTimeout && clearTimeout(this.longPressDelayTimeout);
|
|
759
800
|
this.longPressDelayTimeout = null;
|
|
@@ -766,6 +807,8 @@ const TouchableMixin = {
|
|
|
766
807
|
);
|
|
767
808
|
},
|
|
768
809
|
|
|
810
|
+
/* $FlowFixMe[missing-this-annot] The 'this' type annotation(s) required by
|
|
811
|
+
* Flow's LTI update could not be added via codemod */
|
|
769
812
|
_savePressInLocation: function (e: PressEvent) {
|
|
770
813
|
const touch = extractSingleTouch(e.nativeEvent);
|
|
771
814
|
const pageX = touch && touch.pageX;
|
|
@@ -797,6 +840,8 @@ const TouchableMixin = {
|
|
|
797
840
|
* @param {Event} e Native event.
|
|
798
841
|
* @sideeffects
|
|
799
842
|
*/
|
|
843
|
+
/* $FlowFixMe[missing-this-annot] The 'this' type annotation(s) required by
|
|
844
|
+
* Flow's LTI update could not be added via codemod */
|
|
800
845
|
_performSideEffectsForTransition: function (
|
|
801
846
|
curState: State,
|
|
802
847
|
nextState: State,
|
|
@@ -858,11 +903,15 @@ const TouchableMixin = {
|
|
|
858
903
|
this.touchableDelayTimeout = null;
|
|
859
904
|
},
|
|
860
905
|
|
|
906
|
+
/* $FlowFixMe[missing-this-annot] The 'this' type annotation(s) required by
|
|
907
|
+
* Flow's LTI update could not be added via codemod */
|
|
861
908
|
_startHighlight: function (e: PressEvent) {
|
|
862
909
|
this._savePressInLocation(e);
|
|
863
910
|
this.touchableHandleActivePressIn && this.touchableHandleActivePressIn(e);
|
|
864
911
|
},
|
|
865
912
|
|
|
913
|
+
/* $FlowFixMe[missing-this-annot] The 'this' type annotation(s) required by
|
|
914
|
+
* Flow's LTI update could not be added via codemod */
|
|
866
915
|
_endHighlight: function (e: PressEvent) {
|
|
867
916
|
if (this.touchableHandleActivePressOut) {
|
|
868
917
|
if (
|