model

package
v0.0.0-...-08e5b78 Latest Latest
Warning

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

Go to latest
Published: Jan 25, 2024 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Base

type Base struct {
	tea.Model

	Height int
	Width  int
	// contains filtered or unexported fields
}

func (*Base) Focused

func (v *Base) Focused() bool

type CommandBar

type CommandBar struct {
	*Base
	// contains filtered or unexported fields
}

func NewCommandBar

func NewCommandBar(app types.App) *CommandBar

func (*CommandBar) Init

func (m *CommandBar) Init() tea.Cmd

func (*CommandBar) Update

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

func (*CommandBar) View

func (m *CommandBar) View() string

type KeyMap

type KeyMap struct {
	Binds map[types.Viewable][]key.Binding
	// contains filtered or unexported fields
}

func NewKeyMap

func NewKeyMap(app types.App) *KeyMap

func (*KeyMap) FullHelp

func (k *KeyMap) FullHelp() (kb [][]key.Binding)

func (*KeyMap) ShortHelp

func (k *KeyMap) ShortHelp() (kb []key.Binding)

ShortHelp returns keybindings to be shown in the mini help view. It's part of the key.Map interface.

type Msg

type Msg int
const (
	MsgCmdFilter Msg = iota + 1
	MsgCmdInvoke
)
const MsgNone Msg = -1
type NavBar struct {
	*Base
	// contains filtered or unexported fields
}

func NewNavBar

func NewNavBar(app types.App, views []types.Viewable) *NavBar
func (m *NavBar) Init() tea.Cmd
func (m *NavBar) Update(msg tea.Msg) (tea.Model, tea.Cmd)
func (m *NavBar) View() string

type StatusBar

type StatusBar struct {
	*Base

	Target string
	URL    string
	// contains filtered or unexported fields
}

func NewStatusBar

func NewStatusBar(app types.App, keys *KeyMap) *StatusBar

func (*StatusBar) Init

func (m *StatusBar) Init() tea.Cmd

func (*StatusBar) Update

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

func (*StatusBar) View

func (m *StatusBar) View() string

type Table

type Table struct {
	*Base
	// contains filtered or unexported fields
}

func NewTable

func NewTable(app types.App, is types.Viewable, columns []table.Column, sortBy string) Table

func (*Table) Checkmark

func (v *Table) Checkmark(val bool) table.StyledCell

func (*Table) Init

func (v *Table) Init() tea.Cmd

func (*Table) SelectedRow

func (v *Table) SelectedRow() table.Row

func (*Table) Sort

func (v *Table) Sort(col string)

func (*Table) Update

func (v *Table) Update(msg tea.Msg) (Table, tea.Cmd)

func (*Table) UpdateRows

func (v *Table) UpdateRows(rows []table.Row)

func (*Table) View

func (v *Table) View() string

Jump to

Keyboard shortcuts

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