-
Notifications
You must be signed in to change notification settings - Fork 10
/
App.js
71 lines (70 loc) · 2.42 KB
/
App.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
import { Navigation } from 'react-native-navigation';
import { Provider } from 'react-redux';
import configureStore from './store';
import { registerScreens } from './screens';
import tabsStyle from './constants/TabsStyle';
import appStyle from './constants/AppStyle';
import Screens from './constants/Screens';
import { iconsMap, iconsLoaded } from './utils/AppIcons';
export default registerScreens(configureStore(() => iconsLoaded.then(() =>
Navigation.startTabBasedApp({
tabs: [
{
label: Screens.TAB_HOME.label,
screen: Screens.TAB_HOME.screen,
title: Screens.TAB_HOME.title,
icon: iconsMap['ios-home'],
selectedIcon: iconsMap['ios-home'], // iOS only
navigatorButtons: {
leftButtons: [
{
icon: iconsMap['ios-menu'],
id: 'sideMenu'
}
]
}
},
{
label: Screens.TAB_PAPER.label,
screen: Screens.TAB_PAPER.screen,
title: Screens.TAB_PAPER.title,
icon: iconsMap['ios-paper'],
selectedIcon: iconsMap['ios-paper'], // iOS only
navigatorButtons: {
leftButtons: [
{
icon: iconsMap['ios-menu'],
id: 'sideMenu'
}
]
}
},
{
label: Screens.TAB_GALLERY.label,
screen: Screens.TAB_GALLERY.screen,
title: Screens.TAB_GALLERY.title,
icon: iconsMap['ios-images'],
selectedIcon: iconsMap['ios-images'], // iOS only
navigatorButtons: {
leftButtons: [
{
icon: iconsMap['ios-menu'],
id: 'sideMenu'
}
]
}
},
],
drawer: {
left: {
screen: Screens.DRAWER_PROFILE.screen,
},
style: {
leftDrawerWidth: '85%',
}
},
tabsStyle,
appStyle,
animationType: 'faded',
})
).catch(error => console.error(error))), Provider);