styles

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Sep 10, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

Help

Functions

func Dimmed

func Dimmed(text string) string

Renders the text with `SubText` style

func HelpView

func HelpView(help help.KeyMap) string

Renders the help menu

func InitializeStyles

func InitializeStyles(theme Theme)

Initializes the styles

func Title

func Title(text string) string

Renders the text with `Title` style

Types

type GCheatStyle

type GCheatStyle struct {
	// Base
	Base lipgloss.Style

	// Title
	Title lipgloss.Style

	// Sub text
	SubText lipgloss.Style

	// Style for items over SubAltBg
	SubAltBg lipgloss.Style

	// Style for active list items
	ListItemActive lipgloss.Style

	// Style for inactive list item
	ListItemInactive lipgloss.Style

	// Style for input
	Input lipgloss.Style

	// Error
	Error lipgloss.Style

	// Style for placeholder
	Placeholder lipgloss.Style

	// Folder active list item
	FolderItemActive lipgloss.Style

	// Folder inactive list item
	FolderItemInactive lipgloss.Style

	// Tilte Bar
	AccentBgItem lipgloss.Style

	// Mock screen
	MockScreen lipgloss.Style

	// Background Over
	BackgroundOver lipgloss.Style

	// Sub text item
	SubTextItem lipgloss.Style

	// Overlay item
	OverlayItem lipgloss.Style

	// Time left for inactive cards
	TimeLeftInactive lipgloss.Style

	StatusMsg lipgloss.Style

	Success lipgloss.Style
}

Themes used all over tlock

var Styles GCheatStyle

Instance of styles Must be initialized on program's start

type Theme

type Theme struct {
	// Name
	Name string

	// Background
	Background lipgloss.Color

	// Background focused
	BackgroundOver lipgloss.Color

	// Sub text
	SubText lipgloss.Color

	// Accent
	Accent lipgloss.Color

	// Foreground
	Foreground lipgloss.Color

	// Error
	Error lipgloss.Color

	Success lipgloss.Color
}

func InitTheme

func InitTheme() Theme

Jump to

Keyboard shortcuts

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