Open atulr-grazitti opened 4 years ago
I've solved this before using @touchstart.prevent=""
on the wrapper containing Hooper. This isn't perfect on mobile though (can prevent user from scrolling further down ) so I'm still working on it.
I've solved this before using
@touchstart.prevent=""
on the wrapper containing Hooper. This isn't perfect on mobile though (can prevent user from scrolling further down ) so I'm still working on it.
Did you find a solution?
Update: I applied the following CSS to the div that contains the hooper element
touch-action: pan-y;
This only allows vertical swiping on the element. But horizontal swiping still works because of the hooper code :)
Let me know if it also works for you guys
When you are using the vertical slider and try to swipe on a touch device it's scrolling the window as well, and ideally, when you are swiping the slider its should not scroll the window.
I am not able to find or think the perfect solution for it, but I have used a simple trick to get this solve, Although I am sure better solution can be found.
So What I have done, For a touch device on touch-start and touch-move events I have made body's overflow hidden and on touch-end I have made it auto again, So by this, my problem gets solved, but it would be nice if Hooper handles this.