Documentation
¶
Index ¶
Constants ¶
View Source
const ( DefaultWidth = 50 DefaultHint = "(Enter to submit, esc to quit)" )
Variables ¶
This section is empty.
Functions ¶
func PromptValidate ¶
func PromptValidate( prompt string, defaultValue string, validate func(string) (string, error), ) (string, error)
PromptValidate executes the text input UI with a custom validator. The validator is called when the user presses Enter. If it returns an error, the error message is shown inline beneath the input. If it returns a value and no error, the potentially-normalized value is accepted.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.