@aitrien/motifspec 1.13.0 → 1.13.3
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/CHANGELOG.md +275 -257
- package/LICENSE +21 -21
- package/README.md +128 -150
- package/dist/backdrop.html +1 -1
- package/dist/chroma.css +36 -36
- package/dist/codex.css +1145 -1145
- package/dist/codex.js +126 -126
- package/dist/contrast.md +101 -101
- package/dist/fonts.css +3 -3
- package/dist/icons.svg +18 -18
- package/dist/plate.html +1 -1
- package/dist/plate.js +292 -292
- package/dist/theme-init.js +1 -1
- package/dist/tokens.css +466 -466
- package/dist/tokens.js +3330 -3330
- package/dist/tokens.json +3330 -3330
- package/docs/components/_template.md +37 -37
- package/docs/components/accession-label.md +106 -106
- package/docs/components/backdrop.md +83 -83
- package/docs/components/button-and-link.md +87 -87
- package/docs/components/callout.md +75 -75
- package/docs/components/code-block.md +109 -109
- package/docs/components/data-table.md +73 -73
- package/docs/components/figure.md +68 -68
- package/docs/components/heading-anchor.md +76 -76
- package/docs/components/icon.md +63 -63
- package/docs/components/ornament.md +77 -77
- package/docs/components/pagination.md +78 -78
- package/docs/components/post-list-item.md +91 -91
- package/docs/components/project-card.md +82 -82
- package/docs/components/prose.md +122 -122
- package/docs/components/site-footer.md +99 -99
- package/docs/components/site-header.md +133 -133
- package/docs/components/specimen-plate.md +92 -92
- package/docs/components/table-of-contents.md +83 -83
- package/docs/components/tag.md +70 -70
- package/docs/components/tooltip.md +67 -67
- package/docs/hugo.md +132 -120
- package/docs/syntax-highlighting.md +55 -55
- package/docs/templates.md +21 -30
- package/fonts/OFL-jetbrains-mono.txt +93 -93
- package/fonts/OFL-national-park.txt +93 -93
- package/fonts/OFL-yarndings-12.txt +93 -93
- package/icons/LICENSE +202 -202
- package/icons/manifest.json +75 -75
- package/layouts/_markup/render-blockquote.html +30 -30
- package/layouts/_markup/render-codeblock.html +18 -18
- package/layouts/_markup/render-heading.html +2 -2
- package/layouts/_markup/render-image.html +14 -14
- package/layouts/_markup/render-link.html +14 -14
- package/layouts/_markup/render-table.html +31 -31
- package/layouts/_partials/motifspec/accession/id.html +2 -2
- package/layouts/_partials/motifspec/accession/label.html +18 -18
- package/layouts/_partials/motifspec/accession/status.html +2 -2
- package/layouts/_partials/motifspec/article.html +24 -24
- package/layouts/_partials/motifspec/back-link.html +2 -2
- package/layouts/_partials/motifspec/body-end.html +5 -5
- package/layouts/_partials/motifspec/body-start.html +5 -5
- package/layouts/_partials/motifspec/figure.html +14 -14
- package/layouts/_partials/motifspec/filed-under.html +5 -5
- package/layouts/_partials/motifspec/h2s.html +7 -7
- package/layouts/_partials/motifspec/head.html +15 -15
- package/layouts/_partials/motifspec/pagination-entries.html +34 -34
- package/layouts/_partials/motifspec/pagination-pages.html +30 -30
- package/layouts/_partials/motifspec/post-list-item.html +15 -15
- package/layouts/_partials/motifspec/project-card.html +23 -23
- package/layouts/_partials/motifspec/section-heading.html +3 -3
- package/layouts/_partials/motifspec/site-header.html +27 -27
- package/layouts/_partials/motifspec/table-of-contents.html +21 -21
- package/layouts/_partials/motifspec/tag-filter.html +22 -22
- package/layouts/_partials/motifspec/tags.html +8 -8
- package/layouts/_partials/motifspec/tokens.html +9 -9
- package/package.json +68 -68
- package/scripts/check.mjs +153 -153
- package/scripts/lib.mjs +176 -176
- package/tokens/README.md +3 -3
- package/tokens/border.json +63 -63
- package/tokens/color.json +1902 -1902
- package/tokens/motion.json +207 -207
- package/tokens/radius.json +53 -53
- package/tokens/size.json +378 -378
- package/tokens/space.json +289 -289
- package/tokens/typography.json +859 -859
|
@@ -1,91 +1,91 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: post-list-item
|
|
3
|
-
status: stable
|
|
4
|
-
tokens:
|
|
5
|
-
- border.focus.offset
|
|
6
|
-
- border.focus.width
|
|
7
|
-
- border.width.hairline
|
|
8
|
-
- color.border.default
|
|
9
|
-
- color.border.subtle
|
|
10
|
-
- color.focus.ring
|
|
11
|
-
- color.surface.hover
|
|
12
|
-
- color.text.accent
|
|
13
|
-
- color.text.muted
|
|
14
|
-
- color.text.primary
|
|
15
|
-
- color.text.secondary
|
|
16
|
-
- font.family.mono
|
|
17
|
-
- font.line-height.heading
|
|
18
|
-
- font.line-height.ui
|
|
19
|
-
- font.size.heading-4
|
|
20
|
-
- font.size.label
|
|
21
|
-
- font.size.small
|
|
22
|
-
- font.tracking.heading
|
|
23
|
-
- font.tracking.ui
|
|
24
|
-
- font.weight.heading
|
|
25
|
-
- font.weight.ui
|
|
26
|
-
- motion.duration.fast
|
|
27
|
-
- motion.easing.standard
|
|
28
|
-
- size.column.card
|
|
29
|
-
- size.column.sidebar
|
|
30
|
-
- size.measure.prose
|
|
31
|
-
- space.inline.lg
|
|
32
|
-
- space.inline.xs
|
|
33
|
-
- space.inset.md
|
|
34
|
-
- space.inset.sm
|
|
35
|
-
- space.stack.lg
|
|
36
|
-
- space.stack.sm
|
|
37
|
-
- space.stack.xs
|
|
38
|
-
---
|
|
39
|
-
|
|
40
|
-
# Post list item
|
|
41
|
-
|
|
42
|
-
One ledger row in a list of writing: catalogue number, date and reading time beside the title, summary and tags.
|
|
43
|
-
|
|
44
|
-
## When to use
|
|
45
|
-
|
|
46
|
-
- On the writing index, grouped under year headings (`cx-posts__year`).
|
|
47
|
-
- For "Recent writing" on the home page (five rows, no year heading).
|
|
48
|
-
- For any dated, text-first list: changelogs, release notes, recipes by date.
|
|
49
|
-
|
|
50
|
-
## When not to use
|
|
51
|
-
|
|
52
|
-
- For projects with thumbnails; use `project-card`.
|
|
53
|
-
- For navigation between adjacent posts; use `pagination`.
|
|
54
|
-
|
|
55
|
-
## Markup
|
|
56
|
-
|
|
57
|
-
```html preview
|
|
58
|
-
<h2 class="cx-posts__year">2026</h2>
|
|
59
|
-
<ol class="cx-posts" reversed>
|
|
60
|
-
<li class="cx-post">
|
|
61
|
-
<p class="cx-post__meta">
|
|
62
|
-
<span class="cx-id__no">LM-P-031</span>
|
|
63
|
-
<time datetime="2026-10-02">2026-10-02</time>
|
|
64
|
-
<span>6 min</span>
|
|
65
|
-
</p>
|
|
66
|
-
<div class="cx-post__main">
|
|
67
|
-
<h3 class="cx-post__title"><a href="/writing/tokens-over-mcp/">Serving design tokens to AI assistants over MCP</a></h3>
|
|
68
|
-
<p class="cx-post__summary">Why every token carries a usage rule.</p>
|
|
69
|
-
<ul class="cx-tags"><li><a class="cx-tag" href="/tags/mcp/">mcp</a></li></ul>
|
|
70
|
-
</div>
|
|
71
|
-
</li>
|
|
72
|
-
</ol>
|
|
73
|
-
```
|
|
74
|
-
|
|
75
|
-
## Do
|
|
76
|
-
|
|
77
|
-
- Use `<ol reversed>`; newest first is an order the reader relies on.
|
|
78
|
-
- Keep the meta column to number, date and reading time, in that order.
|
|
79
|
-
- Write summaries as one plain sentence.
|
|
80
|
-
|
|
81
|
-
## Don't
|
|
82
|
-
|
|
83
|
-
- Don't add thumbnails; rows must scan as a column of titles.
|
|
84
|
-
- Don't truncate titles with ellipses. Let them wrap.
|
|
85
|
-
|
|
86
|
-
## Accessibility
|
|
87
|
-
|
|
88
|
-
- The title link's `::after` covers the row, so the whole row is clickable while only one link is announced.
|
|
89
|
-
- Focus on the title draws the ring around the row.
|
|
90
|
-
- Dates use `<time datetime>`.
|
|
91
|
-
- Pairs: `color.text.accent` number on `color.surface.base` (4.5:1); `color.text.muted` meta (4.5:1); `color.text.primary` title on `color.surface.hover` (7:1).
|
|
1
|
+
---
|
|
2
|
+
name: post-list-item
|
|
3
|
+
status: stable
|
|
4
|
+
tokens:
|
|
5
|
+
- border.focus.offset
|
|
6
|
+
- border.focus.width
|
|
7
|
+
- border.width.hairline
|
|
8
|
+
- color.border.default
|
|
9
|
+
- color.border.subtle
|
|
10
|
+
- color.focus.ring
|
|
11
|
+
- color.surface.hover
|
|
12
|
+
- color.text.accent
|
|
13
|
+
- color.text.muted
|
|
14
|
+
- color.text.primary
|
|
15
|
+
- color.text.secondary
|
|
16
|
+
- font.family.mono
|
|
17
|
+
- font.line-height.heading
|
|
18
|
+
- font.line-height.ui
|
|
19
|
+
- font.size.heading-4
|
|
20
|
+
- font.size.label
|
|
21
|
+
- font.size.small
|
|
22
|
+
- font.tracking.heading
|
|
23
|
+
- font.tracking.ui
|
|
24
|
+
- font.weight.heading
|
|
25
|
+
- font.weight.ui
|
|
26
|
+
- motion.duration.fast
|
|
27
|
+
- motion.easing.standard
|
|
28
|
+
- size.column.card
|
|
29
|
+
- size.column.sidebar
|
|
30
|
+
- size.measure.prose
|
|
31
|
+
- space.inline.lg
|
|
32
|
+
- space.inline.xs
|
|
33
|
+
- space.inset.md
|
|
34
|
+
- space.inset.sm
|
|
35
|
+
- space.stack.lg
|
|
36
|
+
- space.stack.sm
|
|
37
|
+
- space.stack.xs
|
|
38
|
+
---
|
|
39
|
+
|
|
40
|
+
# Post list item
|
|
41
|
+
|
|
42
|
+
One ledger row in a list of writing: catalogue number, date and reading time beside the title, summary and tags.
|
|
43
|
+
|
|
44
|
+
## When to use
|
|
45
|
+
|
|
46
|
+
- On the writing index, grouped under year headings (`cx-posts__year`).
|
|
47
|
+
- For "Recent writing" on the home page (five rows, no year heading).
|
|
48
|
+
- For any dated, text-first list: changelogs, release notes, recipes by date.
|
|
49
|
+
|
|
50
|
+
## When not to use
|
|
51
|
+
|
|
52
|
+
- For projects with thumbnails; use `project-card`.
|
|
53
|
+
- For navigation between adjacent posts; use `pagination`.
|
|
54
|
+
|
|
55
|
+
## Markup
|
|
56
|
+
|
|
57
|
+
```html preview
|
|
58
|
+
<h2 class="cx-posts__year">2026</h2>
|
|
59
|
+
<ol class="cx-posts" reversed>
|
|
60
|
+
<li class="cx-post">
|
|
61
|
+
<p class="cx-post__meta">
|
|
62
|
+
<span class="cx-id__no">LM-P-031</span>
|
|
63
|
+
<time datetime="2026-10-02">2026-10-02</time>
|
|
64
|
+
<span>6 min</span>
|
|
65
|
+
</p>
|
|
66
|
+
<div class="cx-post__main">
|
|
67
|
+
<h3 class="cx-post__title"><a href="/writing/tokens-over-mcp/">Serving design tokens to AI assistants over MCP</a></h3>
|
|
68
|
+
<p class="cx-post__summary">Why every token carries a usage rule.</p>
|
|
69
|
+
<ul class="cx-tags"><li><a class="cx-tag" href="/tags/mcp/">mcp</a></li></ul>
|
|
70
|
+
</div>
|
|
71
|
+
</li>
|
|
72
|
+
</ol>
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
## Do
|
|
76
|
+
|
|
77
|
+
- Use `<ol reversed>`; newest first is an order the reader relies on.
|
|
78
|
+
- Keep the meta column to number, date and reading time, in that order.
|
|
79
|
+
- Write summaries as one plain sentence.
|
|
80
|
+
|
|
81
|
+
## Don't
|
|
82
|
+
|
|
83
|
+
- Don't add thumbnails; rows must scan as a column of titles.
|
|
84
|
+
- Don't truncate titles with ellipses. Let them wrap.
|
|
85
|
+
|
|
86
|
+
## Accessibility
|
|
87
|
+
|
|
88
|
+
- The title link's `::after` covers the row, so the whole row is clickable while only one link is announced.
|
|
89
|
+
- Focus on the title draws the ring around the row.
|
|
90
|
+
- Dates use `<time datetime>`.
|
|
91
|
+
- Pairs: `color.text.accent` number on `color.surface.base` (4.5:1); `color.text.muted` meta (4.5:1); `color.text.primary` title on `color.surface.hover` (7:1).
|
|
@@ -1,82 +1,82 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: project-card
|
|
3
|
-
status: stable
|
|
4
|
-
tokens:
|
|
5
|
-
- border.focus.offset
|
|
6
|
-
- border.focus.width
|
|
7
|
-
- border.width.hairline
|
|
8
|
-
- color.border.default
|
|
9
|
-
- color.border.strong
|
|
10
|
-
- color.border.subtle
|
|
11
|
-
- color.focus.ring
|
|
12
|
-
- color.surface.raised
|
|
13
|
-
- color.surface.sunken
|
|
14
|
-
- color.text.primary
|
|
15
|
-
- color.text.secondary
|
|
16
|
-
- font.line-height.heading
|
|
17
|
-
- font.size.heading-4
|
|
18
|
-
- font.size.small
|
|
19
|
-
- font.tracking.heading
|
|
20
|
-
- font.weight.heading
|
|
21
|
-
- motion.duration.fast
|
|
22
|
-
- motion.easing.standard
|
|
23
|
-
- size.column.card
|
|
24
|
-
- size.measure.caption
|
|
25
|
-
- space.gutter.grid
|
|
26
|
-
- space.inline.xs
|
|
27
|
-
- space.inset.md
|
|
28
|
-
- space.stack.sm
|
|
29
|
-
---
|
|
30
|
-
|
|
31
|
-
# Project card
|
|
32
|
-
|
|
33
|
-
A framed summary of one project that links to its case study.
|
|
34
|
-
|
|
35
|
-
## When to use
|
|
36
|
-
|
|
37
|
-
- In a `cx-cards` grid on the home page (two or three selected projects) and the project index.
|
|
38
|
-
- For any catalogued entry with an image: a recipe, an architecture study, a docs guide.
|
|
39
|
-
|
|
40
|
-
## When not to use
|
|
41
|
-
|
|
42
|
-
- For writing; use `post-list-item`, which scans faster as a ledger.
|
|
43
|
-
- For a single featured project with a long description; use a page heading and prose.
|
|
44
|
-
- Without a thumbnail. If there is no image, use `post-list-item` instead.
|
|
45
|
-
|
|
46
|
-
## Markup
|
|
47
|
-
|
|
48
|
-
```html preview
|
|
49
|
-
<ul class="cx-cards">
|
|
50
|
-
<li>
|
|
51
|
-
<article class="cx-card">
|
|
52
|
-
<div class="cx-card__media"><img src="/work/globe/thumb.webp" alt="" width="640" height="400"></div>
|
|
53
|
-
<div class="cx-card__body">
|
|
54
|
-
<p class="cx-id"><span class="cx-id__no">LM-W-001</span><span>2026</span><span class="cx-status cx-status--live">Live</span></p>
|
|
55
|
-
<h3 class="cx-card__title"><a class="cx-card__link" href="/work/globe/">Interactive WebGL globe</a></h3>
|
|
56
|
-
<p class="cx-card__summary">A React app that renders live routes on a 3D globe.</p>
|
|
57
|
-
<ul class="cx-tags"><li><a class="cx-tag" href="/tags/webgl/">webgl</a></li></ul>
|
|
58
|
-
</div>
|
|
59
|
-
</article>
|
|
60
|
-
</li>
|
|
61
|
-
</ul>
|
|
62
|
-
```
|
|
63
|
-
|
|
64
|
-
## Do
|
|
65
|
-
|
|
66
|
-
- Make the title link the only card link; its `::after` stretches over the card.
|
|
67
|
-
- Keep summaries to one sentence (the caption measure is 52ch).
|
|
68
|
-
- Give thumbnails a 16:10 ratio and explicit `width`/`height` to prevent layout shift.
|
|
69
|
-
- Leave thumbnail `alt` empty when the title already names the project; describe it when the image shows something the text doesn't.
|
|
70
|
-
|
|
71
|
-
## Don't
|
|
72
|
-
|
|
73
|
-
- Don't nest buttons or other links inside the card except tags, which sit above the stretched link.
|
|
74
|
-
- Don't add shadows or rounded corners. Hover changes the border only.
|
|
75
|
-
- Don't show more than three tags.
|
|
76
|
-
|
|
77
|
-
## Accessibility
|
|
78
|
-
|
|
79
|
-
- Each card is an `<article>` with an `<h3>` (or the level that fits the page outline).
|
|
80
|
-
- Focus on the title link draws the focus ring around the whole card (`:has(:focus-visible)`).
|
|
81
|
-
- Tags stay keyboard-reachable after the title link.
|
|
82
|
-
- Pairs: `color.text.primary` on `color.surface.raised` (7:1); `color.text.secondary` summary (7:1); hover border `color.border.strong` (3:1).
|
|
1
|
+
---
|
|
2
|
+
name: project-card
|
|
3
|
+
status: stable
|
|
4
|
+
tokens:
|
|
5
|
+
- border.focus.offset
|
|
6
|
+
- border.focus.width
|
|
7
|
+
- border.width.hairline
|
|
8
|
+
- color.border.default
|
|
9
|
+
- color.border.strong
|
|
10
|
+
- color.border.subtle
|
|
11
|
+
- color.focus.ring
|
|
12
|
+
- color.surface.raised
|
|
13
|
+
- color.surface.sunken
|
|
14
|
+
- color.text.primary
|
|
15
|
+
- color.text.secondary
|
|
16
|
+
- font.line-height.heading
|
|
17
|
+
- font.size.heading-4
|
|
18
|
+
- font.size.small
|
|
19
|
+
- font.tracking.heading
|
|
20
|
+
- font.weight.heading
|
|
21
|
+
- motion.duration.fast
|
|
22
|
+
- motion.easing.standard
|
|
23
|
+
- size.column.card
|
|
24
|
+
- size.measure.caption
|
|
25
|
+
- space.gutter.grid
|
|
26
|
+
- space.inline.xs
|
|
27
|
+
- space.inset.md
|
|
28
|
+
- space.stack.sm
|
|
29
|
+
---
|
|
30
|
+
|
|
31
|
+
# Project card
|
|
32
|
+
|
|
33
|
+
A framed summary of one project that links to its case study.
|
|
34
|
+
|
|
35
|
+
## When to use
|
|
36
|
+
|
|
37
|
+
- In a `cx-cards` grid on the home page (two or three selected projects) and the project index.
|
|
38
|
+
- For any catalogued entry with an image: a recipe, an architecture study, a docs guide.
|
|
39
|
+
|
|
40
|
+
## When not to use
|
|
41
|
+
|
|
42
|
+
- For writing; use `post-list-item`, which scans faster as a ledger.
|
|
43
|
+
- For a single featured project with a long description; use a page heading and prose.
|
|
44
|
+
- Without a thumbnail. If there is no image, use `post-list-item` instead.
|
|
45
|
+
|
|
46
|
+
## Markup
|
|
47
|
+
|
|
48
|
+
```html preview
|
|
49
|
+
<ul class="cx-cards">
|
|
50
|
+
<li>
|
|
51
|
+
<article class="cx-card">
|
|
52
|
+
<div class="cx-card__media"><img src="/work/globe/thumb.webp" alt="" width="640" height="400"></div>
|
|
53
|
+
<div class="cx-card__body">
|
|
54
|
+
<p class="cx-id"><span class="cx-id__no">LM-W-001</span><span>2026</span><span class="cx-status cx-status--live">Live</span></p>
|
|
55
|
+
<h3 class="cx-card__title"><a class="cx-card__link" href="/work/globe/">Interactive WebGL globe</a></h3>
|
|
56
|
+
<p class="cx-card__summary">A React app that renders live routes on a 3D globe.</p>
|
|
57
|
+
<ul class="cx-tags"><li><a class="cx-tag" href="/tags/webgl/">webgl</a></li></ul>
|
|
58
|
+
</div>
|
|
59
|
+
</article>
|
|
60
|
+
</li>
|
|
61
|
+
</ul>
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
## Do
|
|
65
|
+
|
|
66
|
+
- Make the title link the only card link; its `::after` stretches over the card.
|
|
67
|
+
- Keep summaries to one sentence (the caption measure is 52ch).
|
|
68
|
+
- Give thumbnails a 16:10 ratio and explicit `width`/`height` to prevent layout shift.
|
|
69
|
+
- Leave thumbnail `alt` empty when the title already names the project; describe it when the image shows something the text doesn't.
|
|
70
|
+
|
|
71
|
+
## Don't
|
|
72
|
+
|
|
73
|
+
- Don't nest buttons or other links inside the card except tags, which sit above the stretched link.
|
|
74
|
+
- Don't add shadows or rounded corners. Hover changes the border only.
|
|
75
|
+
- Don't show more than three tags.
|
|
76
|
+
|
|
77
|
+
## Accessibility
|
|
78
|
+
|
|
79
|
+
- Each card is an `<article>` with an `<h3>` (or the level that fits the page outline).
|
|
80
|
+
- Focus on the title link draws the focus ring around the whole card (`:has(:focus-visible)`).
|
|
81
|
+
- Tags stay keyboard-reachable after the title link.
|
|
82
|
+
- Pairs: `color.text.primary` on `color.surface.raised` (7:1); `color.text.secondary` summary (7:1); hover border `color.border.strong` (3:1).
|
package/docs/components/prose.md
CHANGED
|
@@ -1,122 +1,122 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: prose
|
|
3
|
-
status: stable
|
|
4
|
-
tokens:
|
|
5
|
-
- border.focus.offset
|
|
6
|
-
- border.focus.width
|
|
7
|
-
- border.width.emphasis
|
|
8
|
-
- border.width.hairline
|
|
9
|
-
- color.accent.border
|
|
10
|
-
- color.border.strong
|
|
11
|
-
- color.border.subtle
|
|
12
|
-
- color.focus.ring
|
|
13
|
-
- color.link.hover
|
|
14
|
-
- color.link.rest
|
|
15
|
-
- color.ornament.rest
|
|
16
|
-
- color.surface.highlight
|
|
17
|
-
- color.surface.sunken
|
|
18
|
-
- color.text.accent
|
|
19
|
-
- color.text.muted
|
|
20
|
-
- color.text.primary
|
|
21
|
-
- color.text.secondary
|
|
22
|
-
- font.family.display
|
|
23
|
-
- font.family.mono
|
|
24
|
-
- font.family.ornament
|
|
25
|
-
- font.line-height.display
|
|
26
|
-
- font.line-height.heading
|
|
27
|
-
- font.line-height.ui
|
|
28
|
-
- font.size.code-inline
|
|
29
|
-
- font.size.display
|
|
30
|
-
- font.size.heading-1
|
|
31
|
-
- font.size.heading-2
|
|
32
|
-
- font.size.heading-3
|
|
33
|
-
- font.size.heading-4
|
|
34
|
-
- font.size.label
|
|
35
|
-
- font.size.lede
|
|
36
|
-
- font.size.small
|
|
37
|
-
- font.tracking.display
|
|
38
|
-
- font.tracking.heading
|
|
39
|
-
- font.tracking.label
|
|
40
|
-
- font.tracking.ui
|
|
41
|
-
- font.weight.body
|
|
42
|
-
- font.weight.display
|
|
43
|
-
- font.weight.heading
|
|
44
|
-
- font.weight.strong
|
|
45
|
-
- font.weight.ui
|
|
46
|
-
- radius.control
|
|
47
|
-
- size.container.breakout
|
|
48
|
-
- size.measure.caption
|
|
49
|
-
- size.measure.code
|
|
50
|
-
- size.measure.prose
|
|
51
|
-
- size.ornament.sm
|
|
52
|
-
- space.inline.md
|
|
53
|
-
- space.inline.sm
|
|
54
|
-
- space.inline.xs
|
|
55
|
-
- space.inset.lg
|
|
56
|
-
- space.inset.md
|
|
57
|
-
- space.inset.xs
|
|
58
|
-
- space.section.sm
|
|
59
|
-
- space.stack.lg
|
|
60
|
-
- space.stack.md
|
|
61
|
-
- space.stack.sm
|
|
62
|
-
- space.stack.xl
|
|
63
|
-
- space.stack.xs
|
|
64
|
-
---
|
|
65
|
-
|
|
66
|
-
# Prose
|
|
67
|
-
|
|
68
|
-
Styles for Markdown-rendered long-form content: headings, paragraphs, lists, blockquotes, inline code, keys, marks, links and dividers.
|
|
69
|
-
|
|
70
|
-
## When to use
|
|
71
|
-
|
|
72
|
-
- Around Hugo's `{{ .Content }}` on posts, case studies, about pages and docs.
|
|
73
|
-
- Anywhere running text is longer than two paragraphs.
|
|
74
|
-
|
|
75
|
-
## When not to use
|
|
76
|
-
|
|
77
|
-
- For UI text in cards, nav or tables; components set their own type.
|
|
78
|
-
- For page titles; use `.cx-page-head` with an `<h1>` outside the prose wrapper.
|
|
79
|
-
|
|
80
|
-
## Markup
|
|
81
|
-
|
|
82
|
-
```html preview
|
|
83
|
-
<div class="cx-prose">
|
|
84
|
-
<p>A token without a rule is a colour with a name, so the <a href="/writing/rules/">description becomes the contract</a>.</p>
|
|
85
|
-
<h2 id="why">Why tokens need rules <a class="cx-anchor" href="#why" aria-label="Link to Why tokens need rules">#</a></h2>
|
|
86
|
-
<p>Every semantic token carries a <strong>usage rule</strong> in its <code>$description</code>.</p>
|
|
87
|
-
<ul>
|
|
88
|
-
<li>Name the role, never the page.</li>
|
|
89
|
-
<li>State when not to use it.</li>
|
|
90
|
-
</ul>
|
|
91
|
-
<blockquote><p>Things that are easy to build are also reliable.</p><footer>Jensen Huang <span class="cx-sep" aria-hidden="true">|</span> <cite>Jensen Huang gets mobbed by engineers in Taiwan</cite>, Lex Fridman</footer></blockquote>
|
|
92
|
-
<p>Press <kbd>Ctrl</kbd> + <kbd>K</kbd> to search, or <mark>query the server</mark>.</p>
|
|
93
|
-
<hr>
|
|
94
|
-
<p>Last paragraph of the article.<span class="cx-end-mark" aria-hidden="true">g</span></p>
|
|
95
|
-
</div>
|
|
96
|
-
```
|
|
97
|
-
|
|
98
|
-
## Do
|
|
99
|
-
|
|
100
|
-
- Start content headings at `<h2>`; the page `<h1>` sits outside `.cx-prose`.
|
|
101
|
-
- Give every `<h2>` an id and a heading anchor (see `heading-anchor.md`).
|
|
102
|
-
- Use `.cx-figure--breakout`, `.cx-code--breakout` or `.cx-table--breakout` for wide content; everything else stops at 66ch.
|
|
103
|
-
- End articles with the flower end mark (`g` in `font.family.ornament`).
|
|
104
|
-
- Separate inline metadata with `<span class="cx-sep" aria-hidden="true">|</span>`, never "·". The pipe is muted and hidden from screen readers.
|
|
105
|
-
- Attribute every quotation in the blockquote's `<footer>`: who said it, then the source title in `<cite>`. Only quote words you can trace to that source.
|
|
106
|
-
- Use `<strong>` for emphasis that matters. National Park has no italic, so `<em>` renders as a synthetic oblique.
|
|
107
|
-
|
|
108
|
-
## Don't
|
|
109
|
-
|
|
110
|
-
- Don't present someone else's words as an unattributed principle or as your own, and never copy text from reference sites into sample content.
|
|
111
|
-
|
|
112
|
-
- Don't skip heading levels.
|
|
113
|
-
- Don't remove link underlines; colour is never the only cue.
|
|
114
|
-
- Don't use more than one `<hr>` per article. It renders as a three-stitch ornament.
|
|
115
|
-
- Don't set prose wider than `size.measure.prose`.
|
|
116
|
-
|
|
117
|
-
## Accessibility
|
|
118
|
-
|
|
119
|
-
- Links are underlined at rest and thicken on hover and focus.
|
|
120
|
-
- Heading anchors name their section in `aria-label` and appear on hover or focus (always on touch screens).
|
|
121
|
-
- `<hr>` keeps its separator role; the stitches are generated content with no text.
|
|
122
|
-
- Pairs: `color.text.primary` (7:1), `color.link.rest` and `color.link.hover` (7:1), `color.text.secondary` blockquotes (7:1) on `color.surface.base`.
|
|
1
|
+
---
|
|
2
|
+
name: prose
|
|
3
|
+
status: stable
|
|
4
|
+
tokens:
|
|
5
|
+
- border.focus.offset
|
|
6
|
+
- border.focus.width
|
|
7
|
+
- border.width.emphasis
|
|
8
|
+
- border.width.hairline
|
|
9
|
+
- color.accent.border
|
|
10
|
+
- color.border.strong
|
|
11
|
+
- color.border.subtle
|
|
12
|
+
- color.focus.ring
|
|
13
|
+
- color.link.hover
|
|
14
|
+
- color.link.rest
|
|
15
|
+
- color.ornament.rest
|
|
16
|
+
- color.surface.highlight
|
|
17
|
+
- color.surface.sunken
|
|
18
|
+
- color.text.accent
|
|
19
|
+
- color.text.muted
|
|
20
|
+
- color.text.primary
|
|
21
|
+
- color.text.secondary
|
|
22
|
+
- font.family.display
|
|
23
|
+
- font.family.mono
|
|
24
|
+
- font.family.ornament
|
|
25
|
+
- font.line-height.display
|
|
26
|
+
- font.line-height.heading
|
|
27
|
+
- font.line-height.ui
|
|
28
|
+
- font.size.code-inline
|
|
29
|
+
- font.size.display
|
|
30
|
+
- font.size.heading-1
|
|
31
|
+
- font.size.heading-2
|
|
32
|
+
- font.size.heading-3
|
|
33
|
+
- font.size.heading-4
|
|
34
|
+
- font.size.label
|
|
35
|
+
- font.size.lede
|
|
36
|
+
- font.size.small
|
|
37
|
+
- font.tracking.display
|
|
38
|
+
- font.tracking.heading
|
|
39
|
+
- font.tracking.label
|
|
40
|
+
- font.tracking.ui
|
|
41
|
+
- font.weight.body
|
|
42
|
+
- font.weight.display
|
|
43
|
+
- font.weight.heading
|
|
44
|
+
- font.weight.strong
|
|
45
|
+
- font.weight.ui
|
|
46
|
+
- radius.control
|
|
47
|
+
- size.container.breakout
|
|
48
|
+
- size.measure.caption
|
|
49
|
+
- size.measure.code
|
|
50
|
+
- size.measure.prose
|
|
51
|
+
- size.ornament.sm
|
|
52
|
+
- space.inline.md
|
|
53
|
+
- space.inline.sm
|
|
54
|
+
- space.inline.xs
|
|
55
|
+
- space.inset.lg
|
|
56
|
+
- space.inset.md
|
|
57
|
+
- space.inset.xs
|
|
58
|
+
- space.section.sm
|
|
59
|
+
- space.stack.lg
|
|
60
|
+
- space.stack.md
|
|
61
|
+
- space.stack.sm
|
|
62
|
+
- space.stack.xl
|
|
63
|
+
- space.stack.xs
|
|
64
|
+
---
|
|
65
|
+
|
|
66
|
+
# Prose
|
|
67
|
+
|
|
68
|
+
Styles for Markdown-rendered long-form content: headings, paragraphs, lists, blockquotes, inline code, keys, marks, links and dividers.
|
|
69
|
+
|
|
70
|
+
## When to use
|
|
71
|
+
|
|
72
|
+
- Around Hugo's `{{ .Content }}` on posts, case studies, about pages and docs.
|
|
73
|
+
- Anywhere running text is longer than two paragraphs.
|
|
74
|
+
|
|
75
|
+
## When not to use
|
|
76
|
+
|
|
77
|
+
- For UI text in cards, nav or tables; components set their own type.
|
|
78
|
+
- For page titles; use `.cx-page-head` with an `<h1>` outside the prose wrapper.
|
|
79
|
+
|
|
80
|
+
## Markup
|
|
81
|
+
|
|
82
|
+
```html preview
|
|
83
|
+
<div class="cx-prose">
|
|
84
|
+
<p>A token without a rule is a colour with a name, so the <a href="/writing/rules/">description becomes the contract</a>.</p>
|
|
85
|
+
<h2 id="why">Why tokens need rules <a class="cx-anchor" href="#why" aria-label="Link to Why tokens need rules">#</a></h2>
|
|
86
|
+
<p>Every semantic token carries a <strong>usage rule</strong> in its <code>$description</code>.</p>
|
|
87
|
+
<ul>
|
|
88
|
+
<li>Name the role, never the page.</li>
|
|
89
|
+
<li>State when not to use it.</li>
|
|
90
|
+
</ul>
|
|
91
|
+
<blockquote><p>Things that are easy to build are also reliable.</p><footer>Jensen Huang <span class="cx-sep" aria-hidden="true">|</span> <cite>Jensen Huang gets mobbed by engineers in Taiwan</cite>, Lex Fridman</footer></blockquote>
|
|
92
|
+
<p>Press <kbd>Ctrl</kbd> + <kbd>K</kbd> to search, or <mark>query the server</mark>.</p>
|
|
93
|
+
<hr>
|
|
94
|
+
<p>Last paragraph of the article.<span class="cx-end-mark" aria-hidden="true">g</span></p>
|
|
95
|
+
</div>
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
## Do
|
|
99
|
+
|
|
100
|
+
- Start content headings at `<h2>`; the page `<h1>` sits outside `.cx-prose`.
|
|
101
|
+
- Give every `<h2>` an id and a heading anchor (see `heading-anchor.md`).
|
|
102
|
+
- Use `.cx-figure--breakout`, `.cx-code--breakout` or `.cx-table--breakout` for wide content; everything else stops at 66ch.
|
|
103
|
+
- End articles with the flower end mark (`g` in `font.family.ornament`).
|
|
104
|
+
- Separate inline metadata with `<span class="cx-sep" aria-hidden="true">|</span>`, never "·". The pipe is muted and hidden from screen readers.
|
|
105
|
+
- Attribute every quotation in the blockquote's `<footer>`: who said it, then the source title in `<cite>`. Only quote words you can trace to that source.
|
|
106
|
+
- Use `<strong>` for emphasis that matters. National Park has no italic, so `<em>` renders as a synthetic oblique.
|
|
107
|
+
|
|
108
|
+
## Don't
|
|
109
|
+
|
|
110
|
+
- Don't present someone else's words as an unattributed principle or as your own, and never copy text from reference sites into sample content.
|
|
111
|
+
|
|
112
|
+
- Don't skip heading levels.
|
|
113
|
+
- Don't remove link underlines; colour is never the only cue.
|
|
114
|
+
- Don't use more than one `<hr>` per article. It renders as a three-stitch ornament.
|
|
115
|
+
- Don't set prose wider than `size.measure.prose`.
|
|
116
|
+
|
|
117
|
+
## Accessibility
|
|
118
|
+
|
|
119
|
+
- Links are underlined at rest and thicken on hover and focus.
|
|
120
|
+
- Heading anchors name their section in `aria-label` and appear on hover or focus (always on touch screens).
|
|
121
|
+
- `<hr>` keeps its separator role; the stitches are generated content with no text.
|
|
122
|
+
- Pairs: `color.text.primary` (7:1), `color.link.rest` and `color.link.hover` (7:1), `color.text.secondary` blockquotes (7:1) on `color.surface.base`.
|