Skip to content

fix: keep the trace metadata's text off its inset focus ring, and accept two ring cuts #5306 and #5614 chose - #6200

Merged
leaf-agent merged 1 commit into
mainfrom
fix/issue-6192
Nov 16, 2026
Merged

leaf-agent merged 1 commit into
mainfrom
fix/issue-6192

Conversation

@leaf-agent

@leaf-agent leaf-agent commented Nov 16, 2026 •

Copy link
Copy Markdown
Collaborator

After #6193's sample updates, test_each_sampled_focus_ring_is_shown_whole_in_its_surface still reported eight ring faults, which earlier failing samples had hidden. They have three causes. This PR fixes the one that is a real defect. For the other two, it updates the ring reader to accept outcomes that #5306 and #5614 chose on purpose. With this change the journey passes on main 3bc561561. Without it, a tab walk over data-explorer, code-comparison and review-a-fix on that commit still reports all three kinds.

The trace's metadata scroller covered its own ring (review-a-fix). .lf-trace-metadata wears its ring one band inside its edge, but it had no padding. Once #5306 drew every mark as the box's own outline, the scrolled words painted over the ring's left run. The scroller now starts its words a ring's room (5px) in, as the token's rule for an inset ring expects (tokens.css, "Where it stands"). On screen, this changes the review-a-fix trace's metadata pane: its text moves 5px right, and its focused ring's left edge shows whole.

Before: text over the ring's left edge After: the ring's left edge clear

A full-height question's mark runs below the window (data-explorer, notification-playground, shadow-scale). #5306 says so in its description: a question filling a full-height workspace wears its ring 3px outside itself and reaches the window's foot, "so the ring's bottom run falls below the window". browser/AGENTS.md rules out padding the page for a mark. The reader now skips that bottom run when the ring belongs to a box that isn't focused, isn't fixed, and ends the page at the window's foot. The focused control's own ring is still held to the foot. So is a fixed box: test_the_ring_reading_sees_and_measures_a_ring_cast_as_a_shadow plants an unfocused fixed box there and still passes.

A focus preview covers the question around its control (code-comparison, command-hub, motion-playground). Since #5614, a keyboard step onto a control shows its preview. The preview stands clear of the control and of the controls the user could work next, and may cover the rest of the page. Here the "Show instruction" and "Copy Markdown" previews lie over the enclosing question's location ring. The reader no longer samples another box's ring under an open #lf-preview, but it still reads the focused control's own ring there.

How each cause was dated

The test's last pass in a scheduled run was 7cbf67854 (Oct 27). Runs from Oct 28 to Nov 3 failed on earlier samples, and the Nov 4 run already listed the full-height and trace faults. I ran git bisect run over a tab walk of the affected examples:

Checks run on the branch: the journey itself, tests/browser/controls/test_rings.py (27 passed), and tests/browser/test_render_playwright_trace.py. In that last file, test_trace_tree_opened_by_the_browser_keeps_its_match failed once under -n 3 on this branch. It also fails under -n 3 on unchanged main, with the same row position (480 against a 12–111 band), so this change doesn't cause it.

Closes #6192 — automated triage

… accepted ring cuts as accepted

The trace's metadata scroller wears its ring one band inside its edge but had no
padding, so after #5306 drew marks as the box's own outline its words covered the
ring's left run. It now starts its words a ring's room in.

The focus-ring journey's reader also reported two outcomes their changes chose:
- #5306: a mark on a box that ends the page at the window's foot, such as a
  question filling a full-height workspace, runs its bottom band below the window,
  since Leaf doesn't pad the page for a mark. The reader no longer reports that
  bottom run for a non-focused, non-fixed box at the page's end.
- #5614: a focus preview may cover page content beyond its control and the
  controls the user could work next. The reader no longer samples another box's
  ring under the open preview; the focused control's own ring is still read.

Refs #6192
@leaf-agent
leaf-agent merged commit f1552b0 into main Nov 16, 2026
5 checks passed
@leaf-agent
leaf-agent deleted the fix/issue-6192 branch November 16, 2026 19:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

test_each_sampled_focus_ring_is_shown_whole_in_its_surface: eight ring faults on lf-ask sections and a trace mark behind the stale samples

1 participant