2024-12-01 17:58:53 +00:00
|
|
|
import { Tabs } from 'expo-router'
|
|
|
|
import React from 'react'
|
|
|
|
import { FontAwesome6, MaterialIcons } from '@expo/vector-icons'
|
2024-12-09 20:00:15 +00:00
|
|
|
import TabBar from '@/components/ui/TabBar'
|
2024-12-09 23:04:35 +00:00
|
|
|
import TabsHeader from '@/components/ui/TabsHeader'
|
2024-12-01 17:58:53 +00:00
|
|
|
|
|
|
|
export default function TabLayout() {
|
|
|
|
return (
|
2024-12-09 23:04:35 +00:00
|
|
|
<>
|
|
|
|
<Tabs
|
|
|
|
tabBar={(props) => <TabBar {...props} />}
|
|
|
|
screenOptions={{
|
|
|
|
tabBarHideOnKeyboard: true,
|
|
|
|
header: (props) => <TabsHeader navProps={props} children={undefined} />,
|
|
|
|
}}
|
|
|
|
>
|
2024-12-01 17:58:53 +00:00
|
|
|
<Tabs.Screen
|
|
|
|
name="index"
|
|
|
|
options={{
|
|
|
|
title: 'Carte',
|
|
|
|
headerShown: false,
|
|
|
|
tabBarIcon: ({ color }) => <FontAwesome6 name="map-location-dot" size={24} color={color} />,
|
|
|
|
}}
|
|
|
|
/>
|
|
|
|
<Tabs.Screen
|
|
|
|
name="challenges"
|
|
|
|
options={{
|
2024-12-14 10:55:11 +00:00
|
|
|
title: 'Défi en cours',
|
2024-12-12 17:01:08 +00:00
|
|
|
headerShown: false,
|
2024-12-01 17:58:53 +00:00
|
|
|
tabBarIcon: ({ color }) => <FontAwesome6 name="coins" size={24} color={color} />,
|
|
|
|
}}
|
|
|
|
/>
|
|
|
|
<Tabs.Screen
|
|
|
|
name="train"
|
|
|
|
options={{
|
2024-12-11 22:42:22 +00:00
|
|
|
title: 'Trains',
|
2024-12-01 17:58:53 +00:00
|
|
|
headerTitleStyle: {fontSize: 32},
|
|
|
|
tabBarIcon: ({ color }) => <FontAwesome6 name="train" size={24} color={color} />,
|
|
|
|
}}
|
|
|
|
/>
|
|
|
|
<Tabs.Screen
|
|
|
|
name="history"
|
|
|
|
options={{
|
|
|
|
title: 'Historique',
|
|
|
|
headerTitleStyle: {fontSize: 32},
|
|
|
|
tabBarIcon: ({ color }) => <MaterialIcons name="history" size={24} color={color} />,
|
|
|
|
}}
|
|
|
|
/>
|
2024-12-09 17:29:48 +00:00
|
|
|
<Tabs.Screen
|
|
|
|
name="settings"
|
|
|
|
options={{
|
|
|
|
title: 'Paramètres',
|
|
|
|
headerTitleStyle: {fontSize: 32},
|
|
|
|
tabBarIcon: ({ color }) => <MaterialIcons name="settings" size={24} color={color} />,
|
|
|
|
}}
|
|
|
|
/>
|
2024-12-01 17:58:53 +00:00
|
|
|
</Tabs>
|
2024-12-09 23:04:35 +00:00
|
|
|
</>
|
2024-12-06 18:00:51 +00:00
|
|
|
)
|
2024-12-01 17:58:53 +00:00
|
|
|
}
|