Class: Avo::PanelComponent
- Inherits:
-
ViewComponent::Base
- Object
- ViewComponent::Base
- Avo::PanelComponent
- Includes:
- ApplicationHelper
- Defined in:
- app/components/avo/panel_component.rb
Instance Attribute Summary collapse
-
#classes ⇒ Object
readonly
Returns the value of attribute classes.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#title ⇒ Object
readonly
deprecating title in favor of name.
Instance Method Summary collapse
-
#initialize(name: nil, description: nil, body_classes: nil, data: {}, display_breadcrumbs: false, index: nil, classes: nil, **args) ⇒ PanelComponent
constructor
A new instance of PanelComponent.
Methods included from ApplicationHelper
#a_button, #a_link, #button_classes, #card_classes, #chart_color, #decode_filter_params, #empty_state, #encode_filter_params, #frame_id, #get_model_class, #input_classes, #mount_path, #number_to_social, #render_license_warning, #root_path_without_url, #svg, #white_panel_classes
Methods included from ResourcesHelper
#field_wrapper, #filter_wrapper, #index_field_wrapper, #item_select_all_input, #item_selector_init, #item_selector_input, #resource_grid, #resource_table
Constructor Details
#initialize(name: nil, description: nil, body_classes: nil, data: {}, display_breadcrumbs: false, index: nil, classes: nil, **args) ⇒ PanelComponent
Returns a new instance of PanelComponent.
21 22 23 24 25 26 27 28 29 30 31 |
# File 'app/components/avo/panel_component.rb', line 21 def initialize(name: nil, description: nil, body_classes: nil, data: {}, display_breadcrumbs: false, index: nil, classes: nil, **args) # deprecating title in favor of name @title = args[:title] @name = name || title @description = description @classes = classes @body_classes = body_classes @data = data @display_breadcrumbs = @index = index end |
Instance Attribute Details
#classes ⇒ Object (readonly)
Returns the value of attribute classes.
8 9 10 |
# File 'app/components/avo/panel_component.rb', line 8 def classes @classes end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
7 8 9 |
# File 'app/components/avo/panel_component.rb', line 7 def name @name end |
#title ⇒ Object (readonly)
deprecating title in favor of name
6 7 8 |
# File 'app/components/avo/panel_component.rb', line 6 def title @title end |