Module: SimpleForm::Components::Errors
- Included in:
- Inputs::Base
- Defined in:
- lib/simple_form/components/errors.rb
Instance Method Summary collapse
Instance Method Details
#error ⇒ Object
4 5 6 |
# File 'lib/simple_form/components/errors.rb', line 4 def error template.content_tag(error_tag, error_text, ) if object && errors.present? end |
#error_html_options ⇒ Object
16 17 18 |
# File 'lib/simple_form/components/errors.rb', line 16 def (:error, :error) end |
#error_tag ⇒ Object
8 9 10 |
# File 'lib/simple_form/components/errors.rb', line 8 def error_tag [:error_tag] || SimpleForm.error_tag end |
#error_text ⇒ Object
12 13 14 |
# File 'lib/simple_form/components/errors.rb', line 12 def error_text errors.to_sentence end |