@office-iss/react-native-win32 0.0.0-canary.256 → 0.0.0-canary.258
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 +4 -2
- package/CHANGELOG.json +79 -1
- package/CHANGELOG.md +32 -8
- package/Libraries/Components/ScrollView/ScrollView.js +124 -165
- package/Libraries/Core/InitializeCore.js +2 -0
- package/Libraries/Core/ReactNativeVersion.js +3 -3
- package/Libraries/Core/ReactNativeVersionCheck.win32.js +1 -1
- package/Libraries/Core/setUpGlobals.js +1 -0
- package/Libraries/Core/setUpTimers.js +19 -0
- package/Libraries/LogBox/Data/LogBoxData.js +39 -4
- package/Libraries/LogBox/Data/LogBoxLog.js +5 -2
- package/Libraries/LogBox/Data/parseLogBoxLog.js +22 -1
- package/Libraries/LogBox/LogBox.js +29 -12
- package/Libraries/LogBox/LogBoxNotificationContainer.js +4 -0
- package/Libraries/LogBox/UI/LogBoxInspector.js +8 -70
- package/Libraries/LogBox/UI/LogBoxInspectorBody.js +87 -0
- package/Libraries/LogBox/UI/LogBoxInspectorFooter.js +6 -42
- package/Libraries/LogBox/UI/LogBoxInspectorFooterButton.js +58 -0
- package/Libraries/LogBox/UI/LogBoxInspectorHeader.js +25 -74
- package/Libraries/LogBox/UI/LogBoxInspectorHeader.win32.js +27 -80
- package/Libraries/LogBox/UI/LogBoxInspectorHeaderButton.js +76 -0
- package/Libraries/LogBox/UI/LogBoxNotification.js +13 -152
- package/Libraries/LogBox/UI/LogBoxNotificationCountBadge.js +63 -0
- package/Libraries/LogBox/UI/LogBoxNotificationDismissButton.js +67 -0
- package/Libraries/LogBox/UI/LogBoxNotificationMessage.js +57 -0
- package/Libraries/ReactNative/AppContainer-dev.js +1 -5
- package/Libraries/ReactNative/AppContainer-prod.js +1 -5
- package/Libraries/ReactNative/AppContainer.js +0 -1
- package/Libraries/ReactNative/AppRegistry.js +0 -6
- package/Libraries/ReactNative/renderApplication.js +0 -2
- package/Libraries/Renderer/implementations/ReactFabric-dev.js +15690 -26405
- package/Libraries/Renderer/implementations/ReactFabric-prod.js +2675 -1630
- package/Libraries/Renderer/implementations/ReactFabric-profiling.js +2945 -1682
- package/Libraries/Renderer/implementations/ReactNativeRenderer-dev.js +16141 -27018
- package/Libraries/Renderer/implementations/ReactNativeRenderer-prod.js +2723 -1666
- package/Libraries/Renderer/implementations/ReactNativeRenderer-profiling.js +2984 -1737
- package/Libraries/Share/Share.d.ts +16 -10
- package/Libraries/Share/Share.js +14 -15
- package/Libraries/StyleSheet/StyleSheetTypes.d.ts +19 -0
- package/Libraries/StyleSheet/StyleSheetTypes.js +19 -1
- package/Libraries/StyleSheet/processFilter.js +214 -39
- package/Libraries/Text/Text.js +42 -22
- package/Libraries/Text/Text.win32.js +42 -22
- package/Libraries/Text/TextNativeComponent.js +1 -1
- package/Libraries/Text/TextNativeComponent.win32.js +1 -1
- package/Libraries/Text/TextOptimized.js +538 -0
- package/Libraries/Utilities/ReactNativeTestTools.js +7 -24
- package/Libraries/__tests__/ButtonWin32-test.js +7 -6
- package/Libraries/promiseRejectionTrackingOptions.js +1 -0
- package/index.js +1 -0
- package/index.win32.js +1 -0
- package/jest/mockComponent.js +4 -1
- package/jest/renderer.js +25 -14
- package/jest/setup.js +5 -0
- package/overrides.json +6 -6
- package/package.json +26 -26
- package/src/private/core/components/HScrollViewNativeComponents.js +55 -0
- package/src/private/core/components/VScrollViewNativeComponents.js +47 -0
- package/src/private/core/components/useSyncOnScroll.js +48 -0
- package/src/private/featureflags/ReactNativeFeatureFlags.js +12 -1
- package/src/private/featureflags/specs/NativeReactNativeFeatureFlags.js +2 -1
- package/src/private/specs/modules/NativeDevSettings.js +1 -0
- package/src/private/specs/modules/NativeSampleTurboModule.js +14 -1
- package/src/private/webapis/idlecallbacks/specs/NativeIdleCallbacks.js +34 -0
|
@@ -0,0 +1,67 @@
|
|
|
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
|
+
* @flow strict-local
|
|
8
|
+
* @format
|
|
9
|
+
*/
|
|
10
|
+
|
|
11
|
+
import View from '../../Components/View/View';
|
|
12
|
+
import Image from '../../Image/Image';
|
|
13
|
+
import StyleSheet from '../../StyleSheet/StyleSheet';
|
|
14
|
+
import LogBoxButton from './LogBoxButton';
|
|
15
|
+
import * as LogBoxStyle from './LogBoxStyle';
|
|
16
|
+
import * as React from 'react';
|
|
17
|
+
|
|
18
|
+
export default function LogBoxNotificationDismissButton(props: {
|
|
19
|
+
onPress: () => void,
|
|
20
|
+
}): React.Node {
|
|
21
|
+
return (
|
|
22
|
+
<View style={styles.container}>
|
|
23
|
+
<LogBoxButton
|
|
24
|
+
backgroundColor={{
|
|
25
|
+
default: LogBoxStyle.getTextColor(0.3),
|
|
26
|
+
pressed: LogBoxStyle.getTextColor(0.5),
|
|
27
|
+
}}
|
|
28
|
+
hitSlop={{
|
|
29
|
+
top: 12,
|
|
30
|
+
right: 10,
|
|
31
|
+
bottom: 12,
|
|
32
|
+
left: 10,
|
|
33
|
+
}}
|
|
34
|
+
onPress={props.onPress}
|
|
35
|
+
style={styles.press}>
|
|
36
|
+
<Image
|
|
37
|
+
source={require('./LogBoxImages/close.png')}
|
|
38
|
+
style={styles.image}
|
|
39
|
+
/>
|
|
40
|
+
</LogBoxButton>
|
|
41
|
+
</View>
|
|
42
|
+
);
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
const styles = StyleSheet.create({
|
|
46
|
+
container: {
|
|
47
|
+
alignSelf: 'center',
|
|
48
|
+
flexDirection: 'row',
|
|
49
|
+
flexGrow: 0,
|
|
50
|
+
flexShrink: 0,
|
|
51
|
+
flexBasis: 'auto',
|
|
52
|
+
marginLeft: 5,
|
|
53
|
+
},
|
|
54
|
+
press: {
|
|
55
|
+
height: 20,
|
|
56
|
+
width: 20,
|
|
57
|
+
borderRadius: 25,
|
|
58
|
+
alignSelf: 'flex-end',
|
|
59
|
+
alignItems: 'center',
|
|
60
|
+
justifyContent: 'center',
|
|
61
|
+
},
|
|
62
|
+
image: {
|
|
63
|
+
height: 8,
|
|
64
|
+
width: 8,
|
|
65
|
+
tintColor: LogBoxStyle.getBackgroundColor(1),
|
|
66
|
+
},
|
|
67
|
+
});
|
|
@@ -0,0 +1,57 @@
|
|
|
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
|
+
* @flow strict-local
|
|
8
|
+
* @format
|
|
9
|
+
*/
|
|
10
|
+
|
|
11
|
+
import type {Message as MessageType} from '../Data/parseLogBoxLog';
|
|
12
|
+
|
|
13
|
+
import View from '../../Components/View/View';
|
|
14
|
+
import StyleSheet from '../../StyleSheet/StyleSheet';
|
|
15
|
+
import Text from '../../Text/Text';
|
|
16
|
+
import LogBoxMessage from './LogBoxMessage';
|
|
17
|
+
import * as LogBoxStyle from './LogBoxStyle';
|
|
18
|
+
import * as React from 'react';
|
|
19
|
+
|
|
20
|
+
export default function LogBoxNotificationMessage(props: {
|
|
21
|
+
message: MessageType,
|
|
22
|
+
}): React.Node {
|
|
23
|
+
return (
|
|
24
|
+
<View style={styles.container}>
|
|
25
|
+
<Text numberOfLines={1} style={styles.text}>
|
|
26
|
+
{props.message && (
|
|
27
|
+
<LogBoxMessage
|
|
28
|
+
plaintext
|
|
29
|
+
message={props.message}
|
|
30
|
+
style={styles.substitutionText}
|
|
31
|
+
/>
|
|
32
|
+
)}
|
|
33
|
+
</Text>
|
|
34
|
+
</View>
|
|
35
|
+
);
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
const styles = StyleSheet.create({
|
|
39
|
+
container: {
|
|
40
|
+
alignSelf: 'stretch',
|
|
41
|
+
flexGrow: 1,
|
|
42
|
+
flexShrink: 1,
|
|
43
|
+
flexBasis: 'auto',
|
|
44
|
+
borderLeftColor: LogBoxStyle.getTextColor(0.2),
|
|
45
|
+
borderLeftWidth: 1,
|
|
46
|
+
paddingLeft: 8,
|
|
47
|
+
},
|
|
48
|
+
text: {
|
|
49
|
+
color: LogBoxStyle.getTextColor(1),
|
|
50
|
+
flex: 1,
|
|
51
|
+
fontSize: 14,
|
|
52
|
+
lineHeight: 22,
|
|
53
|
+
},
|
|
54
|
+
substitutionText: {
|
|
55
|
+
color: LogBoxStyle.getTextColor(0.6),
|
|
56
|
+
},
|
|
57
|
+
});
|
|
@@ -90,7 +90,6 @@ const AppContainer = ({
|
|
|
90
90
|
internal_excludeInspector = false,
|
|
91
91
|
internal_excludeLogBox = false,
|
|
92
92
|
rootTag,
|
|
93
|
-
showArchitectureIndicator,
|
|
94
93
|
WrapperComponent,
|
|
95
94
|
rootViewStyle,
|
|
96
95
|
}: Props): React.Node => {
|
|
@@ -150,10 +149,7 @@ const AppContainer = ({
|
|
|
150
149
|
|
|
151
150
|
if (WrapperComponent != null) {
|
|
152
151
|
innerView = (
|
|
153
|
-
<WrapperComponent
|
|
154
|
-
initialProps={initialProps}
|
|
155
|
-
fabric={fabric === true}
|
|
156
|
-
showArchitectureIndicator={showArchitectureIndicator === true}>
|
|
152
|
+
<WrapperComponent initialProps={initialProps} fabric={fabric === true}>
|
|
157
153
|
{innerView}
|
|
158
154
|
</WrapperComponent>
|
|
159
155
|
);
|
|
@@ -21,7 +21,6 @@ const AppContainer = ({
|
|
|
21
21
|
fabric,
|
|
22
22
|
initialProps,
|
|
23
23
|
rootTag,
|
|
24
|
-
showArchitectureIndicator,
|
|
25
24
|
WrapperComponent,
|
|
26
25
|
rootViewStyle,
|
|
27
26
|
}: Props): React.Node => {
|
|
@@ -29,10 +28,7 @@ const AppContainer = ({
|
|
|
29
28
|
|
|
30
29
|
if (WrapperComponent != null) {
|
|
31
30
|
innerView = (
|
|
32
|
-
<WrapperComponent
|
|
33
|
-
initialProps={initialProps}
|
|
34
|
-
fabric={fabric === true}
|
|
35
|
-
showArchitectureIndicator={showArchitectureIndicator === true}>
|
|
31
|
+
<WrapperComponent initialProps={initialProps} fabric={fabric === true}>
|
|
36
32
|
{innerView}
|
|
37
33
|
</WrapperComponent>
|
|
38
34
|
);
|
|
@@ -18,7 +18,6 @@ export type Props = $ReadOnly<{|
|
|
|
18
18
|
fabric?: boolean,
|
|
19
19
|
rootTag: number | RootTag,
|
|
20
20
|
initialProps?: {...},
|
|
21
|
-
showArchitectureIndicator?: boolean,
|
|
22
21
|
WrapperComponent?: ?React.ComponentType<any>,
|
|
23
22
|
rootViewStyle?: ?ViewStyleProp,
|
|
24
23
|
internal_excludeLogBox?: boolean,
|
|
@@ -73,7 +73,6 @@ let componentProviderInstrumentationHook: ComponentProviderInstrumentationHook =
|
|
|
73
73
|
|
|
74
74
|
let wrapperComponentProvider: ?WrapperComponentProvider;
|
|
75
75
|
let rootViewStyleProvider: ?RootViewStyleProvider;
|
|
76
|
-
let showArchitectureIndicator = false;
|
|
77
76
|
|
|
78
77
|
/**
|
|
79
78
|
* `AppRegistry` is the JavaScript entry point to running all React Native apps.
|
|
@@ -89,10 +88,6 @@ const AppRegistry = {
|
|
|
89
88
|
rootViewStyleProvider = provider;
|
|
90
89
|
},
|
|
91
90
|
|
|
92
|
-
enableArchitectureIndicator(enabled: boolean): void {
|
|
93
|
-
showArchitectureIndicator = enabled;
|
|
94
|
-
},
|
|
95
|
-
|
|
96
91
|
registerConfig(config: Array<AppConfig>): void {
|
|
97
92
|
config.forEach(appConfig => {
|
|
98
93
|
if (appConfig.run) {
|
|
@@ -139,7 +134,6 @@ const AppRegistry = {
|
|
|
139
134
|
wrapperComponentProvider && wrapperComponentProvider(appParameters),
|
|
140
135
|
rootViewStyleProvider && rootViewStyleProvider(appParameters),
|
|
141
136
|
appParameters.fabric,
|
|
142
|
-
showArchitectureIndicator,
|
|
143
137
|
scopedPerformanceLogger,
|
|
144
138
|
appKey === 'LogBox', // is logbox
|
|
145
139
|
appKey,
|
|
@@ -35,7 +35,6 @@ export default function renderApplication<Props: Object>(
|
|
|
35
35
|
WrapperComponent?: ?React.ComponentType<any>,
|
|
36
36
|
rootViewStyle?: ?ViewStyleProp,
|
|
37
37
|
fabric?: boolean,
|
|
38
|
-
showArchitectureIndicator?: boolean,
|
|
39
38
|
scopedPerformanceLogger?: IPerformanceLogger,
|
|
40
39
|
isLogBox?: boolean,
|
|
41
40
|
debugName?: string,
|
|
@@ -52,7 +51,6 @@ export default function renderApplication<Props: Object>(
|
|
|
52
51
|
<AppContainer
|
|
53
52
|
rootTag={rootTag}
|
|
54
53
|
fabric={fabric}
|
|
55
|
-
showArchitectureIndicator={showArchitectureIndicator}
|
|
56
54
|
WrapperComponent={WrapperComponent}
|
|
57
55
|
rootViewStyle={rootViewStyle}
|
|
58
56
|
initialProps={initialProps ?? Object.freeze({})}
|