Skip to content

Commit

Permalink
Try and run validation after tab switch only after timeout
Browse files Browse the repository at this point in the history
  • Loading branch information
Kadrian committed May 14, 2024
1 parent cfa4f91 commit ce8e694
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion frontend/src/js/external-forms/form/fields/TabsField.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,9 @@ export const TabsField = ({
selectedTab={fieldProps.value as string}
onSelectTab={(tab) => {
commonProps.setValue(field.name, tab, setValueConfig);
commonProps.trigger();
setTimeout(() => {
commonProps.trigger();
}, 100);
}}
options={field.tabs.map((tab) => ({
label: () => tab.title[commonProps.locale] || "",
Expand Down

0 comments on commit ce8e694

Please sign in to comment.