Class: Polaris::IndexTable::ColumnComponent

Inherits:
Component
  • Object
show all
Defined in:
app/components/polaris/index_table/column_component.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(title, flush: false, **system_arguments, &block) ⇒ ColumnComponent

Returns a new instance of ColumnComponent.



4
5
6
7
8
9
# File 'app/components/polaris/index_table/column_component.rb', line 4

def initialize(title, flush: false, **system_arguments, &block)
  @title = title
  @flush = flush
  @block = block
  @system_arguments = system_arguments
end

Instance Attribute Details

#flushObject (readonly)

Returns the value of attribute flush.



2
3
4
# File 'app/components/polaris/index_table/column_component.rb', line 2

def flush
  @flush
end

#system_argumentsObject (readonly)

Returns the value of attribute system_arguments.



2
3
4
# File 'app/components/polaris/index_table/column_component.rb', line 2

def system_arguments
  @system_arguments
end

#titleObject (readonly)

Returns the value of attribute title.



2
3
4
# File 'app/components/polaris/index_table/column_component.rb', line 2

def title
  @title
end

Instance Method Details

#call(row) ⇒ Object



11
12
13
# File 'app/components/polaris/index_table/column_component.rb', line 11

def call(row)
  @block.call(row)
end