mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-05 19:41:42 +08:00
fix(touch-emulator): 添加 Element.prototype.matches 的polyfill (#8992)
This commit is contained in:
parent
d6663464c9
commit
63c283d8bd
@ -51,6 +51,12 @@
|
||||
};
|
||||
}
|
||||
|
||||
if (!Element.prototype.matches) {
|
||||
Element.prototype.matches =
|
||||
Element.prototype.msMatchesSelector ||
|
||||
Element.prototype.webkitMatchesSelector;
|
||||
}
|
||||
|
||||
if (!Element.prototype.closest) {
|
||||
Element.prototype.closest = function (s) {
|
||||
var el = this;
|
||||
|
Loading…
x
Reference in New Issue
Block a user