Documentation ¶
Index ¶
- type Details
- type Edit
- func (p *Edit) FullHelp() [][]key.Binding
- func (p *Edit) Init() tea.Cmd
- func (p *Edit) Reset()
- func (p *Edit) SetCommand(mode EditMode, cmd *command.Command) error
- func (p *Edit) SetSize(width, height int)
- func (p *Edit) ShortHelp() []key.Binding
- func (p *Edit) Update(msg tea.Msg) (Edit, tea.Cmd)
- func (p *Edit) View() string
- type EditMode
- type Execute
- func (p *Execute) FullHelp() [][]key.Binding
- func (p *Execute) Init() tea.Cmd
- func (p *Execute) SetCommand(cmd command.Command) error
- func (p *Execute) SetSize(width, height int)
- func (p *Execute) ShortHelp() []key.Binding
- func (p *Execute) Update(msg tea.Msg) (Execute, tea.Cmd)
- func (p *Execute) View() string
- type Explain
- func (p *Explain) FullHelp() [][]key.Binding
- func (p *Explain) Init() tea.Cmd
- func (p *Explain) SetCommand(cmd command.Command) error
- func (p *Explain) SetExplanation(explanation string) error
- func (p *Explain) SetSize(width, height int)
- func (p *Explain) ShortHelp() []key.Binding
- func (p *Explain) Update(msg tea.Msg) (Explain, tea.Cmd)
- func (p *Explain) View() string
- type Explorer
- func (p *Explorer) AddCommand(cmd command.Command) int
- func (p *Explorer) FullHelp() [][]key.Binding
- func (p *Explorer) RefreshCommand(cmd command.Command)
- func (p *Explorer) RemoveSelectedCommand() int
- func (p *Explorer) Select(idx int)
- func (p *Explorer) SelectedCommand() (*ExplorerItem, bool)
- func (p *Explorer) SetCommands(cmds []command.Command)
- func (p *Explorer) SetSize(w, h int)
- func (p *Explorer) ShortHelp() []key.Binding
- func (p *Explorer) Update(msg tea.Msg) (Explorer, tea.Cmd)
- func (p Explorer) View() string
- type ExplorerItem
- type Search
- func (p *Search) Content() string
- func (p *Search) Focus()
- func (p *Search) FullHelp() [][]key.Binding
- func (p *Search) Init() tea.Cmd
- func (p *Search) Reset()
- func (p *Search) SetWidth(width int)
- func (p *Search) ShortHelp() []key.Binding
- func (p *Search) Unfocus()
- func (p *Search) Update(msg tea.Msg) (Search, tea.Cmd)
- func (p *Search) View() string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Details ¶ added in v0.3.0
type Details struct {
// contains filtered or unexported fields
}
Details handles the panel for showing the command details.
func NewDetails ¶ added in v0.3.0
NewDetails returns a new DetailsPanel.
func (*Details) SetCommand ¶ added in v0.3.0
SetCommand sets the command to view in the panel.
func (*Details) ToggleConfirmation ¶ added in v0.3.0
ToggleConfirmation toggles the confirmation mode
type Edit ¶ added in v0.3.0
type Edit struct {
// contains filtered or unexported fields
}
Edit handles the panel for editing or creating a command.
func (*Edit) SetCommand ¶ added in v0.3.0
SetCommand sets the panel content.
type EditMode ¶ added in v0.3.0
type EditMode int
EditMode represents the way the panel is going to be used.
const ( // NewCommandMode pannel is going to return a new Command NewCommandMode EditMode // EditCommandMode pannel is going to return the passed Command updated. EditCommandMode )
type Execute ¶ added in v0.3.0
type Execute struct {
// contains filtered or unexported fields
}
Execute handles the panel for executing a command.
func NewExecute ¶ added in v0.3.0
NewExecute returns a new ExecutePanel.
func (*Execute) SetCommand ¶ added in v0.3.0
SetCommand sets the panel content.
type Explain ¶ added in v0.3.0
type Explain struct {
// contains filtered or unexported fields
}
Explain handles the panel for explaing the command
func (*Explain) SetCommand ¶ added in v0.3.0
func (*Explain) SetExplanation ¶ added in v0.3.0
type Explorer ¶ added in v0.3.0
type Explorer struct {
// contains filtered or unexported fields
}
Explorer handles the panel for listing the commands.
func NewExplorer ¶ added in v0.3.0
NewExplorer returns a new ExplorerView.
func (*Explorer) AddCommand ¶ added in v0.3.0
AddCommand adds a new item to the List
func (*Explorer) RefreshCommand ¶ added in v0.3.0
RefreshCommand refresh the item command of the selected Item.
func (*Explorer) RemoveSelectedCommand ¶ added in v0.3.0
RemoveSelectedCommand removes the selected item form the list.
func (*Explorer) SelectedCommand ¶ added in v0.3.0
func (p *Explorer) SelectedCommand() (*ExplorerItem, bool)
SelectedCommand returns the ExplorerItem selected. Returns false if item not found or of incorrect type.
func (*Explorer) SetCommands ¶ added in v0.3.0
SetCommands sets the content of the list.
type ExplorerItem ¶
type ExplorerItem struct { // Command is a pointer to the represented command. Command *command.Command // Loaded indicates if the inner command has been fully loaded. Loaded bool // contains filtered or unexported fields }
ExplorerItem is the explorer items
func (ExplorerItem) Description ¶
func (i ExplorerItem) Description() string
func (ExplorerItem) FilterValue ¶
func (i ExplorerItem) FilterValue() string
func (ExplorerItem) Title ¶
func (i ExplorerItem) Title() string