@office-iss/react-native-win32 0.0.0-canary.264 → 0.0.0-canary.266
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 +61 -7
- package/CHANGELOG.md +28 -8
- package/Libraries/Animated/AnimatedImplementation.js +2 -2
- package/Libraries/Animated/NativeAnimatedAllowlist.js +20 -9
- package/Libraries/Animated/animations/Animation.js +1 -4
- package/Libraries/Animated/createAnimatedComponent.js +13 -0
- package/Libraries/Animated/nodes/AnimatedNode.js +39 -45
- package/Libraries/Animated/nodes/AnimatedObject.js +13 -3
- package/Libraries/Animated/nodes/AnimatedProps.js +81 -37
- package/Libraries/Animated/nodes/AnimatedStyle.js +104 -39
- package/Libraries/Animated/nodes/AnimatedTransform.js +55 -22
- package/Libraries/Animated/nodes/AnimatedWithChildren.js +1 -3
- package/Libraries/Animated/useAnimatedProps.js +38 -20
- package/Libraries/Components/ProgressBarAndroid/ProgressBarAndroid.android.js +3 -1
- package/Libraries/Components/ScrollView/ScrollView.js +12 -9
- package/Libraries/Components/ScrollView/ScrollViewNativeComponent.js +3 -0
- package/Libraries/Components/TextInput/RCTTextInputViewConfig.js +10 -0
- package/Libraries/Components/TextInput/TextInput.d.ts +19 -0
- package/Libraries/Components/TextInput/TextInput.flow.js +17 -1
- package/Libraries/Components/TextInput/TextInput.js +17 -1
- package/Libraries/Components/TextInput/TextInput.win32.js +17 -1
- package/Libraries/Components/Touchable/TouchableBounce.js +1 -1
- package/Libraries/Components/Touchable/TouchableHighlight.js +2 -2
- package/Libraries/Components/Touchable/TouchableOpacity.js +1 -1
- package/Libraries/Components/View/ReactNativeStyleAttributes.js +6 -2
- package/Libraries/Core/ReactNativeVersion.js +2 -2
- package/Libraries/Image/AssetSourceResolver.js +12 -1
- package/Libraries/Modal/Modal.d.ts +7 -0
- package/Libraries/Modal/Modal.js +9 -1
- package/Libraries/NativeComponent/BaseViewConfig.android.js +7 -2
- package/Libraries/NativeComponent/BaseViewConfig.ios.js +11 -2
- package/Libraries/NativeComponent/BaseViewConfig.win32.js +1 -1
- package/Libraries/NativeComponent/StaticViewConfigValidator.js +0 -1
- package/Libraries/ReactNative/AppRegistry.js +2 -6
- package/Libraries/ReactNative/getNativeComponentAttributes.js +4 -0
- package/Libraries/Renderer/shims/ReactNativeTypes.js +3 -3
- package/Libraries/Renderer/shims/ReactNativeViewConfigRegistry.js +5 -6
- package/Libraries/StyleSheet/StyleSheetTypes.d.ts +102 -5
- package/Libraries/StyleSheet/StyleSheetTypes.js +9 -5
- package/Libraries/StyleSheet/processBoxShadow.js +5 -7
- package/Libraries/StyleSheet/processFilter.js +4 -4
- package/Libraries/Text/TextNativeComponent.js +0 -1
- package/Libraries/Utilities/HMRClient.js +5 -5
- package/overrides.json +6 -6
- package/package.json +21 -19
- package/src/private/animated/NativeAnimatedHelper.js +12 -8
- package/src/private/animated/NativeAnimatedHelper.win32.js +12 -8
- package/src/private/animated/useAnimatedPropsMemo.js +349 -0
- package/src/private/components/HScrollViewNativeComponents.js +9 -8
- package/src/private/components/SafeAreaView_INTERNAL_DO_NOT_USE.js +13 -9
- package/src/private/components/VScrollViewNativeComponents.js +9 -8
- package/src/private/featureflags/ReactNativeFeatureFlags.js +50 -22
- package/src/private/featureflags/ReactNativeFeatureFlagsBase.js +8 -2
- package/src/private/featureflags/specs/NativeReactNativeFeatureFlags.js +7 -4
- package/src/private/webapis/dom/geometry/DOMRect.js +2 -2
- package/src/private/webapis/dom/geometry/DOMRectReadOnly.js +2 -2
- package/types/experimental.d.ts +0 -105
- package/types/modules/Codegen.d.ts +6 -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
|
-
* @flow strict
|
|
7
|
+
* @flow strict
|
|
8
8
|
* @format
|
|
9
9
|
*/
|
|
10
10
|
|
|
@@ -20,6 +20,12 @@ let overrides: ?ReactNativeFeatureFlagsJsOnlyOverrides;
|
|
|
20
20
|
|
|
21
21
|
export type Getter<T> = () => T;
|
|
22
22
|
|
|
23
|
+
// This defines the types for the overrides object, whose methods also receive
|
|
24
|
+
// the default value as a parameter.
|
|
25
|
+
export type OverridesFor<T> = Partial<{
|
|
26
|
+
[key in keyof T]: (ReturnType<T[key]>) => ReturnType<T[key]>,
|
|
27
|
+
}>;
|
|
28
|
+
|
|
23
29
|
function createGetter<T: boolean | number | string>(
|
|
24
30
|
configName: string,
|
|
25
31
|
customValueGetter: Getter<?T>,
|
|
@@ -45,7 +51,7 @@ export function createJavaScriptFlagGetter<
|
|
|
45
51
|
configName,
|
|
46
52
|
() => {
|
|
47
53
|
accessedFeatureFlags.add(configName);
|
|
48
|
-
return overrides?.[configName]?.();
|
|
54
|
+
return overrides?.[configName]?.(defaultValue);
|
|
49
55
|
},
|
|
50
56
|
defaultValue,
|
|
51
57
|
);
|
|
@@ -4,8 +4,8 @@
|
|
|
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<<
|
|
8
|
-
* @flow strict
|
|
7
|
+
* @generated SignedSource<<ee3f60941427d4efa2f5b03bf0b78514>>
|
|
8
|
+
* @flow strict
|
|
9
9
|
*/
|
|
10
10
|
|
|
11
11
|
/**
|
|
@@ -29,9 +29,11 @@ export interface Spec extends TurboModule {
|
|
|
29
29
|
+completeReactInstanceCreationOnBgThreadOnAndroid?: () => boolean;
|
|
30
30
|
+destroyFabricSurfacesInReactInstanceManager?: () => boolean;
|
|
31
31
|
+enableAlignItemsBaselineOnFabricIOS?: () => boolean;
|
|
32
|
+
+enableAndroidLineHeightCentering?: () => boolean;
|
|
32
33
|
+enableAndroidMixBlendModeProp?: () => boolean;
|
|
33
34
|
+enableBackgroundStyleApplicator?: () => boolean;
|
|
34
35
|
+enableCleanTextInputYogaNode?: () => boolean;
|
|
36
|
+
+enableDeletionOfUnmountedViews?: () => boolean;
|
|
35
37
|
+enableEagerRootViewAttachment?: () => boolean;
|
|
36
38
|
+enableEventEmitterRetentionDuringGesturesOnAndroid?: () => boolean;
|
|
37
39
|
+enableFabricLogs?: () => boolean;
|
|
@@ -41,16 +43,16 @@ export interface Spec extends TurboModule {
|
|
|
41
43
|
+enableLayoutAnimationsOnIOS?: () => boolean;
|
|
42
44
|
+enableLongTaskAPI?: () => boolean;
|
|
43
45
|
+enableMicrotasks?: () => boolean;
|
|
46
|
+
+enablePreciseSchedulingForPremountItemsOnAndroid?: () => boolean;
|
|
44
47
|
+enablePropsUpdateReconciliationAndroid?: () => boolean;
|
|
45
48
|
+enableReportEventPaintTime?: () => boolean;
|
|
46
49
|
+enableSynchronousStateUpdates?: () => boolean;
|
|
50
|
+
+enableTextPreallocationOptimisation?: () => boolean;
|
|
47
51
|
+enableUIConsistency?: () => boolean;
|
|
48
52
|
+enableViewRecycling?: () => boolean;
|
|
49
53
|
+excludeYogaFromRawProps?: () => boolean;
|
|
50
54
|
+fetchImagesInViewPreallocation?: () => boolean;
|
|
51
|
-
+fixIncorrectScrollViewStateUpdateOnAndroid?: () => boolean;
|
|
52
55
|
+fixMappingOfEventPrioritiesBetweenFabricAndReact?: () => boolean;
|
|
53
|
-
+fixMissedFabricStateUpdatesOnAndroid?: () => boolean;
|
|
54
56
|
+fixMountingCoordinatorReportedPendingTransactionsOnAndroid?: () => boolean;
|
|
55
57
|
+forceBatchingMountItemsOnAndroid?: () => boolean;
|
|
56
58
|
+fuseboxEnabledDebug?: () => boolean;
|
|
@@ -58,6 +60,7 @@ export interface Spec extends TurboModule {
|
|
|
58
60
|
+initEagerTurboModulesOnNativeModulesQueueAndroid?: () => boolean;
|
|
59
61
|
+lazyAnimationCallbacks?: () => boolean;
|
|
60
62
|
+loadVectorDrawablesOnImages?: () => boolean;
|
|
63
|
+
+removeNestedCallsToDispatchMountItemsOnAndroid?: () => boolean;
|
|
61
64
|
+setAndroidLayoutDirection?: () => boolean;
|
|
62
65
|
+traceTurboModulePromiseRejectionsOnAndroid?: () => boolean;
|
|
63
66
|
+useFabricInterop?: () => boolean;
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
* licensed under [CC-BY-SA 2.5](https://creativecommons.org/licenses/by-sa/2.5/).
|
|
15
15
|
*/
|
|
16
16
|
|
|
17
|
-
import DOMRectReadOnly, {type
|
|
17
|
+
import DOMRectReadOnly, {type DOMRectInit} from './DOMRectReadOnly';
|
|
18
18
|
|
|
19
19
|
// flowlint unsafe-getters-setters:off
|
|
20
20
|
|
|
@@ -72,7 +72,7 @@ export default class DOMRect extends DOMRectReadOnly {
|
|
|
72
72
|
/**
|
|
73
73
|
* Creates a new `DOMRect` object with a given location and dimensions.
|
|
74
74
|
*/
|
|
75
|
-
static fromRect(rect?: ?
|
|
75
|
+
static fromRect(rect?: ?DOMRectInit): DOMRect {
|
|
76
76
|
if (!rect) {
|
|
77
77
|
return new DOMRect();
|
|
78
78
|
}
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
|
|
17
17
|
// flowlint sketchy-null:off, unsafe-getters-setters:off
|
|
18
18
|
|
|
19
|
-
export interface
|
|
19
|
+
export interface DOMRectInit {
|
|
20
20
|
x?: ?number;
|
|
21
21
|
y?: ?number;
|
|
22
22
|
width?: ?number;
|
|
@@ -146,7 +146,7 @@ export default class DOMRectReadOnly {
|
|
|
146
146
|
/**
|
|
147
147
|
* Creates a new `DOMRectReadOnly` object with a given location and dimensions.
|
|
148
148
|
*/
|
|
149
|
-
static fromRect(rect?: ?
|
|
149
|
+
static fromRect(rect?: ?DOMRectInit): DOMRectReadOnly {
|
|
150
150
|
if (!rect) {
|
|
151
151
|
return new DOMRectReadOnly();
|
|
152
152
|
}
|
package/types/experimental.d.ts
CHANGED
|
@@ -35,111 +35,11 @@
|
|
|
35
35
|
import {
|
|
36
36
|
GradientValue,
|
|
37
37
|
BlendMode,
|
|
38
|
-
BoxShadowPrimitive,
|
|
39
|
-
DimensionValue,
|
|
40
|
-
FilterFunction,
|
|
41
38
|
} from 'react-native/Libraries/StyleSheet/StyleSheetTypes';
|
|
42
39
|
|
|
43
40
|
export {};
|
|
44
41
|
|
|
45
42
|
declare module '.' {
|
|
46
|
-
export interface FlexStyle {
|
|
47
|
-
/**
|
|
48
|
-
* Equivalent to `top`, `bottom`, `right` and `left`
|
|
49
|
-
*/
|
|
50
|
-
inset?: DimensionValue | undefined;
|
|
51
|
-
|
|
52
|
-
/**
|
|
53
|
-
* Equivalent to `top`, `bottom`
|
|
54
|
-
*/
|
|
55
|
-
insetBlock?: DimensionValue | undefined;
|
|
56
|
-
|
|
57
|
-
/**
|
|
58
|
-
* Equivalent to `bottom`
|
|
59
|
-
*/
|
|
60
|
-
insetBlockEnd?: DimensionValue | undefined;
|
|
61
|
-
|
|
62
|
-
/**
|
|
63
|
-
* Equivalent to `top`
|
|
64
|
-
*/
|
|
65
|
-
insetBlockStart?: DimensionValue | undefined;
|
|
66
|
-
|
|
67
|
-
/**
|
|
68
|
-
* Equivalent to `right` and `left`
|
|
69
|
-
*/
|
|
70
|
-
insetInline?: DimensionValue | undefined;
|
|
71
|
-
|
|
72
|
-
/**
|
|
73
|
-
* Equivalent to `right` or `left`
|
|
74
|
-
*/
|
|
75
|
-
insetInlineEnd?: DimensionValue | undefined;
|
|
76
|
-
|
|
77
|
-
/**
|
|
78
|
-
* Equivalent to `right` or `left`
|
|
79
|
-
*/
|
|
80
|
-
insetInlineStart?: DimensionValue | undefined;
|
|
81
|
-
|
|
82
|
-
/**
|
|
83
|
-
* Equivalent to `marginVertical`
|
|
84
|
-
*/
|
|
85
|
-
marginBlock?: DimensionValue | undefined;
|
|
86
|
-
|
|
87
|
-
/**
|
|
88
|
-
* Equivalent to `marginBottom`
|
|
89
|
-
*/
|
|
90
|
-
marginBlockEnd?: DimensionValue | undefined;
|
|
91
|
-
|
|
92
|
-
/**
|
|
93
|
-
* Equivalent to `marginTop`
|
|
94
|
-
*/
|
|
95
|
-
marginBlockStart?: DimensionValue | undefined;
|
|
96
|
-
|
|
97
|
-
/**
|
|
98
|
-
* Equivalent to `marginHorizontal`
|
|
99
|
-
*/
|
|
100
|
-
marginInline?: DimensionValue | undefined;
|
|
101
|
-
|
|
102
|
-
/**
|
|
103
|
-
* Equivalent to `marginEnd`
|
|
104
|
-
*/
|
|
105
|
-
marginInlineEnd?: DimensionValue | undefined;
|
|
106
|
-
|
|
107
|
-
/**
|
|
108
|
-
* Equivalent to `marginStart`
|
|
109
|
-
*/
|
|
110
|
-
marginInlineStart?: DimensionValue | undefined;
|
|
111
|
-
|
|
112
|
-
/**
|
|
113
|
-
* Equivalent to `paddingVertical`
|
|
114
|
-
*/
|
|
115
|
-
paddingBlock?: DimensionValue | undefined;
|
|
116
|
-
|
|
117
|
-
/**
|
|
118
|
-
* Equivalent to `paddingBottom`
|
|
119
|
-
*/
|
|
120
|
-
paddingBlockEnd?: DimensionValue | undefined;
|
|
121
|
-
|
|
122
|
-
/**
|
|
123
|
-
* Equivalent to `paddingTop`
|
|
124
|
-
*/
|
|
125
|
-
paddingBlockStart?: DimensionValue | undefined;
|
|
126
|
-
|
|
127
|
-
/**
|
|
128
|
-
* Equivalent to `paddingHorizontal`
|
|
129
|
-
*/
|
|
130
|
-
paddingInline?: DimensionValue | undefined;
|
|
131
|
-
|
|
132
|
-
/**
|
|
133
|
-
* Equivalent to `paddingEnd`
|
|
134
|
-
*/
|
|
135
|
-
paddingInlineEnd?: DimensionValue | undefined;
|
|
136
|
-
|
|
137
|
-
/**
|
|
138
|
-
* Equivalent to `paddingStart`
|
|
139
|
-
*/
|
|
140
|
-
paddingInlineStart?: DimensionValue | undefined;
|
|
141
|
-
}
|
|
142
|
-
|
|
143
43
|
export interface ViewProps {
|
|
144
44
|
/**
|
|
145
45
|
* Contols whether this view, and its transitive children, are laid in a way
|
|
@@ -150,11 +50,6 @@ declare module '.' {
|
|
|
150
50
|
}
|
|
151
51
|
|
|
152
52
|
export interface ViewStyle {
|
|
153
|
-
experimental_boxShadow?:
|
|
154
|
-
| ReadonlyArray<BoxShadowPrimitive>
|
|
155
|
-
| string
|
|
156
|
-
| undefined;
|
|
157
|
-
experimental_filter?: ReadonlyArray<FilterFunction> | string | undefined;
|
|
158
53
|
experimental_mixBlendMode?: BlendMode | undefined;
|
|
159
54
|
experimental_backgroundImage?:
|
|
160
55
|
| ReadonlyArray<GradientValue>
|
|
@@ -41,6 +41,7 @@ declare module 'react-native/Libraries/Utilities/codegenNativeComponent' {
|
|
|
41
41
|
|
|
42
42
|
declare module 'react-native/Libraries/Types/CodegenTypes' {
|
|
43
43
|
import type {NativeSyntheticEvent} from 'react-native';
|
|
44
|
+
import type {EventSubscription} from 'react-native/Libraries/vendor/emitter/EventEmitter';
|
|
44
45
|
|
|
45
46
|
// Event types
|
|
46
47
|
// We're not using the PaperName, it is only used to codegen view config settings
|
|
@@ -59,6 +60,7 @@ declare module 'react-native/Libraries/Types/CodegenTypes' {
|
|
|
59
60
|
export type Float = number;
|
|
60
61
|
export type Int32 = number;
|
|
61
62
|
export type UnsafeObject = object;
|
|
63
|
+
export type UnsafeMixed = unknown;
|
|
62
64
|
|
|
63
65
|
type DefaultTypes = number | boolean | string | ReadonlyArray<string>;
|
|
64
66
|
// Default handling, ignore the unused value
|
|
@@ -71,4 +73,8 @@ declare module 'react-native/Libraries/Types/CodegenTypes' {
|
|
|
71
73
|
Type extends DefaultTypes,
|
|
72
74
|
Value extends Type | string | undefined | null,
|
|
73
75
|
> = Type | undefined | null;
|
|
76
|
+
|
|
77
|
+
export type EventEmitter<T> = (
|
|
78
|
+
handler: (arg: T) => void | Promise<void>,
|
|
79
|
+
) => EventSubscription;
|
|
74
80
|
}
|