-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDashboard.js
57 lines (53 loc) · 1.35 KB
/
Dashboard.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
import React from 'react';
import { View, Text, StyleSheet } from 'react-native';
import { createStackNavigator } from '@react-navigation/stack';
import MenuButton from '../components/MenuButton';
import Filter from '../components/Filter';
import HeaderLogo from '../components/HeaderLogo';
const Stack = createStackNavigator();
function Dashboard() {
return (
<View style={styles.container}>
<Text style={styles.title}>Dashboard</Text>
</View>
);
}
export default function DashboardStack() {
return (
<Stack.Navigator
screenOptions={{
headerTitle: () => <HeaderLogo />,
headerStyle: {
elevation: 0,
shadowOpacity: 0,
},
}}
>
<Stack.Screen
name='Dashboard Screen'
component={Dashboard}
options={({ navigation }) => ({
// headerStyle: {
// // paddingHorizontal: 10,
// },
headerLeft: () => <MenuButton navigation={navigation} />,
headerTitle: () => <HeaderLogo />,
headerRight: () => <Filter />,
headerTitleAlign: 'center',
})}
/>
</Stack.Navigator>
);
}
const styles = StyleSheet.create({
container: {
flex: 1,
justifyContent: 'center',
alignItems: 'center',
backgroundColor: '#fff',
},
title: {
fontSize: 20,
color: '#999',
},
});