@office-iss/react-native-win32 0.0.0-canary.245 → 0.0.0-canary.247
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 +100 -1
- package/CHANGELOG.md +33 -8
- package/Libraries/Animated/createAnimatedComponent.js +20 -3
- package/Libraries/Components/ScrollView/ScrollViewStickyHeader.js +13 -1
- package/Libraries/Components/TextInput/TextInput.win32.js +2 -2
- package/Libraries/Components/Touchable/TouchableHighlight.d.ts +4 -10
- package/Libraries/Components/Touchable/TouchableOpacity.d.ts +4 -15
- package/Libraries/Core/Devtools/loadBundleFromServer.js +3 -3
- package/Libraries/Core/ErrorHandlers.js +116 -0
- package/Libraries/Core/ReactNativeVersion.js +1 -1
- package/Libraries/Core/setUpReactDevTools.js +70 -10
- package/Libraries/Debugging/DebuggingOverlayRegistry.js +1 -1
- package/Libraries/Inspector/ElementBox.js +2 -3
- package/Libraries/NativeComponent/NativeComponentRegistry.js +12 -5
- package/Libraries/ReactNative/BridgelessUIManager.js +1 -21
- package/Libraries/ReactNative/RendererImplementation.js +20 -2
- package/Libraries/ReactNative/UIManager.d.ts +0 -21
- package/Libraries/ReactNative/UIManagerProperties.js +0 -3
- package/Libraries/ReactNative/getNativeComponentAttributes.js +3 -6
- package/Libraries/Renderer/shims/ReactFabric.js +3 -0
- package/Libraries/Renderer/shims/ReactFeatureFlags.js +3 -0
- package/Libraries/Renderer/shims/ReactNative.js +3 -0
- package/Libraries/Renderer/shims/ReactNativeTypes.js +25 -1
- package/Libraries/Renderer/shims/ReactNativeViewConfigRegistry.js +3 -0
- package/Libraries/Renderer/shims/createReactNativeComponentClass.js +3 -0
- package/Libraries/StyleSheet/StyleSheetTypes.d.ts +3 -3
- package/Libraries/StyleSheet/StyleSheetTypes.js +3 -3
- package/Libraries/Utilities/{LoadingView.android.js → DevLoadingView.js} +33 -11
- package/Libraries/Utilities/HMRClient.js +8 -8
- package/overrides.json +2 -8
- package/package.json +17 -16
- package/src/private/featureflags/ReactNativeFeatureFlags.js +16 -6
- package/src/private/featureflags/specs/NativeReactNativeFeatureFlags.js +4 -2
- package/src/private/fusebox/setUpFuseboxReactDevToolsDispatcher.js +108 -0
- package/src/private/specs/modules/NativeUIManager.js +0 -7
- package/src/private/webapis/performance/PerformanceObserver.js +11 -5
- package/Libraries/Components/ScrollView/ScrollView.win32.js +0 -1983
- package/Libraries/Utilities/LoadingView.ios.js +0 -50
- package/Libraries/Utilities/LoadingView.js +0 -16
|
@@ -12,8 +12,12 @@ import type {HostComponent} from '../Renderer/shims/ReactNativeTypes';
|
|
|
12
12
|
import type ReactFabricHostComponent from './ReactFabricPublicInstance/ReactFabricHostComponent';
|
|
13
13
|
import type {Element, ElementRef, ElementType} from 'react';
|
|
14
14
|
|
|
15
|
+
import {
|
|
16
|
+
onCaughtError,
|
|
17
|
+
onRecoverableError,
|
|
18
|
+
onUncaughtError,
|
|
19
|
+
} from '../Core/ErrorHandlers';
|
|
15
20
|
import {type RootTag} from './RootTag';
|
|
16
|
-
|
|
17
21
|
export function renderElement({
|
|
18
22
|
element,
|
|
19
23
|
rootTag,
|
|
@@ -31,9 +35,23 @@ export function renderElement({
|
|
|
31
35
|
rootTag,
|
|
32
36
|
null,
|
|
33
37
|
useConcurrentRoot,
|
|
38
|
+
{
|
|
39
|
+
onCaughtError,
|
|
40
|
+
onUncaughtError,
|
|
41
|
+
onRecoverableError,
|
|
42
|
+
},
|
|
34
43
|
);
|
|
35
44
|
} else {
|
|
36
|
-
require('../Renderer/shims/ReactNative').render(
|
|
45
|
+
require('../Renderer/shims/ReactNative').render(
|
|
46
|
+
element,
|
|
47
|
+
rootTag,
|
|
48
|
+
undefined,
|
|
49
|
+
{
|
|
50
|
+
onCaughtError,
|
|
51
|
+
onUncaughtError,
|
|
52
|
+
onRecoverableError,
|
|
53
|
+
},
|
|
54
|
+
);
|
|
37
55
|
}
|
|
38
56
|
}
|
|
39
57
|
|
|
@@ -89,27 +89,6 @@ export interface UIManagerStatic {
|
|
|
89
89
|
| ((value: boolean) => void)
|
|
90
90
|
| undefined;
|
|
91
91
|
|
|
92
|
-
/**
|
|
93
|
-
* Used to display an Android PopupMenu. If a menu item is pressed, the success callback will
|
|
94
|
-
* be called with the following arguments:
|
|
95
|
-
*
|
|
96
|
-
* - item - the menu item.
|
|
97
|
-
* - index - index of the pressed item in array. Returns `undefined` if cancelled.
|
|
98
|
-
*
|
|
99
|
-
* To obtain a native node handle for a component, you can use
|
|
100
|
-
* `React.findNodeHandle(component)`.
|
|
101
|
-
*
|
|
102
|
-
* Note that this works only on Android
|
|
103
|
-
*/
|
|
104
|
-
showPopupMenu?:
|
|
105
|
-
| ((
|
|
106
|
-
node: number,
|
|
107
|
-
items: string[],
|
|
108
|
-
error: () => void /* currently unused */,
|
|
109
|
-
success: (item: string, index: number | undefined) => void,
|
|
110
|
-
) => void)
|
|
111
|
-
| undefined;
|
|
112
|
-
|
|
113
92
|
getViewManagerConfig: (name: string) => {
|
|
114
93
|
Commands: {[key: string]: number};
|
|
115
94
|
};
|
|
@@ -30,7 +30,6 @@ module.exports = [
|
|
|
30
30
|
'clearJSResponder',
|
|
31
31
|
'configureNextLayoutAnimation',
|
|
32
32
|
'createView',
|
|
33
|
-
'dismissPopupMenu',
|
|
34
33
|
'dispatchViewManagerCommand',
|
|
35
34
|
'findSubviewIn',
|
|
36
35
|
'getConstantsForViewManager',
|
|
@@ -45,10 +44,8 @@ module.exports = [
|
|
|
45
44
|
'setChildren',
|
|
46
45
|
'setJSResponder',
|
|
47
46
|
'setLayoutAnimationEnabledExperimental',
|
|
48
|
-
'showPopupMenu',
|
|
49
47
|
'updateView',
|
|
50
48
|
'viewIsDescendantOf',
|
|
51
|
-
'PopupMenu',
|
|
52
49
|
'LazyViewManagersEnabled',
|
|
53
50
|
'ViewManagerNames',
|
|
54
51
|
'StyleConstants',
|
|
@@ -19,17 +19,14 @@ const matricesDiffer = require('../Utilities/differ/matricesDiffer');
|
|
|
19
19
|
const pointsDiffer = require('../Utilities/differ/pointsDiffer');
|
|
20
20
|
const sizesDiffer = require('../Utilities/differ/sizesDiffer');
|
|
21
21
|
const UIManager = require('./UIManager');
|
|
22
|
-
const invariant = require('invariant');
|
|
23
22
|
const nullthrows = require('nullthrows');
|
|
24
23
|
|
|
25
24
|
function getNativeComponentAttributes(uiViewClassName: string): any {
|
|
26
25
|
const viewConfig = UIManager.getViewManagerConfig(uiViewClassName);
|
|
27
26
|
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
uiViewClassName,
|
|
32
|
-
);
|
|
27
|
+
if (viewConfig == null) {
|
|
28
|
+
return null;
|
|
29
|
+
}
|
|
33
30
|
|
|
34
31
|
// TODO: This seems like a whole lot of runtime initialization for every
|
|
35
32
|
// native component that can be either avoided or simplified.
|
|
@@ -7,7 +7,10 @@
|
|
|
7
7
|
* @noformat
|
|
8
8
|
* @flow strict
|
|
9
9
|
* @nolint
|
|
10
|
-
* @generated SignedSource<<
|
|
10
|
+
* @generated SignedSource<<c41f61379973354629ee7bf55ba92541>>
|
|
11
|
+
* @generated SignedSource<<39aa3fa373095c6b192fac24f5b6c30c>>
|
|
12
|
+
*
|
|
13
|
+
* This file was sync'd from the facebook/react repository.
|
|
11
14
|
*/
|
|
12
15
|
|
|
13
16
|
import type {ElementRef, ElementType, Element, AbstractComponent} from 'react';
|
|
@@ -176,6 +179,25 @@ export type TouchedViewDataAtPoint = $ReadOnly<{
|
|
|
176
179
|
...InspectorData,
|
|
177
180
|
}>;
|
|
178
181
|
|
|
182
|
+
export type RenderRootOptions = {
|
|
183
|
+
onUncaughtError?: (
|
|
184
|
+
error: mixed,
|
|
185
|
+
errorInfo: {+componentStack?: ?string},
|
|
186
|
+
) => void,
|
|
187
|
+
onCaughtError?: (
|
|
188
|
+
error: mixed,
|
|
189
|
+
errorInfo: {
|
|
190
|
+
+componentStack?: ?string,
|
|
191
|
+
// $FlowFixMe[unclear-type] unknown props and state.
|
|
192
|
+
+errorBoundary?: ?React$Component<any, any>,
|
|
193
|
+
},
|
|
194
|
+
) => void,
|
|
195
|
+
onRecoverableError?: (
|
|
196
|
+
error: mixed,
|
|
197
|
+
errorInfo: {+componentStack?: ?string},
|
|
198
|
+
) => void,
|
|
199
|
+
};
|
|
200
|
+
|
|
179
201
|
/**
|
|
180
202
|
* Flat ReactNative renderer bundles are too big for Flow to parse efficiently.
|
|
181
203
|
* Provide minimal Flow typing for the high-level RN API and call it a day.
|
|
@@ -204,6 +226,7 @@ export type ReactNativeType = {
|
|
|
204
226
|
element: Element<ElementType>,
|
|
205
227
|
containerTag: number,
|
|
206
228
|
callback: ?() => void,
|
|
229
|
+
options: ?RenderRootOptions,
|
|
207
230
|
): ?ElementRef<ElementType>,
|
|
208
231
|
unmountComponentAtNode(containerTag: number): void,
|
|
209
232
|
unmountComponentAtNodeAndRemoveContainer(containerTag: number): void,
|
|
@@ -239,6 +262,7 @@ export type ReactFabricType = {
|
|
|
239
262
|
containerTag: number,
|
|
240
263
|
callback: ?() => void,
|
|
241
264
|
concurrentRoot: ?boolean,
|
|
265
|
+
options: ?RenderRootOptions,
|
|
242
266
|
): ?ElementRef<ElementType>,
|
|
243
267
|
unmountComponentAtNode(containerTag: number): void,
|
|
244
268
|
getNodeFromInternalInstanceHandle(
|
|
@@ -65,9 +65,9 @@ export interface FlexStyle {
|
|
|
65
65
|
| 'row-reverse'
|
|
66
66
|
| 'column-reverse'
|
|
67
67
|
| undefined;
|
|
68
|
-
rowGap?: number | undefined;
|
|
69
|
-
gap?: number | undefined;
|
|
70
|
-
columnGap?: number | undefined;
|
|
68
|
+
rowGap?: number | string | undefined;
|
|
69
|
+
gap?: number | string | undefined;
|
|
70
|
+
columnGap?: number | string | undefined;
|
|
71
71
|
flexGrow?: number | undefined;
|
|
72
72
|
flexShrink?: number | undefined;
|
|
73
73
|
flexWrap?: 'wrap' | 'nowrap' | 'wrap-reverse' | undefined;
|
|
@@ -644,9 +644,9 @@ type ____LayoutStyle_Internal = $ReadOnly<{
|
|
|
644
644
|
* between children may be larger than the gap value.
|
|
645
645
|
* See https://developer.mozilla.org/en-US/docs/Web/CSS/gap for more details.
|
|
646
646
|
*/
|
|
647
|
-
rowGap?: number,
|
|
648
|
-
columnGap?: number,
|
|
649
|
-
gap?: number,
|
|
647
|
+
rowGap?: number | string,
|
|
648
|
+
columnGap?: number | string,
|
|
649
|
+
gap?: number | string,
|
|
650
650
|
}>;
|
|
651
651
|
|
|
652
652
|
/**
|
|
@@ -12,23 +12,45 @@ import processColor from '../StyleSheet/processColor';
|
|
|
12
12
|
import Appearance from './Appearance';
|
|
13
13
|
import NativeDevLoadingView from './NativeDevLoadingView';
|
|
14
14
|
|
|
15
|
+
const COLOR_SCHEME = {
|
|
16
|
+
dark: {
|
|
17
|
+
refresh: {
|
|
18
|
+
backgroundColor: '#2584e8',
|
|
19
|
+
textColor: '#ffffff',
|
|
20
|
+
},
|
|
21
|
+
load: {
|
|
22
|
+
backgroundColor: '#fafafa',
|
|
23
|
+
textColor: '#242526',
|
|
24
|
+
},
|
|
25
|
+
},
|
|
26
|
+
default: {
|
|
27
|
+
refresh: {
|
|
28
|
+
backgroundColor: '#2584e8',
|
|
29
|
+
textColor: '#ffffff',
|
|
30
|
+
},
|
|
31
|
+
load: {
|
|
32
|
+
backgroundColor: '#404040',
|
|
33
|
+
textColor: '#ffffff',
|
|
34
|
+
},
|
|
35
|
+
},
|
|
36
|
+
};
|
|
37
|
+
|
|
15
38
|
module.exports = {
|
|
16
39
|
showMessage(message: string, type: 'load' | 'refresh') {
|
|
17
40
|
if (NativeDevLoadingView) {
|
|
41
|
+
const colorScheme =
|
|
42
|
+
Appearance.getColorScheme() === 'dark'
|
|
43
|
+
? COLOR_SCHEME.dark
|
|
44
|
+
: COLOR_SCHEME.default;
|
|
45
|
+
|
|
46
|
+
const colorSet = colorScheme[type];
|
|
47
|
+
|
|
18
48
|
let backgroundColor;
|
|
19
49
|
let textColor;
|
|
20
50
|
|
|
21
|
-
if (
|
|
22
|
-
backgroundColor = processColor(
|
|
23
|
-
textColor = processColor(
|
|
24
|
-
} else if (type === 'load') {
|
|
25
|
-
if (Appearance.getColorScheme() === 'dark') {
|
|
26
|
-
backgroundColor = processColor('#fafafa');
|
|
27
|
-
textColor = processColor('#242526');
|
|
28
|
-
} else {
|
|
29
|
-
backgroundColor = processColor('#404040');
|
|
30
|
-
textColor = processColor('#ffffff');
|
|
31
|
-
}
|
|
51
|
+
if (colorSet) {
|
|
52
|
+
backgroundColor = processColor(colorSet.backgroundColor);
|
|
53
|
+
textColor = processColor(colorSet.textColor);
|
|
32
54
|
}
|
|
33
55
|
|
|
34
56
|
NativeDevLoadingView.showMessage(
|
|
@@ -70,7 +70,7 @@ const HMRClient: HMRClientNativeInterface = {
|
|
|
70
70
|
}
|
|
71
71
|
|
|
72
72
|
invariant(hmrClient, 'Expected HMRClient.setup() call at startup.');
|
|
73
|
-
const
|
|
73
|
+
const DevLoadingView = require('./DevLoadingView');
|
|
74
74
|
|
|
75
75
|
// We use this for internal logging only.
|
|
76
76
|
// It doesn't affect the logic.
|
|
@@ -81,13 +81,13 @@ const HMRClient: HMRClientNativeInterface = {
|
|
|
81
81
|
const hasUpdates = hmrClient.hasPendingUpdates();
|
|
82
82
|
|
|
83
83
|
if (hasUpdates) {
|
|
84
|
-
|
|
84
|
+
DevLoadingView.showMessage('Refreshing...', 'refresh');
|
|
85
85
|
}
|
|
86
86
|
try {
|
|
87
87
|
hmrClient.enable();
|
|
88
88
|
} finally {
|
|
89
89
|
if (hasUpdates) {
|
|
90
|
-
|
|
90
|
+
DevLoadingView.hide();
|
|
91
91
|
}
|
|
92
92
|
}
|
|
93
93
|
|
|
@@ -181,7 +181,7 @@ const HMRClient: HMRClientNativeInterface = {
|
|
|
181
181
|
invariant(!hmrClient, 'Cannot initialize hmrClient twice');
|
|
182
182
|
|
|
183
183
|
// Moving to top gives errors due to NativeModules not being initialized
|
|
184
|
-
const
|
|
184
|
+
const DevLoadingView = require('./DevLoadingView');
|
|
185
185
|
|
|
186
186
|
const serverHost = port !== null && port !== '' ? `${host}:${port}` : host;
|
|
187
187
|
|
|
@@ -230,7 +230,7 @@ Error: ${e.message}`;
|
|
|
230
230
|
didConnect = true;
|
|
231
231
|
|
|
232
232
|
if (client.isEnabled() && !isInitialUpdate) {
|
|
233
|
-
|
|
233
|
+
DevLoadingView.showMessage('Refreshing...', 'refresh');
|
|
234
234
|
}
|
|
235
235
|
});
|
|
236
236
|
|
|
@@ -242,11 +242,11 @@ Error: ${e.message}`;
|
|
|
242
242
|
});
|
|
243
243
|
|
|
244
244
|
client.on('update-done', () => {
|
|
245
|
-
|
|
245
|
+
DevLoadingView.hide();
|
|
246
246
|
});
|
|
247
247
|
|
|
248
248
|
client.on('error', data => {
|
|
249
|
-
|
|
249
|
+
DevLoadingView.hide();
|
|
250
250
|
|
|
251
251
|
if (data.type === 'GraphNotFoundError') {
|
|
252
252
|
client.close();
|
|
@@ -267,7 +267,7 @@ Error: ${e.message}`;
|
|
|
267
267
|
});
|
|
268
268
|
|
|
269
269
|
client.on('close', closeEvent => {
|
|
270
|
-
|
|
270
|
+
DevLoadingView.hide();
|
|
271
271
|
|
|
272
272
|
// https://www.rfc-editor.org/rfc/rfc6455.html#section-7.4.1
|
|
273
273
|
// https://www.rfc-editor.org/rfc/rfc6455.html#section-7.1.5
|
package/overrides.json
CHANGED
|
@@ -7,13 +7,13 @@
|
|
|
7
7
|
"**/__snapshots__/**",
|
|
8
8
|
"src-win/rntypes/**"
|
|
9
9
|
],
|
|
10
|
-
"baseVersion": "0.75.0-nightly-
|
|
10
|
+
"baseVersion": "0.75.0-nightly-20240420-03a51da72",
|
|
11
11
|
"overrides": [
|
|
12
12
|
{
|
|
13
13
|
"type": "derived",
|
|
14
14
|
"file": ".flowconfig",
|
|
15
15
|
"baseFile": ".flowconfig",
|
|
16
|
-
"baseHash": "
|
|
16
|
+
"baseHash": "4f8e1f39d8ed29d7d0e21455cac407d352a6824d"
|
|
17
17
|
},
|
|
18
18
|
{
|
|
19
19
|
"type": "derived",
|
|
@@ -108,12 +108,6 @@
|
|
|
108
108
|
"baseFile": "packages/react-native/Libraries/Components/SafeAreaView/SafeAreaView.js",
|
|
109
109
|
"baseHash": "ae5845b576484b3600e395d3b1ee03223530b8f7"
|
|
110
110
|
},
|
|
111
|
-
{
|
|
112
|
-
"type": "derived",
|
|
113
|
-
"file": "src-win/Libraries/Components/ScrollView/ScrollView.win32.js",
|
|
114
|
-
"baseFile": "packages/react-native/Libraries/Components/ScrollView/ScrollView.js",
|
|
115
|
-
"baseHash": "732f5ccb69ff37895b3da2a160a0a6842a770385"
|
|
116
|
-
},
|
|
117
111
|
{
|
|
118
112
|
"type": "platform",
|
|
119
113
|
"file": "src-win/Libraries/Components/TextInput/Tests/TextInputTest.tsx"
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@office-iss/react-native-win32",
|
|
3
|
-
"version": "0.0.0-canary.
|
|
3
|
+
"version": "0.0.0-canary.247",
|
|
4
4
|
"description": "Implementation of react native on top of Office's Win32 platform.",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -30,13 +30,13 @@
|
|
|
30
30
|
"@react-native-community/cli-platform-android": "14.0.0-alpha.2",
|
|
31
31
|
"@react-native-community/cli-platform-ios": "14.0.0-alpha.2",
|
|
32
32
|
"@react-native/assets": "1.0.0",
|
|
33
|
-
"@react-native/assets-registry": "0.75.0-nightly-
|
|
34
|
-
"@react-native/codegen": "0.75.0-nightly-
|
|
35
|
-
"@react-native/community-cli-plugin": "0.75.0-nightly-
|
|
36
|
-
"@react-native/gradle-plugin": "0.75.0-nightly-
|
|
37
|
-
"@react-native/js-polyfills": "0.75.0-nightly-
|
|
38
|
-
"@react-native/normalize-colors": "0.75.0-nightly-
|
|
39
|
-
"@react-native/virtualized-lists": "0.75.0-nightly-
|
|
33
|
+
"@react-native/assets-registry": "0.75.0-nightly-20240420-03a51da72",
|
|
34
|
+
"@react-native/codegen": "0.75.0-nightly-20240420-03a51da72",
|
|
35
|
+
"@react-native/community-cli-plugin": "0.75.0-nightly-20240420-03a51da72",
|
|
36
|
+
"@react-native/gradle-plugin": "0.75.0-nightly-20240420-03a51da72",
|
|
37
|
+
"@react-native/js-polyfills": "0.75.0-nightly-20240420-03a51da72",
|
|
38
|
+
"@react-native/normalize-colors": "0.75.0-nightly-20240420-03a51da72",
|
|
39
|
+
"@react-native/virtualized-lists": "0.75.0-nightly-20240420-03a51da72",
|
|
40
40
|
"abort-controller": "^3.0.0",
|
|
41
41
|
"anser": "^1.4.9",
|
|
42
42
|
"ansi-regex": "^5.0.0",
|
|
@@ -56,11 +56,12 @@
|
|
|
56
56
|
"pretty-format": "^26.5.2",
|
|
57
57
|
"promise": "^8.3.0",
|
|
58
58
|
"react-clone-referenced-element": "^1.0.1",
|
|
59
|
-
"react-devtools-core": "
|
|
59
|
+
"react-devtools-core": "5.1.0",
|
|
60
60
|
"react-refresh": "^0.14.0",
|
|
61
61
|
"react-shallow-renderer": "^16.15.0",
|
|
62
62
|
"regenerator-runtime": "^0.13.2",
|
|
63
63
|
"scheduler": "0.24.0-canary-efb381bbf-20230505",
|
|
64
|
+
"semver": "^7.1.3",
|
|
64
65
|
"stacktrace-parser": "^0.1.10",
|
|
65
66
|
"whatwg-fetch": "^3.0.0",
|
|
66
67
|
"ws": "^6.2.2",
|
|
@@ -69,11 +70,11 @@
|
|
|
69
70
|
"devDependencies": {
|
|
70
71
|
"@babel/core": "^7.20.0",
|
|
71
72
|
"@babel/eslint-parser": "^7.20.0",
|
|
72
|
-
"@react-native/metro-config": "0.75.0-nightly-
|
|
73
|
+
"@react-native/metro-config": "0.75.0-nightly-20240420-03a51da72",
|
|
73
74
|
"@rnw-scripts/babel-react-native-config": "0.0.0",
|
|
74
|
-
"@rnw-scripts/eslint-config": "1.2.
|
|
75
|
-
"@rnw-scripts/jest-out-of-tree-snapshot-resolver": "^1.1.
|
|
76
|
-
"@rnw-scripts/just-task": "2.3.
|
|
75
|
+
"@rnw-scripts/eslint-config": "1.2.17",
|
|
76
|
+
"@rnw-scripts/jest-out-of-tree-snapshot-resolver": "^1.1.21",
|
|
77
|
+
"@rnw-scripts/just-task": "2.3.33",
|
|
77
78
|
"@rnw-scripts/metro-dev-config": "0.0.0",
|
|
78
79
|
"@rnx-kit/jest-preset": "^0.1.0",
|
|
79
80
|
"@types/node": "^18.0.0",
|
|
@@ -85,14 +86,14 @@
|
|
|
85
86
|
"just-scripts": "^1.3.3",
|
|
86
87
|
"prettier": "2.8.8",
|
|
87
88
|
"react": "18.2.0",
|
|
88
|
-
"react-native": "0.75.0-nightly-
|
|
89
|
-
"react-native-platform-override": "^1.9.
|
|
89
|
+
"react-native": "0.75.0-nightly-20240420-03a51da72",
|
|
90
|
+
"react-native-platform-override": "^1.9.34",
|
|
90
91
|
"typescript": "5.0.4"
|
|
91
92
|
},
|
|
92
93
|
"peerDependencies": {
|
|
93
94
|
"@types/react": "^18.2.6",
|
|
94
95
|
"react": "18.2.0",
|
|
95
|
-
"react-native": "0.75.0-nightly-
|
|
96
|
+
"react-native": "0.75.0-nightly-20240420-03a51da72"
|
|
96
97
|
},
|
|
97
98
|
"beachball": {
|
|
98
99
|
"defaultNpmTag": "canary",
|
|
@@ -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
|
-
* @generated SignedSource<<
|
|
7
|
+
* @generated SignedSource<<0e0858557eb27f3eebfecae18ee13c0b>>
|
|
8
8
|
* @flow strict-local
|
|
9
9
|
*/
|
|
10
10
|
|
|
@@ -45,16 +45,18 @@ export type ReactNativeFeatureFlags = {
|
|
|
45
45
|
enableBackgroundExecutor: Getter<boolean>,
|
|
46
46
|
enableCleanTextInputYogaNode: Getter<boolean>,
|
|
47
47
|
enableCustomDrawOrderFabric: Getter<boolean>,
|
|
48
|
-
enableFixForClippedSubviewsCrash: Getter<boolean>,
|
|
49
48
|
enableMicrotasks: Getter<boolean>,
|
|
50
49
|
enableMountHooksAndroid: Getter<boolean>,
|
|
51
50
|
enableSpannableBuildingUnification: Getter<boolean>,
|
|
52
51
|
enableSynchronousStateUpdates: Getter<boolean>,
|
|
53
52
|
enableUIConsistency: Getter<boolean>,
|
|
53
|
+
forceBatchingMountItemsOnAndroid: Getter<boolean>,
|
|
54
54
|
inspectorEnableCxxInspectorPackagerConnection: Getter<boolean>,
|
|
55
55
|
inspectorEnableModernCDPRegistry: Getter<boolean>,
|
|
56
|
+
preventDoubleTextMeasure: Getter<boolean>,
|
|
56
57
|
useModernRuntimeScheduler: Getter<boolean>,
|
|
57
58
|
useNativeViewConfigsInBridgelessMode: Getter<boolean>,
|
|
59
|
+
useStateAlignmentMechanism: Getter<boolean>,
|
|
58
60
|
}
|
|
59
61
|
|
|
60
62
|
/**
|
|
@@ -117,10 +119,6 @@ export const enableCleanTextInputYogaNode: Getter<boolean> = createNativeFlagGet
|
|
|
117
119
|
* When enabled, Fabric will use customDrawOrder in ReactViewGroup (similar to old architecture).
|
|
118
120
|
*/
|
|
119
121
|
export const enableCustomDrawOrderFabric: Getter<boolean> = createNativeFlagGetter('enableCustomDrawOrderFabric', false);
|
|
120
|
-
/**
|
|
121
|
-
* Attempt at fixing a crash related to subview clipping on Android. This is a kill switch for the fix
|
|
122
|
-
*/
|
|
123
|
-
export const enableFixForClippedSubviewsCrash: Getter<boolean> = createNativeFlagGetter('enableFixForClippedSubviewsCrash', false);
|
|
124
122
|
/**
|
|
125
123
|
* Enables the use of microtasks in Hermes (scheduling) and RuntimeScheduler (execution).
|
|
126
124
|
*/
|
|
@@ -141,6 +139,10 @@ export const enableSynchronousStateUpdates: Getter<boolean> = createNativeFlagGe
|
|
|
141
139
|
* Ensures that JavaScript always has a consistent view of the state of the UI (e.g.: commits done in other threads are not immediately propagated to JS during its execution).
|
|
142
140
|
*/
|
|
143
141
|
export const enableUIConsistency: Getter<boolean> = createNativeFlagGetter('enableUIConsistency', false);
|
|
142
|
+
/**
|
|
143
|
+
* Forces the mounting layer on Android to always batch mount items instead of dispatching them immediately. This might fix some crashes related to synchronous state updates, where some views dispatch state updates during mount.
|
|
144
|
+
*/
|
|
145
|
+
export const forceBatchingMountItemsOnAndroid: Getter<boolean> = createNativeFlagGetter('forceBatchingMountItemsOnAndroid', false);
|
|
144
146
|
/**
|
|
145
147
|
* Flag determining if the C++ implementation of InspectorPackagerConnection should be used instead of the per-platform one. This flag is global and should not be changed across React Host lifetimes.
|
|
146
148
|
*/
|
|
@@ -149,6 +151,10 @@ export const inspectorEnableCxxInspectorPackagerConnection: Getter<boolean> = cr
|
|
|
149
151
|
* Flag determining if the modern CDP backend should be enabled. This flag is global and should not be changed across React Host lifetimes.
|
|
150
152
|
*/
|
|
151
153
|
export const inspectorEnableModernCDPRegistry: Getter<boolean> = createNativeFlagGetter('inspectorEnableModernCDPRegistry', false);
|
|
154
|
+
/**
|
|
155
|
+
* When enabled, ParagraphShadowNode will no longer call measure twice.
|
|
156
|
+
*/
|
|
157
|
+
export const preventDoubleTextMeasure: Getter<boolean> = createNativeFlagGetter('preventDoubleTextMeasure', false);
|
|
152
158
|
/**
|
|
153
159
|
* When enabled, it uses the modern fork of RuntimeScheduler that allows scheduling tasks with priorities from any thread.
|
|
154
160
|
*/
|
|
@@ -157,6 +163,10 @@ export const useModernRuntimeScheduler: Getter<boolean> = createNativeFlagGetter
|
|
|
157
163
|
* When enabled, the native view configs are used in bridgeless mode.
|
|
158
164
|
*/
|
|
159
165
|
export const useNativeViewConfigsInBridgelessMode: Getter<boolean> = createNativeFlagGetter('useNativeViewConfigsInBridgelessMode', false);
|
|
166
|
+
/**
|
|
167
|
+
* When enabled, it uses optimised state reconciliation algorithm.
|
|
168
|
+
*/
|
|
169
|
+
export const useStateAlignmentMechanism: Getter<boolean> = createNativeFlagGetter('useStateAlignmentMechanism', false);
|
|
160
170
|
|
|
161
171
|
/**
|
|
162
172
|
* Overrides the feature flags with the provided methods.
|
|
@@ -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
|
-
* @generated SignedSource<<
|
|
7
|
+
* @generated SignedSource<<4ba909c3b360c6a4fc9c6ed5996b6a13>>
|
|
8
8
|
* @flow strict-local
|
|
9
9
|
*/
|
|
10
10
|
|
|
@@ -28,16 +28,18 @@ export interface Spec extends TurboModule {
|
|
|
28
28
|
+enableBackgroundExecutor?: () => boolean;
|
|
29
29
|
+enableCleanTextInputYogaNode?: () => boolean;
|
|
30
30
|
+enableCustomDrawOrderFabric?: () => boolean;
|
|
31
|
-
+enableFixForClippedSubviewsCrash?: () => boolean;
|
|
32
31
|
+enableMicrotasks?: () => boolean;
|
|
33
32
|
+enableMountHooksAndroid?: () => boolean;
|
|
34
33
|
+enableSpannableBuildingUnification?: () => boolean;
|
|
35
34
|
+enableSynchronousStateUpdates?: () => boolean;
|
|
36
35
|
+enableUIConsistency?: () => boolean;
|
|
36
|
+
+forceBatchingMountItemsOnAndroid?: () => boolean;
|
|
37
37
|
+inspectorEnableCxxInspectorPackagerConnection?: () => boolean;
|
|
38
38
|
+inspectorEnableModernCDPRegistry?: () => boolean;
|
|
39
|
+
+preventDoubleTextMeasure?: () => boolean;
|
|
39
40
|
+useModernRuntimeScheduler?: () => boolean;
|
|
40
41
|
+useNativeViewConfigsInBridgelessMode?: () => boolean;
|
|
42
|
+
+useStateAlignmentMechanism?: () => boolean;
|
|
41
43
|
}
|
|
42
44
|
|
|
43
45
|
const NativeReactNativeFeatureFlags: ?Spec = TurboModuleRegistry.get<Spec>(
|