fix(player): a step onto an unplayable video carries on the way it went
Previous onto an embed-blocked or removed video skipped forward again (the auto-advance direction), straight back to the item just left. The player now remembers the direction of the step that reached the item and the videos YouTube refused this session: an error carries on that way, Previous / Next pass over known-dead items without loading them, and go dark when only those are left. A step of your own skips with auto-advance off too.
This commit is contained in:
@@ -76,14 +76,13 @@ function mountPlayer(qc: QueryClient, sessionPos: Map<string, number>) {
|
||||
mountRef: { current: mount },
|
||||
playerRef: createRef<YTPlayer>() as RefObject<YTPlayer | null>,
|
||||
currentIdRef: { current: VID },
|
||||
navRef: { current: { queue: undefined, index: 0 } },
|
||||
modeRef: { current: { autoMode: "off", loopMode: "off" } },
|
||||
setWatched: () => {},
|
||||
setPlayerError: () => {},
|
||||
setLiveData: () => {},
|
||||
reapplyStored: () => {},
|
||||
reclaimFocus: () => {},
|
||||
advanceOnEnd: () => {},
|
||||
skipUnplayable: () => {},
|
||||
sessionPosRef: { current: sessionPos },
|
||||
qc,
|
||||
}),
|
||||
|
||||
Reference in New Issue
Block a user