vanilla-framework 4.10.0 → 4.12.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/README.md +0 -1
- package/package.json +10 -10
- package/scss/_base_forms.scss +1 -0
- package/scss/_base_typography.scss +1 -0
- package/scss/_patterns_equal-height-row.scss +29 -136
- package/scss/_patterns_icons.scss +8 -0
- package/scss/_patterns_lists.scss +6 -4
- package/scss/_patterns_modal.scss +6 -8
- package/scss/_patterns_navigation.scss +39 -35
- package/scss/_patterns_pagination.scss +2 -2
- package/scss/_patterns_rule.scss +2 -10
- package/scss/_patterns_segmented-control.scss +1 -1
- package/scss/_patterns_side-navigation.scss +0 -6
- package/scss/_patterns_suru.scss +35 -4
- package/scss/_settings_colors.scss +2 -2
- package/scss/_settings_spacing.scss +4 -4
- package/scss/_utilities_baseline-grid.scss +0 -15
- package/scss/_utilities_layout.scss +10 -4
- package/scss/_vanilla.scss +0 -2
- package/scss/_utilities_theme-toggle.scss +0 -39
package/README.md
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
#  Vanilla Framework
|
|
2
2
|
|
|
3
|
-
[](https://circleci.com/gh/canonical/vanilla-framework)
|
|
4
3
|
[](http://badge.fury.io/js/vanilla-framework)
|
|
5
4
|
[](https://www.npmjs.com/package/vanilla-framework)
|
|
6
5
|
[](https://david-dm.org/canonical/vanilla-framework#info=devDependencies)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "vanilla-framework",
|
|
3
|
-
"version": "4.
|
|
3
|
+
"version": "4.12.0",
|
|
4
4
|
"author": {
|
|
5
5
|
"email": "webteam@canonical.com",
|
|
6
6
|
"name": "Canonical Webteam"
|
|
@@ -55,24 +55,24 @@
|
|
|
55
55
|
"!/scss/standalone"
|
|
56
56
|
],
|
|
57
57
|
"devDependencies": {
|
|
58
|
-
"@canonical/cookie-policy": "3.6.
|
|
58
|
+
"@canonical/cookie-policy": "3.6.3",
|
|
59
59
|
"@canonical/latest-news": "1.5.0",
|
|
60
|
-
"@percy/cli": "1.28.
|
|
61
|
-
"@testing-library/cypress": "10.0.
|
|
60
|
+
"@percy/cli": "1.28.7",
|
|
61
|
+
"@testing-library/cypress": "10.0.2",
|
|
62
62
|
"autoprefixer": "10.4.19",
|
|
63
|
-
"cypress": "13.
|
|
63
|
+
"cypress": "13.10.0",
|
|
64
64
|
"markdown-spellcheck": "1.3.1",
|
|
65
65
|
"parker": "0.0.10",
|
|
66
66
|
"postcss": "8.4.38",
|
|
67
67
|
"postcss-cli": "11.0.0",
|
|
68
68
|
"postcss-scss": "4.0.9",
|
|
69
|
-
"prettier": "3.
|
|
70
|
-
"sass": "1.
|
|
71
|
-
"stylelint": "16.
|
|
69
|
+
"prettier": "3.3.0",
|
|
70
|
+
"sass": "1.77.4",
|
|
71
|
+
"stylelint": "16.6.1",
|
|
72
72
|
"stylelint-config-recommended-scss": "14.0.0",
|
|
73
73
|
"stylelint-order": "6.0.4",
|
|
74
74
|
"stylelint-prettier": "5.0.0",
|
|
75
|
-
"svgo": "3.2
|
|
76
|
-
"yaml": "2.4.
|
|
75
|
+
"svgo": "3.3.2",
|
|
76
|
+
"yaml": "2.4.3"
|
|
77
77
|
}
|
|
78
78
|
}
|
package/scss/_base_forms.scss
CHANGED
|
@@ -1,108 +1,21 @@
|
|
|
1
1
|
@import 'settings';
|
|
2
2
|
|
|
3
|
-
// wrapper mixin that provides relevant class selectors for 1st, 2nd and 3rd dividers
|
|
4
|
-
@mixin position-divider-by-order-in-grid($divider-order, $large-screen: false) {
|
|
5
|
-
// for large screens, dividers are positioned as pseudo elements at row level
|
|
6
|
-
@if $large-screen {
|
|
7
|
-
@if $divider-order == 1 {
|
|
8
|
-
&.has-1st-divider::before {
|
|
9
|
-
@content;
|
|
10
|
-
}
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
@if $divider-order == 2 {
|
|
14
|
-
&.has-2nd-divider::after {
|
|
15
|
-
@content;
|
|
16
|
-
}
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
@if $divider-order == 3 {
|
|
20
|
-
// when 3rd-divider is present and 1st-divider is not present
|
|
21
|
-
&.has-3rd-divider:not(.has-1st-divider)::before,
|
|
22
|
-
// when 3rd-divider is present and 2nd-divider is not present
|
|
23
|
-
&.has-3rd-divider:not(.has-2nd-divider)::after {
|
|
24
|
-
@content;
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
// when only 3rd-divider is present
|
|
28
|
-
&.has-3rd-divider:not(.has-1st-divider):not(.has-2nd-divider)::before {
|
|
29
|
-
@content;
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
&.has-3rd-divider:not(.has-1st-divider):not(.has-2nd-divider)::after {
|
|
33
|
-
display: none;
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
} @else {
|
|
37
|
-
// for smaller screens, dividers are positioned as pseudo elements at column level
|
|
38
|
-
@if $divider-order == 1 {
|
|
39
|
-
&.has-1st-divider .p-equal-height-row__col::before {
|
|
40
|
-
@content;
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
@if $divider-order == 2 {
|
|
45
|
-
&.has-2nd-divider .p-equal-height-row__col::after {
|
|
46
|
-
@content;
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
@if $divider-order == 3 {
|
|
51
|
-
&.has-3rd-divider:not(.has-1st-divider) .p-equal-height-row__col::before,
|
|
52
|
-
&.has-3rd-divider:not(.has-2nd-divider) .p-equal-height-row__col::after {
|
|
53
|
-
@content;
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
&.has-3rd-divider:not(.has-1st-divider):not(.has-2nd-divider) .p-equal-height-row__col::before {
|
|
57
|
-
@content;
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
&.has-3rd-divider:not(.has-1st-divider):not(.has-2nd-divider) .p-equal-height-row__col::after {
|
|
61
|
-
display: none;
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
}
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
@mixin divider-styles($large-screen: false) {
|
|
68
|
-
// For each row or column grid we only have access to two pseudo elements
|
|
69
|
-
// if 1st-divider (::before) is present, assume 2nd-divider (::after) isn't, then 3rd-divider must be (::after)
|
|
70
|
-
// if 2nd-divider (::after) is present, assume 1st-divider (::before) isn't, then 3rd-divider must be (::before)
|
|
71
|
-
@if $large-screen {
|
|
72
|
-
&.has-1st-divider::before,
|
|
73
|
-
&.has-2nd-divider::after,
|
|
74
|
-
&.has-3rd-divider:not(.has-1st-divider)::before,
|
|
75
|
-
&.has-3rd-divider:not(.has-2nd-divider)::after {
|
|
76
|
-
@content;
|
|
77
|
-
}
|
|
78
|
-
} @else {
|
|
79
|
-
// For smaller screens, the divider pseudo elements are inserted at the column level
|
|
80
|
-
&.has-1st-divider .p-equal-height-row__col::before,
|
|
81
|
-
&.has-2nd-divider .p-equal-height-row__col::after,
|
|
82
|
-
&.has-3rd-divider:not(.has-1st-divider) .p-equal-height-row__col::before,
|
|
83
|
-
&.has-3rd-divider:not(.has-2nd-divider) .p-equal-height-row__col::after {
|
|
84
|
-
@content;
|
|
85
|
-
}
|
|
86
|
-
}
|
|
87
|
-
}
|
|
88
|
-
|
|
89
3
|
@mixin vf-p-equal-height-row {
|
|
90
4
|
.p-equal-height-row {
|
|
91
5
|
@extend %vf-row;
|
|
92
|
-
padding-bottom: $spv--strip-regular * 0.5;
|
|
93
6
|
position: relative;
|
|
94
7
|
|
|
95
8
|
.p-equal-height-row__col {
|
|
96
9
|
// smaller screens each column will have border top by default
|
|
97
|
-
border-top-color: $colors--theme--border-
|
|
10
|
+
border-top-color: $colors--theme--border-low-contrast;
|
|
98
11
|
border-top-style: solid;
|
|
99
12
|
border-top-width: 1px;
|
|
100
13
|
display: grid;
|
|
101
14
|
grid-column: span $grid-columns-small;
|
|
102
15
|
grid-row: span 4;
|
|
103
16
|
grid-template-rows: subgrid;
|
|
17
|
+
margin-bottom: $spv--small;
|
|
104
18
|
margin-top: -1px;
|
|
105
|
-
padding-bottom: $spv--small;
|
|
106
19
|
position: relative;
|
|
107
20
|
|
|
108
21
|
@media screen and ($breakpoint-small <= width < $breakpoint-large) {
|
|
@@ -123,76 +36,56 @@
|
|
|
123
36
|
@media screen and (width >= $breakpoint-large) {
|
|
124
37
|
border: none;
|
|
125
38
|
grid-column: span calc($grid-columns / 4);
|
|
126
|
-
|
|
39
|
+
margin-bottom: 0;
|
|
127
40
|
}
|
|
128
41
|
}
|
|
129
42
|
|
|
130
|
-
//
|
|
131
|
-
@include divider-styles($large-screen: false) {
|
|
132
|
-
@extend %vf-pseudo-border;
|
|
133
|
-
}
|
|
43
|
+
// DIVIDERS
|
|
134
44
|
|
|
135
|
-
//
|
|
136
|
-
|
|
45
|
+
// For each row or column grid we only have access to two pseudo elements
|
|
46
|
+
// if 1st-divider (::before) is present, assume 2nd-divider (::after) isn't, then 3rd-divider must be (::after)
|
|
47
|
+
// if 2nd-divider (::after) is present, assume 1st-divider (::before) isn't, then 3rd-divider must be (::before)
|
|
48
|
+
&.has-divider-1::before,
|
|
49
|
+
&.has-divider-2::after,
|
|
50
|
+
&.has-divider-3:not(.has-divider-1)::before,
|
|
51
|
+
&.has-divider-3:not(.has-divider-2)::after {
|
|
52
|
+
// row level dividers are not visible on smaller screen sizes
|
|
137
53
|
@extend %vf-pseudo-border;
|
|
54
|
+
background-color: $colors--theme--border-low-contrast; // override border color to be low contrast
|
|
138
55
|
display: none;
|
|
139
56
|
}
|
|
140
57
|
|
|
141
|
-
@include position-divider-by-order-in-grid(1) {
|
|
142
|
-
grid-row: 2;
|
|
143
|
-
}
|
|
144
|
-
|
|
145
|
-
@include position-divider-by-order-in-grid(2) {
|
|
146
|
-
grid-row: 3;
|
|
147
|
-
}
|
|
148
|
-
|
|
149
|
-
@include position-divider-by-order-in-grid(3) {
|
|
150
|
-
grid-row: 4;
|
|
151
|
-
}
|
|
152
|
-
|
|
153
|
-
@media screen and ($breakpoint-small <= width < $breakpoint-large) {
|
|
154
|
-
// We don't need to insert divider below item-1 for medium screen size since item-1 gets positioned on the left
|
|
155
|
-
@include position-divider-by-order-in-grid(1) {
|
|
156
|
-
display: none;
|
|
157
|
-
}
|
|
158
|
-
|
|
159
|
-
@include position-divider-by-order-in-grid(2) {
|
|
160
|
-
grid-column: 4 / 7;
|
|
161
|
-
grid-row: 2;
|
|
162
|
-
}
|
|
163
|
-
|
|
164
|
-
@include position-divider-by-order-in-grid(3) {
|
|
165
|
-
grid-column: 4 / 7;
|
|
166
|
-
grid-row: 3;
|
|
167
|
-
}
|
|
168
|
-
}
|
|
169
|
-
|
|
170
58
|
@media screen and (width >= $breakpoint-large) {
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
display: none;
|
|
176
|
-
}
|
|
177
|
-
|
|
178
|
-
@include divider-styles($large-screen: true) {
|
|
59
|
+
&.has-divider-1::before,
|
|
60
|
+
&.has-divider-2::after,
|
|
61
|
+
&.has-divider-3:not(.has-divider-1)::before,
|
|
62
|
+
&.has-divider-3:not(.has-divider-2)::after {
|
|
179
63
|
display: block;
|
|
180
64
|
grid-column-end: span 12;
|
|
181
65
|
grid-column-start: 1;
|
|
182
66
|
margin: auto;
|
|
183
67
|
}
|
|
184
68
|
|
|
185
|
-
|
|
69
|
+
&.has-divider-1::before {
|
|
186
70
|
grid-row: 2;
|
|
187
71
|
}
|
|
188
72
|
|
|
189
|
-
|
|
73
|
+
&.has-divider-2::after {
|
|
190
74
|
grid-row: 3;
|
|
191
75
|
}
|
|
192
76
|
|
|
193
|
-
|
|
77
|
+
// when 3rd-divider is present and 1st-divider is not present
|
|
78
|
+
&.has-divider-3:not(.has-divider-1)::before,
|
|
79
|
+
// when 3rd-divider is present and 2nd-divider is not present
|
|
80
|
+
&.has-divider-3:not(.has-divider-2)::after,
|
|
81
|
+
// when only 3rd-divider is present
|
|
82
|
+
&.has-divider-3:not(.has-divider-1):not(.has-divider-2)::before {
|
|
194
83
|
grid-row: 4;
|
|
195
84
|
}
|
|
85
|
+
|
|
86
|
+
&.has-divider-3:not(.has-divider-1):not(.has-divider-2)::after {
|
|
87
|
+
display: none;
|
|
88
|
+
}
|
|
196
89
|
}
|
|
197
90
|
}
|
|
198
91
|
|
|
@@ -132,7 +132,15 @@
|
|
|
132
132
|
.p-icon--chevron-up {
|
|
133
133
|
transform: rotate(180deg);
|
|
134
134
|
}
|
|
135
|
+
.p-icon--chevron-left {
|
|
136
|
+
transform: rotate(90deg);
|
|
137
|
+
}
|
|
138
|
+
.p-icon--chevron-right {
|
|
139
|
+
transform: rotate(-90deg);
|
|
140
|
+
}
|
|
135
141
|
|
|
142
|
+
.p-icon--chevron-left,
|
|
143
|
+
.p-icon--chevron-right,
|
|
136
144
|
.p-icon--chevron-down,
|
|
137
145
|
.p-icon--chevron-up {
|
|
138
146
|
@extend %icon;
|
|
@@ -121,7 +121,7 @@ $list-step-bullet-margin: $sph--x-large;
|
|
|
121
121
|
}
|
|
122
122
|
|
|
123
123
|
@mixin vf-list-item-divided {
|
|
124
|
-
box-shadow: inset 0px 1px 0px 0px $
|
|
124
|
+
box-shadow: inset 0px 1px 0px 0px $colors--theme--border-low-contrast;
|
|
125
125
|
margin: 0;
|
|
126
126
|
padding-bottom: $sph--large;
|
|
127
127
|
padding-top: $sph--small;
|
|
@@ -131,7 +131,7 @@ $list-step-bullet-margin: $sph--x-large;
|
|
|
131
131
|
}
|
|
132
132
|
|
|
133
133
|
.p-list--divided > .p-list__item:first-child {
|
|
134
|
-
box-shadow: inset 0px 1px 0px 0px $
|
|
134
|
+
box-shadow: inset 0px 1px 0px 0px $colors--theme--border-low-contrast;
|
|
135
135
|
}
|
|
136
136
|
}
|
|
137
137
|
|
|
@@ -318,6 +318,9 @@ $list-step-bullet-margin: $sph--x-large;
|
|
|
318
318
|
|
|
319
319
|
.p-stepped-list__title + .p-stepped-list__content {
|
|
320
320
|
margin-left: $bullet-width-mobile + $list-step-bullet-margin;
|
|
321
|
+
@media (min-width: $threshold-6-12-col) {
|
|
322
|
+
padding-top: $spv-nudge;
|
|
323
|
+
}
|
|
321
324
|
|
|
322
325
|
@media (min-width: $breakpoint-heading-threshold) {
|
|
323
326
|
margin-left: $bullet-width + $list-step-bullet-margin;
|
|
@@ -392,11 +395,10 @@ $list-step-bullet-margin: $sph--x-large;
|
|
|
392
395
|
@include vf-b-row-reset;
|
|
393
396
|
|
|
394
397
|
@media (min-width: $threshold-6-12-col) {
|
|
395
|
-
padding-top: $sp-unit;
|
|
396
398
|
position: relative;
|
|
397
399
|
|
|
398
400
|
&::after {
|
|
399
|
-
background-color: $colors--
|
|
401
|
+
background-color: $colors--theme--border-low-contrast;
|
|
400
402
|
content: '';
|
|
401
403
|
height: 1px;
|
|
402
404
|
left: 0;
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
|
|
6
6
|
.p-modal {
|
|
7
7
|
align-items: center;
|
|
8
|
-
background:
|
|
8
|
+
background: $colors--theme--background-overlay;
|
|
9
9
|
bottom: 0;
|
|
10
10
|
display: flex;
|
|
11
11
|
height: 100vh;
|
|
@@ -21,9 +21,11 @@
|
|
|
21
21
|
}
|
|
22
22
|
|
|
23
23
|
.p-modal__dialog {
|
|
24
|
-
@extend %vf-card;
|
|
24
|
+
@extend %vf-card-padding;
|
|
25
25
|
@extend %vf-has-box-shadow;
|
|
26
26
|
|
|
27
|
+
background-color: $colors--theme--background-default;
|
|
28
|
+
color: $colors--theme--text-default;
|
|
27
29
|
left: $sph--x-large;
|
|
28
30
|
margin-bottom: 0;
|
|
29
31
|
max-height: calc(100% - 2 * $spv--large);
|
|
@@ -46,7 +48,7 @@
|
|
|
46
48
|
.p-modal__header {
|
|
47
49
|
@extend %vf-pseudo-border--bottom;
|
|
48
50
|
|
|
49
|
-
background: $
|
|
51
|
+
background: $colors--theme--background-default;
|
|
50
52
|
display: flex;
|
|
51
53
|
justify-content: space-between;
|
|
52
54
|
margin-bottom: $spv--small;
|
|
@@ -65,8 +67,8 @@
|
|
|
65
67
|
}
|
|
66
68
|
|
|
67
69
|
.p-modal__close {
|
|
70
|
+
@include vf-icon-close-themed;
|
|
68
71
|
background: {
|
|
69
|
-
image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' height='90' width='90'%3E%3Cg color='%23000'%3E%3Cpath fill='none' d='M0 0h90v90H0z'/%3E%3Cpath d='M14.52 6L6 14.52 36.48 45 6 75.49 14.52 84 45 53.52 75.48 84 84 75.49 53.52 45 84 14.52 75.48 6 45 36.49z' fill='%23888'/%3E%3C/g%3E%3C/svg%3E");
|
|
70
72
|
position: center;
|
|
71
73
|
repeat: no-repeat;
|
|
72
74
|
size: $icon-size;
|
|
@@ -83,10 +85,6 @@
|
|
|
83
85
|
text-indent: -999em;
|
|
84
86
|
top: 0;
|
|
85
87
|
width: $icon-size;
|
|
86
|
-
|
|
87
|
-
&:focus {
|
|
88
|
-
outline: $bar-thickness solid $color-focus;
|
|
89
|
-
}
|
|
90
88
|
}
|
|
91
89
|
|
|
92
90
|
.p-modal__footer {
|
|
@@ -872,50 +872,54 @@ $spv-navigation-logo-bottom-position: 0.125rem; // 2px when 1rem is 16px
|
|
|
872
872
|
}
|
|
873
873
|
/* stylelint-enable max-nesting-depth */
|
|
874
874
|
|
|
875
|
-
.p-navigation--sliding
|
|
876
|
-
.
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
}
|
|
880
|
-
@media (min-width: $breakpoint-navigation-threshold) {
|
|
881
|
-
display: none;
|
|
882
|
-
}
|
|
883
|
-
}
|
|
875
|
+
.p-navigation--sliding {
|
|
876
|
+
// Default positioning for nested dropdown buttons. Overridden by subsequent styles.
|
|
877
|
+
.p-navigation__item--dropdown-toggle {
|
|
878
|
+
position: initial;
|
|
884
879
|
|
|
885
|
-
|
|
886
|
-
|
|
880
|
+
&::after {
|
|
881
|
+
content: none;
|
|
882
|
+
}
|
|
887
883
|
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
}
|
|
884
|
+
.p-navigation__link::after {
|
|
885
|
+
@include vf-icon-chevron-themed;
|
|
891
886
|
|
|
892
|
-
|
|
893
|
-
|
|
887
|
+
background-position: center;
|
|
888
|
+
background-repeat: no-repeat;
|
|
889
|
+
background-size: contain;
|
|
890
|
+
content: '';
|
|
891
|
+
display: block;
|
|
892
|
+
height: $spv--large;
|
|
893
|
+
pointer-events: none;
|
|
894
|
+
position: absolute;
|
|
895
|
+
right: map-get($grid-margin-widths, small);
|
|
896
|
+
text-indent: calc(100% + 10rem);
|
|
897
|
+
top: 1rem;
|
|
898
|
+
transform: rotate(-90deg);
|
|
899
|
+
width: map-get($icon-sizes, default);
|
|
894
900
|
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
|
|
901
|
-
pointer-events: none;
|
|
902
|
-
position: absolute;
|
|
903
|
-
right: map-get($grid-margin-widths, small);
|
|
904
|
-
text-indent: calc(100% + 10rem);
|
|
905
|
-
top: 1rem;
|
|
906
|
-
transform: rotate(-90deg);
|
|
907
|
-
width: map-get($icon-sizes, default);
|
|
901
|
+
@media (min-width: $breakpoint-navigation-threshold) {
|
|
902
|
+
right: 0.5rem;
|
|
903
|
+
top: 1.2rem;
|
|
904
|
+
transform: none;
|
|
905
|
+
}
|
|
906
|
+
}
|
|
908
907
|
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
908
|
+
&.is-active > .p-navigation__link::after {
|
|
909
|
+
@media (min-width: $breakpoint-navigation-threshold) {
|
|
910
|
+
transform: rotate(180deg);
|
|
911
|
+
}
|
|
913
912
|
}
|
|
914
913
|
}
|
|
915
914
|
|
|
916
|
-
|
|
915
|
+
// Style for the "go back" button that closes the current level of the sidenav dropdown. Overrides base style from above
|
|
916
|
+
.p-navigation__item--dropdown-close {
|
|
917
|
+
.p-navigation__link::after {
|
|
918
|
+
left: 1rem;
|
|
919
|
+
transform: rotate(90deg);
|
|
920
|
+
}
|
|
917
921
|
@media (min-width: $breakpoint-navigation-threshold) {
|
|
918
|
-
|
|
922
|
+
display: none;
|
|
919
923
|
}
|
|
920
924
|
}
|
|
921
925
|
}
|
|
@@ -7,8 +7,8 @@
|
|
|
7
7
|
|
|
8
8
|
&.is-active,
|
|
9
9
|
&[aria-current='page'] {
|
|
10
|
-
background-color:
|
|
11
|
-
color: $colors--
|
|
10
|
+
background-color: $colors--theme--background-active;
|
|
11
|
+
color: $colors--theme--text-default;
|
|
12
12
|
text-decoration: none;
|
|
13
13
|
}
|
|
14
14
|
}
|
package/scss/_patterns_rule.scss
CHANGED
|
@@ -8,19 +8,11 @@
|
|
|
8
8
|
}
|
|
9
9
|
|
|
10
10
|
.p-rule--muted {
|
|
11
|
-
background-color: $colors--
|
|
12
|
-
|
|
13
|
-
&.is-dark {
|
|
14
|
-
background-color: $colors--dark-theme--border-low-contrast;
|
|
15
|
-
}
|
|
11
|
+
background-color: $colors--theme--border-low-contrast;
|
|
16
12
|
}
|
|
17
13
|
|
|
18
14
|
.p-rule--highlight {
|
|
19
|
-
@include vf-highlight-bar($colors--
|
|
20
|
-
|
|
21
|
-
&.is-dark {
|
|
22
|
-
@include vf-highlight-bar($colors--dark-theme--text-default);
|
|
23
|
-
}
|
|
15
|
+
@include vf-highlight-bar($colors--theme--text-default);
|
|
24
16
|
|
|
25
17
|
&.is-accent {
|
|
26
18
|
@include vf-highlight-bar($color-accent);
|
|
@@ -117,8 +117,6 @@
|
|
|
117
117
|
width: 100%;
|
|
118
118
|
z-index: 102;
|
|
119
119
|
|
|
120
|
-
.p-side-navigation:target &,
|
|
121
|
-
[class*='p-side-navigation--']:target &,
|
|
122
120
|
// is-expanded and is-collapsed are deprecated and replaced by is-drawer-expanded and is-drawer-collapsed
|
|
123
121
|
.p-side-navigation.is-expanded &,
|
|
124
122
|
.p-side-navigation.is-drawer-expanded &,
|
|
@@ -167,8 +165,6 @@
|
|
|
167
165
|
top: 0;
|
|
168
166
|
z-index: 101;
|
|
169
167
|
|
|
170
|
-
.p-side-navigation:target &,
|
|
171
|
-
[class*='p-side-navigation--']:target &,
|
|
172
168
|
.p-side-navigation.is-expanded &,
|
|
173
169
|
.p-side-navigation.is-drawer-expanded &,
|
|
174
170
|
[class*='p-side-navigation--'].is-expanded &,
|
|
@@ -258,8 +254,6 @@
|
|
|
258
254
|
|
|
259
255
|
.p-side-navigation__drawer,
|
|
260
256
|
// fight specificity of expanded version
|
|
261
|
-
.p-side-navigation:target .p-side-navigation__drawer,
|
|
262
|
-
[class*='p-side-navigation--']:target .p-side-navigation__drawer,
|
|
263
257
|
.p-side-navigation.is-expanded .p-side-navigation__drawer,
|
|
264
258
|
.p-side-navigation.is-drawer-expanded .p-side-navigation__drawer,
|
|
265
259
|
[class*='p-side-navigation--'].is-expanded .p-side-navigation__drawer,
|
package/scss/_patterns_suru.scss
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
:root,
|
|
9
9
|
.is-light,
|
|
10
10
|
.is-paper {
|
|
11
|
-
// new suru backgrounds don't have
|
|
11
|
+
// new suru backgrounds don't have white (light) version,
|
|
12
12
|
// they need paper background
|
|
13
13
|
--vf-suru-background: #{$color-paper};
|
|
14
14
|
--vf-suru-25-75: url('#{$assets-path}505636a6-0000_suru-main-25x75-light.png');
|
|
@@ -17,6 +17,7 @@
|
|
|
17
17
|
--vf-suru-fan-bottom-right: url('#{$assets-path}2adade55-suru-corner-fan--bottom-0000_light.jpg');
|
|
18
18
|
--vf-suru-pyramid-top-left: url('#{$assets-path}8846d6a5-suru-pyramid-top-corner_0000_light.jpg');
|
|
19
19
|
--vf-suru-pyramid-top-right: url('#{$assets-path}5d9f8cd3-suru-pyramid-top-right-corner_0000_light.jpg');
|
|
20
|
+
--vf-suru-divider: url('#{$assets-path}9e25feb2-suru-triangle-from-left-edge--_0000_light.jpg');
|
|
20
21
|
}
|
|
21
22
|
|
|
22
23
|
.is-dark {
|
|
@@ -27,6 +28,7 @@
|
|
|
27
28
|
--vf-suru-fan-bottom-right: url('#{$assets-path}725af649-suru-corner-fan--bottom-0001_dark.jpg');
|
|
28
29
|
--vf-suru-pyramid-top-left: url('#{$assets-path}86ed5771-suru-pyramid-top-corner_0001_dark.jpg');
|
|
29
30
|
--vf-suru-pyramid-top-right: url('#{$assets-path}9f740811-suru-pyramid-top-right-corner_0001_dark.jpg');
|
|
31
|
+
--vf-suru-divider: url('#{$assets-path}9c0bee5c-suru-triangle-from-left-edge--_0001_dark.jpg');
|
|
30
32
|
}
|
|
31
33
|
}
|
|
32
34
|
|
|
@@ -85,7 +87,6 @@
|
|
|
85
87
|
}
|
|
86
88
|
|
|
87
89
|
// padding top based on p-section--hero
|
|
88
|
-
// bottom padding not needed (as it's covered by the suru background image)
|
|
89
90
|
padding-top: $spv--large;
|
|
90
91
|
|
|
91
92
|
// on large screens, same as %section-padding--shallow
|
|
@@ -108,7 +109,7 @@
|
|
|
108
109
|
background-image: var(--vf-suru-fan-top-right);
|
|
109
110
|
background-position: top right;
|
|
110
111
|
background-repeat: no-repeat;
|
|
111
|
-
background-size:
|
|
112
|
+
background-size: 32rem 24.09rem; // based on image dimensions (2048x1542) scaled down by 0.25, coverted to rem
|
|
112
113
|
}
|
|
113
114
|
|
|
114
115
|
.p-suru--fan-bottom {
|
|
@@ -121,7 +122,7 @@
|
|
|
121
122
|
background-image: var(--vf-suru-pyramid-top-left);
|
|
122
123
|
background-position: top left;
|
|
123
124
|
background-repeat: no-repeat;
|
|
124
|
-
background-size:
|
|
125
|
+
background-size: 22.125rem 16.1718rem; // based on image dimensions (1380x1035) scaled down by 0.25, converted to rem
|
|
125
126
|
}
|
|
126
127
|
|
|
127
128
|
.p-suru--pyramid-right {
|
|
@@ -129,4 +130,34 @@
|
|
|
129
130
|
background-position: top right;
|
|
130
131
|
}
|
|
131
132
|
}
|
|
133
|
+
|
|
134
|
+
.p-suru--divider {
|
|
135
|
+
background-color: var(--vf-suru-background);
|
|
136
|
+
color: $colors--theme--text-default;
|
|
137
|
+
// same as %section-padding--deep
|
|
138
|
+
padding-bottom: calc($spv--strip-deep / 2);
|
|
139
|
+
position: relative;
|
|
140
|
+
|
|
141
|
+
// only apply suru background images on large screens
|
|
142
|
+
@media (min-width: $breakpoint-large) {
|
|
143
|
+
padding-bottom: calc(2 * $spv--strip-deep);
|
|
144
|
+
|
|
145
|
+
&::after {
|
|
146
|
+
$suru-divider-height: 13.75rem; // 220px / 16px = 13.75rem
|
|
147
|
+
|
|
148
|
+
background-image: var(--vf-suru-divider);
|
|
149
|
+
background-position: bottom left;
|
|
150
|
+
background-repeat: no-repeat;
|
|
151
|
+
background-size: 80rem 14.8125rem; // based on image dimensions (2560x474) scaled down by 0.5, converted to rem
|
|
152
|
+
|
|
153
|
+
bottom: calc((2 * $spv--strip-deep - $suru-divider-height) / 2);
|
|
154
|
+
content: '';
|
|
155
|
+
display: block;
|
|
156
|
+
|
|
157
|
+
height: $suru-divider-height;
|
|
158
|
+
position: absolute;
|
|
159
|
+
width: 100%;
|
|
160
|
+
}
|
|
161
|
+
}
|
|
162
|
+
}
|
|
132
163
|
}
|
|
@@ -179,9 +179,9 @@ $colors--dark-theme--background-active: rgba($colors--dark-theme--text-default,
|
|
|
179
179
|
$colors--dark-theme--background-hover: rgba($colors--dark-theme--text-default, $hover-background-opacity-amount) !default;
|
|
180
180
|
$colors--dark-theme--background-overlay: transparentize($color-dark, 0.15) !default;
|
|
181
181
|
|
|
182
|
-
$colors--dark-theme--border-default: rgba($colors--dark-theme--text-default, 0.
|
|
182
|
+
$colors--dark-theme--border-default: rgba($colors--dark-theme--text-default, 0.2) !default;
|
|
183
183
|
$colors--dark-theme--border-high-contrast: rgba($colors--dark-theme--text-default, 0.5) !default;
|
|
184
|
-
$colors--dark-theme--border-low-contrast: rgba($colors--dark-theme--text-default, 0.
|
|
184
|
+
$colors--dark-theme--border-low-contrast: rgba($colors--dark-theme--text-default, 0.1) !default;
|
|
185
185
|
|
|
186
186
|
$colors--dark-theme--icon: $colors--dark-theme--text-default !default;
|
|
187
187
|
|
|
@@ -52,10 +52,10 @@ $nudges: (
|
|
|
52
52
|
h4-large: 0.45rem,
|
|
53
53
|
h4: 0.45rem,
|
|
54
54
|
h4-mobile: 0.45rem,
|
|
55
|
-
h5: 0.
|
|
56
|
-
h6: 0.
|
|
57
|
-
h6-large: 0.
|
|
58
|
-
p: 0.
|
|
55
|
+
h5: 0.375rem,
|
|
56
|
+
h6: 0.375em,
|
|
57
|
+
h6-large: 0.375rem,
|
|
58
|
+
p: 0.375rem,
|
|
59
59
|
p-ubuntumono: 0.45rem,
|
|
60
60
|
small: 0.05rem,
|
|
61
61
|
x-small: 0.25rem,
|
|
@@ -34,19 +34,4 @@
|
|
|
34
34
|
}
|
|
35
35
|
}
|
|
36
36
|
// stylelint-enable selector-max-type
|
|
37
|
-
|
|
38
|
-
.u-baseline-grid__toggle {
|
|
39
|
-
bottom: $spv--x-large;
|
|
40
|
-
color: $colors--light-theme--text-default; // Force light theme colour because of baseline grid background
|
|
41
|
-
position: fixed;
|
|
42
|
-
right: $sp-unit * 3;
|
|
43
|
-
z-index: 201;
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
// hide the theme toggle in Percy
|
|
47
|
-
@media only percy {
|
|
48
|
-
.u-baseline-grid__toggle {
|
|
49
|
-
visibility: hidden !important;
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
37
|
}
|
|
@@ -3,13 +3,19 @@
|
|
|
3
3
|
@extend %fixed-width-container;
|
|
4
4
|
}
|
|
5
5
|
|
|
6
|
-
|
|
7
|
-
|
|
6
|
+
// stylelint-disable selector-max-type -- table elements can use selector types
|
|
7
|
+
.u-table-layout--auto {
|
|
8
|
+
&,
|
|
9
|
+
table {
|
|
8
10
|
table-layout: auto !important;
|
|
9
11
|
}
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
.u-table-layout--fixed {
|
|
15
|
+
&,
|
|
16
|
+
table {
|
|
12
17
|
table-layout: fixed !important;
|
|
13
18
|
}
|
|
14
19
|
}
|
|
20
|
+
// stylelint-enable selector-max-type
|
|
15
21
|
}
|
package/scss/_vanilla.scss
CHANGED
|
@@ -89,7 +89,6 @@
|
|
|
89
89
|
@import 'utilities_no-print';
|
|
90
90
|
@import 'utilities_text-max-width';
|
|
91
91
|
@import 'utilities_text-figures';
|
|
92
|
-
@import 'utilities_theme-toggle';
|
|
93
92
|
|
|
94
93
|
// Include all the CSS
|
|
95
94
|
@mixin vanilla {
|
|
@@ -183,5 +182,4 @@
|
|
|
183
182
|
@include vf-u-no-print;
|
|
184
183
|
@include vf-u-text-max-width;
|
|
185
184
|
@include vf-u-text-figures;
|
|
186
|
-
@include vf-u-theme-toggle;
|
|
187
185
|
}
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
@import 'settings';
|
|
2
|
-
|
|
3
|
-
@mixin vf-u-theme-toggle {
|
|
4
|
-
.u-theme-toggle {
|
|
5
|
-
bottom: $spv--x-large;
|
|
6
|
-
position: fixed;
|
|
7
|
-
right: $sp-unit * 30;
|
|
8
|
-
z-index: 100;
|
|
9
|
-
|
|
10
|
-
.u-theme-toggle__button {
|
|
11
|
-
margin: 0;
|
|
12
|
-
|
|
13
|
-
&:not(:last-child) {
|
|
14
|
-
border-right: 0;
|
|
15
|
-
}
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
.u-theme-toggle__dark {
|
|
19
|
-
background-color: $colors--dark-theme--background-default;
|
|
20
|
-
color: $colors--dark-theme--text-default;
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
.u-theme-toggle__light {
|
|
24
|
-
background-color: $colors--light-theme--background-default;
|
|
25
|
-
color: $colors--light-theme--text-default;
|
|
26
|
-
}
|
|
27
|
-
.u-theme-toggle__paper {
|
|
28
|
-
background-color: $color-paper;
|
|
29
|
-
color: $color-x-dark;
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
// hide the theme toggle in Percy
|
|
34
|
-
@media only percy {
|
|
35
|
-
.u-theme-toggle {
|
|
36
|
-
visibility: hidden !important;
|
|
37
|
-
}
|
|
38
|
-
}
|
|
39
|
-
}
|