接入移动端原生扫码能力

新增 scanner.scanQrCode HostBridge 契约与二维码结果归一。

接入 Expo Camera 扫码 overlay 并保留 H5 浏览器扫码回退。

让 Tauri 白名单识别扫码 method 但不声明桌面扫码能力。

同步原生壳门禁、Expo 权限检查、方案文档和共享决策记录。
This commit is contained in:
2026-06-19 05:13:21 +08:00
parent a471e69455
commit e4b9cbf09d
26 changed files with 758 additions and 28 deletions
+5 -1
View File
@@ -43,6 +43,7 @@ const h5HostBridgeScannedFacadeImports = new Set([
'requestHostHapticsImpact',
'requestHostLogin',
'requestHostPayment',
'scanHostQrCode',
'setHostAppBadgeCount',
'setHostAppTitle',
'setHostShareTarget',
@@ -120,9 +121,11 @@ const expectedMobileHostBridgeFiles = [
'dispatch.ts',
'files.ts',
'protocol.ts',
'scanner.ts',
'share.ts',
];
const expectedMobileShellFiles = [
'QrScannerOverlay.tsx',
'ShellApp.tsx',
'deepLink.test.ts',
'deepLink.ts',
@@ -718,8 +721,9 @@ function assertNativeShellCapabilityPlan() {
...sharedMethods.slice(8, 12),
'network.statusChanged',
...sharedMethods.slice(12, 21),
sharedMethods[21],
'file.imageDropped',
...sharedMethods.slice(21),
...sharedMethods.slice(22),
],
'native shell documented method table',
);