Repository navigation
Reach On Me and On <agent> by key: o opens the On view, ← → turn its tabs, g A opens the agent's list - #6762
Merged
Merged
Conversation
…n view's tabs, g A opens the agent's list The On view's lists were hard to reach from the keyboard: On Me sat behind `g M`, On <agent> had no key, and turning tabs took seven Tabs. Over seven weeks of this machine's pages, `m` ran 1,851 times while `g M` ran 3 and the On view's tabs took about 90 pointer presses. - `o` presses the leaf (a page command whose control is the leaf), so it opens the On view on the tab the leaf points at and closes it; the leaf's preview and aria-keyshortcuts name it. A key landing on the menu stands on its first row rather than its search, so the arrows go on from there. - ← and → turn the On view's tabs (Menu, On Me, On <agent>, Threads), round from either end, from a row, the view or the tab strip. - `g A` opens On <agent> as `g M` opens On Me; turning from one list to the other by its door now lands on the new list's first row. - Hide annotations moves from `o` to `a`, with every doc, test and comment naming it.
… key puts the view away, and name each list's door on its tab Review of the keys for On Me and On <agent> found: - ← and → on the tab strip stepped from the tab shown rather than the one Tab had moved focus to, so → from a focused Menu skipped On Me. They now step from the focused tab, through `cycledRow`, over the one tab inventory `onTabs` and `turnTab` share. - `o` or a Go-to door closing the view from inside it left focus on nothing. It now lands where Escape does (`letGo`), so Tab goes on from the page. - `g A` was findable only through `?`. A tab the view doesn't show now previews the door that opens its list (`g M`, `g A`, `g T`). - `o` on a folded panel only unfolded it. A key's press on the leaf now unfolds and opens the view, as the doors do; a pointer's press still only unfolds. - Every remaining mention of `o` hiding annotations, in examples, stylesheet comments and test names, now says `a`.
…ly where its keys work A second review found: - `o` on a folded panel unfolded it for good, where Go-to's doors open the view over the fold and the panel folds back as the view goes. A key's press on the folded leaf now opens the view as a door does; a pointer's press still unfolds. - A tab's preview named its door's keys even where they would type into a field, such as the menu's search. It now reads `commandKeysNow`, as Open latest does, so a tab names `g A` only where `g A` would open the list.
leaf-agent
reviewed
Nov 22, 2026
leaf-agent
left a comment
Collaborator
There was a problem hiding this comment.
Four tests in tests/browser/test_render_floating_panel.py fail at this head and pass on current main (run locally, 4/4 both ways):
test_the_leaf_travels_with_its_fold_and_reverses_from_where_it_stands[light|dark]andtest_the_leaf_paints_inside_its_focus_ring_after_foldingfocus the folded leaf and press Enter, expecting it to unfold with focus kept on the leaf. With thepressLed()gate inpressLeaf, Enter on the leaf now opens the On view instead.test_only_the_folded_leaf_shows_a_status_peekexpects the leaf's preview to readPage menu; it now readsPage menuo, since the leaf names its new key.
The second is a test update. The first three are a behavior question the description doesn't cover; see the inline comment.
…it was Tend's review of #6762 found: - `a` is a visual review's Looks right (`visual.approve`, a decision), which answers first while focus is in the review, so a user who learned `a` as Hide annotations would record a decision there. Hide annotations takes `x`, which no scope binds. - The folded-leaf branch read `pressLed()` to tell `o` from a pointer, which also caught Enter and Space on the focused leaf, so they opened the On view where a click unfolds the panel. `o` presses the leaf, so on a folded panel it now unfolds it as every press of the leaf does, and the three fold tests hold as they were. Go-to's doors still open their view over the fold. - The leaf's preview now names its key, so the peek test reads the preview's word and key apart.
leaf-agent
previously approved these changes
Nov 22, 2026
The toggle ran 8 times in 4 sessions since 1 October, so it spends none of the page's free single letters: x is free again. It joins Go-to's named rows through directDestinations, as Versions does, so the leaf's menu row and a finger keep reaching it and the row names g X. g H was passed over, since g T and g M open the lists t and m walk, which leaves H to the changes h walks. It stays a view, not a mode: the panel's standing words already say "Annotations hidden" while it holds, and a mode's chip would take the field, so the user couldn't comment with the pins down. Go-to doesn't arm over a box that claims Escape, so the draft test hides the layer before it opens the editor rather than from the editor's Save.
leaf-agent
previously approved these changes
Nov 22, 2026
g H no longer stands for the changes h walks; the annotation layer's header records the call. Tests press g then Shift+H where they pressed Shift+X.
leaf-agent
approved these changes
Nov 22, 2026
This was referenced Nov 23, 2026
leaf-agent
added a commit
that referenced
this pull request
Nov 23, 2026
) #6762 added a `panel.floating.tabs` binding (← → turns the panel's tabs, [`floating-panel.js`](https://github.com/max-sixty/leaf/blob/bbfb41535d08deb0815d3a6ad396bc8ffc5ac272/browser/runtime/floating-panel.js#L5526-L5534)). The `?` reference lists it under "In the floating panel", after the four row keys. `test_the_reference_lists_each_of_the_panel_s_keys_once` still expected only the four row keys, so it failed on `main` in [run 45086686733](https://github.com/max-sixty/leaf/actions/runs/45086686733). The new row is what #6762 intended, and the behavior this test protects (each key listed once) still holds. So the fix updates the test's expectation to include the tabs row with its `← →` keys, rather than changing the runtime. The test fails by node id on `main` at `017ddeccf` with the same diff as CI ("Left contains one more item: ('panel.floating.tabs', 'Move through the tabs')"). It passes on this branch. Refs #6805 — automated triage Co-authored-by: leaf-agent <[email protected]>
max-sixty
added a commit
that referenced
this pull request
Nov 23, 2026
A pointer the user moves onto a target reads it after a 200 ms dwell. A `pointerover` the browser sends while the pointer rests cancelled that dwell whatever stood under the pointer afterwards, and nothing armed it again. So where only the node under the pointer changed, inside the target the pointer had just come to, the preview never showed until the pointer left and came back. The dwell now ends only when another target arrives under the resting pointer, or the pointer carries a press. What arrives under a pointer the user hasn't moved still shows nothing. A margin entry meets this in CI. On Linux an entry's centre lies on the edge of its icon's stroke, and the innermost node there flips between the icon's `svg` and its `path` whenever the entry repaints. `test_the_feature_gallery_exercises _its_core_journeys` hovers the Inspect projection entry and failed there in 5 of 13 Linux runs of this branch on 23 November, and in none of 15 runs of main and of #6762. A traced copy of the step in CI's test job showed why: in both failing copies the pointer's arrival on the `svg` armed the dwell and a resting `pointerover` on the `path`, 6 and 9 ms later, cleared it. Where the first node was the `path`, the same flips came after the preview showed. The trace did not show why the `svg` is the first node more often on this branch than on main: the DOM under the entry is the same in both and does not change. `test_a_target_redrawn_under_the_pointer_that_came_to_it_still_previews` holds the behaviour in Chromium and Firefox, and fails in both without the change.
max-sixty
added a commit
that referenced
this pull request
Nov 23, 2026
A pointer the user moves onto a target reads it after a 200 ms dwell. A `pointerover` the browser sends while the pointer rests cancelled that dwell whatever stood under the pointer afterwards, and nothing armed it again. So where only the node under the pointer changed, inside the target the pointer had just come to, the preview never showed until the pointer left and came back. The dwell now ends only when another target arrives under the resting pointer, or the pointer carries a press. What arrives under a pointer the user hasn't moved still shows nothing. A margin entry meets this in CI. On Linux an entry's centre lies on the edge of its icon's stroke, and the innermost node there flips between the icon's `svg` and its `path` whenever the entry repaints. `test_the_feature_gallery_exercises _its_core_journeys` hovers the Inspect projection entry and failed there in 5 of 13 Linux runs of this branch on 23 November, and in none of 15 runs of main and of #6762. A traced copy of the step in CI's test job showed why: in both failing copies the pointer's arrival on the `svg` armed the dwell and a resting `pointerover` on the `path`, 6 and 9 ms later, cleared it. Where the first node was the `path`, the same flips came after the preview showed. The trace did not show why the `svg` is the first node more often on this branch than on main: the DOM under the entry is the same in both and does not change. `test_a_target_redrawn_under_the_pointer_that_came_to_it_still_previews` holds the behaviour in Chromium and Firefox, and fails in both without the change.
max-sixty
added a commit
that referenced
this pull request
Nov 23, 2026
…6710) The served state named where work stands in thirteen enumerations: a delivery stage, a failure condition and its operation, a to-do's state, a plan step's, an obligation's status, a thread's attention, the page's activity kind and seven counts. `waiting` meant the user's turn on the page and the agent's in a thread. Every obligation record, every update's delivery, every to-do, every plan step, each thread and the page now say it in the same fields: `next_actor`, `state` (`waiting`, `running`, `blocked`, `done`), the `reason` a state leaves out, and how a done one ended (`outcome`). This answers the entry "Make tasks and work in progress clear" in `notes/TODO.md`. This is the first of two pull requests, split at Max's request. Here a to-do keeps its own served list and takes the new fields; #5979, on top of this one, makes a to-do an obligation record and deletes that list. ## Where to look - `src/leaf/standing.py` is the contract: the vocabulary, which record speaks for a place, and what a job that outlives a turn is (whatever holds an item's start other than the turn that wrote it). - `src/leaf/activity.py` is the one producer of `running` and `blocked`, for each delivery, each update's record, each to-do and the page. The page reads the agent's side of all of it beside `presence` (here, away, gone, closed). - `src/leaf/served_state/state.schema.json` loses `Stage`, `Attention`, a workflow's `condition` and `at_work`, `Obligation.status`, `Activity.kind` and a plan step's `owner`, and gains `WorkState`, `WorkReason` and `Outcome`. - In the browser, `thread/workflow.js` words every standing and `activity-words.js` the page's. ## A thread the user resolves Two rules, both from a week of Max's own use: on the 13 pages he used that week, 63 threads were resolved over a message the agent had not answered, 50 of them within four seconds of sending. By my reading 39 ask for work or an answer and 24 close the exchange. - The request stays owed (`events.owed_turns`). The user's resolve takes a thread off their list and settles nothing the agent owes in it: the message keeps its record and its place on the agent's list and holds the Stop hook. The agent's own resolve still answers for a thread. This stands beside #6106, under which either side's resolve ends the questions the agent asked there. - The thread stays closed until someone reopens it (`thread.post_reply`, a reply's `unannounced`). What the agent says in a thread the user resolved goes into it without reopening it, the status line announces none of it (`announces` in `thread/model.js`, which `isNews` reads too), and the reply's record says so (`stays-closed`), since the user's resolve reaches the agent only where it retires a question the agent asked. `leaf thread reopen` is the agent's choice to bring the thread back, with the `unresolve` event the user's Reopen writes. `threads.md` gives the goal and no rule: the user closed the thread, so it returns only for news they would want to stop and read, such as that the agent could not do what they asked. A question to the user there reopens it by itself. A Codex turn's final message prints its agent nothing, so the turn's handling has it post such news by command. Max picked both halves: the answer leaves the thread closed, and bringing it back is the agent's call (root `AGENTS.md`, "Leaf's role"). What follows: when this lands, each session still holding a page is asked to answer the old messages its user resolved this way, among them `/gpk` and `/dispatch` commands. A logged user `resolve` takes a new meaning, a `reply` gains a field and an `unresolve` may be the agent's, so the page protocol moves from 53 to 54; the plan-outline work in #6707 also takes 54, so whichever lands second moves to 55. ## What users see differently The research note's scenarios S1–S15, built as real logs with 62 checkpoints, ran on `main` and here; their builders have left the tree since and are at d986f9c. The words on every surface are identical at 40. At 11 the live words change: the 5 where the panel and the thread contradict each other about the same work, an update the agent started whose turn then ended with nothing watching (the panel now asks for a nudge), a dialog open in the agent's own window (the thread says Waiting in the terminal), and the 4 where the user resolved a thread before the agent answered. At 11 only the Done list changes: at 10 a request answered with a promise no longer reads Answered while its to-do is open, and at 1 the request the user resolved is listed as Answered once the agent answers it in the closed thread. A to-do whose start stopped or went quiet keeps the line it last said under Stopped or Gone quiet, and the receipt word Up next is gone. ## A preview fix that rides along A pointer moved onto a control whose face redraws within the preview's 200 ms dwell got no preview until it left and came back: the `pointerover` the browser sends for the new node under the resting pointer cancelled the dwell, whatever had arrived (`preview.js`). The dwell now ends only when another target arrives under the pointer, or the pointer carries a press. This pull request's `test` job met it in the feature gallery's journey, which the change edits. On Linux a margin entry's centre lies on the edge of its icon's stroke, and the innermost node there flips between the icon's `svg` and its `path` as the entry repaints. The journey failed in 5 of 13 Linux runs of this branch and in none of 15 of `main` and #6762. Six traced copies of the step in the Linux job, [on this branch](https://github.com/max-sixty/leaf/actions/runs/45268635289) and [on `main`](https://github.com/max-sixty/leaf/actions/runs/45268643151), showed the dwell armed on the `svg` and cleared 6 and 9 ms later in the two that failed; they did not show why the `svg` comes first more often on this branch. [With the fix](https://github.com/max-sixty/leaf/actions/runs/45273513465) all six show the preview, four of them through a redraw that cancelled it before. `test_a_target_redrawn_under_the_pointer_that_came_to_it_still_previews` holds the fix in Chromium and Firefox and fails in both without it. ## What it costs - The public package API changes: an obligation record has `state`, `reason`, `outcome` and `answered` in place of `status`, and a thread's `attention` is a record or a to-do. `lf-deck`, `lf-tabs` and the feature gallery are updated. - A to-do in `leaf page state` says where it stands in the new fields, and `conversation-loop.md` teaches that reading. - The row record moves to format 54 with the protocol, so a page served by an older Leaf and one served by this do not list each other. - 133 files, +4,989 −2,732, and the code is no smaller. Python and JavaScript outside tests gain 125 lines of code, of which #5979 removes 76, and 92 decision points, 56 of them in `activity.py` and `activity-words.js`, which decide and word the liveness cases above. `canonical_activity` goes from 278 lines and 61 decision points to 298 and 82. Tests are +2,189 −1,212, and the new eval case is 709 lines. What shrinks is the contract: across the stack the schema's enumerations for where work stands go from 12, with 43 values, to 6 with 22. ## Checks - Evals, Claude Code against `main`'s instructions, three samples a case on the 22 cases whose tags cover the changed passages: 55 of 66 pass on the stack's text and 54 of 66 on `main`'s, and no case differs by more than one sample. `resolved-request-stays-owed`, new here, passes 10 of 10. After Max's call that the agent decides when a resolved thread comes back, that case ran again, five samples a variant: given a request it cannot carry out, 5 of 5 agents reopen the thread, both where the delivery shows it resolved and where only the reply's record does, against 0 of 5 under the rule before, where only a question reopened it; an answer that delivers what was asked leaves it closed 5 of 5 in each. On Codex, 5 of 5 turns post such a request by command, against 0 of 5 with the rule only in `harness-codex.md`, and 5 of 5 leave an ordinary answer to the final message. The suite read the stack's final wording; the wording of the to-do reading that only this pull request carries has no score of its own. - The Claude Code agent journey, which the change to `hooks/claude-code.ts` calls for, passes every step. Its `withdrawn` step changed: a resolve that changes nothing the agent owes reaches no hook here, so the step takes the comment back. - `tests/model`, `dev/tests/model`, `tests/smoke`, the runtime's Node tests and `pnpm run check` pass here. [A manual dispatch](https://github.com/max-sixty/leaf/actions/runs/44976806053) of every product test, on Linux and macOS, ran on the unsplit branch as it stood before the closed-thread rule was widened. 25 tests failed, 2 because of this change, and both are fixed: one passes under the rule as it now stands, and the other, the Undo row's age, assumed the user's resolve leaves nothing owed, so its fixture now has the agent answer first. The other 23 fail without this change: in `main`'s nightly run or another branch's full run on 21 November (9), on `main` until #6713 and #6717 (5), on `main` today, run there by name (7), or on macOS only (2). [A second dispatch](https://github.com/max-sixty/leaf/actions/runs/44996782669), of this branch beside [`main`'s own](https://github.com/max-sixty/leaf/actions/runs/44989336653), failed no test on Linux that `main`'s run passed. On macOS it failed six that `main`'s run passed, and none of the six fails in six runs by name on this tree on a Mac; `main`'s macOS job failed four that this branch's passed. - `test_an_exact_workflow_reports_stale_work_beside_a_live_page_claim`, a journey test this change edits, has failed on `main` since #6796, whose checks never ran it: its helper now opens threads in the panel, and the test goes on to read a card. Here it chooses cards again first. Max asked for this as one of the long-stuck design questions. No person has read it. Codex reviewed the model and the first resolve rule, the review bot the unsplit pull request and this one, and fresh agents the 21 November merge with `main`, the closed-thread rule and the agent's reopen; their findings are fixed. > _This was written by Claude Code on behalf of max-sixty_
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.
Gives the On view's lists keys of their own.
opresses the leaf: it opens the On view on the tab the leaf points at (On Me while anything waits on the user) and puts it away again; on a folded panel it unfolds it, as any press of the leaf does. ← and → turn the view's tabs (Menu, On Me, On , Threads), round from either end, from a row, the list or the tab strip.g Aopens On by name, asg Mopens On Me, and a tab the view doesn't show previews the door that opens its list. Before this, On had no key, and reaching it tookg Mand seven Tabs.Why: over seven weeks of this machine's pages,
mran 1,851 times whileg Mran 3 andg T9, and the leaf and tabs took 112 pointer presses (leaf-dev logs usageand the tabs' recorded presses).To weigh: Hide annotations moves from
otog H(Hidden), one of Go-to's named rows, since it ran 8 times in those weeks and needs no letter of its own; the leaf's menu row names the new keys. Sog Hdoesn't open the changeshwalks, asg Tandg Mopen the liststandmwalk. It stays a view rather than a mode: the field already says "Annotations hidden" while it holds, and a mode's chip would take the field, so the user couldn't comment with the pins down. A key that opens the menu now lands on its first row rather than its search, so the arrows go on to the other tabs; a mouse's press still puts the caret in the search. Putting the view away byoor a door lands the user where Escape does.Asked for by @max-sixty; reviewed by Codex (two rounds), a cold keyboard pass on a live preview, and Tend. Tests:
test_o_presses_the_leaf_and_the_arrows_turn_the_on_view_s_tabs, the touched annotation, fold and panel tests,pnpm run test:runtime,pnpm run check.