Class: Playbook::PbIconStatValue::IconStatValue

Inherits:
Object
  • Object
show all
Includes:
ActionView::Helpers::NumberHelper, Playbook::Props
Defined in:
app/pb_kits/playbook/pb_icon_stat_value/icon_stat_value.rb

Instance Method Summary collapse

Methods included from Playbook::Props

#dark_props, #generate_classname, #generate_classname_without_spacing, #initialize, #prop, #spacing_options, #spacing_props, #spacing_values

Instance Method Details

#classnameObject



33
34
35
# File 'app/pb_kits/playbook/pb_icon_stat_value/icon_stat_value.rb', line 33

def classname
  generate_classname("pb_icon_stat_value_kit", orientation, size, variant)
end

#title_sizeObject



41
42
43
44
45
46
47
48
49
# File 'app/pb_kits/playbook/pb_icon_stat_value/icon_stat_value.rb', line 41

def title_size
  if size == "lg"
    1
  elsif size == "md"
    2
  else
    3
  end
end

#value_stringObject



37
38
39
# File 'app/pb_kits/playbook/pb_icon_stat_value/icon_stat_value.rb', line 37

def value_string
  value.to_s
end