Class: InnerPlan::Tasks::Form::RowComponent

Inherits:
Phlex::HTML
  • Object
show all
Defined in:
app/components/inner_plan/tasks/form/row_component.rb

Instance Method Summary collapse

Constructor Details

#initializeRowComponent

Returns a new instance of RowComponent.



3
4
5
# File 'app/components/inner_plan/tasks/form/row_component.rb', line 3

def initialize
  @columns = []
end

Instance Method Details

#template(&content) ⇒ Object



7
8
9
10
11
# File 'app/components/inner_plan/tasks/form/row_component.rb', line 7

def template(&content)
  div(class: "row") {
    render content
  }
end

#with_column(span: 6, &content) ⇒ Object



13
14
15
16
17
# File 'app/components/inner_plan/tasks/form/row_component.rb', line 13

def with_column(span: 6, &content)
  div(class: "col-#{span}") {
    render content
  }
end