Skip to content

Upgrade to Bootstrap v4.6.2 #230

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Jul 3, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions _sass/_variables.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
// Customize default style definitions of Bootstrap.
@import 'colors';

$link-decoration: underline;

$card-bg: $gray-100;

$card-border-width: 0;

$container-max-widths: (
sm: 540px,
md: 720px,
lg: 960px,
xl: 1360px
);

$grid-breakpoints: (
xs: 0,
sm: 576px,
md: 768px,
lg: 992px,
xl: 1400px
);
1 change: 1 addition & 0 deletions _sass/bootstrap/_alert.scss
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
position: absolute;
top: 0;
right: 0;
z-index: 2;
padding: $alert-padding-y $alert-padding-x;
color: inherit;
}
Expand Down
4 changes: 1 addition & 3 deletions _sass/bootstrap/_breadcrumb.scss
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,12 @@
}

.breadcrumb-item {
display: flex;

// The separator between breadcrumbs (by default, a forward-slash: "/")
+ .breadcrumb-item {
padding-left: $breadcrumb-item-padding;

&::before {
display: inline-block; // Suppress underlining of the separator in modern browsers
float: left; // Suppress inline spacings and underlining of the separator
padding-right: $breadcrumb-item-padding;
color: $breadcrumb-divider-color;
content: escape-svg($breadcrumb-divider);
Expand Down
18 changes: 9 additions & 9 deletions _sass/bootstrap/_card.scss
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@
}

.card-subtitle {
margin-top: -$card-spacer-y / 2;
margin-top: -$card-spacer-y * .5;
margin-bottom: 0;
}

Expand Down Expand Up @@ -109,15 +109,15 @@
//

.card-header-tabs {
margin-right: -$card-spacer-x / 2;
margin-right: -$card-spacer-x * .5;
margin-bottom: -$card-spacer-y;
margin-left: -$card-spacer-x / 2;
margin-left: -$card-spacer-x * .5;
border-bottom: 0;
}

.card-header-pills {
margin-right: -$card-spacer-x / 2;
margin-left: -$card-spacer-x / 2;
margin-right: -$card-spacer-x * .5;
margin-left: -$card-spacer-x * .5;
}

// Card image
Expand Down Expand Up @@ -206,12 +206,12 @@

.card-img-top,
.card-header {
// stylelint-disable-next-line property-blacklist
// stylelint-disable-next-line property-disallowed-list
border-top-right-radius: 0;
}
.card-img-bottom,
.card-footer {
// stylelint-disable-next-line property-blacklist
// stylelint-disable-next-line property-disallowed-list
border-bottom-right-radius: 0;
}
}
Expand All @@ -221,12 +221,12 @@

.card-img-top,
.card-header {
// stylelint-disable-next-line property-blacklist
// stylelint-disable-next-line property-disallowed-list
border-top-left-radius: 0;
}
.card-img-bottom,
.card-footer {
// stylelint-disable-next-line property-blacklist
// stylelint-disable-next-line property-disallowed-list
border-bottom-left-radius: 0;
}
}
Expand Down
9 changes: 6 additions & 3 deletions _sass/bootstrap/_carousel.scss
Original file line number Diff line number Diff line change
Expand Up @@ -95,8 +95,11 @@
align-items: center; // 2. vertically center contents
justify-content: center; // 3. horizontally center contents
width: $carousel-control-width;
padding: 0;
color: $carousel-control-color;
text-align: center;
background: none;
border: 0;
opacity: $carousel-control-opacity;
@include transition($carousel-control-transition);

