From 00d680b441dabe094cb88ca8138c348c8384d313 Mon Sep 17 00:00:00 2001 From: ManjaroOne666 Date: Tue, 5 Feb 2019 12:36:50 +0000 Subject: [PATCH] scroll/touch events now passive --- components/GalleryThumbs.vue | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/components/GalleryThumbs.vue b/components/GalleryThumbs.vue index 6eaf221..53cacc8 100644 --- a/components/GalleryThumbs.vue +++ b/components/GalleryThumbs.vue @@ -117,11 +117,11 @@ export default { mounted () { window.addEventListener('resize', this.handleResize) - this.$refs.galleryThumbsList.addEventListener('touchstart', this.handleTouch) - this.$refs.galleryThumbsList.addEventListener('touchend', this.handleTouch) - this.$refs.galleryThumbsList.addEventListener('wheel', this.handleThumbsScroll) + this.$refs.galleryThumbsList.addEventListener('touchstart', this.handleTouch, { passive: true }) + this.$refs.galleryThumbsList.addEventListener('touchend', this.handleTouch, { passive: true }) + this.$refs.galleryThumbsList.addEventListener('wheel', this.handleThumbsScroll, { passive: true }) // firefox - this.$refs.galleryThumbsList.addEventListener('mousewheel', this.handleThumbsScroll) + this.$refs.galleryThumbsList.addEventListener('mousewheel', this.handleThumbsScroll, { passive: true }) this.$nextTick(function () { this.updateElements() this.scrollToThumb(this.activeIndex)