update assets from bootstrap@3.3.7

This commit is contained in:
Vu Nguyen
2021-01-14 20:39:47 -06:00
parent 3deee881b1
commit ba3182fd59
73 changed files with 3046 additions and 5453 deletions

View File

@@ -1,19 +1,22 @@
// stylelint-disable selector-no-qualifying-type, property-no-vendor-prefix, media-feature-name-no-vendor-prefix
//
// Forms
// --------------------------------------------------
// Normalize non-controls
//
// Restyle and baseline non-control form elements.
fieldset {
padding: 0;
margin: 0;
border: 0;
// Chrome and Firefox set a `min-width: min-content;` on fieldsets,
// so we reset that to ensure it behaves more like a standard block element.
// See https://github.com/twbs/bootstrap/issues/12359.
min-width: 0;
padding: 0;
margin: 0;
border: 0;
}
legend {
@@ -32,34 +35,54 @@ label {
display: inline-block;
max-width: 100%; // Force IE8 to wrap long content (see https://github.com/twbs/bootstrap/issues/13141)
margin-bottom: 5px;
font-weight: bold;
font-weight: 700;
}
// Normalize form controls
//
// While most of our form styles require extra classes, some basic normalization
// is required to ensure optimum display with or without those classes to better
// address browser inconsistencies.
// Override content-box in Normalize (* isn't specific enough)
input[type='search'] {
input[type="search"] {
// Override content-box in Normalize (* isn't specific enough)
.box-sizing(border-box);
// Search inputs in iOS
//
// This overrides the extra rounded corners on search inputs in iOS so that our
// `.form-control` class can properly style them. Note that this cannot simply
// be added to `.form-control` as it's not specific enough. For details, see
// https://github.com/twbs/bootstrap/issues/11586.
-webkit-appearance: none;
appearance: none;
}
// Position radios and checkboxes better
input[type='radio'],
input[type='checkbox'] {
input[type="radio"],
input[type="checkbox"] {
margin: 4px 0 0;
margin-top: 1px \9; // IE8-9
line-height: normal;
// Apply same disabled cursor tweak as for inputs
// Some special care is needed because <label>s don't inherit their parent's `cursor`.
//
// Note: Neither radios nor checkboxes can be readonly.
&[disabled],
&.disabled,
fieldset[disabled] & {
cursor: @cursor-disabled;
}
}
input[type='file'] {
input[type="file"] {
display: block;
}
// Make range inputs behave like textual form controls
input[type='range'] {
input[type="range"] {
display: block;
width: 100%;
}
@@ -71,9 +94,9 @@ select[size] {
}
// Focus for file, radio, and checkbox
input[type='file']:focus,
input[type='radio']:focus,
input[type='checkbox']:focus {
input[type="file"]:focus,
input[type="radio"]:focus,
input[type="checkbox"]:focus {
.tab-focus();
}
@@ -86,6 +109,7 @@ output {
color: @input-color;
}
// Common form controls
//
// Shared size and type resets for form controls. Apply `.form-control` to any
@@ -120,8 +144,8 @@ output {
background-image: none; // Reset unusual Firefox-on-Android default style; see https://github.com/necolas/normalize.css/issues/214
border: 1px solid @input-border;
border-radius: @input-border-radius; // Note: This has no effect on <select>s in some browsers, due to the limited stylability of <select>s in CSS.
.box-shadow(inset 0 1px 1px rgba(0,0,0,0.075));
.transition(~'border-color ease-in-out .15s, box-shadow ease-in-out .15s');
.box-shadow(inset 0 1px 1px rgba(0, 0, 0, .075));
.transition(~"border-color ease-in-out .15s, box-shadow ease-in-out .15s");
// Customize the `:focus` state to imitate native WebKit styles.
.form-control-focus();
@@ -131,8 +155,8 @@ output {
// Unstyle the caret on `<select>`s in IE10+.
&::-ms-expand {
border: 0;
background-color: transparent;
border: 0;
}
// Disabled and read-only inputs
@@ -158,16 +182,6 @@ output {
}
}
// Search inputs in iOS
//
// This overrides the extra rounded corners on search inputs in iOS so that our
// `.form-control` class can properly style them. Note that this cannot simply
// be added to `.form-control` as it's not specific enough. For details, see
// https://github.com/twbs/bootstrap/issues/11586.
input[type='search'] {
-webkit-appearance: none;
}
// Special styles for iOS temporal inputs
//
@@ -179,10 +193,10 @@ input[type='search'] {
// Note that as of 9.3, iOS doesn't support `week`.
@media screen and (-webkit-min-device-pixel-ratio: 0) {
input[type='date'],
input[type='time'],
input[type='datetime-local'],
input[type='month'] {
input[type="date"],
input[type="time"],
input[type="datetime-local"],
input[type="month"] {
&.form-control {
line-height: @input-height-base;
}
@@ -199,6 +213,7 @@ input[type='search'] {
}
}
// Form groups
//
// Designed to help with the organization and spacing of vertical forms. For
@@ -208,6 +223,7 @@ input[type='search'] {
margin-bottom: @form-group-margin-bottom;
}
// Checkboxes and radios
//
// Indent the labels to position radios/checkboxes as hanging controls.
@@ -219,21 +235,29 @@ input[type='search'] {
margin-top: 10px;
margin-bottom: 10px;
// These are used on elements with <label> descendants
&.disabled,
fieldset[disabled] & {
label {
cursor: @cursor-disabled;
}
}
label {
min-height: @line-height-computed; // Ensure the input doesn't jump when there is no text
padding-left: 20px;
margin-bottom: 0;
font-weight: normal;
font-weight: 400;
cursor: pointer;
}
}
.radio input[type='radio'],
.radio-inline input[type='radio'],
.checkbox input[type='checkbox'],
.checkbox-inline input[type='checkbox'] {
.radio input[type="radio"],
.radio-inline input[type="radio"],
.checkbox input[type="checkbox"],
.checkbox-inline input[type="checkbox"] {
position: absolute;
margin-left: -20px;
margin-top: 4px \9;
margin-left: -20px;
}
.radio + .radio,
@@ -248,9 +272,15 @@ input[type='search'] {
display: inline-block;
padding-left: 20px;
margin-bottom: 0;
font-weight: 400;
vertical-align: middle;
font-weight: normal;
cursor: pointer;
// These are used directly on <label>s
&.disabled,
fieldset[disabled] & {
cursor: @cursor-disabled;
}
}
.radio-inline + .radio-inline,
.checkbox-inline + .checkbox-inline {
@@ -258,36 +288,6 @@ input[type='search'] {
margin-left: 10px; // space out consecutive inline controls
}
// Apply same disabled cursor tweak as for inputs
// Some special care is needed because <label>s don't inherit their parent's `cursor`.
//
// Note: Neither radios nor checkboxes can be readonly.
input[type='radio'],
input[type='checkbox'] {
&[disabled],
&.disabled,
fieldset[disabled] & {
cursor: @cursor-disabled;
}
}
// These classes are used directly on <label>s
.radio-inline,
.checkbox-inline {
&.disabled,
fieldset[disabled] & {
cursor: @cursor-disabled;
}
}
// These classes are used on elements with <label> descendants
.radio,
.checkbox {
&.disabled,
fieldset[disabled] & {
label {
cursor: @cursor-disabled;
}
}
}
// Static form control text
//
@@ -295,20 +295,21 @@ input[type='checkbox'] {
// a horizontal form layout.
.form-control-static {
min-height: (@line-height-computed + @font-size-base);
// 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;
min-height: (@line-height-computed + @font-size-base);
&.input-lg,
&.input-sm {
padding-left: 0;
padding-right: 0;
padding-left: 0;
}
}
// Form control sizing
//
// Build on `.form-control` with modifier classes to decrease or increase the
@@ -373,6 +374,7 @@ input[type='checkbox'] {
}
}
// Form control feedback states
//
// Apply contextual and semantic states to individual form controls.
@@ -427,6 +429,7 @@ input[type='checkbox'] {
// Reposition feedback icon if input has visible label above
.has-feedback label {
& ~ .form-control-feedback {
top: (@line-height-computed + 5); // Height of the `label` and its margin
}
@@ -435,6 +438,7 @@ input[type='checkbox'] {
}
}
// Help text
//
// Apply to any element you wish to create light text for placement immediately
@@ -447,6 +451,7 @@ input[type='checkbox'] {
color: lighten(@text-color, 25%); // lighten the text some for contrast
}
// Inline forms
//
// Make forms appear inline(-block) by adding the `.form-inline` class. Inline
@@ -459,6 +464,7 @@ input[type='checkbox'] {
// Heads up! This is mixin-ed into `.navbar-form` in navbars.less.
.form-inline {
// Kick in the inline
@media (min-width: @screen-sm-min) {
// Inline-block all the things for "inline"
@@ -514,8 +520,8 @@ input[type='checkbox'] {
padding-left: 0;
}
}
.radio input[type='radio'],
.checkbox input[type='checkbox'] {
.radio input[type="radio"],
.checkbox input[type="checkbox"] {
position: relative;
margin-left: 0;
}
@@ -527,12 +533,14 @@ input[type='checkbox'] {
}
}
// Horizontal forms
//
// Horizontal forms are built on grid classes and allow you to create forms with
// labels on the left and inputs on the right.
.form-horizontal {
// Consistent vertical alignment of radios and checkboxes
//
// Labels also get some reset styles, but that is scoped to a media query below.
@@ -540,9 +548,9 @@ input[type='checkbox'] {
.checkbox,
.radio-inline,
.checkbox-inline {
padding-top: (@padding-base-vertical + 1); // Default padding plus a border
margin-top: 0;
margin-bottom: 0;
padding-top: (@padding-base-vertical + 1); // Default padding plus a border
}
// Account for padding we're adding to ensure the alignment and of help text
// and other content below items
@@ -560,9 +568,9 @@ input[type='checkbox'] {
// labels on narrow viewports stack the same as a default form example.
@media (min-width: @screen-sm-min) {
.control-label {
text-align: right;
margin-bottom: 0;
padding-top: (@padding-base-vertical + 1); // Default padding plus a border
margin-bottom: 0;
text-align: right;
}
}