lib/kuber_kit/ui/simple.rb in kuber_kit-0.1.9 vs lib/kuber_kit/ui/simple.rb in kuber_kit-0.2.0

- old
+ new

@@ -66,9 +66,15 @@ def print_warning(title, text) print_text(title, text, color: String::Colors::YELLOW) end + def prompt(text, options, &callback) + print_info("Select", text) + result = $stdin.gets.chomp + callback.call(result) + end + private def print_text(title, text, color:) puts "#{title.colorize(color)}\r\n #{text.colorize(color)}" end end \ No newline at end of file