Repository navigation
fix: a finger holds, drags a slider and scrolls on iOS Safari - #27
Merged
Merged
Conversation
Found on the web gallery on iOS Safari, which sends a long press as no contextmenu and selects the text under the finger instead, and sends every move of a touch to the element it went down on. - A hold in a browser with no sleep from its host takes the browser's own timer, so it fires while the finger is still down there too. Where the browser also sends contextmenu for the same press (Chrome on Android), it opens nothing more (Hold::held). - What a finger holds or drags (a hold's area, a context menu's, a tile, a table's row, a slider, a switch, a segmented control, a chip, a button, a stepper) selects no text and shows no callout. - A slider follows a finger along its rail, reading the move against its own box, as well as by its stops; it leaves a vertical pan to the page. - The gallery's scroll demo is dragged by a finger or a held button.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Found on the web gallery on iOS Safari. Safari sends no
contextmenufor a long press and selects the text under the finger instead. It also sends every move of a touch to the element the touch started on.Fixes
contextmenufor the same press (Chrome on Android), nothing opens a second time (Hold::held).touch-action: pan-y, so a vertical swipe still scrolls the page.Blitz
Checks
cargo fmt --check, clippy (native and wasm32 web), andcargo test --workspace(73 library, 7 audit, 77 Blitz) pass on top of perf: a menu's step and a press draw only the controls they change #26.Generated by Claude Code