Class: Spark::Table::Object

Inherits:
Component::Base show all
Defined in:
app/components/spark/table/object.rb

Instance Method Summary collapse

Methods inherited from Component::Base

#selector, #to_s, #unique_id

Constructor Details

#initializeObject

Returns a new instance of Object.



12
13
14
# File 'app/components/spark/table/object.rb', line 12

def initialize(*)
  super
end

Instance Method Details

#title_attrsObject



16
17
18
19
20
# File 'app/components/spark/table/object.rb', line 16

def title_attrs
  obj = title.present? ? title.tag_attrs : TagAttr.new
  obj.add scope: :row
  obj.classname.add "spark-table-detail-title"
end

#value_attrsObject



22
23
24
25
26
# File 'app/components/spark/table/object.rb', line 22

def value_attrs
  obj = value.present? ? value.tag_attrs : TagAttr.new
  obj.classname.add "spark-table-detail-value"
  obj
end