vanilla-framework 4.15.0 → 4.17.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.
Files changed (47) hide show
  1. package/package.json +17 -13
  2. package/scss/_base_button.scss +1 -1
  3. package/scss/_base_details.scss +1 -1
  4. package/scss/_base_forms.scss +8 -2
  5. package/scss/_base_hr.scss +2 -3
  6. package/scss/_base_icon-definitions.scss +629 -0
  7. package/scss/_base_links.scss +1 -1
  8. package/scss/_base_placeholders.scss +2 -0
  9. package/scss/_base_typography-definitions.scss +1 -1
  10. package/scss/_global_functions.scss +21 -8
  11. package/scss/_layouts_fluid-breakout.scss +2 -2
  12. package/scss/_patterns_accordion.scss +1 -1
  13. package/scss/_patterns_article-pagination.scss +2 -2
  14. package/scss/_patterns_buttons.scss +1 -1
  15. package/scss/_patterns_chip.scss +68 -68
  16. package/scss/_patterns_code-snippet.scss +1 -1
  17. package/scss/_patterns_contextual-menu.scss +1 -1
  18. package/scss/_patterns_cta.scss +7 -0
  19. package/scss/_patterns_equal-height-row.scss +87 -43
  20. package/scss/_patterns_icons.scss +340 -0
  21. package/scss/_patterns_image.scss +53 -16
  22. package/scss/_patterns_links.scss +6 -5
  23. package/scss/_patterns_list-tree.scss +49 -43
  24. package/scss/_patterns_lists.scss +58 -17
  25. package/scss/_patterns_matrix.scss +2 -2
  26. package/scss/_patterns_navigation.scss +4 -4
  27. package/scss/_patterns_pull-quotes.scss +1 -1
  28. package/scss/_patterns_rule.scss +6 -2
  29. package/scss/_patterns_search-and-filter.scss +11 -12
  30. package/scss/_patterns_separator.scss +1 -0
  31. package/scss/_patterns_side-navigation.scss +1 -1
  32. package/scss/_patterns_status-label.scss +5 -0
  33. package/scss/_patterns_strip.scss +3 -2
  34. package/scss/_patterns_switch.scss +2 -1
  35. package/scss/_patterns_table-mobile-card.scss +1 -1
  36. package/scss/_patterns_tooltips.scss +26 -8
  37. package/scss/_settings_breakpoints.scss +16 -0
  38. package/scss/_settings_colors.scss +20 -15
  39. package/scss/_settings_placeholders.scss +4 -3
  40. package/scss/_utilities_baseline-grid.scss +3 -2
  41. package/scss/_utilities_content-align.scss +9 -0
  42. package/scss/_utilities_floats.scss +6 -6
  43. package/scss/_utilities_font-metrics.scss +4 -3
  44. package/scss/_utilities_hide.scss +9 -9
  45. package/scss/_utilities_show.scss +3 -3
  46. package/templates/_macros/vf_hero.jinja +186 -0
  47. package/templates/_macros/vf_tiered-list.jinja +115 -0
@@ -8,7 +8,7 @@
8
8
  }
9
9
 
10
10
  %vf-link-base {
11
- @include vf-focus;
11
+ @include vf-focus-themed;
12
12
 
13
13
  color: $colors--theme--link-default;
14
14
  text-decoration: none;
@@ -98,8 +98,10 @@
98
98
  }
99
99
 
