-
Notifications
You must be signed in to change notification settings - Fork 146
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Actually prevent passive touchmove events default behavior #88
Actually prevent passive touchmove events default behavior #88
Conversation
5084d8e
to
93d1af0
Compare
@kontest @kl0tl Thanks for the PR, i've been interested in a solution to this for a while. I like where you're going with this and the simple I'd like to see if we could add tests and possibly move the I'm hoping to take a deeper look at this and compare this solution to react-easy-swipe's solution too 😄 |
@hartzis I’ve moved the definition of the ref handler out of |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pulled down the branch, did some testing and some research. Moved the listener setup inside react lifecycle methods to avoid the ref being |
(issue fixed in react-swipeable 4.2.0: see FormidableLabs/react-swipeable#88)
It’s possible to listen to
touchmove
manually to ensure the listener has the ability to prevent the default event behavior. Otherwise it’s impossible to let users scroll vertically while playing a video with audio enabled on horizontal swipe in Chrome 56+.