From 370cb5b5d39c33b68d33e2ec28d45ee4e13ba538 Mon Sep 17 00:00:00 2001 From: Silvin Lubecki Date: Sat, 24 Jan 2026 15:38:48 +0100 Subject: [PATCH] fix(tui): use innerWidth for horizontal sidebar The horizontal sidebar received the full terminal width instead of innerWidth (minus app padding), causing content overflow on narrow terminals where the Context percentage would get truncated. Assisted-By: cagent --- pkg/tui/page/chat/chat.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/tui/page/chat/chat.go b/pkg/tui/page/chat/chat.go index e4b592144..81eeaedc8 100644 --- a/pkg/tui/page/chat/chat.go +++ b/pkg/tui/page/chat/chat.go @@ -555,7 +555,7 @@ func (p *chatPage) SetSize(width, height int) tea.Cmd { p.chatHeight = max(1, height-actualEditorHeight-horizontalSidebarHeight-2) // -1 for resize handle, -1 for empty line before status bar p.sidebar.SetMode(sidebar.ModeHorizontal) cmds = append(cmds, - p.sidebar.SetSize(width, horizontalSidebarHeight), + p.sidebar.SetSize(innerWidth, horizontalSidebarHeight), p.sidebar.SetPosition(styles.AppPaddingLeft, 0), p.messages.SetPosition(0, horizontalSidebarHeight), )