mirror of
https://github.com/documenso/documenso.git
synced 2025-11-10 04:22:32 +10:00
feat: reset password from on submit
This commit is contained in:
@ -39,6 +39,7 @@ export const PasswordForm = ({ className }: PasswordFormProps) => {
|
|||||||
const {
|
const {
|
||||||
register,
|
register,
|
||||||
handleSubmit,
|
handleSubmit,
|
||||||
|
reset,
|
||||||
formState: { errors, isSubmitting },
|
formState: { errors, isSubmitting },
|
||||||
} = useForm<TPasswordFormSchema>({
|
} = useForm<TPasswordFormSchema>({
|
||||||
values: {
|
values: {
|
||||||
@ -56,6 +57,8 @@ export const PasswordForm = ({ className }: PasswordFormProps) => {
|
|||||||
password,
|
password,
|
||||||
});
|
});
|
||||||
|
|
||||||
|
reset();
|
||||||
|
|
||||||
toast({
|
toast({
|
||||||
title: 'Password updated',
|
title: 'Password updated',
|
||||||
description: 'Your password has been updated successfully.',
|
description: 'Your password has been updated successfully.',
|
||||||
|
|||||||
Reference in New Issue
Block a user