fix(player): the playing film restarts in place; arrows stay the volume; the bands' holds end

- The info overlay's collection strip listing the film itself: Play/Restart restart or resume it in
  place instead of pausing it on a frozen 0:00.
- Up/Down on the closed ⋯ and tracks buttons stay the volume (openOnArrowKey: false).
- A keyboard focus in the bands holds them for 10 s after the last key, not the whole film; a tap
  leaving a tapped button no longer re-shows the bands its own toggle then hid.
- Next leaving under the focus hands it to its neighbour (the player keeps its focus).
- The chosen audio / subtitle track wears the MenuCheck tick.
This commit is contained in:
2026-09-27 19:42:53 +02:00
parent b7ce1d467c
commit cda626be10
4 changed files with 176 additions and 13 deletions
@@ -72,6 +72,11 @@ export interface AnchoredPopoverOptions {
* scrolls under it while its actions still target the row you opened it on (E10 review round 1).
* This is also what a native context menu does. */
dismissOnScroll?: boolean;
/** Menu/listbox only: ↑/↓ on the CLOSED trigger open the panel (the APG menu-button default, on).
* Turn it off where those keys already mean something on that trigger — a media player's row,
* where ↑/↓ are the volume from anywhere, and a trigger that swallowed them killed it (E28 review
* round 2, P2). Enter/Space/click still open it, and the arrows still rove once it is open. */
openOnArrowKey?: boolean;
}
export function useAnchoredPopover(opts: AnchoredPopoverOptions) {
@@ -199,6 +204,7 @@ export function useAnchoredPopover(opts: AnchoredPopoverOptions) {
setHoverIndex(null);
},
selectedIndex: opts.selectedIndex ?? null,
openOnArrowKeyDown: opts.openOnArrowKey ?? true,
// Disabled items are skipped automatically: with no `disabledIndices`, useListNavigation reads
// each item's DOM `disabled`/`aria-disabled` (PopoverItem always renders native `disabled`), so a
// pending/inert item is never a roving target. (Verified against @floating-ui/react 0.27