Просмотр исходного кода

tui: fix help dialog background (#110)

Rohan Godha 8 месяцев назад
Родитель
Сommit
c9b4564d36
1 измененных файлов с 3 добавлено и 1 удалено
  1. 3 1
      packages/tui/internal/components/dialog/help.go

+ 3 - 1
packages/tui/internal/components/dialog/help.go

@@ -59,6 +59,8 @@ func (h *helpDialog) View() string {
 	descStyle := lipgloss.NewStyle().
 		Background(t.BackgroundElement()).
 		Foreground(t.TextMuted())
+	contentStyle := lipgloss.NewStyle().
+		PaddingLeft(1).Background(t.BackgroundElement())
 
 	lines := []string{}
 	for _, b := range h.bindings {
@@ -74,7 +76,7 @@ func (h *helpDialog) View() string {
 			}
 		}
 
-		lines = append(lines, content)
+		lines = append(lines, contentStyle.Render(content))
 	}
 
 	return strings.Join(lines, "\n")