Class: UI::CardComponent
- Inherits:
-
ViewComponent::Base
- Object
- ViewComponent::Base
- UI::CardComponent
- Includes:
- CardBehavior
- Defined in:
- app/view_components/ui/card_component.rb
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(classes: "", **attributes) ⇒ CardComponent
constructor
A new instance of CardComponent.
Methods included from CardBehavior
#card_classes, #card_html_attributes, #render_card
Constructor Details
#initialize(classes: "", **attributes) ⇒ CardComponent
Returns a new instance of CardComponent.
6 7 8 9 |
# File 'app/view_components/ui/card_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/card_component.rb', line 11 def call render_card { content } end |