Class: CafeCar::Inputs::BaseInput
- Inherits:
-
Object
- Object
- CafeCar::Inputs::BaseInput
- Defined in:
- lib/cafe_car/inputs/base_input.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#options ⇒ Object
Returns the value of attribute options.
Instance Method Summary collapse
-
#initialize(template:, **options) ⇒ BaseInput
constructor
A new instance of BaseInput.
- #tag ⇒ Object
- #to_html ⇒ Object
- #type ⇒ Object
Constructor Details
#initialize(template:, **options) ⇒ BaseInput
Returns a new instance of BaseInput.
6 7 8 9 |
# File 'lib/cafe_car/inputs/base_input.rb', line 6 def initialize(template:, **) @template = template @options = end |
Instance Attribute Details
#options ⇒ Object
Returns the value of attribute options.
4 5 6 |
# File 'lib/cafe_car/inputs/base_input.rb', line 4 def @options end |
Instance Method Details
#tag ⇒ Object
11 |
# File 'lib/cafe_car/inputs/base_input.rb', line 11 def tag = :input |
#to_html ⇒ Object
14 15 16 |
# File 'lib/cafe_car/inputs/base_input.rb', line 14 def to_html @template.Input(tag:, type:, **) end |
#type ⇒ Object
12 |
# File 'lib/cafe_car/inputs/base_input.rb', line 12 def type = :text |