Invite prefill email (#43)

* Add prepopulation of email field in sign-up form
* Updated packages
This commit is contained in:
Giancarlo Buomprisco
2024-07-11 13:59:14 +08:00
committed by GitHub
parent 4f0e6b9bbb
commit 21f42f14ce
24 changed files with 151 additions and 85 deletions

View File

@@ -28,10 +28,14 @@ export function MagicLinkAuthContainer({
inviteToken,
redirectUrl,
shouldCreateUser,
defaultValues,
}: {
inviteToken?: string;
redirectUrl: string;
shouldCreateUser: boolean;
defaultValues?: {
email: string;
};
}) {
const { captchaToken, resetCaptchaToken } = useCaptchaToken();
const { t } = useTranslation();
@@ -44,7 +48,7 @@ export function MagicLinkAuthContainer({
}),
),
defaultValues: {
email: '',
email: defaultValues?.email ?? ''
},
});