Class: Grid::Row::RowComponent

Inherits:
ViewComponent::Base
  • Object
show all
Defined in:
app/components/grid/row/row_component.rb

Instance Method Summary collapse

Constructor Details

#initialize(**options) ⇒ RowComponent

Returns a new instance of RowComponent.



8
9
10
11
# File 'app/components/grid/row/row_component.rb', line 8

def initialize(**options)
  @classes = options[:classes]
  @styles = options[:styles]
end

Instance Method Details

#callObject



13
14
15
16
17
18
19
# File 'app/components/grid/row/row_component.rb', line 13

def call
  (:div,
    content,
    class: default_plus_passed_classes,
    style: @styles
  )
end