-
-
Notifications
You must be signed in to change notification settings - Fork 33.7k
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
Sometimes bubbling stops working on Safari #11014
Comments
Seems to be result of a bug in safari. Basically, the event.timestamp should never be 0, and it seems to be for Safari. It's not in other browsers. Someone else came across something similar in vanilla js: https://stackoverflow.com/questions/57744414/safari-event-timestamp-is-0 This is the only info in that direction that i could find quickly. Basically, the event.timestamp should never be 0, and it seems to be for Safari. It's not in other browsers. |
Yes, you are right, this is an error exclusively in safari, but the case with a zero value is taken into account in the conditions. https://github.com/vuejs/vue/blob/dev/dist/vue.esm.js#L7559 |
@LinusBorg as can I see you use chain of next rules: // crutch // primary rule // crutch // crutch Otherwise result is false, and event handler doesn't runs. If you rely to timestamp rule why you not using Rule
In this case when i make click on icon the I think the chain will should look like this: // primary rule // crutch // crutch when event started from handler - binded element // crutch when event started from child element // crutch |
I created the pull request #11031 |
in oppon, e.timeStamp size is 6,attachedTimestamp size is 13 .Event is alway no work . |
Version
2.6.11
Reproduction link
https://codesandbox.io/s/vue-safari-error-tg4mm
Steps to reproduce
The bug reproduction is quite specific, so please be patient
Now the difficult and not completely clear part
What is expected?
click and method on it works
What is actually happening?
in the above case, this check is not performed
https://github.com/vuejs/vue/blob/dev/dist/vue.esm.js#L7549
This is a specific situation - something like emulating an application in which there is a lot of legacy. different sections can be written on different technologies and sometimes this bug is caught when switching between sections. Unfortunately, I can’t even suggest how this bug is related to the instantiation of a new vue, maybe this is a coincidence
I think this can be fixed by adding "e.target.contains (e.currentTarget)" to the conditions specified in https://github.com/vuejs/vue/blob/dev/dist/vue.esm.js#L7549 but I don’t know if this will not affect performance
The text was updated successfully, but these errors were encountered: