Search code examples
ruby-on-railstwitter-bootstrapcheckboxmaterial-designbootstrap-material-design

Ruby on rails - bootstrap material design - Add checkboxes to simple form


I installed the Bootstrap Material Design in my Ruby on Rails application and every animation is functioning properly, but i can´t see the checkboxes. My code for the checkboxes is:

<div class='form-group'>
  <div class='control-label col-sm-2'>
  </div>
  <div class='col-sm-8'>
    <%= f.input :active, :as => :boolean, :label => false, :inline_label => true %>
  </div>
</div>

Can anyone Help me please?

Thank you all!


Solution

  • I finally got who it's doing:

    <div class='form-group'>
      <div class='control-label col-sm-2'>
    </div>
      <div class="checkbox col-sm-8">
          <label> <%= f.check_box :active, :as => :boolean, :label => false, :inline_label => true %> Active</label>
      </div>
    </div>
    

    You need to add "checkbox" to the div class of the label and then you will see the checkbox animations for the bootstrap material design