internal

package
v0.0.8 Latest Latest
Warning

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

Go to latest
Published: Nov 18, 2020 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Prompt

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

func NewPrompt

func NewPrompt(title string, placeholder ...string) *Prompt

func (*Prompt) Answer

func (p *Prompt) Answer() (result string, err error)

func (*Prompt) Init

func (p *Prompt) Init() tea.Cmd

func (*Prompt) Update

func (p *Prompt) Update(msg tea.Msg) (tea.Model, tea.Cmd)

func (*Prompt) View

func (p *Prompt) View() string

func (*Prompt) YesOrNo

func (p *Prompt) YesOrNo() (bool, error)

type SpinnerCmd

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

func NewSpinnerCmd

func NewSpinnerCmd(cmd *exec.Cmd, title ...string) *SpinnerCmd

func (*SpinnerCmd) Init

func (t *SpinnerCmd) Init() tea.Cmd

func (*SpinnerCmd) Run

func (t *SpinnerCmd) Run() (err error)

func (*SpinnerCmd) Update

func (t *SpinnerCmd) Update(msg tea.Msg) (tea.Model, tea.Cmd)

func (*SpinnerCmd) UpdateOutput

func (t *SpinnerCmd) UpdateOutput(c <-chan []byte)

func (*SpinnerCmd) View

func (t *SpinnerCmd) View() string

type SpinnerTask

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

func NewSpinnerTask

func NewSpinnerTask(title string, task Task) *SpinnerTask

func (*SpinnerTask) Init

func (t *SpinnerTask) Init() tea.Cmd

func (*SpinnerTask) Run

func (t *SpinnerTask) Run() (err error)

func (*SpinnerTask) Update

func (t *SpinnerTask) Update(msg tea.Msg) (tea.Model, tea.Cmd)

func (*SpinnerTask) View

func (t *SpinnerTask) View() string

type Task

type Task func() error

Jump to

Keyboard shortcuts

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