tui: let the user scroll up while the agent streams + keyboard scroll bindings
ChatPanel._sync called scroll_end on every WS event (every stream_delta),
yanking the view back to the bottom on each token — impossible to scroll up
and read earlier messages during a response. Stick-to-bottom: capture
is_vertical_scroll_end before any DOM change and only scroll_end when the
user was already at the bottom; auto-follow resumes when they scroll back.

Add app-level keyboard bindings so the chat scrolls without leaving the
input box: Ctrl+Shift+Up/Down (one line), Ctrl+End (jump to bottom). These
keys are not claimed by TextArea (it uses shift+up/down for select and
ctrl+e/end for line end), so they bubble from the input to the app.
1 parent 55fa7ae commit 851c7be24526550eea45ed083ec810d5b6fcd17c
@Eugene Sukhodolskiy Eugene Sukhodolskiy authored 11 hours ago
Showing 4 changed files
View
clients/terminal/tui/tui_app.py
View
clients/terminal/tui/widgets/chat_panel.py
View
tests/clients/test_chat_panel.py
View
tests/clients/test_tui_app.py