Class: Elements::Block::Cell
- Inherits:
-
Cell
- Object
- Cell
- Elements::Block::Cell
- Defined in:
- app/cells/lato_core/elements/block/cell.rb
Constant Summary collapse
- @@requested_args =
[]
- @@default_args =
{ class: 'md-12', round: false }
Instance Method Summary collapse
- #close ⇒ Object
-
#initialize(args = {}) ⇒ Cell
constructor
A new instance of Cell.
- #open(custom_class: nil) ⇒ Object
Constructor Details
#initialize(args = {}) ⇒ Cell
Returns a new instance of Cell.
12 13 14 15 16 17 18 19 20 |
# File 'app/cells/lato_core/elements/block/cell.rb', line 12 def initialize(args = {}) @args = validate_args( args: args, requested_args: @@requested_args, default_args: @@default_args ) set_conditions end |
Instance Method Details
#close ⇒ Object
27 28 29 |
# File 'app/cells/lato_core/elements/block/cell.rb', line 27 def close render 'close.html' end |
#open(custom_class: nil) ⇒ Object
22 23 24 25 |
# File 'app/cells/lato_core/elements/block/cell.rb', line 22 def open(custom_class: nil) @args[:class] = custom_class if custom_class render 'open.html' end |