@mvarble/mesearch-workflow 0.0.0-stage → 0.2.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.
Files changed (165) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +109 -2
  3. package/agents/reference/authoring.md +127 -0
  4. package/agents/reference/workflow.md +106 -0
  5. package/agents/skills/wf-abandon/SKILL.md +16 -0
  6. package/agents/skills/wf-approve/SKILL.md +23 -0
  7. package/agents/skills/wf-build/SKILL.md +41 -0
  8. package/agents/skills/wf-plan/SKILL.md +47 -0
  9. package/agents/skills/wf-publish/SKILL.md +41 -0
  10. package/agents/skills/wf-reopen/SKILL.md +20 -0
  11. package/agents/skills/wf-resume/SKILL.md +16 -0
  12. package/agents/skills/wf-start/SKILL.md +25 -0
  13. package/agents/skills/wf-status/SKILL.md +12 -0
  14. package/agents/skills/wf-writeup/SKILL.md +58 -0
  15. package/app/ambient.d.ts +71 -0
  16. package/app/lib/components/CopyCode.svelte +24 -0
  17. package/app/lib/components/DocumentMap.svelte +38 -0
  18. package/app/lib/components/DocumentPage.svelte +184 -0
  19. package/app/lib/components/Icon.svelte +35 -0
  20. package/app/lib/components/ImageFigure.svelte +213 -0
  21. package/app/lib/components/LinkList.svelte +46 -0
  22. package/app/lib/components/ModelGraph.svelte +169 -0
  23. package/app/lib/components/OpenEntry.svelte +35 -0
  24. package/app/lib/components/PageList.svelte +35 -0
  25. package/app/lib/components/PrevNext.svelte +24 -0
  26. package/app/lib/components/Proof.svelte +12 -0
  27. package/app/lib/components/Shell.svelte +55 -0
  28. package/app/lib/components/Sidebar.svelte +77 -0
  29. package/app/lib/components/StageRail.svelte +30 -0
  30. package/app/lib/components/Statement.svelte +41 -0
  31. package/app/lib/components/Tex.svelte +25 -0
  32. package/app/lib/components/ThemeToggle.svelte +17 -0
  33. package/app/lib/components/Timeline.svelte +31 -0
  34. package/app/lib/components/Toc.svelte +41 -0
  35. package/app/lib/components/TopBar.svelte +55 -0
  36. package/app/lib/components/TrackCard.svelte +20 -0
  37. package/app/lib/documents.ts +52 -0
  38. package/app/lib/graph/describe.ts +29 -0
  39. package/app/lib/graph/geometry.ts +296 -0
  40. package/app/lib/graph/spec.ts +158 -0
  41. package/app/lib/kit.ts +11 -0
  42. package/app/lib/load.ts +12 -0
  43. package/app/lib/map.ts +6 -0
  44. package/app/lib/nav.ts +91 -0
  45. package/app/lib/questions.ts +33 -0
  46. package/app/lib/server/document.ts +117 -0
  47. package/app/lib/server/map.ts +41 -0
  48. package/app/lib/server/markdown.ts +134 -0
  49. package/app/lib/server/open.ts +35 -0
  50. package/app/lib/server/repo.ts +6 -0
  51. package/app/lib/server/specs.ts +26 -0
  52. package/app/lib/server/title.ts +9 -0
  53. package/app/lib/state/persisted.svelte.ts +40 -0
  54. package/app/lib/state/theme.svelte.ts +24 -0
  55. package/app/lib/tex.ts +99 -0
  56. package/app/params/slug.ts +5 -0
  57. package/app/params/track.ts +5 -0
  58. package/app/routes/+layout.ts +2 -0
  59. package/app/routes/[...key].md/+server.ts +19 -0
  60. package/app/routes/[track=track]/+page.server.ts +14 -0
  61. package/app/routes/[track=track]/+page.svelte +24 -0
  62. package/app/routes/[track=track]/[slug=slug]/+page.server.ts +9 -0
  63. package/app/routes/[track=track]/[slug=slug]/+page.svelte +7 -0
  64. package/app/routes/[track=track]/[slug=slug]/+page.ts +4 -0
  65. package/app/routes/archive/+page.server.ts +18 -0
  66. package/app/routes/archive/+page.svelte +44 -0
  67. package/app/routes/archive/[entry=slug]/+page.server.ts +9 -0
  68. package/app/routes/archive/[entry=slug]/+page.svelte +7 -0
  69. package/app/routes/archive/[entry=slug]/+page.ts +4 -0
  70. package/app/routes/archive/[entry=slug]/[name=slug]/+page.server.ts +14 -0
  71. package/app/routes/archive/[entry=slug]/[name=slug]/+page.svelte +7 -0
  72. package/app/routes/archive/[entry=slug]/[name=slug]/+page.ts +4 -0
  73. package/app/routes/llms-full.txt/+server.ts +17 -0
  74. package/app/routes/llms.txt/+server.ts +50 -0
  75. package/app/routes/math/+page.server.ts +21 -0
  76. package/app/routes/math/+page.svelte +56 -0
  77. package/app/routes/math/[slug=slug]/+page.server.ts +8 -0
  78. package/app/routes/math/[slug=slug]/+page.svelte +7 -0
  79. package/app/routes/math/[slug=slug]/+page.ts +4 -0
  80. package/app/styles/base.css +98 -0
  81. package/app/styles/code.css +83 -0
  82. package/app/styles/index.css +17 -0
  83. package/app/styles/katex.css +14 -0
  84. package/app/styles/layout.css +545 -0
  85. package/app/styles/text.css +96 -0
  86. package/app/styles/tokens/dimensions.css +31 -0
  87. package/app/styles/tokens/typography.css +33 -0
  88. package/app/styles/tokens.css +2 -0
  89. package/app/styles/utils/archive.css +339 -0
  90. package/app/styles/utils/buttons.css +28 -0
  91. package/app/styles/utils/callouts.css +41 -0
  92. package/app/styles/utils/cards.css +95 -0
  93. package/app/styles/utils/graph.css +186 -0
  94. package/app/styles/utils/map.css +45 -0
  95. package/app/styles/utils/tables.css +25 -0
  96. package/dist/cli.d.ts +2 -0
  97. package/dist/cli.js +88 -0
  98. package/dist/cli.js.map +1 -0
  99. package/dist/engine/cli.d.ts +12 -0
  100. package/dist/engine/cli.js +744 -0
  101. package/dist/engine/cli.js.map +1 -0
  102. package/dist/engine/config.d.ts +40 -0
  103. package/dist/engine/config.js +16 -0
  104. package/dist/engine/config.js.map +1 -0
  105. package/dist/engine/lib.d.ts +108 -0
  106. package/dist/engine/lib.js +375 -0
  107. package/dist/engine/lib.js.map +1 -0
  108. package/dist/engine/main.d.ts +1 -0
  109. package/dist/engine/main.js +45 -0
  110. package/dist/engine/main.js.map +1 -0
  111. package/dist/index.d.ts +4 -0
  112. package/dist/index.js +3 -0
  113. package/dist/index.js.map +1 -0
  114. package/dist/site/hooks.d.ts +27 -0
  115. package/dist/site/hooks.js +2 -0
  116. package/dist/site/hooks.js.map +1 -0
  117. package/dist/site/index.d.ts +1 -0
  118. package/dist/site/index.js +2 -0
  119. package/dist/site/index.js.map +1 -0
  120. package/dist/site/preset/index.d.ts +15 -0
  121. package/dist/site/preset/index.js +556 -0
  122. package/dist/site/preset/index.js.map +1 -0
  123. package/dist/site/preset/runtime.d.ts +42 -0
  124. package/dist/site/preset/runtime.js +99 -0
  125. package/dist/site/preset/runtime.js.map +1 -0
  126. package/dist/site/preset/types.d.ts +87 -0
  127. package/dist/site/preset/types.js +2 -0
  128. package/dist/site/preset/types.js.map +1 -0
  129. package/dist/site/vite.d.ts +14 -0
  130. package/dist/site/vite.js +202 -0
  131. package/dist/site/vite.js.map +1 -0
  132. package/dist/sync/index.d.ts +17 -0
  133. package/dist/sync/index.js +175 -0
  134. package/dist/sync/index.js.map +1 -0
  135. package/dist/sync/init.d.ts +7 -0
  136. package/dist/sync/init.js +62 -0
  137. package/dist/sync/init.js.map +1 -0
  138. package/dist/sync/render.d.ts +3 -0
  139. package/dist/sync/render.js +118 -0
  140. package/dist/sync/render.js.map +1 -0
  141. package/dist/sync/site.d.ts +3 -0
  142. package/dist/sync/site.js +58 -0
  143. package/dist/sync/site.js.map +1 -0
  144. package/package.json +78 -3
  145. package/templates/.agents/reference/authoring.md +11 -0
  146. package/templates/.agents/reference/stages/README.md +4 -0
  147. package/templates/AGENTS.md +36 -0
  148. package/templates/site/content/landing.md +5 -0
  149. package/templates/site/katex.config.ts +5 -0
  150. package/templates/site/package.json +22 -0
  151. package/templates/site/src/app.d.ts +8 -0
  152. package/templates/site/src/app.html +23 -0
  153. package/templates/site/src/lib/components/Logo.svelte +12 -0
  154. package/templates/site/src/lib/site.ts +39 -0
  155. package/templates/site/src/routes/+layout.server.ts +3 -0
  156. package/templates/site/src/routes/+layout.svelte +11 -0
  157. package/templates/site/src/routes/+page.server.ts +3 -0
  158. package/templates/site/src/routes/+page.svelte +34 -0
  159. package/templates/site/src/routes/+page.ts +7 -0
  160. package/templates/site/src/styles/index.css +4 -0
  161. package/templates/site/src/styles/tokens/colors.css +107 -0
  162. package/templates/site/static/favicon.svg +1 -0
  163. package/templates/site/tsconfig.json +20 -0
  164. package/templates/site/vite.config.ts +4 -0
  165. package/templates/workflow.config.ts +40 -0
