Repository navigation
fix: check visible keyboard badges on touch screens - #4982
Merged
Merged
Conversation
Touch checks now protect the absence of painted keyboard hints instead of requiring retained placeholder badge nodes to be removed. The original field assertion fails on main because Lit retains an empty badge, hidden by the existing :empty rule; both focused touch checks pass with visibility assertions. Product behavior is unchanged. Closes #4923
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.
The touch checks counted retained DOM nodes rather than visible keyboard hints. The composer keeps an empty badge when a placeholder needs rich content, and the existing
.lf-key-badge:emptyrule hides it withdisplay: none; the failing CI screenshot shows no key badge. Both touch checks now require zero visible badges, preserving the guarantee that a phone advertises no keyboard shortcuts without constraining the retained renderer's structure. Runtime behavior is unchanged.The reported field assertion fails on current main with one retained badge. After the assertion correction, both focused touch tests pass (2 passed):
uv run pytest tests/browser/navigation/test_key_surfaces.py -q -n0 -k 'field_names_no_key_to_a_finger or coarse_pointer_keeps_useful_status'The rich placeholder supports the separate speaker faces introduced in #4804 and the reply arrangement in #4510; this repair keeps those choices. The existing placeholder-text checks and navigation checks remain in place.
Closes #4923 — automated triage