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