Repository navigation
Fix: keep folder badges inside their own page - #64
Merged
Merged
Conversation
Each folder page was exactly the width of its icon grid and sat flush against the next one in a single strip, so a badge overhanging the right-hand column rendered in the next page's space. Inset every page by the badge overhang, clip each page, and take the inset out of the box padding so the icons keep their positions. Focus the mobile folder overlay itself instead of letting the trap fall back to the first app link, and reset the plain focus outline on that link so WebKit cannot paint its own ring.
Safari draws its own focus ring for a script-driven focus on an anchor, and only :focus-visible is styled. The desktop overlay had the same trap and the same missing plain-focus rule as the mobile one.
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.
Summary
.dyn-page-gridby the badge overhang (7px scaled by--sc, clamped to the box padding) and give the page its ownoverflow:hidden, so a badge is clipped by the page it belongs to instead of by the shared viewport.translateXstep in the padded page width so pages no longer sit flush against each other.tabindex="-1"and pass each asinitialFocus, so opening a folder no longer moves focus onto the first app link.:focusoutline on both overlays and their app links, leaving the existing:focus-visibleaccent ring as the only focus style.Testing
All green, except the Docker build smoke test, which has no local Docker and is left to CI. Added 10 tests in
ui/test/folder-overlay.test.mjscovering the page inset, the padded page step, the per-page clip, and the focus target of both overlays.Checklist