import React from "react"; import { ScrollView } from "react-native"; import { SafeAreaView } from "react-native-safe-area-context"; import { StatusBar } from "expo-status-bar"; import { useColorScheme } from "nativewind"; import { Button } from "../../components/button"; import { Card, CardDescription, CardFooter, CardHeader, CardTitle } from "../../components/card"; export interface ExpiredLinkScreenProps { title?: string; message?: string; /** Request a fresh link (e.g. resend verification / reset). */ onRequestNew?: () => void; requestLabel?: string; /** Return to sign in. */ onHome?: () => void; homeLabel?: string; } /** * Shown when a one-time link (email verification, password reset, magic link) * has expired or was already used. Presentational; the host app wires the * "request a new link" + "back to sign in" actions. */ export function ExpiredLinkScreen({ title = "This link has expired", message = "For your security, this link is no longer valid. Request a new one to continue.", onRequestNew, requestLabel = "Send a new link", onHome, homeLabel = "Back to sign in", }: ExpiredLinkScreenProps) { const { colorScheme } = useColorScheme(); const isDark = colorScheme === "dark"; return ( {title} {message} {onRequestNew || onHome ? ( {onRequestNew ? ( ) : null} {onHome ? ( ) : null} ) : null} ); } export default ExpiredLinkScreen;