This repository has been archived by the owner on May 29, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2
/
styles.go
93 lines (77 loc) · 3.07 KB
/
styles.go
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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
package main
import (
"github.com/charmbracelet/lipgloss"
"github.com/evertras/bubble-table/table"
)
// Border definition
var (
customBorder = table.Border{
Top: "─",
Left: "│",
Right: "│",
Bottom: "─",
TopRight: "╮",
TopLeft: "╭",
BottomRight: "╯",
BottomLeft: "╰",
TopJunction: "┬",
LeftJunction: "├",
RightJunction: "┤",
BottomJunction: "┴",
InnerJunction: "┼",
InnerDivider: "│",
}
)
var (
catppuccinLatte = map[string]string{
"idColumnStyle": "#8839ef", // mauve
"imageColumnStyle": "#8839ef", // mauve
"headerStyle": "#40a02b", // green
"footerBoxNameStyle": "#e64553", // maroon
"baseStyleBorderFg": "#181825", // mantle (mocha)
"baseStyleFg": "#4c4f69", // text
"highlightStyleBg": "#6c6f85", // subtext0
"highlightStyleFg": "#e6e9ef", // mantle
"titleStyleFg": "#1e66f5", // blue
"subtleStyleFg": "#fe640b", // peach
}
catppuccinMocha = map[string]string{
"idColumnStyle": "#cba6f7", // mauve
"imageColumnStyle": "#cba6f7", // mauve
"headerStyle": "#a6e3a1", // green
"footerBoxNameStyle": "#eba0ac", // maroon
"baseStyleBorderFg": "#313244", // mantle
"baseStyleFg": "#cdd6f4", // text
"highlightStyleBg": "#313244", // subtext0
"highlightStyleFg": "#b4befe", // mantle
"titleStyleFg": "#89b4fa", // blue
"subtleStyleFg": "#fab387", // peach
}
)
var (
idColumnStyle = lipgloss.NewStyle().
Faint(true).
Foreground(lipgloss.AdaptiveColor{Light: catppuccinLatte["idColumnStyle"], Dark: catppuccinMocha["idColumnStyle"]})
imageColumnStyle = lipgloss.NewStyle().
Foreground(lipgloss.AdaptiveColor{Light: catppuccinLatte["imageColumnStyle"], Dark: catppuccinMocha["imageColumnStyle"]}).
Faint(true)
headerStyle = lipgloss.NewStyle().
Foreground(lipgloss.AdaptiveColor{Light: catppuccinLatte["headerStyle"], Dark: catppuccinMocha["headerStyle"]}).
Bold(true)
footerStyle = lipgloss.NewStyle()
footerBoxNameStyle = lipgloss.NewStyle().
Foreground(lipgloss.AdaptiveColor{Light: catppuccinLatte["footerBoxNameStyle"], Dark: catppuccinMocha["footerBoxNameStyle"]}).
Bold(true)
baseStyle = lipgloss.NewStyle().
BorderForeground(lipgloss.AdaptiveColor{Light: catppuccinLatte["baseStyleBorderFg"], Dark: catppuccinMocha["baseStyleBorderFg"]}).
Foreground(lipgloss.AdaptiveColor{Light: catppuccinLatte["baseStyleFg"], Dark: catppuccinMocha["baseStyleFg"]}).
Align(lipgloss.Left)
highlightStyle = lipgloss.NewStyle().
Background(lipgloss.AdaptiveColor{Light: catppuccinLatte["highlightStyleBg"], Dark: catppuccinMocha["highlightStyleBg"]}).
Foreground(lipgloss.AdaptiveColor{Light: catppuccinLatte["highlightStyleFg"], Dark: catppuccinMocha["highlightStyleFg"]})
titleStyle = lipgloss.NewStyle().
Foreground(lipgloss.AdaptiveColor{Light: catppuccinLatte["titleStyleFg"], Dark: catppuccinMocha["titleStyleFg"]}).
Bold(true)
subtleStyle = lipgloss.NewStyle().
Foreground(lipgloss.AdaptiveColor{Light: catppuccinLatte["subtleStyleFg"], Dark: catppuccinMocha["subtleStyleFg"]})
)