Documentation
¶
Index ¶
- type Autocomplete
- func (a *Autocomplete) ClearUsageHint()
- func (a *Autocomplete) GetCompletionCursorPos() int
- func (a *Autocomplete) GetSelectedShortcut() string
- func (a *Autocomplete) GetUsageHint() string
- func (a *Autocomplete) HandleKey(k tea.KeyPressMsg) (bool, string)
- func (a *Autocomplete) Hide()
- func (a *Autocomplete) IsVisible() bool
- func (a *Autocomplete) RefreshToolsList()
- func (a *Autocomplete) Render() string
- func (a *Autocomplete) SetFileService(s agentdomain.FileService)
- func (a *Autocomplete) SetGitHubIssueService(s agentdomain.GitHubIssueService)
- func (a *Autocomplete) SetHeight(height int)
- func (a *Autocomplete) SetModelService(modelService convdomain.ModelService)
- func (a *Autocomplete) SetPricingService(pricingService convdomain.PricingService)
- func (a *Autocomplete) SetSkillsService(skillsService agentdomain.SkillsService)
- func (a *Autocomplete) SetStateManager(stateManager agentdomain.AgentModeState)
- func (a *Autocomplete) SetToolService(toolService agentdomain.ToolService)
- func (a *Autocomplete) SetWidth(width int)
- func (a *Autocomplete) Update(inputText string, cursorPos int)
- type ShortcutOption
- type ShortcutRegistry
- type SubcommandProvider
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Autocomplete ¶ added in v0.207.0
type Autocomplete struct {
// contains filtered or unexported fields
}
Autocomplete implements inline autocomplete functionality
func NewAutocomplete ¶
func NewAutocomplete(theme tui.Theme, shortcutRegistry ShortcutRegistry) *Autocomplete
NewAutocomplete creates a new autocomplete component
func (*Autocomplete) ClearUsageHint ¶ added in v0.207.0
func (a *Autocomplete) ClearUsageHint()
ClearUsageHint clears the current usage hint
func (*Autocomplete) GetCompletionCursorPos ¶ added in v0.207.0
func (a *Autocomplete) GetCompletionCursorPos() int
GetCompletionCursorPos returns the explicit caret position requested by the most recent handleSelection call, or 0 to mean "use the caller's default heuristic". Mirrors AutocompleteCompleteEvent.CursorPos.
func (*Autocomplete) GetSelectedShortcut ¶ added in v0.207.0
func (a *Autocomplete) GetSelectedShortcut() string
GetSelectedShortcut returns the currently selected shortcut
func (*Autocomplete) GetUsageHint ¶ added in v0.207.0
func (a *Autocomplete) GetUsageHint() string
GetUsageHint returns the current usage hint for ghost text display
func (*Autocomplete) HandleKey ¶ added in v0.207.0
func (a *Autocomplete) HandleKey(k tea.KeyPressMsg) (bool, string)
HandleKey processes key input for autocomplete navigation
func (*Autocomplete) Hide ¶ added in v0.207.0
func (a *Autocomplete) Hide()
Hide hides the autocomplete
func (*Autocomplete) IsVisible ¶ added in v0.207.0
func (a *Autocomplete) IsVisible() bool
IsVisible returns whether autocomplete is currently visible
func (*Autocomplete) RefreshToolsList ¶ added in v0.207.0
func (a *Autocomplete) RefreshToolsList()
RefreshToolsList forces a reload of the tools list This should be called when MCP servers connect or disconnect
func (*Autocomplete) Render ¶ added in v0.207.0
func (a *Autocomplete) Render() string
Render returns the autocomplete suggestions as a string
func (*Autocomplete) SetFileService ¶ added in v0.207.0
func (a *Autocomplete) SetFileService(s agentdomain.FileService)
SetFileService sets the project file lister used by the "@" autocomplete trigger. Safe to call with nil; the trigger then shows nothing.
func (*Autocomplete) SetGitHubIssueService ¶ added in v0.207.0
func (a *Autocomplete) SetGitHubIssueService(s agentdomain.GitHubIssueService)
SetGitHubIssueService sets the GitHub issue lookup used by the "#" autocomplete trigger. Safe to call with nil; the trigger then shows nothing.
func (*Autocomplete) SetHeight ¶ added in v0.207.0
func (a *Autocomplete) SetHeight(height int)
SetHeight sets the height for rendering
func (*Autocomplete) SetModelService ¶ added in v0.207.0
func (a *Autocomplete) SetModelService(modelService convdomain.ModelService)
SetModelService sets the model service for model autocomplete
func (*Autocomplete) SetPricingService ¶ added in v0.207.0
func (a *Autocomplete) SetPricingService(pricingService convdomain.PricingService)
SetPricingService sets the pricing service for model pricing display
func (*Autocomplete) SetSkillsService ¶ added in v0.207.0
func (a *Autocomplete) SetSkillsService(skillsService agentdomain.SkillsService)
SetSkillsService sets the skills service so installed skills appear in the slash-command autocomplete alongside shortcuts.
func (*Autocomplete) SetStateManager ¶ added in v0.207.0
func (a *Autocomplete) SetStateManager(stateManager agentdomain.AgentModeState)
SetStateManager sets the state manager for agent mode filtering
func (*Autocomplete) SetToolService ¶ added in v0.207.0
func (a *Autocomplete) SetToolService(toolService agentdomain.ToolService)
SetToolService sets the tool service for tool autocomplete
func (*Autocomplete) SetWidth ¶ added in v0.207.0
func (a *Autocomplete) SetWidth(width int)
SetWidth sets the width for rendering
func (*Autocomplete) Update ¶ added in v0.207.0
func (a *Autocomplete) Update(inputText string, cursorPos int)
Update handles autocomplete logic
type ShortcutOption ¶
type ShortcutOption struct {
Shortcut string
Description string
Usage string
Catalog bool
Matches []int
}
ShortcutOption represents a shortcut option for autocomplete
type ShortcutRegistry ¶
ShortcutRegistry interface for dependency injection
type SubcommandProvider ¶
type SubcommandProvider interface {
GetSubcommands() []shortcuts.Subcommand
}
SubcommandProvider is an interface for shortcuts that provide subcommands