Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Option ¶
type Option func(*Prompt)
Option configures an option on a prompt.
func WithDefaultChoice ¶
WithDefaultChoice sets the default choice on the prompt.
func WithPersistPrompt ¶
func WithPersistPrompt(v PersistPrompt) Option
WithPersistPrompt configures the prompt persistence behavior.
type PersistPrompt ¶
type PersistPrompt int
PersistPrompt describes the behavior of the prompt after a choice is made.
const ( // PersistPromptAlways always persists the prompt on the screen regardless of the choice. PersistPromptAlways PersistPrompt = iota // PersistPromptIfYes only persists the prompt on the screen if the choice is Yes. PersistPromptIfYes // PersistPromptIfNo only persists the prompt on the screen if the choice is No. PersistPromptIfNo )
Click to show internal directories.
Click to hide internal directories.