fix: 统一修复所有屏幕的安全区域问题
- 有 header 的屏幕使用 edges={['bottom']}(React Navigation 自动处理顶部)
- 没有 header 的屏幕使用 edges={['top', 'bottom']}(需要自己处理顶部)
- 修复了以下屏幕:
- HomeScreen: edges={['bottom']} → ['top', 'bottom']
- MessageListScreen: edges={['top']} → ['top', 'bottom']
- ScheduleScreen: edges={['top']} → ['top', 'bottom']
- ProfileScreen: edges={['top', 'bottom']} ✓ 已正确
- PostDetailScreen: 空状态添加 edges={['bottom']}
- UserScreen: 空状态添加 edges={['bottom']}
- NotificationsScreen: edges={[]} → ['bottom']
- SearchScreen: edges={['left', 'right']} → ['bottom']
- BlockedUsersScreen: 加载状态添加 edges={['bottom']}
- GroupInfoScreen: edges={['bottom']} ✓ 已正确
- PrivateChatInfoScreen: 加载状态添加 edges={['bottom']}
This commit is contained in:
@@ -100,7 +100,7 @@ export const BlockedUsersScreen: React.FC = () => {
|
||||
|
||||
if (loading) {
|
||||
return (
|
||||
<SafeAreaView style={styles.container}>
|
||||
<SafeAreaView style={styles.container} edges={['bottom']}>
|
||||
<View style={styles.loadingWrap}>
|
||||
<ActivityIndicator size="large" color={colors.primary.main} />
|
||||
</View>
|
||||
|
||||
@@ -363,7 +363,7 @@ export const ProfileScreen: React.FC = () => {
|
||||
|
||||
if (!currentUser) {
|
||||
return (
|
||||
<SafeAreaView style={styles.container}>
|
||||
<SafeAreaView style={styles.container} edges={['top', 'bottom']}>
|
||||
<EmptyState
|
||||
title="未登录"
|
||||
description="请先登录"
|
||||
|
||||
@@ -416,7 +416,7 @@ export const UserScreen: React.FC = () => {
|
||||
|
||||
if (!user) {
|
||||
return (
|
||||
<SafeAreaView style={styles.container}>
|
||||
<SafeAreaView style={styles.container} edges={['bottom']}>
|
||||
<EmptyState
|
||||
title="用户不存在"
|
||||
description="该用户可能已被删除"
|
||||
|
||||
Reference in New Issue
Block a user