maverick-wave 5.33.0 → 5.34.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 +2 -2
- package/maverick-wave.min.css +16 -2
- package/maverick-wave.min.js +1 -1
- package/package.json +2 -2
- package/src/js/main.js +769 -3
- package/src/js/occasions.js +107 -0
- package/src/scss/abstracts/_variables.scss +2 -0
- package/src/scss/components/_deck-blocks.scss +963 -0
- package/src/scss/components/_deck-frame.scss +102 -0
- package/src/scss/components/_deck.scss +700 -0
- package/src/scss/components/_index.scss +3 -0
- package/src/scss/components/_occasions.scss +1574 -0
- package/src/scss/layout/_section.scss +4 -4
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
@use '../abstracts' as *;
|
|
2
|
+
@use 'cards';
|
|
3
|
+
|
|
4
|
+
// A deck shown inside a normal page: the iframe that holds it, the column of
|
|
5
|
+
// text beside it, and a card that links to it. The deck itself is a page of
|
|
6
|
+
// its own and loads _deck.scss.
|
|
7
|
+
|
|
8
|
+
@layer mw.components {
|
|
9
|
+
.mw-deck-frame {
|
|
10
|
+
// The window below every layer of sticky chrome: a frame taller than that
|
|
11
|
+
// can never be seen whole
|
|
12
|
+
--mw-deck-frame-room: calc(
|
|
13
|
+
100dvh - var(--mw-header-height) - var(--mw-announcement-offset) - var(
|
|
14
|
+
--mw-section-nav-offset
|
|
15
|
+
)
|
|
16
|
+
);
|
|
17
|
+
|
|
18
|
+
position: relative;
|
|
19
|
+
overflow: hidden;
|
|
20
|
+
margin-inline: auto;
|
|
21
|
+
background-color: $fixed-stage;
|
|
22
|
+
box-shadow: var(--mw-elevation-4);
|
|
23
|
+
|
|
24
|
+
iframe {
|
|
25
|
+
display: block;
|
|
26
|
+
width: 100%;
|
|
27
|
+
height: 100%;
|
|
28
|
+
border: 0;
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
// As wide as the column but never taller than the room. On a phone it
|
|
33
|
+
// stands upright: the deck then asks to be turned.
|
|
34
|
+
.mw-deck-frame:not(.mw-deck-frame-portrait) {
|
|
35
|
+
@include surface;
|
|
36
|
+
width: min(100%, calc((var(--mw-deck-frame-room) - 6rem) * 1.6));
|
|
37
|
+
aspect-ratio: 16 / 10;
|
|
38
|
+
|
|
39
|
+
@include media-down('md') {
|
|
40
|
+
aspect-ratio: 4 / 5;
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
// The shape of the phone the deck was made for, rounded like one - the
|
|
45
|
+
// accent arcs follow that curve instead of the surface signature
|
|
46
|
+
.mw-deck-frame-portrait {
|
|
47
|
+
height: min(844px, calc(var(--mw-deck-frame-room) - 4rem));
|
|
48
|
+
max-width: 100%;
|
|
49
|
+
aspect-ratio: 390 / 844;
|
|
50
|
+
border-radius: 2rem;
|
|
51
|
+
|
|
52
|
+
&::after {
|
|
53
|
+
@include corner-accent;
|
|
54
|
+
border-radius: inherit;
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
// Frame and text: stacked, and side by side once a portrait frame leaves
|
|
59
|
+
// room for the text
|
|
60
|
+
.mw-deck-embed {
|
|
61
|
+
display: grid;
|
|
62
|
+
gap: spacing('8');
|
|
63
|
+
|
|
64
|
+
&:has(> .mw-deck-frame-portrait) {
|
|
65
|
+
@include media-up('md') {
|
|
66
|
+
grid-template-columns: auto minmax(0, 1fr);
|
|
67
|
+
align-items: center;
|
|
68
|
+
gap: spacing('11');
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
.mw-deck-embed-info {
|
|
74
|
+
max-width: 60ch;
|
|
75
|
+
|
|
76
|
+
> p {
|
|
77
|
+
margin-bottom: 0;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
> p + p {
|
|
81
|
+
margin-top: spacing('4');
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
.mw-deck-embed-actions {
|
|
86
|
+
display: flex;
|
|
87
|
+
flex-wrap: wrap;
|
|
88
|
+
gap: spacing('3');
|
|
89
|
+
margin-top: spacing('7');
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
// The preview is a screenshot of the first slide: it keeps its 4:3 instead
|
|
93
|
+
// of being cropped to the card's image height
|
|
94
|
+
.mw-deck-card {
|
|
95
|
+
color: inherit;
|
|
96
|
+
|
|
97
|
+
.mw-card-img {
|
|
98
|
+
height: auto;
|
|
99
|
+
aspect-ratio: 4 / 3;
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
}
|