Skip to content

fix(tui): always start the sidebar closed - #117

Merged
quickbeard merged 1 commit into
mainfrom
sidebar-always-closed
Jul 21, 2026
Merged

quickbeard merged 1 commit into
mainfrom
sidebar-always-closed

Conversation

@quickbeard

Copy link
Copy Markdown
Owner

Summary

The TUI right sidebar starts hidden in this fork, but toggling it open wrote "auto" into the persisted kv store (kv.json), so the next session on a terminal wider than 120 columns started with the sidebar open. This removes the persisted sidebar kv signal entirely: visibility is now driven only by the session-local sidebarOpen signal, so every session starts with the sidebar closed and ctrl+b/<leader>b only affects the current session.

  • packages/tui/src/routes/session/index.tsx: drop kv.signal("sidebar", …), simplify sidebarVisible and the toggle command; stale sidebar keys in existing kv.json files are simply never read (no migration needed)
  • DIVERGENCES.md: updated the existing sidebar row for this file (supersedes the "auto" → "hide" default divergence)
  • CHANGELOG.md: Unreleased entry
  • packages/tui/test/sidebar-hint.view.test.tsx: reworded a comment referencing the old persistence

Test plan

  • bun typecheck in packages/tui passes
  • bun test test/sidebar-hint.view.test.tsx (exercises the toggle path) passes
  • Manual: seeded kv.json with "sidebar":"auto", launched the TUI at 130 columns — sidebar starts closed; ctrl+b opens it; after quit + relaunch into the same session it starts closed again

🤖 Generated with Claude Code

The ctrl+b toggle persisted "auto" into kv.json, so a new session on a
terminal wider than 120 columns reopened the sidebar. Remove the
persisted sidebar kv signal; visibility is driven only by the
session-local sidebarOpen signal.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@quickbeard
quickbeard merged commit 4677d89 into main Jul 21, 2026
0 of 5 checks passed
@quickbeard
quickbeard deleted the sidebar-always-closed branch July 21, 2026 03:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant