import { useState } from 'react'; import { Button } from '../ui/button'; import { Card, CardContent } from '../ui/card'; import { sendVerificationEmail, signOut } from '../../lib/auth-client'; import { Mail } from 'lucide-react'; const logo = '/logo.png'; interface Props { email: string; } export function EmailVerification({ email }: Props) { const [resent, setResent] = useState(false); const [loading, setLoading] = useState(false); async function handleResend() { setLoading(true); await sendVerificationEmail({ email, callbackURL: window.location.origin, }); setLoading(false); setResent(true); } function handleCheckStatus() { window.location.reload(); } return (
We sent a verification link to {email}. Click the link to activate your account.