From 607640f4901c5edf11242495cf563b3111491715 Mon Sep 17 00:00:00 2001 From: Ronnie Beggs Date: Sat, 7 Oct 2023 14:47:32 -0700 Subject: [PATCH] [feat] implement working bottom tab navigation between Cases and Profile pages. --- src/app/(BottomTabNavigation)/Cases/index.tsx | 2 +- .../(BottomTabNavigation)/Profile/index.tsx | 2 +- src/app/(BottomTabNavigation)/_layout.tsx | 16 +++++++---- src/app/(BottomTabNavigation)/home.tsx | 11 -------- src/app/(BottomTabNavigation)/index.tsx | 0 src/app/_layout.tsx | 4 +-- src/app/index.tsx | 27 +++---------------- 7 files changed, 18 insertions(+), 44 deletions(-) delete mode 100644 src/app/(BottomTabNavigation)/home.tsx delete mode 100644 src/app/(BottomTabNavigation)/index.tsx diff --git a/src/app/(BottomTabNavigation)/Cases/index.tsx b/src/app/(BottomTabNavigation)/Cases/index.tsx index e5696100..34453682 100644 --- a/src/app/(BottomTabNavigation)/Cases/index.tsx +++ b/src/app/(BottomTabNavigation)/Cases/index.tsx @@ -5,7 +5,7 @@ import styles from './styles'; function CasesScreen() { return ( - This is the cases screen! + This is the /Cases/index cases screen! ); } diff --git a/src/app/(BottomTabNavigation)/Profile/index.tsx b/src/app/(BottomTabNavigation)/Profile/index.tsx index a5c1791c..44c0084e 100644 --- a/src/app/(BottomTabNavigation)/Profile/index.tsx +++ b/src/app/(BottomTabNavigation)/Profile/index.tsx @@ -5,7 +5,7 @@ import styles from './styles'; function ProfileScreen() { return ( - This is the profile screen! + This is the /Profile/index profile screen! ); } diff --git a/src/app/(BottomTabNavigation)/_layout.tsx b/src/app/(BottomTabNavigation)/_layout.tsx index 3f0d7873..1fbb9c5f 100644 --- a/src/app/(BottomTabNavigation)/_layout.tsx +++ b/src/app/(BottomTabNavigation)/_layout.tsx @@ -2,13 +2,19 @@ import { Tabs } from 'expo-router/tabs'; export default function AppLayout() { return ( - + + diff --git a/src/app/(BottomTabNavigation)/home.tsx b/src/app/(BottomTabNavigation)/home.tsx deleted file mode 100644 index de19980b..00000000 --- a/src/app/(BottomTabNavigation)/home.tsx +++ /dev/null @@ -1,11 +0,0 @@ -import React from 'react'; -import { Text, View } from 'react-native'; -import styles from './Profile/styles'; - -export default function HomeScreen() { - return ( - - This is a test home screen! - - ); -} diff --git a/src/app/(BottomTabNavigation)/index.tsx b/src/app/(BottomTabNavigation)/index.tsx deleted file mode 100644 index e69de29b..00000000 diff --git a/src/app/_layout.tsx b/src/app/_layout.tsx index 74222021..fb31db0e 100644 --- a/src/app/_layout.tsx +++ b/src/app/_layout.tsx @@ -1,10 +1,8 @@ import { Stack } from 'expo-router'; -// import AppLayout from './(BottomTabNavigation)/_layout'; export default function StackLayout() { - // return ; return ( - + ); diff --git a/src/app/index.tsx b/src/app/index.tsx index aadb3970..0f04ee52 100644 --- a/src/app/index.tsx +++ b/src/app/index.tsx @@ -1,28 +1,9 @@ -import { Link } from 'expo-router'; -import { Text, View } from 'react-native'; -import { TouchableOpacity } from 'react-native-gesture-handler'; -import styles from './styles'; +// import { Text, View } from 'react-native'; +// import styles from './styles'; +import { Redirect } from 'expo-router'; function StartScreen() { - return ( - - - - Welcome Screen - - - - - Cases Screen - - - - - Profile Screen - - - - ); + return ; } export default StartScreen;