Fixed#102 - added labels to checkbox and radiobox.

This commit is contained in:
Martin Edenhofer 2014-01-21 13:08:44 +01:00
parent 8138ac2004
commit 3a9cc85e36
3 changed files with 9 additions and 3 deletions

View file

@ -1,5 +1,5 @@
<div class="<%= @attribute.class %>">
<div class="<%= @attribute.class %> checkbox">
<% for row in @attribute.options: %>
<input type="checkbox" value="<%= row.value %>" name="<%= @attribute.name %>" <%= row.checked %>> <%= row.name %> <% if row.note: %>- <%= row.note %><% end %><br/>
<label><input type="checkbox" value="<%= row.value %>" name="<%= @attribute.name %>" <%= row.checked %>> <%= row.name %> <% if row.note: %>- <%= row.note %><% end %></label>
<% end %>
</div>

View file

@ -1,5 +1,5 @@
<div class="<%= @attribute.class %>">
<% for row in @attribute.options: %>
<input type="radio" value="<%= row.value %>" name="<%= @attribute.name %>" <%= row.checked %>> <%= row.name %> <% if row.note: %>- <%= row.note %><% end %><br/>
<label><input type="radio" value="<%= row.value %>" name="<%= @attribute.name %>" <%= row.checked %>> <%= row.name %> <% if row.note: %>- <%= row.note %><% end %></label>
<% end %>
</div>

View file

@ -434,6 +434,12 @@ h5 {
width: 130px;
margin-top: 7px;
}
.form-horizontal .form-group .checkbox label {
text-align: left;
width: 100%;
margin-top: 0;
margin-bottom: 4px;
}
/*
* bootstrap changes