1
0
mirror of https://github.com/webslides/WebSlides.git synced 2025-08-17 18:37:00 +02:00

Avoiding scroll transition on mobile

This commit is contained in:
Antonio Laguna
2017-02-27 12:50:19 +01:00
parent 4379122d1d
commit 5a262f5460

View File

@@ -1,4 +1,4 @@
import ScrollHelper from '../utils/scroll-to'; import MobileDetector from '../utils/mobile-detector';
const MIN_WHEEL_DELTA = 40; const MIN_WHEEL_DELTA = 40;
@@ -17,7 +17,7 @@ export default class Scroll {
this.scrollContainer_ = wsInstance.el; this.scrollContainer_ = wsInstance.el;
this.isGoingUp_ = false; this.isGoingUp_ = false;
if (this.ws_.isVertical) { if (this.ws_.isVertical && !MobileDetector.isAny()) {
this.scrollContainer_.addEventListener( this.scrollContainer_.addEventListener(
'wheel', this.onMouseWheel_.bind(this)); 'wheel', this.onMouseWheel_.bind(this));
} }