styles

package
v0.12.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 19, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const ModalMinWidth = 44

Variables

View Source
var (
	Colors = struct {
		Primary color.Color
		Green   color.Color
		Red     color.Color
		Cyan    color.Color
		Yellow  color.Color
		Blue    color.Color
		Pink    color.Color
		Purple  color.Color
		White   color.Color
		Muted   color.Color
		Black   color.Color
		Dim     color.Color
	}{
		Primary: lipgloss.Color("#65adff"),
		Green:   lipgloss.Color("#6fcc85"),
		Red:     lipgloss.Color("#ff7079"),
		Cyan:    lipgloss.Color("#11d4b7"),
		Yellow:  lipgloss.Color("#f5b41d"),
		Blue:    lipgloss.Color("#65adff"),
		Pink:    lipgloss.Color("#f67396"),
		Purple:  lipgloss.Color("#ca8aef"),
		White:   lipgloss.Color("#ffffff"),
		Muted:   lipgloss.Color("#868a91"),
		Black:   lipgloss.Color("#111317"),
		Dim:     lipgloss.Color("#363a41"),
	}
)
View Source
var (
	Help = help.Styles{
		ShortKey:       keyStyle,
		ShortDesc:      descStyle,
		ShortSeparator: sepStyle,
		Ellipsis:       sepStyle,
		FullKey:        keyStyle,
		FullDesc:       descStyle,
		FullSeparator:  sepStyle,
	}
)
View Source
var ThemeOptions = []ThemeOption{
	{"blue", Colors.Blue},
	{"red", Colors.Red},
	{"amber", Colors.Yellow},
	{"green", Colors.Green},
	{"teal", Colors.Cyan},
	{"purple", Colors.Purple},
	{"pink", Colors.Pink},
}

Functions

func B

func B(s string) string

func BC

func BC(c color.Color, s string) string

func C

func C(c color.Color, s string) string

func Dim added in v0.12.0

func Dim(s string) string

func Frame added in v0.12.0

func Frame(accent color.Color, title, body string) string

func IsValidTheme added in v0.12.0

func IsValidTheme(s string) bool
func Modal(width, height int, under, body string) string

func ModalBody added in v0.12.0

func ModalBody(accent color.Color, title string, rows ...string) string

func Table added in v0.12.0

func Table(sections ...TableSection) string

func Theme added in v0.12.0

func Theme(name string) color.Color

func U

func U(s string) string

func UC

func UC(c color.Color, s string) string

Types

type TableSection added in v0.12.0

type TableSection struct {
	Label color.Color
	Rows  [][2]string
}

type ThemeOption added in v0.12.0

type ThemeOption struct {
	Name  string
	Color color.Color
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL