@swisspost/design-system-styles 6.4.0 → 6.4.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/_svg-icon-map.scss +1 -1
- package/basics.css +1 -3
- package/components/_index.scss +1 -1
- package/components/alert.scss +3 -7
- package/components/card.scss +3 -18
- package/components/datatable.scss +6 -9
- package/components/datepicker.scss +14 -4
- package/components/dropdown.scss +18 -65
- package/components/floating-label.scss +6 -5
- package/components/form-check.scss +109 -173
- package/components/form-select.scss +1 -1
- package/components/form-validation.scss +123 -0
- package/components/forms.scss +4 -2
- package/components/grid.scss +79 -14
- package/components/intranet-header/_language-chooser.scss +2 -1
- package/components/intranet-header/_logo.scss +1 -4
- package/components/intranet-header/_nav-overflow.scss +9 -4
- package/components/intranet-header/_scaffolding.scss +1 -1
- package/components/pagination.scss +22 -19
- package/components/product-card.scss +6 -1
- package/components/stepper.scss +73 -42
- package/components/subnavigation.scss +3 -4
- package/components/tabs/_tab-title.scss +1 -1
- package/components/timepicker.scss +1 -5
- package/components/toast.scss +6 -2
- package/components/topic-teaser.scss +24 -14
- package/index.css +4 -10
- package/intranet.css +4 -10
- package/mixins/_animation.scss +1 -0
- package/mixins/_button.scss +2 -1
- package/mixins/_color.scss +7 -2
- package/mixins/_form-checks.scss +0 -46
- package/mixins/_form-validation.scss +5 -0
- package/mixins/_forms.scss +4 -70
- package/mixins/_icons.scss +6 -0
- package/mixins/_notification.scss +48 -19
- package/package.json +13 -13
- package/placeholders/_dropdown.scss +0 -3
- package/placeholders/_index.scss +0 -1
- package/placeholders/_text.scss +4 -4
- package/themes/bootstrap/_core.scss +2 -0
- package/themes/bootstrap/_forms.scss +0 -2
- package/themes/bootstrap/_overrides-mixins.scss +33 -0
- package/themes/bootstrap/_overrides-variables.scss +1 -2
- package/variables/_breakpoints.scss +2 -0
- package/variables/_grid.scss +37 -9
- package/variables/components/_datatable.scss +6 -10
- package/variables/components/_form-check.scss +50 -11
- package/variables/components/{_form-feedback.scss → _form-validation.scss} +16 -12
- package/variables/components/_forms.scss +2 -2
- package/variables/components/_index.scss +1 -2
- package/variables/components/_notification.scss +4 -1
- package/variables/components/_stepper.scss +8 -7
- package/variables/components/_topic-teaser.scss +5 -0
- package/components/form-feedback.scss +0 -44
- package/placeholders/_notification.scss +0 -13
- package/themes/bootstrap/forms/_form-check.scss +0 -2
- package/variables/components/_form-switch.scss +0 -38
package/components/_index.scss
CHANGED
package/components/alert.scss
CHANGED
|
@@ -6,7 +6,6 @@
|
|
|
6
6
|
@use './../themes/bootstrap/core' as *;
|
|
7
7
|
|
|
8
8
|
@use './../mixins/notification' as notification-mx;
|
|
9
|
-
@use './../placeholders/notification' as notification-ph;
|
|
10
9
|
|
|
11
10
|
@use './../variables/breakpoints';
|
|
12
11
|
@use './../variables/commons';
|
|
@@ -18,7 +17,7 @@
|
|
|
18
17
|
@include notification-mx.notification-size(alert);
|
|
19
18
|
|
|
20
19
|
&:not(.alert-action) {
|
|
21
|
-
@
|
|
20
|
+
@include notification-mx.notification-body(alert);
|
|
22
21
|
}
|
|
23
22
|
}
|
|
24
23
|
|
|
@@ -38,17 +37,14 @@
|
|
|
38
37
|
|
|
39
38
|
> .alert-content {
|
|
40
39
|
flex: 1 1 auto;
|
|
41
|
-
@
|
|
40
|
+
@include notification-mx.notification-body(alert);
|
|
42
41
|
}
|
|
43
42
|
|
|
44
43
|
> .alert-buttons {
|
|
45
44
|
flex: 0 0 auto;
|
|
46
45
|
display: flex;
|
|
47
46
|
align-items: center;
|
|
48
|
-
|
|
49
|
-
> .btn {
|
|
50
|
-
margin-inline-start: notification.$notification-buttons-margin-start;
|
|
51
|
-
}
|
|
47
|
+
gap: notification.$notification-buttons-gap;
|
|
52
48
|
}
|
|
53
49
|
|
|
54
50
|
@include media-breakpoint-up(md) {
|
package/components/card.scss
CHANGED
|
@@ -172,40 +172,25 @@
|
|
|
172
172
|
padding-left: 0.5rem;
|
|
173
173
|
|
|
174
174
|
a {
|
|
175
|
-
display: inline-flexbox;
|
|
176
175
|
display: inline-flex;
|
|
177
176
|
align-items: center;
|
|
178
|
-
padding-
|
|
179
|
-
|
|
177
|
+
padding-inline: spacing.$size-mini;
|
|
178
|
+
gap: spacing.$size-mini;
|
|
180
179
|
color: color.$gray-60;
|
|
181
180
|
text-decoration: none;
|
|
182
181
|
-ms-flex-align: center;
|
|
183
182
|
|
|
184
183
|
&::before {
|
|
185
|
-
@include icons-mixins.
|
|
184
|
+
@include icons-mixins.icon(3020);
|
|
186
185
|
content: '';
|
|
187
186
|
display: inline-block;
|
|
188
|
-
position: relative;
|
|
189
187
|
width: icons.$icon-size-default;
|
|
190
188
|
height: icons.$icon-size-default;
|
|
191
|
-
margin-right: spacing.$spacer * 0.5;
|
|
192
|
-
|
|
193
|
-
transition: animation.$transition-fade;
|
|
194
|
-
opacity: 0.8;
|
|
195
|
-
background-repeat: no-repeat;
|
|
196
|
-
background-position: center center;
|
|
197
|
-
background-size: contain;
|
|
198
|
-
|
|
199
|
-
vertical-align: middle;
|
|
200
189
|
}
|
|
201
190
|
|
|
202
191
|
&:hover,
|
|
203
192
|
&:focus {
|
|
204
193
|
color: color.$black;
|
|
205
|
-
|
|
206
|
-
&::before {
|
|
207
|
-
opacity: 1;
|
|
208
|
-
}
|
|
209
194
|
}
|
|
210
195
|
}
|
|
211
196
|
}
|
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
@use './../variables/components/forms';
|
|
9
9
|
|
|
10
10
|
@use './../mixins/button' as button-mixins;
|
|
11
|
+
@use './../mixins/icons' as icons-mx;
|
|
11
12
|
@use './../mixins/utilities';
|
|
12
13
|
|
|
13
14
|
@use './../placeholders/text';
|
|
@@ -67,22 +68,18 @@
|
|
|
67
68
|
width: spacing.$size-regular;
|
|
68
69
|
height: spacing.$size-regular;
|
|
69
70
|
margin-left: spacing.$size-mini;
|
|
70
|
-
background-repeat: no-repeat;
|
|
71
|
-
background-size: contain;
|
|
72
71
|
|
|
73
72
|
&.datatable-icon-sort-unset {
|
|
74
|
-
|
|
75
|
-
background-position: center top, center bottom;
|
|
73
|
+
@include icons-mx.icon(2127);
|
|
76
74
|
}
|
|
77
75
|
|
|
78
|
-
&.datatable-icon-up
|
|
79
|
-
|
|
80
|
-
|
|
76
|
+
&.datatable-icon-up,
|
|
77
|
+
&.datatable-icon-down {
|
|
78
|
+
@include icons-mx.icon(2112);
|
|
81
79
|
}
|
|
82
80
|
|
|
83
81
|
&.datatable-icon-down {
|
|
84
|
-
|
|
85
|
-
background-position: center center;
|
|
82
|
+
transform: rotate(180deg);
|
|
86
83
|
}
|
|
87
84
|
}
|
|
88
85
|
|
|
@@ -123,6 +123,9 @@ span.ngb-dp-navigation-chevron {
|
|
|
123
123
|
}
|
|
124
124
|
|
|
125
125
|
.ngb-dp-open {
|
|
126
|
+
display: flex;
|
|
127
|
+
align-items: center;
|
|
128
|
+
justify-content: center;
|
|
126
129
|
position: absolute;
|
|
127
130
|
z-index: 5;
|
|
128
131
|
top: forms.$input-border-width;
|
|
@@ -132,9 +135,14 @@ span.ngb-dp-navigation-chevron {
|
|
|
132
135
|
width: forms.$input-height-inner;
|
|
133
136
|
background: transparent;
|
|
134
137
|
|
|
135
|
-
|
|
138
|
+
// DEPRECATED
|
|
136
139
|
.pi-calendar {
|
|
137
|
-
@include icons-mx.
|
|
140
|
+
@include icons-mx.icon(3203);
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
.pi-calendar,
|
|
144
|
+
.pi-3203,
|
|
145
|
+
post-icon {
|
|
138
146
|
width: datepicker.$ngb-dp-icon-size;
|
|
139
147
|
height: datepicker.$ngb-dp-icon-size;
|
|
140
148
|
transform: none;
|
|
@@ -146,7 +154,8 @@ span.ngb-dp-navigation-chevron {
|
|
|
146
154
|
width: forms.$input-height-inner-sm;
|
|
147
155
|
|
|
148
156
|
.pi-3203,
|
|
149
|
-
.pi-calendar
|
|
157
|
+
.pi-calendar,
|
|
158
|
+
post-icon {
|
|
150
159
|
width: datepicker.$ngb-dp-icon-size-sm;
|
|
151
160
|
height: datepicker.$ngb-dp-icon-size-sm;
|
|
152
161
|
}
|
|
@@ -163,7 +172,8 @@ span.ngb-dp-navigation-chevron {
|
|
|
163
172
|
width: forms.$input-height-inner-lg;
|
|
164
173
|
|
|
165
174
|
.pi-3203,
|
|
166
|
-
.pi-calendar
|
|
175
|
+
.pi-calendar,
|
|
176
|
+
post-icon {
|
|
167
177
|
width: datepicker.$ngb-dp-icon-size-lg;
|
|
168
178
|
height: datepicker.$ngb-dp-icon-size-lg;
|
|
169
179
|
}
|
package/components/dropdown.scss
CHANGED
|
@@ -3,13 +3,23 @@
|
|
|
3
3
|
@use './../lic/bootstrap-license';
|
|
4
4
|
@use './../themes/bootstrap/dropdown' as bd;
|
|
5
5
|
|
|
6
|
-
@use './../
|
|
6
|
+
@use './../placeholders/close';
|
|
7
7
|
@use './../variables/color';
|
|
8
8
|
@use './../variables/commons';
|
|
9
|
+
@use './../variables/icons';
|
|
9
10
|
@use './../variables/spacing';
|
|
10
|
-
@use './../
|
|
11
|
+
@use './../mixins/icons' as icons-mx;
|
|
11
12
|
@use './../mixins/utilities';
|
|
12
13
|
|
|
14
|
+
%toggler-icon {
|
|
15
|
+
content: '';
|
|
16
|
+
display: inline-block;
|
|
17
|
+
width: 1em;
|
|
18
|
+
height: 1em;
|
|
19
|
+
margin-left: 0.5rem;
|
|
20
|
+
border: 0;
|
|
21
|
+
}
|
|
22
|
+
|
|
13
23
|
.dropdown,
|
|
14
24
|
.dropup {
|
|
15
25
|
.dropdown-menu {
|
|
@@ -43,76 +53,19 @@
|
|
|
43
53
|
}
|
|
44
54
|
}
|
|
45
55
|
|
|
46
|
-
$gray-arrow-down: icons.get-colored-svg-url('2052', color.$gray-80);
|
|
47
|
-
$white-arrow-down: icons.get-colored-svg-url('2052', color.$white);
|
|
48
|
-
$gray-arrow-up: icons.get-colored-svg-url('2051', color.$gray-80);
|
|
49
|
-
$white-arrow-up: icons.get-colored-svg-url('2051', color.$white);
|
|
50
|
-
$hcm-arrow-down: icons.get-colored-svg-url('2052', buttonText);
|
|
51
|
-
$hcm-arrow-up: icons.get-colored-svg-url('2052', buttonText);
|
|
52
|
-
|
|
53
56
|
.dropdown-toggle {
|
|
54
57
|
&::after {
|
|
55
58
|
@extend %toggler-icon;
|
|
56
|
-
|
|
57
|
-
@include utilities.high-contrast-mode() {
|
|
58
|
-
background-image: url($hcm-arrow-down);
|
|
59
|
-
}
|
|
59
|
+
@include icons-mx.icon(2052);
|
|
60
60
|
}
|
|
61
61
|
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
background-image: url($hcm-arrow-down);
|
|
66
|
-
}
|
|
62
|
+
&[aria-expanded='true']::after,
|
|
63
|
+
.dropup &::after {
|
|
64
|
+
transform: rotate(180deg);
|
|
67
65
|
}
|
|
68
66
|
|
|
69
|
-
&[aria-expanded='true'] {
|
|
70
|
-
|
|
71
|
-
background-image: url($gray-arrow-up);
|
|
72
|
-
@include utilities.high-contrast-mode() {
|
|
73
|
-
background-image: url($hcm-arrow-up);
|
|
74
|
-
}
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
&.btn-primary::after {
|
|
78
|
-
background-image: url($white-arrow-up);
|
|
79
|
-
@include utilities.high-contrast-mode() {
|
|
80
|
-
background-image: url($hcm-arrow-up);
|
|
81
|
-
}
|
|
82
|
-
}
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
.dropup & {
|
|
86
|
-
&::after {
|
|
87
|
-
@extend %toggler-icon;
|
|
88
|
-
background-image: url($gray-arrow-up);
|
|
89
|
-
@include utilities.high-contrast-mode() {
|
|
90
|
-
background-image: url($hcm-arrow-up);
|
|
91
|
-
}
|
|
92
|
-
}
|
|
93
|
-
|
|
94
|
-
&.btn-primary::after {
|
|
95
|
-
background-image: url($white-arrow-up);
|
|
96
|
-
@include utilities.high-contrast-mode() {
|
|
97
|
-
background-image: url($hcm-arrow-up);
|
|
98
|
-
}
|
|
99
|
-
}
|
|
100
|
-
|
|
101
|
-
&[aria-expanded='true'] {
|
|
102
|
-
&::after {
|
|
103
|
-
background-image: url($gray-arrow-down);
|
|
104
|
-
@include utilities.high-contrast-mode() {
|
|
105
|
-
background-image: url($hcm-arrow-down);
|
|
106
|
-
}
|
|
107
|
-
}
|
|
108
|
-
|
|
109
|
-
&.btn-primary::after {
|
|
110
|
-
background-image: url($white-arrow-down);
|
|
111
|
-
@include utilities.high-contrast-mode() {
|
|
112
|
-
background-image: url($hcm-arrow-down);
|
|
113
|
-
}
|
|
114
|
-
}
|
|
115
|
-
}
|
|
67
|
+
.dropup &[aria-expanded='true']::after {
|
|
68
|
+
transform: rotate(0deg);
|
|
116
69
|
}
|
|
117
70
|
}
|
|
118
71
|
|
|
@@ -4,13 +4,14 @@
|
|
|
4
4
|
@forward './../variables/options';
|
|
5
5
|
|
|
6
6
|
@use './../lic/bootstrap-license';
|
|
7
|
-
@use './../themes/bootstrap/forms' as
|
|
7
|
+
@use './../themes/bootstrap/forms/floating-labels' as bffl;
|
|
8
|
+
@use './../themes/bootstrap/forms/form-control' as bffc;
|
|
8
9
|
@use './../mixins/forms' as forms-mx;
|
|
9
10
|
@use './../mixins/utilities' as utilities-mx;
|
|
10
11
|
|
|
11
12
|
@use './../variables/type';
|
|
12
13
|
@use './../variables/components/forms';
|
|
13
|
-
@use './../variables/components/form-
|
|
14
|
+
@use './../variables/components/form-validation';
|
|
14
15
|
|
|
15
16
|
.form-floating {
|
|
16
17
|
> label {
|
|
@@ -162,7 +163,7 @@
|
|
|
162
163
|
~ label {
|
|
163
164
|
width: calc(
|
|
164
165
|
100% - (forms.$input-border-width * 2) - forms.$form-floating-padding-x -
|
|
165
|
-
form-
|
|
166
|
+
form-validation.$form-feedback-icon-offset - form-validation.$form-feedback-icon-size
|
|
166
167
|
);
|
|
167
168
|
}
|
|
168
169
|
|
|
@@ -174,8 +175,8 @@
|
|
|
174
175
|
(forms.$form-floating-label-translate-x * forms.$form-floating-label-upscale * 2) -
|
|
175
176
|
(forms.$input-border-width * forms.$form-floating-label-upscale * 2) -
|
|
176
177
|
(forms.$form-floating-padding-x * forms.$form-floating-label-upscale) -
|
|
177
|
-
(form-
|
|
178
|
-
(form-
|
|
178
|
+
(form-validation.$form-feedback-icon-offset * forms.$form-floating-label-upscale) -
|
|
179
|
+
(form-validation.$form-feedback-icon-size * forms.$form-floating-label-upscale)
|
|
179
180
|
);
|
|
180
181
|
}
|
|
181
182
|
}
|
|
@@ -1,236 +1,172 @@
|
|
|
1
1
|
@forward './../variables/options';
|
|
2
2
|
|
|
3
|
-
@use '
|
|
4
|
-
@use '
|
|
5
|
-
@use '
|
|
6
|
-
@use '
|
|
7
|
-
|
|
8
|
-
@use '
|
|
9
|
-
@use './../variables/spacing';
|
|
10
|
-
@use './../variables/components/form-check';
|
|
11
|
-
@use './../variables/components/form-switch';
|
|
12
|
-
@use './../variables/components/button';
|
|
13
|
-
@use './../mixins/form-checks' as form-checks-mixins;
|
|
14
|
-
@use './../mixins/utilities';
|
|
15
|
-
@use './../functions/icons' as fi;
|
|
16
|
-
@use './../functions/icons';
|
|
3
|
+
@use '../variables/color';
|
|
4
|
+
@use '../variables/type';
|
|
5
|
+
@use '../variables/spacing';
|
|
6
|
+
@use '../variables/animation';
|
|
7
|
+
@use '../variables/components/form-check';
|
|
8
|
+
@use '../mixins/icons' as icons-mx;
|
|
17
9
|
|
|
18
10
|
.form-check {
|
|
19
11
|
display: flex;
|
|
20
12
|
flex-wrap: wrap;
|
|
21
|
-
|
|
13
|
+
row-gap: form-check.$form-check-row-gap;
|
|
14
|
+
column-gap: form-check.$form-check-column-gap;
|
|
15
|
+
margin-bottom: form-check.$form-check-margin-bottom;
|
|
22
16
|
|
|
23
|
-
&-
|
|
24
|
-
|
|
25
|
-
justify-content: flex-end;
|
|
17
|
+
&-inline {
|
|
18
|
+
display: inline-flex;
|
|
26
19
|
}
|
|
27
20
|
|
|
28
|
-
|
|
29
|
-
|
|
21
|
+
&-inline:not(:last-of-type) {
|
|
22
|
+
margin-right: form-check.$form-check-inline-margin-right;
|
|
30
23
|
}
|
|
31
24
|
|
|
25
|
+
&-input,
|
|
32
26
|
&-label {
|
|
33
|
-
|
|
34
|
-
|
|
27
|
+
color: rgba(var(--post-contrast-color-rgb), 0.8);
|
|
28
|
+
transition: color animation.$transition-base-timing;
|
|
35
29
|
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
padding: form-check.$form-check-label-padding-end;
|
|
30
|
+
&:not([disabled]) {
|
|
31
|
+
cursor: pointer;
|
|
39
32
|
}
|
|
40
33
|
|
|
41
|
-
|
|
42
|
-
|
|
34
|
+
&:hover:not([disabled]),
|
|
35
|
+
&:hover:not([disabled]) ~ &-label {
|
|
36
|
+
color: var(--post-contrast-color);
|
|
43
37
|
}
|
|
44
38
|
}
|
|
45
39
|
|
|
46
40
|
&-input {
|
|
47
|
-
|
|
48
|
-
|
|
41
|
+
display: inline-flex;
|
|
42
|
+
flex: 0 auto;
|
|
43
|
+
appearance: none;
|
|
44
|
+
background: none;
|
|
45
|
+
height: form-check.$form-check-input-size;
|
|
46
|
+
width: form-check.$form-check-input-size;
|
|
47
|
+
border: form-check.$form-check-input-border-width solid
|
|
48
|
+
rgba(var(--post-contrast-color-rgb), 0.8);
|
|
49
49
|
|
|
50
|
-
&:
|
|
51
|
-
|
|
50
|
+
&:focus {
|
|
51
|
+
outline: none;
|
|
52
|
+
border-color: currentColor;
|
|
53
|
+
box-shadow: form-check.$form-check-input-focus-box-shadow;
|
|
52
54
|
}
|
|
53
55
|
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
56
|
+
&::after {
|
|
57
|
+
content: '';
|
|
58
|
+
display: block;
|
|
59
|
+
flex: 1;
|
|
58
60
|
}
|
|
59
61
|
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
color:
|
|
63
|
-
|
|
62
|
+
&:checked,
|
|
63
|
+
&:indeterminate {
|
|
64
|
+
color: var(--post-contrast-color);
|
|
65
|
+
border-color: var(--post-contrast-color);
|
|
64
66
|
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
&[type='radio']:checked,
|
|
68
|
-
&[type='checkbox']:checked,
|
|
69
|
-
&[type='checkbox']:indeterminate {
|
|
70
|
-
background-color: transparent;
|
|
67
|
+
~ .form-check-label {
|
|
68
|
+
color: var(--post-contrast-color);
|
|
71
69
|
}
|
|
72
70
|
}
|
|
73
71
|
|
|
74
|
-
&[type='
|
|
75
|
-
|
|
76
|
-
|
|
72
|
+
&[type='checkbox'] {
|
|
73
|
+
&:checked::after {
|
|
74
|
+
@include icons-mx.icon(3035);
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
&:indeterminate::after {
|
|
78
|
+
@include icons-mx.icon(2039);
|
|
79
|
+
}
|
|
77
80
|
}
|
|
78
|
-
}
|
|
79
81
|
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
flex: 1 0 100%;
|
|
83
|
-
margin-top: form-check.$form-check-feedback-margin-top;
|
|
84
|
-
margin-left: -1 * form-check.$form-check-padding-start;
|
|
85
|
-
}
|
|
82
|
+
&[type='radio'] {
|
|
83
|
+
border-radius: 50%;
|
|
86
84
|
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
background-image: url(fi.get-colored-svg-url(2105, color.$white));
|
|
85
|
+
&:checked::after {
|
|
86
|
+
border: spacing.$size-micro solid color.$white;
|
|
87
|
+
background-color: currentColor;
|
|
88
|
+
border-radius: inherit;
|
|
92
89
|
}
|
|
90
|
+
}
|
|
93
91
|
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
}
|
|
92
|
+
&[disabled],
|
|
93
|
+
&[disabled] ~ .form-check-label {
|
|
94
|
+
border-color: rgba(var(--post-contrast-color-rgb), 0.4) !important;
|
|
95
|
+
color: rgba(var(--post-contrast-color-rgb), 0.4) !important;
|
|
96
|
+
}
|
|
100
97
|
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
border-color: graytext !important;
|
|
105
|
-
opacity: 1;
|
|
98
|
+
.form-check-sm & {
|
|
99
|
+
height: form-check.$form-check-input-size-sm;
|
|
100
|
+
width: form-check.$form-check-input-size-sm;
|
|
106
101
|
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
102
|
+
&[type='radio'] {
|
|
103
|
+
&:checked::after {
|
|
104
|
+
border-width: spacing.$size-line;
|
|
110
105
|
}
|
|
111
106
|
}
|
|
112
|
-
|
|
113
|
-
&:focus {
|
|
114
|
-
outline: 2px solid transparent;
|
|
115
|
-
}
|
|
116
107
|
}
|
|
117
108
|
}
|
|
118
|
-
}
|
|
119
109
|
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
@include form-checks-mixins.form-check-variant(
|
|
126
|
-
color.$white,
|
|
127
|
-
rgba(color.$white, 0.6),
|
|
128
|
-
rgba(color.$white, 0.8)
|
|
129
|
-
);
|
|
130
|
-
} @else if($color-contrast == color.$black) {
|
|
131
|
-
@include form-checks-mixins.form-check-variant(
|
|
132
|
-
color.$black,
|
|
133
|
-
rgba(color.$black, 0.6),
|
|
134
|
-
rgba(color.$black, 0.8)
|
|
135
|
-
);
|
|
110
|
+
&-label {
|
|
111
|
+
flex: 1;
|
|
112
|
+
|
|
113
|
+
.form-check-sm & {
|
|
114
|
+
font-size: type.$font-size-12;
|
|
136
115
|
}
|
|
137
116
|
}
|
|
138
117
|
}
|
|
139
118
|
|
|
140
119
|
.form-switch {
|
|
141
|
-
|
|
142
|
-
padding: form-switch.$form-switch-label-padding-start;
|
|
143
|
-
|
|
144
|
-
&.order-first {
|
|
145
|
-
padding: form-switch.$form-switch-label-padding-end;
|
|
146
|
-
}
|
|
147
|
-
}
|
|
120
|
+
column-gap: form-check.$form-switch-column-gap;
|
|
148
121
|
|
|
149
122
|
.form-check-input {
|
|
150
|
-
height: form-
|
|
123
|
+
height: form-check.$form-switch-height;
|
|
124
|
+
width: form-check.$form-switch-width;
|
|
151
125
|
border: 0;
|
|
152
|
-
|
|
153
|
-
background-image:
|
|
154
|
-
|
|
155
|
-
background-position:
|
|
156
|
-
background-
|
|
157
|
-
|
|
126
|
+
border-radius: form-check.$form-switch-width;
|
|
127
|
+
background-image: form-check.$form-switch-background-image;
|
|
128
|
+
background-size: 2 * form-check.$form-switch-width;
|
|
129
|
+
background-position-x: 0;
|
|
130
|
+
transition: background-color animation.$transition-base-timing,
|
|
131
|
+
background-position animation.$transition-base-timing;
|
|
158
132
|
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
@supports selector(:focus-visible) {
|
|
167
|
-
&:focus {
|
|
168
|
-
outline-color: transparent;
|
|
169
|
-
}
|
|
170
|
-
|
|
171
|
-
&:focus-visible {
|
|
172
|
-
outline: button.$input-btn-focus-width solid var(--post-contrast-color, color.$black);
|
|
173
|
-
}
|
|
133
|
+
&::after {
|
|
134
|
+
max-width: form-check.$form-switch-height;
|
|
135
|
+
background-color: form-check.$form-switch-color;
|
|
136
|
+
border: form-check.$form-check-input-border-width solid form-check.$form-switch-border-color;
|
|
137
|
+
border-radius: 50%;
|
|
138
|
+
transition: transform animation.$transition-base-timing;
|
|
174
139
|
}
|
|
175
140
|
|
|
176
141
|
&:checked {
|
|
177
|
-
background-
|
|
178
|
-
form-switch.$form-switch-linear-gradient;
|
|
179
|
-
background-position: right center, left center;
|
|
180
|
-
}
|
|
181
|
-
|
|
182
|
-
&:checked:focus {
|
|
183
|
-
background-image: escape-svg(form-switch.$form-switch-checked-bg-image),
|
|
184
|
-
form-switch.$form-switch-linear-gradient;
|
|
185
|
-
}
|
|
186
|
-
|
|
187
|
-
&:hover:not(:disabled) {
|
|
188
|
-
background-color: form-switch.$form-switch-hover-bg;
|
|
189
|
-
}
|
|
190
|
-
|
|
191
|
-
@include utilities.high-contrast-mode() {
|
|
192
|
-
--post-success: ActiveText;
|
|
193
|
-
|
|
194
|
-
// linear-gradients or statements which contains linear-gradients are disabled in firefox
|
|
195
|
-
// so we have to repeat background-image statements here without linear-gradients
|
|
142
|
+
background-position-x: form-check.$form-switch-width;
|
|
196
143
|
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
background-image: escape-svg(form-switch.$form-switch-checked-bg-image);
|
|
203
|
-
border-color: FieldText;
|
|
204
|
-
outline: none;
|
|
144
|
+
&::after {
|
|
145
|
+
@include icons-mx.remove-icon;
|
|
146
|
+
background-color: form-check.$form-switch-color;
|
|
147
|
+
border-color: form-check.$form-switch-checked-border-color;
|
|
148
|
+
transform: translateX(2rem);
|
|
205
149
|
}
|
|
150
|
+
}
|
|
206
151
|
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
}
|
|
152
|
+
&[disabled] {
|
|
153
|
+
background: form-check.$form-switch-disabled-bg;
|
|
210
154
|
|
|
211
|
-
|
|
212
|
-
|
|
155
|
+
&::after {
|
|
156
|
+
border-color: form-check.$form-switch-disabled-border-color;
|
|
213
157
|
}
|
|
158
|
+
}
|
|
159
|
+
}
|
|
214
160
|
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
161
|
+
&:hover > .form-check-input:not([disabled]) {
|
|
162
|
+
background-color: rgba(var(--post-contrast-color-rgb), 0.1);
|
|
163
|
+
}
|
|
218
164
|
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
background-image: escape-svg(form-switch.$form-switch-checked-bg-image);
|
|
222
|
-
}
|
|
165
|
+
.form-check-label {
|
|
166
|
+
padding-top: form-check.$form-switch-label-padding-top;
|
|
223
167
|
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
border-color: Highlight;
|
|
227
|
-
}
|
|
228
|
-
}
|
|
168
|
+
&.order-first {
|
|
169
|
+
flex: 0 auto;
|
|
229
170
|
}
|
|
230
171
|
}
|
|
231
|
-
|
|
232
|
-
.valid-feedback,
|
|
233
|
-
.invalid-feedback {
|
|
234
|
-
margin-left: -1 * form-switch.$form-switch-padding-start;
|
|
235
|
-
}
|
|
236
172
|
}
|