mirror of
https://github.com/formbricks/formbricks.git
synced 2026-02-08 23:59:38 -06:00
render auth page client-side to avoid vercel bug on searchParams
This commit is contained in:
@@ -1,21 +1,25 @@
|
||||
import { Logo } from "@/app/Logo";
|
||||
"use client";
|
||||
|
||||
import { useSearchParams } from "next/navigation";
|
||||
import { RequestVerificationEmail } from "./RequestVerificationEmail";
|
||||
|
||||
interface SignInProps {
|
||||
/* interface SignInProps {
|
||||
searchParams?: {
|
||||
email?: string;
|
||||
};
|
||||
}
|
||||
};
|
||||
} */
|
||||
|
||||
export default function SignIn({ searchParams }: SignInProps) {
|
||||
export default function SignIn() {
|
||||
const searchParams = useSearchParams();
|
||||
return (
|
||||
<>
|
||||
{searchParams.email ? (
|
||||
{searchParams.get("email") ? (
|
||||
<>
|
||||
<h1 className="leading-2 mb-4 text-center font-bold">Please verify your email address</h1>
|
||||
<p className="text-center">
|
||||
We have sent you an email to the address <span className="italic">{searchParams.email}</span>.
|
||||
Please click the link in the email to activate your account.
|
||||
We have sent you an email to the address{" "}
|
||||
<span className="italic">{searchParams.get("email")}</span>. Please click the link in the email to
|
||||
activate your account.
|
||||
</p>
|
||||
<hr className="my-4" />
|
||||
<p className="text-center text-xs">
|
||||
@@ -24,7 +28,7 @@ export default function SignIn({ searchParams }: SignInProps) {
|
||||
Click the button below to request a new email.
|
||||
</p>
|
||||
<div className="mt-5">
|
||||
<RequestVerificationEmail email={searchParams.email} />
|
||||
<RequestVerificationEmail email={searchParams.get("email")} />
|
||||
</div>
|
||||
</>
|
||||
) : (
|
||||
|
||||
Reference in New Issue
Block a user