100
100
  %hr {
101
+ background: $colors--theme--border-default;
101
102
  border: 0;
102
103
  height: 1px;
104
+ margin-bottom: calc($spv--small - 1px);
103
105
  margin-top: 0;
104
106
  position: relative;
105
107
  width: 100%;
@@ -1,7 +1,7 @@
1
1
  @mixin vf-b-typography-definitions {
2
2
  %vf-is-accent {
3
3
  &.is-accent {
4
- color: $color-accent;
4
+ color: $colors--theme--accent;
5
5
  }
6
6
  }
7
7
 
@@ -1,4 +1,5 @@
1
1
  @use 'sass:math';
2
+ @use 'sass:color';
2
3
 
3
4
  // Functions used across multiple patterns or utils
4
5
 
@@ -33,7 +34,7 @@
33
34
 
34
35
  // Test value of bg $color and return light or dark text color accordingly
35
36
  @function vf-contrast-text-color($color) {
36
- @if (lightness($color) > 55) {
37
+ @if (color.channel($color, 'lightness', $space: hsl) > 55) {
37
38
  @return $colors--light-theme--text-default; // Lighter background, return dark color
38
39
  } @else {
39
40
  @return $colors--dark-theme--text-default; // Darker background, return light color
@@ -43,7 +44,7 @@
43
44
  // Returns the font color to be presented on the passed background-color
44
45
  // variable.
45
46
  @function vf-determine-text-color($background-color) {
46
- @if (lightness($background-color) > 50) {
47
+ @if (color.channel($background-color, 'lightness', $space: hsl) > 50) {
47
48
  @return $colors--light-theme--text-default;
48
49
  } @else {
49
50
  @return $colors--dark-theme--text-default;
@@ -53,23 +54,29 @@
53
54
  // Includes the theme variables based on the background color passed as an argument.
54
55
  // This is currently only used in the deprecated p-strip--accent.
55
56
  @mixin vf-determine-theme-from-background($background-color) {
56
- @if (lightness($background-color) > 50) {
57
+ @if (color.channel($background-color, 'lightness', $space: hsl) > 50) {
57
58
  @include vf-theme-light;
58
59
  } @else {
59
60
  @include vf-theme-dark;
60
61
  }
61
62
  }
62
63
 
63
- // Adds visual focus to elements on :focus-visible,
64
- // or :focus if the browser doesn't support the former
65
- @mixin vf-focus($color: $colors--theme--focus, $width: $bar-thickness, $has-validation: false) {
64
+ // Adds visual focus to elements on :focus-visible or :focus if the browser
65
+ // doesn't support the former
66
+ @mixin vf-focus-themed($light-color: $colors--light-theme--focus, $dark-color: $colors--dark-theme--focus, $width: $bar-thickness, $has-validation: false) {
67
+ --vf-focus-outline-color: #{$light-color};
68
+
69
+ .is-dark & {
70
+ --vf-focus-outline-color: #{$dark-color};
71
+ }
72
+
66
73
  &:focus {
67
- outline: $width solid $color;
74
+ outline: $width solid var(--vf-focus-outline-color);
68
75
  outline-offset: -#{$width};
69
76
  }
70
77
 
71
78
  &:focus-visible {
72
- outline: $width solid $color;
79
+ outline: $width solid var(--vf-focus-outline-color);
73
80
  outline-offset: -#{$width};
74
81
  }
75
82
 
@@ -93,6 +100,12 @@
93
100
  }
94
101
  }
95
102
 
103
+ // This mixin is deprecated and will be removed in a future version of Vanilla.
104
+ // Please use vf-focus-themed instead.
105
+ @mixin vf-focus($color: $colors--theme--focus, $width: $bar-thickness, $has-validation: false) {
106
+ @include vf-focus-themed($light-color: $color, $width: $width, $has-validation: $has-validation);
107
+ }
108
+
96
109
  // Raises a number to a power (https://css-tricks.com/snippets/sass/power-function/)
97
110
  @function pow($number, $exponent) {
98
111
  $value: 1;
@@ -149,7 +149,7 @@
149
149
  grid-column: 2 / -1;
150
150
  grid-template-columns: repeat(2, minmax(0, 1fr));
151
151
 
152
- @media (max-width: $threshold-4-6-col - 1) {
152
+ @media (width < $threshold-4-6-col) {
153
153
  grid-template-columns: repeat(1, minmax(0, 1fr));
154
154
  width: $l-fluid-breakout-main-child-width;
155
155
  }
@@ -163,7 +163,7 @@
163
163
  &:nth-child(2) {
164
164
  justify-content: flex-end;
165
165
 
166
- @media (max-width: $threshold-4-6-col - 1) {
166
+ @media (width < $threshold-4-6-col) {
167
167
  justify-content: flex-start;
168
168
  }
169
169
  }
@@ -17,7 +17,7 @@
17
17
 
18
18
  .p-accordion__tab {
19
19
  @extend %single-border-text-vpadding--scaling;
20
- @include vf-focus;
20
+ @include vf-focus-themed;
21
21
 
22
22
  background-color: inherit;
23
23
  border: 0;
@@ -55,7 +55,7 @@
55
55
  padding-left: $sp-xx-large;
56
56
  text-align: left;
57
57
 
58
- @media (max-width: $breakpoint-x-small - 1) {
58
+ @media (width < $breakpoint-x-small) {
59
59
  margin-right: 0;
60
60
  width: auto;
61
61
 
@@ -84,7 +84,7 @@
84
84
  padding-right: $sp-xx-large;
85
85
  text-align: right;
86
86
 
87
- @media (max-width: $breakpoint-x-small - 1) {
87
+ @media (width < $breakpoint-x-small) {
88
88
  width: 100%;
89
89
  }
90
90
 
@@ -80,7 +80,7 @@
80
80
  $button-disabled-border-color: $colors--theme--button-positive-default,
81
81
  $button-text-color: $colors--theme--button-positive-text
82
82
  );
83
- @include vf-focus($colors--theme--positive-focus);
83
+ @include vf-focus-themed($light-color: $color-focus-positive);
84
84
  }
85
85
  }
86
86
 
@@ -1,22 +1,21 @@
1
1
  @use 'sass:math';
2
2
  @import 'settings';
3
- $chip-border-thickness: 1px;
4
3
 
5
4
  @mixin vf-p-chip {
6
5
  %vf-chip {
7
6
  @extend %small-text;
8
7
  @include vf-transition(#{background-color, border-color}, snap, out);
9
- @include vf-focus;
8
+ @include vf-focus-themed;
10
9
 
11
10
  align-items: baseline;
12
11
  border-radius: 1rem;
13
12
  display: inline-flex;
14
13
  margin: 0 $sph--small $input-margin-bottom 0;
15
14
  max-width: 100%;
16
- padding: calc($spv--x-small - $chip-border-thickness) $sph--small; // account for border thickness using calc
15
+ padding: calc($spv--x-small - $input-border-thickness) $sph--small; // account for border thickness using calc
17
16
  position: relative;
18
17
  user-select: none;
19
- vertical-align: calc($chip-border-thickness - map-get($nudges, p));
18
+ vertical-align: calc($input-border-thickness - map-get($nudges, p));
20
19
  white-space: nowrap;
21
20
 
22
21
  .p-chip__lead,
@@ -72,29 +71,46 @@ $chip-border-thickness: 1px;
72
71
  @include vf-chips-information;
73
72
  }
74
73
 
74
+ @mixin vf-chip-interactive(
75
+ $color-background-hover: $colors--theme--background-neutral-hover,
76
+ $color-border-hover: $colors--theme--border-neutral,
77
+ $color-background-active: $colors--theme--background-neutral-active,
78
+ $color-border-active: $colors--theme--border-neutral
79
+ ) {
80
+ &:hover {
81
+ background-color: $color-background-hover;
82
+ border-color: $color-border-hover;
83
+ text-decoration: none;
84
+ }
85
+
86
+ &[aria-pressed='true'],
87
+ &.is-selected,
88
+ &:active {
89
+ background-color: $color-background-active;
90
+ border-color: $color-border-active;
91
+ }
92
+ }
93
+
75
94
  // Default notification styling
76
95
  @mixin vf-chips-default {
77
96
  .p-chip {
78
97
  @extend %vf-chip;
79
98
 
80
99
  background-color: $colors--theme--background-neutral-default;
81
- border: $chip-border-thickness solid $colors--theme--border-neutral;
100
+ border: $input-border-thickness solid $colors--theme--border-neutral;
82
101
  border-color: $colors--theme--border-neutral;
83
102
  }
84
103
 
104
+ // Status-color chips all use the button pattern mixin to set their colors, so they already have most button styling.
105
+ // We need to add the default button styling to the link default chip as well.
85
106
  // stylelint-disable selector-max-type -- allow button selector for interactive chips
86
- button.p-chip {
87
- &:hover {
88
- background-color: $colors--theme--background-neutral-hover;
89
- border-color: $colors--theme--border-neutral;
90
- }
107
+ a.p-chip {
108
+ @include vf-button-pattern;
109
+ @include vf-chip-interactive;
110
+ }
91
111
 
92
- &[aria-pressed='true'],
93
- &.is-selected,
94
- &:active {
95
- background-color: $colors--theme--background-neutral-active;
96
- border-color: $colors--theme--border-neutral;
97
- }
112
+ button.p-chip {
113
+ @include vf-chip-interactive;
98
114
  }
99
115
  // stylelint-enable selector-max-type
100
116
 
@@ -115,23 +131,19 @@ $chip-border-thickness: 1px;
115
131
  @extend %vf-chip;
116
132
 
117
133
  background-color: $colors--theme--background-positive-default;
118
- border: $chip-border-thickness solid $colors--theme--border-positive;
134
+ border: $input-border-thickness solid $colors--theme--border-positive;
119
135
  border-color: $colors--theme--border-positive;
120
136
  }
121
137
 
122
138
  // stylelint-disable selector-max-type -- allow button selector for interactive chips
123
- button.p-chip--positive {
124
- &:hover {
125
- background-color: $colors--theme--background-positive-hover;
126
- border-color: $colors--theme--border-positive;
127
- }
128
-
129
- &[aria-pressed='true'],
130
- &.is-selected,
131
- &:active {
132
- background-color: $colors--theme--background-positive-active;
133
- border-color: $colors--theme--border-positive;
134
- }
139
+ button.p-chip--positive,
140
+ a.p-chip--positive {
141
+ @include vf-chip-interactive(
142
+ $color-background-hover: $colors--theme--background-positive-hover,
143
+ $color-border-hover: $colors--theme--border-positive,
144
+ $color-background-active: $colors--theme--background-positive-active,
145
+ $color-border-active: $colors--theme--border-positive
146
+ );
135
147
  }
136
148
  // stylelint-enable selector-max-type
137
149
 
@@ -152,23 +164,19 @@ $chip-border-thickness: 1px;
152
164
  @extend %vf-chip;
153
165
 
154
166
  background-color: $colors--theme--background-caution-default;
155
- border: $chip-border-thickness solid $colors--theme--border-caution;
167
+ border: $input-border-thickness solid $colors--theme--border-caution;
156
168
  border-color: $colors--theme--border-caution;
157
169
  }
158
170
 
159
171
  // stylelint-disable selector-max-type -- allow button selector for interactive chips
160
- button.p-chip--caution {
161
- &:hover {
162
- background-color: $colors--theme--background-caution-hover;
163
- border-color: $colors--theme--border-caution;
164
- }
165
-
166
- &[aria-pressed='true'],
167
- &.is-selected,
168
- &:active {
169
- background-color: $colors--theme--background-caution-active;
170
- border-color: $colors--theme--border-caution;
171
- }
172
+ button.p-chip--caution,
173
+ a.p-chip--caution {
174
+ @include vf-chip-interactive(
175
+ $color-background-hover: $colors--theme--background-caution-hover,
176
+ $color-border-hover: $colors--theme--border-caution,
177
+ $color-background-active: $colors--theme--background-caution-active,
178
+ $color-border-active: $colors--theme--border-caution
179
+ );
172
180
  }
173
181
  // stylelint-enable selector-max-type
174
182
 
@@ -189,23 +197,19 @@ $chip-border-thickness: 1px;
189
197
  @extend %vf-chip;
190
198
 
191
199
  background-color: $colors--theme--background-negative-default;
192
- border: $chip-border-thickness solid $colors--theme--border-negative;
200
+ border: $input-border-thickness solid $colors--theme--border-negative;
193
201
  border-color: $colors--theme--border-negative;
194
202
  }
195
203
 
196
204
  // stylelint-disable selector-max-type -- allow button selector for interactive chips
197
- button.p-chip--negative {
198
- &:hover {
199
- background-color: $colors--theme--background-negative-hover;
200
- border-color: $colors--theme--border-negative;
201
- }
202
-
203
- &[aria-pressed='true'],
204
- &.is-selected,
205
- &:active {
206
- background-color: $colors--theme--background-negative-active;
207
- border-color: $colors--theme--border-negative;
208
- }
205
+ button.p-chip--negative,
206
+ a.p-chip--negative {
207
+ @include vf-chip-interactive(
208
+ $color-background-hover: $colors--theme--background-negative-hover,
209
+ $color-border-hover: $colors--theme--border-negative,
210
+ $color-background-active: $colors--theme--background-negative-active,
211
+ $color-border-active: $colors--theme--border-negative
212
+ );
209
213
  }
210
214
  // stylelint-enable selector-max-type
211
215
 
@@ -226,23 +230,19 @@ $chip-border-thickness: 1px;
226
230
  @extend %vf-chip;
227
231
 
228
232
  background-color: $colors--theme--background-information-default;
229
- border: $chip-border-thickness solid $colors--theme--border-information;
233
+ border: $input-border-thickness solid $colors--theme--border-information;
230
234
  border-color: $colors--theme--border-information;
231
235
  }
232
236
 
233
237
  // stylelint-disable selector-max-type -- allow button selector for interactive chips
234
- button.p-chip--information {
235
- &:hover {
236
- background-color: $colors--theme--background-information-hover;
237
- border-color: $colors--theme--border-information;
238
- }
239
-
240
- &[aria-pressed='true'],
241
- &.is-selected,
242
- &:active {
243
- background-color: $colors--theme--background-information-active;
244
- border-color: $colors--theme--border-information;
245
- }
238
+ button.p-chip--information,
239
+ a.p-chip--information {
240
+ @include vf-chip-interactive(
241
+ $color-background-hover: $colors--theme--background-information-hover,
242
+ $color-border-hover: $colors--theme--border-information,
243
+ $color-background-active: $colors--theme--background-information-active,
244
+ $color-border-active: $colors--theme--border-information
245
+ );
246
246
  }
247
247
  // stylelint-enable selector-max-type
248
248
 
@@ -9,7 +9,7 @@
9
9
 
10
10
  Code block:
11
11
  .p-code-snippet__block:
12
- Code block without any additonal styling elements.
12
+ Code block without any additional styling elements.
13
13
  "&.is-wrapped":
14
14
  Code block with wrapped content in lines.
15
15
  .p-code-snippet__block--icon:
@@ -66,7 +66,7 @@
66
66
  }
67
67
 
68
68
  .p-contextual-menu__link {
69
- @include vf-focus;
69
+ @include vf-focus-themed;
70
70
 
71
71
  border: 0;
72
72
  clear: both;
@@ -4,6 +4,8 @@
4
4
  CTA Block:
5
5
  .p-cta-block:
6
6
  Main element of the CTA block.
7
+ "&.is-borderless":
8
+ Borderless variant, to be used to hide top border and padding.
7
9
  */
8
10
 
9
11
  @import 'settings';
@@ -16,5 +18,10 @@
16
18
  flex-wrap: wrap;
17
19
  padding-bottom: $spv--x-large;
18
20
  padding-top: $spv--small;
21
+
22
+ &.is-borderless {
23
+ border: none;
24
+ padding-top: 0;
25
+ }
19
26
  }
20
27
  }
@@ -1,12 +1,36 @@
1
+ /*
2
+ @classreference
3
+ equal-height-row:
4
+ Equal height row:
5
+ .p-equal-height-row:
6
+ Main element of the equal height row component.
7
+ "&.has-divider-1":
8
+ Cross-column divider shown between the first and second grid rows.
9
+ "&.has-divider-2":
10
+ Cross-column divider shown between the second and third grid rows.
11
+ "&.has-divider-3":
12
+ Cross-column divider shown between the third and fourth grid rows.
13
+ .p-equal-height-row--wrap:
14
+ Wraps contents such that two items appear per row on medium screen sizes.
15
+ Column:
16
+ .p-equal-height-row__col:
17
+ Column element within an equal height row.
18
+ Item:
19
+ .p-equal-height-row__item:
20
+ Item element within an equal height row column.
21
+ */
22
+
1
23
  @import 'settings';
2
24
 
3
25
  @mixin vf-p-equal-height-row {
4
- .p-equal-height-row {
26
+ .p-equal-height-row,
27
+ .p-equal-height-row--wrap {
5
28
  @extend %vf-row;
29
+
6
30
  position: relative;
7
31
 
8
32
  .p-equal-height-row__col {
9
- // smaller screens each column will have border top by default
33
+ // At smaller sizes, each column will have top border by default
10
34
  border-top-color: $colors--theme--border-low-contrast;
11
35
  border-top-style: solid;
12
36
  border-top-width: 1px;
@@ -15,21 +39,24 @@
15
39
  grid-row: span 4;
16
40
  grid-template-rows: subgrid;
17
41
  margin-bottom: $spv--small;
18
- margin-top: -1px;
19
42
  position: relative;
20
43
 
21
44
  @media screen and ($breakpoint-small <= width < $breakpoint-large) {
22
45
  grid-column: span $grid-columns-medium;
23
46
  grid-template-columns: subgrid;
24
47
 
25
- // for medium screen, each column item will take half of the available cols from the parent grid
48
+ // At medium size, each column item will take half of the available
49
+ // cols from the parent grid
26
50
  .p-equal-height-row__item {
27
51
  grid-column: span calc($grid-columns-medium / 2);
28
52
  }
29
53
 
30
- // for medium screen, position the first column item on the left of the grid
54
+ // At medium size, position the first column item on the left of the
55
+ // grid
31
56
  .p-equal-height-row__item:first-child {
32
- grid-row: span 100; // this needs to be sufficiently large so remaining column items won't get stretched
57
+ // This needs to be sufficiently large so remaining column items won't
58
+ // get stretched
59
+ grid-row: span 100;
33
60
  }
34
61
  }
35
62
 
@@ -42,63 +69,80 @@
42
69
 
43
70
  // DIVIDERS
44
71
 
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)
72
+ // For each row or column grid we only have access to two pseudo elements:
73
+ // If 1st-divider (::before) is present, assume 2nd-divider (::after) isn't, then 3rd-divider must be (::after)
74
+ // If 2nd-divider (::after) is present, assume 1st-divider (::before) isn't, then 3rd-divider must be (::before)
48
75
  &.has-divider-1::before,
49
76
  &.has-divider-2::after,
50
77
  &.has-divider-3:not(.has-divider-1)::before,
51
78
  &.has-divider-3:not(.has-divider-2)::after {
52
- // row level dividers are not visible on smaller screen sizes
53
79
  @extend %vf-pseudo-border;
54
- background-color: $colors--theme--border-low-contrast; // override border color to be low contrast
80
+
81
+ // Override border color to be low contrast
82
+ background-color: $colors--theme--border-low-contrast;
83
+ // Row-level dividers are not visible on smaller screen sizes
55
84
  display: none;
56
- }
85
+ grid-column-end: span 12;
86
+ grid-column-start: 1;
87
+ margin: auto;
57
88
 
58
- @media screen and (width >= $breakpoint-large) {
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 {
89
+ @media screen and (width >= $breakpoint-large) {
63
90
  display: block;
64
- grid-column-end: span 12;
65
- grid-column-start: 1;
66
- margin: auto;
67
91
  }
92
+ }
68
93
 
69
- &.has-divider-1::before {
70
- grid-row: 2;
71
- }
94
+ &.has-divider-1::before {
95
+ grid-row: 2;
96
+ }
72
97
 
73
- &.has-divider-2::after {
74
- grid-row: 3;
75
- }
98
+ &.has-divider-2::after {
99
+ grid-row: 3;
100
+ }
76
101
 
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 {
83
- grid-row: 4;
84
- }
102
+ // When 3rd-divider is present and 1st-divider is not present
103
+ &.has-divider-3:not(.has-divider-1)::before,
104
+ // When 3rd-divider is present and 2nd-divider is not present
105
+ &.has-divider-3:not(.has-divider-2)::after,
106
+ // When only 3rd-divider is present
107
+ &.has-divider-3:not(.has-divider-1):not(.has-divider-2)::before {
108
+ grid-row: 4;
109
+ }
85
110
 
86
- &.has-divider-3:not(.has-divider-1):not(.has-divider-2)::after {
87
- display: none;
88
- }
111
+ &.has-divider-3:not(.has-divider-1):not(.has-divider-2)::after {
112
+ display: none;
89
113
  }
90
114
  }
91
115
 
92
- // support for 25-75 split on large screen size for this pattern
93
- .row--25-75-on-large > .col,
94
- .row > .col-9 {
95
- & .p-equal-height-row {
96
- grid-template-columns: repeat($grid-columns-small, minmax(0, 1fr));
116
+ // WRAP VARIANT
97
117
 
118
+ // This variant displays multiple columns side-by-side and wraps them at
119
+ // medium size; we have to unset some grid properties from the default
120
+ // variant to enable this functionality
121
+ .p-equal-height-row--wrap {
122
+ .p-equal-height-row__col {
98
123
  @media screen and ($breakpoint-small <= width < $breakpoint-large) {
99
- grid-template-columns: repeat($grid-columns-medium, minmax(0, 1fr));
124
+ // Fit 2 columns onto each row at medium size
125
+ grid-column: span calc($grid-columns-medium / 2);
126
+ grid-template-columns: none;
127
+
128
+ .p-equal-height-row__item {
129
+ grid-column: auto;
130
+ }
131
+
132
+ .p-equal-height-row__item:first-child {
133
+ grid-row: auto;
134
+ }
100
135
  }
136
+ }
137
+ }
101
138
 
139
+ // ADVANCED GRID SUPPORT
140
+
141
+ // Support for 25-75 split on large screen size
142
+ .row--25-75-on-large > .col,
143
+ .row > .col-9 {
144
+ & .p-equal-height-row,
145
+ & .p-equal-height-row--wrap {
102
146
  @media screen and (width >= $breakpoint-large) {
103
147
  grid-template-columns: repeat(9, minmax(0, 1fr));
104
148
  }