clean(desktop): tighten hover-reveal pane code

KISS pass — flatten the translate ternary, derive a single `revealed`,
inline the edge style, drop the redundant set-guard, and trim comments to
the house one-liner style. No behavior change.
This commit is contained in:
Brooklyn Nicholson
2026-06-07 20:37:31 -05:00
parent 27df0959aa
commit 3136cf7bfd
3 changed files with 26 additions and 53 deletions
+2 -5
View File
@@ -55,8 +55,7 @@ export const $sidebarWidth: ReadableAtom<number> = computed($paneStates, states
export const $pinnedSessionIds = atom(storedStringArray(SIDEBAR_PINNED_STORAGE_KEY))
export const $sidebarPinsOpen = atom(true)
// Set by the PaneShell hover-reveal overlay while the collapsed sidebar is
// floated over content. ChatSidebar treats `sidebarOpen || sidebarRevealed` as
// "show my full self" so session rows render in the overlay too.
// floated over content; ChatSidebar gates its rows on `sidebarOpen || this`.
export const $sidebarRevealed = atom(false)
export const $sidebarRecentsOpen = atom(true)
// Cron-job sessions live in their own section below recents, collapsed by
@@ -121,9 +120,7 @@ export function setSidebarPinsOpen(open: boolean) {
}
export function setSidebarRevealed(revealed: boolean) {
if ($sidebarRevealed.get() !== revealed) {
$sidebarRevealed.set(revealed)
}
$sidebarRevealed.set(revealed)
}
export function setSidebarRecentsOpen(open: boolean) {