Skip to content
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

Horizontal swipe event has utterly random direction values, including none, up, down, etc. #1299

Open
php4fan opened this issue Mar 25, 2024 · 0 comments

Comments

@php4fan
Copy link

php4fan commented Mar 25, 2024

  1. Run this on a mobile device: https://codepen.io/php4fan/pen/mdgwBdb
  2. Swipe left and right

Expected: the logged value, which is the direction property of the swipe event, should always be 2 when you swipe left and 4 when you swipe right.

Observed: the value sometimes is 1 (NONE) or even 8 (UP).

According to documentation, by default only horizontal swipe recognition is enabled. And indeed, the event does only fire when you swipe horizontally, as expected. However, the value of direction sometimes is neither left nor right, which makes no sense.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant