@swisspost/design-system-styles 10.3.0 → 10.4.0
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/basics.css +1 -1
- package/cargo-compact.css +1 -1
- package/cargo-default.css +1 -1
- package/cargo-tokens-compact.css +1 -1
- package/cargo-tokens-default.css +1 -1
- package/components/button.css +1 -1
- package/components/button.scss +17 -0
- package/components/dialog.css +1 -1
- package/components/dialog.scss +51 -41
- package/components/form-input.css +1 -1
- package/components/form-input.scss +27 -15
- package/components/header/_custom-properties.scss +27 -27
- package/components/header/_mixins.scss +9 -9
- package/components/header/_placeholders.scss +3 -3
- package/components/header/_post-header.scss +6 -12
- package/components/header/_post-megadropdown.scss +2 -2
- package/components/header/index.css +1 -1
- package/components/switch.css +1 -1
- package/components/switch.scss +7 -3
- package/components/tabs/_tab-title.scss +13 -24
- package/components/tabs/index.css +1 -1
- package/components/toast.css +1 -1
- package/components/validation.css +1 -1
- package/components/validation.scss +1 -0
- package/elements/anchor.css +1 -1
- package/elements/anchor.scss +4 -1
- package/icons/temp/constructionsitelightsystem-solid.css +4 -0
- package/icons/temp/constructionsitelightsystem.css +4 -0
- package/icons/temp/hotwork-solid.css +4 -0
- package/icons/temp/hotwork.css +4 -0
- package/icons/temp/mobilenotification-solid.css +4 -0
- package/icons/temp/mobilenotification.css +4 -0
- package/icons/temp/okr-solid.css +4 -0
- package/icons/temp/okr.css +4 -0
- package/icons/temp/postautoelectric-solid.css +4 -0
- package/icons/temp/postautoelectric.css +4 -0
- package/icons/temp/pricescountryinformation-solid.css +4 -0
- package/icons/temp/pricescountryinformation.css +4 -0
- package/icons/temp/specialtransport-solid.css +4 -0
- package/icons/temp/specialtransport.css +4 -0
- package/icons/temp/sustainablepower-solid.css +4 -0
- package/icons/temp/sustainablepower.css +4 -0
- package/icons/temp/transportmanagement-solid.css +4 -0
- package/icons/temp/transportmanagement.css +4 -0
- package/icons/temp/underconstruction-solid.css +4 -0
- package/icons/temp/underconstruction.css +4 -0
- package/mixins/_button.scss +4 -11
- package/mixins/_utilities.scss +25 -3
- package/package.json +3 -3
- package/post-compact.css +1 -1
- package/post-default.css +1 -1
- package/post-tokens-compact.css +1 -1
- package/post-tokens-default.css +1 -1
- package/tokens/temp/_appearance.scss +1 -1
- package/tokens/temp/_components.scss +104 -26
- package/tokens/temp/_core.scss +9 -1
- package/tokens/temp/_device.scss +55 -1
- package/tokens/temp/_elements.scss +1 -1
- package/tokens/temp/_helpers.scss +3 -1
- package/tokens/temp/_index.scss +1 -1
- package/tokens/temp/_palette.scss +5 -1
- package/tokens/temp/_scheme.scss +1 -1
- package/tokens/temp/_schemestatic.scss +1 -1
- package/tokens/temp/_theme.scss +16 -8
- package/tokens/temp/_utilities-formatted.scss +1 -1
- package/tokens/temp/_utilities.scss +1 -1
- package/utilities/_env-variables.scss +1 -1
package/mixins/_button.scss
CHANGED
|
@@ -63,19 +63,12 @@
|
|
|
63
63
|
@include utilities.focus-style;
|
|
64
64
|
|
|
65
65
|
@include utilities.high-contrast-mode() {
|
|
66
|
+
border-width: 1px !important;
|
|
67
|
+
transition: none;
|
|
68
|
+
|
|
66
69
|
&:is(button) {
|
|
67
70
|
background-color: ButtonFace !important;
|
|
68
|
-
border:
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
&:not(:disabled, .disabled) {
|
|
72
|
-
&:is(button):hover {
|
|
73
|
-
background-color: Highlight !important;
|
|
74
|
-
|
|
75
|
-
> post-icon {
|
|
76
|
-
color: HighlightText !important;
|
|
77
|
-
}
|
|
78
|
-
}
|
|
71
|
+
border-color: ButtonBorder !important;
|
|
79
72
|
}
|
|
80
73
|
}
|
|
81
74
|
}
|
package/mixins/_utilities.scss
CHANGED
|
@@ -76,9 +76,12 @@
|
|
|
76
76
|
outline: none !important;
|
|
77
77
|
}
|
|
78
78
|
|
|
79
|
-
@mixin focus-style(
|
|
79
|
+
@mixin focus-style(
|
|
80
|
+
$additional-selector: '',
|
|
81
|
+
$outline-offset: tokens.get('focus-outline-offset', helpers.$post-focus)
|
|
82
|
+
) {
|
|
80
83
|
&#{$additional-selector} {
|
|
81
|
-
outline-offset:
|
|
84
|
+
outline-offset: $outline-offset !important;
|
|
82
85
|
outline: tokens.get('focus-outline-color', helpers.$post-focus) none
|
|
83
86
|
tokens.get('focus-outline-width', helpers.$post-focus) !important;
|
|
84
87
|
}
|
|
@@ -115,16 +118,35 @@
|
|
|
115
118
|
}
|
|
116
119
|
}
|
|
117
120
|
|
|
118
|
-
@mixin focus-style-custom(
|
|
121
|
+
@mixin focus-style-custom(
|
|
122
|
+
$additional-selector: '',
|
|
123
|
+
$outline-offset: tokens.get('focus-outline-offset', helpers.$post-focus),
|
|
124
|
+
$outline-color: tokens.get('focus-outline-color', helpers.$post-focus)
|
|
125
|
+
) {
|
|
126
|
+
&#{$additional-selector} {
|
|
127
|
+
outline-offset: $outline-offset !important;
|
|
128
|
+
outline: $outline-color none tokens.get('focus-outline-width', helpers.$post-focus) !important;
|
|
129
|
+
}
|
|
130
|
+
|
|
119
131
|
// :has(:focus-visible) mimic a focus-visible-within pseudo-class
|
|
120
132
|
&:is(:focus-visible, :has(:focus-visible), .pretend-focus)#{$additional-selector} {
|
|
133
|
+
outline-style: tokens.get('focus-border-style', helpers.$post-focus) !important;
|
|
121
134
|
@content;
|
|
135
|
+
|
|
136
|
+
@include high-contrast-mode() {
|
|
137
|
+
outline-color: Highlight !important;
|
|
138
|
+
}
|
|
122
139
|
}
|
|
123
140
|
|
|
124
141
|
// When a browser doesn't support :has, use focus-within as a fallback. This means that focus state is displayed on focus and not on focus-visible only (except some browsers like Safari).
|
|
125
142
|
@supports not selector(:has(:focus-visible)) {
|
|
126
143
|
&:is(:focus-visible, :focus-within, .pretend-focus)#{$additional-selector} {
|
|
144
|
+
outline-style: tokens.get('focus-border-style', helpers.$post-focus) !important;
|
|
127
145
|
@content;
|
|
146
|
+
|
|
147
|
+
@include high-contrast-mode() {
|
|
148
|
+
outline-color: Highlight !important;
|
|
149
|
+
}
|
|
128
150
|
}
|
|
129
151
|
}
|
|
130
152
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@swisspost/design-system-styles",
|
|
3
|
-
"version": "10.
|
|
3
|
+
"version": "10.4.0",
|
|
4
4
|
"description": "Design System Styles for the Swiss Post web platform.",
|
|
5
5
|
"author": "Swiss Post <design-system@post.ch>",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -19,11 +19,11 @@
|
|
|
19
19
|
},
|
|
20
20
|
"dependencies": {
|
|
21
21
|
"@popperjs/core": "2.11.8",
|
|
22
|
-
"@swisspost/design-system-icons": "10.
|
|
22
|
+
"@swisspost/design-system-icons": "10.4.0",
|
|
23
23
|
"gulp-sourcemaps": "3.0.0"
|
|
24
24
|
},
|
|
25
25
|
"devDependencies": {
|
|
26
|
-
"@swisspost/design-system-tokens": "10.
|
|
26
|
+
"@swisspost/design-system-tokens": "10.4.0",
|
|
27
27
|
"@types/node": "24.0.0",
|
|
28
28
|
"autoprefixer": "10.5.0",
|
|
29
29
|
"copyfiles": "2.4.1",
|