aboutsummaryrefslogtreecommitdiff
path: root/scss/_custom-forms.scss
diff options
context:
space:
mode:
authorMartijn Cuppens <[email protected]>2018-10-21 09:25:07 +0200
committerXhmikosR <[email protected]>2018-10-21 10:25:07 +0300
commite2014e8ed71a0c68a5cc436b0393486d0945fafe (patch)
treed7da1586a9397507fbb873bc6cf496d3dcdda0bd /scss/_custom-forms.scss
parentc9a43b027ab74f829cc117a05261e18ff4ca3b7c (diff)
downloadbootstrap-e2014e8ed71a0c68a5cc436b0393486d0945fafe.tar.xz
bootstrap-e2014e8ed71a0c68a5cc436b0393486d0945fafe.zip
Custom checkboxes and radios retheming (#27064)
Diffstat (limited to 'scss/_custom-forms.scss')
-rw-r--r--scss/_custom-forms.scss20
1 files changed, 13 insertions, 7 deletions
diff --git a/scss/_custom-forms.scss b/scss/_custom-forms.scss
index a0ec3f6b1..23e50ba3e 100644
--- a/scss/_custom-forms.scss
+++ b/scss/_custom-forms.scss
@@ -26,18 +26,28 @@
&:checked ~ .custom-control-label::before {
color: $custom-control-indicator-checked-color;
+ border-color: $custom-control-indicator-checked-border-color;
@include gradient-bg($custom-control-indicator-checked-bg);
@include box-shadow($custom-control-indicator-checked-box-shadow);
}
&:focus ~ .custom-control-label::before {
// the mixin is not used here to make sure there is feedback
- box-shadow: $custom-control-indicator-focus-box-shadow;
+ @if $enable-shadows {
+ box-shadow: $input-box-shadow, $input-focus-box-shadow;
+ } @else {
+ box-shadow: $custom-control-indicator-focus-box-shadow;
+ }
+ }
+
+ &:focus:not(:checked) ~ .custom-control-label::before {
+ border-color: $custom-control-indicator-focus-border-color;
}
&:active ~ .custom-control-label::before {
color: $custom-control-indicator-active-color;
background-color: $custom-control-indicator-active-bg;
+ border-color: $custom-control-indicator-active-border-color;
@include box-shadow($custom-control-indicator-active-box-shadow);
}
@@ -71,6 +81,7 @@
pointer-events: none;
content: "";
background-color: $custom-control-indicator-bg;
+ border: $custom-control-indicator-border-color solid $custom-control-indicator-border-width;
@include box-shadow($custom-control-indicator-box-shadow);
}
@@ -100,9 +111,6 @@
}
.custom-control-input:checked ~ .custom-control-label {
- &::before {
- @include gradient-bg($custom-control-indicator-checked-bg);
- }
&::after {
background-image: $custom-checkbox-indicator-icon-checked;
}
@@ -110,6 +118,7 @@
.custom-control-input:indeterminate ~ .custom-control-label {
&::before {
+ border-color: $custom-checkbox-indicator-indeterminate-border-color;
@include gradient-bg($custom-checkbox-indicator-indeterminate-bg);
@include box-shadow($custom-checkbox-indicator-indeterminate-box-shadow);
}
@@ -138,9 +147,6 @@
}
.custom-control-input:checked ~ .custom-control-label {
- &::before {
- @include gradient-bg($custom-control-indicator-checked-bg);
- }
&::after {
background-image: $custom-radio-indicator-icon-checked;
}