Skip to content

fix(focus): claim and directional search fixes - #134

Merged
RuudBurger merged 4 commits into
mainfrom
ruud/focus-claim-fixes
Oct 12, 2026
Merged

RuudBurger merged 4 commits into
mainfrom
ruud/focus-claim-fixes

Conversation

@RuudBurger

Copy link
Copy Markdown
Member

Four FocusManager fixes from running the Plex Lightning app on native-style focus (on top of the claim patience in #133).

  • Empty redirect-only groups (a 0x0 claim region) are skipped when a focused item unmounts and when entering a group. An uncached show page's remounting button used to leave focus on the invisible claim region.
  • A removed claim no longer blocks the next one. A later p=10 claim never took over once the p=5 target had gone.
  • Directional moves beam from the focused leaf, like tvOS and Android. Up from Activity on a details page went to the summary instead of the action bar (and to Restart instead of Resume on a movie). Falls back to the row when nothing lines up with the leaf.
  • A claim's own fallback landing doesn't count as last-focused, so ['last-focused', episodeKey] moves to the episode when the key shows up a few ms late instead of staying on its fallback.

Caveat: the last one means a later autoFocus child can still take the slot in a claimed region until the user moves in it. Seems right to me, since a claim landing is a mount-time default, but shout if that bites.

Tests: 382 pass, 5 new regression specs (all failed before). One patch changeset per fix.

@RuudBurger
RuudBurger merged commit 816b99a into main Oct 12, 2026
1 check passed
@RuudBurger
RuudBurger deleted the ruud/focus-claim-fixes branch October 12, 2026 20:35
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.

1 participant