Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Event bubbling... #12

Open
dkimbell13 opened this issue Jan 29, 2024 · 0 comments
Open

Add Event bubbling... #12

dkimbell13 opened this issue Jan 29, 2024 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@dkimbell13
Copy link

Your events do not bubble up!
document.querySelector(this.wz_class).dispatchEvent(new CustomEvent("wz.update", { detail: { "target": this.wz_class, "elem": document.querySelector(this.wz_class) } }));

could/should be something like...
document.querySelector(this.wz_class).dispatchEvent(new CustomEvent("wz.update", { bubbles: true, //Enable bubbling detail: { "target": this.wz_class, "elem": document.querySelector(this.wz_class) } }));

This is prevalent throughout your event dispatching. Please ensure that events bubble, so we don't have to add event handlers directly to the .wizard class element, and instead can bind to the document, with a reference to the .wizard, in the cases where we are dynamically adding a form wizard to our web page.

Thanks!

@AdrianVillamayor AdrianVillamayor self-assigned this Jan 30, 2024
@AdrianVillamayor AdrianVillamayor added bug Something isn't working enhancement New feature or request and removed bug Something isn't working labels Jan 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants