traintrape-moi/client/app/(tabs)/settings.tsx

19 lines
627 B
TypeScript
Raw Normal View History

import { useAuth } from '@/hooks/useAuth'
2024-12-09 21:29:48 +00:00
import { useRouter } from 'expo-router'
import { FAB, List, Surface } from 'react-native-paper'
export default function HistoryScreen() {
2024-12-09 21:29:48 +00:00
const router = useRouter()
const auth = useAuth()
return (
2024-12-09 21:29:48 +00:00
<Surface
style={{ flex: 1 }}>
<List.Item
title="Connexion au serveur"
description={auth.loggedIn ? "Vous êtes déjà connecté⋅e" : "Vous n'êtes pas connecté⋅e"}
2024-12-09 21:29:48 +00:00
right={() => <FAB icon="login" size="small" onPress={() => router.navigate('/login')} />}
onPress={() => router.navigate('/login')} />
2024-12-09 20:00:15 +00:00
</Surface>
)
}