utils

package
v0.0.9 Latest Latest
Warning

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

Go to latest
Published: Jun 3, 2022 License: GPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ListStyles        list.Styles
	LabelStyle        = lipgloss.NewStyle().PaddingLeft(2).Foreground(lipgloss.Color("202"))
	TitleStyle        = list.DefaultStyles().Title.Background(lipgloss.Color("22"))
	NonListTitleStyle = TitleStyle.Copy().MarginLeft(2).Background(lipgloss.Color("22"))
)

Functions

func NewItemDelegate

func NewItemDelegate() list.ItemDelegate

func Ticker

func Ticker() tea.Cmd

Types

type Mod

type Mod struct {
	Name      string
	ID        string
	Reference string
}

type SimpleItem

type SimpleItem[T tea.Model] struct {
	ItemTitle string
	Activate  func(msg tea.Msg, currentModel T) (tea.Model, tea.Cmd)
}

func (SimpleItem[any]) Description

func (n SimpleItem[any]) Description() string

func (SimpleItem[any]) FilterValue

func (n SimpleItem[any]) FilterValue() string

func (SimpleItem[any]) GetTitle

func (n SimpleItem[any]) GetTitle() string

func (SimpleItem[any]) Title

func (n SimpleItem[any]) Title() string

type SimpleItemExtra added in v0.0.9

type SimpleItemExtra[T tea.Model, E any] struct {
	SimpleItem[T]
	Extra E
}

type TickMsg

type TickMsg struct{}

Jump to

Keyboard shortcuts

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