From 04db014b07e833e69e4e1a18526011775432903e Mon Sep 17 00:00:00 2001 From: soe-j <7115203+soe-j@users.noreply.github.com> Date: Tue, 17 May 2022 11:54:54 +0900 Subject: [PATCH] fix: IE11 to use click event `navigator.msMaxTouchPoints` is grater than 0 on IE11. It is enough to judge whether there is `ontouchstart`. --- src/v-click-outside.js | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/v-click-outside.js b/src/v-click-outside.js index 0d43c2f7..7ec8ad1c 100644 --- a/src/v-click-outside.js +++ b/src/v-click-outside.js @@ -1,10 +1,6 @@ const HANDLERS_PROPERTY = '__v-click-outside' const HAS_WINDOWS = typeof window !== 'undefined' -const HAS_NAVIGATOR = typeof navigator !== 'undefined' -const IS_TOUCH = - HAS_WINDOWS && - ('ontouchstart' in window || - (HAS_NAVIGATOR && navigator.msMaxTouchPoints > 0)) +const IS_TOUCH = HAS_WINDOWS && 'ontouchstart' in window const EVENTS = IS_TOUCH ? ['touchstart'] : ['click'] function processDirectiveArguments(bindingValue) {