Skip to content

Commit

Permalink
FIO-9156 fixed the display of Captcha component for nested forms and …
Browse files Browse the repository at this point in the history
…on preview tab
  • Loading branch information
HannaKurban committed Jan 17, 2025
1 parent 4a62b82 commit 172f897
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/Webform.js
Original file line number Diff line number Diff line change
Expand Up @@ -1779,7 +1779,13 @@ export default class Webform extends NestedDataComponent {
});

if (captchaComponent.length > 0) {
captchaComponent[0].verify(`${this.form.name ? this.form.name : 'form'}Load`);
if (this.parent) {
this.parent.subFormReady.then(()=> {
captchaComponent[0].verify(`${this.form.name ? this.form.name : 'form'}Load`);
});
} else {
captchaComponent[0].verify(`${this.form.name ? this.form.name : 'form'}Load`);
};
}
}

Expand Down

0 comments on commit 172f897

Please sign in to comment.