Expand Down Expand Up @@ -127,7 +130,7 @@
display: inline-block;
width: $carousel-control-icon-width;
height: $carousel-control-icon-width;
background: no-repeat 50% / 100% 100%;
background: 50% / 100% 100% no-repeat;
}
.carousel-control-prev-icon {
background-image: escape-svg($carousel-control-prev-icon-bg);
Expand Down Expand Up @@ -186,9 +189,9 @@

.carousel-caption {
position: absolute;
right: (100% - $carousel-caption-width) / 2;
right: (100% - $carousel-caption-width) * .5;
bottom: 20px;
left: (100% - $carousel-caption-width) / 2;
left: (100% - $carousel-caption-width) * .5;
z-index: 10;
padding-top: 20px;
padding-bottom: 20px;
Expand Down
29 changes: 16 additions & 13 deletions _sass/bootstrap/_custom-forms.scss
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
display: block;
min-height: $font-size-base * $line-height-base;
padding-left: $custom-control-gutter + $custom-control-indicator-size;
print-color-adjust: exact; // Keep themed appearance for print
}

.custom-control-inline {
Expand All @@ -25,7 +26,7 @@
left: 0;
z-index: -1; // Put the input behind the label so it doesn't overlay text
width: $custom-control-indicator-size;
height: ($font-size-base * $line-height-base + $custom-control-indicator-size) / 2;
height: ($font-size-base * $line-height-base + $custom-control-indicator-size) * .5;
opacity: 0;

&:checked ~ .custom-control-label::before {
Expand All @@ -38,7 +39,7 @@
&:focus ~ .custom-control-label::before {
// the mixin is not used here to make sure there is feedback
@if $enable-shadows {
box-shadow: $input-box-shadow, $input-focus-box-shadow;
box-shadow: $input-box-shadow, $custom-control-indicator-focus-box-shadow;
} @else {
box-shadow: $custom-control-indicator-focus-box-shadow;
}
Expand Down Expand Up @@ -82,28 +83,28 @@
// Background-color and (when enabled) gradient
&::before {
position: absolute;
top: ($font-size-base * $line-height-base - $custom-control-indicator-size) / 2;
top: ($font-size-base * $line-height-base - $custom-control-indicator-size) * .5;
left: -($custom-control-gutter + $custom-control-indicator-size);
display: block;
width: $custom-control-indicator-size;
height: $custom-control-indicator-size;
pointer-events: none;
content: "";
background-color: $custom-control-indicator-bg;
border: $custom-control-indicator-border-color solid $custom-control-indicator-border-width;
border: $custom-control-indicator-border-width solid $custom-control-indicator-border-color;
@include box-shadow($custom-control-indicator-box-shadow);
}

// Foreground (icon)
&::after {
position: absolute;
top: ($font-size-base * $line-height-base - $custom-control-indicator-size) / 2;
top: ($font-size-base * $line-height-base - $custom-control-indicator-size) * .5;
left: -($custom-control-gutter + $custom-control-indicator-size);
display: block;
width: $custom-control-indicator-size;
height: $custom-control-indicator-size;
content: "";
background: no-repeat 50% / #{$custom-control-indicator-bg-size};
background: 50% / #{$custom-control-indicator-bg-size} no-repeat;
}
}

Expand Down Expand Up @@ -150,7 +151,7 @@

.custom-radio {
.custom-control-label::before {
// stylelint-disable-next-line property-blacklist
// stylelint-disable-next-line property-disallowed-list
border-radius: $custom-radio-indicator-border-radius;
}

Expand Down Expand Up @@ -180,17 +181,17 @@
left: -($custom-switch-width + $custom-control-gutter);
width: $custom-switch-width;
pointer-events: all;
// stylelint-disable-next-line property-blacklist
// stylelint-disable-next-line property-disallowed-list
border-radius: $custom-switch-indicator-border-radius;
}

&::after {
top: add(($font-size-base * $line-height-base - $custom-control-indicator-size) / 2, $custom-control-indicator-border-width * 2);
top: add(($font-size-base * $line-height-base - $custom-control-indicator-size) * .5, $custom-control-indicator-border-width * 2);
left: add(-($custom-switch-width + $custom-control-gutter), $custom-control-indicator-border-width * 2);
width: $custom-switch-indicator-size;
height: $custom-switch-indicator-size;
background-color: $custom-control-indicator-border-color;
// stylelint-disable-next-line property-blacklist
// stylelint-disable-next-line property-disallowed-list
border-radius: $custom-switch-indicator-border-radius;
@include transition(transform .15s ease-in-out, $custom-forms-transition);
}
Expand Down Expand Up @@ -314,6 +315,7 @@
width: 100%;
height: $custom-file-height;
margin: 0;
overflow: hidden;
opacity: 0;

&:focus ~ .custom-file-label {
Expand Down Expand Up @@ -346,6 +348,7 @@
z-index: 1;
height: $custom-file-height;
padding: $custom-file-padding-y $custom-file-padding-x;
overflow: hidden;
font-family: $custom-file-font-family;
font-weight: $custom-file-font-weight;
line-height: $custom-file-line-height;
Expand Down Expand Up @@ -387,7 +390,7 @@
appearance: none;

&:focus {
outline: none;
outline: 0;

// Pseudo-elements must be split across multiple rulesets to have an effect.
// No box-shadow() mixin for focus accessibility.
Expand All @@ -403,7 +406,7 @@
&::-webkit-slider-thumb {
width: $custom-range-thumb-width;
height: $custom-range-thumb-height;
margin-top: ($custom-range-track-height - $custom-range-thumb-height) / 2; // Webkit specific
margin-top: ($custom-range-track-height - $custom-range-thumb-height) * .5; // Webkit specific
@include gradient-bg($custom-range-thumb-bg);
border: $custom-range-thumb-border;
@include border-radius($custom-range-thumb-border-radius);
Expand Down Expand Up @@ -478,7 +481,7 @@
cursor: $custom-range-track-cursor;
background-color: transparent;
border-color: transparent;
border-width: $custom-range-thumb-height / 2;
border-width: $custom-range-thumb-height * .5;
@include box-shadow($custom-range-track-box-shadow);
}

Expand Down
4 changes: 2 additions & 2 deletions _sass/bootstrap/_dropdown.scss
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
display: none; // none by default, but block on "open" of the menu
float: left;
min-width: $dropdown-min-width;
padding: $dropdown-padding-y 0;
padding: $dropdown-padding-y $dropdown-padding-x;
margin: $dropdown-spacer 0 0; // override default ul
@include font-size($dropdown-font-size);
color: $dropdown-color;
Expand Down Expand Up @@ -100,7 +100,7 @@
}
}

// When enabled Popper.js, reset basic dropdown position
// When Popper is enabled, reset the basic dropdown position
// stylelint-disable-next-line no-duplicate-selectors
.dropdown-menu {
&[x-placement^="top"],
Expand Down
20 changes: 10 additions & 10 deletions _sass/bootstrap/_forms.scss
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,6 @@
border: 0;
}

// Remove select outline from select box in FF
&:-moz-focusring {
color: transparent;
text-shadow: 0 0 0 $input-color;
}

// Customize the `:focus` state to imitate native WebKit styles.
@include form-control-focus($ignore-warning: true);

Expand Down Expand Up @@ -69,6 +63,12 @@ input[type="month"] {
}

select.form-control {
// Remove select outline from select box in FF
&:-moz-focusring {
color: transparent;
text-shadow: 0 0 0 $input-color;
}

&:focus::-ms-value {
// Suppress the nested default white text on blue background highlight given to
// the selected option text when the (still closed) <select> receives focus
Expand Down Expand Up @@ -199,13 +199,13 @@ textarea.form-control {
.form-row {
display: flex;
flex-wrap: wrap;
margin-right: -$form-grid-gutter-width / 2;
margin-left: -$form-grid-gutter-width / 2;
margin-right: -$form-grid-gutter-width * .5;
margin-left: -$form-grid-gutter-width * .5;

> .col,
> [class*="col-"] {
padding-right: $form-grid-gutter-width / 2;
padding-left: $form-grid-gutter-width / 2;
padding-right: $form-grid-gutter-width * .5;
padding-left: $form-grid-gutter-width * .5;
}
}

Expand Down
Loading