fix(tui): stop full-screen redraw on input and slash panel toggle (#1188)

Remove the global clear-on-shrink setting so typing in the input box and opening or closing the slash panel no longer trigger a full-screen redraw.
This commit is contained in:
liruifengv 2026-06-29 13:51:31 +08:00 committed by GitHub
parent 97f9263c6f
commit db5fbc53c0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 5 additions and 5 deletions

View file

@ -0,0 +1,5 @@
---
"@moonshot-ai/kimi-code": patch
---
Fix unnecessary full-screen redraws when typing in the input box or toggling the slash panel.

View file

@ -60,11 +60,6 @@ export function createTUIState(options: KimiTUIOptions): TUIState {
const terminal = new ProcessTerminal();
const ui = new TUI(terminal);
// Content shrinks (e.g. a tall inline image is replaced by a short
// placeholder or text) can leave stale rows behind because pi-tui's
// differential renderer does not clear them by default. Enable clearing so
// artifacts like duplicated input boxes do not accumulate.
ui.setClearOnShrink(true);
const transcriptContainer = new GutterContainer(CHROME_GUTTER, CHROME_GUTTER);
const activityContainer = new GutterContainer(CHROME_GUTTER, CHROME_GUTTER);