Repository navigation
Repair UI composition and reply continuity, and improve evaluation reports - #4638
Merged
Merged
Conversation
# Conflicts: # README.md # dev/leaf_dev/arms.py # dev/leaf_dev/commands/eval_report.py # dev/tests/node/test_authoring_assertion.cjs # dist/kernel/kernel.json # dist/kernel/runtime/bundle-content-layout.js # dist/kernel/runtime/bundle-disclosure.js # evals/README.md # leaf-assets.json
leaf-agent
approved these changes
Oct 28, 2026
This was referenced Nov 1, 2026
max-sixty
pushed a commit
that referenced
this pull request
Nov 1, 2026
The notification simulator now fills authored feed containers rather than appending new siblings beside each figure’s authored caption. This preserves the figure’s child structure during upgrade while keeping generated notification words quotable. The insertion came from #4638’s move to selectable previews; this keeps that interaction and both preview formats. No visual change is intended. Validation: the reported `test_page_fixture_renders[notification-playground]` fails before this change and passes afterward (43 seconds). The notification playground workspace/layout browser check also passes. The existing regression covers the defect without changing its assertion. Closes #4933 — automated triage --------- Co-authored-by: leaf-agent <[email protected]>
max-sixty
added a commit
that referenced
this pull request
Nov 5, 2026
At 390x844 under a finger, `data-explorer`'s first screen now holds both filters, the result count, all four columns of the result table and Build query. Before, the count stood at 878px, under the floating panel, and the table scrolled sideways with Risk and Owner past its frame's edge. This is the last live item of the phone-quality queue. Of the four others, three already pass on current main and one is `lf-tabs`' own phone design. They are listed below with the measurements behind each verdict. This changes desktop too: the row buttons' words are shorter at every width. `data-explorer` has no catalog still, since it is a link in `docs/examples.html` rather than a card, so no still shows this change. This PR also moves the asset pin to max-sixty/leaf-assets@9c3dd34381b8: `wt refresh-previews` recaptured all 19 catalog stills, and the README's image URLs follow the pin. None of those differences comes from the change above. They are look changes landed since the pin last moved on 31 October (#4875). `dynamic-widgets` differs most, in 9% of its pixels, and the four largest show the same layouts with today's control faces. No demo image changed. The capture ran on this branch's base, 22accdd. ## What changed `examples/data-explorer.html`: - **At every width**, the buttons read "Move up", "Move down" and "Remove", and each `.query-row` is `role="group"` with `aria-label="Filter N"`, renumbered as rows move. A button's accessible name is its visible text, and the group says which filter it acts on. - **At every width**, the result table drops its `min-width: 30rem`. - **At 42rem or narrower**, a filter row is flex items sized to their content. Each select is as wide as its longest option, the fields' side padding is `--sp-2` (`--wa-form-control-padding-inline`), and Value (`.query-value`, basis 5rem) takes the rest. So Field, Operator and Value share one line down to a 360px window, and Value wraps onto its own line below that. The three buttons take the next line. - **At 42rem or narrower**, the table is `table-layout: auto`, because equal columns split words below about a 355px window ("Checko|ut"). `tests/journeys/test_render_widgets.py`: the data explorer journey now reaches each button through its group by name, and asserts the group's number follows the row when it moves. It fails with the group role removed, and with the label following the filter's id instead of its place. ## Evidence Stills are under `/Users/maximilian/.tmp/leaf.agent-a1ac83feeb90a4603/phone-examples/`: | state | before | after | | --- | --- | --- | | 390x844 touch, at rest | `data-explorer-390-before.png` | `data-explorer-390-after.png` | | same, dark | `data-explorer-390-dark-before.png` | `data-explorer-390-dark-after.png` | | 390x844, after typing 80 into filter 2's value by touch | `data-explorer-390-before-typing.png` | `data-explorer-390-after-typing.png` | | 360x740 and 320x568 touch | not captured | `data-explorer-360-after.png`, `data-explorer-320-after.png` | | 320x568 touch, all six releases | not captured | `data-explorer-320-six-rows-after.png` | | 1120x700 | `data-explorer-1120-before.png` | `data-explorer-1120-after.png` | | 1280x800 | `data-explorer-1280-before.png` | `data-explorer-1280-after.png` | | 1440x900 | `data-explorer-1440-before.png` | `data-explorer-1440-after.png` | | 844x390 (`playground-short-window`) | `data-explorer-844x390-before.png` | `data-explorer-844x390-after.png` | The pairs come from `uv run leaf-dev stills --authored --state data-explorer` with `--viewport phone` (with and without `--scheme dark`), `--viewport 1120x700`, `--viewport desktop`, and `--state playground-short-window`. The measurements come from `leaf-dev probe data-explorer --viewport phone` (or `--viewport WxH --touch`) with a journey that taps the value field, fills it and swipes the page with CDP touch events: | at 390x844, touch | main | this branch | | --- | --- | --- | | "2 releases shown" top | 878px (panel at 782) | 551px | | table frame client / scroll width | 336 / 480 | 336 / 336 | | Risk and Owner headers | right edges 377, 436 (frame ends 363) | 254, 313 | | Build query top | below the fold | 717px | | after filling 80 by touch | count at 861, off screen | count at 551, on screen, no scroll | **Names.** The accessibility tree at every width reads `group "Filter 2"` holding `button "Move up"`, `button "Move down"` and `button "Remove"`. **Table.** With the default rows and with all six releases, no word splits across lines at 320, 340, 355, 360, 390 or 430px in Chromium, nor at 320, 340 or 390px in Firefox. The frame overflows only at 320px with no filters, by 1px (limit 4 and 6 in Chromium, limit 6 in Firefox). The cost of auto layout is that column edges move when the result set changes. At 390x844, Owner's left edge moves 14px when filter 2's value goes from 40 to 80, and it spans 18px across the seven result sets read (15px at 320x568, 17px at 360x740, 20px at 430x932, in Chromium). **Fields.** Each select holds its longest option ("is above", 62px of text) at 320, 340, 355, 360, 390 and 430px (inner room 91, 101, 64, 66, 76, 89px). **Reach.** With a third filter added, the corpus sweep's own aim reader (`aims.js` `flooredAims` with the selector list from `shadow.css`) finds no control under the 44px floor at 390x844 or 360x740. At 320x568 it reports two buttons scrolled under the playground's sticky controls after Add filter moves focus, and main's page reports two as well. **Desktop.** The buttons' words change at every width. Where a row wraps depends on the windows below, read on both arms with `probe --base --authored`: | window | row height, main → here | count top, main → here | frame client / scroll, main → here | | --- | --- | --- | --- | | 700x900 | 100 → 100 | 511 → 511 | 646 / 646 → 646 / 646 | | 800x900 | 100 → 100 | 350 → 350 | 478 / 480 → 478 / 478 | | 844x390 | 100 → 100 | 358 → 358 | 507 / 507 → 507 / 507 | | 1000x800 | 100 → 100 | 350 → 350 | 611 / 611 → 611 / 611 | | 1280x800 | 100 → 62 | 350 → 274 | 798 / 798 → 798 / 798 | | 1440x900 | 62 → 62 | 274 → 274 | 905 / 905 → 905 / 905 | So at 1280x800 the shorter buttons fit beside the fields, and the rows are 38px shorter each. At 800x900 the removed minimum stops a 2px sideways scroll on main. At 1120x700 the rows keep their shape and only the words change. ## The rest of the queue, re-measured on main at 390x844 by touch - **`alert-review`**, no change. The side list becomes a 2357px strip of 14 tabs in a 364px row, which is `lf-tabs`' recorded phone design for a queue (`packages/default/styles/tabs.css`, "A list beside its panels"): the open item stays one row down however long the queue. By touch, a swipe scrolls the strip (scrollLeft 0 → 342 → 1993), each group label sticks at the row's start, tapping the last tab opens it whole in view, and Next on me returns to the first open item. Still: `alert-review-390-unchanged.png`. - **`code-comparison`**, no change. #4638 moved its controls from the playground's sticky rail into the preview two days after the issue's survey. Only the 38px header and 53px tab strip stick now, and the controls scroll away with the page. Reader A scrolls sideways (312 / 819) because "compact · scroll" is the treatment the page compares. Still: `code-comparison-390-unchanged.png`. - **`dynamic-widgets`**, no change. All four `lf-text-document` tab strips are 340 / 340 with both disclosures open, and nothing on the page scrolls sideways. Still: `dynamic-widgets-390-unchanged.png`. - **`github-discoveries`**, no change. No `pre` is 811px wide now. Six code listings inside the collapsed "Source & details" scroll inside their own 276px box (widest 590px), and the page doesn't scroll sideways. A finger swipe on the AX listing scrolls it 212px with no page scroll. Still: `github-discoveries-390-unchanged.png`. The issue's second paragraph, touch controls under 32px, was settled in #3902, whose corpus sweep holds every tab to the 44px floor at 390px. ## What ran - `uv run pytest -n 2 "tests/journeys/test_render_widgets.py::test_structured_data_explorer_keeps_one_aggregate_query_configuration" "tests/journeys/test_render_export.py::test_playground_examples_keep_their_offline_interaction_mode[data-explorer]"`: 2 passed. These are the only tests that read the page's selectors and button names. - `tests/journeys/test_render_gate.py::test_page_fixture_renders[data-explorer]` fails only on "closed surfaces: g opened no go-to". The gate, the phone resize, scroll and typed-box journeys pass. The same failure appears with this branch's base (22accdd) version of `data-explorer.html`, and on `heat-loss`, which this branch doesn't touch, so this branch doesn't cause it. - `uv run pre-commit run --files examples/data-explorer.html tests/journeys/test_render_widgets.py` ## Not verified - WebKit and a real phone. Chromium and Firefox ran under emulation. - A voice-control tool: the name fix was checked in the accessibility tree. - The whole corpus aim sweep (`test_the_layer_holds_its_whole_page_rules_on_the_corpus`, `--run-main`). Its reader ran on this page alone at three widths. - The other 15 refreshed stills by eye: I read their pixel differences and looked at the four largest. ## Calls Max may reverse - `table-layout: auto` on a phone, which takes the column movement above, up to 20px, in exchange for whole words below 355px. The alternative keeps equal columns, which hold still and split words below about 355px. - The asset pin moves in this PR although its stills are unrelated to the change. Dropping that commit leaves the stills as they were on 31 October. - `code-comparison`'s "Comparison viewport" slider changes nothing visible at a phone for most of its range, because the stage is 314px: 400 and 520 both draw 314px candidates, and only 280 and 300 differ. Hiding it on a phone would hide a value the instruction still submits, so I left it and noted it as a follow-up. Closes #4023 > _This was written by Claude Code on behalf of max-sixty_ --------- Co-authored-by: Claude Opus 5.5 <[email protected]>
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 UI hill-climb exposed failures in otherwise valid page compositions: contributor-only playgrounds could not initialize, metric and facts styles reached unrelated authored content, exported workspaces lost navigation geometry, and inspecting another file could reopen a retained reply's old file or lose its saved draft. Repair those shared boundaries and make the evaluation report show the evidence behind each retained change.
The runtime changes keep passive reply continuation from revealing hidden content, let text-input events cross enclosing shadow roots, and register reading regions through document layout so exports receive them too. Metric and facts layouts now apply to their definition-list structures, with metric subgrid alignment restricted to its two-row shape. Playground values can come entirely from registered contributors. Three examples put the working controls and actual selectable previews together; their catalog captures are refreshed.
The standard report adds an authored implementation assessment, material changes for personal review with collapsed inline patches and experiment links, and a preference view derived from native pair judgments. Checkpoints and unscored repair observations remain distinct from measured preferences. Evaluation setup reuses its running Python interpreter; incomplete authors remain unscored, and the patch-review criterion judges navigation outcomes without prescribing keys or a test script.
Validation on the merged main integration:
pnpm run checkpassed (696 runtime tests, 85 Worker tests, and browser build/type/lock checks); five focused browser regressions passed; both standard-report CLI/page-check smokes, focused evaluation configuration/assertion checks, and lint passed. Astra independently reviewed the retained UI changes, live/exported report, and merged runtime integration. Earlier same-source before/after probes cover the individual repair mechanisms. The campaign contains seven Leaf–HTML pairs, not a repeated final-runtime cohort: these repairs establish specific behavior improvements, not a broad measured preference gain.