@steamfield/decks 0.0.0-stage → 1.0.0-rc.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/LICENSE +201 -0
- package/README.md +28 -2
- package/dist/cli.d.ts +1 -0
- package/dist/cli.js +5 -0
- package/dist/index-B2n69xrC.d.ts +75 -0
- package/dist/index-BURtH7IB.d.ts +182 -0
- package/dist/index-BV_-6L5L.d.ts +136 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.js +6 -0
- package/dist/kit/chrome/od-byline.css +7 -0
- package/dist/kit/chrome/od-cover-head.css +10 -0
- package/dist/kit/chrome/od-eyebrow.css +13 -0
- package/dist/kit/chrome/od-logo.css +167 -0
- package/dist/kit/chrome/od-qr-card.css +30 -0
- package/dist/kit/ink/code-ink.css +83 -0
- package/dist/kit/ink/graph-3d.css +29 -0
- package/dist/kit/ink/ink-bars.css +7 -0
- package/dist/kit/ink/ink-card-rect.css +6 -0
- package/dist/kit/ink/ink-chip.css +62 -0
- package/dist/kit/ink/ink-line.css +7 -0
- package/dist/kit/ink/ink-number.css +22 -0
- package/dist/kit/ink/ink-ping.css +4 -0
- package/dist/kit/ink/ink-rule.css +4 -0
- package/dist/kit/ink/ink-timeline-cursor.css +3 -0
- package/dist/kit/ink/ink-timeline.css +9 -0
- package/dist/kit/ink/underline.css +12 -0
- package/dist/kit/ink/unit-grid.css +3 -0
- package/dist/kit/story/story-card.css +19 -0
- package/dist/kit/story/story-link.css +13 -0
- package/dist/kit/story/story-stage.css +59 -0
- package/dist/kit/styles/base.css +82 -0
- package/dist/kit/styles/compat.css +78 -0
- package/dist/kit/styles/components.css +224 -0
- package/dist/kit/styles/fonts/inter-cyrillic-ext-wght-normal.woff2 +0 -0
- package/dist/kit/styles/fonts/inter-cyrillic-wght-normal.woff2 +0 -0
- package/dist/kit/styles/fonts/inter-greek-ext-wght-normal.woff2 +0 -0
- package/dist/kit/styles/fonts/inter-greek-wght-normal.woff2 +0 -0
- package/dist/kit/styles/fonts/inter-latin-ext-wght-normal.woff2 +0 -0
- package/dist/kit/styles/fonts/inter-latin-wght-normal.woff2 +0 -0
- package/dist/kit/styles/fonts/inter-vietnamese-wght-normal.woff2 +0 -0
- package/dist/kit/styles/fonts.css +73 -0
- package/dist/kit/styles/index.css +36 -0
- package/dist/kit/styles/layout.css +181 -0
- package/dist/kit/styles/stats.css +92 -0
- package/dist/kit/styles/story-frame.css +179 -0
- package/dist/kit/styles/story-marks.css +115 -0
- package/dist/kit/styles/story-transition.css +182 -0
- package/dist/kit/styles.css +1 -0
- package/dist/kit.d.ts +880 -0
- package/dist/kit.js +3475 -0
- package/dist/layers.css +60 -0
- package/dist/layouts.css +58 -0
- package/dist/lint/ai-rhetoric-patterns.tsv +110 -0
- package/dist/lint/deck-writing-reminder.md +9 -0
- package/dist/motion.css +215 -0
- package/dist/motion.d.ts +2 -0
- package/dist/motion.js +1 -0
- package/dist/node.d.ts +63 -0
- package/dist/node.js +1 -0
- package/dist/overview-view.css +58 -0
- package/dist/play-view.css +29 -0
- package/dist/plugin/skills/building-a-deck/SKILL.md +22 -0
- package/dist/plugin/skills/building-a-deck/references/workflow.md +86 -0
- package/dist/plugin/skills/deck-data/SKILL.md +27 -0
- package/dist/plugin/skills/deck-data/references/fact-check.md +59 -0
- package/dist/plugin/skills/deck-data/references/provenance.md +61 -0
- package/dist/plugin/skills/deck-design/SKILL.md +31 -0
- package/dist/plugin/skills/deck-design/references/layout.md +55 -0
- package/dist/plugin/skills/deck-motion/SKILL.md +34 -0
- package/dist/plugin/skills/deck-motion/references/motion.md +66 -0
- package/dist/plugin/skills/visualization/SKILL.md +34 -0
- package/dist/plugin/skills/visualization/references/VENDORED.md +25 -0
- package/dist/plugin/skills/visualization/references/annotations.md +27 -0
- package/dist/plugin/skills/visualization/references/chart-selection.md +29 -0
- package/dist/plugin/skills/visualization/references/color-strategy.md +22 -0
- package/dist/plugin/skills/visualization/references/encoding-channels.md +44 -0
- package/dist/plugin/skills/visualization/references/ink.md +38 -0
- package/dist/plugin/skills/visualization/references/marks.md +33 -0
- package/dist/plugin/skills/visualization/references/presentation.md +43 -0
- package/dist/plugin/skills/working-with-decks/SKILL.md +34 -0
- package/dist/plugin/skills/working-with-decks/references/project.md +59 -0
- package/dist/plugin/skills/writing-slides/SKILL.md +45 -0
- package/dist/plugin/skills/writing-slides/references/lint.md +11 -0
- package/dist/plugin/skills/writing-slides/references/prose-patterns.md +48 -0
- package/dist/presenter-view.css +113 -0
- package/dist/print-view.module.css +32 -0
- package/dist/prose-patterns-DPqjGBFu.js +76 -0
- package/dist/prose-scan-BrWZ7gxZ.js +233 -0
- package/dist/src-C-OfT72W.js +396 -0
- package/dist/src-CmQgaG1b.js +2469 -0
- package/dist/src-DizFoqYt.js +1508 -0
- package/dist/templates/conventional/deck.config.ts +7 -0
- package/dist/templates/conventional/setup.ts +3 -0
- package/dist/templates/conventional/slides/01-cover.mdx +9 -0
- package/dist/templates/conventional/slides/02-first-point.mdx +12 -0
- package/dist/templates/conventional/styles/index.css +1 -0
- package/dist/templates/story/components/FirstStage.tsx +34 -0
- package/dist/templates/story/data/01-first.ts +8 -0
- package/dist/templates/story/data-sources.md +7 -0
- package/dist/templates/story/deck.config.ts +8 -0
- package/dist/templates/story/setup.ts +3 -0
- package/dist/templates/story/slides/01-cover.mdx +9 -0
- package/dist/templates/story/slides/02-first-point.mdx +6 -0
- package/dist/templates/story/styles/index.css +1 -0
- package/dist/transition.css +87 -0
- package/docs/README.md +28 -0
- package/docs/canvas.md +134 -0
- package/docs/cli.md +49 -0
- package/docs/code-blocks.md +132 -0
- package/docs/config.md +183 -0
- package/docs/getting-started.md +204 -0
- package/docs/kit.md +371 -0
- package/docs/migrating-from-slidev.md +45 -0
- package/docs/motion.md +396 -0
- package/docs/presenting.md +99 -0
- package/docs/slides.md +246 -0
- package/package.json +108 -4
|
@@ -0,0 +1,179 @@
|
|
|
1
|
+
/* ── Story slides: the frame ──────────────────────────────────────────────
|
|
2
|
+
The slide level chrome of a story slide: the 16:9 box every layer shares,
|
|
3
|
+
the frame units and duration mirrors declared on it, the cover layout, the
|
|
4
|
+
headline, and the cross slide hand off. The marks that sit inside the frame
|
|
5
|
+
are in story-marks.css, which loads straight after this file.
|
|
6
|
+
|
|
7
|
+
Every rule here is scoped under `.od-slide.is-story`, because the shared
|
|
8
|
+
addon stylesheet ships to every deck and nothing in this file should reach
|
|
9
|
+
a conventional slide.
|
|
10
|
+
|
|
11
|
+
Two exceptions live at the bottom and cannot be scoped, because the browser
|
|
12
|
+
owns the elements: the `::view-transition-*` pseudo elements (document
|
|
13
|
+
level by definition) and their keyframes. Their duration and easing mirror
|
|
14
|
+
`DUR.morph` and `SETTLE_CSS` in `packages/decks/story/easings.ts`; if either moves,
|
|
15
|
+
move both.
|
|
16
|
+
------------------------------------------------------------------------ */
|
|
17
|
+
|
|
18
|
+
.od-slide.is-story {
|
|
19
|
+
position: relative;
|
|
20
|
+
display: block;
|
|
21
|
+
padding: 0;
|
|
22
|
+
overflow: hidden;
|
|
23
|
+
|
|
24
|
+
/* The largest 16:9 box that fits the viewport. Ink is drawn in a 1920x1080
|
|
25
|
+
viewBox and the overlay is laid out in CSS, and the two only coincide if
|
|
26
|
+
the box holding them has the viewBox's aspect ratio. When the slide itself
|
|
27
|
+
was the box, any viewport that was not 16:9 made `xMidYMid slice` crop the
|
|
28
|
+
ink: fullscreen on a 16:10 laptop cut everything past viewBox x=1824,
|
|
29
|
+
which is where this deck draws. Both layers live in this frame instead, so
|
|
30
|
+
nothing is ever cropped and ink lands on overlay at any aspect ratio. */
|
|
31
|
+
/* The frame fits above the credit's band (0px on a deck with no credit), so nothing in a
|
|
32
|
+
stage can reach the credit. */
|
|
33
|
+
--od-avail-h: calc(100cqh - var(--deck-credit-space, 0px));
|
|
34
|
+
--od-fw: min(100cqw, var(--od-avail-h) * 16 / 9);
|
|
35
|
+
--od-fh: min(var(--od-avail-h), 56.25cqw);
|
|
36
|
+
|
|
37
|
+
/* One percent of the frame, for everything inside it. These replace cqw and
|
|
38
|
+
cqh: a viewport unit inside the frame drifts from the ink the moment the
|
|
39
|
+
window stops being 16:9. 1 --sw is 19.2 viewBox units, 1 --sh is 10.8. */
|
|
40
|
+
--sw: calc(var(--od-fw) / 100);
|
|
41
|
+
--sh: calc(var(--od-fh) / 100);
|
|
42
|
+
/* Horizontal layout can expand independently of type and SVG geometry. */
|
|
43
|
+
--lw: calc(var(--od-fw) / 100);
|
|
44
|
+
/* Half the letterbox band: how far a layer that is meant to cover the whole
|
|
45
|
+
window (a full bleed map, say) has to reach past the frame on each side.
|
|
46
|
+
Everything laid out inside the frame still uses --sw/--sh. */
|
|
47
|
+
--od-bleed-x: calc((100cqw - var(--od-fw)) / 2);
|
|
48
|
+
/* Mirrors of the TS duration table, for the handful of transitions that
|
|
49
|
+
stay in CSS. Keep in sync with DUR in packages/decks/story/easings.ts. */
|
|
50
|
+
--od-dur-card: 300ms;
|
|
51
|
+
--od-dur-opacity: 140ms;
|
|
52
|
+
--od-settle: cubic-bezier(0.32, 0.72, 0, 1);
|
|
53
|
+
--od-draw: cubic-bezier(0.65, 0, 0.35, 1);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
/* Cover variant: the stage carries the ink, the glow stays. */
|
|
57
|
+
.od-slide.is-story.is-story-cover {
|
|
58
|
+
background:
|
|
59
|
+
radial-gradient(
|
|
60
|
+
57cqw 70cqh at 86% 12%,
|
|
61
|
+
rgba(var(--od-glow-primary-rgb), 0.1),
|
|
62
|
+
rgba(var(--od-glow-primary-rgb), 0) 55%
|
|
63
|
+
),
|
|
64
|
+
radial-gradient(
|
|
65
|
+
43cqw 57cqh at 8% 102%,
|
|
66
|
+
rgba(var(--od-glow-secondary-rgb), 0.07),
|
|
67
|
+
rgba(var(--od-glow-secondary-rgb), 0) 55%
|
|
68
|
+
),
|
|
69
|
+
var(--od-canvas-cover);
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
/* The 16:9 box the stage svg and the overlay share. */
|
|
73
|
+
.od-slide.is-story .od-story-frame {
|
|
74
|
+
position: absolute;
|
|
75
|
+
left: 50%;
|
|
76
|
+
top: calc(var(--od-avail-h) / 2);
|
|
77
|
+
width: var(--od-fw);
|
|
78
|
+
height: var(--od-fh);
|
|
79
|
+
transform: translate(-50%, -50%);
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
/* Reflowable HTML and chart containers use the window width, capped at 12:5
|
|
83
|
+
on ultrawide displays. Type stays tied to the fitted frame height so it
|
|
84
|
+
cannot crowd the vertical layout. Fixed-coordinate SVG scenes opt out. */
|
|
85
|
+
.od-slide.is-story.is-fluid {
|
|
86
|
+
--od-fw: min(100cqw, var(--od-avail-h) * 2.4);
|
|
87
|
+
--sw: calc(min(var(--od-fw), var(--od-fh) * 16 / 9) / 100);
|
|
88
|
+
--lw: calc(var(--od-fw) / 100);
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
/* ── Stage ── */
|
|
92
|
+
.od-slide.is-story .od-stage {
|
|
93
|
+
position: absolute;
|
|
94
|
+
inset: 0;
|
|
95
|
+
display: block;
|
|
96
|
+
width: 100%;
|
|
97
|
+
height: 100%;
|
|
98
|
+
pointer-events: none;
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
/* A second full bleed svg layer, for ink that has to sit on an element with a
|
|
102
|
+
CSS box (anything carrying a view-transition-name). */
|
|
103
|
+
.od-slide.is-story .od-stage-layer {
|
|
104
|
+
position: absolute;
|
|
105
|
+
inset: 0;
|
|
106
|
+
display: block;
|
|
107
|
+
width: 100%;
|
|
108
|
+
height: 100%;
|
|
109
|
+
pointer-events: none;
|
|
110
|
+
}
|
|
111
|
+
.od-slide.is-story .od-stage-layer > svg {
|
|
112
|
+
display: block;
|
|
113
|
+
width: 100%;
|
|
114
|
+
height: 100%;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
/* Cover chrome: the one story overlay that is a flow layout rather than a set
|
|
118
|
+
of absolutely placed pieces. */
|
|
119
|
+
.od-slide.is-story .od-cover-frame {
|
|
120
|
+
position: absolute;
|
|
121
|
+
inset: 0;
|
|
122
|
+
display: flex;
|
|
123
|
+
flex-direction: column;
|
|
124
|
+
justify-content: space-between;
|
|
125
|
+
padding: calc(8.1 * var(--sh)) calc(5.7 * var(--lw));
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
/* A cover frame with no byline row (the close) has two children, and
|
|
129
|
+
space-between would drop the title to the floor. This centers the middle
|
|
130
|
+
block in the space left over, which is where a three-row frame puts it,
|
|
131
|
+
without an empty element standing in as a spacer. */
|
|
132
|
+
.od-slide.is-story .od-cover-frame > .od-cover-center {
|
|
133
|
+
margin-block: auto;
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
/* The body block: eyebrow, title, lede. Narrower than the frame so a title
|
|
137
|
+
wraps where it reads best. */
|
|
138
|
+
.od-slide.is-story .od-cover-body {
|
|
139
|
+
max-width: calc(64 * var(--lw));
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
/* The one sentence under a cover title. */
|
|
143
|
+
.od-slide.is-story .od-cover-lede {
|
|
144
|
+
margin: 1.7rem 0 0;
|
|
145
|
+
max-width: calc(52 * var(--lw));
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
/* ── Headline: fixed top left, never moves within a slide ──
|
|
149
|
+
A fixed width rather than a max-width. A shrink-to-fit box changes width
|
|
150
|
+
with its text, so the named view-transition group morphed between two
|
|
151
|
+
different boxes and scaled both headline snapshots on every slide change.
|
|
152
|
+
With one width on both sides only the height can differ. */
|
|
153
|
+
.od-slide.is-story .od-story-head {
|
|
154
|
+
position: absolute;
|
|
155
|
+
top: calc(6.2 * var(--sh));
|
|
156
|
+
left: calc(5.7 * var(--lw));
|
|
157
|
+
margin: 0;
|
|
158
|
+
width: calc(64 * var(--lw));
|
|
159
|
+
/* Frame units, not rem: rem holds still while the frame shrinks, so on a
|
|
160
|
+
1280px laptop the headline wrapped into the stage. 46.4px at 1920. */
|
|
161
|
+
font-size: calc(calc(2.4167 * var(--sw)) * var(--deck-text-scale, 1));
|
|
162
|
+
font-weight: 510;
|
|
163
|
+
line-height: 1.12;
|
|
164
|
+
letter-spacing: -0.022em;
|
|
165
|
+
color: var(--od-text);
|
|
166
|
+
}
|
|
167
|
+
/* The headline and the cover title set in `fonts.serif`, which is the sans
|
|
168
|
+
unless the deck's theme.json says otherwise. The !important answers the
|
|
169
|
+
`.slidev-layout h1, h2` rule in base.css, which pins headings to the sans. */
|
|
170
|
+
.od-slide.is-story .od-story-head,
|
|
171
|
+
.od-slide.is-story .od-title {
|
|
172
|
+
font-family: var(--od-font-serif) !important;
|
|
173
|
+
}
|
|
174
|
+
/* One line at the full width of the frame, for a stage that needs the height
|
|
175
|
+
a wrapped headline would take. */
|
|
176
|
+
.od-slide.is-story .od-story-head.is-wide {
|
|
177
|
+
width: calc(88 * var(--lw));
|
|
178
|
+
white-space: nowrap;
|
|
179
|
+
}
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
/* ── Story slides: the marks ──────────────────────────────────────────────
|
|
2
|
+
What sits inside the frame: the house card surface the story card, the row
|
|
3
|
+
strip and the dataset card share, its accent hues, the prose card box and
|
|
4
|
+
the svg stage label. Loads after story-frame.css, which declares the frame
|
|
5
|
+
units these rules measure in.
|
|
6
|
+
|
|
7
|
+
Every rule here is scoped under `.od-slide.is-story`, for the same reason
|
|
8
|
+
as the frame: the addon stylesheet ships to every deck and nothing in this
|
|
9
|
+
file should reach a conventional slide.
|
|
10
|
+
------------------------------------------------------------------------ */
|
|
11
|
+
|
|
12
|
+
/* ── House card surface ──
|
|
13
|
+
The same construction as `.doc-card` in the frontend: one corner anchored
|
|
14
|
+
radial glow, tinted with the card's accent, over the flat surface token.
|
|
15
|
+
Elevation comes from the glow, the hairline border and the radius, not
|
|
16
|
+
from a drop shadow. `--card-accent` defaults to cyan; the `accent-*`
|
|
17
|
+
modifiers pick the hue of the ink the card sits beside. */
|
|
18
|
+
.od-slide.is-story .od-story-card,
|
|
19
|
+
.od-slide.is-story .od-rowstrip,
|
|
20
|
+
.od-slide.is-story .od-dataset-card {
|
|
21
|
+
--card-accent: var(--od-cyan);
|
|
22
|
+
--card-glow: 12%;
|
|
23
|
+
border: var(--od-hairline, 1px) solid var(--od-border);
|
|
24
|
+
border-radius: var(--od-radius, 12px);
|
|
25
|
+
background:
|
|
26
|
+
radial-gradient(
|
|
27
|
+
ellipse 80% 100% at 0% 0%,
|
|
28
|
+
color-mix(in srgb, var(--card-accent) var(--card-glow), transparent) 0%,
|
|
29
|
+
transparent 60%
|
|
30
|
+
),
|
|
31
|
+
var(--od-surface);
|
|
32
|
+
}
|
|
33
|
+
.od-slide.is-story .accent-rose {
|
|
34
|
+
--card-accent: var(--od-rose);
|
|
35
|
+
}
|
|
36
|
+
.od-slide.is-story .accent-amber {
|
|
37
|
+
--card-accent: var(--od-amber);
|
|
38
|
+
}
|
|
39
|
+
.od-slide.is-story .accent-emerald {
|
|
40
|
+
--card-accent: var(--od-emerald);
|
|
41
|
+
}
|
|
42
|
+
.od-slide.is-story .accent-violet {
|
|
43
|
+
--card-accent: var(--od-violet);
|
|
44
|
+
}
|
|
45
|
+
.od-slide.is-story .accent-slate {
|
|
46
|
+
--card-accent: var(--od-slate);
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
/* ── Prose card ── */
|
|
50
|
+
.od-slide.is-story .od-story-card {
|
|
51
|
+
position: absolute;
|
|
52
|
+
bottom: calc(12 * var(--sh));
|
|
53
|
+
/* shape.card-width, in --lw frame units. */
|
|
54
|
+
width: calc(var(--od-card-width, 36) * var(--lw));
|
|
55
|
+
padding: calc(1.5 * var(--sw)) calc(1.7 * var(--sw));
|
|
56
|
+
}
|
|
57
|
+
.od-slide.is-story .od-story-card.anchor-left {
|
|
58
|
+
left: calc(5.7 * var(--lw));
|
|
59
|
+
}
|
|
60
|
+
.od-slide.is-story .od-story-card.anchor-right {
|
|
61
|
+
right: calc(5.7 * var(--lw));
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
/* ── Clean labelled row ── */
|
|
65
|
+
.od-slide.is-story .od-rowstrip {
|
|
66
|
+
overflow: hidden;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
/* ── Stage furniture: typeset text is never filtered ── */
|
|
70
|
+
.od-slide.is-story .od-stage-label {
|
|
71
|
+
font-family: var(--od-font-mono);
|
|
72
|
+
font-size: calc(30px * var(--deck-text-scale, 1));
|
|
73
|
+
font-weight: 500;
|
|
74
|
+
letter-spacing: 0.02em;
|
|
75
|
+
fill: var(--od-text-faint);
|
|
76
|
+
}
|
|
77
|
+
.od-slide.is-story .od-stage-label.is-end {
|
|
78
|
+
fill: var(--od-text-secondary);
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
/* ── Stage text: the four sizes a labelled box is built from ──
|
|
82
|
+
The name of a thing, the line of detail under it, a small uppercase
|
|
83
|
+
category and a figure. Sizes are the median of what the pitch's stages had
|
|
84
|
+
each written out per stage; `InkLabeledCard` uses the first two, and a
|
|
85
|
+
stage that draws its own boxes takes the same four rather than picking new
|
|
86
|
+
sizes. Existing stages keep their scoped classes: retrofitting would move
|
|
87
|
+
text by a few px per site and buys nothing on a finished deck. */
|
|
88
|
+
.od-slide.is-story .od-stage-name {
|
|
89
|
+
font-family: var(--od-font-sans);
|
|
90
|
+
font-size: calc(30px * var(--deck-text-scale, 1));
|
|
91
|
+
font-weight: 590;
|
|
92
|
+
letter-spacing: -0.012em;
|
|
93
|
+
fill: var(--od-text);
|
|
94
|
+
}
|
|
95
|
+
.od-slide.is-story .od-stage-note {
|
|
96
|
+
font-family: var(--od-font-mono);
|
|
97
|
+
font-size: calc(20px * var(--deck-text-scale, 1));
|
|
98
|
+
font-weight: 400;
|
|
99
|
+
fill: var(--od-text-faint);
|
|
100
|
+
}
|
|
101
|
+
.od-slide.is-story .od-stage-tag {
|
|
102
|
+
font-family: var(--od-font-mono);
|
|
103
|
+
font-size: calc(15px * var(--deck-text-scale, 1));
|
|
104
|
+
font-weight: 500;
|
|
105
|
+
letter-spacing: 0.08em;
|
|
106
|
+
text-transform: uppercase;
|
|
107
|
+
fill: var(--od-text-faint);
|
|
108
|
+
}
|
|
109
|
+
.od-slide.is-story .od-stage-value {
|
|
110
|
+
font-family: var(--od-font-mono);
|
|
111
|
+
font-size: calc(20px * var(--deck-text-scale, 1));
|
|
112
|
+
font-weight: 590;
|
|
113
|
+
font-variant-numeric: tabular-nums;
|
|
114
|
+
fill: var(--od-text-secondary);
|
|
115
|
+
}
|
|
@@ -0,0 +1,182 @@
|
|
|
1
|
+
/* Snapshot drift exposes the document canvas; keep it in the deck's ink. */
|
|
2
|
+
html[data-deck-transition="story"] {
|
|
3
|
+
background-color: var(--od-canvas);
|
|
4
|
+
}
|
|
5
|
+
html[data-deck-transition="story"]::view-transition-old(*),
|
|
6
|
+
html[data-deck-transition="story"]::view-transition-new(*) {
|
|
7
|
+
mix-blend-mode: plus-lighter;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
/* ── Cross slide hand off ────────────────────────────────────────────────
|
|
11
|
+
Names are assigned only when the stage says it is rendering the real slide
|
|
12
|
+
(`vt-on`, set from $renderContext), and nulled again under the presenter
|
|
13
|
+
and the print container, so a duplicated name can never abort a
|
|
14
|
+
transition. Only adjacent slides ever share a name.
|
|
15
|
+
|
|
16
|
+
Box-shaped morph targets get an opaque background, because a transparent
|
|
17
|
+
snapshot cross-fades against whatever happens to be behind it. The two ink
|
|
18
|
+
layers stay transparent on purpose: both sides of their morph sit on the
|
|
19
|
+
same canvas, so an opaque box would hide the stage underneath. */
|
|
20
|
+
.od-slide.is-story.vt-on .od-story-head {
|
|
21
|
+
view-transition-name: od-story-head;
|
|
22
|
+
}
|
|
23
|
+
.od-slide.is-story.vt-on .od-story-card.anchor-left {
|
|
24
|
+
view-transition-name: od-story-card-left;
|
|
25
|
+
}
|
|
26
|
+
.od-slide.is-story.vt-on .od-story-card.anchor-right {
|
|
27
|
+
view-transition-name: od-story-card-right;
|
|
28
|
+
}
|
|
29
|
+
.od-slide.is-story.vt-on .vt-drift-line {
|
|
30
|
+
view-transition-name: od-drift-line;
|
|
31
|
+
}
|
|
32
|
+
.od-slide.is-story.vt-on .vt-clean-row {
|
|
33
|
+
view-transition-name: od-clean-row;
|
|
34
|
+
background-color: var(--od-surface);
|
|
35
|
+
}
|
|
36
|
+
.od-slide.is-story.vt-on .vt-seed-square {
|
|
37
|
+
view-transition-name: od-seed-square;
|
|
38
|
+
background-color: var(--od-surface);
|
|
39
|
+
}
|
|
40
|
+
.od-slide.is-story.vt-on .vt-baseline {
|
|
41
|
+
view-transition-name: od-baseline;
|
|
42
|
+
}
|
|
43
|
+
.od-slide.is-story.vt-on .vt-campus-grid {
|
|
44
|
+
view-transition-name: od-campus-grid;
|
|
45
|
+
}
|
|
46
|
+
.od-slide.is-story.vt-on .vt-power-board {
|
|
47
|
+
view-transition-name: od-power-board;
|
|
48
|
+
}
|
|
49
|
+
.od-slide.is-story.vt-on .vt-campus-pair {
|
|
50
|
+
view-transition-name: od-campus-pair;
|
|
51
|
+
}
|
|
52
|
+
.od-slide.is-story.vt-on .vt-qr-frame {
|
|
53
|
+
view-transition-name: od-qr-frame;
|
|
54
|
+
background-color: var(--od-qr-white);
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
/* Document level: the morph itself. 600ms is DUR.morph, 240ms is DUR.draw,
|
|
58
|
+
the curves are SETTLE_CSS and DRAW_CSS. All mirror packages/decks/story/easings.ts.
|
|
59
|
+
|
|
60
|
+
The rules are scoped to `html[data-deck-transition="story"]`, which a deck sets through
|
|
61
|
+
`htmlAttrs` in its headmatter. This stylesheet ships with the addon to
|
|
62
|
+
every deck, and a conventional deck that later turns on view transitions
|
|
63
|
+
must not inherit this pacing by accident.
|
|
64
|
+
|
|
65
|
+
Named groups (the hand offs above) travel on SETTLE over the morph
|
|
66
|
+
duration. The root, which is everything else, cross fades over the same
|
|
67
|
+
duration and curve on both sides, so the two opacities always sum to one
|
|
68
|
+
under the browser's plus-lighter blend and the frame never dips toward
|
|
69
|
+
black, while the new frame settles in from a short drift, downward going
|
|
70
|
+
forward and upward going back. The drift is the one length in this file
|
|
71
|
+
written in vh: --sw and --sh are declared on .od-slide.is-story, and a
|
|
72
|
+
::view-transition pseudo element is a child of the document root, so a
|
|
73
|
+
frame unit resolves to nothing here. Both keyframes use the literal. The
|
|
74
|
+
direction is stamped on <html> by packages/decks/setup/main.ts before the snapshot.
|
|
75
|
+
|
|
76
|
+
The headline and the prose card carry names of their own. Between two
|
|
77
|
+
story slides they cross fade in place; entering from a slide without one
|
|
78
|
+
(`:only-child`, no old image) they rise in like the root, the card one
|
|
79
|
+
stagger after the headline (280ms is two DUR.opacity beats). */
|
|
80
|
+
html[data-deck-transition="story"]::view-transition-group(*) {
|
|
81
|
+
animation-duration: 600ms;
|
|
82
|
+
animation-timing-function: cubic-bezier(0.32, 0.72, 0, 1);
|
|
83
|
+
}
|
|
84
|
+
html[data-deck-transition="story"]::view-transition-old(*),
|
|
85
|
+
html[data-deck-transition="story"]::view-transition-new(*) {
|
|
86
|
+
animation-duration: 600ms;
|
|
87
|
+
animation-timing-function: cubic-bezier(0.32, 0.72, 0, 1);
|
|
88
|
+
}
|
|
89
|
+
html[data-deck-transition="story"]::view-transition-old(root) {
|
|
90
|
+
animation: od-vt-out 600ms cubic-bezier(0.32, 0.72, 0, 1) both;
|
|
91
|
+
}
|
|
92
|
+
html[data-deck-transition="story"]::view-transition-new(root) {
|
|
93
|
+
animation: od-vt-in 600ms cubic-bezier(0.32, 0.72, 0, 1) both;
|
|
94
|
+
}
|
|
95
|
+
html[data-deck-transition="story"][data-deck-nav="backward"]::view-transition-new(root) {
|
|
96
|
+
animation-name: od-vt-in-back;
|
|
97
|
+
}
|
|
98
|
+
html[data-deck-transition="story"]::view-transition-new(od-story-head):only-child,
|
|
99
|
+
html[data-deck-transition="story"]::view-transition-new(od-story-card-left):only-child,
|
|
100
|
+
html[data-deck-transition="story"]::view-transition-new(od-story-card-right):only-child {
|
|
101
|
+
animation: od-vt-in 600ms cubic-bezier(0.32, 0.72, 0, 1) both;
|
|
102
|
+
}
|
|
103
|
+
html[data-deck-transition="story"][data-deck-nav="backward"]::view-transition-new(
|
|
104
|
+
od-story-head
|
|
105
|
+
):only-child,
|
|
106
|
+
html[data-deck-transition="story"][data-deck-nav="backward"]::view-transition-new(
|
|
107
|
+
od-story-card-left
|
|
108
|
+
):only-child,
|
|
109
|
+
html[data-deck-transition="story"][data-deck-nav="backward"]::view-transition-new(
|
|
110
|
+
od-story-card-right
|
|
111
|
+
):only-child {
|
|
112
|
+
animation-name: od-vt-in-back;
|
|
113
|
+
}
|
|
114
|
+
html[data-deck-transition="story"]::view-transition-new(od-story-card-left):only-child,
|
|
115
|
+
html[data-deck-transition="story"]::view-transition-new(od-story-card-right):only-child {
|
|
116
|
+
animation-delay: 280ms;
|
|
117
|
+
}
|
|
118
|
+
html[data-deck-transition="story"]::view-transition-old(od-story-head):only-child,
|
|
119
|
+
html[data-deck-transition="story"]::view-transition-old(od-story-card-left):only-child,
|
|
120
|
+
html[data-deck-transition="story"]::view-transition-old(od-story-card-right):only-child {
|
|
121
|
+
animation: od-vt-out 600ms cubic-bezier(0.32, 0.72, 0, 1) both;
|
|
122
|
+
}
|
|
123
|
+
@keyframes od-vt-out {
|
|
124
|
+
from {
|
|
125
|
+
opacity: 1;
|
|
126
|
+
}
|
|
127
|
+
to {
|
|
128
|
+
opacity: 0;
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
@keyframes od-vt-in {
|
|
132
|
+
from {
|
|
133
|
+
opacity: 0;
|
|
134
|
+
transform: translateY(1.4vh);
|
|
135
|
+
}
|
|
136
|
+
to {
|
|
137
|
+
opacity: 1;
|
|
138
|
+
transform: none;
|
|
139
|
+
}
|
|
140
|
+
}
|
|
141
|
+
@keyframes od-vt-in-back {
|
|
142
|
+
from {
|
|
143
|
+
opacity: 0;
|
|
144
|
+
transform: translateY(-1.4vh);
|
|
145
|
+
}
|
|
146
|
+
to {
|
|
147
|
+
opacity: 1;
|
|
148
|
+
transform: none;
|
|
149
|
+
}
|
|
150
|
+
}
|
|
151
|
+
@keyframes od-vt-fade {
|
|
152
|
+
from {
|
|
153
|
+
opacity: 0;
|
|
154
|
+
}
|
|
155
|
+
to {
|
|
156
|
+
opacity: 1;
|
|
157
|
+
}
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
/* ── Reduced motion: keep the narrative sweeps, drop the drift ── */
|
|
161
|
+
@media (prefers-reduced-motion: reduce) {
|
|
162
|
+
/* A running keyframe outranks a plain declaration, so the drift is
|
|
163
|
+
removed by swapping the keyframe, at the specificity of the back rule. */
|
|
164
|
+
html[data-deck-transition="story"][data-deck-nav]::view-transition-old(root),
|
|
165
|
+
html[data-deck-transition="story"][data-deck-nav]::view-transition-new(root),
|
|
166
|
+
html[data-deck-transition="story"]::view-transition-old(root),
|
|
167
|
+
html[data-deck-transition="story"]::view-transition-new(root),
|
|
168
|
+
html[data-deck-transition="story"][data-deck-nav]::view-transition-new(od-story-head):only-child,
|
|
169
|
+
html[data-deck-transition="story"][data-deck-nav]::view-transition-new(
|
|
170
|
+
od-story-card-left
|
|
171
|
+
):only-child,
|
|
172
|
+
html[data-deck-transition="story"][data-deck-nav]::view-transition-new(
|
|
173
|
+
od-story-card-right
|
|
174
|
+
):only-child,
|
|
175
|
+
html[data-deck-transition="story"]::view-transition-new(od-story-head):only-child,
|
|
176
|
+
html[data-deck-transition="story"]::view-transition-new(od-story-card-left):only-child,
|
|
177
|
+
html[data-deck-transition="story"]::view-transition-new(od-story-card-right):only-child {
|
|
178
|
+
animation-name: od-vt-fade;
|
|
179
|
+
animation-duration: 140ms;
|
|
180
|
+
animation-delay: 0ms;
|
|
181
|
+
}
|
|
182
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
@import "./styles/index.css";
|