Class: Phlexi::Form::Components::Base

Inherits:
HTML
  • Object
show all
Defined in:
lib/phlexi/form/components/base.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(field, **attributes) ⇒ Base

Returns a new instance of Base.



9
10
11
12
13
14
15
# File 'lib/phlexi/form/components/base.rb', line 9

def initialize(field, **attributes)
  @field = field
  @attributes = attributes

  build_attributes
  append_attribute_classes
end

Instance Attribute Details

#attributesObject (readonly)

Returns the value of attribute attributes.



7
8
9
# File 'lib/phlexi/form/components/base.rb', line 7

def attributes
  @attributes
end

#fieldObject (readonly)

Returns the value of attribute field.



7
8
9
# File 'lib/phlexi/form/components/base.rb', line 7

def field
  @field
end