// Package style provide display coloring
package style import ( ) var ( Default = "" Black = "black" Red = "red" Green = "green" Yellow = "yellow" Blue = "blue" Magenta = "magenta" Cyan = "cyan" White = "white" BrightBlack = "bright-black" BrightRed = "bright-red" BrightGreen = "bright-green" BrightYellow = "bright-yellow" BrightBlue = "bright-blue" BrightMagenta = "bright-magenta" BrightCyan = "bright-cyan" BrightWhite = "bright-white" BgBlack = "bg-black" BgRed = "bg-red" BgGreen = "bg-green" BgYellow = "bg-yellow" BgBlue = "bg-blue" BgMagenta = "bg-magenta" BgCyan = "bg-cyan" BgWhite = "bg-white" BgBrightBlack = "bg-bright-black" BgBrightRed = "bg-bright-red" BgBrightGreen = "bg-bright-green" BgBrightYellow = "bg-bright-yellow" BgBrightBlue = "bg-bright-blue" BgBrightMagenta = "bg-bright-magenta" BgBrightCyan = "bg-bright-cyan" BgBrightWhite = "bg-bright-white" Bold = "bold" Dim = "dim" Italic = "italic" Underlined = "underlined" Blink = "blink" Inverse = "inverse" ) // Of combines different styles. func ( ...string) string { return strings.TrimSpace(strings.Join(, " ")) } // XTerm256Color returns a color from the xterm 256-color palette. func ( uint8) string { return ui.XTerm256Color().String() } // TrueColor returns a 24-bit true color. func (, , uint8) string { return ui.TrueColor(, , ).String() } // SGR returns the SGR sequence for given style. func ( string) string { return Parse().SGR() } func ( string) ui.Style { := make([]ui.Styling, 0) for , := range strings.Split(, " ") { if := ui.ParseStyling(); != nil { = append(, ) } } return ui.ApplyStyling(ui.Style{}, ...) }