Skip to content
This repository has been archived by the owner on May 16, 2024. It is now read-only.

jsaction can work against touch adjstument behavior of Chrome #8

Open
RByers opened this issue May 21, 2015 · 0 comments
Open

jsaction can work against touch adjstument behavior of Chrome #8

RByers opened this issue May 21, 2015 · 0 comments

Comments

@RByers
Copy link

RByers commented May 21, 2015

One problem with event delegation in general is that it can defeat efforts from the browser to try to guess what elements are activateable. Eg. Chrome has a 'touch adjustment' heuristic which is necessary to get good touch targeting on websites not specifically designed for touch. Without any event handler, :active/:hover effect or other indication that an element is tappable, Chrome will slightly bias taps towards other elements under the contact area of the finger. Safari and IE do something like this too, but details aren't available (and they probably do a better job at avoiding issues than us!).

Here is an example where using jsaction in conjunction with Chrome's touch adjustment behavior triggered confusion / problems.

Perhaps jsaction should do something to continue to give the browser a signal that such elements are really tappable? Eg. Maybe it should register dummy event handlers on the elements? I'm happy to make changes to Blink here if we can agree on some protocol, but it should be based around standard APIs (not library-level conventions). Eg. we don't currently take ARIA role attributes into account in this heuristic, but perhaps we should? Longer term, maybe we should try to standardize an API like Element.supportsActivation which you could explicitly set to true when our heuristics don't guess correctly?

Thoughts?

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

No branches or pull requests

1 participant