module Opal::Prompt

Defined in:

opal/prompt.cr
opal/prompt/ask.cr
opal/prompt/confirm.cr
opal/prompt/multi_select.cr
opal/prompt/progress.cr
opal/prompt/select.cr
opal/prompt/spinner.cr

Class Method Summary

Class Method Detail

def self.ask(question : String, default : String | Nil = nil, required : Bool = false, driver : Terminal::Driver | Nil = nil) : String #

[View source]
def self.confirm(question : String, default : Bool = true, driver : Terminal::Driver | Nil = nil) : Bool #

[View source]
def self.multi_select(question : String, options : Array(String), default_indices : Array(Int32) = [] of Int32, driver : Terminal::Driver | Nil = nil) : Array(String) #

[View source]
def self.progress(total : Int32, bar_width : Int32 = 30, color : Color | Symbol | String = :cyan, title : String | Nil = nil, driver : Terminal::Driver | Nil = nil, &block : ProgressBar -> Nil) : Nil #

[View source]
def self.select(question : String, options : Array(String), default_index : Int32 = 0, driver : Terminal::Driver | Nil = nil) : String #

[View source]
def self.spinner(text : String, driver : Terminal::Driver | Nil = nil, &block : Spinner -> T) : T forall T #

[View source]