vanilla-framework 3.1.0 → 3.3.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/package.json CHANGED
@@ -44,7 +44,7 @@
44
44
  "percy": "percy exec -- node snapshots.js",
45
45
  "icon-svgs-to-mixins": "node scripts/convert-svgs-to-icon-mixins.js icons"
46
46
  },
47
- "version": "3.1.0",
47
+ "version": "3.3.0",
48
48
  "files": [
49
49
  "_index.scss",
50
50
  "/scss",
@@ -54,18 +54,18 @@
54
54
  "dependencies": {
55
55
  "@canonical/cookie-policy": "3.4.0",
56
56
  "@canonical/latest-news": "1.3.0",
57
- "autoprefixer": "10.4.2",
58
- "postcss": "8.4.6",
57
+ "autoprefixer": "10.4.4",
58
+ "postcss": "8.4.12",
59
59
  "postcss-cli": "9.1.0",
60
- "sass": "1.49.7"
60
+ "sass": "1.49.11"
61
61
  },
62
62
  "devDependencies": {
63
63
  "@percy/script": "1.1.0",
64
64
  "get-site-urls": "1.1.7",
65
65
  "markdown-spellcheck": "1.3.1",
66
66
  "parker": "0.0.10",
67
- "prettier": "2.5.1",
68
- "stylelint": "14.3.0",
67
+ "prettier": "2.6.2",
68
+ "stylelint": "14.6.1",
69
69
  "stylelint-config-prettier": "9.0.3",
70
70
  "stylelint-config-recommended-scss": "5.0.2",
71
71
  "stylelint-order": "5.0.0",
@@ -16,48 +16,45 @@
16
16
  }
17
17
 
18
18
  .p-accordion__tab {
19
- // calculate icon top position based on top padding (from %single-border-text-vpadding--scaling)
20
- // and offset to align it with baseline of accordion tab text element
21
- $icon-top-position: calc(#{$table-cell-vertical-padding + (map-get($line-heights, default-text) - $icon-size) * 0.5});
22
-
23
19
  @extend %single-border-text-vpadding--scaling;
24
20
  @include vf-focus;
25
21
 
26
- background: {
27
- color: inherit;
28
- position: top $icon-top-position left $sph--large;
29
- repeat: no-repeat;
30
- }
31
-
22
+ background-color: inherit;
32
23
  border: 0;
33
24
  border-radius: 0;
34
25
  font-size: inherit;
35
26
  justify-content: flex-start;
36
27
  margin-bottom: 0;
37
- padding-left: $sph--large + $icon-size + $sph--large;
38
28
  padding-right: $sph--large;
29
+ position: relative;
39
30
  text-align: left;
40
31
  transition-duration: 0s;
41
32
  width: 100%;
42
33
  z-index: 2;
43
34
 
35
+ &::before {
36
+ @include vf-icon-chevron($color-mid-dark);
37
+ @include vf-animation($property: transform, $duration: fast);
38
+ @extend %icon;
39
+
40
+ content: '';
41
+ margin-right: $sph--large;
42
+ }
43
+
44
44
  // aria-selected controls the open and closed state for the accordion tab
45
45
  &[aria-expanded='true'] {
46
- @include vf-icon-minus($color-mid-dark);
47
-
48
46
  // override base expanded button styles
49
47
  background-color: inherit;
48
+
50
49
  &:hover {
51
50
  background-color: $colors--light-theme--background-hover;
52
51
  }
53
-
54
- background-size: $icon-size;
55
52
  }
56
53
 
57
54
  &[aria-expanded='false'] {
58
- @include vf-icon-plus($color-mid-dark);
59
-
60
- background-size: $icon-size;
55
+ &::before {
56
+ transform: rotate(-90deg);
57
+ }
61
58
  }
62
59
  }
63
60
 
@@ -74,25 +71,17 @@
74
71
  }
75
72
 
76
73
  // stylelint-disable selector-max-type
77
- h2.p-accordion__heading > .p-accordion__tab,
78
- .p-heading--2 > .p-accordion__tab {
79
- $icon-top-position: calc(#{$table-cell-vertical-padding + (map-get($line-heights, h2) - $icon-size) * 0.5});
80
-
81
- background-position-y: $icon-top-position;
74
+ .p-heading--2 > .p-accordion__tab::before,
75
+ h2.p-accordion__heading > .p-accordion__tab::before {
76
+ @include vf-icon-size($x-height);
77
+ vertical-align: 0;
82
78
  }
83
79
 
84
- h3.p-accordion__heading > .p-accordion__tab,
85
- .p-heading--3 > .p-accordion__tab {
86
- $icon-top-position: calc(#{$table-cell-vertical-padding + (map-get($line-heights, h3) - $icon-size) * 0.5});
87
-
88
- background-position-y: $icon-top-position;
89
- }
90
-
91
- h4.p-accordion__heading > .p-accordion__tab,
92
- .p-heading--4 > .p-accordion__tab {
93
- $icon-top-position: calc(#{$table-cell-vertical-padding + (map-get($line-heights, h4) - $icon-size) * 0.5});
94
-
95
- background-position-y: $icon-top-position;
80
+ .p-heading--3 > .p-accordion__tab::before,
81
+ .p-heading--4 > .p-accordion__tab::before,
82
+ h3.p-accordion__heading > .p-accordion__tab::before,
83
+ h4.p-accordion__heading > .p-accordion__tab::before {
84
+ vertical-align: 0;
96
85
  }
97
86
  // stylelint-enable selector-max-type
98
87
 
@@ -40,10 +40,10 @@ $code-snippet-header-v-spacing: $spv--small;
40
40
 
41
41
  .p-code-snippet__block--numbered {
42
42
  counter-reset: line-numbering;
43
- }
44
43
 
45
- .p-code-snippet__line {
46
- @extend %code-numbered-line;
44
+ .p-code-snippet__line {
45
+ @extend %code-numbered-line;
46
+ }
47
47
  }
48
48
 
49
49
  .p-code-snippet__header {
@@ -1,12 +1,25 @@
1
1
  @import 'settings';
2
2
 
3
3
  $lightness-threshold: 70;
4
+ $navigation-logo-tag-width: 1.5rem;
5
+ $navigation-logo-tag-height: 2.2rem;
6
+ $navigation-logo-tag-height-desktop: 2.4rem;
7
+ $navigation-logo-height: 3rem;
8
+ $navigation-logo-height-desktop: 3.5rem;
9
+ $navigation-logo-width: 1.1rem;
10
+ $sph-navigation-link: 0.3rem;
11
+ $spv-navigation-logo: 0.3125rem;
4
12
 
5
13
  @mixin vf-p-navigation {
6
14
  // placeholders
7
15
  %navigation-link-responsive-padding-vertical {
8
- padding-bottom: $spv--large;
9
- padding-top: $spv--large;
16
+ padding-bottom: $spv--medium;
17
+ padding-top: $spv--medium;
18
+
19
+ @media (min-width: $breakpoint-navigation-threshold) {
20
+ padding-bottom: $spv--large;
21
+ padding-top: $spv--large;
22
+ }
10
23
  }
11
24
 
12
25
  %navigation-link-responsive-padding-left {
@@ -47,6 +60,11 @@ $lightness-threshold: 70;
47
60
  @include vf-animation($properties, snap);
48
61
  @include vf-focus;
49
62
 
63
+ // override button styles
64
+ background-color: transparent;
65
+ border: none;
66
+ border-radius: 0;
67
+
50
68
  display: block;
51
69
  font-weight: $font-weight-bold;
52
70
  line-height: map-get($line-heights, default-text);
@@ -179,12 +197,17 @@ $lightness-threshold: 70;
179
197
  }
180
198
  }
181
199
 
200
+ // Styles for old navigation logo
182
201
  .p-navigation__logo {
183
202
  display: flex;
184
203
  flex: 0 0 auto;
185
- height: 3.5rem;
204
+ height: $navigation-logo-height;
186
205
  margin: 0 $sph--large 0 0;
187
206
 
207
+ @media (min-width: $breakpoint-navigation-threshold) {
208
+ height: $navigation-logo-height-desktop;
209
+ }
210
+
188
211
  .p-navigation__item {
189
212
  @include vf-focus;
190
213
 
@@ -192,6 +215,53 @@ $lightness-threshold: 70;
192
215
  }
193
216
  }
194
217
 
218
+ .p-navigation__tagged-logo {
219
+ display: flex; // to prevent logo link from expanding full width
220
+ margin-right: 0;
221
+ min-width: 13rem;
222
+
223
+ .p-navigation__logo-tag {
224
+ background-color: $color-accent;
225
+ height: $navigation-logo-tag-height;
226
+ left: 0;
227
+ position: absolute;
228
+ top: 0;
229
+ width: $navigation-logo-tag-width;
230
+
231
+ @media (min-width: $breakpoint-navigation-threshold) {
232
+ height: $navigation-logo-tag-height-desktop;
233
+ }
234
+ }
235
+
236
+ .p-navigation__logo-icon {
237
+ bottom: $spv-navigation-logo;
238
+ left: 50%;
239
+ position: absolute;
240
+ transform: translate(-50%, 0);
241
+ width: $navigation-logo-width;
242
+ }
243
+
244
+ .p-navigation__logo-title {
245
+ @extend %vf-heading-4;
246
+
247
+ line-height: map-get($line-heights, x-small);
248
+ }
249
+
250
+ .p-navigation__link {
251
+ @extend %navigation-link;
252
+
253
+ padding-left: $navigation-logo-tag-width + $sph-navigation-link;
254
+
255
+ &:hover {
256
+ background-color: transparent !important;
257
+ }
258
+
259
+ &::before {
260
+ content: none;
261
+ }
262
+ }
263
+ }
264
+
195
265
  .p-navigation__image {
196
266
  align-self: center;
197
267
  max-height: 2rem;
@@ -199,6 +269,19 @@ $lightness-threshold: 70;
199
269
  }
200
270
 
201
271
  // navigation items
272
+ .p-navigation__items {
273
+ display: none; // hidden by default on mobile (expands is a dropdown)
274
+ list-style: none;
275
+ margin: -1px 0 0 0;
276
+ padding: 0;
277
+
278
+ @media (min-width: $breakpoint-navigation-threshold) {
279
+ display: flex;
280
+ flex-wrap: wrap;
281
+ margin-top: 0; // prevents bottom border of nav from moving 1px
282
+ }
283
+ }
284
+
202
285
  .p-navigation__nav {
203
286
  display: none;
204
287
  flex-direction: column;
@@ -212,15 +295,14 @@ $lightness-threshold: 70;
212
295
  }
213
296
  }
214
297
 
215
- .p-navigation__items {
216
- list-style: none;
217
- margin: -1px 0 0 0;
218
- padding: 0;
298
+ // items inside the logo banner (for mobile menu)
299
+ .p-navigation__banner .p-navigation__items {
300
+ display: flex;
301
+ flex-wrap: wrap;
302
+ margin-top: 0; // prevents bottom border of nav from moving 1px
219
303
 
220
304
  @media (min-width: $breakpoint-navigation-threshold) {
221
- display: flex;
222
- flex-wrap: wrap;
223
- margin-top: 0; // prevents bottom border of nav from moving 1px
305
+ display: none;
224
306
  }
225
307
  }
226
308
 
@@ -229,7 +311,8 @@ $lightness-threshold: 70;
229
311
  display: none;
230
312
  }
231
313
 
232
- .p-navigation__toggle--open {
314
+ .p-navigation__toggle--open,
315
+ .p-navigation__toggle--search {
233
316
  display: block;
234
317
 
235
318
  @media (min-width: $breakpoint-navigation-threshold) {
@@ -238,7 +321,8 @@ $lightness-threshold: 70;
238
321
  }
239
322
 
240
323
  .p-navigation__toggle--open,
241
- .p-navigation__toggle--close {
324
+ .p-navigation__toggle--close,
325
+ .p-navigation__toggle--search {
242
326
  @extend %navigation-link-responsive-padding-horizontal;
243
327
  @extend %navigation-link-responsive-padding-vertical;
244
328
  @include vf-focus;
@@ -262,6 +346,14 @@ $lightness-threshold: 70;
262
346
  display: flex;
263
347
  }
264
348
 
349
+ .p-navigation__items {
350
+ display: block;
351
+
352
+ @media (min-width: $breakpoint-navigation-threshold) {
353
+ display: flex;
354
+ }
355
+ }
356
+
265
357
  .p-navigation__toggle--open {
266
358
  display: none;
267
359
  }
@@ -279,6 +371,7 @@ $lightness-threshold: 70;
279
371
 
280
372
  // on mobile screens search box is visible inside of the mobile navigation dropdown
281
373
  .p-navigation__search {
374
+ display: none;
282
375
  padding-top: $spv--large;
283
376
 
284
377
  // allow search box to take full width
@@ -287,64 +380,59 @@ $lightness-threshold: 70;
287
380
  }
288
381
  }
289
382
 
290
- // on mobile screens both search toggle and overlay are not used and hidden from view
291
383
  .p-navigation__link--search-toggle {
292
384
  @extend %navigation-link;
293
385
 
294
- display: none;
386
+ display: block;
295
387
  height: 100%; // keep the height of the navigation when 'Search' label is hidden
296
388
  padding-left: 0; // on small screens label is hidden, so we remove left padding as well
297
389
  padding-right: 2 * $sph--small + map-get($icon-sizes, default);
298
390
  position: relative;
299
- }
300
391
 
301
- .p-navigation__search-overlay {
302
- display: none;
303
- }
392
+ // hide "search" label on small screens (only show the icon)
393
+ .p-navigation__search-label {
394
+ display: none;
395
+ }
304
396
 
305
- // the expanding search box is only visible on large screens in navigation bar
306
- @media (min-width: $breakpoint-navigation-threshold) {
307
- .p-navigation__link--search-toggle {
308
- display: block;
397
+ // show both label and icon on large screens
398
+ @media (min-width: $breakpoint-large) {
399
+ padding-left: $sph--large;
309
400
 
310
- // hide "search" label on small screens (only show the icon)
311
401
  .p-navigation__search-label {
312
- display: none;
402
+ display: initial;
313
403
  }
404
+ }
314
405
 
315
- // show both label and icon on large screens
316
- @media (min-width: $breakpoint-large) {
317
- padding-left: $sph--large;
318
-
319
- .p-navigation__search-label {
320
- display: initial;
321
- }
322
- }
406
+ &::after {
407
+ background-position: center;
408
+ background-repeat: no-repeat;
409
+ background-size: contain;
410
+ content: '';
411
+ display: block;
412
+ height: $spv--large;
413
+ pointer-events: none;
414
+ position: absolute;
415
+ right: calc(#{$sph--small} + 1px); // 1px for the border on selects. this aligns it with any selects underneath
416
+ text-indent: calc(100% + 10rem);
417
+ top: calc(#{$spv--medium} + #{map-get($nudges, x-small)});
418
+ width: map-get($icon-sizes, default);
323
419
 
324
- &::after {
325
- background-position: center;
326
- background-repeat: no-repeat;
327
- background-size: contain;
328
- content: '';
329
- display: block;
330
- height: $spv--large;
331
- pointer-events: none;
332
- position: absolute;
333
- right: map-get($grid-margin-widths, small);
334
- text-indent: calc(100% + 10rem);
420
+ @media (min-width: $breakpoint-navigation-threshold) {
335
421
  top: calc(#{$spv--large} + #{map-get($nudges, x-small)});
336
- width: map-get($icon-sizes, default);
422
+ }
423
+ }
424
+ }
337
425
 
338
- @media (min-width: $threshold-4-6-col) {
339
- right: map-get($grid-margin-widths, default);
340
- }
426
+ .p-navigation__nav .p-navigation__link--search-toggle {
427
+ display: none;
341
428
 
342
- @media (min-width: $breakpoint-navigation-threshold) {
343
- right: calc(#{$sph--small} + 1px); // 1px for the border on selects. this aligns it with any selects underneath
344
- }
345
- }
429
+ @media (min-width: $breakpoint-navigation-threshold) {
430
+ display: block;
346
431
  }
432
+ }
347
433
 
434
+ // the expanding search box is only visible on large screens in navigation bar
435
+ @media (min-width: $breakpoint-navigation-threshold) {
348
436
  .p-navigation__search {
349
437
  align-items: center;
350
438
  display: none;
@@ -356,7 +444,6 @@ $lightness-threshold: 70;
356
444
  @include vf-animation(opacity, snap);
357
445
 
358
446
  background-color: $colors--light-theme--background-overlay;
359
- bottom: 0;
360
447
  display: block;
361
448
  height: 100%;
362
449
  left: 0;
@@ -368,30 +455,51 @@ $lightness-threshold: 70;
368
455
  width: 100%;
369
456
  z-index: 59;
370
457
  }
458
+ }
371
459
 
372
- // when navigation search is expanded
373
- .p-navigation.has-search-open {
374
- // hide all navigation items (including search toggle)
375
- .p-navigation__items {
376
- display: none;
377
- }
460
+ // when navigation search is expanded
461
+ .p-navigation.has-search-open {
462
+ // make sure search in navigation renders on top of the overlay
463
+ .p-navigation__nav {
464
+ display: flex;
465
+ z-index: 60;
466
+ }
378
467
 
379
- // show expanded search box
380
- .p-navigation__search {
381
- display: flex;
382
- }
468
+ // hide all navigation items (including search toggle)
469
+ .p-navigation__nav .p-navigation__items {
470
+ display: none;
471
+ }
383
472
 
384
- // fade in search overlay
385
- .p-navigation__search-overlay {
386
- opacity: 0.5;
387
- pointer-events: all;
388
- }
473
+ // show expanded search box
474
+ .p-navigation__search {
475
+ display: flex;
476
+ }
389
477
 
390
- // make sure search in navigation renders on top of the overlay
391
- .p-navigation__nav {
392
- z-index: 60;
478
+ // fade in search overlay
479
+ .p-navigation__search-overlay {
480
+ opacity: 0.5;
481
+ pointer-events: all;
482
+ }
483
+ }
484
+
485
+ .p-navigation.has-menu-open {
486
+ // hide all navigation items (including search toggle)
487
+ .p-navigation__nav {
488
+ display: flex;
489
+ }
490
+
491
+ .p-navigation__nav .p-navigation__items {
492
+ display: block;
493
+
494
+ @media (min-width: $breakpoint-navigation-threshold) {
495
+ display: flex;
393
496
  }
394
497
  }
498
+
499
+ // show expanded search box
500
+ .p-navigation__search {
501
+ display: none;
502
+ }
395
503
  }
396
504
 
397
505
  // DROPDOWNS
@@ -412,7 +520,7 @@ $lightness-threshold: 70;
412
520
  top: $spv--large * 2 + map-get($line-heights, default-text);
413
521
  }
414
522
 
415
- @media (max-width: $breakpoint-navigation-threshold - 1) {
523
+ @media (max-width: ($breakpoint-navigation-threshold - 1)) {
416
524
  box-shadow: none;
417
525
  }
418
526
  }
@@ -537,11 +645,16 @@ $lightness-threshold: 70;
537
645
  background-color: $color-navigation-background--hover;
538
646
  }
539
647
 
648
+ &[aria-pressed='true'],
540
649
  &:active {
541
650
  background-color: $color-navigation-background--active;
542
651
  }
543
652
  }
544
653
 
654
+ .p-navigation__logo-title {
655
+ color: $color-navigation-text;
656
+ }
657
+
545
658
  .p-navigation__item--dropdown-toggle {
546
659
  &::after {
547
660
  @include vf-icon-chevron($color-navigation-icon);
@@ -552,6 +665,7 @@ $lightness-threshold: 70;
552
665
  }
553
666
  }
554
667
 
668
+ .p-navigation__toggle--search::after,
555
669
  .p-navigation__item .p-navigation__link--search-toggle::after {
556
670
  @include vf-icon-search($color-navigation-icon);
557
671
  }
@@ -571,9 +685,19 @@ $lightness-threshold: 70;
571
685
  }
572
686
  }
573
687
 
574
- .p-navigation__link::before {
688
+ .p-navigation__nav .p-navigation__link::before {
575
689
  background: $color-navigation-separator;
576
690
  }
691
+
692
+ // on mobile expanded nav needs to match pressed color of the buttons
693
+ &.has-menu-open .p-navigation__nav,
694
+ &.has-search-open .p-navigation__nav {
695
+ background-color: $color-navigation-background--active;
696
+
697
+ @media (min-width: $breakpoint-navigation-threshold) {
698
+ background-color: transparent;
699
+ }
700
+ }
577
701
  }
578
702
 
579
703
  @mixin vf-navigation-light-theme {
@@ -582,9 +706,9 @@ $lightness-threshold: 70;
582
706
  $color-navigation-background: $colors--light-theme--background-default,
583
707
  $color-navigation-background--hover: $colors--light-theme--background-alt,
584
708
  $color-navigation-background--active: $colors--light-theme--background-active,
585
- $color-navigation-highlight: $color-accent,
709
+ $color-navigation-highlight: $colors--light-theme--text-default,
586
710
  $color-navigation-separator: $colors--light-theme--border-low-contrast,
587
- $color-navigation-icon: $colors--light-theme--text-muted
711
+ $color-navigation-icon: $colors--light-theme--text-default
588
712
  );
589
713
  }
590
714
 
@@ -594,8 +718,8 @@ $lightness-threshold: 70;
594
718
  $color-navigation-background: $colors--dark-theme--background-default,
595
719
  $color-navigation-background--hover: $colors--dark-theme--background-hover,
596
720
  $color-navigation-background--active: $colors--dark-theme--background-active,
597
- $color-navigation-highlight: $color-accent,
721
+ $color-navigation-highlight: $colors--dark-theme--text-default,
598
722
  $color-navigation-separator: $colors--dark-theme--border-low-contrast,
599
- $color-navigation-icon: $colors--dark-theme--text-muted
723
+ $color-navigation-icon: $colors--dark-theme--text-default
600
724
  );
601
725
  }
@@ -29,6 +29,7 @@
29
29
  .p-pull-quote__citation {
30
30
  @extend %vf-heading-6;
31
31
 
32
+ display: block;
32
33
  margin-top: $spv--small;
33
34
  }
34
35
  }
@@ -1,9 +1,14 @@
1
- @mixin vf-p-tab-buttons {
1
+ @mixin vf-p-segmented-control {
2
+ .p-segmented-control,
3
+ // p-tab-buttons is deprecated,
4
+ // please use p-segmented-control instead
2
5
  .p-tab-buttons {
6
+ .p-segmented-control__list,
3
7
  .p-tab-buttons__list {
4
8
  display: flex;
5
9
  }
6
10
 
11
+ .p-segmented-control__button,
7
12
  .p-tab-buttons__button {
8
13
  @extend %vf-button-has-icon;
9
14
 
@@ -41,8 +46,14 @@
41
46
  }
42
47
  }
43
48
 
49
+ &.is-dense .p-segmented-control__button,
44
50
  &.is-dense .p-tab-buttons__button {
45
51
  @extend %vf-button-dense-vertical-padding;
46
52
  }
47
53
  }
48
54
  }
55
+
56
+ // Deprecated mixin kept for compatibility
57
+ @mixin vf-p-tab-buttons {
58
+ @include vf-p-segmented-control;
59
+ }
@@ -35,8 +35,11 @@
35
35
 
36
36
  .p-side-navigation:target &,
37
37
  [class*='p-side-navigation--']:target &,
38
+ // is-expanded and is-collapsed are deprecated and replaced by is-drawer-expanded and is-drawer-collapsed
38
39
  .p-side-navigation.is-expanded &,
39
- [class*='p-side-navigation--'].is-expanded & {
40
+ .p-side-navigation.is-drawer-expanded &,
41
+ [class*='p-side-navigation--'].is-expanded &,
42
+ [class*='p-side-navigation--'].is-drawer-expanded & {
40
43
  @extend %vf-has-box-shadow;
41
44
 
42
45
  animation: vf-p-side-navigation-expand map-get($animation-duration, brisk);
@@ -44,10 +47,20 @@
44
47
  }
45
48
 
46
49
  .p-side-navigation.is-collapsed &,
47
- [class*='p-side-navigation--'].is-collapsed & {
50
+ .p-side-navigation.is-drawer-collapsed &,
51
+ [class*='p-side-navigation--'].is-collapsed &,
52
+ [class*='p-side-navigation--'].is-drawer-collapsed & {
48
53
  animation: vf-p-side-navigation-collapse map-get($animation-duration, brisk);
49
54
  }
50
55
 
56
+ .p-side-navigation.is-drawer-hidden &,
57
+ [class*='p-side-navigation--'].is-drawer-hidden & {
58
+ display: none;
59
+ @media (min-width: $threshold-6-12-col) {
60
+ display: block;
61
+ }
62
+ }
63
+
51
64
  @media (min-width: $breakpoint-x-small) {
52
65
  max-width: 20rem;
53
66
  }
@@ -68,7 +81,9 @@
68
81
  .p-side-navigation:target &,
69
82
  [class*='p-side-navigation--']:target &,
70
83
  .p-side-navigation.is-expanded &,
71
- [class*='p-side-navigation--'].is-expanded & {
84
+ .p-side-navigation.is-drawer-expanded &,
85
+ [class*='p-side-navigation--'].is-expanded &,
86
+ [class*='p-side-navigation--'].is-drawer-expanded & {
72
87
  opacity: 1;
73
88
  pointer-events: all;
74
89
  }
@@ -134,7 +149,9 @@
134
149
  .p-side-navigation:target .p-side-navigation__drawer,
135
150
  [class*='p-side-navigation--']:target .p-side-navigation__drawer,
136
151
  .p-side-navigation.is-expanded .p-side-navigation__drawer,
137
- [class*='p-side-navigation--'].is-expanded .p-side-navigation__drawer {
152
+ .p-side-navigation.is-drawer-expanded .p-side-navigation__drawer,
153
+ [class*='p-side-navigation--'].is-expanded .p-side-navigation__drawer,
154
+ [class*='p-side-navigation--'].is-drawer-expanded .p-side-navigation__drawer {
138
155
  box-shadow: none;
139
156
  display: block;
140
157
  max-width: none;
@@ -416,6 +433,15 @@
416
433
  &::before {
417
434
  @include vf-icon-chevron($color-sidenav-toggle-icon);
418
435
  }
436
+
437
+ &[aria-expanded='true'] {
438
+ background-color: $color-transparent;
439
+
440
+ &:hover {
441
+ background: $color-sidenav-item-background-hover;
442
+ color: $color-sidenav-text-active;
443
+ }
444
+ }
419
445
  }
420
446
 
421
447
  .p-side-navigation__drawer {
@@ -431,11 +457,11 @@
431
457
  border-color: $color-sidenav-list-border;
432
458
  }
433
459
 
434
- %theme-side-navigation__list {
460
+ .p-side-navigation__list::after {
435
461
  background: $color-sidenav-list-border;
436
462
  }
437
463
 
438
- %theme-side-navigation__link {
464
+ .p-side-navigation__link {
439
465
  &,
440
466
  &:visited {
441
467
  color: $color-sidenav-text-default;
@@ -462,14 +488,6 @@
462
488
  }
463
489
  }
464
490
 
465
- .p-side-navigation__list::after {
466
- @extend %theme-side-navigation__list;
467
- }
468
-
469
- .p-side-navigation__link {
470
- @extend %theme-side-navigation__link;
471
- }
472
-
473
491
  .p-side-navigation__item--title,
474
492
  .p-side-navigation__item--title .p-side-navigation__link {
475
493
  color: $color-sidenav-text-active;
@@ -1,8 +1,8 @@
1
1
  @import 'settings';
2
2
 
3
- // Default label styling
4
- @mixin vf-p-label {
5
- %vf-label {
3
+ // Default status label styling
4
+ @mixin vf-p-status-label {
5
+ %vf-status-label {
6
6
  @extend %x-small-text;
7
7
  @extend %u-no-margin--bottom--small;
8
8
 
@@ -15,38 +15,48 @@
15
15
  white-space: nowrap;
16
16
  }
17
17
 
18
+ .p-status-label,
18
19
  .p-label {
19
- @extend %vf-label;
20
+ @extend %vf-status-label;
20
21
 
21
22
  background-color: $color-mid-dark;
22
23
  color: $color-x-light;
23
24
  }
24
25
 
26
+ .p-status-label--positive,
25
27
  .p-label--positive {
26
- @extend %vf-label;
28
+ @extend %vf-status-label;
27
29
 
28
30
  background-color: $color-positive;
29
31
  color: $color-x-light;
30
32
  }
31
33
 
34
+ .p-status-label--caution,
32
35
  .p-label--caution {
33
- @extend %vf-label;
36
+ @extend %vf-status-label;
34
37
 
35
38
  background-color: $color-caution;
36
39
  color: $color-dark;
37
40
  }
38
41
 
42
+ .p-status-label--information,
39
43
  .p-label--information {
40
- @extend %vf-label;
44
+ @extend %vf-status-label;
41
45
 
42
46
  background-color: $color-information;
43
47
  color: $color-x-light;
44
48
  }
45
49
 
50
+ .p-status-label--negative,
46
51
  .p-label--negative {
47
- @extend %vf-label;
52
+ @extend %vf-status-label;
48
53
 
49
54
  background-color: $color-negative;
50
55
  color: $color-x-light;
51
56
  }
52
57
  }
58
+
59
+ // Deprecated mixin kept for compatibility
60
+ @mixin vf-p-label {
61
+ @include vf-p-status-label;
62
+ }
@@ -21,7 +21,6 @@
21
21
  @import 'patterns_headings';
22
22
  @import 'patterns_icons';
23
23
  @import 'patterns_image';
24
- @import 'patterns_label';
25
24
  @import 'patterns_links';
26
25
  @import 'patterns_list-tree';
27
26
  @import 'patterns_lists';
@@ -39,9 +38,10 @@
39
38
  @import 'patterns_separator';
40
39
  @import 'patterns_side-navigation';
41
40
  @import 'patterns_slider';
41
+ @import 'patterns_status-label';
42
42
  @import 'patterns_strip';
43
43
  @import 'patterns_switch';
44
- @import 'patterns_tab-buttons';
44
+ @import 'patterns_segmented-control';
45
45
  @import 'patterns_table-icons';
46
46
  @import 'patterns_table-expanding';
47
47
  @import 'patterns_table-of-contents';
@@ -102,7 +102,6 @@
102
102
  @include vf-p-form-password-toggle;
103
103
  @include vf-p-icons;
104
104
  @include vf-p-image;
105
- @include vf-p-label;
106
105
  @include vf-p-links;
107
106
  @include vf-p-list-tree;
108
107
  @include vf-p-lists;
@@ -117,12 +116,13 @@
117
116
  @include vf-p-pull-quotes;
118
117
  @include vf-p-search-and-filter;
119
118
  @include vf-p-search-box;
119
+ @include vf-p-segmented-control;
120
120
  @include vf-p-separator;
121
121
  @include vf-p-side-navigation;
122
122
  @include vf-p-slider;
123
+ @include vf-p-status-label;
123
124
  @include vf-p-strip;
124
125
  @include vf-p-switch;
125
- @include vf-p-tab-buttons;
126
126
  @include vf-p-table-icons;
127
127
  @include vf-p-table-expanding;
128
128
  @include vf-p-table-of-contents;