diff options
author | Gleb Mazovetskiy <glex.spb@gmail.com> | 2014-06-24 05:03:39 +0400 |
---|---|---|
committer | Gleb Mazovetskiy <glex.spb@gmail.com> | 2014-06-24 05:08:13 +0400 |
commit | 7951a6d663ae8fb3646ef6a9de537ee18d282877 (patch) | |
tree | 33232660fe068f0a52c02f98244a8d9178438197 /assets/stylesheets/bootstrap/_forms.scss | |
parent | 0cbe7255b5ef45ba79ab684b61bf2d2443876e84 (diff) |
provide a concatenated js file by default
Diffstat (limited to 'assets/stylesheets/bootstrap/_forms.scss')
-rw-r--r-- | assets/stylesheets/bootstrap/_forms.scss | 60 |
1 files changed, 45 insertions, 15 deletions
diff --git a/assets/stylesheets/bootstrap/_forms.scss b/assets/stylesheets/bootstrap/_forms.scss index 4d1a097..e496fb0 100644 --- a/assets/stylesheets/bootstrap/_forms.scss +++ b/assets/stylesheets/bootstrap/_forms.scss @@ -283,6 +283,26 @@ input[type="checkbox"] { } +// Static form control text +// +// Apply class to a `p` element to make any string of text align with labels in +// a horizontal form layout. + +.form-control-static { + // Size it appropriately next to real form controls + padding-top: ($padding-base-vertical + 1); + padding-bottom: ($padding-base-vertical + 1); + // Remove default margin from `p` + margin-bottom: 0; + + &.input-lg, + &.input-sm { + padding-left: 0; + padding-right: 0; + } +} + + // Form control sizing // // Build on `.form-control` with modifier classes to decrease or increase the @@ -347,16 +367,6 @@ input[type="checkbox"] { } -// Static form control text -// -// Apply class to a `p` element to make any string of text align with labels in -// a horizontal form layout. - -.form-control-static { - margin-bottom: 0; // Remove default margin from `p` -} - - // Help text // // Apply to any element you wish to create light text for placement immediately @@ -482,11 +492,6 @@ input[type="checkbox"] { @include make-row(); } - .form-control-static { - padding-top: ($padding-base-vertical + 1); - padding-bottom: ($padding-base-vertical + 1); - } - // Reset spacing and right align labels, but scope to media queries so that // labels on narrow viewports stack the same as a default form example. @media (min-width: $screen-sm-min) { @@ -505,4 +510,29 @@ input[type="checkbox"] { top: 0; right: ($grid-gutter-width / 2); } + + // Form group sizes + // + // Quick utility class for applying `.input-lg` and `.input-sm` styles to the + // inputs and labels within a `.form-group`. + .form-group-lg { + @media (min-width: $screen-sm-min) { + .control-label { + padding-top: (($padding-large-vertical * $line-height-large) + 1); + } + } + .form-control { + @extend .input-lg; + } + } + .form-group-sm { + @media (min-width: $screen-sm-min) { + .control-label { + padding-top: ($padding-small-vertical + 1); + } + } + .form-control { + @extend .input-sm; + } + } } |