Class: DividerComponent
- Defined in:
- app/components/divider_component.rb
Overview
Divider — horizontal/vertical dividers, optionally with text or icon.
Usage:
Divider()
Divider(horizontal: true) { text "OR" }
Divider(section: true, inverted: true)
Constant Summary
Constants inherited from Component
Instance Method Summary collapse
Methods inherited from Component
default, #initialize, #render_in, slot
Constructor Details
This class inherits a constructor from Component
Instance Method Details
#to_s ⇒ Object
19 20 21 22 23 24 25 26 27 28 29 |
# File 'app/components/divider_component.rb', line 19 def to_s classes = class_names( "ui", { "vertical" => vertical, "horizontal" => horizontal, "hidden" => hidden, "section" => section, "inverted" => inverted, "fitted" => fitted, "clearing" => clearing }, "divider" ) tag.div(class: classes) { @content } end |