Class: MarkdownInput

Inherits:
Formtastic::Inputs::TextInput
  • Object
show all
Defined in:
app/helpers/markdown_input.rb

Instance Method Summary collapse

Instance Method Details

#to_htmlObject



4
5
6
7
8
9
10
11
12
# File 'app/helpers/markdown_input.rb', line 4

def to_html
  input_wrapping do
    label_html <<
      builder.text_area(method, input_html_options) <<
      template.(:div, '', class: 'markdown-input__preview', 'data-images': images_json) <<
      template.render(partial: '/admin/shared/markdown_input/images', object: options[:images]) <<
      template.render(partial: '/admin/shared/markdown_input/guide')
  end
end