Class: Irelia::Form::Select::Component

Inherits:
Base::Component
  • Object
show all
Defined in:
app/components/irelia/form/select/component.rb

Instance Method Summary collapse

Instance Method Details

#optionsObject



6
7
8
9
10
# File 'app/components/irelia/form/select/component.rb', line 6

def options
  @options.merge({
    selected: value
  })
end

#variantsObject



12
13
14
15
16
17
# File 'app/components/irelia/form/select/component.rb', line 12

def variants
  class_names(
    "irelia-form__select",
    "irelia-form__select--default": variant == :default
  )
end