Module: CLI::UI::Frame::FrameStyle
- Extended by:
- T::Helpers, T::Sig
- Includes:
- Kernel
- Included in:
- Box, Bracket
- Defined in:
- lib/cli/ui/frame/frame_style.rb,
lib/cli/ui/frame/frame_style/box.rb,
lib/cli/ui/frame/frame_style/bracket.rb
Defined Under Namespace
Modules: Box, Bracket
Classes: InvalidFrameStyleName
Constant Summary
collapse
- MAP =
{
box: -> { FrameStyle::Box },
bracket: -> { FrameStyle::Bracket },
}
Class Method Summary
collapse
Instance Method Summary
collapse
Methods included from T::Sig
sig
Methods included from T::Helpers
abstract!, final!, interface!, mixes_in_class_methods, sealed!
Class Method Details
.lookup(name) ⇒ Object
32
33
34
35
36
|
# File 'lib/cli/ui/frame/frame_style.rb', line 32
def lookup(name)
MAP.fetch(name.to_sym).call
rescue KeyError
raise(InvalidFrameStyleName, name)
end
|
Instance Method Details
#close(text, color:, right_text: nil) ⇒ Object
78
|
# File 'lib/cli/ui/frame/frame_style.rb', line 78
def close(text, color:, right_text: nil); end
|
#divider(text, color:) ⇒ Object
91
|
# File 'lib/cli/ui/frame/frame_style.rb', line 91
def divider(text, color:); end
|
#prefix ⇒ Object
45
|
# File 'lib/cli/ui/frame/frame_style.rb', line 45
def prefix; end
|
#prefix_width ⇒ Object
49
50
51
|
# File 'lib/cli/ui/frame/frame_style.rb', line 49
def prefix_width
CLI::UI::ANSI.printing_width(prefix)
end
|
#print_at_x(x, str) ⇒ Object
#start(text, color:) ⇒ Object
64
|
# File 'lib/cli/ui/frame/frame_style.rb', line 64
def start(text, color:); end
|
#style_name ⇒ Object
40
|
# File 'lib/cli/ui/frame/frame_style.rb', line 40
def style_name; end
|