fix(plex): a Restart does not replay on a reload or a Forward onto the player
fromStart rode in history.state._sub, so reloading the player entry restarted the item from 0 again and the progress checkpoint overwrote its resume point. A sub-view config can now say what the history entry keeps of a view.
This commit is contained in:
@@ -76,3 +76,18 @@ describe("PLEX_SUB_URL decode guards", () => {
|
||||
expect(U.decode("")).toBeNull();
|
||||
});
|
||||
});
|
||||
|
||||
describe("PLEX_SUB_URL entry", () => {
|
||||
// E28 review E1: the Restart click must not replay on a reload / Forward onto the player entry.
|
||||
it("keeps the player without its one-shot fromStart, and every other view whole", () => {
|
||||
const entry = U.entry!;
|
||||
expect(entry({ kind: "player", id: "7", queue: ["7", "8"], fromStart: true })).toEqual({
|
||||
kind: "player",
|
||||
id: "7",
|
||||
queue: ["7", "8"],
|
||||
fromStart: undefined,
|
||||
});
|
||||
const info = { kind: "info", id: "7" } as const;
|
||||
expect(entry(info)).toBe(info);
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user