import { useState } from "react"; import { Link } from "react-router-dom"; import { useAuthStore } from "../stores/auth.ts"; export function ForgotPasswordPage() { const [email, setEmail] = useState(""); const [sent, setSent] = useState(false); const { requestPasswordReset, isLoading, error, clearError } = useAuthStore(); const handleSubmit = async (e: React.FormEvent) => { e.preventDefault(); clearError(); try { await requestPasswordReset(email); setSent(true); } catch { // error displayed from store } }; return (
{"┌─ DUMPSTER ─┐"}
If an account exists for{" "} {email}, we've sent a password reset link. Check your inbox.
The link expires in 1 hour.