Skip to content

Say that a keyed focus hold falls back to its stand-ins, and keep lands for presses that go elsewhere - #6092

Merged
max-sixty merged 1 commit into
mainfrom
hold-focus-landing
Nov 16, 2026
Merged

max-sixty merged 1 commit into
mainfrom
hold-focus-landing

Conversation

@max-sixty

Copy link
Copy Markdown
Owner

Asked to keep a keyboard user in a list after Remove, Claude Code widget authors often worked out the nearest surviving row themselves in the command row's lands(from) instead of holding focus with holdFocus(list, { key }). module-input.md didn't say that a keyed hold tries the caller's stand-ins after the surviving items (one author skipped it because it "has no Add item fallback for an empty list"), and module-authoring.md called lands(from) "where a key leaves the user", which reads as the place for every landing. module-input.md now gives the hold's order and says a run that redraws the user's own place holds focus, leaving lands to a press that takes the user elsewhere, as lf-timeline's step arrows do (#4626).

In widget-list-keeps-focus, Claude Code passed 13 of 13 with the change against 9 of 16 without it; Codex passed 5 of 5 on both arms. The case's rubric now also accepts a native popover opened through popovertarget, which module-input.md says returns the user to its control on closing; regrading the six earlier outputs under it changed no grade.

To weigh: the earlier 2 of 6 didn't recur at this merge base (7 of 10), so the size of the gap is uncertain.

Requested by max-sixty. Checks: the eval runs above, pre-commit.

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

…ds for presses that go elsewhere

In `widget-list-keeps-focus`, Claude Code authors asked to keep the user in a list
after Remove often worked out the nearest surviving row themselves, inside the
command row's `lands(from)`, instead of holding focus with
`holdFocus(list, { key })`. One said the hold "has no Add item fallback for an empty
list". `module-input.md` said `restore` takes stand-ins, but not that a keyed hold
tries them only after the surviving items, and `module-authoring.md` said "Where a key
leaves the user is the row's `lands(from)`", which reads as the place for every
landing. `lands` came with #4626 so lf-timeline could carry a user to another step's
row off Leaf. A Remove keeps the user where they were.

`module-input.md` now gives a keyed hold's order (the same item, the nearest
survivor, on the control like the user's, then the stand-ins) and says a run that
redraws the user's own place holds focus and leaves `lands` to a press that goes
elsewhere. `lands` is described as where a press takes the user.

Claude Code passed 13 of 13 runs with the change and 9 of 16 without it (7 of 10 on
this merge base, 2 of 6 on 15 November); 2 of the 3 failures without it today were
the self-computed landing. Codex passed 5 of 5 on both arms.

The rubric also accepts a native popover that Add item opens through
`popovertarget`, closed with `closeNativeLayer` and no return focus of its own:
Leaf puts the user on that control as the popover opens, so closing returns them
there (`module-input.md`, "Layers"). Regrading the six saved 15 November outputs
under it changed none of their grades.
@max-sixty
max-sixty merged commit aa76e00 into main Nov 16, 2026
5 checks passed
@max-sixty
max-sixty deleted the hold-focus-landing branch November 16, 2026 05:46
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