codeburn/mac/Sources/CodeBurnMenubar/Data
ozymandiashh d62857ea4e feat(menubar): route every user-facing string through a strings catalog
Groundwork for #1219. The menubar app hardcoded ~530 English strings across
Views/, the presentation structs, the status-item menu and the update alerts,
so there was nothing for a translator to translate.

Every user-facing literal now goes through `L(_:)` / `L(_:_:)`, which look the
string up in `Localizable.strings` in the SwiftPM target resource bundle. The
key *is* the English copy, so English stays the development language and a
missing translation degrades to correct English instead of a dotted
identifier. `en.lproj` is therefore an identity table; it exists so the bundle
advertises `en` and so a translation can be diffed against it.

Why the lookups are explicit rather than relying on SwiftUI's implicit
`LocalizedStringKey`: SwiftPM emits target resources into a sibling bundle
(`CodeBurnMenubar_CodeBurnMenubar.bundle`) that the packaging scripts copy into
`Contents/Resources`. `Bundle.main` has no `.lproj` at all, so `Text("literal")`
would always miss. Naming `Bundle.module` is the one form that resolves the
same way in `swift run`, in `swift test` and in the packaged `.app`.

Enum raw values that double as identity (`Period`, `MenubarScope`,
`InsightMode`, `AccentPreset`, `ProviderFilter`) keep their raw value and gain
a `displayLabel`, so persistence and cache keys are untouched by translation.

Three display-only date formatters that were pinned to `en_US_POSIX` with fixed
patterns now use `setLocalizedDateFormatFromTemplate`, and the calendar
popover's weekday row comes from the locale's own symbols. The `yyyy-MM-dd`
formatter stays POSIX: it parses and builds data keys, not display text.

Not extracted, deliberately: provider, model and plan names; units; currency
codes; shell commands and paths; quota window labels that policy code matches
on by English substring (`QuotaSummary.headlineWindow`); and anything the
`codeburn` CLI produces.

