You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Click on "Some text". Observe it logs "Inner clicked".
Click on "And then a nested div". Observe it logs both "Inner clicked" and "Outer clicked".
Change yew's code as described at the top.
Now clicking "And then a nested div" logs only "Inner clicked".
Expected behavior
Propagation should be cancelled even if the listener is not attached to the innermost element of the DOM element to which the event was first delivered.
Environment:
Yew version: master
Rust version: 1.56.1
Target, if relevant: wasm32-unknown-emscripten (probably not relevant)
Build tool, if relevant: trunk (proably not relevant)
OS, if relevant: Linux (probably not relevant)
Browser and version, if relevant: Firefox 94.0.2
Questionnaire
I'm interested in fixing this myself but don't know where to start
I would like to fix and I have a solution
I don't have time to fix this right now, but maybe later
If you the maintainers like the fix described at the top I can turn this into a pull request. Or you can do it if you'd rather avoid a roundtrip. Alternately, if this isn't the right change and you can describe how it's wrong, I can create a PR with the right change instead.
The text was updated successfully, but these errors were encountered:
Problem
I think the check for event propagation cancellation happens too early. In particular, I think that
ought to be
Steps To Reproduce
Using this simple program:
Expected behavior
Propagation should be cancelled even if the listener is not attached to the innermost element of the DOM element to which the event was first delivered.
Environment:
Questionnaire
If you the maintainers like the fix described at the top I can turn this into a pull request. Or you can do it if you'd rather avoid a roundtrip. Alternately, if this isn't the right change and you can describe how it's wrong, I can create a PR with the right change instead.
The text was updated successfully, but these errors were encountered: