feat(video): Reset view on every YouTube video menu
The row that sets a video back to fresh (its state row and resume point both go) was only on the feed's cards. It is now on Home's shelves, a Playlists row's menu and the player's related list too, and is named "Reset view" / "Megtekintés visszaállítása".
This commit is contained in:
@@ -38,8 +38,8 @@ import { raw } from "../../lib/notifications";
|
||||
export interface VideoActionHandlers {
|
||||
onState: (id: string, status: VideoStatus) => void;
|
||||
onToggleSave: (id: string, saved: boolean) => void;
|
||||
/** Omitted where a surface cannot reset a video's state (Home's shelves). */
|
||||
onResetState?: (id: string) => void;
|
||||
/** Back to fresh: its state row and resume point both go. */
|
||||
onResetState: (id: string) => void;
|
||||
/** Omitted where the host menu leads with its own Play row (Home's shelf card resolves `next`). */
|
||||
onOpen?: (v: Video, startAt?: number | null) => void;
|
||||
/** The feed's channel filter, where the menu can narrow it: the library feed. Omitted on a channel
|
||||
@@ -189,7 +189,7 @@ export function useVideoActions(handlers: VideoActionHandlers, open: boolean) {
|
||||
separatorBefore: true,
|
||||
onSelect: () => onState(v.id, hidden ? "new" : "hidden"),
|
||||
},
|
||||
...(onResetState && isResettable(v)
|
||||
...(isResettable(v)
|
||||
? [
|
||||
{
|
||||
id: "reset",
|
||||
|
||||
Reference in New Issue
Block a user