Class: UI::TableHeadComponent
- Inherits:
-
ViewComponent::Base
- Object
- ViewComponent::Base
- UI::TableHeadComponent
- Includes:
- TableHeadBehavior
- Defined in:
- app/view_components/ui/table_head_component.rb
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(classes: "", **attributes) ⇒ TableHeadComponent
constructor
A new instance of TableHeadComponent.
Methods included from TableHeadBehavior
#head_classes, #head_html_attributes, #render_head
Constructor Details
#initialize(classes: "", **attributes) ⇒ TableHeadComponent
Returns a new instance of TableHeadComponent.
6 7 8 9 |
# File 'app/view_components/ui/table_head_component.rb', line 6 def initialize(classes: "", **attributes) @classes = classes @attributes = attributes end |
Instance Method Details
#call ⇒ Object
11 12 13 |
# File 'app/view_components/ui/table_head_component.rb', line 11 def call content_tag :th, content, **head_html_attributes.deep_merge(@attributes) end |