maverick-wave 5.24.0 → 5.25.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/.claude/skills/mw-maverick-wave/SKILL.md +32 -5
- package/.claude/skills/mw-maverick-wave/references/components.md +4 -0
- package/.claude/skills/mw-maverick-wave/references/javascript.md +44 -8
- package/.claude/skills/mw-maverick-wave/references/layout.md +23 -1
- package/.claude/skills/mw-maverick-wave/references/theming.md +21 -1
- package/CHANGELOG.md +14 -0
- package/CLAUDE.md +4 -0
- package/README.md +4 -2
- package/index.html +13 -0
- package/maverick-wave.min.css +4 -4
- package/maverick-wave.min.js +1 -1
- package/package.json +2 -2
- package/src/js/main.js +149 -57
- package/src/partials/get-started-container.html +5 -10
- package/src/partials/input-group-container.html +1 -3
- package/src/partials/tags-container.html +0 -6
- package/src/scss/components/_blog-post.scss +15 -10
- package/src/scss/components/_button-bar.scss +10 -6
- package/src/scss/components/_code.scss +23 -34
- package/src/scss/components/_info.scss +8 -1
- package/src/scss/components/_kanban.scss +6 -6
- package/src/scss/components/_meta-info.scss +7 -6
- package/src/scss/components/_tables.scss +6 -4
- package/src/scss/components/_tiles.scss +20 -30
- package/src/scss/layout/_grid.scss +28 -0
- package/src/scss/layout/_header.scss +16 -9
- package/src/scss/layout/_home.scss +21 -2
- package/src/scss/layout/_main.scss +7 -7
- package/src/scss/layout/_page-header.scss +4 -4
- package/src/scss/layout/_section.scss +9 -9
- package/src/scss/main-lean.scss +16 -0
- package/src/scss/utilities/_index.scss +1 -0
- package/src/scss/utilities/_print.scss +107 -0
|
@@ -3,7 +3,8 @@
|
|
|
3
3
|
@layer mw.components {
|
|
4
4
|
.mw-button-bar {
|
|
5
5
|
display: flex;
|
|
6
|
-
|
|
6
|
+
flex-direction: column;
|
|
7
|
+
gap: spacing('2');
|
|
7
8
|
align-items: center;
|
|
8
9
|
justify-content: center;
|
|
9
10
|
flex-wrap: wrap;
|
|
@@ -11,17 +12,20 @@
|
|
|
11
12
|
border-radius: radius('md');
|
|
12
13
|
padding: spacing('2');
|
|
13
14
|
|
|
15
|
+
.mw-btn {
|
|
16
|
+
width: 100%;
|
|
17
|
+
}
|
|
18
|
+
|
|
14
19
|
&:hover {
|
|
15
20
|
border-color: var(--mw-border-accent);
|
|
16
21
|
}
|
|
17
22
|
|
|
18
|
-
@include media-
|
|
19
|
-
flex-direction:
|
|
20
|
-
gap: spacing('
|
|
23
|
+
@include media-up('sm') {
|
|
24
|
+
flex-direction: row;
|
|
25
|
+
gap: spacing('3');
|
|
21
26
|
|
|
22
27
|
.mw-btn {
|
|
23
|
-
width:
|
|
24
|
-
min-width: 0;
|
|
28
|
+
width: auto;
|
|
25
29
|
}
|
|
26
30
|
}
|
|
27
31
|
}
|
|
@@ -42,15 +42,15 @@
|
|
|
42
42
|
white-space: pre-wrap;
|
|
43
43
|
display: block;
|
|
44
44
|
line-height: 1.5;
|
|
45
|
+
font-size: font-size('3xs');
|
|
45
46
|
|
|
46
|
-
@include media-
|
|
47
|
+
@include media-up('xs') {
|
|
47
48
|
font-size: font-size('2xs');
|
|
48
|
-
white-space: pre-wrap;
|
|
49
|
-
word-break: break-word;
|
|
50
49
|
}
|
|
51
50
|
|
|
52
|
-
|
|
53
|
-
|
|
51
|
+
// Back to the shared `code, pre` size
|
|
52
|
+
@include media-up('sm') {
|
|
53
|
+
font-size: font-size('xs');
|
|
54
54
|
}
|
|
55
55
|
}
|
|
56
56
|
}
|
|
@@ -80,10 +80,13 @@
|
|
|
80
80
|
&-filename {
|
|
81
81
|
font-weight: font-weight('medium');
|
|
82
82
|
margin-right: spacing('2');
|
|
83
|
+
font-size: font-size('2xs');
|
|
84
|
+
// The header wraps at this width, so the language chip needs its own line
|
|
85
|
+
margin-bottom: spacing('1');
|
|
83
86
|
|
|
84
|
-
@include media-
|
|
85
|
-
font-size: font-size('
|
|
86
|
-
margin-bottom: spacing('
|
|
87
|
+
@include media-up('sm') {
|
|
88
|
+
font-size: font-size('xs');
|
|
89
|
+
margin-bottom: spacing('0');
|
|
87
90
|
}
|
|
88
91
|
}
|
|
89
92
|
|
|
@@ -102,19 +105,16 @@
|
|
|
102
105
|
border: none;
|
|
103
106
|
max-width: 100%;
|
|
104
107
|
overflow-x: auto;
|
|
108
|
+
font-size: font-size('3xs');
|
|
109
|
+
padding: spacing('1');
|
|
105
110
|
|
|
106
|
-
@include media-
|
|
111
|
+
@include media-up('xs') {
|
|
107
112
|
font-size: font-size('2xs');
|
|
108
|
-
padding: spacing('1');
|
|
109
|
-
|
|
110
|
-
code {
|
|
111
|
-
white-space: pre-wrap;
|
|
112
|
-
word-break: break-word;
|
|
113
|
-
}
|
|
114
113
|
}
|
|
115
114
|
|
|
116
|
-
@include media-
|
|
117
|
-
font-size: font-size('
|
|
115
|
+
@include media-up('sm') {
|
|
116
|
+
font-size: font-size('xs');
|
|
117
|
+
padding: spacing('4');
|
|
118
118
|
}
|
|
119
119
|
}
|
|
120
120
|
}
|
|
@@ -213,18 +213,6 @@
|
|
|
213
213
|
overflow-x: auto;
|
|
214
214
|
position: relative;
|
|
215
215
|
|
|
216
|
-
// Add horizontal scrolling indicator for small screens
|
|
217
|
-
@include media-down('sm') {
|
|
218
|
-
background-position:
|
|
219
|
-
left center,
|
|
220
|
-
right center;
|
|
221
|
-
background-repeat: no-repeat;
|
|
222
|
-
background-size:
|
|
223
|
-
20px 100%,
|
|
224
|
-
20px 100%;
|
|
225
|
-
background-attachment: local, local;
|
|
226
|
-
}
|
|
227
|
-
|
|
228
216
|
& > * {
|
|
229
217
|
max-width: 100%;
|
|
230
218
|
}
|
|
@@ -234,14 +222,15 @@
|
|
|
234
222
|
width: 100%;
|
|
235
223
|
|
|
236
224
|
pre {
|
|
237
|
-
white-space: pre;
|
|
225
|
+
white-space: pre-wrap;
|
|
226
|
+
word-break: break-word;
|
|
238
227
|
width: 100%;
|
|
239
228
|
overflow-x: auto;
|
|
240
229
|
|
|
241
|
-
//
|
|
242
|
-
@include media-
|
|
243
|
-
white-space: pre
|
|
244
|
-
word-break:
|
|
230
|
+
// From here the box can scroll a long line instead of splitting it
|
|
231
|
+
@include media-up('xs') {
|
|
232
|
+
white-space: pre;
|
|
233
|
+
word-break: normal;
|
|
245
234
|
}
|
|
246
235
|
}
|
|
247
236
|
|
|
@@ -63,7 +63,9 @@
|
|
|
63
63
|
align-items: flex-start;
|
|
64
64
|
width: 100%;
|
|
65
65
|
max-width: 68ch;
|
|
66
|
-
|
|
66
|
+
// Left, like everything else that carries running text. It used to centre
|
|
67
|
+
// itself, which only ever matched a page whose headings were centred too.
|
|
68
|
+
margin-inline: 0;
|
|
67
69
|
padding: spacing('6') spacing('7');
|
|
68
70
|
font-weight: font-weight('normal');
|
|
69
71
|
line-height: 1.7;
|
|
@@ -78,6 +80,11 @@
|
|
|
78
80
|
transform: none;
|
|
79
81
|
}
|
|
80
82
|
|
|
83
|
+
// For the page that does centre its blocks
|
|
84
|
+
&-center {
|
|
85
|
+
margin-inline: auto;
|
|
86
|
+
}
|
|
87
|
+
|
|
81
88
|
strong {
|
|
82
89
|
margin-bottom: spacing('2');
|
|
83
90
|
}
|
|
@@ -67,15 +67,15 @@
|
|
|
67
67
|
auto-fit,
|
|
68
68
|
minmax(min(#{$_mw-kanban-lane-min}, 100%), 1fr)
|
|
69
69
|
);
|
|
70
|
-
|
|
71
|
-
|
|
70
|
+
// Frame only - how tight the board sits on a phone is a viewport call
|
|
71
|
+
gap: spacing('3');
|
|
72
|
+
padding: spacing('3');
|
|
72
73
|
background: var(--mw-kanban-background);
|
|
73
74
|
border-radius: radius('md');
|
|
74
75
|
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
padding: spacing('3');
|
|
76
|
+
@include media-up('sm') {
|
|
77
|
+
gap: spacing('4');
|
|
78
|
+
padding: spacing('4');
|
|
79
79
|
}
|
|
80
80
|
}
|
|
81
81
|
|
|
@@ -9,13 +9,14 @@
|
|
|
9
9
|
display: flex;
|
|
10
10
|
flex-wrap: wrap;
|
|
11
11
|
align-items: center;
|
|
12
|
-
justify-content: flex-
|
|
13
|
-
|
|
12
|
+
justify-content: flex-start;
|
|
13
|
+
column-gap: spacing('6');
|
|
14
|
+
row-gap: spacing('2');
|
|
14
15
|
|
|
15
|
-
@include media-
|
|
16
|
-
justify-content: flex-
|
|
17
|
-
column-gap:
|
|
18
|
-
row-gap: spacing('
|
|
16
|
+
@include media-up('sm') {
|
|
17
|
+
justify-content: flex-end;
|
|
18
|
+
column-gap: normal;
|
|
19
|
+
row-gap: spacing('1');
|
|
19
20
|
}
|
|
20
21
|
}
|
|
21
22
|
|
|
@@ -10,7 +10,8 @@
|
|
|
10
10
|
|
|
11
11
|
th,
|
|
12
12
|
td {
|
|
13
|
-
padding: spacing('
|
|
13
|
+
padding: spacing('2') spacing('3');
|
|
14
|
+
font-size: font-size('xs');
|
|
14
15
|
text-align: left;
|
|
15
16
|
border: 1px solid var(--mw-border);
|
|
16
17
|
color: var(--mw-text-muted-color);
|
|
@@ -40,11 +41,12 @@
|
|
|
40
41
|
}
|
|
41
42
|
}
|
|
42
43
|
|
|
43
|
-
@include media-
|
|
44
|
+
@include media-up('sm') {
|
|
44
45
|
th,
|
|
45
46
|
td {
|
|
46
|
-
padding: spacing('
|
|
47
|
-
|
|
47
|
+
padding: spacing('3') spacing('4');
|
|
48
|
+
// Back to whatever the table is set in - the base size is the phone step
|
|
49
|
+
font-size: inherit;
|
|
48
50
|
}
|
|
49
51
|
}
|
|
50
52
|
}
|
|
@@ -20,9 +20,12 @@
|
|
|
20
20
|
grid-template-columns: repeat(3, 1fr);
|
|
21
21
|
}
|
|
22
22
|
|
|
23
|
+
// The page gutter is the container's job, a second inset only narrows the tile
|
|
23
24
|
&-4col {
|
|
24
|
-
|
|
25
|
-
|
|
25
|
+
@include media-up('sm') {
|
|
26
|
+
width: 85%;
|
|
27
|
+
grid-template-columns: repeat(2, 1fr);
|
|
28
|
+
}
|
|
26
29
|
|
|
27
30
|
@include media-up('md') {
|
|
28
31
|
grid-template-columns: repeat(3, 1fr);
|
|
@@ -31,28 +34,12 @@
|
|
|
31
34
|
@include media-up('lg') {
|
|
32
35
|
grid-template-columns: repeat(4, 1fr);
|
|
33
36
|
}
|
|
34
|
-
|
|
35
|
-
@include media-down('sm') {
|
|
36
|
-
grid-template-columns: 1fr;
|
|
37
|
-
// Full width from here on - the page gutter is the container's job,
|
|
38
|
-
// a second inset only narrows the tile
|
|
39
|
-
width: 100%;
|
|
40
|
-
padding: spacing('0');
|
|
41
|
-
gap: spacing('4');
|
|
42
|
-
}
|
|
43
37
|
}
|
|
44
38
|
|
|
45
39
|
&-2col {
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
@include media-down('sm') {
|
|
50
|
-
grid-template-columns: 1fr;
|
|
51
|
-
// Full width from here on - the page gutter is the container's job,
|
|
52
|
-
// a second inset only narrows the tile
|
|
53
|
-
width: 100%;
|
|
54
|
-
padding: spacing('0');
|
|
55
|
-
gap: spacing('4');
|
|
40
|
+
@include media-up('sm') {
|
|
41
|
+
width: 75%;
|
|
42
|
+
grid-template-columns: repeat(2, 1fr);
|
|
56
43
|
}
|
|
57
44
|
}
|
|
58
45
|
}
|
|
@@ -75,7 +62,7 @@
|
|
|
75
62
|
container: mw-tile / inline-size;
|
|
76
63
|
background: var(--mw-card-background);
|
|
77
64
|
@include surface;
|
|
78
|
-
padding: spacing('
|
|
65
|
+
padding: spacing('4');
|
|
79
66
|
box-shadow: var(--mw-elevation-2);
|
|
80
67
|
transition: var(--mw-transition);
|
|
81
68
|
border: 1px solid var(--mw-border);
|
|
@@ -84,6 +71,11 @@
|
|
|
84
71
|
flex-direction: column;
|
|
85
72
|
cursor: pointer;
|
|
86
73
|
|
|
74
|
+
// Ahead of the size modifiers below, which take over from 'sm'
|
|
75
|
+
@include media-up('sm') {
|
|
76
|
+
padding: spacing('5');
|
|
77
|
+
}
|
|
78
|
+
|
|
87
79
|
// Same hover as a card, arc included - a tile is the larger clickable
|
|
88
80
|
// relative of one, and a pair that looks alike has to react alike.
|
|
89
81
|
&::after {
|
|
@@ -169,7 +161,9 @@
|
|
|
169
161
|
}
|
|
170
162
|
|
|
171
163
|
&-sm {
|
|
172
|
-
|
|
164
|
+
@include media-up('sm') {
|
|
165
|
+
padding: spacing('4');
|
|
166
|
+
}
|
|
173
167
|
|
|
174
168
|
.mw-tile-img {
|
|
175
169
|
width: 80px;
|
|
@@ -197,7 +191,9 @@
|
|
|
197
191
|
}
|
|
198
192
|
|
|
199
193
|
&-lg {
|
|
200
|
-
|
|
194
|
+
@include media-up('sm') {
|
|
195
|
+
padding: spacing('6');
|
|
196
|
+
}
|
|
201
197
|
|
|
202
198
|
.mw-tile-img {
|
|
203
199
|
width: 120px;
|
|
@@ -249,10 +245,4 @@
|
|
|
249
245
|
margin: spacing('0') auto spacing('2');
|
|
250
246
|
}
|
|
251
247
|
}
|
|
252
|
-
|
|
253
|
-
@include media-down('sm') {
|
|
254
|
-
.mw-tile {
|
|
255
|
-
padding: spacing('4');
|
|
256
|
-
}
|
|
257
|
-
}
|
|
258
248
|
}
|
|
@@ -51,6 +51,10 @@ $_column-steps-lg: (
|
|
|
51
51
|
),
|
|
52
52
|
);
|
|
53
53
|
|
|
54
|
+
// The breakpoints a grid can be pushed to. Outside the layer blocks for the
|
|
55
|
+
// same reason as the steps above: both read it.
|
|
56
|
+
$_grid-from: ('sm', 'md', 'lg', 'xl');
|
|
57
|
+
|
|
54
58
|
@layer mw.layout {
|
|
55
59
|
%grid-base {
|
|
56
60
|
display: grid;
|
|
@@ -290,6 +294,19 @@ $_column-steps-lg: (
|
|
|
290
294
|
}
|
|
291
295
|
}
|
|
292
296
|
|
|
297
|
+
// Every ramp above turns two-column at `sm`, and 576px is generous for a
|
|
298
|
+
// column of running text next to a picture. This pushes the whole ramp up:
|
|
299
|
+
// single column until the breakpoint named, the grid's own steps from there.
|
|
300
|
+
// A modifier, so it works on all of them - and it has to come after them,
|
|
301
|
+
// because it carries the same specificity and wins on order alone.
|
|
302
|
+
@each $breakpoint in $_grid-from {
|
|
303
|
+
.mw-grid-from-#{$breakpoint} {
|
|
304
|
+
@include media-down($breakpoint) {
|
|
305
|
+
@include _single-column;
|
|
306
|
+
}
|
|
307
|
+
}
|
|
308
|
+
}
|
|
309
|
+
|
|
293
310
|
// A feature card grows outwards - its frame and its label bar reach into the
|
|
294
311
|
// gap, and two rows of them would touch. The card asks for the room, but the
|
|
295
312
|
// grid has to hand it over: written next to the card it would sit in
|
|
@@ -350,4 +367,15 @@ $_column-steps-lg: (
|
|
|
350
367
|
@include _reveal-ramp($steps);
|
|
351
368
|
}
|
|
352
369
|
}
|
|
370
|
+
|
|
371
|
+
// Below its breakpoint the grid is one column, so the stagger has to count in
|
|
372
|
+
// one too - otherwise two cards standing above each other rise on different
|
|
373
|
+
// beats. Last, so it beats the ramp it corrects at equal specificity.
|
|
374
|
+
@each $breakpoint in $_grid-from {
|
|
375
|
+
.mw-grid-from-#{$breakpoint} {
|
|
376
|
+
@include media-down($breakpoint) {
|
|
377
|
+
@include _reveal-stagger(1);
|
|
378
|
+
}
|
|
379
|
+
}
|
|
380
|
+
}
|
|
353
381
|
}
|
|
@@ -529,16 +529,19 @@
|
|
|
529
529
|
}
|
|
530
530
|
}
|
|
531
531
|
|
|
532
|
-
// Profile button - avatar
|
|
532
|
+
// Profile button - a round avatar until there is room for the signed-in name
|
|
533
|
+
// beside it
|
|
533
534
|
.mw-profile-btn {
|
|
534
535
|
display: inline-flex;
|
|
535
536
|
align-items: center;
|
|
537
|
+
justify-content: center;
|
|
536
538
|
gap: spacing('3');
|
|
537
539
|
height: 40px;
|
|
538
|
-
|
|
540
|
+
width: 40px;
|
|
541
|
+
padding: spacing('0');
|
|
539
542
|
background: transparent;
|
|
540
543
|
border: 1px solid var(--mw-header-border);
|
|
541
|
-
border-radius: radius('
|
|
544
|
+
border-radius: radius('full');
|
|
542
545
|
color: var(--mw-header-text-color);
|
|
543
546
|
cursor: pointer;
|
|
544
547
|
transition: var(--mw-transition);
|
|
@@ -583,14 +586,18 @@
|
|
|
583
586
|
font-size: font-size('xl');
|
|
584
587
|
}
|
|
585
588
|
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
589
|
+
.mw-profile-btn-name {
|
|
590
|
+
display: none;
|
|
591
|
+
}
|
|
592
|
+
|
|
593
|
+
@include media-up('md') {
|
|
594
|
+
width: auto;
|
|
595
|
+
justify-content: normal;
|
|
596
|
+
padding: spacing('0') spacing('4') spacing('0') spacing('1');
|
|
597
|
+
border-radius: radius('2xl');
|
|
591
598
|
|
|
592
599
|
.mw-profile-btn-name {
|
|
593
|
-
display:
|
|
600
|
+
display: inline;
|
|
594
601
|
}
|
|
595
602
|
}
|
|
596
603
|
}
|
|
@@ -5,11 +5,17 @@
|
|
|
5
5
|
justify-items: center;
|
|
6
6
|
align-items: center;
|
|
7
7
|
text-align: center;
|
|
8
|
+
// The hero container runs the full width of the screen (see _main.scss), so
|
|
9
|
+
// the content has to produce the container width itself - otherwise it
|
|
10
|
+
// starts at a different edge than the header and every section below it.
|
|
11
|
+
// The gutter is already inside the token, hence no inline padding here.
|
|
12
|
+
width: var(--mw-container-width);
|
|
13
|
+
margin-inline: auto;
|
|
8
14
|
|
|
9
15
|
&-content {
|
|
10
|
-
padding: spacing('9') spacing('
|
|
16
|
+
padding: spacing('9') spacing('0');
|
|
11
17
|
@include media-up('sm') {
|
|
12
|
-
padding: spacing('6');
|
|
18
|
+
padding-block: spacing('6');
|
|
13
19
|
}
|
|
14
20
|
|
|
15
21
|
&-fade {
|
|
@@ -28,6 +34,19 @@
|
|
|
28
34
|
}
|
|
29
35
|
}
|
|
30
36
|
|
|
37
|
+
// A hero that points somewhere instead of sitting in the middle: the signet,
|
|
38
|
+
// the headline and the buttons all start at the edge the rest of the page
|
|
39
|
+
// starts at. Centred is still the default - a hero is short enough for it,
|
|
40
|
+
// which is exactly what a section head is not.
|
|
41
|
+
.mw-home-start {
|
|
42
|
+
justify-items: start;
|
|
43
|
+
text-align: left;
|
|
44
|
+
|
|
45
|
+
.mw-home-text {
|
|
46
|
+
margin-inline: 0;
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
|
|
31
50
|
@keyframes fadeIn {
|
|
32
51
|
from {
|
|
33
52
|
opacity: 0;
|
|
@@ -13,19 +13,19 @@
|
|
|
13
13
|
counter-reset: mw-section-head;
|
|
14
14
|
}
|
|
15
15
|
|
|
16
|
-
//
|
|
17
|
-
//
|
|
18
|
-
//
|
|
16
|
+
// Takes the full container on a phone and steps inwards as the screen grows.
|
|
17
|
+
// For a column of full-width cards, which at 1200px leaves more empty card
|
|
18
|
+
// than content.
|
|
19
19
|
.mw-container-narrow {
|
|
20
|
-
width:
|
|
20
|
+
width: 100%;
|
|
21
21
|
margin-inline: auto;
|
|
22
22
|
|
|
23
|
-
@include media-
|
|
23
|
+
@include media-up('md') {
|
|
24
24
|
width: 90%;
|
|
25
25
|
}
|
|
26
26
|
|
|
27
|
-
@include media-
|
|
28
|
-
width:
|
|
27
|
+
@include media-up('lg') {
|
|
28
|
+
width: 80%;
|
|
29
29
|
}
|
|
30
30
|
}
|
|
31
31
|
|
|
@@ -34,11 +34,11 @@
|
|
|
34
34
|
flex-wrap: wrap;
|
|
35
35
|
align-items: center;
|
|
36
36
|
gap: spacing('3');
|
|
37
|
-
|
|
37
|
+
width: 100%;
|
|
38
38
|
|
|
39
|
-
@include media-
|
|
40
|
-
width:
|
|
41
|
-
margin-left:
|
|
39
|
+
@include media-up('sm') {
|
|
40
|
+
width: auto;
|
|
41
|
+
margin-left: auto;
|
|
42
42
|
}
|
|
43
43
|
}
|
|
44
44
|
|
|
@@ -113,11 +113,9 @@
|
|
|
113
113
|
// levels read as a hierarchy rather than as two of the same thing.
|
|
114
114
|
.mw-section-subtitle {
|
|
115
115
|
font-size: fluid('xl', '2xl', $to: 'sm');
|
|
116
|
-
//
|
|
117
|
-
//
|
|
118
|
-
|
|
119
|
-
// before it.
|
|
120
|
-
margin: spacing('8') spacing('0') spacing('4') spacing('0');
|
|
116
|
+
// The section boundary is 56px on a phone, so the component boundary sits
|
|
117
|
+
// with it or the two stop being distinguishable
|
|
118
|
+
margin: spacing('6') spacing('0') spacing('4') spacing('0');
|
|
121
119
|
position: relative;
|
|
122
120
|
|
|
123
121
|
&::after {
|
|
@@ -201,11 +199,13 @@
|
|
|
201
199
|
}
|
|
202
200
|
}
|
|
203
201
|
|
|
204
|
-
@include media-
|
|
205
|
-
//
|
|
206
|
-
// boundary
|
|
202
|
+
@include media-up('sm') {
|
|
203
|
+
// One step above the demo gap of spacing('6'), and that step is the whole
|
|
204
|
+
// margin the boundary between two components has over the one between two
|
|
205
|
+
// demos - the heading leans toward what it names, not toward what came
|
|
206
|
+
// before it.
|
|
207
207
|
.mw-section-subtitle {
|
|
208
|
-
margin-top: spacing('
|
|
208
|
+
margin-top: spacing('8');
|
|
209
209
|
}
|
|
210
210
|
}
|
|
211
211
|
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
// The same framework without the 48 components: tokens, reset, typography,
|
|
2
|
+
// grid, container, section, header, footer and every utility. Add the
|
|
3
|
+
// components the page actually uses next to it, each one its own file:
|
|
4
|
+
//
|
|
5
|
+
// @use 'maverick-wave/src/scss/main-lean' with ($primary-color: #1b1b1d);
|
|
6
|
+
// @use 'maverick-wave/src/scss/components/buttons';
|
|
7
|
+
// @use 'maverick-wave/src/scss/components/cards';
|
|
8
|
+
//
|
|
9
|
+
// The configuration goes on this file, not on the component imports - they
|
|
10
|
+
// read the tokens it forwards. A landing page that uses eight components lands
|
|
11
|
+
// around a third of the full build; the components carry the rest.
|
|
12
|
+
@forward 'abstracts/variables';
|
|
13
|
+
|
|
14
|
+
@use 'base';
|
|
15
|
+
@use 'layout';
|
|
16
|
+
@use 'utilities';
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
@use '../abstracts' as *;
|
|
2
|
+
|
|
3
|
+
// Last layer on purpose: these rules have to win against the components they
|
|
4
|
+
// flatten, and a media query adds no specificity of its own.
|
|
5
|
+
@layer mw.utilities {
|
|
6
|
+
// Hidden on screen, shown on paper. Before the print block and not after it:
|
|
7
|
+
// both rules have the same specificity, so the later one would win in print
|
|
8
|
+
// too and the note would never appear.
|
|
9
|
+
.mw-print-only {
|
|
10
|
+
display: none;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
@media print {
|
|
14
|
+
// Paper is white and ink is black, whatever the screen was told to be. The
|
|
15
|
+
// tokens are redeclared on .mw-theme-light too - that copy sits further
|
|
16
|
+
// down the tree and would otherwise shadow the one on :root.
|
|
17
|
+
:root,
|
|
18
|
+
.mw-theme-light {
|
|
19
|
+
--mw-page-background: #fff;
|
|
20
|
+
--mw-card-background: #fff;
|
|
21
|
+
--mw-footer-background: #fff;
|
|
22
|
+
--mw-text-color: #000;
|
|
23
|
+
--mw-text-muted-color: #333;
|
|
24
|
+
--mw-border: #999;
|
|
25
|
+
--mw-border-accent: #666;
|
|
26
|
+
|
|
27
|
+
// No toner for depth that paper cannot show anyway. Level 0 is not in the
|
|
28
|
+
// list: it is flat by definition and nothing reads it as a variable.
|
|
29
|
+
--mw-elevation-1: none;
|
|
30
|
+
--mw-elevation-2: none;
|
|
31
|
+
--mw-elevation-3: none;
|
|
32
|
+
--mw-elevation-4: none;
|
|
33
|
+
--mw-elevation-5: none;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
body {
|
|
37
|
+
background: #fff;
|
|
38
|
+
color: #000;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
// Chrome that is fixed on screen would print on the first page and cover
|
|
42
|
+
// what is underneath, and navigation is useless on paper either way.
|
|
43
|
+
.mw-header,
|
|
44
|
+
.mw-announcement:not(.mw-announcement-static),
|
|
45
|
+
.mw-section-nav,
|
|
46
|
+
.mw-scroll-hint,
|
|
47
|
+
.mw-menu-btn,
|
|
48
|
+
.mw-theme-toggle,
|
|
49
|
+
.mw-skip-link,
|
|
50
|
+
.mw-toast-stack,
|
|
51
|
+
.mw-hide-print {
|
|
52
|
+
display: none;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
// The counterpart: a note that only makes sense on the printed page
|
|
56
|
+
.mw-print-only {
|
|
57
|
+
display: revert;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
// A surface without its tone still needs an edge to be a surface
|
|
61
|
+
.mw-card,
|
|
62
|
+
.mw-panel,
|
|
63
|
+
.mw-tile,
|
|
64
|
+
.mw-alert,
|
|
65
|
+
.mw-info {
|
|
66
|
+
border: 1px solid #999;
|
|
67
|
+
background: #fff;
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
// Anything that is one thing should not be torn across two pages
|
|
71
|
+
.mw-card,
|
|
72
|
+
.mw-panel,
|
|
73
|
+
.mw-tile,
|
|
74
|
+
.mw-section-head,
|
|
75
|
+
.mw-leader-row,
|
|
76
|
+
.mw-item-list-item,
|
|
77
|
+
tr,
|
|
78
|
+
figure,
|
|
79
|
+
blockquote {
|
|
80
|
+
break-inside: avoid;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
// A heading at the foot of a page belongs to the next one
|
|
84
|
+
h1,
|
|
85
|
+
h2,
|
|
86
|
+
h3,
|
|
87
|
+
.mw-section-head-title,
|
|
88
|
+
.mw-section-subtitle {
|
|
89
|
+
break-after: avoid;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
// Screen rhythm is scroll distance; on paper it is wasted sheets
|
|
93
|
+
.mw-section {
|
|
94
|
+
padding-block: spacing('6');
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
// A link is only worth printing when its target comes with it. Internal
|
|
98
|
+
// anchors and mail links stay quiet - the first says nothing on paper, the
|
|
99
|
+
// second already shows the address as its text.
|
|
100
|
+
.mw-prose a[href^='http']::after,
|
|
101
|
+
.mw-disclaimer a[href^='http']::after {
|
|
102
|
+
content: ' (' attr(href) ')';
|
|
103
|
+
font-size: font-size('xs');
|
|
104
|
+
word-break: break-all;
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
}
|