Skip to content

fix: land On Me's Show in the margin card it opens, not On Me's own drawing of the message - #6083

Merged
leaf-agent merged 1 commit into
mainfrom
fix/issue-6081
Nov 16, 2026
Merged

leaf-agent merged 1 commit into
mainfrom
fix/issue-6081

Conversation

@leaf-agent

Copy link
Copy Markdown
Collaborator

On Me's Show on a question asked in a thread's words has left focus on body since #6056, instead of in the margin card it opens. The panel's reader declines an anchored thread, so the route opens the thread's margin card and travels to it (onPage → scrollToThread). Both chose their focus target through threadFocusTarget, which prefers the primary reader's destination, and the panel's reader still draws the message in On Me's card. So the arrival landed on that lf-msg (stack: scrollToThread's arrive → focusForNavigation), and On Me closing then dropped the user on the page. #5039 had worked around this by closing On Me before the arrival; #6056 removed that close on the premise that a drawing aside receives no arrival, which holds for authoredHolder but not for this target lookup.

An arrival on the page now asks threadFocusTarget for the page's drawings only (page: true): in onPage's non-travel branch and in scrollToThread, whose three callers are all page routes in destination.js. That route runs only after the primary declined the thread, drew nothing for it, or is about to put its view away (reader: "page"), so its view is never the right target there. The early close stays deleted.

Verification: tests/browser/controls/test_focus.py::test_show_from_on_me_lands_in_the_card_it_opens fails on current main (timeout waiting for focus in .lf-margin-preview) and passes here. The 86 browser tests selected by -k "show_from or show_on or on_me or (on_panel and show) or arrival or arrives or walk_to" pass. One of them, test_render_floating_panel.py::test_an_arrival_the_opening_view_will_cover_puts_it_away, errors in the teardown shift watch the same way on main without this change. pnpm run test:runtime and pnpm run check:browser pass.

Closes #6081 — automated triage

…the thread

On Me's Show on a question asked in a thread's words left focus on body
after #6056. The panel's reader declines an anchored thread, so the
route opens the thread's margin card and travels there (`onPage`,
`scrollToThread`). Both picked their focus target through
`threadFocusTarget`, which prefers the primary reader's destination; the
panel's reader still drew the message in On Me's card, so the arrival
landed there and On Me closing dropped the user on the page. #5039 had
closed On Me before the arrival; #6056 removed that close.

An arrival on the page now asks `threadFocusTarget` for the page's
drawings only (`page: true`), in `onPage` and in `scrollToThread`, whose
callers are all page routes. The primary's view is never the target of
an arrival it declined or is about to put away.

`test_show_from_on_me_lands_in_the_card_it_opens` fails on main and
passes here.

Closes #6081
@leaf-agent
leaf-agent merged commit 557cc31 into main Nov 16, 2026
6 checks passed
@leaf-agent
leaf-agent deleted the fix/issue-6081 branch November 16, 2026 00:25
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.

test_show_from_on_me_lands_in_the_card_it_opens: On Me's Show leaves focus on body since #6056

1 participant