This commit is contained in:
Developer
2026-03-10 19:04:18 +08:00
parent 18eebfb0d2
commit cf20b016ff
18 changed files with 1106 additions and 123 deletions

View File

@@ -1,9 +1,10 @@
import { Tabs } from 'expo-router';
import { Ionicons } from '@expo/vector-icons';
import { Stack } from 'expo-router';
import { StatusBar } from 'expo-status-bar';
import { SafeAreaProvider } from 'react-native-safe-area-context';
import { View } from 'react-native';
import { useEffect } from 'react';
import { useAuthStore } from '../store/authStore';
import { MiniPlayer } from '../components/MiniPlayer';
export default function RootLayout() {
const restore = useAuthStore(s => s.restore);
@@ -15,28 +16,10 @@ export default function RootLayout() {
return (
<SafeAreaProvider>
<StatusBar style="dark" />
<Tabs
screenOptions={{
tabBarActiveTintColor: '#00AEEC',
tabBarInactiveTintColor: '#999',
tabBarStyle: { borderTopColor: '#eee' },
headerShown: false,
}}
>
<Tabs.Screen
name="index"
options={{
title: '首页',
tabBarIcon: ({ color, size }: { color: string; size: number }) => (
<Ionicons name="home" size={size} color={color} />
),
}}
/>
<Tabs.Screen
name="video"
options={{ href: null }}
/>
</Tabs>
<View style={{ flex: 1 }}>
<Stack screenOptions={{ headerShown: false }} />
<MiniPlayer />
</View>
</SafeAreaProvider>
);
}