class Formtastic::Inputs::RegexInput

Public Instance Methods

input_html_options() click to toggle source
# File lib/formtastic/regex-input.rb, line 5
def input_html_options

  {
      class: 'regex-input',
      data: {
          regex: options[:regex],
          example: options[:example]
      },
      placeholder_text: options[:example]
  }
end
input_wrapping(&block) click to toggle source

Overwrite default li tag

# File lib/formtastic/regex-input.rb, line 18
def input_wrapping(&block)
  template.content_tag(:div,
                      [template.capture(&block), error_html, hint_html].join("\n").html_safe,
                      wrapper_html_options
  )
end
wrapper_html_options() click to toggle source

Overwrite wrapper html by the active admin class

Calls superclass method
# File lib/formtastic/regex-input.rb, line 26
def wrapper_html_options
  super.merge(:class => 'filter_form_field filter_string')
end