diff options
author | 2022-05-20 00:51:30 +0100 | |
---|---|---|
committer | 2022-05-21 17:06:33 +0100 | |
commit | 79722f7356fa8e633cfda683857100f10409bcbd (patch) | |
tree | a070e6831dd50155e71f66c3d918b57ee81d3007 /components/Menu.jsx | |
parent | 9996d8f36cf91a7e9932961cbf0c178a62aa14d3 (diff) | |
download | notes_mobile-79722f7356fa8e633cfda683857100f10409bcbd.tar.gz notes_mobile-79722f7356fa8e633cfda683857100f10409bcbd.tar.bz2 notes_mobile-79722f7356fa8e633cfda683857100f10409bcbd.zip |
configure eas, improve top bar
Diffstat (limited to 'components/Menu.jsx')
-rw-r--r-- | components/Menu.jsx | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/components/Menu.jsx b/components/Menu.jsx index f6de610..fb82f34 100644 --- a/components/Menu.jsx +++ b/components/Menu.jsx @@ -1,5 +1,6 @@ -import { StyleSheet, Text, View } from 'react-native'; +import { StyleSheet, Text, View, Alert } from 'react-native'; import AsyncStorage from '@react-native-async-storage/async-storage'; +import { confirmLogout } from '../helpers' const Menu = ({ session, setSession, setEdit, showError, saveNote }) => { const logout = async () => { @@ -38,12 +39,16 @@ const Menu = ({ session, setSession, setEdit, showError, saveNote }) => { > New Note </Text> - <Text style={styles.menuText}>{session.email}</Text> <Text style={styles.menuText} - onPress={logout} > - Logout + Sort + </Text> + <Text + style={styles.menuText} + onPress={() => confirmLogout({ logout, email: session.email })} + > + {session.email} </Text> </> ) @@ -54,7 +59,7 @@ const Menu = ({ session, setSession, setEdit, showError, saveNote }) => { const styles = StyleSheet.create({ menu: { - backgroundColor: 'lightgrey', + backgroundColor: '#333', height: 60, width: '100%', flexDirection: 'row', @@ -65,6 +70,7 @@ const styles = StyleSheet.create({ menuText: { fontWeight: 'bold', paddingHorizontal: 15, + color: 'white', }, }); |