Commit b1b54bf
fix(tui): use alternate screen buffer for login screen (#492)
This fixes the issue where the login screen would spam 'Welcome to Cortex
CLI' messages on some Ubuntu terminals instead of properly rendering the
interactive TUI.
The root cause was that the inline rendering approach using cursor escape
sequences (MoveUp/MoveDown) was not reliable across all terminal emulators.
Some terminals don't properly support these cursor control sequences,
especially in SSH sessions or with certain terminal multiplexer
configurations.
Solution: Refactored the login screen to use ratatui with the alternate
screen buffer, similar to how the trust screen already works. This approach:
- Uses EnterAlternateScreen for reliable full-screen rendering
- Leverages ratatui's proper terminal abstraction
- Works consistently across all terminal emulators
- Prevents content from leaking to the scrollback buffer
Fixes rendering issues on Ubuntu terminals where cursor escape sequences
were not properly interpreted.
Co-authored-by: Droid Agent <droid@factory.ai>1 parent 9b00df4 commit b1b54bf
1 file changed
Lines changed: 189 additions & 246 deletions
0 commit comments