import { MailOpenIcon } from "lucide-react"; import { useSession } from "next-auth/react"; import { useRouter } from "next/router"; import { useEffect } from "react"; import { APP_NAME } from "@calcom/lib/constants"; import { useLocale } from "@calcom/lib/hooks/useLocale"; import { trpc } from "@calcom/trpc"; import useEmailVerifyCheck from "@calcom/trpc/react/hooks/useEmailVerifyCheck"; import { Button, EmptyScreen, showToast } from "@calcom/ui"; import PageWrapper from "@components/PageWrapper"; function VerifyEmailPage() { const { data } = useEmailVerifyCheck(); const { data: session } = useSession(); const router = useRouter(); const { t } = useLocale(); const mutation = trpc.viewer.auth.resendVerifyEmail.useMutation(); useEffect(() => { if (data?.isVerified) { router.replace("/getting-started"); } // eslint-disable-next-line react-hooks/exhaustive-deps }, [data?.isVerified]); return (