diff --git a/app/(tabs)/_layout.tsx b/app/(tabs)/_layout.tsx index 68ee98c..cbf4a54 100644 --- a/app/(tabs)/_layout.tsx +++ b/app/(tabs)/_layout.tsx @@ -1,15 +1,19 @@ import { Tabs } from 'expo-router' import React from 'react' -import { StyleSheet, View, Text } from 'react-native' +import { StyleSheet, View, Text, Platform } from 'react-native' import { LinearGradient } from 'expo-linear-gradient' import { useTranslation } from 'react-i18next' import { useSafeAreaInsets } from 'react-native-safe-area-context' import { HomeIcon, MessageIcon, MyIcon, VideoIcon } from '@/components/icon' +const TAB_BAR_HEIGHT = 60 + export default function TabLayout() { const { t } = useTranslation() const insets = useSafeAreaInsets() + // Android 不需要额外的底部安全区域,iOS 和 Web 需要 + const bottomInset = Platform.OS === 'android' ? 0 : insets.bottom return ( ( + + ), }} >