-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Prevent event bubbling in polyfill #296
Comments
Call |
Yes, true. That would work, but shouldn't polymer keep track of that somehow? I mean, I shouldn't be forced to stop propagation only for the fallback case. If it works for supporting browsers, it should be the job of the dependent polyfill to prevent the same behaviour in fallback case. Not a big deal for me, but a thing of principles though. 😉 |
Ok, I wasn't understanding that when you wrote 'fallback', you mean Yes, the polyfills and the native semantics should behave the same. For the majority of (bubbling) events, propagation is important, and To be honest, I wasn't aware that the spec has a list of 'non-propagating' On Wed, Sep 25, 2013 at 12:36 PM, Stefan Judis [email protected]:
|
Okay - will read about this "other things in Shadow DOM called 'fallback'". 😉 And thanks for investigating. |
Sorry for being vague about 'fallback', I don't think it's relevant or I would have been clearer. There are references to 'fallback' content here: https://dvcs.w3.org/hg/webcomponents/raw-file/tip/spec/shadow/index.html. Thanks for bringing this problem to our attention. :) |
Should be fixed as of googlearchive/ShadowDOM@b04881f |
When using polymer components and firing events, the original events are still bubbling up. For example when I create a custom element which includes an input field and I define my custom element to trigger a change event on change of this included input field the custom element will trigger 'change' twice.
For example we create this element:
and attach this event handler:
The event handler will be triggered two times. Once for the input element that should be hidden inside of the shadow DOM (but isn't because of the not supporting browser) and once for the change event of the new custom element.
The text was updated successfully, but these errors were encountered: