feat(files): the Downloads page goes — the tray, a Storage tab and a Downloads settings tab take its place
- The Downloads module, its rail icon and badge are gone. A bookmark, the remembered page and an old
history entry that name it land on Files (urlState.resolvePage); `g d` goes to Files too.
- Users page: a Storage tab — the disk in numbers, every user's use against their own limit with
their file count, every user's downloads; aligned tables, one menu per row (edit / reset quota,
open source, copy, the owner's quota). The admin storage rows carry quota + file count, the admin
job list its owner.
- Settings: a Downloads tab — the download formats in one list (duplicate a built-in, edit or delete
your own) and the site sign-ins, moved from Account.
- "View" on an added download, a clip or a converting upload opens the tray on that row (unfolded,
back if closed; a finished one opens as a file; under a player it opens without taking focus).
- The download dialog opens on the format used last.
- DataTable: `pager={false}` for a short list, `cardRow` to give a lone "…" its own card line.
- Welcome and README speak of Files; a new Files screenshot.
This commit is contained in:
@@ -70,13 +70,13 @@ afterEach(() => {
|
||||
describe("BootGate", () => {
|
||||
it("a new tab with Startup off opens on the page the account left — never on Home first", async () => {
|
||||
localStorage.setItem("siftlode.startOnHome.5", "0");
|
||||
localStorage.setItem("siftlode.page.5", "downloads");
|
||||
localStorage.setItem("siftlode.page.5", "plex");
|
||||
vi.spyOn(api, "me").mockResolvedValue(account());
|
||||
mount();
|
||||
|
||||
expect((await screen.findByTestId("app")).textContent).toBe("downloads");
|
||||
expect(renders.map((r) => r.page)).toEqual(renders.map(() => "downloads"));
|
||||
expect(new URLSearchParams(window.location.search).get("page")).toBe("downloads");
|
||||
expect((await screen.findByTestId("app")).textContent).toBe("plex");
|
||||
expect(renders.map((r) => r.page)).toEqual(renders.map(() => "plex"));
|
||||
expect(new URLSearchParams(window.location.search).get("page")).toBe("plex");
|
||||
expect(sessionStorage.getItem(ACTIVE_ACCOUNT_KEY)).toBe("5"); // the tab is pinned
|
||||
});
|
||||
|
||||
@@ -176,12 +176,12 @@ describe("BootGate", () => {
|
||||
// Pinned to 9, but 9 was signed out in another tab: the server answers as the browser's default, 5.
|
||||
sessionStorage.setItem(ACTIVE_ACCOUNT_KEY, "9");
|
||||
localStorage.setItem("siftlode.startOnHome.5", "0");
|
||||
localStorage.setItem("siftlode.page.5", "downloads");
|
||||
localStorage.setItem("siftlode.page.5", "plex");
|
||||
vi.spyOn(api, "me").mockResolvedValue(account());
|
||||
mount();
|
||||
|
||||
expect((await screen.findByTestId("app")).textContent).toBe("downloads");
|
||||
expect(renders.map((r) => r.page)).toEqual(renders.map(() => "downloads"));
|
||||
expect((await screen.findByTestId("app")).textContent).toBe("plex");
|
||||
expect(renders.map((r) => r.page)).toEqual(renders.map(() => "plex"));
|
||||
expect(sessionStorage.getItem(ACTIVE_ACCOUNT_KEY)).toBe("5");
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user