Skip to content

Commit 6284b37

Browse files
committed
Don't correct event target from text nodes to parent node for DOM mutation events.
1 parent 6a0942c commit 6284b37

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/event.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -448,7 +448,7 @@ jQuery.event = {
448448
}
449449

450450
// check if target is a textnode (safari)
451-
if ( event.target.nodeType === 3 ) {
451+
if ( event.target.nodeType === 3 && event.type.slice(0,3) !== "DOM" ) { // DOM mutation events really have text nodes as targets
452452
event.target = event.target.parentNode;
453453
}
454454

0 commit comments

Comments
 (0)