Merge branch 'fix-splash-screen-and-initial-routes' into 'main'

Fix splash screen and initial routes

See merge request torpenn/boxons!10
merge-requests/10/merge
Torpenn 2025-03-03 22:13:03 +00:00
commit 936319352f
9 changed files with 27 additions and 10 deletions

View File

@ -12,7 +12,7 @@ export default {
"splash": { "splash": {
"image": "./assets/images/splash.png", "image": "./assets/images/splash.png",
"resizeMode": "contain", "resizeMode": "contain",
"backgroundColor": "#ffffff" "backgroundColor": "#000000"
}, },
"ios": { "ios": {
"supportsTablet": true, "supportsTablet": true,

16
app/(tabs)/_layout.tsx Normal file
View File

@ -0,0 +1,16 @@
import { Tabs } from 'expo-router';
import { i18n } from '../i18n/i18n';
export default function TabLayout() {
return (
<Tabs>
<Tabs.Screen
name="index"
options={{
title: i18n.t('appTitle'),
headerShown: false,
}}
/>
</Tabs>
);
}

View File

@ -16,7 +16,7 @@ export {
export const unstable_settings = { export const unstable_settings = {
// Ensure that reloading on `/modal` keeps a back button present. // Ensure that reloading on `/modal` keeps a back button present.
initialRouteName: 'Dashboard', initialRouteName: '(tabs)',
}; };
// Prevent the splash screen from auto-hiding before asset loading is complete. // Prevent the splash screen from auto-hiding before asset loading is complete.
@ -50,8 +50,8 @@ function RootLayoutNav() {
return ( return (
<LanguageProvider> <LanguageProvider>
<ThemeProvider theme={theme}> <ThemeProvider theme={theme}>
<Stack initialRouteName="Dashboard"> <Stack>
<Stack.Screen name="Dashboard" options={{ headerShown: false }} /> <Stack.Screen name="(tabs)" options={{ headerShown: false }} />
<Stack.Screen name="Timer" options={{ headerShown: false }} /> <Stack.Screen name="Timer" options={{ headerShown: false }} />
<Stack.Screen name="Settings" options={{ headerShown: true, title: i18n.t('settings.title') }} /> <Stack.Screen name="Settings" options={{ headerShown: true, title: i18n.t('settings.title') }} />
</Stack> </Stack>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 46 KiB

After

Width:  |  Height:  |  Size: 2.3 MiB

View File

@ -56,6 +56,7 @@
<string>$(PRODUCT_BUNDLE_IDENTIFIER).expo.index_route</string> <string>$(PRODUCT_BUNDLE_IDENTIFIER).expo.index_route</string>
<string>$(PRODUCT_BUNDLE_IDENTIFIER).expo.index_route</string> <string>$(PRODUCT_BUNDLE_IDENTIFIER).expo.index_route</string>
<string>$(PRODUCT_BUNDLE_IDENTIFIER).expo.index_route</string> <string>$(PRODUCT_BUNDLE_IDENTIFIER).expo.index_route</string>
<string>$(PRODUCT_BUNDLE_IDENTIFIER).expo.index_route</string>
</array> </array>
<key>NSUserNotificationUsageDescription</key> <key>NSUserNotificationUsageDescription</key>
<string>Nous utilisons des notifications pour vous avertir pendant l'utilisation de l'application.</string> <string>Nous utilisons des notifications pour vous avertir pendant l'utilisation de l'application.</string>

View File

@ -13,4 +13,4 @@
<key>EXUpdatesURL</key> <key>EXUpdatesURL</key>
<string>https://u.expo.dev/d301ba68-1a3d-44b4-937e-ada774c6f67c</string> <string>https://u.expo.dev/d301ba68-1a3d-44b4-937e-ada774c6f67c</string>
</dict> </dict>
</plist> </plist>

8
package-lock.json generated
View File

@ -25,7 +25,7 @@
"expo-splash-screen": "~0.27.7", "expo-splash-screen": "~0.27.7",
"expo-status-bar": "~1.12.1", "expo-status-bar": "~1.12.1",
"expo-system-ui": "~3.0.7", "expo-system-ui": "~3.0.7",
"expo-updates": "~0.25.27", "expo-updates": "~0.25.28",
"expo-web-browser": "~13.0.3", "expo-web-browser": "~13.0.3",
"i18n-js": "^4.4.3", "i18n-js": "^4.4.3",
"react": "18.2.0", "react": "18.2.0",
@ -12494,9 +12494,9 @@
} }
}, },
"node_modules/expo-updates": { "node_modules/expo-updates": {
"version": "0.25.27", "version": "0.25.28",
"resolved": "https://registry.npmjs.org/expo-updates/-/expo-updates-0.25.27.tgz", "resolved": "https://registry.npmjs.org/expo-updates/-/expo-updates-0.25.28.tgz",
"integrity": "sha512-1hyYZqBEXcAiEuSRPJ6dINTndGlWi6/bwlyYGjSnyoYfu/vzZQrJ+XA8JUP4EvJ3b0g8a0UOIjlDJ9ke9kMcfg==", "integrity": "sha512-NTI1r7wvXel36qCzKwCjCJ9HExBo6GX9wkA9WzaNsysmg+eEd5BCmcaxvQGZUQkfDocEfI78N5vRBSuMi0iS1w==",
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"@expo/code-signing-certificates": "0.0.5", "@expo/code-signing-certificates": "0.0.5",

View File

@ -41,7 +41,7 @@
"expo-splash-screen": "~0.27.7", "expo-splash-screen": "~0.27.7",
"expo-status-bar": "~1.12.1", "expo-status-bar": "~1.12.1",
"expo-system-ui": "~3.0.7", "expo-system-ui": "~3.0.7",
"expo-updates": "~0.25.27", "expo-updates": "~0.25.28",
"expo-web-browser": "~13.0.3", "expo-web-browser": "~13.0.3",
"i18n-js": "^4.4.3", "i18n-js": "^4.4.3",
"react": "18.2.0", "react": "18.2.0",