Class: UiComponents::DaisyUi::DataDisplay::Countdown::ItemComponent

Inherits:
BaseComponent
  • Object
show all
Defined in:
app/components/ui_components/daisy_ui/data_display/countdown/item_component.rb

Constant Summary

Constants inherited from BaseComponent

BaseComponent::ALIGNS, BaseComponent::AXES, BaseComponent::COLORS, BaseComponent::CSS_CLASSES, BaseComponent::CSS_CLASSES_DEFAULT, BaseComponent::CSS_CLASSES_VARIANTS, BaseComponent::KINDS, BaseComponent::SIZES

Instance Attribute Summary

Attributes inherited from BaseComponent

#slot_order

Instance Method Summary collapse

Methods inherited from BaseComponent

tracks_slot_order

Constructor Details

#initialize(value:, type: "second", label: nil, automatic:, **args) ⇒ ItemComponent

Returns a new instance of ItemComponent.



13
14
15
16
17
18
19
20
21
22
23
24
25
26
# File 'app/components/ui_components/daisy_ui/data_display/countdown/item_component.rb', line 13

def initialize(
    value:,
    type: "second",
    label: nil,
    automatic:,
    **args
  )
  @value = value.to_s
  @type = type.to_s
  @label = label.to_s
  @automatic = automatic

  super(**args)
end