diff --git a/app.json b/app.json index 5a77a38..e61c197 100644 --- a/app.json +++ b/app.json @@ -5,44 +5,36 @@ "version": "1.0.0", "orientation": "portrait", "icon": "./assets/images/icon.png", - "scheme": "projectit207", + "scheme": "myapp", "userInterfaceStyle": "automatic", - "newArchEnabled": true, + "splash": { + "image": "./assets/images/splash.png", + "resizeMode": "contain", + "backgroundColor": "#ffffff" + }, "ios": { - "supportsTablet": true + "supportsTablet": true, + "bundleIdentifier": "com.yourcompany.projectit207" }, "android": { "adaptiveIcon": { - "backgroundColor": "#E6F4FE", - "foregroundImage": "./assets/images/android-icon-foreground.png", - "backgroundImage": "./assets/images/android-icon-background.png", - "monochromeImage": "./assets/images/android-icon-monochrome.png" + "foregroundImage": "./assets/images/adaptive-icon.png", + "backgroundColor": "#ffffff" }, - "edgeToEdgeEnabled": true, - "predictiveBackGestureEnabled": false + "package": "com.yourcompany.projectit207", + "permissions": ["INTERNET"] }, "web": { + "bundler": "metro", "output": "static", "favicon": "./assets/images/favicon.png" }, "plugins": [ "expo-router", - [ - "expo-splash-screen", - { - "image": "./assets/images/splash-icon.png", - "imageWidth": 200, - "resizeMode": "contain", - "backgroundColor": "#ffffff", - "dark": { - "backgroundColor": "#000000" - } - } - ] + "expo-font" ], "experiments": { - "typedRoutes": true, - "reactCompiler": true + "typedRoutes": true } } -} +} \ No newline at end of file diff --git a/app/(tabs)/_layout.tsx b/app/(tabs)/_layout.tsx index 93f0b5b..e5d0b58 100644 --- a/app/(tabs)/_layout.tsx +++ b/app/(tabs)/_layout.tsx @@ -1,31 +1,10 @@ import { Tabs } from "expo-router"; import { Ionicons } from "@expo/vector-icons"; -import { Button, Alert } from "react-native"; -import AsyncStorage from "@react-native-async-storage/async-storage"; -import { useRouter } from "expo-router"; export default function TabsLayout() { - const router = useRouter(); - - const handleLogout = async () => { - Alert.alert("Đăng xuất", "Bạn có chắc muốn đăng xuất?", [ - { - text: "Hủy", - style: "cancel", - }, - { - text: "Đăng xuất", - style: "destructive", - onPress: async () => { - await AsyncStorage.removeItem("authToken"); - router.replace("/"); // quay về màn hình đăng nhập - }, - }, - ]); - }; return ( - + , - headerRight: () =>