@swisspost/design-system-styles 9.0.0-next.2 → 9.0.0-next.21
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 +85 -23
- package/basics.css +1 -1
- package/basics.scss +2 -6
- package/cargo-external.css +7 -0
- package/cargo-external.scss +10 -0
- package/cargo-internal.css +7 -0
- package/cargo-internal.scss +10 -0
- package/cargo-tokens-external.css +1 -0
- package/cargo-tokens-external.scss +8 -0
- package/cargo-tokens-internal.css +1 -0
- package/cargo-tokens-internal.scss +8 -0
- package/components/_form-check.scss +166 -0
- package/components/_index.scss +21 -13
- package/components/appstore-badge.css +1 -0
- package/components/appstore-badge.scss +18 -0
- package/components/avatar.css +1 -0
- package/components/avatar.scss +41 -0
- package/components/badge.css +1 -1
- package/components/badge.scss +8 -2
- package/components/banner.css +1 -0
- package/components/banner.scss +105 -0
- package/components/blockquote.css +1 -0
- package/components/blockquote.scss +46 -0
- package/components/breadcrumb.css +1 -1
- package/components/breadcrumb.scss +4 -24
- package/components/breakpoints.css +1 -0
- package/components/breakpoints.scss +17 -0
- package/components/button-group.css +1 -1
- package/components/button-group.scss +7 -6
- package/components/button.css +1 -1
- package/components/button.scss +41 -228
- package/components/card-control.css +1 -1
- package/components/card-control.scss +33 -24
- package/components/card.css +1 -1
- package/components/card.scss +72 -68
- package/components/checkbox.css +1 -0
- package/components/checkbox.scss +127 -0
- package/components/chip.css +1 -1
- package/components/chip.scss +9 -8
- package/components/close.css +1 -1
- package/components/close.scss +0 -2
- package/components/datatable.css +1 -3
- package/components/datatable.scss +22 -17
- package/components/datepicker.css +1 -1
- package/components/datepicker.scss +6 -22
- package/components/dialog.css +1 -1
- package/components/dialog.scss +26 -38
- package/components/dropdown.css +1 -1
- package/components/dropdown.scss +9 -6
- package/components/fonts.css +1 -1
- package/components/fonts.scss +7 -45
- package/components/form-footer.css +1 -0
- package/components/form-footer.scss +18 -0
- package/components/form-hint.css +1 -0
- package/components/form-hint.scss +15 -0
- package/components/form-input.css +1 -0
- package/components/form-input.scss +301 -0
- package/components/form-range.css +1 -1
- package/components/form-range.scss +9 -9
- package/components/form-search-input.css +1 -0
- package/components/form-search-input.scss +97 -0
- package/components/form-select.css +1 -1
- package/components/form-select.scss +266 -55
- package/components/form-textarea.css +1 -1
- package/components/form-textarea.scss +172 -9
- package/components/globals/_index.scss +1 -0
- package/components/globals/post-footer.css +1 -0
- package/components/globals/post-footer.scss +113 -0
- package/components/header/_mixins.scss +48 -0
- package/components/header/index.css +1 -0
- package/components/header/index.scss +131 -0
- package/components/icon-button.css +1 -0
- package/components/icon-button.scss +19 -0
- package/components/icon-close-button.css +1 -0
- package/components/icon-close-button.scss +29 -0
- package/components/intranet-header/_icon.scss +1 -1
- package/components/intranet-header/_index.scss +0 -2
- package/components/intranet-header/_language-chooser.scss +3 -2
- package/components/intranet-header/_nav-overflow.scss +2 -2
- package/components/intranet-header/_scaffolding.scss +1 -1
- package/components/intranet-header/_searchbox.scss +1 -1
- package/components/intranet-header/_sidebar.scss +11 -11
- package/components/intranet-header/_top-navigation.scss +1 -1
- package/components/list-check.css +1 -0
- package/components/list-check.scss +79 -0
- package/components/list-group.css +1 -1
- package/components/list-group.scss +72 -127
- package/components/modal.css +2 -2
- package/components/modal.scss +2 -4
- package/components/offcanvas.css +1 -1
- package/components/offcanvas.scss +0 -2
- package/components/pagination.css +1 -1
- package/components/pagination.scss +10 -9
- package/components/popover.css +1 -1
- package/components/popover.scss +0 -2
- package/components/product-card.css +1 -1
- package/components/product-card.scss +11 -5
- package/components/progress.scss +0 -2
- package/components/radio-button.css +1 -0
- package/components/radio-button.scss +125 -0
- package/components/segmented-button.css +3 -0
- package/components/segmented-button.scss +207 -0
- package/components/skiplinks.css +1 -0
- package/components/skiplinks.scss +20 -0
- package/components/spinner.scss +0 -1
- package/components/stepper.css +1 -1
- package/components/stepper.scss +40 -33
- package/components/subnavigation.css +1 -1
- package/components/subnavigation.scss +17 -14
- package/components/switch.css +1 -0
- package/components/switch.scss +212 -0
- package/components/tables.css +1 -1
- package/components/tables.scss +0 -1
- package/components/tabs/_tab-title.scss +16 -55
- package/components/tabs/_tabs-wrapper.scss +3 -13
- package/components/tabs/index.css +1 -1
- package/components/tabs/index.scss +0 -2
- package/components/tag.css +1 -1
- package/components/tag.scss +1 -2
- package/components/teaser.css +1 -0
- package/components/teaser.scss +83 -0
- package/components/text-highlight.css +1 -1
- package/components/timepicker.css +1 -1
- package/components/timepicker.scss +13 -16
- package/components/toast.css +1 -1
- package/components/toast.scss +19 -16
- package/components/tooltip.css +1 -1
- package/components/tooltip.scss +0 -2
- package/components/transitions.scss +0 -2
- package/components/validation.css +1 -0
- package/components/validation.scss +120 -0
- package/elements/_index.scss +7 -1
- package/elements/anchor.css +1 -0
- package/elements/anchor.scss +33 -0
- package/elements/body.css +1 -1
- package/elements/body.scss +5 -1
- package/elements/fieldset-legend.css +1 -1
- package/elements/fieldset-legend.scss +7 -3
- package/elements/heading.css +1 -1
- package/elements/heading.scss +10 -12
- package/elements/list-bullet.css +1 -0
- package/elements/list-bullet.scss +43 -0
- package/elements/list-description.css +1 -0
- package/elements/list-description.scss +5 -0
- package/elements/list-number.css +1 -0
- package/elements/list-number.scss +33 -0
- package/elements/paragraph.css +1 -0
- package/elements/paragraph.scss +17 -0
- package/elements/reset.css +1 -1
- package/elements/reset.scss +16 -7
- package/elements.css +1 -0
- package/elements.scss +1 -0
- package/fonts.css +1 -1
- package/functions/_breakpoint.scss +26 -0
- package/functions/_forms.scss +46 -3
- package/functions/_icons.scss +2 -14
- package/helpers/_index.scss +4 -0
- package/helpers/clearfix.css +1 -0
- package/helpers/clearfix.scss +5 -0
- package/helpers/focus-ring.css +1 -0
- package/helpers/focus-ring.scss +5 -0
- package/helpers/text-truncation.css +1 -0
- package/helpers/text-truncation.scss +5 -0
- package/helpers/visually-hidden.css +1 -0
- package/helpers/visually-hidden.scss +5 -0
- package/index.css +3 -3
- package/index.scss +2 -5
- package/intranet.css +3 -3
- package/intranet.scss +2 -2
- package/layout/_containers.scss +32 -0
- package/layout/_section.scss +133 -0
- package/layout/grid/_index.scss +11 -0
- package/layout/grid/_mixins.scss +104 -0
- package/layout/grid/_variables.scss +2 -0
- package/layout/index.css +1 -0
- package/layout/index.scss +3 -0
- package/mixins/_button.scss +19 -15
- package/mixins/_form-checks.scss +1 -1
- package/mixins/_forms.scss +42 -33
- package/mixins/_icon-button.scss +27 -0
- package/mixins/_icons.scss +22 -32
- package/mixins/_index.scss +3 -2
- package/mixins/_layout.scss +26 -0
- package/mixins/_list.scss +112 -0
- package/mixins/_media.scss +58 -2
- package/mixins/_notification.scss +59 -53
- package/mixins/_utilities.scss +46 -25
- package/package.json +16 -16
- package/palettes/_mixins.scss +74 -0
- package/palettes/_utilities.scss +3 -0
- package/palettes/_variables.scss +2 -0
- package/palettes/cargo-palettes.css +1 -0
- package/palettes/cargo-palettes.scss +3 -0
- package/palettes/post-palettes.css +1 -0
- package/palettes/post-palettes.scss +3 -0
- package/placeholders/_button.scss +3 -6
- package/placeholders/_close.scss +2 -5
- package/placeholders/_schemes.scss +10 -0
- package/post-external.css +3 -3
- package/post-external.scss +7 -1
- package/post-internal.css +3 -3
- package/post-internal.scss +7 -1
- package/post-tokens-external.css +1 -1
- package/post-tokens-external.scss +1 -1
- package/post-tokens-internal.css +1 -1
- package/post-tokens-internal.scss +1 -1
- package/themes/bootstrap/_core.scss +0 -2
- package/themes/bootstrap/_forms.scss +0 -4
- package/themes/bootstrap/_overrides-variables.scss +0 -6
- package/themes/bootstrap/_utilities.scss +45 -1
- package/tokens/_cargo-theme.scss +8 -0
- package/tokens/_helpers.scss +1 -0
- package/tokens/_palettes.scss +9 -0
- package/tokens/_schemes.scss +11 -0
- package/tokens/_utilities_formatted.scss +1 -0
- package/tokens/temp/_channel.scss +4 -3
- package/tokens/temp/_components.scss +594 -503
- package/tokens/temp/_core.scss +49 -37
- package/tokens/temp/_device.scss +210 -239
- package/tokens/temp/_elements.scss +11 -11
- package/tokens/temp/_helpers.scss +13 -0
- package/tokens/temp/_index.scss +6 -4
- package/tokens/temp/_palettes.scss +19 -0
- package/tokens/temp/_scheme.scss +334 -0
- package/tokens/temp/_theme.scss +28 -9
- package/tokens/temp/_utilities-formatted.scss +128 -0
- package/tokens/temp/_utilities.scss +34 -58
- package/tokens/temp/palettes/_cargo-dark.scss +19 -0
- package/tokens/temp/palettes/_cargo-light.scss +19 -0
- package/tokens/temp/palettes/_post-dark.scss +19 -0
- package/tokens/temp/palettes/_post-light.scss +19 -0
- package/utilities/_not-defined.scss +44 -0
- package/utilities/_variables.scss +304 -22
- package/utilities/index.css +1 -0
- package/utilities/{_index.scss → index.scss} +1 -2
- package/variables/_animation.scss +10 -6
- package/variables/_breakpoints.scss +9 -5
- package/variables/_color.scss +0 -61
- package/variables/_commons.scss +1 -0
- package/variables/_elevation.scss +16 -22
- package/variables/_grid.scss +2 -12
- package/variables/_icons.scss +19 -696
- package/variables/_index.scss +1 -1
- package/variables/_sizing.scss +17 -0
- package/variables/_spacing.scss +0 -152
- package/variables/_type.scss +17 -27
- package/variables/components/_accordion.scss +0 -47
- package/variables/components/_badge.scss +9 -5
- package/variables/components/_button.scss +61 -113
- package/variables/components/_card.scss +7 -4
- package/variables/components/_chip.scss +13 -7
- package/variables/components/_close.scss +14 -8
- package/variables/components/_code.scss +1 -1
- package/variables/components/_datatable.scss +12 -8
- package/variables/components/_dropdowns.scss +1 -1
- package/variables/components/_form-check.scss +9 -46
- package/variables/components/_forms.scss +8 -101
- package/variables/components/_index.scss +0 -5
- package/variables/components/_modal.scss +17 -12
- package/variables/components/_nav.scss +3 -3
- package/variables/components/_navbar.scss +7 -4
- package/variables/components/_notification.scss +48 -37
- package/variables/components/_pagination.scss +14 -6
- package/variables/components/_spinners.scss +7 -2
- package/variables/components/_stepper.scss +15 -10
- package/variables/components/_subnavigation.scss +11 -9
- package/variables/components/_tables.scss +11 -6
- package/variables/components/_tag.scss +10 -7
- package/components/accordion.css +0 -1
- package/components/accordion.scss +0 -100
- package/components/alert.css +0 -1
- package/components/alert.scss +0 -137
- package/components/carousel.css +0 -1
- package/components/carousel.scss +0 -178
- package/components/elevation.css +0 -1
- package/components/elevation.scss +0 -8
- package/components/floating-label.css +0 -1
- package/components/floating-label.scss +0 -353
- package/components/form-check.css +0 -1
- package/components/form-check.scss +0 -297
- package/components/form-validation.css +0 -1
- package/components/form-validation.scss +0 -148
- package/components/forms.css +0 -1
- package/components/forms.scss +0 -215
- package/components/grid.css +0 -1
- package/components/grid.scss +0 -170
- package/components/icons.css +0 -1
- package/components/icons.scss +0 -60
- package/components/sizing.css +0 -1
- package/components/sizing.scss +0 -85
- package/components/topic-teaser.css +0 -1
- package/components/topic-teaser.scss +0 -196
- package/layouts/portal/_grid.scss +0 -85
- package/layouts/portal/_index.scss +0 -2
- package/layouts/portal/_subnavigation.scss +0 -5
- package/layouts/portal/_variables.scss +0 -8
- package/mixins/_accordion.scss +0 -16
- package/mixins/_elevation.scss +0 -6
- package/mixins/_focus.scss +0 -9
- package/mixins/_form-validation.scss +0 -5
- package/mixins/_size.scss +0 -65
- package/placeholders/_modes.scss +0 -10
- package/themes/bootstrap/_carousel.scss +0 -2
- package/themes/bootstrap/_containers.scss +0 -2
- package/themes/bootstrap/_grid.scss +0 -2
- package/themes/bootstrap/_overrides-mixins.scss +0 -33
- package/themes/bootstrap/forms/_floating-labels.scss +0 -2
- package/themes/bootstrap/forms/_form-control.scss +0 -2
- package/themes/bootstrap/forms/_form-select.scss +0 -2
- package/themes/bootstrap/forms/_form-text.scss +0 -2
- package/tokens/_modes.scss +0 -11
- package/tokens/temp/_mode.scss +0 -299
- package/utilities/_functions.scss +0 -35
- package/utilities/temp/_legacy.scss +0 -95
- package/variables/_options.scss +0 -5
- package/variables/components/_carousel.scss +0 -27
- package/variables/components/_figures.scss +0 -6
- package/variables/components/_form-select.scss +0 -13
- package/variables/components/_form-validation.scss +0 -38
- package/variables/components/_list-group.scss +0 -29
- package/variables/components/_topic-teaser.scss +0 -32
package/components/button.scss
CHANGED
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
@forward './../variables/options';
|
|
2
|
-
|
|
3
1
|
@use 'sass:map';
|
|
4
2
|
@use 'sass:math';
|
|
5
3
|
|
|
@@ -13,9 +11,15 @@
|
|
|
13
11
|
@use './../mixins/utilities';
|
|
14
12
|
@use './../mixins/forms';
|
|
15
13
|
@use './../mixins/button' as button-mx;
|
|
14
|
+
@use './../mixins/icon-button' as icon-button-mx;
|
|
16
15
|
@use './../functions/icons' as icon-fn;
|
|
17
16
|
@use './../functions/color' as color-fn;
|
|
18
17
|
@use './../placeholders/button' as button-ph;
|
|
18
|
+
@use '../functions/tokens';
|
|
19
|
+
@use '../tokens/components';
|
|
20
|
+
@use '../tokens/elements';
|
|
21
|
+
|
|
22
|
+
tokens.$default-map: components.$post-button;
|
|
19
23
|
|
|
20
24
|
.btn {
|
|
21
25
|
// Resets
|
|
@@ -26,269 +30,78 @@
|
|
|
26
30
|
max-width: 100%;
|
|
27
31
|
overflow: hidden;
|
|
28
32
|
transition: button.$btn-transition;
|
|
29
|
-
border-width: button
|
|
33
|
+
border-width: tokens.get('button-border-width');
|
|
30
34
|
border-style: solid;
|
|
31
|
-
border-radius: button
|
|
35
|
+
border-radius: tokens.get('button-border-radius-round');
|
|
32
36
|
background-color: transparent;
|
|
33
37
|
box-shadow: none;
|
|
34
|
-
color: var(--post-gray-80);
|
|
35
38
|
font-family: inherit;
|
|
36
|
-
font-weight: button
|
|
37
|
-
text-decoration: none
|
|
39
|
+
font-weight: tokens.get('button-label-font-weight');
|
|
40
|
+
text-decoration: none;
|
|
38
41
|
white-space: nowrap; // Long content should never break in buttons
|
|
39
42
|
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
@include utilities.disabled-style() {
|
|
43
|
-
text-decoration: line-through !important;
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
@include utilities.not-disabled-hover() {
|
|
47
|
-
color: var(--post-contrast-color-inverted); // Override <a> color
|
|
48
|
-
background-color: color.$gray-60;
|
|
43
|
+
&:hover {
|
|
44
|
+
text-decoration: none;
|
|
49
45
|
}
|
|
50
46
|
|
|
51
|
-
@include
|
|
52
|
-
border-radius: commons.$border-radius;
|
|
53
|
-
color: var(--post-contrast-color-inverted); // Override <a> color
|
|
54
|
-
background-color: color.$gray-60;
|
|
47
|
+
@include button-mx.button-size();
|
|
55
48
|
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
}
|
|
49
|
+
&:disabled {
|
|
50
|
+
border-style: tokens.get('button-border-style-disabled');
|
|
59
51
|
}
|
|
60
52
|
|
|
61
|
-
@include
|
|
62
|
-
&:disabled {
|
|
63
|
-
color: color.$white-alpha-80;
|
|
64
|
-
}
|
|
53
|
+
@include utilities.focus-style;
|
|
65
54
|
|
|
66
|
-
@include utilities.not-disabled-hover() {
|
|
67
|
-
background-color: color.$yellow;
|
|
68
|
-
border-color: transparent;
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
@include utilities.focus-style() {
|
|
72
|
-
background-color: color.$yellow;
|
|
73
|
-
border-color: transparent;
|
|
74
|
-
}
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
// Styles to improve accessibility in high contrast mode
|
|
78
55
|
@include utilities.high-contrast-mode() {
|
|
79
|
-
|
|
80
|
-
background-color: ButtonFace;
|
|
56
|
+
background-color: ButtonFace !important;
|
|
81
57
|
|
|
82
58
|
&:not(:disabled, .disabled) {
|
|
83
59
|
&:hover {
|
|
84
|
-
|
|
60
|
+
background-color: Highlight !important;
|
|
85
61
|
}
|
|
86
62
|
}
|
|
87
|
-
|
|
88
|
-
&:disabled {
|
|
89
|
-
border-color: GrayText !important;
|
|
90
|
-
}
|
|
91
|
-
|
|
92
|
-
.pi {
|
|
93
|
-
filter: invert(1) !important;
|
|
94
|
-
}
|
|
95
63
|
}
|
|
96
64
|
}
|
|
97
65
|
|
|
98
|
-
//
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
color: var(--post-contrast-color-inverted);
|
|
103
|
-
|
|
104
|
-
&:disabled {
|
|
105
|
-
background-color: color.$gray-10;
|
|
106
|
-
border-color: color.$gray-60;
|
|
107
|
-
}
|
|
108
|
-
|
|
109
|
-
.pi {
|
|
110
|
-
filter: invert(1);
|
|
111
|
-
forced-color-adjust: none;
|
|
112
|
-
}
|
|
113
|
-
|
|
114
|
-
@include color-mx.on-dark-background {
|
|
115
|
-
background-color: var(--post-contrast-color);
|
|
116
|
-
color: var(--post-gray-10); // Apply same color as secondary/tertiary button on dark theme
|
|
117
|
-
|
|
118
|
-
&:disabled {
|
|
119
|
-
color: var(--post-contrast-color);
|
|
120
|
-
background-color: color.$white-alpha-20;
|
|
121
|
-
border-color: var(--post-contrast-color);
|
|
122
|
-
}
|
|
123
|
-
}
|
|
66
|
+
// Type variants
|
|
67
|
+
@each $variant in button.$btn-variants {
|
|
68
|
+
.btn-#{$variant} {
|
|
69
|
+
$color: if($variant == 'default', 'secondary', if($variant == 'link', 'tertiary', $variant));
|
|
124
70
|
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
filter: invert(0);
|
|
71
|
+
@if ($variant != 'link' and $variant != 'tertiary') {
|
|
72
|
+
box-shadow: tokens.get('button-elevation');
|
|
128
73
|
}
|
|
129
|
-
}
|
|
130
|
-
}
|
|
131
74
|
|
|
132
|
-
|
|
133
|
-
.btn-default,
|
|
134
|
-
.btn-secondary {
|
|
135
|
-
@extend %btn-transparent-background;
|
|
136
|
-
border-color: color.$gray-60;
|
|
137
|
-
|
|
138
|
-
@include color-mx.on-dark-background {
|
|
139
|
-
border-color: var(--post-contrast-color);
|
|
140
|
-
color: var(--post-contrast-color);
|
|
75
|
+
@include button-mx.button-variant-def('enabled', $color);
|
|
141
76
|
|
|
142
77
|
&:disabled {
|
|
143
|
-
|
|
144
|
-
border-color: color.$white-alpha-60;
|
|
145
|
-
}
|
|
146
|
-
}
|
|
147
|
-
}
|
|
148
|
-
|
|
149
|
-
// Tertiary
|
|
150
|
-
.btn-link,
|
|
151
|
-
.btn-tertiary {
|
|
152
|
-
@extend %btn-transparent-background;
|
|
153
|
-
border: 0;
|
|
154
|
-
padding-inline: spacing.$size-micro;
|
|
155
|
-
|
|
156
|
-
// Styles to improve accessibility in high contrast mode
|
|
157
|
-
@include utilities.high-contrast-mode() {
|
|
158
|
-
color: linktext;
|
|
159
|
-
text-decoration: underline !important;
|
|
160
|
-
}
|
|
161
|
-
}
|
|
162
|
-
|
|
163
|
-
// Icon
|
|
164
|
-
.btn-icon {
|
|
165
|
-
@include button-mx.icon-button();
|
|
166
|
-
|
|
167
|
-
@each $size in button.$btn-non-default-sizes {
|
|
168
|
-
&.btn-#{$size} {
|
|
169
|
-
@include button-mx.icon-button($size);
|
|
170
|
-
}
|
|
171
|
-
}
|
|
172
|
-
}
|
|
173
|
-
|
|
174
|
-
// Animated
|
|
175
|
-
|
|
176
|
-
.btn-animated,
|
|
177
|
-
.btn-animated-start {
|
|
178
|
-
&:not(.btn-link, .btn-tertiary) {
|
|
179
|
-
&::after {
|
|
180
|
-
@include icon-mx.icon(2111);
|
|
181
|
-
content: '';
|
|
182
|
-
display: block;
|
|
183
|
-
height: 2em;
|
|
184
|
-
width: 2em;
|
|
185
|
-
position: absolute;
|
|
186
|
-
transition:
|
|
187
|
-
opacity 250ms,
|
|
188
|
-
transform 250ms;
|
|
189
|
-
opacity: 0;
|
|
190
|
-
}
|
|
191
|
-
|
|
192
|
-
> span {
|
|
193
|
-
transition: transform 250ms;
|
|
78
|
+
@include button-mx.button-variant-def('disabled', $color);
|
|
194
79
|
}
|
|
195
80
|
|
|
196
|
-
@
|
|
197
|
-
@include
|
|
198
|
-
&::after {
|
|
199
|
-
transform: translateX(0);
|
|
200
|
-
opacity: 1;
|
|
201
|
-
}
|
|
202
|
-
}
|
|
203
|
-
|
|
204
|
-
> span {
|
|
205
|
-
// Initially transform to place text in the right rendering context for a smooth animation
|
|
206
|
-
transform: translateX(0);
|
|
207
|
-
}
|
|
208
|
-
}
|
|
209
|
-
}
|
|
210
|
-
}
|
|
211
|
-
|
|
212
|
-
.btn-animated:not(.btn-link, .btn-tertiary) {
|
|
213
|
-
&::after {
|
|
214
|
-
right: button.$btn-padding-x-md - button.$btn-animation-distance-md -
|
|
215
|
-
(math.div(button.$btn-font-size-md * 2, 3));
|
|
216
|
-
transform: translateX(button.$btn-border-width * -1);
|
|
217
|
-
}
|
|
218
|
-
|
|
219
|
-
@each $size in button.$btn-non-default-sizes {
|
|
220
|
-
&.btn-#{$size}::after {
|
|
221
|
-
right: map.get(button.$btn-padding-x-map, $size) - map.get(
|
|
222
|
-
button.$btn-animation-distance-map,
|
|
223
|
-
$size
|
|
224
|
-
) -
|
|
225
|
-
(math.div(map.get(button.$btn-font-size-map, $size) * 2, 3));
|
|
226
|
-
}
|
|
227
|
-
}
|
|
228
|
-
|
|
229
|
-
// Only animate when user prefers to see animations
|
|
230
|
-
@media (prefers-reduced-motion: no-preference) {
|
|
231
|
-
@include utilities.not-disabled-focus-hover() {
|
|
232
|
-
> span {
|
|
233
|
-
transform: translateX(map.get(button.$btn-animation-distance-map, md) * -1);
|
|
234
|
-
}
|
|
235
|
-
|
|
236
|
-
@each $size in button.$btn-non-default-sizes {
|
|
237
|
-
&.btn-#{$size} > span {
|
|
238
|
-
transform: translateX(map.get(button.$btn-animation-distance-map, $size) * -1);
|
|
239
|
-
}
|
|
240
|
-
}
|
|
241
|
-
}
|
|
242
|
-
}
|
|
243
|
-
}
|
|
244
|
-
|
|
245
|
-
.btn-animated-start:not(.btn-link, .btn-tertiary) {
|
|
246
|
-
&::after {
|
|
247
|
-
@include icon-mx.icon(2110);
|
|
248
|
-
left: button.$btn-padding-x-md - button.$btn-animation-distance-md -
|
|
249
|
-
(math.div(button.$btn-font-size-md * 2, 3));
|
|
250
|
-
transform: translateX(button.$btn-border-width);
|
|
251
|
-
}
|
|
252
|
-
|
|
253
|
-
@each $size in button.$btn-non-default-sizes {
|
|
254
|
-
&.btn-#{$size}::after {
|
|
255
|
-
left: map.get(button.$btn-padding-x-map, $size) - map.get(
|
|
256
|
-
button.$btn-animation-distance-map,
|
|
257
|
-
$size
|
|
258
|
-
) -
|
|
259
|
-
(math.div(map.get(button.$btn-font-size-map, $size) * 2, 3));
|
|
260
|
-
}
|
|
261
|
-
}
|
|
262
|
-
|
|
263
|
-
// Only animate when user prefers to see animations
|
|
264
|
-
@media (prefers-reduced-motion: no-preference) {
|
|
265
|
-
@include utilities.not-disabled-focus-hover() {
|
|
266
|
-
> span {
|
|
267
|
-
transform: translateX(map.get(button.$btn-animation-distance-map, md));
|
|
268
|
-
}
|
|
269
|
-
|
|
270
|
-
@each $size in button.$btn-non-default-sizes {
|
|
271
|
-
&.btn-#{$size} > span {
|
|
272
|
-
transform: translateX(map.get(button.$btn-animation-distance-map, $size));
|
|
273
|
-
}
|
|
274
|
-
}
|
|
81
|
+
@include utilities.not-disabled-hover() {
|
|
82
|
+
@include button-mx.button-variant-def('hover', $color);
|
|
275
83
|
}
|
|
276
84
|
}
|
|
277
85
|
}
|
|
278
86
|
|
|
279
|
-
// Size variants, default is
|
|
87
|
+
// Size variants, default is md
|
|
280
88
|
@each $size in button.$btn-non-default-sizes {
|
|
281
89
|
.btn-#{$size} {
|
|
282
90
|
@include button-mx.button-size($size);
|
|
283
91
|
}
|
|
284
92
|
}
|
|
285
93
|
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
94
|
+
.btn-link {
|
|
95
|
+
-webkit-text-decoration: tokens.get('link-decoration', elements.$post-link);
|
|
96
|
+
text-decoration: tokens.get('link-decoration', elements.$post-link);
|
|
97
|
+
border: 0 none;
|
|
98
|
+
border-radius: tokens.get('link-border-radius', elements.$post-link);
|
|
99
|
+
min-height: 0;
|
|
100
|
+
font-size: inherit;
|
|
101
|
+
font-weight: inherit;
|
|
102
|
+
padding: 0;
|
|
290
103
|
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
104
|
+
&:hover {
|
|
105
|
+
color: tokens.get('link-hover-fg', elements.$post-link);
|
|
106
|
+
}
|
|
294
107
|
}
|