Versions in this module Expand all Collapse all v0 v0.1.2 Jul 14, 2024 Changes in this version + type Components struct + type Dimensions struct + type Input struct + func NewInput(runMode RunMode, promptMode PromptMode, pipe string, prompts []string) (*Input, error) + func (i *Input) GetArgs() string + func (i *Input) GetPipe() string + func (i *Input) GetPromptMode() PromptMode + func (i *Input) GetRunMode() RunMode + type Prompt struct + func NewPrompt(mode PromptMode) *Prompt + func (p *Prompt) AsString() string + func (p *Prompt) Blur() *Prompt + func (p *Prompt) Focus() *Prompt + func (p *Prompt) GetMode() PromptMode + func (p *Prompt) GetValue() string + func (p *Prompt) SetMode(mode PromptMode) *Prompt + func (p *Prompt) SetValue(value string) *Prompt + func (p *Prompt) Update(msg tea.Msg) (*Prompt, tea.Cmd) + func (p *Prompt) View() string + type PromptMode int + const ApiBaseConfigPromptMode + const ChatPromptMode + const DefaultPromptMode + const ExecPromptMode + const ModelConfigPromptMode + const TokenConfigPromptMode + func GetPromptModeFromString(s string) PromptMode + func (m PromptMode) String() string + type Renderer struct + func NewRenderer(options ...glamour.TermRendererOption) *Renderer + func (r *Renderer) RenderApiBaseConfigMessage() string + func (r *Renderer) RenderApiTokenConfigMessage() string + func (r *Renderer) RenderConfigMessage(username string) string + func (r *Renderer) RenderContent(in string) string + func (r *Renderer) RenderError(in string) string + func (r *Renderer) RenderHelp(in string) string + func (r *Renderer) RenderHelpMessage() string + func (r *Renderer) RenderSuccess(in string) string + func (r *Renderer) RenderWarning(in string) string + type RunMode int + const CliMode + const ReplMode + func (m RunMode) String() string + type Spinner struct + func NewSpinner() *Spinner + func (s *Spinner) Tick() tea.Msg + func (s *Spinner) Update(msg tea.Msg) (*Spinner, tea.Cmd) + func (s *Spinner) View() string + type State struct + type Ui struct + func NewUi(input *Input) *Ui + func (u *Ui) Init() tea.Cmd + func (u *Ui) Update(msg tea.Msg) (tea.Model, tea.Cmd) + func (u *Ui) View() string v0.1.1 Jul 7, 2024