Class: Bs5::ExpandableList::GroupComponent
- Inherits:
-
ViewComponent::Base
- Object
- ViewComponent::Base
- Bs5::ExpandableList::GroupComponent
- Defined in:
- app/components/bs5/expandable_list/group_component.rb
Constant Summary collapse
- DEFAULT_TAG_NAME =
:div
Instance Attribute Summary collapse
-
#is_accordion ⇒ Object
(also: #accordion?)
readonly
Returns the value of attribute is_accordion.
-
#is_stretchable ⇒ Object
(also: #stretchable?)
readonly
Returns the value of attribute is_stretchable.
-
#options ⇒ Object
readonly
Returns the value of attribute options.
-
#tag_name ⇒ Object
readonly
Returns the value of attribute tag_name.
Instance Method Summary collapse
-
#initialize(options = {}) ⇒ GroupComponent
constructor
A new instance of GroupComponent.
Constructor Details
#initialize(options = {}) ⇒ GroupComponent
Returns a new instance of GroupComponent.
15 16 17 18 19 20 21 |
# File 'app/components/bs5/expandable_list/group_component.rb', line 15 def initialize( = {}) @is_accordion = .delete(:accordion) @is_stretchable = .delete(:stretchable) @id = .delete(:id) @tag_name = .delete(:tag) || DEFAULT_TAG_NAME @options = end |
Instance Attribute Details
#is_accordion ⇒ Object (readonly) Also known as: accordion?
Returns the value of attribute is_accordion.
11 12 13 |
# File 'app/components/bs5/expandable_list/group_component.rb', line 11 def is_accordion @is_accordion end |
#is_stretchable ⇒ Object (readonly) Also known as: stretchable?
Returns the value of attribute is_stretchable.
11 12 13 |
# File 'app/components/bs5/expandable_list/group_component.rb', line 11 def is_stretchable @is_stretchable end |
#options ⇒ Object (readonly)
Returns the value of attribute options.
11 12 13 |
# File 'app/components/bs5/expandable_list/group_component.rb', line 11 def @options end |
#tag_name ⇒ Object (readonly)
Returns the value of attribute tag_name.
11 12 13 |
# File 'app/components/bs5/expandable_list/group_component.rb', line 11 def tag_name @tag_name end |