Skip to content

Let the panel compose what it says in passing from facts walks and notices declare - #6442

Merged
max-sixty merged 22 commits into
mainfrom
passing-seat
Nov 19, 2026
Merged

max-sixty merged 22 commits into
mainfrom
passing-seat

Conversation

@max-sixty

@max-sixty max-sixty commented Nov 18, 2026 •

Copy link
Copy Markdown
Owner

Walk owners and notice producers now declare facts, and the panel composes what it says from them, saying only what the screen and its own words don't; a listener hears the whole position either way. This is #6427's follow-up: Max asked to put "what does this tell the reader that the screen doesn't?" to everything the panel says in passing, to let the panel compose it rather than each call site guessing what is visible, and for a way to survey, review and iterate. leaf-dev words (#6439, landed) is that survey; three fresh reviewers worked from its captures.

The panel's field on main and on this branch after four presses

How it composes. beginWalk(key, noun, read, {list, about}). list is the walk's first and last stops: Leaf declines a step while both stand whole in view, so the ring alone answers it and the walk the user came by stands (a two-tab strip, a question's options, a diff whose hunks all show). about names the fact where the user stands that the list belongs to ("comparison" for its changes). Each surface passes the facts its own words say: the page field's standing words say a comparison and hidden annotations, so there a change's place reads "5 changes since v2 · 1 of 5" and a notice that only repeats them stays out of the field; the folded leaf's peek and a thread's field say none, so they show the notice and the whole position ("Change 1 of 2 since v1" beside a thread's reply, which read a bare "1 of 5"). Such a notice holds the seat like any other, so on the page field it is unseen for its moment and news waits behind it. Notices take stands, the condition their words state, and retire, shown or queued, when it lapses ("N changes since v2 — v shows them" once a comparison stands).

Settled with Max: a list on screen names what it counts ("Tab 14 of 14", "Command 1 of 97", where #6427 had "14 of 14"), since a fresh reviewer found the bare count ambiguous beside a tab strip whose rows read "1 of 31 pages real". Hiding annotations by key keeps "— o shows them" in the field, since the standing words don't name the key.

Also from the survey: Go-to armed with no hint in view says "No visible targets"; counts agree with nouns ("1 visible target"), and the filters say "threads" and "margin entries"; page search reads a match inside a word back as the word ("rather", not "ra the r") and Enter says the match's place; . announces folding; a diff's steps are heard as "Hunk 2 of 3: src/summary.rs".

Weaknesses: a dot or line chart bounds its walk by its whole drawing, which counts as shown when taller than the window; a partly visible option list's walk replaces On Me's, so On Me's view loses its ring on that item; Go-to with hint chips still says nothing in the field (as on main).

Tests: new browser tests for the thread-field change walk, notices following their premise, the toggle's notice in the field and the folded peek, and a match inside a word; the touched browser and journey tests, pnpm run check and the runtime tests pass.

This was written by Claude Code on behalf of max-sixty

After `t` or `m`, the panel's empty field said the walk's position
("Thread 4 of 7") for as long as the user stayed at the stop it reached,
so the agent's status line, and every update to it, stayed hidden while
the user read there. Max asked for the position to show for a few
seconds and the status to come back, and for the rule behind when the
field says the user's own state ("page status") instead of the agent's.

The rule, now in the floating panel's header: the agent's status is the
field's own words. Something of the user's replaces it only while it
answers or directs what the user is doing: an error until their first
edit, selected words, held keys, the Go-to filter while it waits for a
key, and a notice or a walk's position for a notice's moment. Where the
user stands by a choice that lasts (a mode, an older version, a
comparison, hidden annotations) leads the status instead.

Behavior that changed:
- A walk's step holds the panel's seat for NOTICE_MS (4 s) from the
  latest step (`answerStep`, replacing `holdStatus(900)`), then the
  status returns while the walk itself stays where it landed (On Me's
  ring, the thread view's lead). News arriving meanwhile now waits for
  that moment, as it waits for a notice, rather than 900 ms.
- A thread open in the panel keeps the position before its reply, since
  the field there says no status.
- A mode (Draw, Design, the picker) now leads the status, "In Draw mode
  · <status>", with Close at the field's end, instead of replacing it;
  the `stance` reading of `data-lf-says` is gone. This extends Max's
  request to the general rule and is the call he may reverse.

Tests: a fake-clock browser test that the status returns after the
moment and a step renews it (fails on main); the Draw-mode tests read
the status after the mode's name; the semantic-selection journey no
longer depends on the match position outliving its moment.

> _This was written by Claude Code on behalf of max-sixty_
…e field's rule and the guide

> _This was written by Claude Code on behalf of max-sixty_
# Conflicts:
#	browser/runtime/floating-panel.js
After #6403 dropped "Options" from the On Me walk's position, Max asked
for the same question to be put to everything the panel shows in
passing: what does it tell the reader that the screen doesn't?

A walk's position now names its list only when the walk carries the
user across the page and the panel doesn't already name it ("Thread 2
of 5", "Match 3 of 9", "2 of 5 waiting on me"). Behavior that changed:

- A walk inside a list on screen whose end may be out of view says only
  its place: tabs, the Page Map, the command reference and visual
  review's cases read "2 of 14" rather than "Tab 2 of 14", "Entry …",
  "Command …", "Case …". `rowWalk` declares its position with no noun;
  its `noun` still names the step routes.
- The change walk reads "5 changes since v2 · 1 of 5" rather than
  "5 changes since v2 · Change 1 of 5 since v2", since the field
  already names the comparison. A listener still hears "Change 1 of 5
  since v2".
- A walk over a list always wholly in view declares no walk: a
  question's options, the reaction bar, the response options, a margin
  cluster's entries, the visible margin markers, Go-to and
  target-picker hints, and a chart's points. The ring shows the place,
  so the field keeps the agent's status, or the walk the user came by:
  On Me's "1 of 4 waiting on me" now stands while they arrow through
  that item's options. `rowWalk` takes `position: null` for such a
  list; a reader returning null still ends the walk standing, as the
  panel's own rows do. A chart still tells a listener "Point 3 of 8",
  through `walkPositionLabel`, which the portable API now exports.
- The Go-to filter's count ("3 visible hyperlinks; type a hint or press
  Tab to hear them.") is announced only, as arming Go-to already is;
  the narrowed hints show it. With none, the field's "No visible
  hyperlinks" loses its full stop, as the seat's other words have none.

Kept as notices: the comparison's and the annotation toggle's. Making
either announce-only left an earlier notice standing over its opposite
("Annotations hidden — o shows them" after showing them, "No changes
marked" over a fresh comparison), since a notice isn't tied to the
condition its words state.

The rule is stated at `beginWalk` (walk-declaration.js), and
module-input.md says what `rowWalk` and `beginWalk` show with a null
noun. One gap: with a thread open in the panel, whose field shows no
standing words, the change walk's lead reads a bare "1 of 5".
…each press

The panel's seat for passing words answers presses: a notice, a walk's position,
the Go-to word, where the user stands. Judging those words one call site at a time
missed how they read beside each other and beside the screen, so this presses every
page command a key reaches at rest, the journeys whose later presses depend on the
first, and the first stop of each widget kind, and tabulates what the seat says, what
it says once a notice's moment has passed and what the live region heard, base
beside head. PANEL_SAYS, the seat's reader, moves to leaf_dev.browser so the tests
and the survey read the seat the same way.
…their owners declare

A walk's owner used to choose what Leaf's panel showed of its position: a null noun
for a list on screen, `position: null` for one wholly in view, and its own label for
a listener. No owner could know what the panel's own words already named, so with a
thread open in the panel the change walk read a bare "1 of 5", and a two-tab strip
said "1 of 2" while both tabs stood in view.

Owners now declare facts and Leaf composes the words. `beginWalk(key, noun, read,
{list, named})` takes what one stop is, the elements a list on screen stands in, and
whether the page field's standing words name the list. Leaf declines a step whose
list stands whole in view, so the ring alone answers it and the walk the user came by
stands; says the place alone where the list is on screen or the field names it; and
the whole position elsewhere. `beginWalk` returns the whole position for the owner's
announcement. Behavior that changed:

- With a thread open in the panel, the change walk's lead names the comparison,
  "Change 1 of 2 since v1"; the page field still says "2 changes since v1 · 1 of 2".
- A list's step says nothing where all of the list is in view, measured at the step:
  a two-tab strip, a visual review's queue, a chart's points; a long tab strip or the
  command reference still says "2 of 14".
- Packages lose `walkPositionLabel` and `rowWalk`'s `position: null`; module-input.md
  says what `list` does.

A notice now stands no longer than its words hold (`notice(…, {stands})`), shown or
waiting: "N changes since v2 — v shows them" goes once a comparison stands, and "No
changes marked" once one marks some. With that, `v` and `o` no longer show a notice
that only repeats the field's standing words ("5 changes since v2", "Annotations
hidden"); a listener still hears them, and their opposites, as before.

Listener words the survey (`leaf-dev words`) found wrong: Go-to's counts agree with
their nouns ("1 visible target", "2 visible threads", where the threads filter said
"Thread controls"), and Enter on a page search's match says its place and context
as `n` does ("Match 3 of 9, selected: …").
The survey heard page search say "…issues ra the r than blockers" for "the" in
"rather": the match's description put a space on each side of the match whatever
stood there. A match whose neighbouring letters run on in its own text node now joins
them, so a listener hears "rather"; one at a node's edge keeps its space.
The survey pressed ArrowDown, ArrowRight and End at each widget's first stop, which
missed walks on other keys, such as a diff's ] and [ between hunks. It now presses
each key of the walks the register offers from that stop and nowhere else, and
reaches further down a page.
…lists by their stops

Review of the last round found the panel's surfaces disagreeing about where the user
stands. The page field says the comparison and hidden annotations in its standing
words, but the folded leaf's peek and a thread's field say none of them, so making
`v` and `o` announce-only left the folded peek blank, and the change walk's `named`
flag had its owner assert what the page field's words said.

A notice or walk now names the fact where the user stands that it concerns (`about`):
"comparison" for a comparison's start, end and changes, "annotations" for the `o`
toggle. Each surface passes the facts its own words say: the page field leaves an
`about` notice to its standing words and says a change's place alone, while the peek
and a thread's field, which say none, show the notice and the whole position. So
folded, `o` shows "Annotations hidden — o shows them" again; unfolded, the field says
"Annotations hidden" at once with no notice repeating it.

A walk's `list` is its first and last stops, never one holding element: a scrolling
case list measured as its own box declined steps whose cases ran out of view. The
visual review's queue rows, the chart's first and last point shapes and a diff's hunk
and file heads now bound their walks, and the visual review announces the case's
place, which focus moving to the case doesn't say.

Also: a notice's premise and its press's both hold it up; a notice whose premise has
already lapsed isn't shown; the since-seen count's arrival is a signal, so a newer
arrival retires the older news; page search's announcement falls back to the active
match's place where the walk can't place it.
# Conflicts:
#	browser/runtime/annotation-overlay/margin-projection.js
#	browser/runtime/change-walk.js
#	browser/runtime/floating-panel.js
#	browser/runtime/keyboard/command-reference.js
#	browser/runtime/keyboard/go-to-sequence.js
#	browser/runtime/notifications.js
#	browser/runtime/walk-declaration.js
#	browser/runtime/walk-position.js
#	packages/default/widgets/lf-chart.js
#	packages/default/widgets/lf-tabs.js
#	packages/visual-review/widgets/lf-visual-review.js
#	skills/leaf/references/module-input.md
#	tests/browser/navigation/test_go_to.py
#	tests/browser/projection/test_visual_review.py
Merging main after #6427 landed as a squash restored lines this branch had since
removed: lf-options' `position: null` and the portable export of
`walkPositionLabel`.
…survey

A fresh reviewer read the survey's captures and found a bare "14 of 14" beside a tab
strip whose rows read "1 of 31 pages real": the panel stands apart from the list it
counts, so a position names its list wherever the panel says one ("Tab 14 of 14",
"Command 1 of 97"), and says its place alone only where the surface's own words name
the list, as "5 changes since v2 · 1 of 5" does. A list wholly in view still says
nothing.

From the same review and a second code review:

- Go-to armed with no hint chips on screen says "No visible targets" while it waits,
  as an empty filter already said "No visible hyperlinks"; the next key otherwise
  went to Go-to with nothing saying so.
- On Me's region walk says "waiting on me here" only where the region holds part of
  On Me.
- A listener hears `.` fold and unfold the panel, a diff's steps in the walks' shape
  ("Hunk 2 of 3: src/summary.rs"), and page search's match words without "…." where
  the context ends in an ellipsis.
- A notice the page field leaves to its standing words holds no seat against news,
  and doesn't displace news already showing.
- The standing parts are one table, which both the field's words and the set of
  facts they say read.

Tests: the diff walk assertions read what a listener hears, since a diff whose hunks
all stand in view now shows no position; the command reference's reads "Command 1 of N".

@leaf-agent leaf-agent left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Holding the verdict because of the two calls the description leaves "For Max to weigh": the named counts ("Tab 14 of 14", "Command 1 of 97") and dropping "— o shows them" when unfolded. Approving would let this merge before those are settled. The branch also carries #6439's leaf-dev words, which is still open on its own.

One finding, inline. notifications.js decides once, for every surface, that a notice carrying about holds no seat. The panel's surfaces don't all agree with that. Only the unfolded page field leaves such a notice to its standing words. The folded leaf's peek (peekPresentation, which reads passing() with no says) is the surface where the notice is meant to show.

Comment thread browser/runtime/notifications.js Resolved
…n entries

A last fresh look at the survey's differing rows found one regression: hiding
annotations by key had stopped showing "— o shows them" in the field, leaving a
sighted user who hid them by accident a standing "Annotations hidden" that names no
way back. A notice now leaves the field to its standing words only where its words
say nothing more than they do: hiding by key names the key, so it shows in the field
for its moment again; "Annotations shown" and a comparison's start and end still
show only where no standing words say them, as on the folded leaf.

Also from that look: Go-to's margin filter says "margin entries", the glossary's
term and its own id, as "threads" beside it already does; and Enter on a page
search's match is heard in the shape `n` gives, "Match 3 of 9: …. Selected.".
max-sixty added a commit that referenced this pull request Nov 19, 2026
…each press (#6439)

`uv run leaf-dev words [--page NAME]... [--base [REF]]` surveys what
Leaf's panel says in passing. On a set of example pages it presses every
page command a key reaches at rest (twice), the journeys whose later
presses depend on the first (a search's next match, a comparison's
changes, On Me then its options), each key `g` leads to, and each walk a
widget declares at its first stop. After each press it records the
seat's words, what they say once a notice's moment has passed, what the
live region heard, and a capture of the window, then writes a table per
page with the base's words struck through where they differ.

Max asked for a way to survey what the panel produces, review it and
iterate. A run over the eight default pages takes about four minutes per
page and arm. Its first runs found defects #6442 fixes: Go-to counts
such as "1 visible targets", page search reading "ra the r than" for a
match inside "rather", and notices that repeated the field's own words.

`PANEL_SAYS`, the seat's reader, moves from `tests/render_harness.py` to
`leaf_dev.browser` so tests and survey read the seat alike; the
developing-leaf skill points panel-word changes at the survey. Ran end
to end on all eight pages against main; ruff passes.

> _This was written by Claude Code on behalf of max-sixty_
The notice queue dropped a press's notice that carried `about` while news showed,
and let news take the seat from one that did show. Only the page field leaves such
a notice to its standing words; the folded leaf's peek shows it, so there the user's
own `v` or `o` went unsaid behind the news, or was replaced by it at once. The
queue can't tell which surface draws the seat, so it no longer decides: the notice
holds the seat as any other does, unseen on the page field for its moment, and
`passing(says)` alone hides it there (review on #6442).

The tests that read the field while a notice's moment still stands read it once the
press has drawn, rather than under a one-second deadline the suite's source check
refuses. With both the replacement and the premise watch disabled, the comparison
test fails as it should.
@max-sixty
max-sixty merged commit 823e8d7 into main Nov 19, 2026
7 checks passed
@max-sixty
max-sixty deleted the passing-seat branch November 19, 2026 00:45
max-sixty added a commit that referenced this pull request Nov 19, 2026
…o FIELD_READINGS

#6442 has each surface of the panel hear what passes through what its own words
already say of where the user stands (`says`): on the page field a notice about
one of those facts is left to them, and a walk over a list one of them is about
says its place alone ("5 changes since v2 · 1 of 5"). The panel now gathers that
per surface (`passingFacts`), so the field's facts, the folded leaf's peek and
FIELD_READINGS keep one order and one rule.

Behavior change against this branch's earlier head: the Go-to word and a walk's
position lead with all of where the user stands again, as on main, while a notice
keeps the stance alone (`lead` on the "notice" reading). #6442's place-alone
wording counts on it, and with it #6444 changes no words. Leading every passing
word with the stance alone, as this branch had it, is still open with Max.
The guide's Go-to example reads "No visible threads", as #6442 words it.
max-sixty added a commit that referenced this pull request Nov 19, 2026
…ffers Close (#6448)

While `g` waits for a key, the panel's field now says so: the Go-to map
is a stance, as Draw mode and page search are, so the field reads "In
Go-to · Away · Close esc", and Close takes the map off from any step.
Before, the field went on saying the agent's status with the hints
painted, so nothing where the user reads said the next key went to Go-to
or how to leave. Max asked for this after #6442's survey found it.

<img
src="https://gist.githubusercontent.com/max-sixty/17c067fe5d4b7930043a18803c0295c8/raw/b944dee7ec6c65001fd80a22dbc4ebde99cc497e/go-to-stance.png"
alt="The panel's row on main and on this branch, after g and after g h"
width="710">

Escape keeps its order (a letter, then the filter, then close) in two
rows: one backs a letter or the filter, the other is the stance's exit,
live throughout so Close works from a filter too, with `esc` beside it
only while Escape would close. "In Go-to" takes the glossary's noun,
since "In Go to · Away" read as a verb and its object.

**To weigh:** a draft standing in the page field rewraps as the map arms
and closes (494 → 460 px on triage-board), because the stance's ✕ takes
the seat where the field can't say Close. The panel's header accepted
that for modes as a rare path; it now accepts it for Go-to too, on the
grounds that the user's aim is on the page's hints then, not the panel.
An open thread's field still names no stance, Go-to's included, as on
main.

Tests: a new browser test walks the field through arming, a filter that
keeps a chip, Escape, an empty filter and Close; the Go-to journey and
reference tests, `pnpm run check` and the runtime tests pass.

> _This was written by Claude Code on behalf of max-sixty_
max-sixty added a commit that referenced this pull request Nov 19, 2026
The floating panel's empty field says one thing at a time (an error,
keys held while the page loads, where typed words go, selected words, a
passing notice, the agent's status, or Reply in a thread), and its end
offers one press. That rule lived in three places: the branch order of
`fieldReading` in `floating-panel.js`, the editors' own end arbitration
(`SAYS_ELSE`), and about 80 lines of the panel's header, with the
guide's table copying the order by hand. Now `FIELD_READINGS` in the new
`browser/runtime/field-readings.js` declares each reading in order, with
its lifetime, what leads its words and what its end offers. `readField`
walks that list, and the panel only gathers the moment's facts for the
surface asking, including what that surface's own words already say of
where the user stands (#6442's `says`, now `passingFacts`). The folded
leaf's peek and the Errors dot read the same reading instead of
predicting it. A runtime test holds the guide's table
(`docs/using.html`, "What the panel's line says") to the declared order.

The diff doesn't make these behavior changes obvious:

- When two errors are raised before the user writes, the field shows the
newer one. The older one now puts the error dot on the leaf. Before, it
showed nowhere until the user's first edit.
- While the page holds keys pressed before it was ready, an open
thread's reply field offers nothing at its end, as the page field
already did.

What passes on the page field leads as on `main`: a notice with the
stance alone, the Go-to word and a walk's position with all of where the
user stands, which #6442's "5 changes since v2 · 1 of 5" counts on. Max
kept that over leading every passing word with the stance alone.

Max asked for this on a Leaf review page ("let's try to make this much
more cohesive"). Codex reviewed it, and its findings are folded in. The
runtime suite (1061 tests) passes, as do 111 browser tests covering the
panel, notices, Go-to, walks, comparisons and the peek.

> _This was written by Claude Code on behalf of max-sixty_
leaf-agent added a commit that referenced this pull request Nov 19, 2026
…stops saying a notice (#6523)

#6442 made Go-to armed with no hint in view say "No visible targets" in
the panel field (its description lists this under "Also from the
survey"). That word passes through the field's `notice` reading
(`browser/runtime/field-readings.js`, `passingWords`), as a filter's "No
visible threads" already did before #6442. On `NOTED_PAGE` no hint
shows, so after `g` the field reads `No visible targets · Close esc`
with `data-lf-says="notice"`, and
`test_user_news_interrupts_and_then_restores_background_news` failed on
its check of the reading's name.

The test exists to protect that Go-to takes the seat from the restored
background news. It now asserts exactly that: `expect_panel_says(page,
"Agent replied — open Threads", says=False)`. No product behavior
changes; #6442's intent stands.

The test fails on `dd38dcb16` with the reported `Actual value: notice`,
and passes with this change (`uv run pytest
"tests/journeys/navigation/test_key_surfaces.py::test_user_news_interrupts_and_then_restores_background_news"
--run-nightly`).

Closes #6516 — automated triage

Co-authored-by: leaf-agent <[email protected]>
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.

2 participants