Class: Arclight::ExpandHierarchyButtonComponent
- Inherits:
-
Blacklight::Component
- Object
- Blacklight::Component
- Arclight::ExpandHierarchyButtonComponent
- Defined in:
- app/components/arclight/expand_hierarchy_button_component.rb
Overview
Component for rendering an expand button in the hierarchy view
Instance Method Summary collapse
- #expand_link ⇒ Object
-
#initialize(path:, classes: 'btn btn-secondary btn-sm') ⇒ ExpandHierarchyButtonComponent
constructor
A new instance of ExpandHierarchyButtonComponent.
Constructor Details
#initialize(path:, classes: 'btn btn-secondary btn-sm') ⇒ ExpandHierarchyButtonComponent
Returns a new instance of ExpandHierarchyButtonComponent.
6 7 8 9 10 |
# File 'app/components/arclight/expand_hierarchy_button_component.rb', line 6 def initialize(path:, classes: 'btn btn-secondary btn-sm') super() @path = path @classes = classes end |
Instance Method Details
#expand_link ⇒ Object
12 13 14 |
# File 'app/components/arclight/expand_hierarchy_button_component.rb', line 12 def link_to t('arclight.views.show.expand'), @path, class: @classes end |