expo-harmony-toolkit 1.7.1 → 1.7.3
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/README.en.md +20 -9
- package/README.md +22 -11
- package/build/core/autolinking.d.ts +10 -0
- package/build/core/autolinking.js +421 -0
- package/build/core/build/commands.d.ts +19 -0
- package/build/core/build/commands.js +61 -0
- package/build/core/build/compatibilityShims.d.ts +1 -0
- package/build/core/build/compatibilityShims.js +272 -0
- package/build/core/build/localHar.d.ts +13 -0
- package/build/core/build/localHar.js +337 -0
- package/build/core/build/reporting.d.ts +19 -0
- package/build/core/build/reporting.js +67 -0
- package/build/core/build/rnohCompatibility.d.ts +1 -0
- package/build/core/build/rnohCompatibility.js +38 -0
- package/build/core/build.d.ts +4 -12
- package/build/core/build.js +70 -762
- package/build/core/constants.d.ts +2 -1
- package/build/core/constants.js +3 -2
- package/build/core/dependencyInspection.d.ts +2 -0
- package/build/core/dependencyInspection.js +112 -0
- package/build/core/env.js +1 -1
- package/build/core/report.js +33 -10
- package/build/core/signing.d.ts +2 -0
- package/build/core/signing.js +30 -0
- package/build/core/template/capabilityRegistry.d.ts +9 -0
- package/build/core/template/capabilityRegistry.js +84 -0
- package/build/core/template/expoModulesCoreShim.d.ts +2 -0
- package/build/core/template/expoModulesCoreShim.js +279 -0
- package/build/core/template/metro.d.ts +2 -0
- package/build/core/template/metro.js +213 -0
- package/build/core/template/nativeFiles.d.ts +8 -0
- package/build/core/template/nativeFiles.js +333 -0
- package/build/core/template/renderers/camera.d.ts +4 -0
- package/build/core/template/renderers/camera.js +612 -0
- package/build/core/template/renderers/fileSystem.d.ts +4 -0
- package/build/core/template/renderers/fileSystem.js +814 -0
- package/build/core/template/renderers/imagePicker.d.ts +4 -0
- package/build/core/template/renderers/imagePicker.js +753 -0
- package/build/core/template/renderers/location.d.ts +4 -0
- package/build/core/template/renderers/location.js +836 -0
- package/build/core/template/runtimeShims.d.ts +2 -0
- package/build/core/template/runtimeShims.js +192 -0
- package/build/core/template/support.d.ts +11 -0
- package/build/core/template/support.js +108 -0
- package/build/core/template.d.ts +2 -6
- package/build/core/template.js +47 -3966
- package/build/data/capabilities.js +45 -19
- package/build/data/dependencyCatalog.js +10 -0
- package/build/data/publicDocs.d.ts +11 -0
- package/build/data/publicDocs.js +28 -0
- package/build/data/validatedMatrices.js +9 -1
- package/build/docs/render.d.ts +9 -0
- package/build/docs/render.js +248 -0
- package/build/types.d.ts +12 -0
- package/docs/cli-build.md +1 -1
- package/docs/npm-release.md +1 -0
- package/docs/official-app-shell-sample.md +2 -1
- package/docs/official-minimal-sample.md +2 -1
- package/docs/official-native-capabilities-sample.md +28 -47
- package/docs/official-ui-stack-sample.md +2 -1
- package/docs/signing-and-release.md +3 -0
- package/docs/support-matrix.md +38 -16
- package/package.json +13 -5
- package/docs/v1.5.1-acceptance.md +0 -385
- package/docs/v1.6.0-acceptance.md +0 -193
- package/docs/v1.7.0-acceptance.md +0 -111
- package/docs/v1.7.1-acceptance.md +0 -111
|
@@ -12,12 +12,24 @@ const PREVIEW_BASELINE_EVIDENCE = {
|
|
|
12
12
|
device: true,
|
|
13
13
|
release: false,
|
|
14
14
|
};
|
|
15
|
+
const PREVIEW_BASELINE_EVIDENCE_SOURCE = {
|
|
16
|
+
bundle: 'automated',
|
|
17
|
+
debugBuild: 'automated',
|
|
18
|
+
device: 'manual-doc',
|
|
19
|
+
release: 'none',
|
|
20
|
+
};
|
|
15
21
|
const EXPLORATORY_EVIDENCE = {
|
|
16
22
|
bundle: false,
|
|
17
23
|
debugBuild: false,
|
|
18
24
|
device: false,
|
|
19
25
|
release: false,
|
|
20
26
|
};
|
|
27
|
+
const EXPLORATORY_EVIDENCE_SOURCE = {
|
|
28
|
+
bundle: 'none',
|
|
29
|
+
debugBuild: 'none',
|
|
30
|
+
device: 'none',
|
|
31
|
+
release: 'none',
|
|
32
|
+
};
|
|
21
33
|
exports.CAPABILITY_DEFINITIONS = [
|
|
22
34
|
{
|
|
23
35
|
id: 'expo-file-system',
|
|
@@ -26,15 +38,16 @@ exports.CAPABILITY_DEFINITIONS = [
|
|
|
26
38
|
supportTier: 'preview',
|
|
27
39
|
runtimeMode: 'adapter',
|
|
28
40
|
evidence: PREVIEW_BASELINE_EVIDENCE,
|
|
29
|
-
|
|
41
|
+
evidenceSource: PREVIEW_BASELINE_EVIDENCE_SOURCE,
|
|
42
|
+
note: 'Toolkit-managed Harmony native file-system adapters cover the v1.7.3 preview subset: UTF-8/base64 sandbox I/O, append and partial reads, md5 metadata, and direct downloads into the app sandbox.',
|
|
30
43
|
docsUrl: 'https://github.com/react-native-oh-library/usage-docs/blob/master/en/react-native-fs.md',
|
|
31
44
|
nativePackageNames: ['react-native-fs'],
|
|
32
45
|
harmonyPermissions: [],
|
|
33
46
|
sampleRoute: '/file-system',
|
|
34
47
|
acceptanceChecklist: [
|
|
35
|
-
'Write
|
|
36
|
-
'Read
|
|
37
|
-
'
|
|
48
|
+
'Write UTF-8 and base64 content into the app sandbox.',
|
|
49
|
+
'Read back full and partial content and verify md5 metadata.',
|
|
50
|
+
'Download a remote file into the sandbox and clean up generated entries.',
|
|
38
51
|
],
|
|
39
52
|
},
|
|
40
53
|
{
|
|
@@ -44,15 +57,20 @@ exports.CAPABILITY_DEFINITIONS = [
|
|
|
44
57
|
supportTier: 'preview',
|
|
45
58
|
runtimeMode: 'adapter',
|
|
46
59
|
evidence: PREVIEW_BASELINE_EVIDENCE,
|
|
47
|
-
|
|
60
|
+
evidenceSource: PREVIEW_BASELINE_EVIDENCE_SOURCE,
|
|
61
|
+
note: 'Toolkit-managed Harmony adapters cover the v1.7.3 preview subset: media and camera permissions, single/multi-select library flows, system photo/video capture, pending-result restore, and richer video asset metadata.',
|
|
48
62
|
docsUrl: 'https://github.com/react-native-oh-library/usage-docs/blob/master/en/react-native-image-picker.md',
|
|
49
63
|
nativePackageNames: ['react-native-image-picker', 'react-native-permissions'],
|
|
50
|
-
harmonyPermissions: [
|
|
64
|
+
harmonyPermissions: [
|
|
65
|
+
'ohos.permission.CAMERA',
|
|
66
|
+
'ohos.permission.MICROPHONE',
|
|
67
|
+
'ohos.permission.READ_IMAGEVIDEO',
|
|
68
|
+
],
|
|
51
69
|
sampleRoute: '/image-picker',
|
|
52
70
|
acceptanceChecklist: [
|
|
53
|
-
'Request media-library permissions and surface denied/cancel states.',
|
|
54
|
-
'Launch
|
|
55
|
-
'Launch
|
|
71
|
+
'Request media-library and camera permissions and surface denied/cancel states.',
|
|
72
|
+
'Launch single, multi-select, and mixed library flows and return asset metadata.',
|
|
73
|
+
'Launch photo/video camera capture and restore one pending result when the JS side resumes.',
|
|
56
74
|
],
|
|
57
75
|
},
|
|
58
76
|
{
|
|
@@ -62,15 +80,21 @@ exports.CAPABILITY_DEFINITIONS = [
|
|
|
62
80
|
supportTier: 'preview',
|
|
63
81
|
runtimeMode: 'adapter',
|
|
64
82
|
evidence: PREVIEW_BASELINE_EVIDENCE,
|
|
65
|
-
|
|
83
|
+
evidenceSource: PREVIEW_BASELINE_EVIDENCE_SOURCE,
|
|
84
|
+
note: 'Toolkit-managed Harmony adapters cover the v1.7.3 preview subset: foreground/background permission flows, current and last-known fixes, geocoding, continuous watch subscriptions, and sensor-backed heading updates.',
|
|
66
85
|
docsUrl: 'https://github.com/react-native-oh-library/usage-docs/blob/master/en/%40react-native-community-geolocation.md',
|
|
67
86
|
nativePackageNames: ['@react-native-community/geolocation', 'react-native-permissions'],
|
|
68
|
-
harmonyPermissions: [
|
|
87
|
+
harmonyPermissions: [
|
|
88
|
+
'ohos.permission.LOCATION',
|
|
89
|
+
'ohos.permission.APPROXIMATELY_LOCATION',
|
|
90
|
+
'ohos.permission.LOCATION_IN_BACKGROUND',
|
|
91
|
+
'ohos.permission.ACCELEROMETER',
|
|
92
|
+
],
|
|
69
93
|
sampleRoute: '/location',
|
|
70
94
|
acceptanceChecklist: [
|
|
71
|
-
'Request foreground location
|
|
72
|
-
'Resolve one
|
|
73
|
-
'Resolve
|
|
95
|
+
'Request foreground and background location permissions.',
|
|
96
|
+
'Resolve current and last-known fixes plus one active watch update.',
|
|
97
|
+
'Resolve heading snapshot/watch updates and reverse-geocoded results.',
|
|
74
98
|
],
|
|
75
99
|
},
|
|
76
100
|
{
|
|
@@ -80,15 +104,16 @@ exports.CAPABILITY_DEFINITIONS = [
|
|
|
80
104
|
supportTier: 'preview',
|
|
81
105
|
runtimeMode: 'adapter',
|
|
82
106
|
evidence: PREVIEW_BASELINE_EVIDENCE,
|
|
83
|
-
|
|
107
|
+
evidenceSource: PREVIEW_BASELINE_EVIDENCE_SOURCE,
|
|
108
|
+
note: 'Toolkit-managed Harmony adapters cover the v1.7.3 preview subset: embedded camera preview, still capture, preview pause/resume, microphone permission, and in-session video recording controls.',
|
|
84
109
|
docsUrl: 'https://github.com/react-native-oh-library/usage-docs/blob/master/en/react-native-camera-kit.md',
|
|
85
110
|
nativePackageNames: ['react-native-camera-kit', 'react-native-permissions'],
|
|
86
|
-
harmonyPermissions: ['ohos.permission.CAMERA'],
|
|
111
|
+
harmonyPermissions: ['ohos.permission.CAMERA', 'ohos.permission.MICROPHONE'],
|
|
87
112
|
sampleRoute: '/camera',
|
|
88
113
|
acceptanceChecklist: [
|
|
89
|
-
'Request camera
|
|
90
|
-
'Capture one photo and
|
|
91
|
-
'
|
|
114
|
+
'Request camera and microphone permissions.',
|
|
115
|
+
'Capture one photo and one embedded video result and surface metadata back to JS.',
|
|
116
|
+
'Exercise preview pause/resume plus denied or canceled outcomes without crashing the Harmony runtime.',
|
|
92
117
|
],
|
|
93
118
|
},
|
|
94
119
|
{
|
|
@@ -98,6 +123,7 @@ exports.CAPABILITY_DEFINITIONS = [
|
|
|
98
123
|
supportTier: 'experimental',
|
|
99
124
|
runtimeMode: 'shim',
|
|
100
125
|
evidence: EXPLORATORY_EVIDENCE,
|
|
126
|
+
evidenceSource: EXPLORATORY_EVIDENCE_SOURCE,
|
|
101
127
|
note: 'Notifications stay below the public promise until a complete Harmony delivery story is validated end to end.',
|
|
102
128
|
docsUrl: 'https://github.com/react-native-oh-library',
|
|
103
129
|
nativePackageNames: [],
|
|
@@ -37,6 +37,11 @@ exports.DEPENDENCY_CATALOG = {
|
|
|
37
37
|
supportTier: 'verified',
|
|
38
38
|
note: 'Toolkit can parse Expo config and scaffold Harmony sidecar files for managed/CNG projects.',
|
|
39
39
|
},
|
|
40
|
+
'@expo/metro-runtime': {
|
|
41
|
+
status: 'supported',
|
|
42
|
+
supportTier: 'verified',
|
|
43
|
+
note: 'Metro runtime is part of the validated managed Expo routing/bundling chain and keeps Expo workspace peers aligned.',
|
|
44
|
+
},
|
|
40
45
|
'@babel/runtime': {
|
|
41
46
|
status: 'supported',
|
|
42
47
|
supportTier: 'verified',
|
|
@@ -62,6 +67,11 @@ exports.DEPENDENCY_CATALOG = {
|
|
|
62
67
|
supportTier: 'verified',
|
|
63
68
|
note: 'React is treated as a baseline JavaScript dependency.',
|
|
64
69
|
},
|
|
70
|
+
'react-dom': {
|
|
71
|
+
status: 'supported',
|
|
72
|
+
supportTier: 'verified',
|
|
73
|
+
note: 'React DOM is treated as a workspace peer for Expo Router and web-capable managed Expo projects inside the validated matrix.',
|
|
74
|
+
},
|
|
65
75
|
'react-native': {
|
|
66
76
|
status: 'supported',
|
|
67
77
|
supportTier: 'verified',
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export declare const PUBLIC_RELEASE_TRACKS: {
|
|
2
|
+
readonly latest: "fully accepted verified only";
|
|
3
|
+
readonly next: "preview fast track";
|
|
4
|
+
};
|
|
5
|
+
export declare const PRIMARY_SAMPLE_PATH = "examples/official-ui-stack-sample";
|
|
6
|
+
export declare const PREVIEW_SAMPLE_PATH = "examples/official-native-capabilities-sample";
|
|
7
|
+
export declare const SUPPORTING_SAMPLE_PATHS: readonly ["examples/official-app-shell-sample", "examples/official-minimal-sample"];
|
|
8
|
+
export declare const VERIFIED_JS_UI_CAPABILITY_NAMES: readonly ["expo-router", "expo-linking", "expo-constants", ...("react-native-reanimated" | "react-native-svg")[]];
|
|
9
|
+
export declare const PREVIEW_CAPABILITY_DEFINITIONS: import("..").CapabilityDefinition[];
|
|
10
|
+
export declare const EXPERIMENTAL_CAPABILITY_NAMES: readonly [...string[], "react-native-gesture-handler"];
|
|
11
|
+
export declare const PUBLIC_CURRENT_VERSION = "1.7.3";
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.PUBLIC_CURRENT_VERSION = exports.EXPERIMENTAL_CAPABILITY_NAMES = exports.PREVIEW_CAPABILITY_DEFINITIONS = exports.VERIFIED_JS_UI_CAPABILITY_NAMES = exports.SUPPORTING_SAMPLE_PATHS = exports.PREVIEW_SAMPLE_PATH = exports.PRIMARY_SAMPLE_PATH = exports.PUBLIC_RELEASE_TRACKS = void 0;
|
|
4
|
+
const constants_1 = require("../core/constants");
|
|
5
|
+
const capabilities_1 = require("./capabilities");
|
|
6
|
+
const uiStack_1 = require("./uiStack");
|
|
7
|
+
exports.PUBLIC_RELEASE_TRACKS = {
|
|
8
|
+
latest: 'fully accepted verified only',
|
|
9
|
+
next: 'preview fast track',
|
|
10
|
+
};
|
|
11
|
+
exports.PRIMARY_SAMPLE_PATH = 'examples/official-ui-stack-sample';
|
|
12
|
+
exports.PREVIEW_SAMPLE_PATH = 'examples/official-native-capabilities-sample';
|
|
13
|
+
exports.SUPPORTING_SAMPLE_PATHS = [
|
|
14
|
+
'examples/official-app-shell-sample',
|
|
15
|
+
'examples/official-minimal-sample',
|
|
16
|
+
];
|
|
17
|
+
exports.VERIFIED_JS_UI_CAPABILITY_NAMES = [
|
|
18
|
+
'expo-router',
|
|
19
|
+
'expo-linking',
|
|
20
|
+
'expo-constants',
|
|
21
|
+
...uiStack_1.UI_STACK_VALIDATED_ADAPTERS.map((adapter) => adapter.canonicalPackageName),
|
|
22
|
+
];
|
|
23
|
+
exports.PREVIEW_CAPABILITY_DEFINITIONS = capabilities_1.CAPABILITY_DEFINITIONS.filter((definition) => definition.supportTier === 'preview');
|
|
24
|
+
exports.EXPERIMENTAL_CAPABILITY_NAMES = [
|
|
25
|
+
...capabilities_1.CAPABILITY_DEFINITIONS.filter((definition) => definition.supportTier === 'experimental').map((definition) => definition.packageName),
|
|
26
|
+
'react-native-gesture-handler',
|
|
27
|
+
];
|
|
28
|
+
exports.PUBLIC_CURRENT_VERSION = constants_1.TOOLKIT_VERSION;
|
|
@@ -6,10 +6,12 @@ const uiStack_1 = require("./uiStack");
|
|
|
6
6
|
exports.DEFAULT_VALIDATED_MATRIX_ID = 'expo55-rnoh082-ui-stack';
|
|
7
7
|
const BASE_ALLOWED_DEPENDENCIES = [
|
|
8
8
|
'expo',
|
|
9
|
+
'@expo/metro-runtime',
|
|
9
10
|
'expo-constants',
|
|
10
11
|
'expo-linking',
|
|
11
12
|
'expo-router',
|
|
12
13
|
'react',
|
|
14
|
+
'react-dom',
|
|
13
15
|
'react-native',
|
|
14
16
|
'expo-status-bar',
|
|
15
17
|
'@babel/runtime',
|
|
@@ -36,6 +38,9 @@ exports.VALIDATED_RELEASE_MATRICES = {
|
|
|
36
38
|
required: true,
|
|
37
39
|
version: '>=55.0.0 <56.0.0',
|
|
38
40
|
},
|
|
41
|
+
'@expo/metro-runtime': {
|
|
42
|
+
version: '>=55.0.0 <56.0.0',
|
|
43
|
+
},
|
|
39
44
|
'expo-constants': {
|
|
40
45
|
version: '>=55.0.0 <56.0.0',
|
|
41
46
|
},
|
|
@@ -43,12 +48,15 @@ exports.VALIDATED_RELEASE_MATRICES = {
|
|
|
43
48
|
version: '>=55.0.0 <56.0.0',
|
|
44
49
|
},
|
|
45
50
|
'expo-router': {
|
|
46
|
-
version: '>=
|
|
51
|
+
version: '>=55.0.0 <56.0.0',
|
|
47
52
|
},
|
|
48
53
|
react: {
|
|
49
54
|
required: true,
|
|
50
55
|
version: '19.1.1',
|
|
51
56
|
},
|
|
57
|
+
'react-dom': {
|
|
58
|
+
version: '19.1.1',
|
|
59
|
+
},
|
|
52
60
|
'react-native': {
|
|
53
61
|
required: true,
|
|
54
62
|
version: '0.82.1',
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export type DocsLocale = 'zh' | 'en';
|
|
2
|
+
export declare function renderReadmeCurrentStatus(locale: DocsLocale): string;
|
|
3
|
+
export declare function renderReadmeSupportMatrixSection(locale: DocsLocale): string;
|
|
4
|
+
export declare function renderSupportMatrixVerifiedMatrix(locale: DocsLocale): string;
|
|
5
|
+
export declare function renderSupportMatrixVerifiedAllowlist(): string;
|
|
6
|
+
export declare function renderSupportMatrixCapabilityTelemetry(locale: DocsLocale): string;
|
|
7
|
+
export declare function renderSupportMatrixPreviewCapabilities(locale: DocsLocale): string;
|
|
8
|
+
export declare function renderSupportMatrixUiStackRules(locale: DocsLocale): string;
|
|
9
|
+
export declare function renderSupportMatrixReleaseTracks(locale: DocsLocale): string;
|
|
@@ -0,0 +1,248 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.renderReadmeCurrentStatus = renderReadmeCurrentStatus;
|
|
4
|
+
exports.renderReadmeSupportMatrixSection = renderReadmeSupportMatrixSection;
|
|
5
|
+
exports.renderSupportMatrixVerifiedMatrix = renderSupportMatrixVerifiedMatrix;
|
|
6
|
+
exports.renderSupportMatrixVerifiedAllowlist = renderSupportMatrixVerifiedAllowlist;
|
|
7
|
+
exports.renderSupportMatrixCapabilityTelemetry = renderSupportMatrixCapabilityTelemetry;
|
|
8
|
+
exports.renderSupportMatrixPreviewCapabilities = renderSupportMatrixPreviewCapabilities;
|
|
9
|
+
exports.renderSupportMatrixUiStackRules = renderSupportMatrixUiStackRules;
|
|
10
|
+
exports.renderSupportMatrixReleaseTracks = renderSupportMatrixReleaseTracks;
|
|
11
|
+
const publicDocs_1 = require("../data/publicDocs");
|
|
12
|
+
const validatedMatrices_1 = require("../data/validatedMatrices");
|
|
13
|
+
const uiStack_1 = require("../data/uiStack");
|
|
14
|
+
const matrix = validatedMatrices_1.VALIDATED_RELEASE_MATRICES[validatedMatrices_1.DEFAULT_VALIDATED_MATRIX_ID];
|
|
15
|
+
function renderReadmeCurrentStatus(locale) {
|
|
16
|
+
const headers = locale === 'zh'
|
|
17
|
+
? ['项目', '说明']
|
|
18
|
+
: ['Item', 'Status'];
|
|
19
|
+
const versionLabel = locale === 'zh' ? '当前版本' : 'Current version';
|
|
20
|
+
const supportModelLabel = locale === 'zh' ? '支持模型' : 'Support model';
|
|
21
|
+
const verifiedMatrixLabel = locale === 'zh' ? '唯一 `verified` 公开矩阵' : 'Public `verified` matrix';
|
|
22
|
+
const inputLabel = locale === 'zh' ? '输入范围' : 'Supported input';
|
|
23
|
+
const verifiedCapabilitiesLabel = locale === 'zh' ? '`verified` JS/UI 能力' : '`verified` JS/UI capabilities';
|
|
24
|
+
const previewLabel = locale === 'zh' ? '`preview` 原生能力' : '`preview` native capabilities';
|
|
25
|
+
const experimentalLabel = locale === 'zh' ? '`experimental` 能力' : '`experimental` capabilities';
|
|
26
|
+
const releaseTracksLabel = locale === 'zh' ? '发布轨' : 'Release tracks';
|
|
27
|
+
const telemetryLabel = locale === 'zh' ? 'capability 遥测' : 'Capability telemetry';
|
|
28
|
+
const buildPathLabel = locale === 'zh' ? '构建链' : 'Build path';
|
|
29
|
+
const primarySampleLabel = locale === 'zh' ? '主 sample' : 'Primary sample';
|
|
30
|
+
const previewSampleLabel = locale === 'zh' ? 'preview sample' : 'Preview sample';
|
|
31
|
+
const supportingSamplesLabel = locale === 'zh' ? '辅助 onboarding samples' : 'Supporting onboarding samples';
|
|
32
|
+
const releaseTracksValue = locale === 'zh'
|
|
33
|
+
? `\`latest\` = ${publicDocs_1.PUBLIC_RELEASE_TRACKS.latest};\`next\` = ${publicDocs_1.PUBLIC_RELEASE_TRACKS.next}`
|
|
34
|
+
: `\`latest\` = fully accepted \`verified\` only; \`next\` = ${publicDocs_1.PUBLIC_RELEASE_TRACKS.next}`;
|
|
35
|
+
const inputValue = locale === 'zh' ? 'Managed/CNG Expo 项目' : 'Managed/CNG Expo projects';
|
|
36
|
+
const listJoiner = locale === 'zh' ? '、' : ', ';
|
|
37
|
+
return [
|
|
38
|
+
`| ${headers[0]} | ${headers[1]} |`,
|
|
39
|
+
'| --- | --- |',
|
|
40
|
+
`| ${versionLabel} | \`v${publicDocs_1.PUBLIC_CURRENT_VERSION}\` |`,
|
|
41
|
+
`| ${supportModelLabel} | \`verified + preview + experimental\` |`,
|
|
42
|
+
`| ${verifiedMatrixLabel} | \`${validatedMatrices_1.DEFAULT_VALIDATED_MATRIX_ID}\` |`,
|
|
43
|
+
`| ${inputLabel} | ${inputValue} |`,
|
|
44
|
+
`| ${verifiedCapabilitiesLabel} | ${joinInlineCode(publicDocs_1.VERIFIED_JS_UI_CAPABILITY_NAMES, listJoiner)} |`,
|
|
45
|
+
`| ${previewLabel} | ${joinInlineCode(publicDocs_1.PREVIEW_CAPABILITY_DEFINITIONS.map((definition) => definition.packageName), listJoiner)} |`,
|
|
46
|
+
`| ${experimentalLabel} | ${joinInlineCode(publicDocs_1.EXPERIMENTAL_CAPABILITY_NAMES, listJoiner)} |`,
|
|
47
|
+
`| ${releaseTracksLabel} | ${releaseTracksValue} |`,
|
|
48
|
+
`| ${telemetryLabel} | \`runtimeMode\` + \`evidence(...)\` + \`evidenceSource(...)\` |`,
|
|
49
|
+
`| ${buildPathLabel} | \`doctor -> init -> bundle -> build-hap\` |`,
|
|
50
|
+
`| ${primarySampleLabel} | \`${publicDocs_1.PRIMARY_SAMPLE_PATH}\` |`,
|
|
51
|
+
`| ${previewSampleLabel} | \`${publicDocs_1.PREVIEW_SAMPLE_PATH}\` |`,
|
|
52
|
+
`| ${supportingSamplesLabel} | ${publicDocs_1.SUPPORTING_SAMPLE_PATHS.map((samplePath) => `\`${samplePath}\``).join(locale === 'zh' ? '、' : ', ')} |`,
|
|
53
|
+
].join('\n');
|
|
54
|
+
}
|
|
55
|
+
function renderReadmeSupportMatrixSection(locale) {
|
|
56
|
+
const verifiedLine = locale === 'zh'
|
|
57
|
+
? `- \`verified\`:唯一公开矩阵仍是 \`${validatedMatrices_1.DEFAULT_VALIDATED_MATRIX_ID}\``
|
|
58
|
+
: `- \`verified\`: the only public matrix remains \`${validatedMatrices_1.DEFAULT_VALIDATED_MATRIX_ID}\``;
|
|
59
|
+
const previewLine = locale === 'zh'
|
|
60
|
+
? `- \`preview\`:${joinInlineCode(publicDocs_1.PREVIEW_CAPABILITY_DEFINITIONS.map((definition) => definition.packageName))}`
|
|
61
|
+
: `- \`preview\`: ${joinInlineCode(publicDocs_1.PREVIEW_CAPABILITY_DEFINITIONS.map((definition) => definition.packageName))}`;
|
|
62
|
+
const experimentalLine = locale === 'zh'
|
|
63
|
+
? `- \`experimental\`:${joinInlineCode(publicDocs_1.EXPERIMENTAL_CAPABILITY_NAMES)}`
|
|
64
|
+
: `- \`experimental\`: ${joinInlineCode(publicDocs_1.EXPERIMENTAL_CAPABILITY_NAMES)}`;
|
|
65
|
+
const strictLine = locale === 'zh'
|
|
66
|
+
? '`doctor --strict` 继续只代表 `verified`。`doctor --target-tier preview` 会在同一 runtime matrix 下额外放行 preview 能力,但这不等于它们已经进入正式承诺。'
|
|
67
|
+
: '`doctor --strict` still means `verified` only. `doctor --target-tier preview` allows the same runtime matrix plus preview-tier capabilities, but that does not promote them into the formal public promise.';
|
|
68
|
+
const telemetryLines = locale === 'zh'
|
|
69
|
+
? [
|
|
70
|
+
'- `doctor-report.json` 的 `capabilities[]` 会带出 `runtimeMode`',
|
|
71
|
+
'- `doctor-report.json` 与 `toolkit-config.json` 会带出 `evidence.bundle`、`evidence.debugBuild`、`evidence.device`、`evidence.release`',
|
|
72
|
+
'- `doctor-report.json` 与 `toolkit-config.json` 会带出 `evidenceSource.bundle`、`evidenceSource.debugBuild`、`evidenceSource.device`、`evidenceSource.release`',
|
|
73
|
+
'- `runtimeMode=shim` 说明当前仍未进入 verified runtime path,即使 bundle / debug build 已经可走通',
|
|
74
|
+
'- `evidenceSource.device=manual-doc` 表示当前只有人工设备验收记录,不代表机器自动验证',
|
|
75
|
+
]
|
|
76
|
+
: [
|
|
77
|
+
'- `doctor-report.json` exposes `capabilities[].runtimeMode`',
|
|
78
|
+
'- `doctor-report.json` and `toolkit-config.json` expose `evidence.bundle`, `evidence.debugBuild`, `evidence.device`, and `evidence.release`',
|
|
79
|
+
'- `doctor-report.json` and `toolkit-config.json` expose `evidenceSource.bundle`, `evidenceSource.debugBuild`, `evidenceSource.device`, and `evidenceSource.release`',
|
|
80
|
+
'- `runtimeMode=shim` means the capability still has not reached a verified runtime path even if bundling and debug-build scaffolding already exist',
|
|
81
|
+
'- `evidenceSource.device=manual-doc` means the current device signal comes from manual acceptance records, not automated verification',
|
|
82
|
+
];
|
|
83
|
+
return [verifiedLine, previewLine, experimentalLine, '', strictLine, '', ...telemetryLines].join('\n');
|
|
84
|
+
}
|
|
85
|
+
function renderSupportMatrixVerifiedMatrix(locale) {
|
|
86
|
+
const appShellValue = locale === 'zh'
|
|
87
|
+
? '`expo-router` `55.x`、`expo-linking` `55.x`、`expo-constants` `55.x`、`@expo/metro-runtime` `55.x`、`react-dom` `19.1.1`'
|
|
88
|
+
: '`expo-router` `55.x`, `expo-linking` `55.x`, `expo-constants` `55.x`, `@expo/metro-runtime` `55.x`, `react-dom` `19.1.1`';
|
|
89
|
+
const uiStackValue = locale === 'zh'
|
|
90
|
+
? '`react-native-reanimated` `3.6.0`、`react-native-svg` `15.0.0`'
|
|
91
|
+
: '`react-native-reanimated` `3.6.0`, `react-native-svg` `15.0.0`';
|
|
92
|
+
return [
|
|
93
|
+
'| 项目 | 要求 |',
|
|
94
|
+
'| --- | --- |',
|
|
95
|
+
`| Expo SDK | \`${matrix.expoSdkVersion}\` |`,
|
|
96
|
+
`| React | \`${matrix.dependencyRules.react?.version}\` |`,
|
|
97
|
+
`| React Native | \`${matrix.dependencyRules['react-native']?.version}\` |`,
|
|
98
|
+
`| \`@react-native-oh/react-native-harmony\` | \`${matrix.dependencyRules['@react-native-oh/react-native-harmony']?.version}\` |`,
|
|
99
|
+
`| \`@react-native-oh/react-native-harmony-cli\` | \`${matrix.dependencyRules['@react-native-oh/react-native-harmony-cli']?.version}\` |`,
|
|
100
|
+
'| `@react-native-community/cli` | `20.x` |',
|
|
101
|
+
'| `metro` | `0.83.x` |',
|
|
102
|
+
`| App Shell 依赖 | ${appShellValue} |`,
|
|
103
|
+
`| UI stack 依赖 | ${uiStackValue} |`,
|
|
104
|
+
'| 原生标识 | 至少设置 `android.package` 或 `ios.bundleIdentifier` |',
|
|
105
|
+
].join('\n');
|
|
106
|
+
}
|
|
107
|
+
function renderSupportMatrixVerifiedAllowlist() {
|
|
108
|
+
return matrix.allowedDependencies.map((dependencyName) => `- \`${dependencyName}\``).join('\n');
|
|
109
|
+
}
|
|
110
|
+
function renderSupportMatrixCapabilityTelemetry(locale) {
|
|
111
|
+
const lines = locale === 'zh'
|
|
112
|
+
? [
|
|
113
|
+
'所有 capability 从现在开始都同时公开:',
|
|
114
|
+
'',
|
|
115
|
+
'- `supportTier`',
|
|
116
|
+
'- `runtimeMode`',
|
|
117
|
+
'- `evidence.bundle`',
|
|
118
|
+
'- `evidence.debugBuild`',
|
|
119
|
+
'- `evidence.device`',
|
|
120
|
+
'- `evidence.release`',
|
|
121
|
+
'- `evidenceSource.bundle`',
|
|
122
|
+
'- `evidenceSource.debugBuild`',
|
|
123
|
+
'- `evidenceSource.device`',
|
|
124
|
+
'- `evidenceSource.release`',
|
|
125
|
+
'',
|
|
126
|
+
'判读规则:',
|
|
127
|
+
'',
|
|
128
|
+
'- `runtimeMode=shim`:说明当前还在桥接或占位阶段,即使 bundle / debug build 已完成,也不应宣称 verified',
|
|
129
|
+
'- `runtimeMode=adapter`:说明已经进入真实适配路径,但仍缺少某些验收证据',
|
|
130
|
+
'- `runtimeMode=verified`:说明能力已进入正式承诺,且证据闭环完成',
|
|
131
|
+
]
|
|
132
|
+
: [
|
|
133
|
+
'All capabilities now publish the following fields together:',
|
|
134
|
+
'',
|
|
135
|
+
'- `supportTier`',
|
|
136
|
+
'- `runtimeMode`',
|
|
137
|
+
'- `evidence.bundle`',
|
|
138
|
+
'- `evidence.debugBuild`',
|
|
139
|
+
'- `evidence.device`',
|
|
140
|
+
'- `evidence.release`',
|
|
141
|
+
'- `evidenceSource.bundle`',
|
|
142
|
+
'- `evidenceSource.debugBuild`',
|
|
143
|
+
'- `evidenceSource.device`',
|
|
144
|
+
'- `evidenceSource.release`',
|
|
145
|
+
'',
|
|
146
|
+
'Reading rules:',
|
|
147
|
+
'',
|
|
148
|
+
'- `runtimeMode=shim`: the capability is still on a bridge or placeholder path and must not be described as verified',
|
|
149
|
+
'- `runtimeMode=adapter`: the capability is on a real adapter path but still lacks part of the evidence needed for verified promotion',
|
|
150
|
+
'- `runtimeMode=verified`: the capability has entered the formal public promise and closed the evidence loop',
|
|
151
|
+
];
|
|
152
|
+
return lines.join('\n');
|
|
153
|
+
}
|
|
154
|
+
function renderSupportMatrixPreviewCapabilities(locale) {
|
|
155
|
+
const headers = locale === 'zh'
|
|
156
|
+
? ['Expo 能力', '当前层级', 'runtimeMode', 'evidence', 'Harmony 依赖方向', '受管权限', '官方 sample route']
|
|
157
|
+
: ['Expo capability', 'Support tier', 'runtimeMode', 'evidence', 'Harmony dependency direction', 'Managed permissions', 'Official sample route'];
|
|
158
|
+
return [
|
|
159
|
+
`| ${headers.join(' | ')} |`,
|
|
160
|
+
`| ${headers.map(() => '---').join(' | ')} |`,
|
|
161
|
+
...publicDocs_1.PREVIEW_CAPABILITY_DEFINITIONS.map((definition) => {
|
|
162
|
+
const dependencyDirection = definition.nativePackageNames.length > 0
|
|
163
|
+
? definition.nativePackageNames.join(', ')
|
|
164
|
+
: 'toolkit-managed bridge';
|
|
165
|
+
const permissions = definition.harmonyPermissions.length > 0
|
|
166
|
+
? definition.harmonyPermissions.join(locale === 'zh' ? '、' : ', ')
|
|
167
|
+
: locale === 'zh'
|
|
168
|
+
? '无新增必需权限'
|
|
169
|
+
: 'no additional required permissions';
|
|
170
|
+
return [
|
|
171
|
+
`\`${definition.packageName}\``,
|
|
172
|
+
`\`${definition.supportTier}\``,
|
|
173
|
+
`\`${definition.runtimeMode}\``,
|
|
174
|
+
`\`${renderEvidence(definition)}\``,
|
|
175
|
+
dependencyDirection,
|
|
176
|
+
permissions,
|
|
177
|
+
`\`${definition.sampleRoute}\``,
|
|
178
|
+
].join(' | ');
|
|
179
|
+
}).map((row) => `| ${row} |`),
|
|
180
|
+
].join('\n');
|
|
181
|
+
}
|
|
182
|
+
function renderSupportMatrixUiStackRules(locale) {
|
|
183
|
+
const intro = locale === 'zh'
|
|
184
|
+
? 'canonical 包与 Harmony adapter 包固定为双向强制:'
|
|
185
|
+
: 'Canonical packages and Harmony adapters stay strictly paired in both directions:';
|
|
186
|
+
const rules = locale === 'zh'
|
|
187
|
+
? [
|
|
188
|
+
'规则固定为:',
|
|
189
|
+
'',
|
|
190
|
+
'- 出现 canonical 包,必须同时出现对应 `@react-native-oh-tpl/*`',
|
|
191
|
+
'- 出现 `@react-native-oh-tpl/*`,也必须同时出现对应 canonical 包',
|
|
192
|
+
'- canonical 包按 semver 校验',
|
|
193
|
+
'- `@react-native-oh-tpl/*` 按 exact dependency specifier 校验',
|
|
194
|
+
'',
|
|
195
|
+
'当前固定 exact specifier:',
|
|
196
|
+
]
|
|
197
|
+
: [
|
|
198
|
+
'The enforced rules are:',
|
|
199
|
+
'',
|
|
200
|
+
'- canonical packages require their matching `@react-native-oh-tpl/*` adapters',
|
|
201
|
+
'- adapter packages also require their canonical counterparts',
|
|
202
|
+
'- canonical packages are validated with semver ranges',
|
|
203
|
+
'- `@react-native-oh-tpl/*` adapters are validated against exact dependency specifiers',
|
|
204
|
+
'',
|
|
205
|
+
'Pinned exact specifiers:',
|
|
206
|
+
];
|
|
207
|
+
return [
|
|
208
|
+
intro,
|
|
209
|
+
'',
|
|
210
|
+
...uiStack_1.UI_STACK_VALIDATED_ADAPTERS.map((adapter) => `- \`${adapter.canonicalPackageName}\` ↔ \`${adapter.adapterPackageName}\``),
|
|
211
|
+
'',
|
|
212
|
+
...rules,
|
|
213
|
+
'',
|
|
214
|
+
...uiStack_1.UI_STACK_VALIDATED_ADAPTERS.map((adapter) => `- \`${adapter.adapterPackageName}\`: \`${(0, uiStack_1.getUiStackAdapterSpecifier)(adapter)}\``),
|
|
215
|
+
].join('\n');
|
|
216
|
+
}
|
|
217
|
+
function renderSupportMatrixReleaseTracks(locale) {
|
|
218
|
+
return locale === 'zh'
|
|
219
|
+
? [
|
|
220
|
+
'- `latest`',
|
|
221
|
+
' - 只承接完整验收的 `verified` 能力',
|
|
222
|
+
' - 只允许 verified sample / gate 作为发布依据',
|
|
223
|
+
'- `next`',
|
|
224
|
+
' - 承接 preview fast track',
|
|
225
|
+
' - 必须至少通过 preview sample、bundle、debug build gate',
|
|
226
|
+
' - 不得被描述为 verified 或 release-ready',
|
|
227
|
+
].join('\n')
|
|
228
|
+
: [
|
|
229
|
+
'- `latest`',
|
|
230
|
+
' - only carries fully accepted `verified` capabilities',
|
|
231
|
+
' - only verified samples and gates may justify a release',
|
|
232
|
+
'- `next`',
|
|
233
|
+
' - carries preview fast-track work',
|
|
234
|
+
' - must at least pass the preview sample, bundle, and debug-build gates',
|
|
235
|
+
' - must not be described as verified or release-ready',
|
|
236
|
+
].join('\n');
|
|
237
|
+
}
|
|
238
|
+
function joinInlineCode(entries, joiner = ', ') {
|
|
239
|
+
return entries.map((entry) => `\`${entry}\``).join(joiner);
|
|
240
|
+
}
|
|
241
|
+
function renderEvidence(definition) {
|
|
242
|
+
return [
|
|
243
|
+
`bundle=${definition.evidence.bundle ? 'yes' : 'no'}[${definition.evidenceSource.bundle}]`,
|
|
244
|
+
`debugBuild=${definition.evidence.debugBuild ? 'yes' : 'no'}[${definition.evidenceSource.debugBuild}]`,
|
|
245
|
+
`device=${definition.evidence.device ? 'yes' : 'no'}[${definition.evidenceSource.device}]`,
|
|
246
|
+
`release=${definition.evidence.release ? 'yes' : 'no'}[${definition.evidenceSource.release}]`,
|
|
247
|
+
].join(', ');
|
|
248
|
+
}
|
package/build/types.d.ts
CHANGED
|
@@ -3,6 +3,8 @@ export type EligibilityStatus = 'eligible' | 'ineligible';
|
|
|
3
3
|
export type SupportTier = 'verified' | 'preview' | 'experimental' | 'unsupported';
|
|
4
4
|
export type DoctorTargetTier = Exclude<SupportTier, 'unsupported'>;
|
|
5
5
|
export type CapabilityRuntimeMode = 'shim' | 'adapter' | 'verified';
|
|
6
|
+
export type CapabilityEvidenceSource = 'automated' | 'manual-doc' | 'none';
|
|
7
|
+
export type DependencyBuildabilityRisk = 'known' | 'js-only-unknown' | 'native-risk' | 'unresolved';
|
|
6
8
|
export type DependencySource = 'dependency' | 'devDependency' | 'peerDependency' | 'expo-plugin';
|
|
7
9
|
export interface ExpoHarmonyPluginProps {
|
|
8
10
|
bundleName?: string;
|
|
@@ -66,6 +68,7 @@ export interface DetectedDependency {
|
|
|
66
68
|
source: DependencySource;
|
|
67
69
|
status: CompatibilityStatus;
|
|
68
70
|
supportTier: SupportTier;
|
|
71
|
+
buildabilityRisk: DependencyBuildabilityRisk;
|
|
69
72
|
blocking: boolean;
|
|
70
73
|
note: string;
|
|
71
74
|
replacement?: string;
|
|
@@ -89,6 +92,12 @@ export interface CapabilityEvidence {
|
|
|
89
92
|
device: boolean;
|
|
90
93
|
release: boolean;
|
|
91
94
|
}
|
|
95
|
+
export interface CapabilityEvidenceSourceMap {
|
|
96
|
+
bundle: CapabilityEvidenceSource;
|
|
97
|
+
debugBuild: CapabilityEvidenceSource;
|
|
98
|
+
device: CapabilityEvidenceSource;
|
|
99
|
+
release: CapabilityEvidenceSource;
|
|
100
|
+
}
|
|
92
101
|
export interface CapabilityDefinition {
|
|
93
102
|
id: string;
|
|
94
103
|
packageName: string;
|
|
@@ -96,6 +105,7 @@ export interface CapabilityDefinition {
|
|
|
96
105
|
supportTier: DoctorTargetTier;
|
|
97
106
|
runtimeMode: CapabilityRuntimeMode;
|
|
98
107
|
evidence: CapabilityEvidence;
|
|
108
|
+
evidenceSource: CapabilityEvidenceSourceMap;
|
|
99
109
|
note: string;
|
|
100
110
|
docsUrl?: string;
|
|
101
111
|
nativePackageNames: string[];
|
|
@@ -110,6 +120,7 @@ export interface ProjectCapabilityReport {
|
|
|
110
120
|
supportTier: DoctorTargetTier;
|
|
111
121
|
runtimeMode: CapabilityRuntimeMode;
|
|
112
122
|
evidence: CapabilityEvidence;
|
|
123
|
+
evidenceSource: CapabilityEvidenceSourceMap;
|
|
113
124
|
note: string;
|
|
114
125
|
docsUrl?: string;
|
|
115
126
|
nativePackageNames: string[];
|
|
@@ -123,6 +134,7 @@ export interface ManagedCapabilityRecord {
|
|
|
123
134
|
supportTier: DoctorTargetTier;
|
|
124
135
|
runtimeMode: CapabilityRuntimeMode;
|
|
125
136
|
evidence: CapabilityEvidence;
|
|
137
|
+
evidenceSource: CapabilityEvidenceSourceMap;
|
|
126
138
|
}
|
|
127
139
|
export interface DoctorReport {
|
|
128
140
|
generatedAt: string;
|
package/docs/cli-build.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# CLI 构建指南
|
|
2
2
|
|
|
3
|
-
`v1.7.
|
|
3
|
+
`v1.7.3` 延续 `verified + preview + experimental` 支持分层,并把四项 preview capability 的现有 `🟠` 缺口收口到明确 `🟡` 子集,其中 `expo55-rnoh082-ui-stack` 仍是唯一 verified 矩阵。
|
|
4
4
|
|
|
5
5
|
CLI 命令集合不变:
|
|
6
6
|
|
package/docs/npm-release.md
CHANGED
|
@@ -60,6 +60,7 @@ pnpm release:check
|
|
|
60
60
|
|
|
61
61
|
- hosted CI 默认仍可通过 `EXPO_HARMONY_RELEASE_SKIP_HAP=1` 跳过真实 DevEco HAP 构建
|
|
62
62
|
- debug / release HAP gate 继续由 capability acceptance、带工具链环境的 CI 或本地验收补齐
|
|
63
|
+
- preview capability 若在报告里显示 `device=yes`,必须同时以 `evidenceSource.device=manual-doc` 对外说明其来源,不得表述成 CI 自动设备验证
|
|
63
64
|
|
|
64
65
|
## 手动发布
|
|
65
66
|
|
|
@@ -38,7 +38,7 @@ pnpm run harmony:build:debug
|
|
|
38
38
|
如果要继续验证 release 构建,先准备本地签名覆盖文件:
|
|
39
39
|
|
|
40
40
|
```bash
|
|
41
|
-
|
|
41
|
+
cp .expo-harmony/signing.local.example.json .expo-harmony/signing.local.json
|
|
42
42
|
$EDITOR .expo-harmony/signing.local.json
|
|
43
43
|
pnpm run harmony:env
|
|
44
44
|
pnpm run harmony:build:release
|
|
@@ -46,6 +46,7 @@ pnpm run harmony:build:release
|
|
|
46
46
|
|
|
47
47
|
说明:
|
|
48
48
|
|
|
49
|
+
- `.expo-harmony/signing.local.example.json` 是可直接复制的本地 signing 範本
|
|
49
50
|
- `.expo-harmony/signing.local.json` 是本地 signing 入口
|
|
50
51
|
- signing 缺失时,`harmony:env` 和 `harmony:build:release` 会明确提示,不会静默跳过
|
|
51
52
|
|
|
@@ -35,7 +35,7 @@ pnpm run harmony:build:debug
|
|
|
35
35
|
如果要继续验证 release 构建,先准备本地签名覆盖文件:
|
|
36
36
|
|
|
37
37
|
```bash
|
|
38
|
-
|
|
38
|
+
cp .expo-harmony/signing.local.example.json .expo-harmony/signing.local.json
|
|
39
39
|
$EDITOR .expo-harmony/signing.local.json
|
|
40
40
|
pnpm run harmony:env
|
|
41
41
|
pnpm run harmony:build:release
|
|
@@ -43,6 +43,7 @@ pnpm run harmony:build:release
|
|
|
43
43
|
|
|
44
44
|
说明:
|
|
45
45
|
|
|
46
|
+
- `.expo-harmony/signing.local.example.json` 是可直接复制的本地 signing 範本
|
|
46
47
|
- `.expo-harmony/signing.local.json` 是本地 signing 入口
|
|
47
48
|
- toolkit 会把本地 signing 合并进 `harmony/build-profile.json5`
|
|
48
49
|
- 如果 signing 没配置,`harmony:env` 会明确报缺失;这属于预期阻断
|