Disable dashboard banners and label Home navigation

This commit is contained in:
webadderall committed 2026-09-22 20:06:18 +10:00
1 parent 9049a82b84
commit 6a6434a999
10 files changed
+23 -26

No files matched your search

Binary file not shown.

Before

Width:  |  Height:  |  Size: 189 KiB

After

Width:  |  Height:  |  Size: 90 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 195 KiB

After

Width:  |  Height:  |  Size: 89 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 37 KiB

After

Width:  |  Height:  |  Size: 36 KiB

@@ -4,7 +4,7 @@ import {
Cloud,
File,
GearSix,
ImageSquare,
House,
Plus,
UploadSimple,
UserCircle,
@@ -66,11 +66,11 @@ export function DashboardSidebar({
aria-current={section === "projects" ? "page" : undefined}
onClick={() => setSection("projects")}
>
<ImageSquare
<House
weight={section === "projects" ? "fill" : "regular"}
className="size-[18px]"
/>
Projects
Home
</Button>
<Button
variant="ghost"
@@ -3,7 +3,7 @@ export type AnnouncementConfig = { enabled: boolean; banners: AnnouncementBanner
/** Code-only configuration. One banner hides navigation; an empty list hides the card. */
export const dashboardAnnouncements: AnnouncementConfig = {
enabled: true,
enabled: false,
banners: [
{ src: "announcements/placeholder-1.svg", alt: "Announcement banner placeholder 1" },
{ src: "announcements/placeholder-2.svg", alt: "Announcement banner placeholder 2" },
@@ -12,7 +12,6 @@ import type { useExportSettings } from "../export/useExportSettings";
import type { useExportStatusViewModel } from "../export/useExportStatusViewModel";
import type { useVideoEditorPresets } from "../presets/useVideoEditorPresets";
import type { useProjectState } from "../state/useProjectState";
import { APP_HEADER_ICON_BUTTON_CLASS } from "../TutorialHelp";
import { EditorExportMenu } from "./EditorExportMenu";
import { EditorPresetMenu } from "./EditorPresetMenu";
@@ -109,11 +108,12 @@ export function EditorHeader(props: Props) {
variant="ghost"
size="sm"
onClick={handleOpenProjectBrowser}
className={APP_HEADER_ICON_BUTTON_CLASS}
title={t("editor.project.projects", "Open projects")}
aria-label={t("editor.project.projects", "Open projects")}
className="h-9 shrink-0 gap-2 px-3"
title="Home"
aria-label="Home"
>
<House weight="fill" className="h-4 w-4" />
<span>Home</span>
</Button>
<span
aria-hidden="true"
+2 -2
View File
@@ -108,7 +108,7 @@ test("populated project and preset popovers fit long names and dismiss outside",
test.setTimeout(60000);
await installDesktopBridge(page);
await page.goto("/?windowType=editor");
await expect(page.getByRole("button", { name: "Open projects", exact: true })).toBeVisible();
await expect(page.getByRole("button", { name: "Home", exact: true })).toBeVisible();
await page.evaluate(() => {
window.electronAPI.listProjectFiles = async () => ({
success: true,
@@ -123,7 +123,7 @@ test("populated project and preset popovers fit long names and dismiss outside",
})),
});
});
await page.getByRole("button", { name: "Open projects", exact: true }).click();
await page.getByRole("button", { name: "Home", exact: true }).click();
const projects = page.getByRole("dialog", { name: "Projects", exact: true });
await expect(projects.getByRole("button", { name: /A very long project name/ })).toHaveCount(5);
await expectButtonsFit(projects);
+1 -1
View File
@@ -63,7 +63,7 @@ test("editor loads video, switches tools and edits export options", async ({ pag
fullPage: true,
animations: "disabled",
});
await page.getByRole("button", { name: "Open projects", exact: true }).click();
await page.getByRole("button", { name: "Home", exact: true }).click();
await expect(page.getByRole("dialog", { name: "Projects", exact: true })).toBeVisible();
await page.keyboard.press("Escape");
await page.getByRole("button", { name: "Crop Video", exact: true }).click();
+11 -14
View File
@@ -43,7 +43,7 @@ test("home dashboard searches, sorts, opens projects and returns to the editor",
};
});
await page.goto("/?windowType=editor");
await page.getByRole("button", { name: "Open projects", exact: true }).click();
await page.getByRole("button", { name: "Home", exact: true }).click();
const home = page.getByRole("dialog", { name: "Projects dashboard", exact: true });
await expect(home).toBeVisible();
const cards = home.getByRole("list", { name: "Your projects" }).locator("li > button");
@@ -77,7 +77,7 @@ test("home dashboard searches, sorts, opens projects and returns to the editor",
page.getByRole("button", { name: "Remove custom color", exact: true }),
).toBeVisible();
await page.keyboard.press("Escape");
await home.getByRole("button", { name: "Projects", exact: true }).click();
await home.getByRole("button", { name: "Home", exact: true }).click();
await expect(home.locator('[aria-label="Local profile"]')).toHaveCount(3);
await home.getByRole("button", { name: "Options for App walkthrough", exact: true }).click();
@@ -91,14 +91,14 @@ test("home dashboard searches, sorts, opens projects and returns to the editor",
await home.getByRole("button", { name: "Tutorials", exact: true }).click();
await expect(cards).toHaveCount(1);
await expect(cards.first()).toHaveAccessibleName("App walkthrough");
await home.getByRole("button", { name: "Projects", exact: true }).click();
await home.getByRole("button", { name: "Home", exact: true }).click();
await home.getByRole("button", { name: "Last 7 days", exact: true }).click();
await expect(cards).toHaveCount(0);
await home.getByRole("button", { name: "All", exact: true }).click();
await expect(cards).toHaveCount(3);
await home.getByRole("button", { name: "Settings", exact: true }).click();
await expect(home.getByRole("region", { name: "Dashboard settings" })).toBeVisible();
await home.getByRole("button", { name: "Projects", exact: true }).click();
await home.getByRole("button", { name: "Home", exact: true }).click();
await home.getByRole("button", { name: "New", exact: true }).click();
await expect(page.locator("html")).toHaveAttribute("data-hud-opened", "true");
await home.getByRole("button", { name: "Select projects to delete" }).click();
@@ -132,7 +132,7 @@ test("home dashboard searches, sorts, opens projects and returns to the editor",
test("home dashboard explains an empty library", async ({ page }) => {
await installDesktopBridge(page);
await page.goto("/?windowType=editor");
await page.getByRole("button", { name: "Open projects", exact: true }).click();
await page.getByRole("button", { name: "Home", exact: true }).click();
await expect(page.getByText("No projects yet")).toBeVisible();
await page.getByRole("button", { name: "Back to editor" }).click();
await expect(page.getByRole("button", { name: "Rename project" })).toBeVisible();
@@ -152,7 +152,7 @@ test("autosave creates one untitled project, stays idle without edits, and refre
await page.waitForTimeout(1800);
await expect(page.locator("html")).toHaveAttribute("data-project-creates", "1");
expect(await page.locator("html").getAttribute("data-project-saves")).toBe(before);
await page.getByRole("button", { name: "Open projects", exact: true }).click();
await page.getByRole("button", { name: "Home", exact: true }).click();
await expect(page.getByRole("dialog", { name: "Projects dashboard" })).toBeVisible();
await expect(page.locator("html")).toHaveAttribute(
"data-saved-thumbnail",
@@ -179,7 +179,7 @@ test("deletion refreshes the grid and keeps unselected projects", async ({ page
};
});
await page.goto("/?windowType=editor");
await page.getByRole("button", { name: "Open projects", exact: true }).click();
await page.getByRole("button", { name: "Home", exact: true }).click();
const home = page.getByRole("dialog", { name: "Projects dashboard" });
await home.getByRole("button", { name: "Select projects to delete" }).click();
await home.getByRole("list").getByRole("button", { name: "Delete", exact: true }).click();
@@ -230,7 +230,7 @@ test("cards rename inline, preserve folder chips and use existing share links",
};
});
await page.goto("/?windowType=editor");
await page.getByRole("button", { name: "Open projects", exact: true }).click();
await page.getByRole("button", { name: "Home", exact: true }).click();
const home = page.getByRole("dialog", { name: "Projects dashboard" });
await expect(home.getByRole("button", { name: "Remove Demo from Work" })).toContainText("Work");
await home.getByRole("button", { name: "Options for Demo" }).click();
@@ -290,12 +290,9 @@ test("dashboard supports creation sort, independent folders, shared settings and
await page.goto("/?windowType=editor");
await page.getByRole("radio", { name: "Videos", exact: true }).click();
await expect(page.getByRole("complementary", { name: "Videos" })).toBeVisible();
await page.getByRole("button", { name: "Open projects", exact: true }).click();
await page.getByRole("button", { name: "Home", exact: true }).click();
const home = page.getByRole("dialog", { name: "Projects dashboard" });
await home.getByRole("button", { name: "Next announcement" }).click();
await expect(
home.getByRole("img", { name: "Announcement banner placeholder 2" }),
).toBeVisible();
await expect(home.getByLabel("Announcements", { exact: true })).toHaveCount(0);
await home.getByRole("button", { name: "Sort projects" }).click();
await page.getByRole("menuitem", { name: "Last created", exact: true }).click();
await expect(
@@ -378,7 +375,7 @@ test("Solar navigation selection, circular initials, and Raw sources are consist
await scene.click();
await expect(scene).toBeChecked();
await expect(videos).not.toBeChecked();
const homeButton = page.getByRole("button", { name: "Open projects", exact: true });
const homeButton = page.getByRole("button", { name: "Home", exact: true });
await expect(homeButton.locator("svg")).toHaveAttribute("data-icon-style", "bold");
await homeButton.click();
const home = page.getByRole("dialog", { name: "Projects dashboard" });
+1 -1
View File
@@ -76,7 +76,7 @@ test("Videos supports selection, remove all, undo and real timeline drag inserti
await expect(panel.getByText("first.mp4", { exact: true })).toBeVisible();
const videosButton = page.getByRole("button", { name: "Videos", exact: true });
expect((await videosButton.boundingBox())!.x).toBeLessThan(
(await page.getByRole("button", { name: "Open projects", exact: true }).boundingBox())!.x,
(await page.getByRole("button", { name: "Home", exact: true }).boundingBox())!.x,
);
expect((await panel.boundingBox())!.x).toBeLessThan(100);
await expect(videosButton).toHaveClass(/button--secondary/);