fix: update the dialog cancel to reset
This commit is contained in:
@@ -202,7 +202,7 @@ export const EnableAuthenticatorAppDialog = ({
|
||||
variant="secondary"
|
||||
onClick={() => {
|
||||
onOpenChange(false);
|
||||
setupTwoFactorAuthenticationForm.setValue('password', '');
|
||||
setupTwoFactorAuthenticationForm.reset();
|
||||
}}
|
||||
>
|
||||
Cancel
|
||||
|
||||
@@ -138,7 +138,14 @@ export const ViewRecoveryCodesDialog = ({ open, onOpenChange }: ViewRecoveryCode
|
||||
/>
|
||||
|
||||
<DialogFooter>
|
||||
<Button type="button" variant="secondary" onClick={() => onOpenChange(false)}>
|
||||
<Button
|
||||
type="button"
|
||||
variant="secondary"
|
||||
onClick={() => {
|
||||
onOpenChange(false);
|
||||
viewRecoveryCodesForm.reset();
|
||||
}}
|
||||
>
|
||||
Cancel
|
||||
</Button>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user