@lettercamp/cli 0.1.6 → 0.1.8
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 +3 -1
- package/dist/account.js +189 -0
- package/dist/build.js +24 -9
- package/dist/cli.js +35 -5
- package/dist/code-block.js +50 -0
- package/dist/code-detection.js +24 -0
- package/dist/code-highlight.js +54 -0
- package/dist/custom-layout.js +32 -0
- package/dist/deploy.js +131 -0
- package/dist/dev.js +52 -15
- package/dist/domain.js +190 -0
- package/dist/hosting.js +132 -0
- package/dist/lettercamp.js +2 -2
- package/dist/media-dimensions.js +154 -0
- package/dist/new.js +1 -1
- package/dist/ports.js +31 -0
- package/dist/preview.js +48 -0
- package/dist/prompts.js +31 -0
- package/dist/publication-links.js +23 -0
- package/dist/react.js +15 -0
- package/dist/reading-time.js +25 -0
- package/dist/upload.js +57 -0
- package/dist/workspace.js +8 -3
- package/package.json +12 -2
- package/renderer/src/components/AuthorByline.astro +26 -0
- package/renderer/src/components/BlogHome.astro +37 -0
- package/renderer/src/components/Footer.astro +35 -0
- package/renderer/src/components/Header.astro +38 -0
- package/renderer/src/components/MobileMenuIcons.astro +7 -0
- package/renderer/src/components/PostCard.astro +25 -0
- package/renderer/src/components/SocialLink.astro +23 -0
- package/renderer/src/layouts/SiteLayout.astro +73 -27
- package/renderer/src/lib/analytics.ts +21 -0
- package/renderer/src/lib/author-dialog.ts +102 -0
- package/renderer/src/lib/authors.js +18 -0
- package/renderer/src/lib/block-widths.ts +30 -0
- package/renderer/src/lib/branding.js +15 -0
- package/renderer/src/lib/button.js +10 -0
- package/renderer/src/lib/category-routes.js +19 -0
- package/renderer/src/lib/code-block.ts +46 -0
- package/renderer/src/lib/fonts.js +33 -0
- package/renderer/src/lib/home-layout.ts +5 -0
- package/renderer/src/lib/image-radius.ts +5 -0
- package/renderer/src/lib/image-rounding.ts +28 -0
- package/renderer/src/lib/image-widths.ts +13 -0
- package/renderer/src/lib/metadata.js +47 -0
- package/renderer/src/lib/mobile-navigation.ts +76 -0
- package/renderer/src/lib/post-layout.ts +6 -0
- package/renderer/src/lib/post-share.ts +264 -0
- package/renderer/src/lib/post-toc.ts +69 -0
- package/renderer/src/lib/posts.js +40 -0
- package/renderer/src/lib/publication-url.js +14 -0
- package/renderer/src/lib/table-styles.ts +12 -0
- package/renderer/src/lib/urls.js +3 -0
- package/renderer/src/pages/[...slug].astro +50 -25
- package/renderer/src/pages/category/[tag].astro +16 -0
- package/renderer/src/pages/category/index.astro +4 -0
- package/renderer/src/pages/index.astro +10 -0
- package/renderer/src/styles/post-share.css +57 -0
- package/renderer/src/styles/site.css +352 -51
- package/renderer/src/layouts/Content.astro +0 -1
|
@@ -1,70 +1,371 @@
|
|
|
1
1
|
:root {
|
|
2
2
|
color-scheme: light;
|
|
3
|
-
font-family:
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
3
|
+
--font-family: 'Inter', Arial, Helvetica, sans-serif;
|
|
4
|
+
font-size: 100%;
|
|
5
|
+
--type-scale: 1;
|
|
6
|
+
--text-base: calc(1rem * var(--type-scale));
|
|
7
|
+
--text-title: calc(clamp(2rem, 3.5vw, 2.625rem) * var(--type-scale));
|
|
8
|
+
--text-card-title: calc(clamp(1.125rem, 1.4vw, 1.25rem) * var(--type-scale));
|
|
9
|
+
--text-h2: calc(var(--text-base) * 1.875);
|
|
10
|
+
--text-h3: calc(var(--text-base) * 1.5);
|
|
11
|
+
--text-h4: calc(var(--text-base) * 1.25);
|
|
12
|
+
--text-h5: calc(var(--text-base) * 1.125);
|
|
13
|
+
--text-summary: calc(var(--text-base) * .9375);
|
|
14
|
+
--text-small: calc(var(--text-base) * .875);
|
|
15
|
+
--text-label: calc(var(--text-base) * .8125);
|
|
16
|
+
--text-meta: calc(var(--text-base) * .75);
|
|
17
|
+
font-family: var(--font-family);
|
|
18
|
+
color: #111;
|
|
19
|
+
background: var(--site-background, #ffffff);
|
|
20
|
+
font-synthesis: weight style;
|
|
7
21
|
-webkit-font-smoothing: antialiased;
|
|
22
|
+
--muted: #666;
|
|
23
|
+
--text-secondary: #6f6e77;
|
|
24
|
+
--text-tertiary: #86848d;
|
|
25
|
+
--line: #f0f0f0;
|
|
26
|
+
--site-width: min(1280px, calc(100% - 64px));
|
|
8
27
|
}
|
|
9
28
|
* { box-sizing: border-box; }
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
a
|
|
29
|
+
[hidden] { display: none !important; }
|
|
30
|
+
body { margin: 0; font-size: var(--text-base); line-height: 1.65; }
|
|
31
|
+
a { color: inherit; text-underline-offset: .22em; }
|
|
32
|
+
button { font: inherit; color: inherit; cursor: pointer; }
|
|
33
|
+
a:focus-visible, button:focus-visible, summary:focus-visible { outline: 2px solid #111; outline-offset: 5px; border-radius: 3px; }
|
|
13
34
|
img { display: block; max-width: 100%; height: auto; }
|
|
14
|
-
|
|
15
|
-
.site-header {
|
|
16
|
-
.
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
.
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
.
|
|
35
|
+
h1, h2, h3, h4, h5, h6 { font-family: var(--heading-font, var(--font-family)); text-wrap: balance; overflow-wrap: anywhere; }
|
|
36
|
+
.site-header-inner, .footer-inner, .blog-home { width: var(--site-width); margin-inline: auto; }
|
|
37
|
+
.site-header { position: relative; z-index: 30; border: 0; background: var(--site-background, #ffffff); }
|
|
38
|
+
.site-header[data-header-position='fixed'] { position: sticky; top: 0; }
|
|
39
|
+
html:has(.site-header[data-header-position='fixed']) { scroll-padding-top: 80px; }
|
|
40
|
+
.site-header-inner { position: relative; min-height: 64px; display: flex; align-items: center; justify-content: space-between; gap: 24px; padding-block: 12px; }
|
|
41
|
+
@keyframes header-scroll-away { from { opacity: 1; transform: translateY(0); } to { opacity: 0; transform: translateY(-6px); } }
|
|
42
|
+
@media (prefers-reduced-motion: no-preference) {
|
|
43
|
+
@supports (animation-timeline: scroll()) {
|
|
44
|
+
.site-header[data-header-position='scroll']:not(:focus-within):not(:has(details[open])) .site-header-inner {
|
|
45
|
+
animation: header-scroll-away linear both;
|
|
46
|
+
animation-timeline: scroll(root block);
|
|
47
|
+
animation-range: 0px 64px;
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
.site-header .brand { min-width: 0; overflow-wrap: anywhere; }
|
|
52
|
+
.site-header .brand img { flex-shrink: 0; }
|
|
53
|
+
.brand { display: inline-flex; align-items: center; gap: 9px; font-size: calc(var(--text-base) * 1.0625); font-weight: 600; letter-spacing: -.45px; text-decoration: none; }
|
|
54
|
+
.brand img { width: 24px; height: 24px; }
|
|
55
|
+
.site-header nav { display: flex; flex-wrap: wrap; gap: 28px; font-size: var(--text-small); }
|
|
56
|
+
.site-header nav a { text-decoration: none; color: var(--muted); }
|
|
57
|
+
.site-header nav a[aria-current], .site-header nav a:hover { color: #111; }
|
|
58
|
+
.header-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 16px 28px; margin-left: auto; max-width: 100%; }
|
|
59
|
+
.header-primary { display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 5px 20px; border: 0; border-radius: 12px; background: var(--button-color, #111111); color: var(--button-text, #ffffff); font-size: var(--text-label); font-weight: 500; line-height: 1.4; text-decoration: none; overflow-wrap: anywhere; max-width: 100%; }
|
|
60
|
+
.site-header a.header-primary, .site-header a.header-primary:hover { color: var(--button-text, #ffffff); }
|
|
61
|
+
.header-primary:hover { filter: brightness(.9); }
|
|
62
|
+
.mobile-navigation { display: none; }
|
|
63
|
+
.mobile-menu-toggle { position: relative; display: grid; place-items: center; width: 44px; height: 44px; padding: 0; border: 0; list-style: none; cursor: pointer; background: transparent; }
|
|
64
|
+
.mobile-menu-toggle::-webkit-details-marker { display: none; }
|
|
65
|
+
.mobile-menu-toggle svg { grid-area: 1 / 1; width: 24px; height: 24px; transition: opacity 180ms ease, transform 180ms ease; }
|
|
66
|
+
.mobile-close-icon { opacity: 0; transform: rotate(-90deg) scale(.75); }
|
|
67
|
+
.mobile-navigation[open] .mobile-menu-icon { opacity: 0; transform: rotate(90deg) scale(.75); }
|
|
68
|
+
.mobile-navigation[open] .mobile-close-icon { opacity: 1; transform: rotate(0) scale(1); }
|
|
69
|
+
@keyframes mobile-menu-enter { from { opacity: 0; translate: 0 -6px; } to { opacity: 1; translate: 0 0; } }
|
|
70
|
+
@media (prefers-reduced-motion: reduce) {
|
|
71
|
+
.mobile-menu-toggle svg { transition: none; }
|
|
72
|
+
}
|
|
73
|
+
.blog-home { padding-block: 72px 100px; }
|
|
74
|
+
.blog-heading { margin-bottom: 18px; }
|
|
75
|
+
.blog-home:not(:has(> .category-selector:not([hidden]))) > .blog-heading { margin-bottom: 64px; }
|
|
76
|
+
.blog-heading h1 { margin-bottom: 0; }
|
|
77
|
+
.article-category { margin: 0 0 20px; }
|
|
78
|
+
.article-category a, .post-card-category { display: inline-flex; align-items: center; justify-content: center; padding: 4px 15px; border: 0; border-radius: 10px; background: #fafafa; color: var(--muted); font-size: var(--text-meta); font-weight: 500; line-height: 1.333333; text-decoration: none; }
|
|
79
|
+
h1 { font-size: var(--text-title); font-weight: 500; line-height: 1.15; letter-spacing: -.04em; margin: 0 0 22px; }
|
|
80
|
+
.description { color: var(--text-secondary); font-size: var(--text-base); line-height: 1.65; max-width: 660px; margin: 0; }
|
|
81
|
+
.category-selector { display: flex; flex-wrap: wrap; gap: 8px 24px; margin-block: 0 40px; }
|
|
82
|
+
.category-selector a { padding-block: 8px; color: var(--muted); font-size: var(--text-small); line-height: 1.5; text-decoration: none; transition: color .15s; }
|
|
83
|
+
.category-selector a:hover { color: #111; }
|
|
84
|
+
.category-selector a[aria-current='page'] { color: #111; font-weight: 500; }
|
|
85
|
+
.post-list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 64px 48px; }
|
|
86
|
+
.post-card { position: relative; isolation: isolate; min-width: 0; }
|
|
87
|
+
.post-card-link { color: inherit; text-decoration: none; }
|
|
88
|
+
.post-card-link::after { content: ''; position: absolute; inset: 0; z-index: 1; }
|
|
89
|
+
.post-card-link:focus-visible { outline: none; }
|
|
90
|
+
.post-card-link:focus-visible::after { outline: 2px solid currentColor; outline-offset: 6px; border-radius: 4px; }
|
|
91
|
+
.post-card-layout { display: flex; flex-direction: column; height: 100%; gap: 20px; text-decoration: none; }
|
|
92
|
+
.post-card-content { display: flex; flex-direction: column; flex: 1; min-width: 0; }
|
|
93
|
+
.post-card-meta { margin-top: auto; min-width: 0; }
|
|
94
|
+
.archive-date { display: none; }
|
|
95
|
+
.post-card-details { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 12px; margin-bottom: 12px; color: #8c8b93; font-size: var(--text-label); line-height: 1.4; }
|
|
96
|
+
.post-card-category { min-width: 0; overflow-wrap: anywhere; }
|
|
97
|
+
.post-card-date { white-space: nowrap; }
|
|
98
|
+
.post-card-cover { flex-shrink: 0; overflow: hidden; aspect-ratio: 1200 / 630; background: #f4f4f4; border: 1px solid var(--line); border-radius: calc(var(--image-short-side, 200px) * var(--image-radius, 0.02)); }
|
|
99
|
+
.post-card-cover img { width: 100%; height: 100%; object-fit: cover; transition: transform .25s ease; }
|
|
100
|
+
.post-card:has(.post-card-link:hover) .post-card-cover img { transform: scale(1.025); }
|
|
101
|
+
.image-placeholder { display: grid; place-items: center; height: 100%; font-size: calc(var(--text-base) * 1.625); letter-spacing: -.05em; color: #777; }
|
|
102
|
+
.post-card h3 { font-size: var(--text-card-title); font-weight: 500; line-height: 1.35; letter-spacing: -.025em; margin: 0 0 8px; text-wrap: pretty; }
|
|
103
|
+
.post-card p { font-size: var(--text-summary); line-height: 1.55; margin: 0; color: var(--text-secondary); }
|
|
104
|
+
.post-byline { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; margin-top: auto; padding-top: 24px; color: #8c8b93; font-size: var(--text-label); line-height: 1.4; }
|
|
105
|
+
.post-authors { display: inline-flex; align-items: center; flex-wrap: wrap; gap: 6px 8px; min-width: 0; }
|
|
106
|
+
.author-portraits { position: relative; z-index: 2; display: inline-flex; align-items: center; flex-shrink: 0; isolation: isolate; }
|
|
107
|
+
.author-portrait { position: relative; display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; width: 24px; height: 24px; border: 1px solid #fafafa; border-radius: 50%; background: #f1f1f2; }
|
|
108
|
+
.author-portraits .author-portrait + .author-portrait { margin-left: -8px; }
|
|
109
|
+
.author-portraits .author-portrait:hover { z-index: 1; }
|
|
110
|
+
.author-avatar { display: block; width: 100%; height: 100%; border-radius: 50%; object-fit: cover; }
|
|
111
|
+
.author-initials { color: #666; font-size: 9px; font-weight: 500; line-height: 1; }
|
|
112
|
+
.author-names { min-width: 0; overflow-wrap: anywhere; }
|
|
113
|
+
.author-more { position: relative; z-index: 2; display: inline; padding: 0; border: 0; background: transparent; color: inherit; font: inherit; text-decoration: underline; text-decoration-color: color-mix(in srgb, currentColor 40%, transparent); text-underline-offset: 3px; cursor: pointer; white-space: nowrap; }
|
|
114
|
+
.author-more:hover { color: var(--text-primary, #111); }
|
|
115
|
+
.author-more:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; border-radius: 3px; }
|
|
116
|
+
.authors-popover { position: fixed; inset: auto; width: min(240px, calc(100vw - 16px)); max-height: 320px; margin: 0; padding: 10px; overflow: auto; border: 1px solid #ebebeb; border-radius: 9px; background: #fafafa; color: #55545c; box-shadow: 0 4px 18px #00000017; font: 13px/1.4 var(--font-family); outline: none; }
|
|
117
|
+
.authors-popover::backdrop { background: transparent; }
|
|
118
|
+
.authors-popover-list { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; }
|
|
119
|
+
.authors-popover-author { display: flex; align-items: center; gap: 9px; min-width: 0; overflow-wrap: anywhere; }
|
|
120
|
+
.authors-popover-author .author-portrait { width: 24px; height: 24px; }
|
|
121
|
+
.authors-popover-author .author-initials { font-size: 10px; }
|
|
122
|
+
@media (prefers-reduced-motion: no-preference) {
|
|
123
|
+
.authors-popover:popover-open { animation: authors-popover-in 100ms ease-out; }
|
|
124
|
+
@keyframes authors-popover-in { from { opacity: 0; transform: translateY(2px); } to { opacity: 1; transform: translateY(0); } }
|
|
125
|
+
}
|
|
126
|
+
.post-byline time { white-space: nowrap; }
|
|
127
|
+
.reading-time { margin-left: auto; white-space: nowrap; }
|
|
128
|
+
[data-home-layout='rows'] .post-list { grid-template-columns: 1fr; }
|
|
129
|
+
[data-home-layout='rows'] .post-list .post-card-layout { display: grid; grid-template-columns: minmax(0, .86fr) minmax(0, 1.14fr); align-items: center; gap: 32px; }
|
|
130
|
+
[data-home-layout='rows'] .post-list .post-card h3 { font-size: var(--text-h3); }
|
|
131
|
+
.archive { margin-top: 104px; }
|
|
132
|
+
.archive > h2 { font-size: var(--text-h3); font-weight: 500; letter-spacing: -.025em; margin: 0 0 20px; }
|
|
133
|
+
.archive-list { display: grid; gap: 4px; }
|
|
134
|
+
.archive-list .post-card { margin-inline: -12px; padding-inline: 12px; border-radius: 6px; }
|
|
135
|
+
.archive-list .post-card:is(:hover, :focus-within) { background: #f7f7f8; }
|
|
136
|
+
.archive-list .post-card-layout { padding-block: 18px; }
|
|
137
|
+
.archive-list .post-card-cover, .archive-list .post-card-description { display: none; }
|
|
138
|
+
.archive-list .post-card-content { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .85fr); align-items: center; gap: 16px 32px; }
|
|
139
|
+
.archive-list .post-card-details { display: none; }
|
|
140
|
+
.archive-list h3 { grid-area: 1 / 1; font-size: var(--text-base); margin: 0; }
|
|
141
|
+
.archive-list .post-card-meta { grid-area: 1 / 2; display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 6px 16px; margin: 0; color: #8c8b93; font-size: var(--text-label); line-height: 1.4; }
|
|
142
|
+
.archive-list .archive-date { display: block; white-space: nowrap; }
|
|
143
|
+
.archive-list .post-byline { align-items: flex-end; min-width: 0; margin: 0; padding: 0; text-align: right; }
|
|
144
|
+
.archive-list .post-authors { justify-content: flex-end; }
|
|
145
|
+
.archive-list .author-portraits { display: none; }
|
|
146
|
+
.archive-list :is(.post-byline, .post-card-date) { font-size: var(--text-label); }
|
|
147
|
+
.empty-state { grid-column: 1 / -1; color: var(--muted); padding: 40px 0 70px; font-size: var(--text-base); }
|
|
148
|
+
.publication { width: min(760px, calc(100% - 48px)); margin: 60px auto 100px; }
|
|
149
|
+
.article-header { margin-bottom: 40px; }
|
|
150
|
+
.article-header h1 { font-weight: 700; }
|
|
151
|
+
.publication h1 { line-height: 1.2; }
|
|
152
|
+
.byline { display: flex; flex-wrap: wrap; gap: 8px 20px; margin-top: 26px; font-size: var(--text-label); color: var(--text-tertiary); }
|
|
153
|
+
.byline { align-items: center; }
|
|
154
|
+
.byline .post-byline { flex-direction: row; align-items: center; flex-wrap: nowrap; gap: 16px; max-width: 100%; padding: 0; margin: 0; overflow-x: auto; scrollbar-width: thin; white-space: nowrap; }
|
|
155
|
+
.byline .post-authors { flex-wrap: nowrap; flex-shrink: 0; white-space: nowrap; }
|
|
156
|
+
.byline .post-byline > time, .byline .reading-time { flex-shrink: 0; font-size: inherit; }
|
|
157
|
+
.byline .reading-time { margin-left: 0; }
|
|
31
158
|
.cover { margin: 0 0 44px; }
|
|
32
|
-
.cover img, .prose img
|
|
33
|
-
.prose {
|
|
159
|
+
.cover img, .prose img, .article-hero-image img { background-color: #fafafa; }
|
|
160
|
+
.cover img, .prose img:not([width]) { width: 100%; border-radius: calc(var(--image-short-side, 200px) * var(--image-radius, 0.02)); }
|
|
161
|
+
.prose img { display: block; max-width: 100%; height: auto; margin: 32px auto; border-radius: calc(var(--image-short-side, 200px) * var(--image-radius, 0.02)); }
|
|
162
|
+
.prose img[data-media-sized] { width: 100%; }
|
|
163
|
+
.prose :is(img, video):not([width][height]) { aspect-ratio: auto 16 / 9; }
|
|
164
|
+
.prose video { display: block; max-width: 100%; height: auto; background: #fafafa; }
|
|
165
|
+
.prose video:not([width]) { width: 100%; }
|
|
166
|
+
.prose audio { width: min(100%, 560px); height: 54px; }
|
|
167
|
+
.publication-post { width: var(--site-width); }
|
|
168
|
+
.article-hero { margin-bottom: 64px; padding-bottom: 64px; border-bottom: 1px solid var(--line); }
|
|
169
|
+
.article-hero-with-image { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: center; gap: 64px; }
|
|
170
|
+
.article-intro { min-width: 0; }
|
|
171
|
+
.article-hero .article-intro { max-width: 760px; }
|
|
172
|
+
.article-hero-image { margin: 0; }
|
|
173
|
+
.article-hero-image img { width: 100%; border-radius: calc(var(--image-short-side, 200px) * var(--image-radius, 0.02)); }
|
|
174
|
+
.publication-post { --post-content-width: calc(var(--text-base) * 40); }
|
|
175
|
+
.publication-post[data-post-cover='hidden'] .article-hero-image, .publication-post[data-post-toc='hidden'] .article-sidebar { display: none; }
|
|
176
|
+
.publication-post[data-post-cover='hidden'] .article-hero, .publication-post[data-post-hero='stacked'] .article-hero { display: block; }
|
|
177
|
+
.publication-post[data-post-toc='hidden'] .article-body { display: block; max-width: var(--post-content-width); }
|
|
178
|
+
.article-body { max-width: var(--post-content-width, 640px); margin-inline: auto; }
|
|
179
|
+
.article-body-with-toc { display: grid; grid-template-columns: 180px minmax(0, var(--post-content-width, 640px)); align-items: start; gap: 32px; max-width: calc(var(--post-content-width, 640px) + 212px); }
|
|
180
|
+
.article-sidebar { min-width: 0; position: sticky; top: 32px; max-height: calc(100dvh - 64px); overflow-y: auto; }
|
|
181
|
+
.article-toc { padding: 4px 0 6px; }
|
|
182
|
+
.article-toc h2 { font-family: var(--font-family); margin: 0 0 20px; font-size: var(--text-label); font-weight: 600; letter-spacing: 0; }
|
|
183
|
+
.article-toc ol { list-style: none; margin: 0; padding: 0; }
|
|
184
|
+
.article-toc li + li { margin-top: 14px; }
|
|
185
|
+
.article-toc a { display: block; font-size: var(--text-label); line-height: 1.6; color: var(--muted); text-decoration: none; overflow-wrap: anywhere; }
|
|
186
|
+
.article-toc a:hover { color: #111; text-decoration: underline; }
|
|
187
|
+
.article-toc .toc-subheading { padding-left: 16px; }
|
|
188
|
+
.article-body .prose { min-width: 0; }
|
|
189
|
+
.prose :is(h2, h3, h4, h5, h6) { scroll-margin-top: 32px; }
|
|
190
|
+
.prose { font-size: var(--text-base); line-height: var(--body-line-height, 1.8); overflow-wrap: anywhere; }
|
|
34
191
|
.prose > :first-child { margin-top: 0; }
|
|
35
192
|
.prose p { margin: 1.3em 0; }
|
|
36
|
-
.prose h2 { font:
|
|
37
|
-
.prose h3 { font:
|
|
38
|
-
.prose h4 { font:
|
|
193
|
+
.prose h2 { font-size: var(--text-h2); line-height: 1.3; font-weight: 600; letter-spacing: -.04em; margin: 2em 0 .7em; }
|
|
194
|
+
.prose h3 { font-size: var(--text-h3); line-height: 1.4; font-weight: 600; letter-spacing: -.03em; margin: 1.7em 0 .6em; }
|
|
195
|
+
.prose h4 { font-size: var(--text-h4); line-height: 1.5; font-weight: 600; margin: 1.6em 0 .5em; }
|
|
196
|
+
.prose h5 { font-size: var(--text-h5); line-height: 1.5; }
|
|
197
|
+
.prose h6 { font-size: var(--text-base); line-height: 1.5; }
|
|
39
198
|
.prose h3 a { text-decoration: none; }
|
|
40
199
|
.prose h3 a:hover { text-decoration: underline; }
|
|
41
200
|
.prose ul, .prose ol { padding-left: 1.4em; }
|
|
42
201
|
.prose li { padding-left: .2em; margin: .5em 0; }
|
|
43
|
-
.prose
|
|
202
|
+
.prose .task-list-item:has(> input[type="checkbox"]:checked, > p > input[type="checkbox"]:checked) { text-decoration: line-through; }
|
|
203
|
+
.prose blockquote { border-left: 2px solid var(--line); padding: 4px 0 4px 26px; margin: 36px 0; color: #555; font-size: calc(var(--text-base) * 1.15); line-height: 1.55; }
|
|
44
204
|
.prose blockquote p { margin: .3em 0; }
|
|
45
|
-
.prose hr { border: 0; height: 1px; background:
|
|
46
|
-
.prose pre { padding: 24px; overflow: auto; border-radius:
|
|
205
|
+
.prose hr { border: 0; height: 1px; background: var(--line); margin: 42px 0; }
|
|
206
|
+
.prose pre { padding: 24px; overflow: auto; border-radius: 5px; font-size: var(--text-small); line-height: 1.8; }
|
|
47
207
|
.prose code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .85em; }
|
|
48
|
-
.prose :not(pre) > code { padding: .18em .35em; background: #
|
|
49
|
-
.
|
|
50
|
-
.
|
|
51
|
-
.card
|
|
52
|
-
.card
|
|
53
|
-
.
|
|
54
|
-
.prose .card
|
|
55
|
-
.card
|
|
56
|
-
.
|
|
57
|
-
.site-footer
|
|
58
|
-
.
|
|
208
|
+
.prose :not(pre) > code { padding: .18em .35em; background: #f3f3f3; border-radius: 3px; }
|
|
209
|
+
.prose span[style*="background-color"] code { background-color: inherit; }
|
|
210
|
+
.cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin: 32px 0; }
|
|
211
|
+
.card { display: flex; flex-direction: column; align-items: start; padding: 26px; border-radius: 6px; background: #f6f6f6; text-decoration: none; }
|
|
212
|
+
.card:hover { background: #eee; }
|
|
213
|
+
.card-eyebrow { font-size: calc(var(--text-base) * .6875); text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
|
|
214
|
+
.prose .card h3 { font-size: calc(var(--text-base) * 1.375); margin: 12px 0 6px; }
|
|
215
|
+
.prose .card p { font-size: var(--text-summary); line-height: 1.7; color: var(--muted); margin: 0 0 20px; }
|
|
216
|
+
.card-link { font-size: var(--text-label); font-weight: 600; margin-top: auto; }
|
|
217
|
+
.site-footer { border-top: 1px solid var(--line); }
|
|
218
|
+
.footer-inner { padding-block: 64px 80px; }
|
|
219
|
+
.footer-main { display: grid; grid-template-columns: repeat(calc(var(--footer-columns) + 1), minmax(0, 1fr)); align-items: start; gap: 32px; }
|
|
220
|
+
.footer-brand { min-width: 0; }
|
|
221
|
+
.footer-brand .brand { font-size: var(--text-small); }
|
|
222
|
+
.footer-brand .brand img { width: 24px; height: 24px; }
|
|
223
|
+
.footer-columns { grid-column: 2 / -1; display: grid; grid-template-columns: repeat(var(--footer-columns), minmax(0, 1fr)); gap: 32px; }
|
|
224
|
+
.footer-column h2 { font-family: var(--font-family); font-size: var(--text-small); line-height: 1.85; font-weight: 500; margin: 0 0 24px; overflow-wrap: anywhere; }
|
|
225
|
+
.footer-column ul { display: grid; gap: 8px; padding: 0; margin: 0; list-style: none; font-size: var(--text-small); }
|
|
226
|
+
.footer-column a { display: inline-block; color: var(--muted); font-size: var(--text-small); line-height: 1.7; text-decoration: none; overflow-wrap: anywhere; }
|
|
227
|
+
.footer-column li { line-height: 1.7; }
|
|
228
|
+
.site-footer a:hover { color: #111; }
|
|
229
|
+
.footer-bottom { display: flex; align-items: center; flex-wrap: wrap; gap: 16px 24px; margin-top: 64px; color: var(--muted); font-size: var(--text-small); }
|
|
230
|
+
.footer-bottom a { text-decoration: none; }
|
|
231
|
+
.footer-credit { margin-left: auto; opacity: .65; }
|
|
232
|
+
.footer-credit:is(:hover, :focus-visible) { opacity: 1; }
|
|
233
|
+
.footer-socials { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
|
|
234
|
+
.footer-socials a { display: inline-flex; align-items: center; justify-content: center; min-width: 28px; min-height: 28px; }
|
|
235
|
+
.footer-socials svg { width: 18px; height: 18px; }
|
|
236
|
+
.skip-link { position: absolute; left: 20px; top: -100px; padding: 10px 15px; background: #111; color: white; z-index: 10; }
|
|
59
237
|
.skip-link:focus { top: 15px; }
|
|
238
|
+
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
|
|
239
|
+
@media (max-width: 900px) {
|
|
240
|
+
:root { --site-width: calc(100% - 48px); }
|
|
241
|
+
.post-list { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 48px 32px; }
|
|
242
|
+
.article-hero-with-image { gap: 32px; }
|
|
243
|
+
.article-body-with-toc { grid-template-columns: 180px minmax(0, 1fr); gap: 32px; }
|
|
244
|
+
.footer-main { grid-template-columns: 1fr; gap: 32px; }
|
|
245
|
+
.footer-columns { grid-column: 1; grid-template-columns: repeat(var(--footer-tablet-columns), minmax(0, 1fr)); gap: 40px 32px; }
|
|
246
|
+
}
|
|
247
|
+
@media (max-width: 760px) {
|
|
248
|
+
.article-hero-with-image, .article-body-with-toc { grid-template-columns: minmax(0, 1fr); }
|
|
249
|
+
.article-hero { margin-bottom: 36px; padding-bottom: 36px; }
|
|
250
|
+
.publication-post .article-sidebar { display: none; }
|
|
251
|
+
}
|
|
60
252
|
@media (max-width: 600px) {
|
|
61
|
-
.site-header
|
|
62
|
-
.site-header {
|
|
63
|
-
.brand {
|
|
64
|
-
|
|
65
|
-
.
|
|
66
|
-
.
|
|
67
|
-
.
|
|
253
|
+
.site-header-inner { width: auto; margin-inline: 24px 10px; min-height: 64px; padding-block: 10px; gap: 12px; }
|
|
254
|
+
.site-header .brand { flex: 1; overflow: hidden; }
|
|
255
|
+
.site-header .brand span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
|
|
256
|
+
.header-actions { flex: none; flex-wrap: nowrap; gap: 8px; }
|
|
257
|
+
.site-header .desktop-navigation { display: none; }
|
|
258
|
+
.header-actions > .header-primary { display: block; max-width: min(42vw, 200px); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
|
|
259
|
+
.mobile-navigation { display: block; position: static; }
|
|
260
|
+
.site-header .mobile-menu-panel { position: fixed; inset: var(--mobile-menu-top, 64px) 0 0; z-index: 5; display: flex; flex-direction: column; flex-wrap: nowrap; align-items: stretch; gap: 4px; width: 100%; margin: 0; padding: 24px 24px max(32px, env(safe-area-inset-bottom)); overflow-y: auto; overscroll-behavior: contain; background: var(--site-background, #ffffff); }
|
|
261
|
+
.mobile-menu-panel a { flex: none; padding: 12px 0; font-size: var(--text-base); line-height: 1.4; overflow-wrap: anywhere; }
|
|
262
|
+
@media (prefers-reduced-motion: no-preference) { .mobile-navigation[open] .mobile-menu-panel { animation: mobile-menu-enter 180ms ease-out; } }
|
|
263
|
+
.blog-home { padding-block: 46px 64px; }
|
|
264
|
+
.blog-home:not(:has(> .category-selector:not([hidden]))) > .blog-heading { margin-bottom: 40px; }
|
|
265
|
+
.category-selector { margin-bottom: 36px; gap: 4px 20px; }
|
|
266
|
+
.post-list { grid-template-columns: 1fr; gap: 48px; }
|
|
267
|
+
[data-home-layout='rows'] .post-list .post-card-layout { display: flex; align-items: stretch; gap: 20px; }
|
|
268
|
+
[data-home-layout='rows'] .post-list .post-card h3 { font-size: var(--text-h4); }
|
|
269
|
+
.archive { margin-top: 72px; }
|
|
270
|
+
.publication { margin-top: 36px; }
|
|
68
271
|
.cards { grid-template-columns: 1fr; }
|
|
69
|
-
.
|
|
272
|
+
.footer-columns { grid-template-columns: repeat(var(--footer-mobile-columns), minmax(0, 1fr)); gap: 32px 24px; }
|
|
273
|
+
.footer-inner { padding-block: 40px 56px; }
|
|
274
|
+
.footer-bottom { margin-top: 48px; }
|
|
275
|
+
.footer-bottom { gap: 18px; }
|
|
276
|
+
}
|
|
277
|
+
.article-toc a { display: block; container-type: inline-size; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; overflow-wrap: normal; }
|
|
278
|
+
.article-toc .toc-label { display: inline; }
|
|
279
|
+
.article-toc a:is(:hover, :focus-visible) { text-overflow: clip; }
|
|
280
|
+
.article-toc a:is(:hover, :focus-visible) .toc-label { display: inline-block; min-width: 100%; animation: toc-scroll 6s linear infinite alternate; }
|
|
281
|
+
@keyframes toc-scroll {
|
|
282
|
+
0%, 15% { transform: translateX(0); }
|
|
283
|
+
85%, 100% { transform: translateX(min(0px, calc(100cqi - 100%))); }
|
|
284
|
+
}
|
|
285
|
+
@media (prefers-reduced-motion: reduce) {
|
|
286
|
+
.article-toc a:is(:hover, :focus-visible) { white-space: normal; overflow-wrap: anywhere; }
|
|
287
|
+
.article-toc a:is(:hover, :focus-visible) .toc-label { display: inline; animation: none; }
|
|
288
|
+
}
|
|
289
|
+
/* Vertical posts share one reading column from the headline through the body. */
|
|
290
|
+
.publication-post[data-post-hero='stacked'] { margin-top: 48px; }
|
|
291
|
+
.publication-post[data-post-hero='stacked'] .article-hero { margin-bottom: 40px; padding-bottom: 0; border-bottom: 0; }
|
|
292
|
+
.publication-post[data-post-hero='stacked'] .article-intro { max-width: var(--post-content-width); margin-inline: auto; text-align: left; }
|
|
293
|
+
.publication-post[data-post-hero='stacked'] h1 { margin-bottom: 0; line-height: 1.12; }
|
|
294
|
+
.publication-post[data-post-hero='stacked'] .article-intro .description { margin: 16px 0 0; }
|
|
295
|
+
.publication-post[data-post-hero='stacked'] .byline { justify-content: flex-start; margin-top: 24px; }
|
|
296
|
+
.publication-post[data-post-hero='stacked'] .byline :is(.post-byline, .post-authors) { justify-content: flex-start; }
|
|
297
|
+
.publication-post[data-post-hero='stacked'] .article-hero-image { margin: 32px auto 0; }
|
|
298
|
+
.publication-post[data-post-hero='stacked'] .article-hero-image img { border-radius: calc(var(--image-short-side, 200px) * var(--image-radius, 0.02)); }
|
|
299
|
+
.publication-post[data-post-hero='stacked'] .article-body { display: block; max-width: var(--post-content-width); }
|
|
300
|
+
.publication-post[data-post-hero='stacked'] .article-sidebar { position: static; max-height: none; overflow: visible; margin: 0 0 32px; padding: 0; border: 0; }
|
|
301
|
+
.toc-trigger { display: none; }
|
|
302
|
+
.publication-post[data-post-hero='stacked'] .article-sidebar[data-floating-toc] { position: fixed; z-index: 20; left: 8px; top: 50%; transform: translateY(-50%); margin: 0; }
|
|
303
|
+
.publication-post[data-post-hero='stacked'] .toc-trigger { display: flex; flex-direction: column; align-items: center; gap: 0; max-height: min(60dvh, 320px); overflow: hidden; width: 28px; padding: 8px 6px; border: 0; border-radius: 6px; background: transparent; color: #414146; cursor: pointer; }
|
|
304
|
+
.toc-trigger span { position: relative; display: block; flex: none; width: 16px; height: 12px; }
|
|
305
|
+
.toc-trigger span::after { content: ''; position: absolute; left: 0; top: 5px; width: 100%; height: 2px; border-radius: 2px; background: currentColor; opacity: .3; transform: scaleX(.5); transform-origin: left center; transition: transform 140ms ease-out, opacity 140ms ease-out; }
|
|
306
|
+
.toc-trigger:is([aria-expanded='true'], :hover, :focus-visible) span::after { opacity: .38; transform: scaleX(.5625); }
|
|
307
|
+
.toc-trigger span[data-active]::after, .toc-trigger:is([aria-expanded='true'], :hover, :focus-visible) span[data-active]::after { opacity: .5; transform: scaleX(.625); }
|
|
308
|
+
.toc-trigger:is([aria-expanded='true'], :hover, :focus-visible) span:hover::after { opacity: 1; transform: scaleX(1); }
|
|
309
|
+
.toc-trigger:focus-visible { outline: 2px solid #b8b8c0; outline-offset: 1px; }
|
|
310
|
+
.publication-post[data-post-hero='stacked'] [data-floating-toc] .article-toc { visibility: hidden; opacity: 0; position: absolute; left: 100%; top: 50%; transform: translate(-4px, -50%) scale(.98); transform-origin: left center; width: min(240px, calc(100vw - 60px)); max-height: calc(100dvh - 48px); overflow-y: auto; overscroll-behavior: contain; padding: 5px; margin-left: 6px; border: 0; border-radius: 9px; background: var(--site-background, #fff); box-shadow: 0 6px 18px rgb(0 0 0 / 2%), 0 3px 9px rgb(0 0 0 / 4%), 0 1px 1px rgb(0 0 0 / 4%); transition: opacity 120ms ease-out, transform 140ms ease-out; }
|
|
311
|
+
.publication-post[data-post-hero='stacked'] [data-floating-toc]::after { content: ''; position: absolute; left: 100%; top: 0; width: 6px; height: 100%; }
|
|
312
|
+
.publication-post[data-post-hero='stacked'] [data-toc-open] .article-toc { visibility: visible; opacity: 1; transform: translate(0, -50%) scale(1); }
|
|
313
|
+
.publication-post[data-post-hero='stacked'] [data-floating-toc] .article-toc h2 { margin: 0 0 3px; padding: 6px 8px 4px; color: #87878e; font-size: 11px; line-height: 16px; font-weight: 500; letter-spacing: 0; text-transform: none; }
|
|
314
|
+
.publication-post[data-post-hero='stacked'] [data-floating-toc] .article-toc li + li { margin-top: 4px; }
|
|
315
|
+
.publication-post[data-post-hero='stacked'] [data-floating-toc] .article-toc a { padding: 5px 8px; border-radius: 5px; color: #414146; font-size: var(--text-label); line-height: 1.4; white-space: normal; overflow-wrap: anywhere; text-decoration: none; transition: background-color 120ms ease; }
|
|
316
|
+
.publication-post[data-post-hero='stacked'] [data-floating-toc] .article-toc a[aria-current='location'] { color: #303034; font-weight: 500; background: color-mix(in srgb, var(--site-background, #fff), #000 5%); }
|
|
317
|
+
.publication-post[data-post-hero='stacked'] [data-floating-toc] .article-toc a:is(:hover, :focus-visible) { background: #fafafa; outline: none; }
|
|
318
|
+
.publication-post[data-post-hero='stacked'] [data-floating-toc] .toc-label { display: inline; animation: none; }
|
|
319
|
+
@media (prefers-reduced-motion: reduce) {
|
|
320
|
+
.toc-trigger span::after, .publication-post[data-post-hero='stacked'] [data-floating-toc] .article-toc, .publication-post[data-post-hero='stacked'] [data-floating-toc] .article-toc a { transition: none; }
|
|
321
|
+
}
|
|
322
|
+
.article-toc a[aria-current='location'] { color: #111; font-weight: 500; }
|
|
323
|
+
@media (min-width: 1200px) {
|
|
324
|
+
.publication-post[data-post-hero='split'][data-post-toc='visible'] .article-body-with-toc { grid-template-columns: minmax(180px, 1fr) minmax(0, var(--post-content-width)) minmax(180px, 1fr); max-width: none; }
|
|
325
|
+
.publication-post[data-post-hero='split'] .article-sidebar { width: 180px; }
|
|
326
|
+
}
|
|
327
|
+
@media (max-width: 900px) {
|
|
328
|
+
/* Keep the floating control clear of the reading column on small screens. */
|
|
329
|
+
.publication-post[data-post-hero='stacked'] .article-sidebar[data-floating-toc] { left: 0; }
|
|
330
|
+
.publication-post[data-post-hero='stacked'] .toc-trigger { width: 20px; padding-inline: 2px; }
|
|
331
|
+
}
|
|
332
|
+
@media (max-width: 600px) {
|
|
333
|
+
.publication-post[data-post-hero='stacked'] { margin-top: 32px; }
|
|
334
|
+
.publication-post[data-post-hero='stacked'] .article-hero { margin-bottom: 32px; }
|
|
335
|
+
.publication-post[data-post-hero='stacked'] .byline { gap: 8px 16px; margin-top: 20px; }
|
|
336
|
+
}
|
|
337
|
+
@media (prefers-reduced-motion: reduce) {
|
|
338
|
+
*, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
|
|
70
339
|
}
|
|
340
|
+
|
|
341
|
+
.prose figure { margin: 1.3em 0; }
|
|
342
|
+
.prose figure:has(img) { margin-block: 32px; }
|
|
343
|
+
.prose figure img, .prose figure > p:has(img) { margin-block: 0; }
|
|
344
|
+
.prose figure :is(img, video, audio) { display: block; max-width: 100%; }
|
|
345
|
+
.prose figure > a { display: block; }
|
|
346
|
+
.prose figcaption { margin-top: 4px; color: var(--muted, #777); font-size: 13px; line-height: 1.5; text-align: center; }
|
|
347
|
+
.prose figcaption p { margin: 0; }
|
|
348
|
+
|
|
349
|
+
/* Homepage width and container-responsive layouts. */
|
|
350
|
+
|
|
351
|
+
.blog-home { container: home-layout / inline-size; width: min(var(--home-content-width, 1280px), calc(100% - 64px)); }
|
|
352
|
+
@media (max-width: 900px) {
|
|
353
|
+
.blog-home { width: min(var(--home-content-width, 1280px), calc(100% - 48px)); }
|
|
354
|
+
}
|
|
355
|
+
@container home-layout (max-width: 852px) {
|
|
356
|
+
.archive-list .post-card-content { grid-template-columns: minmax(0, 1fr); align-items: start; gap: 10px; }
|
|
357
|
+
.archive-list h3 { grid-area: 1 / 1; }
|
|
358
|
+
.archive-list .post-card-meta { grid-area: 2 / 1; }
|
|
359
|
+
[data-home-layout='grid'] .post-list { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 48px 32px; }
|
|
360
|
+
}
|
|
361
|
+
@container home-layout (max-width: 552px) {
|
|
362
|
+
[data-home-layout='grid'] .post-list { grid-template-columns: 1fr; gap: 48px; }
|
|
363
|
+
[data-home-layout='grid'] .archive-list .post-card-layout { padding-block: 12px; }
|
|
364
|
+
[data-home-layout='grid'] .archive-list .post-card-content { grid-template-columns: minmax(0, 1fr) 14px; align-items: center; gap: 12px; }
|
|
365
|
+
[data-home-layout='grid'] .archive-list .post-card-meta { display: none; }
|
|
366
|
+
[data-home-layout='grid'] .archive-list h3 { min-width: 0; overflow: hidden; white-space: nowrap; text-wrap: nowrap; text-overflow: ellipsis; font-family: var(--font-family); font-size: var(--text-summary); font-weight: 400; letter-spacing: normal; line-height: 1.55; }
|
|
367
|
+
[data-home-layout='grid'] .archive-list .post-card-content::after { content: ''; grid-area: 1 / 2; justify-self: center; width: 6px; height: 6px; border-top: 1.5px solid #c5c5ca; border-right: 1.5px solid #c5c5ca; transform: rotate(45deg); pointer-events: none; }
|
|
368
|
+
[data-home-layout='rows'] .post-list .post-card-layout { display: flex; align-items: stretch; gap: 20px; }
|
|
369
|
+
[data-home-layout='rows'] .post-list .post-card h3 { font-size: var(--text-h4); }
|
|
370
|
+
|
|
371
|
+
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
<slot />
|