search

package
v0.4.1 Latest Latest
Warning

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

Go to latest
Published: Apr 6, 2024 License: GPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Control

type Control uint
const (
	SELECT Control = iota
	CANCEL
	CURSOR_UP
	CURSOR_DOWN
	TYPING
	UPDATE_SUGGESTIONS
)

type Item

type Item string

func (Item) FilterValue

func (i Item) FilterValue() string

type ItemDelegate

type ItemDelegate struct{}

func (ItemDelegate) Height

func (d ItemDelegate) Height() int

func (ItemDelegate) Render

func (d ItemDelegate) Render(w io.Writer, m list.Model, index int, listItem list.Item)

func (ItemDelegate) Spacing

func (d ItemDelegate) Spacing() int

func (ItemDelegate) Update

func (d ItemDelegate) Update(msg tea.Msg, m *list.Model) tea.Cmd

type Model

type Model struct {
	// contains filtered or unexported fields
}

func New

func New() *Model

func (*Model) Init

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

func (*Model) InputValue

func (m *Model) InputValue() string

func (*Model) SetSize

func (m *Model) SetSize(w, h int)

func (*Model) SetSuggestions

func (m *Model) SetSuggestions(best string, suggestions []string)

func (*Model) SuggestionValue

func (m *Model) SuggestionValue() (string, bool)

func (*Model) Update

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

func (*Model) View

func (m *Model) View() string

Jump to

Keyboard shortcuts

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