You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 22561bb
Browse filesBrowse the repository at this point in the historyBrowse files
fix(Comments): Mark as resolved and Reopen hand focus to the control that replaces them
Resolving a thread replaces Mark as resolved with Reopen, and reopening it
replaces Reopen with Mark as resolved, when the host's update arrives. The
pressed control left the page, so keyboard focus fell to the page body. Both
controls now take one ref from Core's focus hand-off, useFocusAcrossSwap:
when the pressed control leaves while it has focus, the control that
replaces it takes focus, unless focus has moved somewhere else. A failed
request replaces nothing.
OverflowList renders an inert copy of each action to measure it, so the
hand-off ignores an element while it is inside an inert region. It reads
inertness when it records or takes a hand-off, not when the element
attaches, because a region can stop being inert later. Core's internal
entry re-exports the hook for Lab.
In a narrow panel, Reopen does not fit the actions row and collapses into
the more menu right after it takes focus. While the resolve action sits in
that menu, the menu's trigger takes the same ref, so focus moves to the
trigger.
[chore] Internal: the focus hand-off Core runs when it replaces one of a control's elements ignores an element while it is inside an inert region, such as the copy OverflowList renders to measure its items, and Core's internal `@astryxdesign/core/internal/touch` entry re-exports it for Astryx's own packages, so Lab's Comments carries focus from Mark as resolved to Reopen and back, or to the more-menu trigger when the replacement collapses into that menu. It is not part of the public API. Apps see no change.
0 commit comments