Documentation
¶
Index ¶
- func AltFilter(term string, targets []string) []list.Rank
- func KeyUsedByList(k list.KeyMap, msg tea.Msg) bool
- func MakeSearchFunc(option SearchOption) func(term string, targets []string) []list.Rank
- type DefaultItemDelegateAlt
- type SearchList
- func (s SearchList) GetMsgForParent() (tea.Model, tea.Msg)
- func (s SearchList) HandleRecvFocus() (tea.Model, tea.Cmd)
- func (s SearchList) HandleSizeMsg(msg teapb.ResizeMsg) (tea.Model, tea.Cmd)
- func (s SearchList) Init() tea.Cmd
- func (s *SearchList) SetMsgForParent(msg tea.Msg)
- func (s SearchList) Update(msg tea.Msg) (tea.Model, tea.Cmd)
- func (s SearchList) View() string
- type SearchListConfig
- type SearchOption
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AltFilter ¶
DefaultFilter uses the sahilm/fuzzy to filter through the list. This is set by default.
func MakeSearchFunc ¶
func MakeSearchFunc(option SearchOption) func(term string, targets []string) []list.Rank
Types ¶
type DefaultItemDelegateAlt ¶
type DefaultItemDelegateAlt struct { list.DefaultDelegate // contains filtered or unexported fields }
func SelectableItemsDelegate ¶
func SelectableItemsDelegate() DefaultItemDelegateAlt
type SearchList ¶
type SearchList struct { List list.Model SearchInput textinput.Model // contains filtered or unexported fields }
func NewSearchList ¶
func NewSearchList[T list.DefaultItem](items []T, config SearchListConfig, d list.ItemDelegate) SearchList
func (SearchList) GetMsgForParent ¶
func (s SearchList) GetMsgForParent() (tea.Model, tea.Msg)
func (SearchList) HandleRecvFocus ¶
func (s SearchList) HandleRecvFocus() (tea.Model, tea.Cmd)
func (SearchList) HandleSizeMsg ¶
func (SearchList) Init ¶
func (s SearchList) Init() tea.Cmd
func (*SearchList) SetMsgForParent ¶
func (s *SearchList) SetMsgForParent(msg tea.Msg)
func (SearchList) View ¶
func (s SearchList) View() string
type SearchListConfig ¶
Click to show internal directories.
Click to hide internal directories.