diff options
Diffstat (limited to 'config/initializers')
| -rw-r--r-- | config/initializers/simple_form_bootstrap.rb | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/config/initializers/simple_form_bootstrap.rb b/config/initializers/simple_form_bootstrap.rb index d90ea6398..4b9bd320d 100644 --- a/config/initializers/simple_form_bootstrap.rb +++ b/config/initializers/simple_form_bootstrap.rb @@ -132,6 +132,17 @@ SimpleForm.setup do |config| ba.use :hint, wrap_with: { tag: 'p', class: 'help-block small' } end end + + config.wrappers :multi_select_inline, tag: 'div', class: 'form-group', error_class: 'has-error' do |b| + b.use :html5 + b.optional :readonly + b.use :label, class: 'control-label' + b.wrapper tag: 'div', class: 'form-inline col-sm-8 col-xs-7' do |ba| + ba.use :input, class: 'form-control' + ba.use :error, wrap_with: {tag: 'span', class: 'help-block small'} + ba.use :hint, wrap_with: {tag: 'p', class: 'help-block small'} + end + 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, |
