Documentation
¶
Index ¶
Constants ¶
View Source
const ( // HeaderRowNum ui header max row num HeaderRowNum = 7 FooterRowNum = 1 // MenuRowNum menu component max row num MenuRowNum = 6 // LogoColumnNum logo component max column num LogoColumnNum = 50 )
Variables ¶
View Source
var ( // ThemeConfigFS is the theme config file system. //go:embed theme/* ThemeConfigFS embed.FS // ThemeMap is the theme map. ThemeMap = make(map[string]ThemeConfig) // ThemeNameArray is the theme name array. ThemeNameArray []string )
Functions ¶
func PersistentThemeConfig ¶ added in v1.7.0
func PersistentThemeConfig(themeName string)
PersistentThemeConfig saves theme config to file
Types ¶
type Color ¶ added in v1.7.0
type Color string
Color is a color string.
const ( // DefaultColor represents a default color. DefaultColor Color = "default" // DefaultTheme represents a default theme. DefaultTheme = "default" )
type Config ¶
type Config struct {
RestConfig *rest.Config
Theme *ThemeConfig
}
Config application configs
type ThemeConfig ¶ added in v1.7.0
type ThemeConfig struct {
Info struct {
Title Color
Text Color
}
Menu struct {
Description Color
Key Color
}
Logo struct {
Text Color
}
Crumbs struct {
Foreground Color
Background Color
}
Border struct {
App Color
Table Color
}
Table struct {
Title Color
Header Color
Body Color
CursorBg Color
CursorFg Color
}
Status struct {
Starting Color
Healthy Color
UnHealthy Color
Waiting Color
Succeeded Color
Failed Color
Unknown Color
}
Yaml struct {
Key Color
Colon Color
Value Color
}
Topology struct {
Line Color
App Color
Workflow Color
Component Color
Policy Color
Trait Color
Kind Color
}
}
ThemeConfig is the theme config.
func LoadThemeConfig ¶ added in v1.7.0
func LoadThemeConfig() *ThemeConfig
LoadThemeConfig loads theme config from env or use the default setting
Click to show internal directories.
Click to hide internal directories.