接入原生壳外观查询能力

新增 HostBridge appearance.getColorScheme 只读契约和 H5 facade

Expo 壳通过 React Native Appearance 读取系统配色

Tauri 壳通过主窗口 theme 读取桌面配色

补齐外观查询测试、漂移检查和架构文档
This commit is contained in:
2026-06-18 02:00:49 +08:00
parent 6b39bdbe19
commit 45eec17007
13 changed files with 164 additions and 15 deletions

View File

@@ -153,6 +153,7 @@ if (!appSource.includes('capabilities: resolveMobileHostCapabilities()')) {
for (const capability of [
'host.getRuntime',
'appearance.getColorScheme',
'share.open',
'share.setTarget',
'navigation.openNativePage',
@@ -175,3 +176,7 @@ if (!iosMobileCapabilitySet.has('app.setBadgeCount')) {
if (mobileCapabilitySet.has('app.setBadgeCount')) {
throw new Error('Android mobile shell base capabilities must not include app.setBadgeCount');
}
if (!bridgeSource.includes('Appearance.getColorScheme()')) {
throw new Error('mobile shell HostBridge must read the native color scheme');
}