faa1e82301
Package mobile/ (Expo SDK 56, expo-router) réutilisant l'API backend : Login (mdp+TOTP), Chat (+ TTS expo-speech), Review (approuver/refuser). JWT en expo-secure-store, thème dark HUD, EXPO_PUBLIC_API_BASE. typecheck vert. STT mobile reporté (lib native), TTS OK. Versions gérées par Expo. Palier de risque : reversible (client mobile, API commune). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
17 lines
481 B
TypeScript
17 lines
481 B
TypeScript
import { Redirect } from "expo-router";
|
|
import { ActivityIndicator, View } from "react-native";
|
|
import { useAuth } from "@/auth";
|
|
import { C } from "@/theme";
|
|
|
|
export default function Index() {
|
|
const { token, ready } = useAuth();
|
|
if (!ready) {
|
|
return (
|
|
<View style={{ flex: 1, justifyContent: "center", backgroundColor: C.bg }}>
|
|
<ActivityIndicator color={C.accent} />
|
|
</View>
|
|
);
|
|
}
|
|
return <Redirect href={token ? "/(tabs)/chat" : "/login"} />;
|
|
}
|