Also copies the SwiftPM resource bundle into the app in build-local.sh, using
the named-bundle + `[[ -d ]]` pattern package-app.sh already uses. Without it
the assembled app finds no strings table (and already trapped on first icon
load, the resource-bundle half of #1262).
2026-09-12 15:21:49 -07:00
..
AntigravityQuotaPresentation.swift feat(menubar): live Antigravity quota — local language-server probe, Settings pane, Plan tab 2026-08-24 09:40:04 -07:00
AntigravitySubscriptionService.swift feat(menubar): add native Capacity Dock (#1167) 2026-08-29 00:37:30 -07:00
CapacityDockGlanceWindow.swift feat(menubar): switch the Capacity Dock gauge between usage windows 2026-09-12 06:38:34 -07:00
CapacityDockInteractionState.swift feat(menubar): add native Capacity Dock (#1167) 2026-08-29 00:37:30 -07:00
CapacityDockPreferences.swift feat(menubar): route every user-facing string through a strings catalog 2026-09-12 15:21:49 -07:00
CapacityDockProviderCredential.swift fix(menubar): give the pasted Copilot token a GitHub host of its own 2026-09-12 12:02:13 -07:00
CapacityDockProviderQuotaService.swift feat(mac): add native Grok Build provider 2026-09-01 18:46:02 +05:30
CapacityEstimator.swift feat(mac): native Swift menubar app + one-command install 2026-04-17 16:55:56 -07:00
ClaudeCredentialStore.swift fix: isolate overridden Claude credential homes 2026-08-29 23:38:37 +05:30
ClaudeSubscriptionService.swift fix(menubar): make a failed disconnect leave a consistent state 2026-08-19 11:43:44 -07:00
CLIClaudeConfig.swift feat(menubar): configure CLAUDE_CONFIG_DIRS via Settings (#434) (#436) 2026-06-06 02:30:46 +02:00
ClinePassSubscriptionService.swift feat(menubar): add native Capacity Dock (#1167) 2026-08-29 00:37:30 -07:00
CLIWatchdog.swift fix(menubar): no-output watchdog, lock signal cleanup, dead-pid takeover, serve orphan reaping 2026-08-23 05:35:17 -07:00
CodeBurnCacheDirectory.swift perf(desktop): share cache state and eliminate duplicate cold hydration 2026-08-12 17:16:41 +03:00
CodexBankedResets.swift feat(codex): notify once when OpenAI banks a limit reset 2026-09-12 14:37:24 -07:00
CodexCredentialStore.swift feat(menubar): add native Capacity Dock (#1167) 2026-08-29 00:37:30 -07:00
CodexSubscriptionService.swift feat(codex): read the per-credit fields the reset-credits payload already carries 2026-09-12 14:37:24 -07:00
CodexUsage.swift feat(codex): read the per-credit fields the reset-credits payload already carries 2026-09-12 14:37:24 -07:00
CopilotExplicitDisconnect.swift fix(mac): preserve explicit Copilot disconnect across refreshes 2026-09-09 16:17:15 +05:30
CopilotHostEndpoint.swift fix(menubar): follow GH_HOST and gh's own host for the Copilot env and gh rungs 2026-09-12 12:02:13 -07:00
CopilotQuotaPresentation.swift feat(menubar): route every user-facing string through a strings catalog 2026-09-12 15:21:49 -07:00
CopilotSubscriptionService.swift fix(menubar): follow GH_HOST and gh's own host for the Copilot env and gh rungs 2026-09-12 12:02:13 -07:00
CursorSubscriptionService.swift fix(menubar): harden the Cursor quota adapter 2026-08-29 14:17:15 -07:00
DataClient.swift fix(menubar): refresh(key:) reported failure instead of joining an in-flight fetch 2026-09-02 07:52:18 -07:00
EarlyQuotaReset.swift fix(mac): say what a usage-drop early reset actually did 2026-09-12 14:58:42 -07:00
EarlyQuotaResetMonitor.swift feat(mac): decide early quota resets in pure, testable types 2026-09-12 14:58:17 -07:00
GeminiQuotaPresentation.swift feat(menubar): live Gemini quota — service, Settings pane, popover Plan tab 2026-08-24 08:43:47 -07:00
GeminiSubscriptionService.swift feat(menubar): add native Capacity Dock (#1167) 2026-08-29 00:37:30 -07:00
GrokBuildSubscriptionService.swift fix(mac): scope Grok's omitted-percent-is-zero rule to unified billing; finish the fixture scrub 2026-09-04 01:38:08 -07:00
KimiQuotaPresentation.swift fix(menubar): keep showing Kimi quota when the login is idle, stamp stale data 2026-07-26 06:35:13 -07:00
KimiSubscriptionService.swift feat(menubar): add native Capacity Dock (#1167) 2026-08-29 00:37:30 -07:00
MenubarPayload.swift Merge origin/main into cache-read and quota pace 2026-09-12 20:27:33 +03:00
MenubarStatusCache.swift perf(desktop): share cache state and eliminate duplicate cold hydration 2026-08-12 17:16:41 +03:00
ProviderConnectionCatalog.swift feat(menubar): route every user-facing string through a strings catalog 2026-09-12 15:21:49 -07:00
ProviderReconnectPresentation.swift feat(menubar): route every user-facing string through a strings catalog 2026-09-12 15:21:49 -07:00
ProviderStripPagingState.swift harden provider period and cache contracts 2026-09-02 16:18:05 +05:30
QuotaPace.swift menubar: linear pace on Codex quota windows — deficit/reserve, projection, run-out ETA (#726) (#728) 2026-07-20 05:21:43 -07:00
QuotaPacePresentation.swift fix(menubar): stop the dock resizing and claiming a refresh it is not doing 2026-09-12 12:19:29 -07:00
QuotaSummary.swift feat(menubar): route every user-facing string through a strings catalog 2026-09-12 15:21:49 -07:00
ServeConnection.swift fix(menubar): no-output watchdog, lock signal cleanup, dead-pid takeover, serve orphan reaping 2026-08-23 05:35:17 -07:00
SubscriptionRefreshCadence.swift feat(menubar): route every user-facing string through a strings catalog 2026-09-12 15:21:49 -07:00
SubscriptionSnapshotStore.swift perf(desktop): share cache state and eliminate duplicate cold hydration 2026-08-12 17:16:41 +03:00
SubscriptionUsage.swift fix(menubar): provider-correct plan tab copy; surface model-scoped weekly limits 2026-07-02 19:37:51 +02:00
UpdateChecker.swift feat(menubar): route every user-facing string through a strings catalog 2026-09-12 15:21:49 -07:00
UpdateNotifier.swift feat(mac): notify when an update is available 2026-09-10 12:39:38 -07:00
UsageDataChangeGuard.swift docs(dsh): finish the provider registration checklist 2026-08-17 10:59:58 -07:00
UsageRefreshCadence.swift feat(menubar): route every user-facing string through a strings catalog 2026-09-12 15:21:49 -07:00
ZaiSubscriptionService.swift fix(mac): map Z.ai body auth errors 2026-08-31 13:51:46 -03:00