Skip to content

Give package presses their symbol and name from their action - #4572

Merged
max-sixty merged 7 commits into
mainfrom
action-names
Oct 28, 2026
Merged

max-sixty merged 7 commits into
mainfrom
action-names

Conversation

@max-sixty

Copy link
Copy Markdown
Owner

#4563 gave every runtime press whose face its surface draws its symbol and name from ACTIONS through nameAction. Package presses still paired showAction or actionTemplate with a hand-written name, so the two could drift there.

The public package API (widget-api.js) now offers nameAction and namedAction, and these presses use them, keeping their own labels where they say more:

  • lf-sample's Full view / Return to page
  • lf-diff's Expand/Collapse all files and lf-call-diff's Expand/Collapse all call-tree roots
  • lf-deck's forward press (Start / Next)
  • lf-file-editor's Retry

showAction and actionElement leave the public package API: no package uses them, and nameAction already swaps the symbol for a press whose action follows its state. actionTemplate stays for a symbol that isn't a press's whole face, such as lf-trace's play/pause pair. module-reading.md's Icons section says which to use. No protocol bump, since the public package API doesn't bump it (#4551).

No behavior change: each press keeps its symbol, label and tooltip, and each keeps its own face.

Checks: pnpm run check (runtime tests 693/693) and 9 focused browser tests covering each of these presses (live samples' full view, diff fold-all, call-diff rows, deck, file-editor status controls on a phone).

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

Done had three faces: the word on a thread's to-do line and on its On me card,
and ✓ in the panel row's way out of a to-do. The thread line was worded because
✓ is the thread head's Resolve, and the row's end takes only a symbol.

Done now names its own symbol, a ticked circle as task apps draw a finished
task, so it is one symbol on the thread line, the On me card and the row's end,
and never reads as Resolve. `ACTIONS.done` points at the new `checked` icon;
browser/AGENTS.md's example of ✓ now names resolve.

Behavior: the Done buttons on a thread's to-do and on an On me card show the
symbol with "Done" as tooltip and accessible name, rather than the word.
A role's symbol press took its symbol and name from `ACTIONS`, but a press
whose face its surface draws, such as the floating panel's, a message's
controls, the composer's Send and Dictate and a recording's Full screen,
drew `actionTemplate(action)` and spelled its tooltip and accessible name by
hand. The two could drift: On me's Show was "Show" where the action said
"Show on page".

`nameAction(control, action, {label, title, className})`, and the template
directive `namedAction`, give such a press the action's symbol and name, as a
symbol role does, with `label` and `title` saying more where the press needs
to. Every such press in the runtime uses it; `actionTemplate` stays for a
symbol that is not a press's whole face, such as a menu row's icon or the
second of two symbols a press swaps by CSS. `actionName` is the one home of an
action's name, read by both paths.

The `show` action's name is now "Show": it takes the reader to where a thing
stands, which On me's Show does whether that is the page or a message. The
thread view's seat and About's row say "Show on page" or "Show in message" as
their label.

Behavior: the panel's Find, the recording's Full screen and the expand toggle
now carry a tooltip matching their accessible name; names are otherwise
unchanged.
# Conflicts:
#	browser/runtime/floating-panel.js
#	dist/kernel/kernel.json
#	dist/kernel/leaf.js
A package press whose face its widget draws still showed an action's symbol
with `showAction` or `actionTemplate` and spelled its name by hand, so the two
could drift as the runtime's could before #4563. The public package API now
offers `nameAction` and `namedAction`, and lf-sample's Full view, lf-diff's and
lf-call-diff's Expand/Collapse all, lf-deck's forward press and lf-file-editor's
Retry use them, saying their own label where it says more.

`showAction` and `actionElement` leave the public package API: no package uses
them, and `nameAction` covers a press whose action follows its state.
`actionTemplate` stays for a symbol that isn't a press's whole face, such as a
trace's play/pause pair. module-reading.md's Icons section says which to use.
No protocol bump: the public package API doesn't bump it.

Behavior: none; each press keeps its symbol, label and tooltip.
@max-sixty
max-sixty merged commit 880b0ab into main Oct 28, 2026
4 checks passed
@max-sixty
max-sixty deleted the action-names branch October 28, 2026 09:05
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