The agent that grows with you
Python aiai-agentai-agentsanthropicchatgptclaudeclaude-codecodexhermeshermes-agentllmnous-researchopenai
fix(desktop): status bar shows for every install, including ones that hid it under the old key
Tekniumcca26097c5bd
diff --git a/apps/desktop/src/store/statusbar-prefs.test.ts b/apps/desktop/src/store/statusbar-prefs.test.tsnew file mode 100644index 00000000000..2d41618cd33--- /dev/null+++ b/apps/desktop/src/store/statusbar-prefs.test.ts@@ -0,0 +1,32 @@+import { beforeEach, describe, expect, it, vi } from 'vitest'++const LEGACY_VISIBLE_KEY = 'hermes.desktop.statusbarVisible'++const loadStore = () => import('./statusbar-prefs')++describe('statusbar whole-bar visibility', () => {+ beforeEach(() => {+ window.localStorage.clear()+ vi.resetModules()+ })++ it('shows the bar on a fresh install and for installs that hid it under the v1 key', async () => {+ window.localStorage.setItem(LEGACY_VISIBLE_KEY, 'false')++ const { $statusbarVisible } = await loadStore()++ expect($statusbarVisible.get()).toBe(true)+ })++ it('still honours a hide made after the update', async () => {+ const first = await loadStore()++ first.toggleStatusbarVisible()+ expect(first.$statusbarVisible.get()).toBe(false)++ vi.resetModules()+ const reloaded = await loadStore()++ expect(reloaded.$statusbarVisible.get()).toBe(false)+ })+})diff --git a/apps/desktop/src/store/statusbar-prefs.ts b/apps/desktop/src/store/statusbar-prefs.tsindex a82e91617d6..16fc197353d 100644--- a/apps/desktop/src/store/statusbar-prefs.ts+++ b/apps/desktop/src/store/statusbar-prefs.ts@@ -1,7 +1,11 @@import { Codecs, persistentAtom } from '@/lib/persisted'const STATUSBAR_HIDDEN_STORAGE_KEY = 'hermes.desktop.statusbarHidden'-const STATUSBAR_VISIBLE_STORAGE_KEY = 'hermes.desktop.statusbarVisible'+// v1 (`hermes.desktop.statusbarVisible`) shipped a stretch where the bar was+// opt-in, so many stores hold a `false` the user never chose. v2 is read fresh+// and the v1 key is deliberately NOT seeded from: every existing install comes+// back to "on" once, and hiding it again persists here.+const STATUSBAR_VISIBLE_STORAGE_KEY = 'hermes.desktop.statusbarVisible.v2'// Whole-bar visibility, VS Code's `workbench.statusBar.visible`. On by default.// Hiding it unmounts the bar (its 15s status poll goes with it), so the way back