ui

package
v0.5.6 Latest Latest
Warning

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

Go to latest
Published: Aug 2, 2025 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// Global style variables - will be updated by UpdateStyles
	AccentStyle    lipgloss.Style
	TextStyle      lipgloss.Style
	TitleStyle     lipgloss.Style
	LogoStyle      lipgloss.Style
	SelectedStyle  lipgloss.Style
	NormalStyle    lipgloss.Style
	DimStyle       lipgloss.Style
	CompletedStyle lipgloss.Style
	ErrorStyle     lipgloss.Style
	SuccessStyle   lipgloss.Style
	BulletStyle    lipgloss.Style
	LineStyle      lipgloss.Style
	ContainerStyle lipgloss.Style
	GreenStyle     lipgloss.Style
	YellowStyle    lipgloss.Style
	RedStyle       lipgloss.Style
)

Functions

func InitializeStyles added in v0.4.0

func InitializeStyles() error

InitializeStyles initializes styles with default or loaded config

func UpdateOnInit

func UpdateOnInit() tea.Cmd

func UpdateStyles added in v0.4.0

func UpdateStyles(cfg *config.Config)

UpdateStyles updates all styles based on the provided config

Types

type ActionModel

type ActionModel struct {
	Actions        []string
	SelectedAction string
}

type BranchModel

type BranchModel struct {
	Actions        []string
	SelectedAction string
	Branches       []string
	SelectedBranch string
}

type CommitModel

type CommitModel struct {
	Actions        []string
	SelectedAction string
}

type ConfigModel

type ConfigModel struct {
	Actions        []string
	SelectedAction string
	Flavors        []string
	SelectedFlavor string
	Accents        []string
	SelectedAccent string
}

type Model

type Model struct {
	CurrentStep   Step
	Loading       bool
	Selected      int
	ActionModel   ActionModel
	BranchModel   BranchModel
	CommitModel   CommitModel
	RemoteModel   RemoteModel
	TagModel      TagModel
	ConfigModel   ConfigModel
	CurrentConfig *config.Config
	Spinner       spinner.Model
	Level         int
	Output        []string
	Err           string
	Success       string
}

func (Model) Init

func (m Model) Init() tea.Cmd

func (Model) Update

func (m Model) Update(msg tea.Msg) (tea.Model, tea.Cmd)

func (Model) View

func (m Model) View() string

View renders the entire UI based on the current model state.

type RemoteModel

type RemoteModel struct {
	Actions        []string
	SelectedAction string
	Options        []string
	Selected       string
}

type Step

type Step int
const (
	StepLoad Step = iota
	StepAction
	StepBranchAction
	StepBranchSelect
	StepCommit
	StepTag
	StepTagSelect
	StepTagAdd
	StepTagInput
	StepRemote
	StepRemoteSelect
	StepChanges
	StepOptions
	StepOptionsFlavorSelect
	StepOptionsAccentSelect
)

type TagModel

type TagModel struct {
	Actions        []string
	SelectedAction string
	Options        []string
	Selected       string
	AddOptions     []string
	SelectedAddTag string
	CurrentTag     string
	ManualInput    string
	InputMode      bool
}

Jump to

Keyboard shortcuts

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