Skip to content

Ratatui migration#36

Open
Palanikannan1437 wants to merge 8 commits into
mainfrom
ratatui-migration
Open

Ratatui migration#36
Palanikannan1437 wants to merge 8 commits into
mainfrom
ratatui-migration

Conversation

@Palanikannan1437
Copy link
Copy Markdown
Contributor

Right now a freaking pane takes 60-80mbs each, with 6+ sessions and 5+ windows each, it's insane

this pr gets each pane to roughly take 1.5-2mb in memory ;)

Adds docs/ratatui-migration/ with a complete spec for porting apps/tui
(Bun + OpenTUI + Solid) to apps/tui-rs (Rust + Ratatui), targeting an
~85-90% per-process RAM reduction (80 MB → ~10-15 MB) with byte-for-byte
visual parity.

17 ordered docs covering:
- Phased plan + success criteria (01)
- Lightweight crate stack with web-research justification (02)
- Architecture comparison + WS protocol -> serde mapping (03-04)
- State management, layout, components, input handling (05-09)
- Mux integration, config, themes, server bootstrap (10-13)
- Edge cases, testing strategy, distribution, feasibility matrix (14-17)

Reference snapshots (35x56 panes, Catppuccin Mocha):
- 3x .ansi truecolor captures + .txt + .meta + 1 PNG ground truth
- Decoded SGR palette mapped to ThemePalette tokens
- Hardcoded layout invariants for byte-exact reproduction
Comment on lines +8 to +17
KeyModifiers as CrosstermKeyModifiers, MouseButton as CrosstermMouseButton,
MouseEventKind as CrosstermMouseEventKind,
};
use crossterm::execute;
use crossterm::terminal::{
self, Clear, ClearType, EnterAlternateScreen, LeaveAlternateScreen, disable_raw_mode,
enable_raw_mode,
};
use futures_util::StreamExt;
use opensessions_sidebar_protocol::{
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what's this about

Add all remaining user-facing features to reach full parity with the
TypeScript reference sidebar:

- Metadata display: status/progress/logs in detail panel with tone icons
- 20 theme palettes: port all 18 missing themes from themes.ts
- Modal infrastructure: overlay system with key dispatch interception
- Theme picker: searchable list with live preview (t key)
- Kill confirmation: red-bordered confirm modal before killing sessions
- Local links: render session local_links in detail panel
- Session card metadata: optional status+progress summary row
- Port display: port hints on branch row (⌁port or ⌁port+N)
- Dynamic detail panel height: Left/Right keys resize, min 4
- Drag-to-resize: mouse drag on separator to resize detail panel
rs545837 added 2 commits May 23, 2026 17:59
l opens lazydiff in a new tmux window, L opens it in a new terminal
window. Launches in the focused session's working directory.
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.

2 participants