@ongov/ontario-design-system-complete-styles 9.1.0 → 9.2.0-alpha.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/dist/styles/components/ontario-accordion/ontario-accordion.scss +24 -3
- package/dist/styles/components/ontario-card/ontario-card.scss +6 -11
- package/dist/styles/components/ontario-checkbox/ontario-checkboxes.scss +4 -0
- package/dist/styles/components/ontario-header/ontario-application-header.scss +4 -3
- package/dist/styles/components/ontario-header/ontario-header.scss +3 -2
- package/dist/styles/components/ontario-header/service-ontario-header.scss +3 -2
- package/dist/styles/components/ontario-header-menu-tabs/ontario-header-menu-tabs.scss +3 -4
- package/dist/styles/components/ontario-header-overflow-menu/ontario-header-overflow-menu.scss +3 -4
- package/dist/styles/components/ontario-radio-buttons/ontario-radio-buttons.scss +2 -1
- package/dist/styles/css/compiled/ontario-theme.css.map +1 -1
- package/dist/styles/scss/1-variables/_box-shadow.variables.scss +4 -0
- package/dist/styles/scss/2-tools/placeholder/_focus.placeholders.scss +2 -3
- package/dist/styles/scss/4-elements/_global.elements.scss +4 -3
- package/dist/styles/scss/theme.scss +1 -0
- package/package.json +7 -7
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/global.variables' as globalVariables;
|
|
2
|
+
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/box-shadow.variables' as boxShadow;
|
|
2
3
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/spacing.variables' as spacing;
|
|
3
4
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/colours.variables' as colours;
|
|
4
5
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/breakpoints.variables' as breakpoints;
|
|
@@ -96,7 +97,7 @@
|
|
|
96
97
|
|
|
97
98
|
&:focus {
|
|
98
99
|
@extend %ontario-focus;
|
|
99
|
-
box-shadow:
|
|
100
|
+
box-shadow: boxShadow.$ontario-focus-box-shadow inset;
|
|
100
101
|
}
|
|
101
102
|
|
|
102
103
|
&:active {
|
|
@@ -105,10 +106,31 @@
|
|
|
105
106
|
}
|
|
106
107
|
|
|
107
108
|
.ontario-accordion__content {
|
|
108
|
-
display: none;
|
|
109
109
|
padding: spacing.$spacing-3 spacing.$spacing-3 spacing.$spacing-6 spacing.$spacing-3;
|
|
110
110
|
margin-left: spacing.$spacing-0;
|
|
111
111
|
|
|
112
|
+
// Collapsed content is hidden via the native `hidden="until-found"` attribute rather than
|
|
113
|
+
// `display: none`, so it stays in the DOM and is discoverable by the browser's built-in
|
|
114
|
+
// find-in-page (Ctrl+F/Cmd+F) search. `content-visibility: hidden` keeps it out of the
|
|
115
|
+
// render/paint path without removing it from the accessibility tree or search index.
|
|
116
|
+
// (This mirrors the browser's default UA styling for `[hidden="until-found"]`, made
|
|
117
|
+
// explicit here so it isn't accidentally overridden by other component styles.)
|
|
118
|
+
//
|
|
119
|
+
// Note: `content-visibility: hidden` only skips rendering of the element's *contents* -
|
|
120
|
+
// it does NOT collapse the element's own box model. Padding must be reset to 0 here,
|
|
121
|
+
// otherwise the section would still reserve visual space (a gap) while collapsed.
|
|
122
|
+
&[hidden='until-found'] {
|
|
123
|
+
content-visibility: hidden;
|
|
124
|
+
padding: spacing.$spacing-0;
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
// Fallback for browsers that don't support `hidden="until-found"`: falls back to a
|
|
128
|
+
// standard `hidden` attribute, which fully hides the content (matching the previous
|
|
129
|
+
// CSS-only hiding behaviour).
|
|
130
|
+
&[hidden]:not([hidden='until-found']) {
|
|
131
|
+
display: none;
|
|
132
|
+
}
|
|
133
|
+
|
|
112
134
|
@media screen and (min-width: breakpoints.$small-breakpoint) {
|
|
113
135
|
margin-left: spacing.$spacing-6;
|
|
114
136
|
}
|
|
@@ -134,7 +156,6 @@
|
|
|
134
156
|
display: none;
|
|
135
157
|
}
|
|
136
158
|
|
|
137
|
-
.ontario-expander--active ~ .ontario-accordion__content,
|
|
138
159
|
.ontario-expander--active .ontario-accordion__button-icon--close {
|
|
139
160
|
display: block;
|
|
140
161
|
}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
@use 'sass:math';
|
|
2
2
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/global.variables' as globalVariables;
|
|
3
|
+
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/box-shadow.variables' as boxShadow;
|
|
3
4
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/spacing.variables' as spacing;
|
|
4
5
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/colours.variables' as colours;
|
|
5
6
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/breakpoints.variables' as breakpoints;
|
|
6
|
-
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/2-tools/placeholder/focus.placeholders' as placeholders;
|
|
7
7
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/font-weights.variables' as fontWeights;
|
|
8
8
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/font-sizes.variables' as fontSizes;
|
|
9
9
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/2-tools/functions/global.functions' as globalFunctions;
|
|
@@ -31,13 +31,13 @@
|
|
|
31
31
|
}
|
|
32
32
|
|
|
33
33
|
&:focus-within {
|
|
34
|
-
box-shadow:
|
|
34
|
+
box-shadow: boxShadow.$ontario-focus-box-shadow;
|
|
35
35
|
outline: 4px solid transparent;
|
|
36
36
|
transition: box-shadow 0.1s ease-in-out;
|
|
37
37
|
}
|
|
38
38
|
|
|
39
39
|
&:active {
|
|
40
|
-
box-shadow:
|
|
40
|
+
box-shadow: boxShadow.$ontario-focus-box-shadow;
|
|
41
41
|
background-color: colours.$ontario-greyscale-5;
|
|
42
42
|
}
|
|
43
43
|
|
|
@@ -48,13 +48,6 @@
|
|
|
48
48
|
}
|
|
49
49
|
}
|
|
50
50
|
|
|
51
|
-
.ontario-card--image-true {
|
|
52
|
-
margin-top: spacing.$spacing-2 * -1;
|
|
53
|
-
@at-root .ontario-card__card-type--horizontal & {
|
|
54
|
-
margin-top: spacing.$spacing-0;
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
|
|
58
51
|
.ontario-card__card-type--horizontal {
|
|
59
52
|
display: flex;
|
|
60
53
|
|
|
@@ -247,7 +240,7 @@ $ontario-card-heading-colours: (
|
|
|
247
240
|
}
|
|
248
241
|
}
|
|
249
242
|
.ontario-card--position-vertical & {
|
|
250
|
-
|
|
243
|
+
flex-shrink: 0;
|
|
251
244
|
}
|
|
252
245
|
|
|
253
246
|
.ontario-card__card-type--horizontal & {
|
|
@@ -266,6 +259,8 @@ $ontario-card-heading-colours: (
|
|
|
266
259
|
background-size: 100% 100%;
|
|
267
260
|
|
|
268
261
|
.ontario-card--position-vertical & {
|
|
262
|
+
display: block;
|
|
263
|
+
height: auto;
|
|
269
264
|
border-top-left-radius: globalVariables.$global-radius;
|
|
270
265
|
border-top-right-radius: globalVariables.$global-radius;
|
|
271
266
|
}
|
|
@@ -18,6 +18,10 @@ $ontario-checkboxes-size-mobile: globalFunctions.px-to-rem(32);
|
|
|
18
18
|
$ontario-checkbox-border-size: globalFunctions.px-to-rem(2);
|
|
19
19
|
$ontario-checkbox-box-shadow-outline: globalFunctions.px-to-rem(4);
|
|
20
20
|
|
|
21
|
+
// DS-2191: Assign --checkbox-bg for both native DOM and shadow DOM display of checkbox elements.
|
|
22
|
+
// :root supports native DOM display exclusively while :host is ignored.
|
|
23
|
+
// :host supports shadow DOM display exclusively while :root is ignored.
|
|
24
|
+
:root,
|
|
21
25
|
:host {
|
|
22
26
|
--checkbox-bg: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M0 2.667C0 1.194 1.194 0 2.667 0h18.667C22.806 0 24 1.194 24 2.667v18.667C24 22.806 22.806 24 21.333 24H2.667C1.194 24 0 22.806 0 21.333V2.667z' fill='%231a1a1a'/%3E%3Cpath d='M2.667 12.616l6.667 6.718 12-12.092-1.88-1.908L9.333 15.53l-4.787-4.8-1.88 1.894z' fill='%23fff'/%3E%3C/svg%3E");
|
|
23
27
|
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
@use 'sass:math';
|
|
2
2
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/global.variables' as globalVariables;
|
|
3
|
+
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/box-shadow.variables' as boxShadow;
|
|
3
4
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/spacing.variables' as spacing;
|
|
4
5
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/colours.variables' as colours;
|
|
5
6
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/breakpoints.variables' as breakpoints;
|
|
@@ -71,7 +72,7 @@ $border-width-2: 2px;
|
|
|
71
72
|
}
|
|
72
73
|
|
|
73
74
|
&:focus {
|
|
74
|
-
box-shadow:
|
|
75
|
+
box-shadow: boxShadow.$ontario-focus-box-shadow;
|
|
75
76
|
outline: 4px solid transparent;
|
|
76
77
|
transition: all 0.1s ease-in-out;
|
|
77
78
|
}
|
|
@@ -156,7 +157,7 @@ $border-width-2: 2px;
|
|
|
156
157
|
}
|
|
157
158
|
|
|
158
159
|
&:focus {
|
|
159
|
-
box-shadow:
|
|
160
|
+
box-shadow: boxShadow.$ontario-focus-box-shadow;
|
|
160
161
|
transition: all 0.1s ease-in-out;
|
|
161
162
|
}
|
|
162
163
|
}
|
|
@@ -223,7 +224,7 @@ $border-width-2: 2px;
|
|
|
223
224
|
|
|
224
225
|
a {
|
|
225
226
|
&:focus {
|
|
226
|
-
box-shadow:
|
|
227
|
+
box-shadow: boxShadow.$ontario-focus-box-shadow;
|
|
227
228
|
transition: all 0.1s ease-in-out;
|
|
228
229
|
}
|
|
229
230
|
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
@use 'sass:math';
|
|
2
2
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/global.variables' as globalVariables;
|
|
3
|
+
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/box-shadow.variables' as boxShadow;
|
|
3
4
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/spacing.variables' as spacing;
|
|
4
5
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/colours.variables' as colours;
|
|
5
6
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/breakpoints.variables' as breakpoints;
|
|
@@ -98,7 +99,7 @@ $ontario-header-z-index: zIndex.$ontario-z-index-above-high;
|
|
|
98
99
|
&:focus,
|
|
99
100
|
&:active {
|
|
100
101
|
@extend %ontario-focus;
|
|
101
|
-
box-shadow:
|
|
102
|
+
box-shadow: boxShadow.$ontario-focus-box-shadow inset;
|
|
102
103
|
}
|
|
103
104
|
|
|
104
105
|
&.ontario-link--active {
|
|
@@ -516,7 +517,7 @@ $ontario-header-z-index: zIndex.$ontario-z-index-above-high;
|
|
|
516
517
|
}
|
|
517
518
|
|
|
518
519
|
&:invalid:focus {
|
|
519
|
-
box-shadow:
|
|
520
|
+
box-shadow: boxShadow.$ontario-focus-box-shadow;
|
|
520
521
|
-moz-box-shadow: none;
|
|
521
522
|
}
|
|
522
523
|
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
@use 'sass:math';
|
|
2
2
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/global.variables' as globalVariables;
|
|
3
|
+
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/box-shadow.variables' as boxShadow;
|
|
3
4
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/spacing.variables' as spacing;
|
|
4
5
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/colours.variables' as colours;
|
|
5
6
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/breakpoints.variables' as breakpoints;
|
|
@@ -81,7 +82,7 @@
|
|
|
81
82
|
}
|
|
82
83
|
|
|
83
84
|
&:focus {
|
|
84
|
-
box-shadow:
|
|
85
|
+
box-shadow: boxShadow.$ontario-box-shadow colours.$ontario-colour-service-ontario-header-focus;
|
|
85
86
|
}
|
|
86
87
|
}
|
|
87
88
|
|
|
@@ -177,7 +178,7 @@
|
|
|
177
178
|
}
|
|
178
179
|
|
|
179
180
|
&:focus {
|
|
180
|
-
box-shadow:
|
|
181
|
+
box-shadow: boxShadow.$ontario-box-shadow colours.$ontario-colour-service-ontario-header-focus;
|
|
181
182
|
}
|
|
182
183
|
}
|
|
183
184
|
|
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
@use 'sass:math';
|
|
2
2
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/global.variables' as globalVariables;
|
|
3
|
+
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/box-shadow.variables' as boxShadow;
|
|
3
4
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/spacing.variables' as spacing;
|
|
4
5
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/colours.variables' as colours;
|
|
5
6
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/breakpoints.variables' as breakpoints;
|
|
6
7
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/fonts.variables' as fonts;
|
|
7
8
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/2-tools/functions/global.functions' as globalFunctions;
|
|
8
9
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/font-weights.variables' as fontWeights;
|
|
9
|
-
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/2-tools/placeholder/focus.placeholders' as
|
|
10
|
-
focusPlaceholders;
|
|
11
10
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/z-index.variables' as zIndex;
|
|
12
11
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/font-sizes.variables' as fontSize;
|
|
13
12
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/typography.variables';
|
|
@@ -70,7 +69,7 @@ $ontario-header-overflow-menu-link-font-size: globalFunctions.px-to-rem(18);
|
|
|
70
69
|
&:focus,
|
|
71
70
|
&:active {
|
|
72
71
|
@extend %ontario-focus;
|
|
73
|
-
box-shadow:
|
|
72
|
+
box-shadow: boxShadow.$ontario-focus-box-shadow inset;
|
|
74
73
|
}
|
|
75
74
|
|
|
76
75
|
&.ontario-link--active {
|
|
@@ -126,7 +125,7 @@ $ontario-header-overflow-menu-link-font-size: globalFunctions.px-to-rem(18);
|
|
|
126
125
|
|
|
127
126
|
&:active,
|
|
128
127
|
&:focus {
|
|
129
|
-
box-shadow:
|
|
128
|
+
box-shadow: boxShadow.$ontario-focus-box-shadow inset;
|
|
130
129
|
}
|
|
131
130
|
|
|
132
131
|
&[aria-selected='true'] {
|
package/dist/styles/components/ontario-header-overflow-menu/ontario-header-overflow-menu.scss
CHANGED
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
@use 'sass:math';
|
|
2
2
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/global.variables' as globalVariables;
|
|
3
|
+
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/box-shadow.variables' as boxShadow;
|
|
3
4
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/spacing.variables' as spacing;
|
|
4
5
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/colours.variables' as colours;
|
|
5
6
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/breakpoints.variables' as breakpoints;
|
|
6
7
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/fonts.variables' as fonts;
|
|
7
8
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/2-tools/functions/global.functions' as globalFunctions;
|
|
8
9
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/font-weights.variables' as fontWeights;
|
|
9
|
-
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/2-tools/placeholder/focus.placeholders' as
|
|
10
|
-
focusPlaceholders;
|
|
11
10
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/z-index.variables' as zIndex;
|
|
12
11
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/font-sizes.variables' as fontSize;
|
|
13
12
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/typography.variables';
|
|
@@ -69,7 +68,7 @@ $mobile-menu-tab-line-height: 2.1875rem;
|
|
|
69
68
|
&:focus,
|
|
70
69
|
&:active {
|
|
71
70
|
@extend %ontario-focus;
|
|
72
|
-
box-shadow:
|
|
71
|
+
box-shadow: boxShadow.$ontario-focus-box-shadow inset;
|
|
73
72
|
}
|
|
74
73
|
|
|
75
74
|
&.ontario-link--active {
|
|
@@ -212,7 +211,7 @@ $mobile-menu-tab-line-height: 2.1875rem;
|
|
|
212
211
|
|
|
213
212
|
&:active,
|
|
214
213
|
&:focus {
|
|
215
|
-
box-shadow:
|
|
214
|
+
box-shadow: boxShadow.$ontario-focus-box-shadow inset;
|
|
216
215
|
}
|
|
217
216
|
|
|
218
217
|
&[aria-selected='true'] {
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
@use 'sass:math';
|
|
2
2
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/global.variables' as globalVariables;
|
|
3
|
+
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/box-shadow.variables' as boxShadow;
|
|
3
4
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/spacing.variables' as spacing;
|
|
4
5
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/colours.variables' as colours;
|
|
5
6
|
@use 'pkg:@ongov/ontario-design-system-global-styles/styles/scss/1-variables/breakpoints.variables' as breakpoints;
|
|
@@ -124,7 +125,7 @@ $ontario-input-offset: math.div((globalVariables.$touch-target-size - $ontario-r
|
|
|
124
125
|
}
|
|
125
126
|
|
|
126
127
|
.ontario-radios__input:focus + .ontario-radios__label:before {
|
|
127
|
-
-moz-box-shadow:
|
|
128
|
+
-moz-box-shadow: boxShadow.$ontario-focus-box-shadow;
|
|
128
129
|
-webkit-box-shadow: colours.$ontario-colour-focus;
|
|
129
130
|
@extend %ontario-focus;
|
|
130
131
|
}
|