Class: EpicEditorInput

Inherits:
Formtastic::Inputs::TextInput
  • Object
show all
Defined in:
lib/formtastic-epiceditor/inputs/epic_editor_input.rb

Overview

app/inputs/my_special_string_input.rb use with :as => :my_special_string

Instance Method Summary collapse

Instance Method Details

#input_html_optionsObject



4
5
6
7
8
# File 'lib/formtastic-epiceditor/inputs/epic_editor_input.rb', line 4

def input_html_options
  {
    :class => "epiceditor"
  }.merge(super)
end

#to_htmlObject



10
11
12
13
14
15
16
17
# File 'lib/formtastic-epiceditor/inputs/epic_editor_input.rb', line 10

def to_html
  input_wrapping do
    label_html <<
    "<div id='#{input_html_options[:id]}-epiceditor' class='epiceditor-container'></div><div style='clear:both;'></div>".html_safe <<
    builder.hidden_field(method, input_html_options) <<
    buildInitScript(input_html_options[:id])
  end
end