Re: [pointerevents] Initial thoughts for gestures (#636)

Better web platform support for gestures is one of my pet peeves. I pitched the idea long time ago while at Google, but nothing came out of it. Implementing gestures is not hard, but it is fiddly, especially supporting multiple gestures on a single item.

After Google, I wrote a gesture library for myself called gesturion. I've looked at all current libraries I could find, and none of them supported my requirements. You can check out the demo of a list with list items responding to 4 different gestures:

https://atotic.github.io/gesturion/demo/list.html

I'd be happy to help you in any way if you are interested.

Here are the problems I thought were worth solving in gesturion:

* support for multiple gestures on a single item. The 'correct' gesture gets triggered depending on initial movement.
* extensible: custom gesture support
* platform bookkeeping during gesture: prevent scroll, turn off text selection
* global notification when new gesture starts. This supports cleanup of artifacts from previous gesture. Ex: swipe menu buttons still showing
* no memory leaks: when element is deleted from dom, the gesture handlers should be automatically deleted, no need to explicitly unregister
* inline gesture registration, just because I am old school I like my handlers inline `onpointerdown="GestureManager.OnEvent(event, PressGesture, HighlightEffect)"`

I believe this would be an important missing piece for web platform on mobile. 

-- 
GitHub Notification of comment by atotic
Please view or discuss this issue at https://github.com/w3c/pointerevents/issues/636#issuecomment-3843670313 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Tuesday, 3 February 2026 21:02:59 UTC