Align debug pane with columns

This commit is contained in:
Salastil
2025-11-23 00:16:24 -05:00
parent 6bf9f35f8d
commit 4cb7bd5945
2 changed files with 8 additions and 9 deletions

View File

@@ -169,12 +169,12 @@ func (m Model) View() string {
} }
func (m Model) renderMainView() string { func (m Model) renderMainView() string {
cols := lipgloss.JoinHorizontal( gap := lipgloss.NewStyle().MarginRight(1)
lipgloss.Top, sportsCol := gap.Render(m.sports.View(m.styles, m.focus == focusSports))
m.sports.View(m.styles, m.focus == focusSports), matchesCol := gap.Render(m.matches.View(m.styles, m.focus == focusMatches))
m.matches.View(m.styles, m.focus == focusMatches), streamsCol := m.streams.View(m.styles, m.focus == focusStreams)
m.streams.View(m.styles, m.focus == focusStreams),
) cols := lipgloss.JoinHorizontal(lipgloss.Top, sportsCol, matchesCol, streamsCol)
colsWidth := lipgloss.Width(cols) colsWidth := lipgloss.Width(cols)
debugPane := m.renderDebugPane(colsWidth) debugPane := m.renderDebugPane(colsWidth)
status := m.renderStatusLine() status := m.renderStatusLine()

View File

@@ -24,12 +24,11 @@ func NewStyles() Styles {
border := lipgloss.RoundedBorder() border := lipgloss.RoundedBorder()
return Styles{ return Styles{
Title: lipgloss.NewStyle().Bold(true).Foreground(lipgloss.Color("12")), Title: lipgloss.NewStyle().Bold(true).Foreground(lipgloss.Color("12")),
Box: lipgloss.NewStyle().Border(border).Padding(0, 1).MarginRight(1), Box: lipgloss.NewStyle().Border(border).Padding(0, 1),
Active: lipgloss.NewStyle(). Active: lipgloss.NewStyle().
Border(border). Border(border).
BorderForeground(lipgloss.Color("#FA8072")). // Not pink, its Salmon obviously BorderForeground(lipgloss.Color("#FA8072")). // Not pink, its Salmon obviously
Padding(0, 1). Padding(0, 1),
MarginRight(1),
Status: lipgloss.NewStyle().Foreground(lipgloss.Color("8")).MarginTop(1), Status: lipgloss.NewStyle().Foreground(lipgloss.Color("8")).MarginTop(1),
Error: lipgloss.NewStyle().Foreground(lipgloss.Color("9")).Bold(true), Error: lipgloss.NewStyle().Foreground(lipgloss.Color("9")).Bold(true),
Subtle: lipgloss.NewStyle().Foreground(lipgloss.Color("243")), Subtle: lipgloss.NewStyle().Foreground(lipgloss.Color("243")),