vendor/assets/stylesheets/furatto/_forms.scss in furatto-0.0.1 vs vendor/assets/stylesheets/furatto/_forms.scss in furatto-0.0.2

- old
+ new

@@ -35,11 +35,12 @@ input[type="tel"], input[type="color"], .uneditable-input { display: inline-block; height: $base-line-height; - padding: 4px 6px; + padding-left: 8px; + height: 30px; margin-bottom: $base-line-height / 2; font-size: $base-font-size; line-height: $base-line-height; color: $input-color; @include border-radius($input-border-radius); @@ -80,45 +81,51 @@ } } //Input sizes .input-mini { - width: 60px; + width: 16.667%; } .input-small { - width: 90px; + width: 33.34%; } .input-medium { - width: 150px; + width: 50%; } .input-large { - width: 210px; + width: 66.668%; } .input-xlarge { - width: 270px; + width: 83.335%; } -.input-xxlarge { - width: 350px; +.input-block { + width: 100%; } /* Inline Forms */ /* ------------ */ .inline-form, .horizontal-form { input, textarea, - select { + select, + .form-fields, + .checkbox-fields { display: inline-block; margin-bottom: 0; vertical-align: middle; } + .form-fields { + margin-top: 4px; + } + label { display: inline-block; } // Re-hide hidden elements due to specifity @@ -128,69 +135,46 @@ } /* Horizontal form */ /* --------------- */ .horizontal-form { - .furatto-controls { + .form-fields { display: block; margin-bottom: 10px; label { width: 160px; margin-right: 20px; text-align: right; } } - .furatto-actions { + .form-actions { margin-left: 184px; } } -/* Login Form */ -/* ------------ */ -.login-form { - width: 30%; - text-align: center; - - input[type="text"], - input[type="password"], - input[type="email"] { - display: block; - width: 96%; - height: 35px; - padding: 0px 0px 0px 10px; - height: 42px; - background: #fcfcfc; - } - - .furatto-login-icon { - margin-bottom: 20px; - } - - .login-header { - font-size: $base-font-size + 10; - margin: 0; - color: $dark-gray; - } -} - /* Centered forms */ /* -------------- */ .centered-form { - margin: 0 auto; + @include center-block; } /* Level up the label on for checkboxes */ /* ------------------------------------ */ -label.checkbox { +label.checkbox-label { + display: inline-block; position: relative; top: -4px; margin-left: 5px; margin-right: 5px; } +label.radiobutton-label { + @extend .checkbox-label; +} + label { @include touch-callout; } /* Uneditable inputs */ @@ -205,31 +189,16 @@ background: #EEE; } /* Input states */ /* ------------ */ -.info { - textarea, - input[type="text"], - input[type="password"], - input[type="datetime"], - input[type="datetime-local"], - input[type="date"], - input[type="month"], - input[type="time"], - input[type="week"], - input[type="number"], - input[type="email"], - input[type="url"], - input[type="search"], - input[type="tel"], - input[type="color"] { - color: $dark-blue; - border: 1px solid $dark-blue; +.form-fields-success{ + + .form-fields { + color: $dark-green; } -} -.success{ + textarea, input[type="text"], input[type="password"], input[type="datetime"], input[type="datetime-local"], @@ -245,11 +214,14 @@ input[type="color"] { color: $dark-green; border: 1px solid $dark-green; } } -.warning{ +.form-fields-warning{ + .form-fields { + color: $dark-orange; + } textarea, input[type="text"], input[type="password"], input[type="datetime"], input[type="datetime-local"], @@ -265,11 +237,15 @@ input[type="color"] { color: $dark-orange; border: 1px solid $dark-orange; } } -.error{ +.form-fields-error{ + .form-fields { + color: $dark-red; + } + textarea, input[type="text"], input[type="password"], input[type="datetime"], input[type="datetime-local"], @@ -286,5 +262,46 @@ color: $dark-red; border: 1px solid $dark-red; } } +/* Form controls */ +/* ------------- */ + +.form-fields { + margin: 8px 0; + + .help-hint { + display: inline-block; + } + + + label { + font-weight: bold; + } +} + +.checkbox-fields { + vertical-align: middle; + margin: 8px 0 15px 0; + + + input[type="checkbox"] { + margin-right: 5px; + } +} + + +@media only screen and (max-width: 768px) { + .horizontal-form { + .form-fields { + label { + display: block; + text-align: left; + } + } + + .form-actions { + margin-left: 0; + } + } +}