<label class="error">Name</label><input type="text" name="user[name]" class="error" /><small class="error">Name is required</small>
config.wrappers :default, class: :input, hint_class: :field_with_hint, error_class: :field_with_errors do |b|b.use :html5b.use :placeholderb.optional :maxlengthb.optional :patternb.optional :min_maxb.optional :readonly## Inputsb.use :label, error_html: { class: :error }b.use :hint, wrap_with: { tag: :small, class: :hint }b.use :input, error_html: { class: :error }b.use :error, wrap_with: { tag: :small, class: :error }end
--
You received this message because you are subscribed to the Google Groups "SimpleForm" group.
To unsubscribe from this group and stop receiving emails from it, send an email to plataformatec-simp...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to a topic in the Google Groups "SimpleForm" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/plataformatec-simpleform/I9RzwZKniGw/unsubscribe.
To unsubscribe from this group and all its topics, send an email to plataformatec-simp...@googlegroups.com.
error_class
on input do the same as error_class
on wrapper. It will add the class to wrapper as it is being added now. It does work if you change the :field_with_errors
class to error
.