From 414b1fc88b1fc9d527d93e9fc1b3fa21d8c098e3 Mon Sep 17 00:00:00 2001 From: Tiago Evangelista Pinto Date: Mon, 27 Nov 2023 18:07:11 -0300 Subject: [PATCH] fix(onboarding-ui): Disable registration button when offline registration succeed (#1227) --- .changeset/pretty-students-wonder.md | 5 +++++ .../src/forms/RegisterOfflineForm/steps/PasteStep.tsx | 8 ++++++-- 2 files changed, 11 insertions(+), 2 deletions(-) create mode 100644 .changeset/pretty-students-wonder.md diff --git a/.changeset/pretty-students-wonder.md b/.changeset/pretty-students-wonder.md new file mode 100644 index 0000000000..0eebb6dba1 --- /dev/null +++ b/.changeset/pretty-students-wonder.md @@ -0,0 +1,5 @@ +--- +"@rocket.chat/onboarding-ui": patch +--- + +Fix offline registration wizard validation diff --git a/packages/onboarding-ui/src/forms/RegisterOfflineForm/steps/PasteStep.tsx b/packages/onboarding-ui/src/forms/RegisterOfflineForm/steps/PasteStep.tsx index 30d6838a95..8a26c3f967 100644 --- a/packages/onboarding-ui/src/forms/RegisterOfflineForm/steps/PasteStep.tsx +++ b/packages/onboarding-ui/src/forms/RegisterOfflineForm/steps/PasteStep.tsx @@ -17,7 +17,7 @@ const PasteStep = ({ setStep }: PasteStepProps): ReactElement => { const isMobile = !breakpoints.includes('md'); const { register, - formState: { isSubmitting, isValid }, + formState: { isSubmitting, isValidating, isSubmitSuccessful }, } = useFormContext(); return ( @@ -59,7 +59,11 @@ const PasteStep = ({ setStep }: PasteStepProps): ReactElement => { -