Repository navigation
Use icon actions for conversation controls - #347
Merged
Merged
Conversation
leaf-agent
reviewed
Sep 6, 2026
leaf-agent
left a comment
Collaborator
There was a problem hiding this comment.
Two things, both small against the size of the change. The cross-surface icon vocabulary, the metadata-row Resolve, and the reworked geometry assertions all read well, and dropping reservations_taken along with the widest-word reservation is a real subtraction.
The first comment is the one I'd act on: removing the x command left one press behind in a test where x was the assertion, so that test's duplicate-press guard no longer holds anything up.
# Conflicts: # tests/test_render_navigation.py
leaf-agent
approved these changes
Sep 6, 2026
# Conflicts: # skills/leaf/assets/runtime/icons.js
leaf-agent
approved these changes
Sep 6, 2026
max-sixty
added a commit
that referenced
this pull request
Sep 6, 2026
Three nightly tests have been red on `main` since #341, and nightly runs after `main` moves, so PR CI and `wt merge` both stay green while nobody sees them. All three are the same seam: the live interaction gallery injects its playback row from the runtime and leaves the authored page owning it. **The ring census.** The page drew `outline: var(--here-ring)` on the injected presses without naming the ring, so the floor below divided by a population short of it. It was drawing the ring twice over: `offer` marks those buttons `data-lf-offer="button"`, so the theme's pressable floor already carries the hand, the hover tint, the disabled treatment, and a ring that names itself. The page's copies are gone and the floor's answer stands alone. No other authored page in the corpus draws the layer's ring. **The control-row sweep.** The row is a control row nothing had declared. Declaring it means proving it holds still, and it did not: the toggle rewrites its own word as a demo runs — Loading…, Play, Pause, Played — so pressing Replay moved the button beside it, and the live status line changed length on the same line as both presses. The toggle now reserves the width of every word it can say, through `reserve`, the layer's own helper, called where the runtime builds the row — `scripts/corpus.py` copies each source's `<main>` and none of its `<head>`, so a rule in the gallery's head would not reach the generated corpus, which is the page this sweep actually walks. The status line stands under the two presses at every width rather than only on a phone; reserving its width instead would hold the row open at the width of its longest sentence. `interaction-playback` is the new archetype; an archetype may now name an `example`, because a demo is a scenario the module names rather than markup the synthetic stability page can compose, so its proof runs on the gallery itself. Replay is the press for the same reason the diff's review press is: the button that has to hold still is the toggle, and pressing Replay is what sends it through every word it has. **The injected-surfaces walk.** The gallery's own counts had moved on: #341 added a live undecided suggestion and a second stored version, and merging `main` brought the playground package's ask, so the walk now sees thirteen asks and three version rows. `tests/test_site.py` asserted the status line's `margin-left: 0` at 390px, which the layout change makes vacuous; it now reads the invariant that replaced it. ## Checks `uv run pre-commit run --all-files` is clean, and `uv run pytest tests --run-nightly` passed whole — 2096 tests — on this branch before `main` moved under it. On the merged tree that full run reports 11 failures. A paired control, a detached checkout of `ca4ac82d` with none of this branch on it, fails 10 of the same tests, so they arrived with the eight PRs that landed while the first run was going. The eleventh, `test_a_failed_preview_bootstrap_hears_the_replacement_server[theme.css]`, passes on its own here and on the control: a flake in a 27-minute run. The three tests this PR is about pass. Nightly is red on `main` for two reasons this PR does not reach, both worth someone's attention: - the playground package's Reset, Copy instruction and Apply card share rows and match no archetype, so `test_the_composed_corpus_declares_every_control_row_archetype` fails on `main` for that reason now instead; - `.lf-resolve.lf-icon-action` (#347) has the left edge of its focus ring under `.lf-react-trigger` (#349) in the ship-review thread, two independent PRs whose rows now overlap by two pixels, which `test_every_ring_the_layer_draws_is_shown_whole_somewhere_in_the_corpus` reports as 2 faults over 714 stops. Plus pre-existing reds in `test_render_anchors`, `test_render_export`, `test_render_projection` and `test_render_widgets`, all present on the control. **#340 is the standing fix for the shape of this: nightly modules a PR touches never run before it lands. ## Overlapping PRs **#353 repairs the same three readings, and opened while this branch's first suite was running. It took the `reserve` route from the start, which is where this one has now arrived; it also rehomes the scenarios' `#bg-motion-*` lookups onto the stage, which this does not. One of the two should close, and which is Max's call. ## Note for #351 **#351 deletes this same block of gallery CSS and rehomes none of it, which would leave the injected buttons without their pill shape or their `--aim-floor` aim target. Whichever lands first, the other conflicts here. > _This was written by Claude Code on behalf of max-sixty_ 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_01Q7ZBoNLYxFVhWgDsXH1RTx --------- Co-authored-by: Claude Opus 5 (1M context) <[email protected]>
This was referenced Sep 7, 2026
Merged
max-sixty
pushed a commit
that referenced
this pull request
Sep 7, 2026
…walk to the pill ring (#367) ## Problem The nightly leg of [`ci` on `59d0aa3`](https://github.com/max-sixty/leaf/actions/runs/34060060243) went red on three readings. Two were the interaction gallery and landed with #359; the third, `test_every_ring_the_layer_draws_is_shown_whole_somewhere_in_the_corpus`, still reproduces on `ac3342a4` and is a different seam — #366 names it as outstanding and does not reach it. The census reports the resolve icon action's focus ring clipped in `ship-review`, in the page and in the comments: ``` in the page of ship-review, the ring on button.lf-btn.lf-resolve.lf-icon-action.lf-ui "" is not all there: its left edge is under button.lf-react-trigger.lf-ui "" (ring 1143,466,1179,502 vs 1119,467,1145,493, sampled 1144,484) ``` The reaction trigger is painted above the message head and turns opaque exactly while the message is focus-within — which is when the resolve control beside it is wearing a ring. It stood off that control's own box by 2px, and the ring is 4px wide of it, so two of those pixels were behind the trigger. Two independent PRs put the rows there: the icon action (#347) and the trigger's offset (#349), each correct about the box it measured. ## Solution Both copies of the rule — the chrome sheet's, and the frozen-conversation mirror in `theme.css` — now stand the trigger off the ring rather than off the box, naming the band as `--here-ring-w` plus the offset each sheet's own focus rule states, and keeping the 2px gap that was already there measured outwards from the ring. Clearing that fault makes the census reach its last assertion for the first time, and it reports the `pill` ring painted nowhere the corpus can be walked to. That one is pre-existing and was masked behind the clip: the strip's trigger wore `lf-pill lf-react-trigger` until #349 made it an icon, so the palette chips behind the press are now the only focusable boxes left drawing that ring — and no walk opens a palette. A `a reaction palette` walk scope presses a message's trigger and stands on the chips. ## Testing - `tests/test_render_controls.py` in full on this branch: 81 passed. - The everyday suite (898 passed, 6 skipped) and `pre-commit run --all-files` pass. - Bug-back for each half, on this branch's own tree: reverting the two CSS rules returns the 2 clipping faults over 714 stops; reverting the walk scope alone returns `1 of the layer's 45 rings are painted nowhere the corpus can be walked to: pill`. <details><summary>Scope, and what this deliberately leaves to other PRs</summary> The same run's other two readings are #359's and merged. `test_the_composed_corpus_declares_every_control_row_archetype` is red on `main` for the playground package's Reset / Copy instruction / Apply card row; #366 declares that archetype, so it is left out of this branch — an earlier revision of this one carried a second implementation of it and it was dropped once #366 appeared. #365 touches `reactions.js` and `chrome.css` but neither the trigger's offset rule nor the `lf-pill` class on a chip, so the walk scope added here keeps its subject if that lands first. </details> --- Automated fix for [failed run](https://github.com/max-sixty/leaf/actions/runs/34060060243) Co-authored-by: leaf-agent <[email protected]>
max-sixty
pushed a commit
that referenced
this pull request
Sep 7, 2026
…tion and composer readings as the icon actions now draw them (#369) ## Problem The nightly leg of [`ci` on `ac3342a4`](https://github.com/max-sixty/leaf/actions/runs/34069973701) went red on ten readings. Four are already held by open branches — `test_every_ring_the_layer_draws_is_shown_whole_somewhere_in_the_corpus` by #367, and `test_the_composed_corpus_declares_every_control_row_archetype` plus `test_the_render_gate_applies_every_standing_action_a_second_time` by #366 — and this branch leaves them there. The other six all reproduce deterministically on `4cbef417`, and one of them is the product's. **A recovered draft loses the control that would send it.** `test_an_empty_draft_survives_reload_and_blocks_a_version_switch` timed out waiting for Save. `lf-draft` reserves the width of its engaged Save + Cancel pair through `measure`, whose take runs whenever the row is first drawn — which since #362 is at presentation rather than at connection. A draft holding an unsent edit opens its editor in `connectedCallback`, before that. The take then ran `replaceChildren(this.#pencil)` over an editor that was already open, so the reader was left with their words in a live textarea, the resting ✎ beside it, and no Save at all. **Five readings written against shapes #347 replaced.** Its icon actions moved Send inside its field, gave Resolve the accessible name `Resolve thread`, withdrew the page-level `x` resolution, and gave a spent submit a face of its own: - `test_command_hub_send_and_pause_is_one_thread_fold` — `get_by_role("button", name="Resolve", exact=True)` no longer matches. - `test_a_diff_surface_keeps_the_complete_thread_lifecycle_inline[light,dark]` — pressed `x` for the inline resolution and no event was sent. - three `test_render_drafts.py` readings — the response bar is 28px wider now that its submit sits inside the field, so its left edge crossed `#p2`'s centre and Playwright's centre-aimed triple-click landed on the textarea instead of on the passage. It had been clearing that centre by 9px. - `test_a_control_a_widget_built_is_told_from_a_label_it_wrote` — the option group's Add is now `.lf-compose-submit`, whose disabled rule deliberately keeps `opacity: 1` and swaps the accent disc for a muted ring on paper, so a field with nothing in it reads quiet rather than broken. The same design is asserted from the other side in the diff-surface test above (`assert quiet["opacity"] == "1"`), so the two readings had come to contradict each other. ## Solution `lf-draft` gains one `#paintRow`, which states the whole row from `this.#ta` — the editor itself — and is what the reserve take, `#open`, and `#close` all call. Read that way the take cannot arrive with a stale idea of which mode the widget is in. The five readings are restated at the surfaces the layer now draws. Resolve is named exactly; the inline resolution goes through the control's own keyboard route, which is what #347 left it. Passage selection moves to a `select_words` helper that aims at the passage's first line rather than at its box, since a short paragraph in a wide column is mostly empty at the centre and that empty half is where a float placed to keep *its own* target clear will stand. The spent-face reading is taken as a change against each control's own live face — lifting the disabled fact off it and putting it straight back — for the same reason the wash and the ring in that test are already read as changes rather than as constants: a control is free to dress its own state and outrank the floor. ## Testing - The four touched nightly modules in full (`test_render_drafts.py`, `test_render_widgets.py`, `test_render_anchors.py`, `test_render_projection.py`): 362 passed, 1 failed — the remaining failure is #366's `lf-playground` verb, unchanged on this branch. - The everyday suite: 898 passed, 6 skipped. `pre-commit` on the changed files passes. - Bug-back on the spent-face reading: flattening `.lf-compose-submit`'s disabled rule to bare `opacity: 1` returns the failure, with the live and spent faces printed identical. - The draft repair's own bug-back is the run above: the reading it fixes is the one that timed out on `ac3342a4`, and it passes here. <details><summary>How the composer came to cover the passage below it</summary> Measured on `NOTED_PAGE` at 1200×900, after selecting `#p1` and typing into the bar. `#p2` spans `211…931`, so its centre is `x=571`. | | `.lf-fab-input` left | `elementFromPoint(571, 217)` | | --- | --- | --- | | `b03501fa`, before #347 | 580 | `P` | | `4cbef417` | 552 | `TEXTAREA.lf-fab-input` | `placeClear` bounds its bands by the viewport, the target, and controls carrying `data-lf-offer` — not by other passages — and it prefers the band nearest the target, which on this page is the one directly below `#p1`. So standing over `#p2` is placement working as stated; what changed is only how far left the bar reaches. That is left alone here. </details> --- Automated fix for [failed run](https://github.com/max-sixty/leaf/actions/runs/34069973701) --------- Co-authored-by: leaf-agent <[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.
Replaces text-heavy composer actions with a shared icon vocabulary across page comments, thread replies, inline conversations, and custom options. Send and Add now live inside their text fields, while popup and panel Close controls use a borderless ×.
Resolve remains visually distinct from closing the surface: it is a compact outlined check aligned with the thread's first author/time row, carries the explicit accessible label and tooltip “Resolve thread,” and preserves its pending, folding, focus, and reopen behavior. When that reply also exposes its reaction affordance, the reaction control sits one hit target to Resolve's left instead of covering it. The old
xresolution shortcut is removed soxmeans close; Resolve remains keyboard-accessible through the button's normal Enter/Space activation.The browser coverage now holds cross-surface icon consistency, narrow and dark layouts, composer growth, keyboard reachability, pending settlement, and resolution folding. A context-blind live usability pass found the intended thread and resolved it without a wrong click.
Checks: pre-commit; exact-head CI test, lint, and website-worker jobs; 5 affected nightly navigation tests; focused conversation, margin, and reaction interaction tests; live UI sweep at 320px and 1440px in light and dark modes.