diff --git a/lib/generators/simple_form/templates/config/initializers/simple_form_bootstrap.rb b/lib/generators/simple_form/templates/config/initializers/simple_form_bootstrap.rb index 180f80ca..6f828ecb 100644 --- a/lib/generators/simple_form/templates/config/initializers/simple_form_bootstrap.rb +++ b/lib/generators/simple_form/templates/config/initializers/simple_form_bootstrap.rb @@ -95,6 +95,16 @@ SimpleForm.setup do |config| end end + config.wrappers :inline_form, tag: 'div', class: 'form-group', error_class: 'has-error' do |b| + b.use :html5 + b.use :placeholder + b.use :label, class: 'sr-only' + + b.use :input, class: 'form-control' + b.use :error, wrap_with: { tag: 'span', class: 'help-block' } + b.use :hint, wrap_with: { tag: 'p', class: 'help-block' } + end + # Wrappers for forms and inputs using the Bootstrap toolkit. # Check the Bootstrap docs (http://getbootstrap.com) # to learn about the different styles for forms and inputs,