Repository navigation
Open the leaf's menu as the On view's first tab, searched from the field - #4895
Merged
Merged
Conversation
The leaf now opens the On view on a new first tab, Menu, beside On me, On <agent> and Threads, so the menu reaches the obligations and threads the status counts. Versions, Navigate, Annotations and Errors open as views over the menu with a way back to it. While the menu stands, the panel's field is its search: typing narrows the rows (those inside its lists included) and lists the threads and versions whose names match, ending with a press that opens the command reference on the same words; Enter presses the first row found and Down goes to the rows. The popup menu over the leaf goes, with its opening, held rows and status, fade, sliding lists and their arrow and Tab keys: the menu is an ordinary view, so it closes on Escape or a press on the page like every other, and Escape from a list over it closes the view rather than stepping back. Copy agent session, Copy Leaf version, Copy preview diagnostics and Copy session reference leave the menu for About this page, which already lists each with a copy control; Copy link stays. The menu's status no longer repeats the Waiting on counts its tabs show. The s command is renamed Select mode, beside Draw and Design mode. The user chose this configuration on the menu-design page on 30 October.
…do armed Three behaviors the menu's move into the On view had broken, which the migrated tests caught: - The menu again holds the rows and status lines it opened with while it stands, in its view's opening record: a row news offers joins at the next opening and one news takes away stands disabled, so news moves nothing under the reader (browser/AGENTS.md, "News never moves what the reader is reading"). - Versions' row walk stops on each version's Compare again. - A finger's two presses on the menu's Undo take the gesture back again: undo's arm now reads the shown place past Leaf's own surfaces, and stays armed when the panel takes a thread's view away for the menu, since that went by a press in Leaf's chrome. Going back from a list to the menu also stands on the row that opened it.
The tests now open the menu as the panel's view (`panel_menu` returns the Menu view, or a list's view over it, and `close_panel_menu` puts it away by the leaf), read the view's `data-open` in place of the popup's `data-menu` and `data-level`, and press rows as buttons rather than menu items. Behavior the rewritten tests now hold: - Opening the menu, or `g V`, from an open thread or On view replaces that view; the popup used to stand over it. - `g V` from the page leaves focus on Versions itself, and Down enters its rows; `?` over Versions leaves it standing under the reference. - Escape closes the menu and any list over it in one step; the menu's arrow-level and Tab-leave keys are gone; Down from the menu's search enters its rows; the menu's search finds rows, threads and commands. - The session reference, preview diagnostics and Leaf version are read and copied from About this page; the menu's head no longer says the Waiting on counts, which its tabs show; `s` reads Select mode. Removed with what they protected: the write watch's credit for the popup's line limits being taken off and put back during its fade, and its test; Copy Leaf version as one press in the menu (About this page's tests cover the copy); the popup painting over the panel's box; the search-from-the-menu case that returned to the same reply editor, since the menu now replaces the thread; and `?` dismissing Versions as a light-DOM popover.
From a review of the new menu: - Escape from a list over the menu (Versions, Navigate, Annotations, Errors) steps back to the menu, onto the row that opened it, and from the menu returns the user to the leaf; it used to drop focus on the page's body and close everything at once. - The arrows, and Enter and Down from the search, skip a row standing disabled, as Undo does with nothing to take back; the walk used to stop on it. - The menu's search finds the rows that open its lists, and Errors, by name, and Up from the first row found returns to the search. - The search's prompt is shorter, so a phone's field shows it whole. Tests now press Escape twice where a list stood over the menu.
# Conflicts: # browser/runtime/activity-words.js # dist/kernel/kernel.json # dist/kernel/leaf.js
…h Versions An element holds one key declaration (keyboard/scopes.js), and Versions' number keys, moved onto the panel's view when the popup menu went, replaced Threads' `/` there: in Threads, `/` searched the page's words again rather than finding a thread. Both views' keys now stand in one declaration, each row and Versions' claim on the page's character keys gated by its own view. Tests that pressed the On view's tabs by position, or listed them, count the Menu tab first.
…'s controls While a view is open, the field without the caret draws no frame and shows the status in its place, so under a line drawn above the controls it read as the view's last row: on Versions, "Away" looked like one more row under "‹ Menu". The one hairline now stands above the row, and the way back or the tabs read with the view they steer. The user chose this on 31 October over keeping the line and over adding a second one above the field.
# Conflicts: # browser/runtime/activity-words.js # browser/runtime/floating-panel.js # browser/runtime/keyboard/command-reference.js # browser/runtime/page-about.js # browser/runtime/page-controls.js # browser/styles/floating-panel.css # dev/leaf_dev/commands/stills.py # dist/kernel/kernel.json # dist/kernel/leaf.js # dist/kernel/runtime/bundle-content-layout.js # tests/browser/test_chrome_contracts.py # tests/browser/test_render_floating_panel.py
# Conflicts: # browser/runtime/floating-panel.js # browser/styles/floating-panel.css # dist/kernel/kernel.json # dist/kernel/leaf.js
Behavior changes: - A double-click on a list's ‹ goes back to the menu once. The menu is taller than the list, so the second click used to press, and focus, whichever menu row came under the pointer, Undo among them. A capture listener on the panel now refuses the mousedown and click of a run begun on another control; clicks repeated on one control, as Next match or Resolve, each still press it. - `/` in the menu returns to its search, keeping the words typed, rather than opening page search. Each view declares its own keys on VIEWS (`keys`, `claims`), and the one declaration on the view is generated from the view shown, replacing the hand-merged Threads and Versions declaration. - The menu's search lists the lists whose names match first, then rows, then threads and versions. A thread found there opens over the menu, so its ‹ returns to the words typed. - The search results' separator is a 1px rule instead of an unstyled hr. - On a phone (420px and narrower) the On view's tabs keep 3px of their inset, so at 390px the four tabs, a list's press and Close stand on one line. - About this page shows each copy's full text since #4889, so the dead one-line summaries in page-about.js go; the startup journey checks the preview's checkout in Page details instead of the removed summary. - The quick seat no longer steps aside for page search before its way out arrives in the repaint frame, which wrote `hidden` twice to the same value in the task that put the menu away. > _This was written by Claude Code on behalf of max-sixty_
CI lays text out in DejaVu Sans, wider than the faces phones ship, and there the 390px phone row didn't fit: On me wrapped Close under its tabs, and Threads, which scrolled its tabs instead (only On me had `data-named`), cut the last tab off. Menu, with no press, fit. So turning the tabs moved Close between lines and the tabs between scrolled and whole. Behavior changes: - The foot (Menu, On me and Threads, the only views that have one) follows one rule: the tabs keep their words whole, and where a press and Close don't fit beside them they take a line of their own at its end. - Close ends the foot's presses inside its `.lf-fp-aux`, as it ends the head line's, so the two wrap together; the press before it now stands 2px from it, as on the head line. - Every tab keeps room for one press before Close, Menu's none included, so every tab breaks the line alike and turning them moves nothing. - `data-named` goes. The phone test now asserts what holds in any face: no tab scrolls, and at 390px and 340px turning between the tabs moves no tab and not Close. At 390px in Apple's faces the row is still one line; in DejaVu, and at 375px and 340px in either, the press and Close stand on their own line. > _This was written by Claude Code on behalf of max-sixty_
On a phone, On <agent>'s plan head beside its chooser needs more than the one press the foot reserves, so its presses and Close took a second line. The foot grows from its bottom edge, so that line lifted the tabs 34px and the tab just tapped left the finger (main does the same). Behavior changes: - Where the presses and Close don't fit beside the tabs, they stand on a line over them (`flex-wrap: wrap-reverse`), with Close in the top-right corner as on the head line. The tabs stay on the row on every tab, On <agent> with a plan included. - The tabs' line is as tall as the presses' whether or not they share it, so the tabs don't drop 4px when the presses leave their line. The phone test now turns On Claude with a plan too, and asserts no tab moves on any tab and Close stays put on every other; with plain `wrap` it fails on On Claude. > _This was written by Claude Code on behalf of max-sixty_
Escape or ‹ from a list over the menu ran the transition's own focus first, which, opened by a key, stands the user on the menu's first row; the paint that follows moved the menu's tab stop there, and `back()` then put the user on the row that opened the list, moving the stop back. The write watch fails that as a write that changes nothing (test_a_failed_save_is_an_error_until_the_next_valid_one, every run here; CI caught it on 90a37f3). Behavior change: going back to the menu leaves focus to `back()`, which puts the user on the opening row directly, or where the menu no longer lists it, where the transition would have. > _This was written by Claude Code on behalf of max-sixty_
This was referenced Nov 1, 2026
leaf-agent
added a commit
that referenced
this pull request
Nov 1, 2026
The control-size sweep now reaches preview diagnostics through About this page, following #4895, and measures the usable target each control offers. Both pointer cases failed before this repair and pass afterward. The 24px and 44px floors stay the same. The remaining failures were in the probe: it rejected a wide version row because Compare intentionally owns its end, and it assumed a command's row-wide hit area was centred on its label even when a touch description stood below it. The probe now checks the central minimum-size portion of a wider face and locates an expanded hit area from its containing block and computed insets. A covered centre still fails. This changes test measurement only. Validation: both cases of `test_every_control_the_layer_offers_is_a_box_the_user_can_hit` pass, as does `test_the_add_field_previews_the_option_it_will_make`, which consumes the shared aim measurement. Temporary negative controls also pass: expanding Compare across the fine-pointer version target is detected, and removing the coarse-pointer command's hit-area pseudo-element is detected. Pre-commit checks and `git diff --check` pass. Closes #4927. --------- Co-authored-by: leaf-agent <[email protected]>
max-sixty
added a commit
that referenced
this pull request
Nov 3, 2026
… constant On a 390px phone the On view's tabs, now word presses with a border and a finger's floor, stood 261px against 256px of room, so Close went to a line of its own (#4895 promised one line). A tighter inset constant fit by 2.7px in Apple's faces and not at all in DejaVu. Each tab now stands its words between two rooms that shrink to nothing, and the strip gives every tab the same share of what it has (a grid of minmax(min-content, max-content) columns); the room between tabs is folded into those rooms. The tabs' line breaks only where the tabs at their narrowest don't fit beside the room kept for a press and Close, and holds that width when On <agent>'s plan head takes a line of its own, so no tab moves between views. At 390px the tabs keep about 1.6px of room each in Apple's faces and 0.5px in DejaVu. test_on_a_phone_turning_on_s_tabs_moves_nothing now fails when Close leaves the tabs' line at 390px; it failed on dee738b. Also: the journey test that disables quick shortcuts presses the reference's option, which is the press now; the inline face's comments say news keeps the accent; and a diff line number's look has one home, `.lf-diff-line-number`, with the gutter face adding only what makes it a press.
max-sixty
added a commit
that referenced
this pull request
Nov 3, 2026
… command's availability in its when (#5250) Six keyboard tests in `tests/browser` fail on `main`, in CI and locally, since #4873 and #4895. Three of the causes were in the runtime, and the rest in fixtures that still used the API those changes replaced. - **The command reference.** #4873 let a row declare `run` as a getter that returns nothing while the command can't act, and the reference read that value to decide whether a row runs at all. So Resolve, outside a thread, became a disabled option rather than one the user can pick and be told "Available in a thread". The reference now asks whether the row declares a `run` (or a `runKey` for a keyed route), as registration already does, and leaves "now" to availability. - **Availability.** #4873 also folded the `when` of four rows (`thread.primary`, `thread.resolution.toggle`, `message.copy`, `message.edit.previous`) into such a getter, so every reader of availability but dispatch took them as live while their `run` had nothing to do: the reference listed "Copy message as Markdown" while words were selected, and the message editor advertised ↑ with no message above to edit. With the reference fix above, that row would also have become one to pick. Their `when` is back, with a plain `run`, as `bindings.js` asks ("Do not repeat a guard inside `run` if the guard changes whether the key should be shown"). - **The panel's corner fold.** #4873 had the corner mark call the fold directly instead of pressing the fold command's row, so the press was no longer announced or logged. It presses the row again. - **Fixtures.** Four declared a key-dependent action as `run(binding)`, which #4873 renamed `runKey`, so they received `undefined`. Two lookups, and a journey's two, still asked for reference rows as buttons, which #4895 made listbox options. `tests/AGENTS.md` now asks whether anyone is fixing a failure on `main`, rather than who owns it. Tend had filed these causes (#5073, #5076) a day earlier, with no pull request since, and the session that met them took them for local-only: main's newest runs had all been cancelled by later pushes, and a search for the test names joined with `OR` found nothing. So the guidance names the latest finished run, says a cause issue with neither Tend's eyes reaction nor a linked pull request is still waiting, and has a session working for a maintainer start a local session for a failure nobody is fixing. Checked by node id: the six tests, the floating panel's fold tests, the radio and slider fixture's test, `tests/journeys/test_render_code_reading.py`, and the tests that press Enter, `r`, the copy key and ↑ in a thread (`test_key_surfaces::test_a_key_on_screen_is_a_key_that_works`, `test_rewrites`' three walks, `test_layout`'s Markdown copy, `test_commenting`'s native copy, `test_resolving`'s and `test_seated_threads`' settling). `pnpm run test:runtime` and `pnpm run check` pass. Five other keyboard failures on `main` (`test_focus`'s reference-command gesture, `test_commenting`'s submit shortcuts and `startup/test_keys`' early key) still fail with this change and have other causes. Closes #5073 Closes #5076 > _This was written by Claude Code on behalf of max-sixty_
max-sixty
added a commit
that referenced
this pull request
Nov 4, 2026
…#5313) #4873 let a command row declare `run` as a getter that returns nothing while the command can't act. Dispatch then fell through, but every other reader of availability (the command reference, key hints, `aria-keyshortcuts`) reads `when` and took such a row as live. #5250 put four thread rows back on `when` with a plain `run`, as `bindings.js` asks ("Do not repeat a guard inside `run` if the guard changes whether the key should be shown"). This does the same for the six rows that were left: - `navigation.back` (`register.js`), `selection.restore` (`composing/capture.js`) and the three `margin.card.*` rows (`annotation-overlay/thread-preview.js`) already had a `when` that matched their getter's guard, so their behavior is unchanged. - `code.copy` (`code-copy.js`) had no `when`. Before its Copy button upgraded, a code block advertised Enter as "copy code" and the press fell through to the page. It now waits in its `when` for the button. The detail dial's arrows (`packages/detail/widgets/lf-dial.js`) had the same fault without a getter: `dial.less` and `dial.more` had no `when`, and their `run` returned at the dial's ends. At Skim the dial advertised ← for Less detail, which does nothing. Each row now needs a depth beside the current one in its `when`, and drawing a depth calls `commandsChanged` so Leaf reads them again. A probe of `detail` reads the dial's `aria-keyshortcuts` as `ArrowRight` at Skim, both arrows at Read and `ArrowLeft` at Everything; on `main` it reads both arrows at every depth. With no getter left, a row's `run` and `runKey` are plain values again: - `declaresCommandHandler` is deleted. Registration, the register's touch check, button wiring and the command reference read `row.run` and `row.runKey` directly. - Go-to registers its direct destinations by spreading them, without copying property descriptors. - The three runtime tests that pinned the getter contract are deleted. Three browser tests still looked up command reference rows as buttons, which #4895 made listbox options. They now ask for options: - `controls/test_focus.py::test_a_reference_command_finishes_its_gesture_before_a_newer_control`, which failed on `main` with no Tend cause issue. - `test_render_code_reading.py::test_code_wrapping_keeps_source_copy_and_reader_choice`, which presses Unwrap lines and Copy code in the reference, then Enter on the block. - `test_render_heading_links.py::test_a_heading_copies_the_link_to_the_section_it_opens`. Checked by node id: those tests; `test_reading_place`'s Restore selection; `test_render_code_reading`'s copy over plain HTTP; `test_summaries`' margin paging, which Tabs into and out of a card; `test_clusters`' reference row for Escape; four of `test_key_scopes`' Escape and back-gesture tests; and `test_dial`. `pnpm run test:runtime`, `pnpm run check:browser` and pre-commit pass. Locally, three of `check:worker`'s bundle and storage tests hit their 5 s and 60 s timeouts at a load average of 50 to 85, so the pull request's run is their check. > _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.
The leaf now opens the On view on a new first tab, Menu, beside On me, On and Threads, and the field becomes the menu's search. The user chose this combination on 30 October from a playground of independent choices. The menu now reaches the obligations and threads its status counts, and the popup it replaces, with the machinery only it needed, is gone.
What changes for the user
opening.menuSeats,opening.menuLines), so news moves nothing in it.findCommands). Enter presses the first result, ↓ moves into the results, ↑ from the first and/from any return to the search. A thread found there opens over the menu, so its ‹ returns to the words.aboutgroup of page controls; Copy link stays in the menu. About shows each copy's full text (since Lay out every label beside its value in one facts list, Leaf's own and a page's #4889), so those rows' one-line summaries, which only the menu showed, are gone.sreads "Select mode"; Undo's row keeps a long gesture's name to two lines; the arrows skip disabled rows. The On view's foot follows one rule on Menu, On me and Threads: the tabs keep their words whole, and where a press and Close don't fit beside them they take a line of their own over the tabs, at its end, so the tabs stay on the row and a tab turned to never leaves the finger that turned it, On 's plan head included. Close now ends the foot's presses as it ends the head line's, and every tab keeps room for one press, so turning tabs moves nothing wherever the line breaks;data-named, which gave On me that rule while Menu and Threads scrolled their tabs, goes. On a phone (420px and narrower) the tabs keep 3px of their 8px inset, so at 390px in Apple's faces the row is one line.Where to look
browser/runtime/floating-panel.js: themenuview inVIEWS,menuView/menuFound, the menu tab inonTabs/onTab,pressLeaf, the Escape steps inpageRung, andback()landing on the opening row; the view's Close stays offered at the end of the tabs while the menu's search holds the field. The popup's state, template, fade, level keys andmenuitemroles are deleted. A view's own keys are declared onVIEWS(keys,claims) and the one declaration on the view is generated from the view shown, since an element holds one key declaration (keyboard/scopes.js): the menu's and Threads'/and Versions' number keys. A capture listener on the panel swallows the second press of a run begun on another control, its mousedown as well as its click, so it neither presses that control nor takes focus to it. The quick seat no longer steps aside for a search with no way out yet: page search's comes in the repaint frame, and stepping aside meanwhile hid the seat again in the task that put the menu away.browser/styles/floating-panel.css: the popup's rules, its way back among them, removed; the hairline drawn on.lf-fp-rowwhile a view is open.browser/runtime/undo.js: the Undo arm is kept when the chrome replaces the view it was armed in, so pressing Undo twice through the menu still works.page-controls.js,page-about.js,activity-words.js,composing/target-picker.js,keyboard/command-reference.js: theaboutgroup, the status words, Select mode, and the command reference opened on a query.docs/ui.htmlfollow the new menu. Tests that pressed the On view's tabs by position count Menu first, a list's way back to the menu is the ‹ in its head, and Escape out of a list over the menu takes two presses.Behaviour to weigh
Pressing the leaf while a thread is open shows the menu in the thread's place, since every tab replaces the view; the way back to the thread is through Threads. Stacking the menu over the thread with its own way back would add a case to Back and to the Escape order.
Testing
Runtime unit tests (737) and
pnpm run check:browserpass. A menu-related browser and journey selection passes, except tests that fail identically on a clean copy ofmainon this machine (obligation walk, the leaf's fold travel, draft editing, diffs, widget quality, dictation, application boundary, options, key surfaces, touch return, a wait's deadline, a data-bound diff, a boxless target's reading). New tests cover the double-click on ‹, the menu's/, list order and a found thread's way back, and the phone tab row; each fails without its fix. The automated review could not run on this PR (tend's Codex accounts are out of quota); an independent review of the late changes found the defects these commits fix.