diff --git a/Ejectable/components/ScreenInfo.tsx b/Ejectable/components/ScreenInfo.tsx index 4f7b22c4..4154b13f 100644 --- a/Ejectable/components/ScreenInfo.tsx +++ b/Ejectable/components/ScreenInfo.tsx @@ -31,6 +31,19 @@ export function ScreenInfo2() { ); } +export function ScreenInfo3() { + return ( + + + Green Travel Carbon Calculator v. 2 + + + ); +} + const styles = StyleSheet.create({ settingsContainer: { marginHorizontal: 50, diff --git a/Ejectable/navigation/BottomTabNavigator.tsx b/Ejectable/navigation/BottomTabNavigator.tsx index 8340f013..83b9e690 100644 --- a/Ejectable/navigation/BottomTabNavigator.tsx +++ b/Ejectable/navigation/BottomTabNavigator.tsx @@ -10,9 +10,10 @@ import * as React from 'react'; import Colors from '../constants/Colors'; import useColorScheme from '../hooks/useColorScheme'; +import SplashScreen from '../screens/SplashScreen'; import TripScreen from '../screens/TripScreen'; import SettingsScreen from '../screens/SettingsScreen'; -import { BottomTabParamList, TripParamList, SettingsParamList } from '../types'; +import { SplashParamList, BottomTabParamList, TripParamList, SettingsParamList } from '../types'; const BottomTab = createBottomTabNavigator(); @@ -21,11 +22,11 @@ export default function BottomTabNavigator() { return ( , }} @@ -37,6 +38,13 @@ export default function BottomTabNavigator() { tabBarIcon: ({ color }) => , }} /> + , + }} + /> ); } @@ -49,8 +57,21 @@ function TabBarIcon(props: { name: React.ComponentProps['name'] // Each tab has its own navigation stack, you can read more about this pattern here: // https://reactnavigation.org/docs/tab-based-navigation#a-stack-navigator-for-each-tab +const SplashStack = createStackNavigator(); const TripStack = createStackNavigator(); +function SplashNavigator() { + return ( + + + + ); +} + function TripNavigator() { return ( diff --git a/Ejectable/navigation/LinkingConfiguration.ts b/Ejectable/navigation/LinkingConfiguration.ts index b5b157d3..2b3d9ea5 100644 --- a/Ejectable/navigation/LinkingConfiguration.ts +++ b/Ejectable/navigation/LinkingConfiguration.ts @@ -12,14 +12,19 @@ export default { screens: { Root: { screens: { + Splash: { + screens: { + SplashScreen: 'one', + }, + }, Trip: { screens: { - TripScreen: 'one', + TripScreen: 'two', }, }, Settings: { screens: { - SettingsScreen: 'two', + SettingsScreen: 'three', }, }, }, diff --git a/Ejectable/screens/SettingsScreen.tsx b/Ejectable/screens/SettingsScreen.tsx index c6059ed5..6c4b6329 100644 --- a/Ejectable/screens/SettingsScreen.tsx +++ b/Ejectable/screens/SettingsScreen.tsx @@ -26,11 +26,11 @@ export default function SettingsScreen() {