fix(login): use onChange instead of onBlur with react-hook-form (#11354)

# Which Problems Are Solved

Fixes a problem where submit buttons where not correctly enabled onBlur
event

# How the Problems Are Solved

By changing the react-hook-form mode property to onChange, buttons are
enabled as intended
This commit is contained in:
Max Peintner
2026-01-14 08:07:04 +00:00
committed by GitHub
parent 86fd769439
commit cd36abd725
13 changed files with 38 additions and 131 deletions
@@ -25,7 +25,7 @@ type Props = {
export function RegisterPasskey({ sessionId, userId, isPrompt, organization, requestId, code, codeId }: Props) {
const { handleSubmit, formState } = useForm<Inputs>({
mode: "onBlur",
mode: "onChange",
});
const [error, setError] = useState<string>("");