docs: update meta files for multi-theme system session
This commit is contained in:
parent
ff2d354219
commit
54edb43e8b
8 changed files with 60 additions and 8 deletions
|
|
@ -46,13 +46,13 @@
|
|||
- Layout store persists to SQLite on every addPane/removePane/setPreset/setPaneGroup change (fire-and-forget). Restores on app startup via `restoreFromDb()`.
|
||||
- Session groups: Pane.group? field in layout store, group_name column in sessions table, collapsible group headers in sidebar. Right-click pane to set group.
|
||||
- File watcher uses notify crate v6, watches parent directory (NonRecursive), emits `file-changed` Tauri events.
|
||||
- Settings use key-value `settings` table in SQLite (session.rs). Frontend: `settings-bridge.ts` adapter. v3 uses SettingsTab.svelte (v2 SettingsDialog.svelte deleted in P10). SettingsTab has two sections: Global (theme flavor, default shell, default CWD — persisted via settings-bridge) and Group/Project CRUD.
|
||||
- Settings use key-value `settings` table in SQLite (session.rs). Frontend: `settings-bridge.ts` adapter. v3 uses SettingsTab.svelte (v2 SettingsDialog.svelte deleted in P10). SettingsTab has two sections: Global (theme selector with optgroup by theme group, default shell, default CWD — persisted via settings-bridge) and Group/Project CRUD.
|
||||
- Notifications use ephemeral toast system: `notifications.svelte.ts` store (max 5, 4s auto-dismiss), `ToastContainer.svelte` display. Agent dispatcher emits toasts on agent complete/error/crash.
|
||||
- StatusBar component shows active group name, project count, agent count, tokens, cost. Uses workspace store (v3 rewrite, no longer uses layout store).
|
||||
- Agent tree (AgentTree.svelte) uses SVG with recursive layout. Tree data built by `agent-tree.ts` utility from agent messages.
|
||||
- ctx integration opens `~/.claude-context/context.db` as SQLITE_OPEN_READ_ONLY — never writes. CtxDb uses Option<Connection> for graceful absence if DB doesn't exist.
|
||||
- SSH sessions spawn TerminalPane with shell=/usr/bin/ssh and args array. No SSH library needed — PTY handles it natively.
|
||||
- Theme flavors (Latte/Frappe/Macchiato/Mocha) override CSS variables at runtime. Open terminals hot-swap via onThemeChange() callback registry in theme.svelte.ts.
|
||||
- Theme system: 11 themes (4 Catppuccin + 7 editor: VSCode Dark+, Atom One Dark, Monokai, Dracula, Nord, Solarized Dark, GitHub Dark). All map to same 26 --ctp-* CSS custom properties — zero component changes needed. ThemeId replaces CatppuccinFlavor. getCurrentTheme()/setTheme() are primary API (deprecated wrappers exist). THEME_LIST has ThemeMeta with group metadata for optgroup UI. Open terminals hot-swap via onThemeChange() callback registry in theme.svelte.ts.
|
||||
- Detached pane mode: App.svelte checks URL param `?detached=1` and renders a single pane without sidebar/grid chrome. Used for pop-out windows.
|
||||
- Shiki syntax highlighting uses lazy singleton pattern (avoid repeated WASM init). 13 languages preloaded. Used in MarkdownPane and AgentPane text messages.
|
||||
- Cargo workspace at v2/ level: members = [src-tauri, bterminal-core, bterminal-relay]. Cargo.lock is at workspace root (v2/), not in src-tauri/.
|
||||
|
|
|
|||
11
CHANGELOG.md
11
CHANGELOG.md
|
|
@ -8,7 +8,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|||
## [Unreleased]
|
||||
|
||||
### Added
|
||||
- SettingsTab global settings section: theme flavor dropdown (Catppuccin 4 flavors), default shell input, default CWD input — all persisted via settings-bridge (getSetting/setSetting), loaded on mount
|
||||
- Multi-theme system: 7 new editor themes (VSCode Dark+, Atom One Dark, Monokai, Dracula, Nord, Solarized Dark, GitHub Dark) alongside 4 Catppuccin flavors — total 11 themes across 2 groups
|
||||
- `ThemeId` union type, `ThemePalette` (26-color interface), `ThemeMeta` (id/label/group/isDark), `THEME_LIST` registry with group metadata, `ALL_THEME_IDS` for validation
|
||||
- Theme store `getCurrentTheme()`/`setTheme()` as primary API; deprecated `getCurrentFlavor()`/`setFlavor()` wrappers for backwards compat
|
||||
- SettingsTab theme selector with `<optgroup>` grouping (Catppuccin, Editor groups)
|
||||
- SettingsTab global settings section: theme selector, default shell input, default CWD input — all persisted via settings-bridge (getSetting/setSetting), loaded on mount
|
||||
- v3 Mission Control (All Phases 1-10 complete): multi-project dashboard with project groups, per-project Claude sessions, team agents panel, terminal tabs, workspace tabs (Sessions/Docs/Context/Settings)
|
||||
- v3 session continuity (P6): `persistSessionForProject()` saves agent state + messages to SQLite on session complete; `registerSessionProject()` maps session to project; `ClaudeSession.restoreMessagesFromRecords()` restores cached messages on mount
|
||||
- v3 workspace teardown (P7): `clearAllAgentSessions()` clears agent sessions on group switch; terminal tabs reset via `switchGroup()`
|
||||
|
|
@ -29,7 +33,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|||
- Claude CLI path auto-detection: `findClaudeCli()` in both sidecar runners checks common paths (~/.local/bin/claude, ~/.claude/local/claude, /usr/local/bin/claude, /usr/bin/claude) then falls back to `which`/`where`; resolved path passed to SDK via `pathToClaudeCodeExecutable` option
|
||||
- Early error reporting when Claude CLI is not found — sidecar emits `agent_error` immediately instead of cryptic SDK failure
|
||||
|
||||
### Changed
|
||||
- Theme system generalized from Catppuccin-only to multi-theme: all 11 themes map to same `--ctp-*` CSS custom properties (26 vars) — zero component-level changes needed
|
||||
- `CatppuccinFlavor` type deprecated in favor of `ThemeId`; `CatppuccinPalette` deprecated in favor of `ThemePalette`; `FLAVOR_LABELS` and `ALL_FLAVORS` deprecated in favor of `THEME_LIST` and `ALL_THEME_IDS`
|
||||
|
||||
### Fixed
|
||||
- SettingsTab input overflow: added `min-width: 0` on `.setting-row` to prevent flex children from overflowing container
|
||||
- SettingsTab a11y: project field labels changed from `<div><label>` to wrapping `<label><span class="field-label">` pattern for proper label/input association
|
||||
- SettingsTab CSS: removed unused `.project-field label` selector, simplified input selector to `.project-field input:not([type="checkbox"])`
|
||||
|
||||
|
|
|
|||
|
|
@ -64,8 +64,8 @@ Terminal emulator with SSH and Claude Code session management. v1 (GTK3+VTE Pyth
|
|||
| `v2/src/lib/utils/detach.ts` | Detached pane mode (pop-out windows via URL params) |
|
||||
| `v2/src/lib/utils/updater.ts` | Tauri auto-updater utility |
|
||||
| `v2/src/lib/stores/notifications.svelte.ts` | Toast notification store (notify, dismiss) |
|
||||
| `v2/src/lib/stores/theme.svelte.ts` | Theme flavor store (Catppuccin 4 flavors) |
|
||||
| `v2/src/lib/styles/themes.ts` | Catppuccin palette definitions (Latte/Frappe/Macchiato/Mocha) |
|
||||
| `v2/src/lib/stores/theme.svelte.ts` | Theme store (11 themes: 4 Catppuccin + 7 editor themes) |
|
||||
| `v2/src/lib/styles/themes.ts` | Theme palette definitions, ThemeId/ThemePalette/ThemeMeta types, THEME_LIST |
|
||||
| `v2/src/lib/components/Agent/AgentTree.svelte` | SVG agent tree visualization |
|
||||
| `v2/src/lib/components/Context/ContextPane.svelte` | ctx database viewer (projects, entries, search) |
|
||||
| `v2/src/lib/components/StatusBar/StatusBar.svelte` | Global status bar (group name, project count, agent count, cost) |
|
||||
|
|
@ -132,7 +132,7 @@ cd v2/src-tauri && cargo test # Cargo tests (backend)
|
|||
|
||||
## Conventions
|
||||
|
||||
- Catppuccin Mocha theme for all UI elements
|
||||
- 11 themes: 4 Catppuccin (Mocha default) + 7 editor themes (VSCode Dark+, Atom One Dark, Monokai, Dracula, Nord, Solarized Dark, GitHub Dark)
|
||||
- Session configs stored as JSON
|
||||
- Single-file Python app (v1) — will change to multi-file Rust+Svelte (v2)
|
||||
- Polish language in some code comments (v1 legacy)
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
Terminal with session panel (MobaXterm-style), built with GTK 3 + VTE. Catppuccin Mocha theme.
|
||||
|
||||
> **v2 complete, v3 all phases complete.** v2: Multi-session Claude agent dashboard using Tauri 2.x + Svelte 5. v3: Multi-project mission control dashboard (All Phases 1-10 complete) -- project groups with per-project Claude sessions, session continuity (persist/restore agent messages), team agents panel, terminal tabs, workspace tabs (Sessions/Docs/Context/Settings), command palette with group switching. Features: **project groups** (up to 5 projects per group, horizontal layout, adaptive viewport count), **per-project Claude sessions** with session continuity, **team agents panel** (compact subagent cards), **terminal tabs** (shell/SSH/agent per project), agent panes with structured output, tree visualization with subtree cost and session resume, **subagent/agent-teams support**, **multi-machine support** (bterminal-relay WebSocket server + RemoteManager), **Claude profile/account switching** (switcher-claude integration), **skill discovery and autocomplete** (type `/` in agent prompt), SSH session management, ctx context database viewer, SQLite session persistence with layout restore, live markdown file viewer with Shiki syntax highlighting, Catppuccin themes (4 flavors), .deb + AppImage packaging, GitHub Actions CI, 138 vitest + 36 cargo tests. Branch `v2-mission-control`. See [docs/v3-task_plan.md](docs/v3-task_plan.md) for v3 architecture.
|
||||
> **v2 complete, v3 all phases complete.** v2: Multi-session Claude agent dashboard using Tauri 2.x + Svelte 5. v3: Multi-project mission control dashboard (All Phases 1-10 complete) -- project groups with per-project Claude sessions, session continuity (persist/restore agent messages), team agents panel, terminal tabs, workspace tabs (Sessions/Docs/Context/Settings), command palette with group switching. Features: **project groups** (up to 5 projects per group, horizontal layout, adaptive viewport count), **per-project Claude sessions** with session continuity, **team agents panel** (compact subagent cards), **terminal tabs** (shell/SSH/agent per project), agent panes with structured output, tree visualization with subtree cost and session resume, **subagent/agent-teams support**, **multi-machine support** (bterminal-relay WebSocket server + RemoteManager), **Claude profile/account switching** (switcher-claude integration), **skill discovery and autocomplete** (type `/` in agent prompt), SSH session management, ctx context database viewer, SQLite session persistence with layout restore, live markdown file viewer with Shiki syntax highlighting, 11 themes (4 Catppuccin + 7 editor themes: VSCode Dark+, Atom One Dark, Monokai, Dracula, Nord, Solarized Dark, GitHub Dark), .deb + AppImage packaging, GitHub Actions CI, 138 vitest + 36 cargo tests. Branch `v2-mission-control`. See [docs/v3-task_plan.md](docs/v3-task_plan.md) for v3 architecture.
|
||||
|
||||

|
||||
|
||||
|
|
|
|||
2
TODO.md
2
TODO.md
|
|
@ -10,6 +10,7 @@
|
|||
|
||||
## Completed
|
||||
|
||||
- [x] **Multi-theme system** -- 7 editor themes (VSCode Dark+, Atom One Dark, Monokai, Dracula, Nord, Solarized Dark, GitHub Dark) + 4 Catppuccin. ThemeId/ThemePalette/ThemeMeta types, THEME_LIST, optgroup selector. | Done: 2026-03-07
|
||||
- [x] **v3 Phases 6-10 Complete** -- Session continuity (persist/restore agent messages), workspace teardown on group switch, dead v2 component removal (~1,836 lines), StatusBar rewrite, subagent routing fix. | Done: 2026-03-07
|
||||
- [x] **v3 Mission Control MVP (Phases 1-5)** -- Data model + groups.rs + workspace store + 12 Workspace components + App.svelte rewrite + ClaudeSession + TerminalTabs + TeamAgentsPanel. 138 vitest + 36 cargo tests. | Done: 2026-03-07
|
||||
- [x] **v3 Architecture planning** -- Adversarial review (3 agents, 12 issues resolved), final architecture in docs/v3-task_plan.md. | Done: 2026-03-07
|
||||
|
|
@ -19,4 +20,3 @@
|
|||
- [x] **AgentPane onDestroy bug fix** -- Stop-on-close moved to TilingGrid onClose. | Done: 2026-03-06
|
||||
- [x] **Sidecar SDK migration** -- @anthropic-ai/claude-agent-sdk query(). | Done: 2026-03-06
|
||||
- [x] **Multi-machine support (Phases A-D)** -- bterminal-core, bterminal-relay, RemoteManager, frontend. | Done: 2026-03-06
|
||||
- [x] **Multi-machine reconnection** -- Exponential backoff, TCP probe, auto-reconnect. | Done: 2026-03-06
|
||||
|
|
|
|||
|
|
@ -242,6 +242,19 @@
|
|||
#### Verification
|
||||
- All 138 vitest + 36 cargo tests pass, vite build succeeds
|
||||
|
||||
### Session: 2026-03-07 (continued) — Multi-Theme System
|
||||
|
||||
#### Theme System Generalization (7 Editor Themes)
|
||||
- [x] Generalized CatppuccinFlavor to ThemeId union type (11 themes)
|
||||
- [x] Added 7 editor themes: VSCode Dark+, Atom One Dark, Monokai, Dracula, Nord, Solarized Dark, GitHub Dark
|
||||
- [x] Added ThemePalette, ThemeMeta, THEME_LIST types; deprecated old Catppuccin-only types
|
||||
- [x] Theme store: getCurrentTheme()/setTheme() with deprecated wrappers for backwards compat
|
||||
- [x] SettingsTab: optgroup-based theme selector, fixed input overflow with min-width:0
|
||||
- [x] All themes map to same --ctp-* CSS vars — zero component changes needed
|
||||
|
||||
#### Verification
|
||||
- All 138 vitest + 35 cargo tests pass
|
||||
|
||||
### Next Steps
|
||||
- [ ] Real-world relay testing (2 machines)
|
||||
- [ ] TLS/certificate pinning for relay connections
|
||||
|
|
|
|||
|
|
@ -99,3 +99,32 @@
|
|||
#### Rust Cleanup (committed separately)
|
||||
- [x] Removed dead `update_ssh_session()` method from session.rs and its test
|
||||
- [x] Fixed stale TilingGrid comment in AgentPane.svelte
|
||||
|
||||
### Session: 2026-03-07 — Multi-Theme System (7 Editor Themes)
|
||||
|
||||
#### Theme System Generalization
|
||||
- [x] Generalized `CatppuccinFlavor` type to `ThemeId` union type (11 values)
|
||||
- [x] Added 7 new editor themes: VSCode Dark+, Atom One Dark, Monokai, Dracula, Nord, Solarized Dark, GitHub Dark
|
||||
- [x] Added `ThemePalette` interface (26-color slots) — all themes map to same slots
|
||||
- [x] Added `ThemeMeta` interface (id, label, group, isDark) for UI metadata
|
||||
- [x] Added `THEME_LIST: ThemeMeta[]` with group metadata ('Catppuccin' or 'Editor')
|
||||
- [x] Added `ALL_THEME_IDS: ThemeId[]` derived from THEME_LIST for validation
|
||||
- [x] Deprecated `CatppuccinFlavor`, `CatppuccinPalette`, `FLAVOR_LABELS`, `ALL_FLAVORS` (kept as backwards compat aliases)
|
||||
|
||||
#### Theme Store Updates
|
||||
- [x] `getCurrentTheme(): ThemeId` replaces `getCurrentFlavor()` as primary getter
|
||||
- [x] `setTheme(theme: ThemeId)` replaces `setFlavor()` as primary setter
|
||||
- [x] `initTheme()` validates saved theme against `ALL_THEME_IDS`
|
||||
- [x] Deprecated `getCurrentFlavor()` and `setFlavor()` with delegation wrappers
|
||||
|
||||
#### SettingsTab Theme Selector
|
||||
- [x] Theme dropdown uses `<optgroup>` per theme group (Catppuccin, Editor)
|
||||
- [x] `themeGroups` derived from `THEME_LIST` using Map grouping
|
||||
- [x] `handleThemeChange()` replaces direct `setFlavor()` call
|
||||
- [x] Fixed input overflow in `.setting-row` with `min-width: 0`
|
||||
|
||||
#### Design Decision
|
||||
All editor themes map to the same `--ctp-*` CSS custom property names (26 vars). This means every component works unchanged — no component-level theme awareness needed. Each theme provides its own mapping of colors to the 26 semantic slots.
|
||||
|
||||
#### Verification
|
||||
- All 138 vitest + 35 cargo tests pass
|
||||
|
|
|
|||
|
|
@ -388,6 +388,7 @@ No sidecar changes needed for v3.0.
|
|||
| Keyboard shortcut layers: App > Workspace > Terminal | Prevents conflicts. Terminal captures raw keys only when focused. App layer uses Ctrl+K/G. | 2026-03-07 |
|
||||
| AgentPane splits into ClaudeSession + TeamAgentsPanel | Team agents shown inline in right panel, not as separate panes. Saves xterm/pane slots. | 2026-03-07 |
|
||||
| Unmount/remount on group switch | Serialize xterm scrollbacks, destroy, remount new group. <100ms perceived. Frees ~80MB. | 2026-03-07 |
|
||||
| All themes map to --ctp-* CSS vars | 7 editor themes (VSCode Dark+, Atom One Dark, Monokai, Dracula, Nord, Solarized Dark, GitHub Dark) added alongside 4 Catppuccin. All map to same 26 --ctp-* CSS custom properties — zero component changes needed. | 2026-03-07 |
|
||||
|
||||
## Errors Encountered
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue