-
Appearance
+
{t("Appearance", ui.locale)}
-
-
+
+
-
Follows the macOS theme when set to System.
+
{t("Follows the macOS theme when set to System.", ui.locale)}
-
+
-
Changing the language reloads brew-browser.
+
{t("language.hint.reload", ui.locale)}
-
+
-
Which section opens when you launch brew-browser.
+
{t("Which section opens when you launch brew-browser.", ui.locale)}
-
+
-
Requires app restart to take effect. The default
- (HudWindow) matches the rest of macOS.
+
{t("Requires app restart to take effect. The default (HudWindow) matches the rest of macOS.", ui.locale)}
-
+
- When on, brew-browser shows extra metadata generated at build time
- by AI: friendly names, expanded descriptions, use cases, similar
- package suggestions, and category tags.
- Zero LLM calls are made from your machine — all
- enrichment is baked into the app binary.
+ {t("When on, brew-browser shows extra metadata generated at build time by AI: friendly names, expanded descriptions, use cases, similar package suggestions, and category tags.", ui.locale)}
+ {t("Zero LLM calls are made from your machine", ui.locale)}
+ {t("— all enrichment is baked into the app binary.", ui.locale)}
- When off, only Homebrew's native metadata appears. Categories
- (sidebar tile grid, donut chart, chip filters) are also hidden
- because they're AI-generated.
+ {t("When off, only Homebrew's native metadata appears. Categories (sidebar tile grid, donut chart, chip filters) are also hidden because they're AI-generated.", ui.locale)}
diff --git a/src/lib/components/Sidebar.svelte b/src/lib/components/Sidebar.svelte
index 4b8157a..e9f9ad9 100644
--- a/src/lib/components/Sidebar.svelte
+++ b/src/lib/components/Sidebar.svelte
@@ -18,13 +18,20 @@
import { search } from "$lib/stores/search.svelte";
import { settings } from "$lib/stores/settings.svelte";
import { vulnerabilities } from "$lib/stores/vulnerabilities.svelte";
+ import {
+ formatBrewOperationsRunning,
+ formatVulnerablePackageLabel,
+ formatVulnerablePackages,
+ t,
+ type MessageKey,
+ } from "$lib/i18n/messages";
import { normalizeServiceStatus, type PackageKind, type SearchHit } from "$lib/types";
import Pill from "./Pill.svelte";
import type { SidebarSection } from "$lib/types";
interface NavItem {
id: SidebarSection;
- label: string;
+ labelKey: MessageKey;
shortcut: string;
icon: typeof Boxes;
}
@@ -33,13 +40,13 @@
so ⌘0 maps to it and it gets the visual primacy without a dedicated
brand row eating sidebar space. */
const nav: NavItem[] = [
- { id: "dashboard", label: "Dashboard", shortcut: "⌘0", icon: LayoutDashboard },
- { id: "library", label: "Library", shortcut: "⌘1", icon: Boxes },
- { id: "discover", label: "Discover", shortcut: "⌘2", icon: Compass },
- { id: "trending", label: "Trending", shortcut: "⌘3", icon: TrendingUp },
- { id: "snapshots", label: "Snapshots", shortcut: "⌘4", icon: Archive },
- { id: "services", label: "Services", shortcut: "⌘5", icon: Server },
- { id: "activity", label: "Activity", shortcut: "⌘6", icon: Activity },
+ { id: "dashboard", labelKey: "nav.dashboard", shortcut: "⌘0", icon: LayoutDashboard },
+ { id: "library", labelKey: "nav.library", shortcut: "⌘1", icon: Boxes },
+ { id: "discover", labelKey: "nav.discover", shortcut: "⌘2", icon: Compass },
+ { id: "trending", labelKey: "nav.trending", shortcut: "⌘3", icon: TrendingUp },
+ { id: "snapshots", labelKey: "nav.snapshots", shortcut: "⌘4", icon: Archive },
+ { id: "services", labelKey: "nav.services", shortcut: "⌘5", icon: Server },
+ { id: "activity", labelKey: "nav.activity", shortcut: "⌘6", icon: Activity },
];
// ───────── Sidebar type-ahead search ─────────
@@ -153,7 +160,7 @@
const base = env.summary;
if (activity.runningCount > 0) {
const n = activity.runningCount;
- return `${base}\n${n} brew operation${n === 1 ? "" : "s"} running`;
+ return `${base}\n${formatBrewOperationsRunning(n, ui.locale)}`;
}
return base;
});
@@ -183,8 +190,7 @@
vulnerabilities.severityCounts.vulnerablePackages,
);
const vulnBadgeTooltip = $derived.by(() => {
- const n = vulnBadgeCount;
- return `${n} package${n === 1 ? "" : "s"} with known vulnerabilities`;
+ return formatVulnerablePackages(vulnBadgeCount, ui.locale);
});
function openVulnDashboard() {
@@ -194,7 +200,7 @@
}
-