Class: DesignSystem::Generic::PanelComponent
- Inherits:
-
BaseComponent
- Object
- ViewComponent::Base
- BaseComponent
- DesignSystem::Generic::PanelComponent
- Defined in:
- app/components/design_system/generic/panel_component.rb
Overview
Confirmation/transaction panel rendered by ds_panel.
Direct Known Subclasses
Instance Attribute Summary collapse
-
#body ⇒ Object
readonly
Returns the value of attribute body.
-
#title ⇒ Object
readonly
Returns the value of attribute title.
Instance Method Summary collapse
-
#initialize(title:, body:) ⇒ PanelComponent
constructor
A new instance of PanelComponent.
- #panel_classes ⇒ Object
Methods included from Helpers::CssHelper
Methods included from BrandDerivable
Constructor Details
#initialize(title:, body:) ⇒ PanelComponent
Returns a new instance of PanelComponent.
5 6 7 8 9 |
# File 'app/components/design_system/generic/panel_component.rb', line 5 def initialize(title:, body:) super() @title = title @body = body end |
Instance Attribute Details
#body ⇒ Object (readonly)
Returns the value of attribute body.
11 12 13 |
# File 'app/components/design_system/generic/panel_component.rb', line 11 def body @body end |
#title ⇒ Object (readonly)
Returns the value of attribute title.
11 12 13 |
# File 'app/components/design_system/generic/panel_component.rb', line 11 def title @title end |
Instance Method Details
#panel_classes ⇒ Object
13 14 15 |
# File 'app/components/design_system/generic/panel_component.rb', line 13 def panel_classes ["#{brand}-panel"] end |