@@ -0,0 +1,7 @@
1
+ <script lang="ts">
2
+ import DocumentPage from '../../../lib/components/DocumentPage.svelte';
3
+
4
+ let { data } = $props();
5
+ </script>
6
+
7
+ <DocumentPage {data} />
@@ -0,0 +1,4 @@
1
+ import { withComponent } from '../../../lib/load';
2
+ import type { PageLoad } from '../../../lib/kit';
3
+
4
+ export const load: PageLoad = ({ data }) => withComponent(data);
@@ -0,0 +1,18 @@
1
+ import { cms } from '$cms';
2
+
3
+ import { linkOf } from '../../lib/documents';
4
+ import { documentMap } from '../../lib/server/map';
5
+ import type { PageServerLoad } from '../../lib/kit';
6
+
7
+ // Entries in progress first, then those done, then those set aside; newest first within each. The
8
+ // map is the one on the Mathematics page: the archive's documents are part of it.
9
+ export const load: PageServerLoad = () => {
10
+ const entries = cms.archive.list();
11
+ const group = (status: string) => entries.filter((e) => e.status == status).map(linkOf);
12
+ return {
13
+ active: group('active'),
14
+ done: group('done'),
15
+ abandoned: group('abandoned'),
16
+ map: documentMap(),
17
+ };
18
+ };
@@ -0,0 +1,44 @@
1
+ <script lang="ts">
2
+ import DocumentMap from '../../lib/components/DocumentMap.svelte';
3
+ import PageList from '../../lib/components/PageList.svelte';
4
+ import { ARCHIVE, SITE } from '$site';
5
+
6
+ let { data } = $props();
7
+ </script>
8
+
9
+ <svelte:head>
10
+ <title>{ARCHIVE.title} · {SITE.name}</title>
11
+ <meta property="og:title" content="{ARCHIVE.title} · {SITE.name}" />
12
+ <meta name="description" content={ARCHIVE.blurb} />
13
+ <meta property="og:description" content={ARCHIVE.blurb} />
14
+ </svelte:head>
15
+
16
+ <div class="doc-layout">
17
+ <article class="doc track-index">
18
+ <header class="doc-header">
19
+ <h1>{ARCHIVE.title}</h1>
20
+ <p class="lede">{ARCHIVE.blurb}</p>
21
+ </header>
22
+ {#if ARCHIVE.about}
23
+ <div class="prose">
24
+ <p>{ARCHIVE.about}</p>
25
+ </div>
26
+ {/if}
27
+ {#if data.map.nodes.length}
28
+ <DocumentMap {...data.map} />
29
+ {/if}
30
+ {#if data.active.length}
31
+ <h2>In progress</h2>
32
+ <PageList links={data.active} empty="" />
33
+ {/if}
34
+ <h2>Done</h2>
35
+ <PageList links={data.done} empty="No entry is finished yet." />
36
+ {#if data.abandoned.length}
37
+ <h2>Set aside</h2>
38
+ <p class="muted">
39
+ Worked on, then put down. Their documents stay, should they be taken up again.
40
+ </p>
41
+ <PageList links={data.abandoned} empty="" />
42
+ {/if}
43
+ </article>
44
+ </div>
@@ -0,0 +1,9 @@
1
+ import { cms } from '$cms';
2
+
3
+ import { documentData } from '../../../lib/server/document';
4
+ import type { EntryGenerator, PageServerLoad } from '../../../lib/kit';
5
+
6
+ export const entries: EntryGenerator = () =>
7
+ cms.archive.list().map((entry) => ({ entry: entry.slug }));
8
+
9
+ export const load: PageServerLoad = ({ params }) => documentData(`archive/${params.entry}`);
@@ -0,0 +1,7 @@
1
+ <script lang="ts">
2
+ import DocumentPage from '../../../lib/components/DocumentPage.svelte';
3
+
4
+ let { data } = $props();
5
+ </script>
6
+
7
+ <DocumentPage {data} />
@@ -0,0 +1,4 @@
1
+ import { withComponent } from '../../../lib/load';
2
+ import type { PageLoad } from '../../../lib/kit';
3
+
4
+ export const load: PageLoad = ({ data }) => withComponent(data);
@@ -0,0 +1,14 @@
1
+ import { cms } from '$cms';
2
+
3
+ import { documentData } from '../../../../lib/server/document';
4
+ import type { EntryGenerator, PageServerLoad } from '../../../../lib/kit';
5
+
6
+ export const entries: EntryGenerator = () =>
7
+ cms.archive
8
+ .list()
9
+ .flatMap((entry) =>
10
+ cms.archive.documents(entry.key).map((doc) => ({ entry: entry.slug, name: doc.name })),
11
+ );
12
+
13
+ export const load: PageServerLoad = ({ params }) =>
14
+ documentData(`archive/${params.entry}/${params.name}`);
@@ -0,0 +1,7 @@
1
+ <script lang="ts">
2
+ import DocumentPage from '../../../../lib/components/DocumentPage.svelte';
3
+
4
+ let { data } = $props();
5
+ </script>
6
+
7
+ <DocumentPage {data} />
@@ -0,0 +1,4 @@
1
+ import { withComponent } from '../../../../lib/load';
2
+ import type { PageLoad } from '../../../../lib/kit';
3
+
4
+ export const load: PageLoad = ({ data }) => withComponent(data);
@@ -0,0 +1,17 @@
1
+ import { cms } from '$cms';
2
+
3
+ import { markdownOf } from '../../lib/server/markdown';
4
+ import { SITE } from '$site';
5
+ import type { RequestHandler } from '../../lib/kit';
6
+
7
+ export const prerender = true;
8
+
9
+ export const GET: RequestHandler = () => {
10
+ const header = `# ${SITE.name}\n\n> ${SITE.description}\n`;
11
+ const body = cms
12
+ .all()
13
+ .map((doc) => `\n---\n\n<!-- document: ${doc.key} -->\n\n${markdownOf(doc)}`);
14
+ return new Response(header + body.join(''), {
15
+ headers: { 'content-type': 'text/plain; charset=utf-8' },
16
+ });
17
+ };
@@ -0,0 +1,50 @@
1
+ import { cms } from '$cms';
2
+
3
+ import { resolve } from '$app/paths';
4
+ import { markdownHrefOf } from '../../lib/documents';
5
+ import { ARCHIVE, LLMS, MATH, SITE, TRACKS } from '$site';
6
+ import type { RequestHandler } from '../../lib/kit';
7
+
8
+ export const prerender = true;
9
+
10
+ // The index format of https://llmstxt.org: a title, a one-paragraph summary, then one section per
11
+ // track, the math notes and the archive, listing each document's Markdown with its summary. Links
12
+ // are absolute when the build knows where the site is hosted (`SITE_URL=https://example.org`),
13
+ // and root-relative otherwise.
14
+ export const GET: RequestHandler = () => {
15
+ const origin = (process.env.SITE_URL ?? '').replace(/\/$/, '');
16
+ const link = (key: string) => `${origin}${markdownHrefOf(key)}`;
17
+ const lines = [
18
+ `# ${SITE.name}`,
19
+ '',
20
+ `> ${SITE.description}`,
21
+ '',
22
+ `Every document below links to its Markdown source. ${LLMS.about} ` +
23
+ `Everything concatenated: ${origin}${resolve('/llms-full.txt')}`,
24
+ `Source: ${SITE.repo}`,
25
+ ];
26
+ const section = (
27
+ title: string,
28
+ blurb: string,
29
+ docs: { key: string; title: string; summary: string }[],
30
+ ) => {
31
+ lines.push('', `## ${title}`, '', blurb, '');
32
+ for (const doc of docs) lines.push(`- [${doc.title}](${link(doc.key)}): ${doc.summary}`);
33
+ };
34
+ for (const track of TRACKS) section(track.title, track.blurb, cms.pages.list(track.id));
35
+ section(MATH.title, MATH.blurb, cms.math.list());
36
+ section(
37
+ ARCHIVE.title,
38
+ ARCHIVE.blurb,
39
+ cms.archive.list().flatMap((entry) => [
40
+ { ...entry, summary: `(${entry.status}) ${entry.summary}` },
41
+ ...cms.archive.documents(entry.key).map((doc) => ({
42
+ ...doc,
43
+ title: `${entry.title}: ${doc.title}`,
44
+ })),
45
+ ]),
46
+ );
47
+ return new Response(lines.join('\n') + '\n', {
48
+ headers: { 'content-type': 'text/plain; charset=utf-8' },
49
+ });
50
+ };
@@ -0,0 +1,21 @@
1
+ import { cms } from '$cms';
2
+
3
+ import { linkOf } from '../../lib/documents';
4
+ import { documentMap } from '../../lib/server/map';
5
+ import { MATH_PARTS } from '$site';
6
+ import type { PageServerLoad } from '../../lib/kit';
7
+
8
+ // The math notes in reading order, part by part and numbered through, and the map they make with
9
+ // the archive's documents that build on them. A site without parts lists its notes by title.
10
+ export const load: PageServerLoad = () => ({
11
+ notes: cms.math.list().map(linkOf),
12
+ parts: MATH_PARTS.map((part) => {
13
+ const notes = cms.math.list(part.id);
14
+ return {
15
+ ...part,
16
+ notes: notes.map(linkOf),
17
+ start: notes.length ? cms.math.position(notes[0]!.key) : 1,
18
+ };
19
+ }),
20
+ map: documentMap(),
21
+ });
@@ -0,0 +1,56 @@
1
+ <script lang="ts">
2
+ import DocumentMap from '../../lib/components/DocumentMap.svelte';
3
+ import PageList from '../../lib/components/PageList.svelte';
4
+ import { MATH, SITE } from '$site';
5
+
6
+ let { data } = $props();
7
+ </script>
8
+
9
+ <svelte:head>
10
+ <title>{MATH.title} · {SITE.name}</title>
11
+ <meta property="og:title" content="{MATH.title} · {SITE.name}" />
12
+ <meta name="description" content={MATH.blurb} />
13
+ <meta property="og:description" content={MATH.blurb} />
14
+ </svelte:head>
15
+
16
+ <div class="doc-layout">
17
+ <article class="doc track-index">
18
+ <header class="doc-header">
19
+ <h1>{MATH.title}</h1>
20
+ <p class="lede">{MATH.blurb}</p>
21
+ </header>
22
+ {#if data.parts.length}
23
+ <!-- The notes in the order they are read: part by part, numbered through. -->
24
+ {#each data.parts as part (part.id)}
25
+ <section class="math-part" aria-labelledby={part.id}>
26
+ <h2 id={part.id}>{part.title}</h2>
27
+ <p class="part-blurb">{part.blurb}</p>
28
+ <PageList
29
+ links={part.notes}
30
+ numbered
31
+ start={part.start}
32
+ empty="No notes in this part yet."
33
+ />
34
+ </section>
35
+ {/each}
36
+ {#if data.map.nodes.length}
37
+ <section class="math-part" aria-labelledby="map">
38
+ <h2 id="map">What rests on what</h2>
39
+ <p class="part-blurb">
40
+ The order above is one way through. The map shows why it is the order it is:
41
+ an arrow runs from each note to the notes and the archive's documents that
42
+ build on it.
43
+ </p>
44
+ <DocumentMap {...data.map} />
45
+ </section>
46
+ {/if}
47
+ {:else}
48
+ <!-- Notes without parts, by title, under the map they make. -->
49
+ {#if data.map.nodes.length}
50
+ <DocumentMap {...data.map} />
51
+ {/if}
52
+ <h2>Notes</h2>
53
+ <PageList links={data.notes} empty="No notes yet." />
54
+ {/if}
55
+ </article>
56
+ </div>
@@ -0,0 +1,8 @@
1
+ import { cms } from '$cms';
2
+
3
+ import { documentData } from '../../../lib/server/document';
4
+ import type { EntryGenerator, PageServerLoad } from '../../../lib/kit';
5
+
6
+ export const entries: EntryGenerator = () => cms.math.list().map((note) => ({ slug: note.slug }));
7
+
8
+ export const load: PageServerLoad = ({ params }) => documentData(`math/${params.slug}`);
@@ -0,0 +1,7 @@
1
+ <script lang="ts">
2
+ import DocumentPage from '../../../lib/components/DocumentPage.svelte';
3
+
4
+ let { data } = $props();
5
+ </script>
6
+
7
+ <DocumentPage {data} />
@@ -0,0 +1,4 @@
1
+ import { withComponent } from '../../../lib/load';
2
+ import type { PageLoad } from '../../../lib/kit';
3
+
4
+ export const load: PageLoad = ({ data }) => withComponent(data);
@@ -0,0 +1,98 @@
1
+ /* Resets and element defaults that hold on every page. */
2
+
3
+ *,
4
+ *::before,
5
+ *::after {
6
+ box-sizing: border-box;
7
+ margin: 0;
8
+ padding: 0;
9
+ scrollbar-width: thin;
10
+ scrollbar-color: var(--scrollbar) transparent;
11
+ }
12
+
13
+ html {
14
+ scroll-padding-top: calc(var(--topbar-height) + var(--space-6));
15
+ -webkit-text-size-adjust: 100%;
16
+ }
17
+
18
+ body {
19
+ min-height: 100vh;
20
+ display: flex;
21
+ flex-direction: column;
22
+ font: var(--font-body);
23
+ color: var(--fg-2);
24
+ background-color: var(--bg-1);
25
+ tab-size: 4;
26
+ }
27
+
28
+ ::selection {
29
+ background: var(--bg-selection);
30
+ }
31
+
32
+ a {
33
+ color: var(--fg-accent);
34
+ text-decoration: none;
35
+ }
36
+
37
+ a:hover {
38
+ text-decoration: underline;
39
+ text-underline-offset: 0.2em;
40
+ }
41
+
42
+ :focus-visible {
43
+ outline: 2px solid var(--fg-accent);
44
+ outline-offset: 2px;
45
+ border-radius: var(--radius-sm);
46
+ }
47
+
48
+ img,
49
+ svg {
50
+ display: block;
51
+ max-width: 100%;
52
+ }
53
+
54
+ button {
55
+ font: inherit;
56
+ color: inherit;
57
+ background: none;
58
+ border: none;
59
+ cursor: pointer;
60
+ }
61
+
62
+ code,
63
+ kbd,
64
+ pre {
65
+ font-family: var(--font-family-mono);
66
+ }
67
+
68
+ .skip-link {
69
+ position: absolute;
70
+ left: var(--space-4);
71
+ top: -3rem;
72
+ z-index: 100;
73
+ padding: var(--space-2) var(--space-4);
74
+ background: var(--bg-accent);
75
+ color: var(--fg-on-accent);
76
+ border-radius: var(--radius);
77
+
78
+ &:focus {
79
+ top: var(--space-2);
80
+ }
81
+ }
82
+
83
+ /* Read by screen readers, but not drawn. */
84
+ .visually-hidden {
85
+ position: absolute;
86
+ width: 1px;
87
+ height: 1px;
88
+ overflow: hidden;
89
+ clip-path: inset(50%);
90
+ white-space: nowrap;
91
+ }
92
+
93
+ @media (prefers-reduced-motion: reduce) {
94
+ * {
95
+ transition: none !important;
96
+ scroll-behavior: auto !important;
97
+ }
98
+ }
@@ -0,0 +1,83 @@
1
+ /* Inline code and shiki blocks. Shiki emits both themes as CSS variables (`defaultColor: false`),
2
+ * and the `.dark` class picks one. */
3
+
4
+ :not(pre) > code {
5
+ font-size: var(--font-size-mono);
6
+ padding: 0.12em 0.36em;
7
+ background: var(--bg-3);
8
+ border: 1px solid var(--border);
9
+ border-radius: var(--radius-sm);
10
+ color: var(--fg-1);
11
+ overflow-wrap: anywhere;
12
+ }
13
+
14
+ .code-block {
15
+ position: relative;
16
+ border: 1px solid var(--border);
17
+ border-radius: var(--radius);
18
+ background: var(--bg-3);
19
+ overflow: hidden;
20
+
21
+ figcaption {
22
+ font: var(--font-tiny);
23
+ padding: var(--space-2) var(--space-4);
24
+ border-bottom: 1px solid var(--border);
25
+ background: var(--bg-2);
26
+
27
+ a {
28
+ display: flex;
29
+ gap: var(--space-2);
30
+ align-items: baseline;
31
+ color: var(--fg-3);
32
+ }
33
+
34
+ code {
35
+ font-size: inherit;
36
+ color: var(--fg-2);
37
+ padding: 0;
38
+ background: none;
39
+ border: none;
40
+ overflow-wrap: anywhere;
41
+ }
42
+
43
+ span {
44
+ white-space: nowrap;
45
+ }
46
+ }
47
+ }
48
+
49
+ pre.shiki {
50
+ font: var(--font-mono);
51
+ padding: var(--space-4);
52
+ overflow-x: auto;
53
+ background: transparent !important;
54
+ }
55
+
56
+ .shiki,
57
+ .shiki span {
58
+ color: var(--shiki-light);
59
+ }
60
+
61
+ :root.dark .shiki,
62
+ :root.dark .shiki span {
63
+ color: var(--shiki-dark);
64
+ }
65
+
66
+ .copy-button {
67
+ position: absolute;
68
+ right: var(--space-2);
69
+ bottom: var(--space-2);
70
+ font: var(--font-tiny);
71
+ padding: var(--space-1) var(--space-2);
72
+ color: var(--fg-3);
73
+ background: var(--bg-1);
74
+ border: 1px solid var(--border);
75
+ border-radius: var(--radius-sm);
76
+ opacity: 0;
77
+ transition: opacity 0.15s;
78
+
79
+ .code-block:hover &,
80
+ &:focus-visible {
81
+ opacity: 1;
82
+ }
83
+ }
@@ -0,0 +1,17 @@
1
+ /* The documentation site's stylesheet. Every rule refers to the tokens, and never to a raw colour:
2
+ * the site defines the colour tokens itself (`src/styles/tokens/colors.css`, which its own
3
+ * `src/styles/index.css` imports beside this file). */
4
+
5
+ @import './tokens.css';
6
+ @import './katex.css';
7
+ @import './base.css';
8
+ @import './layout.css';
9
+ @import './text.css';
10
+ @import './code.css';
11
+ @import './utils/buttons.css';
12
+ @import './utils/callouts.css';
13
+ @import './utils/tables.css';
14
+ @import './utils/cards.css';
15
+ @import './utils/graph.css';
16
+ @import './utils/map.css';
17
+ @import './utils/archive.css';
@@ -0,0 +1,14 @@
1
+ @import 'katex/dist/katex.css';
2
+ @import '@mvarble/mesearch-markdown/styles/katex.css';
3
+
4
+ /* The site's sizes over the shared rules: the scroll box around display math, the lifted `\tag`, and
5
+ * inline math that never breaks across a line all come from mesearch-markdown. */
6
+
7
+ .katex {
8
+ font-size: 1.08em;
9
+ line-height: 1.2;
10
+ }
11
+
12
+ .katex-display {
13
+ margin: var(--space-2) 0 !important;
14
+ }