Bug 221366
Summary: | :active pseudoclass not removed when element ineligible for click event (iOS) | ||
---|---|---|---|
Product: | WebKit | Reporter: | Jordan Walke <jordojw> |
Component: | CSS | Assignee: | Nobody <webkit-unassigned> |
Status: | NEW | ||
Severity: | Normal | CC: | akeerthi, dino, koivisto, simon.fraser, smoley, thorton, webkit-bug-importer, wenson_hsieh |
Priority: | P2 | Keywords: | InRadar |
Version: | WebKit Nightly Build | ||
Hardware: | Unspecified | ||
OS: | Unspecified |
Jordan Walke
The :active pseudoclass is correctly applied to elements that have an ontouchstart event handler, when the user begins touching an anchor element (probably buttons too). However, when the tap become ineligible while the touches are still active, the :active pseudoclass is not removed. This can occur when the user moves their touch beyond some threshold, *or* if the element is contained inside of a scroll view (or page) that scrolls. In those cases, the :active pseudoclass should be removed. Having a reliable :active class is important for providing visual feedback to the user that when they release their touch, a "click" (or href redirect on anchor) will be triggered.
https://twitter.com/jordwalke/status/1355644884502278144
The :hover pseudoclass also remains "stuck" even after the user removes their touches, but this behavior may not be as critical to fix because there are other ways of removing the :hover class at the application level or css. The :active class is more important to fix because there is no reliable way to fix this in application space / css.
Attachments | ||
---|---|---|
Add attachment proposed patch, testcase, etc. |
Smoley
Thanks for filing. Apple internal see also:
rdar://49868944