Commit 7a36421
committed
fix(tui): use alternate screen buffer for login screen
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.1 parent 9b00df4 commit 7a36421
1 file changed
Lines changed: 189 additions & 246 deletions
0 commit comments