blob: d4c75ffcd86c2bebb17175c5fe08f207fd079dc5 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
|
package common
import "github.com/charmbracelet/lipgloss"
var (
// Palette colors shared across the TUI package.
ColorBackground = lipgloss.Color("235")
ColorPanel = lipgloss.Color("238")
ColorPrimary = lipgloss.Color("75")
ColorAccent = lipgloss.Color("222")
ColorMuted = lipgloss.Color("246")
ColorText = lipgloss.Color("255")
ColorDanger = lipgloss.Color("203")
)
var (
// ScreenStyle is the base style for full-screen models.
ScreenStyle = lipgloss.NewStyle().
Foreground(ColorText)
// HeaderStyle is used by top-level titles and screen headers.
HeaderStyle = lipgloss.NewStyle().
Bold(true).
Foreground(ColorPrimary)
// TabActiveStyle is applied to the currently-selected tab.
TabActiveStyle = lipgloss.NewStyle().
Bold(true).
Foreground(ColorBackground).
Background(ColorPrimary).
Padding(0, 1)
// TabInactiveStyle is applied to non-selected tabs.
TabInactiveStyle = lipgloss.NewStyle().
Foreground(ColorMuted).
Padding(0, 1)
// PanelStyle is used for boxed sections.
PanelStyle = lipgloss.NewStyle().
Border(lipgloss.NormalBorder()).
BorderForeground(ColorPanel).
Padding(0, 1)
// HelpBarStyle is used for keybinding hints at the bottom.
HelpBarStyle = lipgloss.NewStyle().
Foreground(ColorMuted).
BorderTop(true).
BorderForeground(ColorPanel)
// HighlightStyle emphasizes inline values.
HighlightStyle = lipgloss.NewStyle().
Bold(true).
Foreground(ColorAccent)
// ErrorStyle is used for fatal or warning messages.
ErrorStyle = lipgloss.NewStyle().
Bold(true).
Foreground(ColorDanger)
)
|