mirror of
https://github.com/jquery/jquery.git
synced 2026-01-24 12:38:22 -05:00
Fix #13180: don't delegate into SVG <use>
This commit is contained in:
committed by
Dave Methvin
parent
7812aab1c9
commit
f860e0bd2f
@@ -405,8 +405,9 @@ jQuery.event = {
|
|||||||
cur = event.target;
|
cur = event.target;
|
||||||
|
|
||||||
// Find delegate handlers
|
// Find delegate handlers
|
||||||
|
// Black-hole SVG <use> instance trees (#13180)
|
||||||
// Avoid non-left-click bubbling in Firefox (#3861)
|
// Avoid non-left-click bubbling in Firefox (#3861)
|
||||||
if ( delegateCount && (!event.button || event.type !== "click") ) {
|
if ( delegateCount && cur.nodeType && (!event.button || event.type !== "click") ) {
|
||||||
|
|
||||||
for ( ; cur != this; cur = cur.parentNode || this ) {
|
for ( ; cur != this; cur = cur.parentNode || this ) {
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user