xonecas.io
60255
Zn

Zoea-Nova / commit 22cc77f

fix(tui): account for scrollbar width in content rendering

- Subtract scrollbar width (2 chars) from panelContentWidth
- Prevents overflow caused by appending scrollbar to full-width content
- Root cause: content was rendered to full width, then scrollbar added
- Fix: render content 2 chars narrower to make room for scrollbar

xonecas2026-02-05 22cc77fdc2078c94d0e23bd9070eadfc17342aea parent 3658823

1 file changed

internal/tui/app.go+2−1
@@ -641,7 +641,8 @@ func (m *Model) updateViewportContent() {
641641 // Log entries must fill the panel content area exactly.
642642 // Panel is rendered with logStyle.Width(m.width - 2).Padding(0, 2)
643643 // Content width = m.width - 2, minus 4 for padding (2 each side) = m.width - 6
644- panelContentWidth := m.width - 6
644+ // Scrollbar adds 2 chars (space + scrollbar char), so subtract that too
645+ panelContentWidth := m.width - 6 - 2 // -2 for scrollbar
645646
646647 var lines []string
647648 for _, entry := range m.logs {