]> git.ipfire.org Git - thirdparty/bootstrap.git/commitdiff
Remove `MSPointerEvent` and `ms-touch-action` in tests (#30463)
authorXhmikosR <xhmikosr@gmail.com>
Sun, 29 Mar 2020 06:59:54 +0000 (09:59 +0300)
committerGitHub <noreply@github.com>
Sun, 29 Mar 2020 06:59:54 +0000 (09:59 +0300)
js/src/carousel.js
js/tests/unit/carousel.spec.js

index 509f7ca9d8fa86f665ec1e17f650b2230ccfafe5..3020974d382b0882ea50ee150cb1aba42d718733 100644 (file)
@@ -118,7 +118,7 @@ class Carousel {
     this._element = element
     this._indicatorsElement = SelectorEngine.findOne(SELECTOR_INDICATORS, this._element)
     this._touchSupported = 'ontouchstart' in document.documentElement || navigator.maxTouchPoints > 0
-    this._pointerEvent = Boolean(window.PointerEvent || window.MSPointerEvent)
+    this._pointerEvent = Boolean(window.PointerEvent)
 
     this._addEventListeners()
     Data.setData(element, DATA_KEY, this)
index a163f9ae41e0cc4d7ad5ed9a7a719d90a14895f4..be32d19d9b36412495efa66057cbebc2a47c453a 100644 (file)
@@ -5,12 +5,11 @@ import EventHandler from '../../src/dom/event-handler'
 import { getFixture, clearFixture, createEvent, jQueryMock } from '../helpers/fixture'
 
 describe('Carousel', () => {
-  const { Simulator, PointerEvent, MSPointerEvent } = window
-  const originWinPointerEvent = PointerEvent || MSPointerEvent
-  const supportPointerEvent = Boolean(PointerEvent || MSPointerEvent)
+  const { Simulator, PointerEvent } = window
+  const originWinPointerEvent = PointerEvent
+  const supportPointerEvent = Boolean(PointerEvent)
 
-  window.MSPointerEvent = null
-  const cssStyleCarousel = '.carousel.pointer-event { -ms-touch-action: none; touch-action: none; }'
+  const cssStyleCarousel = '.carousel.pointer-event { touch-action: none; }'
 
   const stylesCarousel = document.createElement('style')
   stylesCarousel.type = 'text/css'