Class: Arara::Tags::TextArea

Inherits:
ActionView::Helpers::Tags::Base
  • Object
show all
Includes:
ActionView::Helpers::Tags::Placeholderable
Defined in:
app/components/arara/tags/text_area.rb

Overview

:nodoc:

Instance Method Summary collapse

Instance Method Details

#renderObject



10
11
12
13
14
15
16
17
18
19
20
21
22
# File 'app/components/arara/tags/text_area.rb', line 10

def render
  options = @options.stringify_keys
  add_default_name_and_id(options)

  if size = options.delete("size")
    options["cols"], options["rows"] = size.split("x") if size.respond_to?(:split)
  end

  options["textarea"] = true
  options["value"] = options.delete("value") { value_before_type_cast }

  @template_object.template.render(Arara::TextFieldComponent, options.symbolize_keys)
end