From d2dd42dab4313145bddd33bc2fb854b137efafb3 Mon Sep 17 00:00:00 2001 From: XhmikosR Date: Fri, 4 Dec 2020 14:56:10 +0200 Subject: [PATCH] Update carousel.js --- js/src/carousel.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/src/carousel.js b/js/src/carousel.js index d4a24ab82..2fd7b14ab 100644 --- a/js/src/carousel.js +++ b/js/src/carousel.js @@ -120,7 +120,7 @@ class Carousel extends BaseComponent { this._config = this._getConfig(config) this._indicatorsElement = SelectorEngine.findOne(SELECTOR_INDICATORS, this._element) /* eslint-disable-next-line compat/compat */ - this._touchSupported = 'ontouchstart' in window || (('maxTouchPoints' in navigator) && (navigator.maxTouchPoints > 0)) + this._touchSupported = 'ontouchstart' in document.documentElement || (('maxTouchPoints' in navigator) && (navigator.maxTouchPoints > 0)) this._pointerEvent = PointerEvent in window this._addEventListeners()