@@ -5,24 +5,21 @@ import { createBottomTabNavigator } from '@react-navigation/bottom-tabs'
5
5
import { createStackNavigator } from '@react-navigation/stack'
6
6
import { MaterialCommunityIcons } from '@expo/vector-icons'
7
7
import { STACK_SCREENS } from './index'
8
- import Home from '../HomeContainers /Home'
8
+ import Home from '../HomeContainer /Home'
9
9
import CoursePlaylistsContainer from '../CoursePlaylistsContainer/CoursePlaylistsContainer'
10
10
import VideoContainer from '../VideoContainer/VideoContainer'
11
- import UniversityListContainer from '../UniversityListContainer/UniversityListContainer'
12
11
import PlaylistContainer from '../PlaylistContainer/PlaylistContainer'
13
- import DepartmentListContainer from '../DepartmentListContainer/DepartmentListContainer'
14
- import CourseListContainer from '../CourseListContainer/CourseListContainer'
15
12
16
13
const Tab = createBottomTabNavigator ( )
17
14
const Stack = createStackNavigator ( )
18
15
19
16
/**
20
17
* The navigator of the home tab. Contains a stack navigator.
21
18
*/
22
- const HomeNaivgator = ( ) => {
19
+ const HomeNavigator = ( ) => {
23
20
return (
24
21
< Stack . Navigator initialRouteName = { STACK_SCREENS . HOME } >
25
- < Stack . Screen name = { STACK_SCREENS . HOME } component = { Home } />
22
+ < Stack . Screen name = { STACK_SCREENS . HOME } component = { HomeView } />
26
23
< Stack . Screen name = { STACK_SCREENS . COURSE_PLAYLISTS } component = { CoursePlaylistsView } />
27
24
< Stack . Screen name = { STACK_SCREENS . PLAYLIST } component = { PlaylistView } />
28
25
< Stack . Screen name = { STACK_SCREENS . VIDEO } component = { VideoView } />
@@ -31,35 +28,11 @@ const HomeNaivgator = () => {
31
28
}
32
29
33
30
/**
34
- * Wraps the UniversityListContainer so that it can
31
+ * Wraps the Home container so that it can
35
32
* receive the proper props
36
33
*/
37
- const UniversityListView = ( { navigation } ) => {
38
- return < UniversityListContainer navigation = { navigation } />
39
- }
40
-
41
- /**
42
- * Wraps the DepartmentListContainer so that it can
43
- * receive the proper props
44
- */
45
- const DepartmentListView = ( { navigation, route } ) => {
46
- return (
47
- < DepartmentListContainer universityId = { route . params . universityId } navigation = { navigation } />
48
- )
49
- }
50
-
51
- /**
52
- * Wraps the CourseListContainer so that it can
53
- * receive the proper props
54
- */
55
- const CourseListView = ( { navigation, route } ) => {
56
- return (
57
- < CourseListContainer
58
- departmentId = { route . params . departmentId }
59
- acronym = { route . params . acronym }
60
- navigation = { navigation }
61
- />
62
- )
34
+ const HomeView = ( { navigation } ) => {
35
+ return < Home navigation = { navigation } />
63
36
}
64
37
65
38
/**
@@ -91,11 +64,8 @@ const VideoView = ({ route }) => {
91
64
*/
92
65
const CourseNavigator = ( ) => {
93
66
return (
94
- < Stack . Navigator initialRouteName = { STACK_SCREENS . UNIVERSITY_LIST } >
95
- < Stack . Screen name = { STACK_SCREENS . UNIVERSITY_LIST } component = { UniversityListView } />
96
- < Stack . Screen name = { STACK_SCREENS . DEPT_LIST } component = { DepartmentListView } />
97
- < Stack . Screen name = { STACK_SCREENS . COURSE_LIST } component = { CourseListView } />
98
- < Stack . Screen name = { STACK_SCREENS . HOME } component = { Home } />
67
+ < Stack . Navigator initialRouteName = { STACK_SCREENS . HOME } >
68
+ < Stack . Screen name = { STACK_SCREENS . HOME } component = { HomeView } />
99
69
< Stack . Screen name = { STACK_SCREENS . COURSE_PLAYLISTS } component = { CoursePlaylistsView } />
100
70
< Stack . Screen name = { STACK_SCREENS . PLAYLIST } component = { PlaylistView } />
101
71
< Stack . Screen name = { STACK_SCREENS . VIDEO } component = { VideoView } />
@@ -124,7 +94,7 @@ const CTNavigationContainer = () => {
124
94
/>
125
95
< Tab . Screen
126
96
name = "Home"
127
- component = { HomeNaivgator }
97
+ component = { HomeNavigator }
128
98
options = { {
129
99
tabBarLabel : 'Home' ,
130
100
tabBarIcon : ( { color, size } ) => (
0 commit comments