Unify styles
This commit is contained in:
@@ -81,10 +81,10 @@ func (d *DetailsViewer) View() string {
|
||||
// Title bar
|
||||
titleStyle := lipgloss.NewStyle().
|
||||
Bold(true).
|
||||
Foreground(lipgloss.Color("252"))
|
||||
Foreground(d.common.Styles.Palette.Text.GetForeground())
|
||||
|
||||
helpStyle := lipgloss.NewStyle().
|
||||
Foreground(lipgloss.Color("240"))
|
||||
Foreground(d.common.Styles.Palette.Muted.GetForeground())
|
||||
|
||||
header := lipgloss.JoinHorizontal(
|
||||
lipgloss.Left,
|
||||
@@ -96,7 +96,7 @@ func (d *DetailsViewer) View() string {
|
||||
// Container style
|
||||
containerStyle := lipgloss.NewStyle().
|
||||
Border(lipgloss.RoundedBorder()).
|
||||
BorderForeground(lipgloss.Color("240")).
|
||||
BorderForeground(d.common.Styles.Palette.Border.GetForeground()).
|
||||
Padding(0, 1).
|
||||
Width(d.width).
|
||||
Height(d.height)
|
||||
@@ -104,7 +104,7 @@ func (d *DetailsViewer) View() string {
|
||||
// Optional: highlight border when focused (for future interactivity)
|
||||
if d.focused {
|
||||
containerStyle = containerStyle.
|
||||
BorderForeground(lipgloss.Color("86"))
|
||||
BorderForeground(d.common.Styles.Palette.Accent.GetForeground())
|
||||
}
|
||||
|
||||
content := lipgloss.JoinVertical(
|
||||
|
||||
@@ -90,7 +90,22 @@ func New(
|
||||
delegate.ShowDescription = false
|
||||
delegate.SetSpacing(0)
|
||||
|
||||
// Update Styles
|
||||
delegate.Styles.NormalTitle = lipgloss.NewStyle().Foreground(c.Styles.Palette.Text.GetForeground())
|
||||
delegate.Styles.SelectedTitle = lipgloss.NewStyle().Foreground(c.Styles.Palette.Accent.GetForeground()).Bold(true).PaddingLeft(2)
|
||||
delegate.Styles.NormalDesc = lipgloss.NewStyle().Foreground(c.Styles.Palette.Muted.GetForeground())
|
||||
delegate.Styles.SelectedDesc = lipgloss.NewStyle().Foreground(c.Styles.Palette.Accent.GetForeground()).PaddingLeft(2)
|
||||
delegate.Styles.FilterMatch = lipgloss.NewStyle().Foreground(c.Styles.Palette.Secondary.GetForeground()).Underline(true)
|
||||
|
||||
l := list.New([]list.Item{}, delegate, 0, 0)
|
||||
l.Styles.FilterPrompt = lipgloss.NewStyle().Foreground(c.Styles.Palette.Accent.GetForeground())
|
||||
l.Styles.FilterCursor = lipgloss.NewStyle().Foreground(c.Styles.Palette.Accent.GetForeground())
|
||||
|
||||
// Ensure the filter input text is readable (using Text color instead of potentially inheriting something else)
|
||||
l.FilterInput.TextStyle = lipgloss.NewStyle().Foreground(c.Styles.Palette.Text.GetForeground())
|
||||
l.FilterInput.PromptStyle = l.Styles.FilterPrompt
|
||||
l.FilterInput.CursorStyle = l.Styles.FilterCursor
|
||||
|
||||
l.SetShowTitle(false)
|
||||
l.SetShowHelp(false)
|
||||
l.SetShowStatusBar(false)
|
||||
|
||||
@@ -530,7 +530,7 @@ func (m *Model) renderRow(r int) string {
|
||||
if m.rows[r].IsGap {
|
||||
gapText := m.rows[r].GetString("gap_display")
|
||||
gapStyle := lipgloss.NewStyle().
|
||||
Foreground(lipgloss.Color("240")).
|
||||
Foreground(m.common.Styles.Palette.Muted.GetForeground()).
|
||||
Align(lipgloss.Center).
|
||||
Width(m.Width())
|
||||
return gapStyle.Render(gapText)
|
||||
|
||||
Reference in New Issue
Block a user