clickOutside兼容辣鸡火狐
parent
00bf4f3d42
commit
4e8e2cdcb4
|
@ -98,9 +98,12 @@ export const clickOutside = function(dom, fn = noop) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
var target = ev.originalTarget || ev.target
|
var target = ev.explicitOriginalTarget || ev.target
|
||||||
console.log(target, typeof target, target.__proto__)
|
if (
|
||||||
if (dom === target || dom.contains(target)) {
|
dom === target ||
|
||||||
|
dom.contains(target) ||
|
||||||
|
(dom.root && dom.root.contains(target))
|
||||||
|
) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Reference in New Issue