Class: Pulse::Table::Column
- Defined in:
- app/components/pulse/table/column.rb
Overview
Encapsulates table column properties
Constant Summary
Constants inherited from Component
Constants included from AttributesHelper
AttributesHelper::PLURAL_ARIA_ATTRIBUTES, AttributesHelper::PLURAL_DATA_ATTRIBUTES
Instance Attribute Summary collapse
-
#footer ⇒ Object
readonly
Returns the value of attribute footer.
-
#options ⇒ Object
readonly
Returns the value of attribute options.
-
#sort_by ⇒ Object
readonly
Returns the value of attribute sort_by.
-
#sr_title ⇒ Object
readonly
Returns the value of attribute sr_title.
-
#title ⇒ Object
readonly
Returns the value of attribute title.
Instance Method Summary collapse
-
#initialize(title: '', sr_title: nil, sort_by: nil, footer: nil, **options, &block) ⇒ Column
constructor
A new instance of Column.
Methods inherited from Component
generate_id, #merge_attributes, #merge_classes
Methods included from SvgHelper
Methods included from FetchOrFallbackHelper
#fetch_or_fallback, #fetch_or_fallback_boolean
Methods included from AttributesHelper
#aria, #data, #merge_aria, #merge_data, #merge_prefixed_attribute_hashes
Constructor Details
#initialize(title: '', sr_title: nil, sort_by: nil, footer: nil, **options, &block) ⇒ Column
Returns a new instance of Column.
9 10 11 12 13 14 15 16 17 |
# File 'app/components/pulse/table/column.rb', line 9 def initialize(title: '', sr_title: nil, sort_by: nil, footer: nil, **, &block) @title = title @sr_title = sr_title @sort_by = sort_by @footer = @block = block @options = end |
Instance Attribute Details
#footer ⇒ Object (readonly)
Returns the value of attribute footer.
7 8 9 |
# File 'app/components/pulse/table/column.rb', line 7 def @footer end |
#options ⇒ Object (readonly)
Returns the value of attribute options.
7 8 9 |
# File 'app/components/pulse/table/column.rb', line 7 def @options end |
#sort_by ⇒ Object (readonly)
Returns the value of attribute sort_by.
7 8 9 |
# File 'app/components/pulse/table/column.rb', line 7 def sort_by @sort_by end |
#sr_title ⇒ Object (readonly)
Returns the value of attribute sr_title.
7 8 9 |
# File 'app/components/pulse/table/column.rb', line 7 def sr_title @sr_title end |
#title ⇒ Object (readonly)
Returns the value of attribute title.
7 8 9 |
# File 'app/components/pulse/table/column.rb', line 7 def title @title end |