接入移动壳安全区布局

Expo 移动壳使用 SafeAreaProvider 和 SafeAreaView 包裹 WebView

新增安全区边界配置和测试

补充移动壳安全区依赖检查和架构文档
This commit is contained in:
2026-06-18 08:14:27 +08:00
parent 94046153c6
commit 94a866b48b
9 changed files with 76 additions and 27 deletions

View File

@@ -124,6 +124,9 @@ for (const snippet of [
'subscribeMobileNetworkStatus',
'navigation.canGoBack',
'buildHostBridgeMessageScript',
'SafeAreaProvider',
'SafeAreaView',
'MOBILE_SHELL_SAFE_AREA_EDGES',
]) {
if (!appSource.includes(snippet)) {
throw new Error(`mobile shell App missing ${snippet}`);
@@ -137,6 +140,7 @@ for (const dependency of [
'expo-network',
'expo-notifications',
'expo-sharing',
'react-native-safe-area-context',
]) {
if (!packageConfig.dependencies?.[dependency]) {
throw new Error(`mobile shell package missing ${dependency}`);