Skip to content
This repository has been archived by the owner on Jan 9, 2023. It is now read-only.

Commit

Permalink
Hid checkbox labels (#663)
Browse files Browse the repository at this point in the history
Hid redundant labels using “sr-only” class.
The checkbox ended up where the label used to be so I added a class of
“checkbox-label-space” that can be used where that comes into play.
  • Loading branch information
jscottchapman authored and jkleinsc committed Sep 27, 2016
1 parent 30f2337 commit d243f1a
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 6 deletions.
10 changes: 6 additions & 4 deletions app/inventory/batch/template.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,14 @@
{{select-or-typeahead property="vendor" label=(t 'inventory.labels.vendor') list=vendorList selection=model.vendor className="col-sm-4 required test-vendor"}}
{{em-input property="invoiceNo" label=(t 'inventory.labels.invoiceNumber') class="col-sm-4 test-invoice-number"}}
</div>
<div class="row">
<div class="form-group row">
{{select-or-typeahead property="location" label=(t 'inventory.labels.location') list=warehouseList selection=model.location className="col-sm-5"}}
{{select-or-typeahead property="aisleLocation" label=(t 'inventory.labels.aisleLocation') list=aisleLocationList selection=model.aisleLocation className="col-sm-5"}}
<div class="form-group col-sm-2">
<label class="control-label">{{t 'inventory.labels.gift'}}</label>
{{em-checkbox label=(t 'inventory.labels.gift') property="giftInKind"}}
<div class="col-sm-2 checkbox-label-space">
<div class="form-check">
<label class="control-label sr-only">{{t 'inventory.labels.gift'}}</label>
{{em-checkbox label=(t 'inventory.labels.gift') property="giftInKind"}}
</div>
</div>
</div>
<div class="panel panel-primary">
Expand Down
4 changes: 2 additions & 2 deletions app/inventory/request/template.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
{{/if}}
{{#if canFulfill}}
<div class="form-group">
<label class="control-label">{{t 'inventory.labels.fulfillRequest'}}</label>
<label class="control-label sr-only">{{t 'inventory.labels.fulfillRequest'}}</label>
</div>
{{em-checkbox label=(t 'inventory.labels.fulfillRequest') property="shouldFulfillRequest"}}
{{/if}}
Expand All @@ -77,7 +77,7 @@
selectedLocations=model.inventoryLocations
}}
<div class="form-group">
<label class="control-label">{{t 'inventory.labels.consumePurchases'}}</label>
<label class="control-label sr-only">{{t 'inventory.labels.consumePurchases'}}</label>
</div>
{{em-checkbox label=(t 'inventory.labels.markAsConsumed') property="markAsConsumed"}}
{{/if}}
Expand Down
4 changes: 4 additions & 0 deletions app/styles/components/_form_styles.scss
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,7 @@

select { height: 44px; }
}

.checkbox-label-space {
top: 25px;
}

0 comments on commit d243f1a

Please sign in to comment.