-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathApp.js
More file actions
106 lines (100 loc) · 3.36 KB
/
Copy pathApp.js
File metadata and controls
106 lines (100 loc) · 3.36 KB
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
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
import React, {Component} from 'react';
import {YellowBox} from 'react-native';
/*Ekranda çıkan uyarıları gizler.Kod uyarıları!!! */
/*--------------------------------- */
YellowBox.ignoreWarnings(['Warning: ...']);
console.disableYellowBox = true;
/*--------------------------------- */
//Copmponents
import Home from './src/screens/home/Home';
import Login from './src/screens/login/Login';
import _Login from './src/screens/login/_Login';
import Appointment from './src/screens/appointment/Appointment';
import _Appointment from './src/screens/appointment/_Appointment';
import ContactRequest from './src/screens/contactRequest/ContactRequest';
import _ContactRequest from './src/screens/contactRequest/_ContactRequest';
import Works from './src/screens/works/Work';
import Profile from './src/screens/Account/Profile';
import ForgottenPassword from './src/screens/login/ForgottenPassword';
import AppointmentList from './src/components/AppointmentList';
//Packages
import {Router, Stack, Tabs, Scene, Actions} from 'react-native-router-flux';
import Icon from 'react-native-vector-icons/FontAwesome';
import getToken from './src/screens/api/getToken';
Icon.loadFont();
class App extends Component {
componentDidMount() {
console.log('App Started...');
getToken();
}
render() {
const scenes = Actions.create(
<Stack key="root" hideNavBar>
<Tabs showLabel={true} swipeEnabled={true}>
<Scene
initial
tabBarLabel="Anasayfa"
hideNavBar
icon={({tintColor}) => (
<Icon name="home" color={tintColor} size={24} />
)}>
<Scene key="home" component={Home} />
<Scene hideNavBar key="works" component={Works} />
</Scene>
<Scene
tabs={true}
hideNavBar
key="contact"
component={_ContactRequest}
tabBarLabel="İletişim"
icon={({tintColor}) => (
<Icon name="calendar" color={tintColor} size={24} />
)}
/>
<Scene
tabs={true}
hideNavBar
key="appointment"
component={_Appointment}
tabBarLabel="Randevu"
icon={({tintColor}) => (
<Icon name="phone-square" color={tintColor} size={24} />
)}
/>
<Scene
tabBarLabel="Hesabım"
icon={({tintColor}) => (
<Icon name="user" color={tintColor} size={24} />
)}>
<Scene tabs={true} hideNavBar key="login" component={_Login} />
<Scene
tabs={true}
hideNavBar
key="appointmentList"
component={AppointmentList}
/>
<Scene tabs={true} key="profile" component={Profile} hideNavBar />
<Scene
tabs={true}
hideNavBar
key="forgottenPassword"
component={ForgottenPassword}
/>
</Scene>
<Scene
tabs={true}
key="works"
component={Works}
hideNavBar
tabBarLabel="Örnekler"
icon={({tintColor}) => (
<Icon name="camera-retro" color={tintColor} size={24} />
)}
/>
</Tabs>
</Stack>,
);
return <Router scenes={scenes} />;
}
}
export default App;