Files
Cato ed4288cecd fix(auth): adopt shared account forms and recovery (#51)
* fix(auth): adopt shared account forms and recovery

* fix(auth): use released all-method second-factor protection
2026-10-26 05:34:47 +01:00

33 lines
843 B
TypeScript

"use client";
import { SignUpForm as SharedSignUpForm } from "@bitbaum/accountkit/auth/react";
import type { SignInMethods } from "@bitbaum/accountkit/auth";
import { Link } from "@/i18n/navigation";
import { authClient } from "@/lib/auth-client";
import { ROUTES } from "@/lib/routes";
import { AUTH_CLASSES, useAuthLabels } from "./shared";
export function SignUpForm(props: {
methods: SignInMethods;
next: string;
signUpPath: string;
}) {
const labels = useAuthLabels();
return (
<SharedSignUpForm
{...props}
client={authClient}
classes={AUTH_CLASSES}
labels={labels}
signInLink={
<Link
href={{ pathname: ROUTES.signIn, query: { next: props.next } }}
className="underline underline-offset-4"
>
{labels.signIn}
</Link>
}
/>
);
}