blume 2.1.3 → 2.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.
- package/AGENTS.md +1 -1
- package/CHANGELOG.md +126 -0
- package/README.md +4 -4
- package/dist/cli/{chunk-74wfhv79.js → chunk-05f21r8h.js} +1 -1
- package/dist/cli/{chunk-9qzgg6mj.js → chunk-1cm0h819.js} +3 -3
- package/dist/cli/{chunk-nbyvgnnm.js → chunk-1rkxzg3n.js} +104 -47
- package/dist/cli/chunk-1rkxzg3n.js.map +36 -0
- package/dist/cli/{chunk-desvm72z.js → chunk-2nr29y95.js} +22 -26
- package/dist/cli/chunk-2nr29y95.js.map +13 -0
- package/dist/cli/{chunk-32khwcb6.js → chunk-49r370mb.js} +42 -69
- package/dist/cli/{chunk-32khwcb6.js.map → chunk-49r370mb.js.map} +9 -10
- package/dist/cli/{chunk-ms9z66nz.js → chunk-4rftmttv.js} +2 -2
- package/dist/cli/{chunk-s0bdnc7v.js → chunk-79bzzkx4.js} +5 -4
- package/dist/cli/chunk-79bzzkx4.js.map +10 -0
- package/dist/cli/{chunk-hvcxng5f.js → chunk-7tekknev.js} +6 -6
- package/dist/cli/{chunk-dv2z0rzf.js → chunk-8b489v1b.js} +38 -13
- package/dist/cli/{chunk-dv2z0rzf.js.map → chunk-8b489v1b.js.map} +5 -4
- package/dist/cli/{chunk-0pmb4tr4.js → chunk-8f8xw4x2.js} +1195 -222
- package/dist/cli/chunk-8f8xw4x2.js.map +44 -0
- package/dist/cli/chunk-96snx8yy.js +329 -0
- package/dist/cli/chunk-96snx8yy.js.map +13 -0
- package/dist/cli/{chunk-ckrcm08h.js → chunk-a3ydrqny.js} +48 -62
- package/dist/cli/{chunk-ckrcm08h.js.map → chunk-a3ydrqny.js.map} +4 -5
- package/dist/cli/{chunk-bxwhtvw8.js → chunk-ahc5gc9h.js} +5 -5
- package/dist/cli/{chunk-dpy8qdjf.js → chunk-as09pafp.js} +73 -182
- package/dist/cli/chunk-as09pafp.js.map +18 -0
- package/dist/cli/{chunk-tfycddbt.js → chunk-bjk964fp.js} +2 -2
- package/dist/cli/{chunk-gfc5fqvf.js → chunk-br0n8n3e.js} +18 -18
- package/dist/cli/{chunk-gfc5fqvf.js.map → chunk-br0n8n3e.js.map} +1 -1
- package/dist/cli/{chunk-297ajdcv.js → chunk-c69tw29j.js} +6 -6
- package/dist/cli/{chunk-297ajdcv.js.map → chunk-c69tw29j.js.map} +3 -3
- package/dist/cli/chunk-cn3dy3hz.js +146 -0
- package/dist/cli/chunk-cn3dy3hz.js.map +11 -0
- package/dist/cli/{chunk-124fvmzq.js → chunk-dm4mg9bj.js} +11064 -8742
- package/dist/cli/{chunk-124fvmzq.js.map → chunk-dm4mg9bj.js.map} +78 -64
- package/dist/cli/{chunk-dqhg54mr.js → chunk-dmx6cezx.js} +1 -1
- package/dist/cli/{chunk-60hz265r.js → chunk-dpcahcrb.js} +24 -11
- package/dist/cli/chunk-dpcahcrb.js.map +10 -0
- package/dist/cli/{chunk-a57yh0h9.js → chunk-dyk3r7jw.js} +7 -7
- package/dist/cli/{chunk-a57yh0h9.js.map → chunk-dyk3r7jw.js.map} +1 -1
- package/dist/cli/{chunk-twy7psdz.js → chunk-enk76qd5.js} +14 -10
- package/dist/cli/chunk-enk76qd5.js.map +10 -0
- package/dist/cli/{chunk-k3gr1nm9.js → chunk-fqy4n3q2.js} +13 -16
- package/dist/cli/{chunk-k3gr1nm9.js.map → chunk-fqy4n3q2.js.map} +3 -3
- package/dist/cli/{chunk-sc93apfs.js → chunk-frk2wdq1.js} +17 -17
- package/dist/cli/{chunk-sc93apfs.js.map → chunk-frk2wdq1.js.map} +2 -2
- package/dist/cli/{chunk-kdpzw38a.js → chunk-gprwej7h.js} +95 -7
- package/dist/cli/chunk-gprwej7h.js.map +11 -0
- package/dist/cli/chunk-kkrteb15.js +157 -0
- package/dist/cli/chunk-kkrteb15.js.map +10 -0
- package/dist/cli/{chunk-ave1wcbr.js → chunk-m9bp2hc1.js} +1 -1
- package/dist/cli/{chunk-58bt3hag.js → chunk-mrvh4c88.js} +4 -4
- package/dist/cli/{chunk-5cmts6dv.js → chunk-p8zg3a2h.js} +7 -7
- package/dist/cli/{chunk-5cmts6dv.js.map → chunk-p8zg3a2h.js.map} +1 -1
- package/dist/cli/{chunk-0w6hs479.js → chunk-rkqae7kh.js} +30 -18
- package/dist/cli/chunk-rkqae7kh.js.map +10 -0
- package/dist/cli/{chunk-bqxaqn5p.js → chunk-t5xx74rd.js} +8 -8
- package/dist/cli/{chunk-bqxaqn5p.js.map → chunk-t5xx74rd.js.map} +1 -1
- package/dist/cli/{chunk-1f882900.js → chunk-th0pgaj5.js} +2 -2
- package/dist/cli/{chunk-dhwtqnnd.js → chunk-vnbvhgmd.js} +2 -2
- package/dist/cli/{chunk-gxtg6ed2.js → chunk-vzy9rh6y.js} +21 -21
- package/dist/cli/{chunk-gxtg6ed2.js.map → chunk-vzy9rh6y.js.map} +3 -3
- package/dist/cli/{chunk-j1x92mx9.js → chunk-w6e455pz.js} +1 -1
- package/dist/cli/chunk-wehv26ry.js +155 -0
- package/dist/cli/chunk-wehv26ry.js.map +11 -0
- package/dist/cli/{chunk-y4msrwm9.js → chunk-xgq4eytj.js} +15 -15
- package/dist/cli/{chunk-36bxs9c7.js → chunk-xt0qvz1t.js} +27 -23
- package/dist/cli/chunk-xt0qvz1t.js.map +10 -0
- package/dist/cli/index.js +78 -42
- package/dist/cli/index.js.map +7 -6
- package/dist/types/ai/changelog-components.d.ts +18 -0
- package/dist/types/ai/changelog-markdown.d.ts +12 -0
- package/dist/types/ai/openapi-components.d.ts +7 -7
- package/dist/types/ai/operation-details.d.ts +39 -0
- package/dist/types/ai/relative-links.d.ts +3 -1
- package/dist/types/ai/serializers.d.ts +6 -4
- package/dist/types/analytics/head.d.ts +4 -2
- package/dist/types/analytics/script.d.ts +8 -2
- package/dist/types/components/content/youtube.d.ts +20 -0
- package/dist/types/components/layout/nav-utils.d.ts +8 -0
- package/dist/types/components/openapi/example-panels.d.ts +33 -0
- package/dist/types/components/openapi/helpers.d.ts +53 -11
- package/dist/types/components/openapi/snippets.d.ts +7 -1
- package/dist/types/core/alert-diagnostics.d.ts +10 -0
- package/dist/types/core/builtin-tags.d.ts +16 -0
- package/dist/types/core/changelog-list.d.ts +48 -0
- package/dist/types/core/closest-match.d.ts +6 -0
- package/dist/types/core/code-fence-diagnostics.d.ts +18 -0
- package/dist/types/core/code-fences.d.ts +8 -1
- package/dist/types/core/config-input.d.ts +1 -1
- package/dist/types/core/content-assets.d.ts +16 -18
- package/dist/types/core/diagnostics.d.ts +14 -0
- package/dist/types/core/directive-diagnostics.d.ts +22 -8
- package/dist/types/core/former-routes.d.ts +14 -0
- package/dist/types/core/github.d.ts +5 -4
- package/dist/types/core/heading-markers.d.ts +65 -2
- package/dist/types/core/hidden-pages.d.ts +3 -0
- package/dist/types/core/includes.d.ts +23 -0
- package/dist/types/core/last-modified.d.ts +18 -6
- package/dist/types/core/links.d.ts +42 -2
- package/dist/types/core/load-module.d.ts +19 -4
- package/dist/types/core/manifest.d.ts +14 -1
- package/dist/types/core/markdown-mirrors.d.ts +22 -0
- package/dist/types/core/mdx-elements.d.ts +32 -0
- package/dist/types/core/mdx-syntax.d.ts +100 -0
- package/dist/types/core/meta-diagnostics.d.ts +7 -0
- package/dist/types/core/meta.d.ts +32 -5
- package/dist/types/core/nav-diagnostics.d.ts +9 -2
- package/dist/types/core/navigation.d.ts +13 -0
- package/dist/types/core/ordering-prefix.d.ts +6 -0
- package/dist/types/core/pinned-ids.d.ts +23 -0
- package/dist/types/core/project-graph.d.ts +9 -1
- package/dist/types/core/redirect-patterns.d.ts +18 -0
- package/dist/types/core/relative-files.d.ts +31 -0
- package/dist/types/core/schema.d.ts +267 -7
- package/dist/types/core/sources/normalize.d.ts +101 -9
- package/dist/types/core/sources/types.d.ts +16 -0
- package/dist/types/core/static-files.d.ts +10 -0
- package/dist/types/core/static-host.d.ts +42 -0
- package/dist/types/core/svg-images.d.ts +26 -0
- package/dist/types/core/syntax-diagnostics.d.ts +14 -0
- package/dist/types/core/types.d.ts +42 -1
- package/dist/types/deploy/generated-files.d.ts +41 -0
- package/dist/types/deploy/redirects.d.ts +21 -7
- package/dist/types/markdown/code-title.d.ts +9 -5
- package/dist/types/markdown/directives.d.ts +8 -0
- package/dist/types/markdown/fence-language.d.ts +51 -0
- package/dist/types/markdown/fence-meta.d.ts +5 -0
- package/dist/types/markdown/github-alerts.d.ts +35 -0
- package/dist/types/openapi/asyncapi.d.ts +6 -5
- package/dist/types/openapi/checks.d.ts +10 -5
- package/dist/types/openapi/model.d.ts +55 -8
- package/dist/types/openapi/parse.d.ts +4 -1
- package/dist/types/sources/filesystem.d.ts +14 -4
- package/dist/types/sources/mdx-remote.d.ts +6 -3
- package/dist/types/sources/registry.d.ts +3 -3
- package/dist/types/theme/color.d.ts +33 -0
- package/dist/types/theme/palette.d.ts +122 -0
- package/docs/01-quickstart.mdx +1 -1
- package/docs/02-deployment.mdx +23 -8
- package/docs/04-migrating.mdx +16 -4
- package/docs/advanced/changelog.mdx +27 -1
- package/docs/advanced/skills.mdx +1 -1
- package/docs/cli/audit.mdx +1 -1
- package/docs/cli/doctor.mdx +2 -2
- package/docs/cli/evals.mdx +1 -1
- package/docs/cli/index.mdx +4 -2
- package/docs/cli/validate.mdx +10 -7
- package/docs/configuration/analytics.mdx +2 -0
- package/docs/configuration/customization.mdx +3 -1
- package/docs/configuration/index.mdx +2 -2
- package/docs/configuration/theming.mdx +5 -1
- package/docs/content/components.mdx +26 -6
- package/docs/content/frontmatter.mdx +1 -1
- package/docs/content/includes.mdx +6 -2
- package/docs/content/index.mdx +11 -1
- package/docs/content/islands.mdx +2 -0
- package/docs/content/meta.mdx +9 -3
- package/docs/content/navigation.mdx +14 -6
- package/docs/content/sources/obsidian.mdx +1 -1
- package/docs/content/sources/remote-mdx.mdx +3 -1
- package/docs/content/syntax.mdx +76 -8
- package/docs/content/variables.mdx +3 -1
- package/docs/discoverability/agent-discovery.mdx +1 -1
- package/docs/discoverability/json-api.mdx +1 -1
- package/docs/discoverability/llms-txt.mdx +1 -1
- package/docs/discoverability/markdown.mdx +2 -2
- package/docs/discoverability/open-graph.mdx +1 -1
- package/docs/discoverability/sitemap-and-robots.mdx +1 -1
- package/docs/references/graphql.mdx +2 -0
- package/docs/references/openapi.mdx +45 -7
- package/package.json +4 -4
- package/skills/blume/SKILL.md +2 -2
- package/skills/blume-migrate/SKILL.md +49 -27
- package/skills/blume-migrate/references/docsify.md +262 -0
- package/skills/blume-migrate/references/docus.md +298 -0
- package/skills/blume-migrate/references/docusaurus.md +3 -3
- package/skills/blume-migrate/references/fern.md +327 -0
- package/skills/blume-migrate/references/fumadocs.md +1 -1
- package/skills/blume-migrate/references/gitbook.md +267 -0
- package/skills/blume-migrate/references/github-wiki.md +259 -0
- package/skills/blume-migrate/references/jekyll.md +253 -0
- package/skills/blume-migrate/references/mdbook.md +256 -0
- package/skills/blume-migrate/references/mintlify.md +5 -5
- package/skills/blume-migrate/references/mkdocs.md +236 -0
- package/skills/blume-migrate/references/monorepo.md +20 -8
- package/skills/blume-migrate/references/nextra.md +2 -2
- package/skills/blume-migrate/references/readme.md +257 -0
- package/skills/blume-migrate/references/redocly.md +198 -0
- package/skills/blume-migrate/references/starlight.md +3 -3
- package/skills/blume-migrate/references/vitepress.md +204 -0
- package/skills/blume-migrate/references/vuepress.md +271 -0
- package/skills/blume-migrate/scripts/docsify-codemod.mjs +2387 -0
- package/skills/blume-migrate/scripts/docus-codemod.mjs +2542 -0
- package/skills/blume-migrate/scripts/fern-codemod.mjs +2633 -0
- package/skills/blume-migrate/scripts/github-wiki-codemod.mjs +2808 -0
- package/skills/blume-migrate/scripts/include-excerpts.mjs +649 -0
- package/skills/blume-migrate/scripts/jekyll-codemod.mjs +3649 -0
- package/skills/blume-migrate/scripts/mintlify-codemod.mjs +17 -13
- package/skills/blume-migrate/scripts/mkdocs-codemod.mjs +2526 -0
- package/skills/blume-migrate/scripts/operation-routes.mjs +508 -0
- package/skills/blume-migrate/scripts/pin-heading-ids.mjs +1049 -0
- package/skills/blume-migrate/scripts/readme-codemod.mjs +4139 -0
- package/skills/blume-migrate/scripts/vitepress-codemod.mjs +1511 -0
- package/src/ai/changelog-components.ts +24 -0
- package/src/ai/changelog-markdown.ts +45 -41
- package/src/ai/component-markdown.ts +22 -9
- package/src/ai/llms.ts +36 -5
- package/src/ai/markdown.ts +2 -2
- package/src/ai/openapi-components.ts +25 -9
- package/src/ai/operation-details.ts +208 -0
- package/src/ai/relative-links.ts +48 -8
- package/src/ai/serializers.ts +7 -6
- package/src/ai/site-skill.ts +6 -2
- package/src/analytics/head.ts +11 -5
- package/src/analytics/script.ts +13 -3
- package/src/astro/generate.ts +32 -6
- package/src/astro/index.ts +1 -0
- package/src/astro/integration.ts +27 -1
- package/src/astro/mdx-source-errors.ts +46 -0
- package/src/astro/templates.ts +89 -185
- package/src/audit/checks/redirects.ts +5 -1
- package/src/audit/redirects.ts +36 -19
- package/src/audit/report.ts +22 -9
- package/src/audit/run.ts +12 -28
- package/src/audit/terms.ts +23 -0
- package/src/audit/url.ts +2 -2
- package/src/cli/build-failure.ts +256 -7
- package/src/cli/command-meta.ts +1 -1
- package/src/cli/commands/audit.ts +1 -1
- package/src/cli/commands/build.ts +12 -3
- package/src/cli/commands/check.ts +13 -2
- package/src/cli/commands/dev.ts +1 -1
- package/src/cli/commands/doctor.ts +4 -2
- package/src/cli/commands/init.ts +3 -3
- package/src/cli/commands/preview.ts +17 -1
- package/src/cli/commands/validate.ts +22 -10
- package/src/cli/prepare.ts +1 -1
- package/src/cli/preview-pages.ts +161 -0
- package/src/cli/unknown-flags.ts +1 -42
- package/src/components/code-copy.ts +51 -0
- package/src/components/code-language.ts +75 -0
- package/src/components/content/AccordionItem.astro +16 -1
- package/src/components/content/Callout.astro +11 -1
- package/src/components/content/Changelog.astro +189 -0
- package/src/components/content/CodeBlock.astro +8 -11
- package/src/components/content/Tabs.astro +16 -2
- package/src/components/content/YouTube.astro +6 -4
- package/src/components/content/code-block.ts +33 -0
- package/src/components/content/content-strings.ts +5 -1
- package/src/components/content/inline-markdown.ts +35 -8
- package/src/components/content/youtube.ts +49 -7
- package/src/components/layout/Analytics.astro +5 -1
- package/src/components/layout/NavTree.astro +8 -3
- package/src/components/layout/RootLayout.astro +18 -31
- package/src/components/layout/nav-utils.ts +14 -0
- package/src/components/layout/search/pagefind.ts +2 -1
- package/src/components/openapi/Operation.astro +4 -0
- package/src/components/openapi/PanelTabs.astro +9 -3
- package/src/components/openapi/RequestBody.astro +42 -8
- package/src/components/openapi/RequestPanel.astro +34 -53
- package/src/components/openapi/example-panels.ts +110 -0
- package/src/components/openapi/helpers.ts +195 -20
- package/src/components/openapi/operation-model.ts +63 -26
- package/src/components/openapi/request.ts +13 -0
- package/src/components/openapi/snippets.ts +14 -2
- package/src/core/alert-diagnostics.ts +89 -0
- package/src/core/builtin-tags.ts +76 -0
- package/src/core/changelog-list.ts +87 -0
- package/src/core/closest-match.ts +41 -0
- package/src/core/code-fence-diagnostics.ts +267 -0
- package/src/core/code-fences.ts +43 -7
- package/src/core/component-diagnostics.ts +65 -12
- package/src/core/config-input.ts +1 -1
- package/src/core/config.ts +46 -1
- package/src/core/content-assets.ts +64 -144
- package/src/core/diagnostics.ts +36 -3
- package/src/core/directive-diagnostics.ts +265 -47
- package/src/core/former-routes.ts +46 -0
- package/src/core/git-ignored.ts +53 -0
- package/src/core/github.ts +5 -4
- package/src/core/heading-markers.ts +156 -2
- package/src/core/hidden-pages.ts +64 -0
- package/src/core/includes.ts +181 -41
- package/src/core/last-modified.ts +47 -10
- package/src/core/links.ts +438 -83
- package/src/core/load-module.ts +98 -9
- package/src/core/manifest.ts +12 -9
- package/src/core/markdown-mirrors.ts +52 -0
- package/src/core/mdx-elements.ts +153 -0
- package/src/core/mdx-syntax.ts +377 -0
- package/src/core/meta-diagnostics.ts +134 -0
- package/src/core/meta.ts +154 -55
- package/src/core/nav-diagnostics.ts +16 -4
- package/src/core/navigation.ts +70 -10
- package/src/core/ordering-prefix.ts +22 -2
- package/src/core/pinned-ids.ts +141 -0
- package/src/core/project-graph.ts +221 -29
- package/src/core/redirect-patterns.ts +41 -0
- package/src/core/relative-files.ts +145 -0
- package/src/core/schema.ts +17 -3
- package/src/core/sources/mdx-remote.ts +75 -14
- package/src/core/sources/normalize.ts +885 -179
- package/src/core/sources/notion.ts +5 -4
- package/src/core/sources/obsidian.ts +2 -5
- package/src/core/sources/types.ts +17 -0
- package/src/core/static-files.ts +40 -0
- package/src/core/static-host.ts +125 -0
- package/src/core/svg-images.ts +98 -0
- package/src/core/syntax-diagnostics.ts +491 -0
- package/src/core/types.ts +43 -1
- package/src/deploy/artifacts.ts +2 -28
- package/src/deploy/generated-files.ts +128 -0
- package/src/deploy/platforms/vercel.ts +25 -1
- package/src/deploy/redirects.ts +43 -16
- package/src/deploy/sitemap.ts +2 -1
- package/src/markdown/base-links.ts +87 -6
- package/src/markdown/code-title.ts +29 -13
- package/src/markdown/content-assets.ts +210 -0
- package/src/markdown/directives.ts +69 -5
- package/src/markdown/fence-language.ts +106 -0
- package/src/markdown/fence-meta.ts +42 -0
- package/src/markdown/github-alerts.ts +172 -0
- package/src/markdown/heading-anchors.ts +265 -56
- package/src/markdown/include.ts +30 -3
- package/src/markdown/index.ts +145 -40
- package/src/markdown/prompt-text.ts +95 -0
- package/src/markdown/relative-links.ts +37 -2
- package/src/markdown/route-snapshot.ts +22 -12
- package/src/markdown/svg-fallback.ts +51 -0
- package/src/markdown/title-heading.ts +134 -0
- package/src/migrate/migrate.ts +127 -2
- package/src/og/card.ts +14 -4
- package/src/openapi/asyncapi.ts +14 -6
- package/src/openapi/checks.ts +160 -15
- package/src/openapi/model.ts +172 -33
- package/src/openapi/parse.ts +13 -4
- package/src/openapi/render-mdx.ts +55 -9
- package/src/openapi/source.ts +87 -6
- package/src/registry/eject.ts +0 -1
- package/src/search/documents.ts +10 -2
- package/src/sources/filesystem.ts +28 -3
- package/src/sources/mdx-remote.ts +7 -15
- package/src/theme/color.ts +14 -0
- package/src/theme/entry.ts +22 -1
- package/src/theme/palette.ts +74 -1
- package/dist/cli/chunk-0pmb4tr4.js.map +0 -35
- package/dist/cli/chunk-0w6hs479.js.map +0 -10
- package/dist/cli/chunk-150jk7km.js +0 -52
- package/dist/cli/chunk-150jk7km.js.map +0 -10
- package/dist/cli/chunk-36bxs9c7.js.map +0 -10
- package/dist/cli/chunk-53jqw8z0.js +0 -89
- package/dist/cli/chunk-53jqw8z0.js.map +0 -10
- package/dist/cli/chunk-60hz265r.js.map +0 -10
- package/dist/cli/chunk-desvm72z.js.map +0 -14
- package/dist/cli/chunk-dpy8qdjf.js.map +0 -17
- package/dist/cli/chunk-es8h0v3j.js +0 -441
- package/dist/cli/chunk-es8h0v3j.js.map +0 -11
- package/dist/cli/chunk-kdpzw38a.js.map +0 -11
- package/dist/cli/chunk-nbyvgnnm.js.map +0 -36
- package/dist/cli/chunk-s0bdnc7v.js.map +0 -10
- package/dist/cli/chunk-twy7psdz.js.map +0 -10
- package/dist/cli/chunk-ydp3065p.js +0 -64
- package/dist/cli/chunk-ydp3065p.js.map +0 -10
- /package/dist/cli/{chunk-74wfhv79.js.map → chunk-05f21r8h.js.map} +0 -0
- /package/dist/cli/{chunk-9qzgg6mj.js.map → chunk-1cm0h819.js.map} +0 -0
- /package/dist/cli/{chunk-ms9z66nz.js.map → chunk-4rftmttv.js.map} +0 -0
- /package/dist/cli/{chunk-hvcxng5f.js.map → chunk-7tekknev.js.map} +0 -0
- /package/dist/cli/{chunk-bxwhtvw8.js.map → chunk-ahc5gc9h.js.map} +0 -0
- /package/dist/cli/{chunk-tfycddbt.js.map → chunk-bjk964fp.js.map} +0 -0
- /package/dist/cli/{chunk-dqhg54mr.js.map → chunk-dmx6cezx.js.map} +0 -0
- /package/dist/cli/{chunk-ave1wcbr.js.map → chunk-m9bp2hc1.js.map} +0 -0
- /package/dist/cli/{chunk-58bt3hag.js.map → chunk-mrvh4c88.js.map} +0 -0
- /package/dist/cli/{chunk-1f882900.js.map → chunk-th0pgaj5.js.map} +0 -0
- /package/dist/cli/{chunk-dhwtqnnd.js.map → chunk-vnbvhgmd.js.map} +0 -0
- /package/dist/cli/{chunk-j1x92mx9.js.map → chunk-w6e455pz.js.map} +0 -0
- /package/dist/cli/{chunk-y4msrwm9.js.map → chunk-xgq4eytj.js.map} +0 -0
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import type { SkillArtifact } from "../ai/skills.ts";
|
|
2
|
+
import type { BlumeProject } from "../core/project-graph.ts";
|
|
3
|
+
import type { ResolvedConfig } from "../core/schema.ts";
|
|
4
|
+
/** A generated `.well-known` discovery document: `null` content when it's off. */
|
|
5
|
+
export interface WellKnownFile {
|
|
6
|
+
content: string | null;
|
|
7
|
+
label: string;
|
|
8
|
+
path: string;
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* The generated `.well-known` discovery documents — the Web Bot Auth signature
|
|
12
|
+
* directory, the RFC 9727 API catalog, and the AI catalog under both the
|
|
13
|
+
* ai-catalog spec's well-known URI and the ARD v0.91 one (see
|
|
14
|
+
* `ai/ai-catalog.ts`) — each with `null` content when its feature is off.
|
|
15
|
+
*/
|
|
16
|
+
export declare const wellKnownFiles: (config: ResolvedConfig, skills: readonly SkillArtifact[]) => WellKnownFile[];
|
|
17
|
+
/**
|
|
18
|
+
* The files a build serves beside its pages that don't come from `public/`,
|
|
19
|
+
* as base-less root-relative paths: what `publishBuildArtifacts` writes once
|
|
20
|
+
* Astro is done (llms.txt, the sitemap, robots.txt, `agent-readability.json`,
|
|
21
|
+
* the `.well-known` discovery documents, the Agent Skills index, `skill.md`)
|
|
22
|
+
* and the generated endpoints at fixed paths (the RSS feeds, the JSON docs
|
|
23
|
+
* API and its OpenAPI description, the MCP discovery documents). Each is
|
|
24
|
+
* listed under the gate its writer reads, so a feature the config switches
|
|
25
|
+
* off drops its file here too: `blume validate` accepts a link to
|
|
26
|
+
* `/llms.txt` exactly when the build writes one.
|
|
27
|
+
*
|
|
28
|
+
* Read from the config alone, before a build: the skill archives a build
|
|
29
|
+
* publishes beside the index, and the platform files (`_redirects`,
|
|
30
|
+
* `_headers`, `vercel.json`), aren't listed. A page's Markdown copy
|
|
31
|
+
* (`/guide.md`) is its route's, and resolves through the page.
|
|
32
|
+
*/
|
|
33
|
+
export declare const generatedFilePaths: (project: BlumeProject) => string[];
|
|
34
|
+
/**
|
|
35
|
+
* Whether a base-less path is a file the project's site serves beside its
|
|
36
|
+
* pages: one in `public/` (`/spec.pdf`, a folder's `index.html`) or one the
|
|
37
|
+
* build generates (`/llms.txt`). What `generateRuntime` and `blume doctor`
|
|
38
|
+
* check navigation entries against, beside the routes, as `blume validate`
|
|
39
|
+
* checks links.
|
|
40
|
+
*/
|
|
41
|
+
export declare const servedFiles: (project: BlumeProject) => ((path: string) => boolean);
|
|
@@ -41,15 +41,29 @@ export declare const applyBaseToAstroRedirects: (redirects: Redirect[], basePath
|
|
|
41
41
|
* public file (see {@link baseRedirectTarget}).
|
|
42
42
|
*/
|
|
43
43
|
export declare const applyBaseToPlatformRedirects: (redirects: Redirect[], basePath: string, deployBase: string, routes: RouteSet) => Redirect[];
|
|
44
|
+
/**
|
|
45
|
+
* Whether `from` names a page's own `index.html` (`/guide/index.html` for the
|
|
46
|
+
* page `/guide`, `/index.html` for the root), a URL a migrated site may have
|
|
47
|
+
* linked. A static build writes the page there, and Astro writes a redirect
|
|
48
|
+
* page to `<from>/index.html`, which would need that file to be a folder:
|
|
49
|
+
* the build fails with `EISDIR`. Hosts serve the page at that URL anyway,
|
|
50
|
+
* unless a redirect rule answers it first. `pages` are the served page
|
|
51
|
+
* routes, which carry `basePath`, as `from` does.
|
|
52
|
+
*/
|
|
53
|
+
export declare const isPageIndexFile: (from: string, pages: RouteSet) => boolean;
|
|
44
54
|
/**
|
|
45
55
|
* Based `redirects`, each exact one that moves a page followed by the same
|
|
46
|
-
* redirect for the page's Markdown copies: from a path no page
|
|
47
|
-
* to one a page is, `/old.md` goes to `/new.md` (and `.mdx`
|
|
48
|
-
* would otherwise 404 for an agent still reading the old
|
|
49
|
-
*
|
|
50
|
-
*
|
|
51
|
-
*
|
|
52
|
-
*
|
|
56
|
+
* redirect for the page's Markdown copies: from a path whose copies no page
|
|
57
|
+
* serves to one a page is served at, `/old.md` goes to `/new.md` (and `.mdx`
|
|
58
|
+
* alike), where it would otherwise 404 for an agent still reading the old
|
|
59
|
+
* URL. A served copy never gives way: `/index` names the root's copies, so
|
|
60
|
+
* `/index` → `/` moving them would turn the home page's `/index.md` into a
|
|
61
|
+
* redirect to itself. A pattern gets none; one that carries its capture over
|
|
62
|
+
* (`/beta/:slug*` → `/v2/:slug*`) already moves `/beta/guide.md` along. Nor
|
|
63
|
+
* does a redirect from an `.html` file (`/guide.html`, from a migrated site),
|
|
64
|
+
* which had no copy to move. `pages` are the served page routes (carrying
|
|
65
|
+
* `basePath`, not `deployment.base`), and `bases` the deployment base each
|
|
66
|
+
* end carries: Astro's config leaves it off `from` (see
|
|
53
67
|
* {@link applyBaseToAstroRedirects}).
|
|
54
68
|
*/
|
|
55
69
|
export declare const withMirrorRedirects: (redirects: Redirect[], pages: RouteSet, bases: {
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
* Code-fence meta. A Shiki transformer reads the tokens after the language and
|
|
3
3
|
* promotes them to attributes on the rendered `<pre>`:
|
|
4
4
|
*
|
|
5
|
-
* - a title — the
|
|
6
|
-
* becomes `data-title`; the theme's code header
|
|
7
|
-
* language label.
|
|
5
|
+
* - a title — the bare words (```ts blume.config.ts, ```js Install the
|
|
6
|
+
* client) or `title="..."` — becomes `data-title`; the theme's code header
|
|
7
|
+
* shows it, falling back to the language label.
|
|
8
8
|
* - the `lineNumbers` keyword (```ts file.ts lineNumbers) becomes
|
|
9
9
|
* `data-line-numbers`; the theme renders a counter-driven line-number gutter.
|
|
10
10
|
* - the `wrap` keyword becomes `data-wrap`: this block's long lines wrap
|
|
@@ -24,6 +24,7 @@ export declare const EXPANDABLE_MIN_LINES = 16;
|
|
|
24
24
|
/** The slice of Shiki's transformer `this` context Blume reads. */
|
|
25
25
|
interface CodeMetaContext {
|
|
26
26
|
options: {
|
|
27
|
+
lang?: string;
|
|
27
28
|
meta?: {
|
|
28
29
|
__raw?: string;
|
|
29
30
|
};
|
|
@@ -40,8 +41,11 @@ export interface CodeTitleTransformer {
|
|
|
40
41
|
name: string;
|
|
41
42
|
pre: (this: CodeMetaContext, node: PreNode) => void;
|
|
42
43
|
}
|
|
43
|
-
/**
|
|
44
|
-
|
|
44
|
+
/**
|
|
45
|
+
* The title a fence's meta string promotes to `data-title`, if any. `lang` is
|
|
46
|
+
* the fence's language, which decides the other tools' keywords it drops.
|
|
47
|
+
*/
|
|
48
|
+
export declare const parseCodeTitle: (raw: string | undefined, lang?: string) => string | undefined;
|
|
45
49
|
/** How many lines a block's code runs to, a trailing newline aside. */
|
|
46
50
|
export declare const lineCount: (source?: string) => number;
|
|
47
51
|
/** Build the transformer. Runs after Shiki's built-in `data-language` hook. */
|
|
@@ -31,6 +31,14 @@ interface CalloutAliases {
|
|
|
31
31
|
export declare const CALLOUT_ALIASES: Readonly<CalloutAliases>;
|
|
32
32
|
/** Resolve a directive name to a Callout type, or `null` if it is not one. */
|
|
33
33
|
export declare const calloutTypeFor: (name: string) => string | null;
|
|
34
|
+
/**
|
|
35
|
+
* A node's phrasing children (a directive label's, a paragraph's) written
|
|
36
|
+
* back as inline Markdown, for a component prop that renders it — a callout
|
|
37
|
+
* title. Text, emphasis, strong, strikethrough, code, and links keep their
|
|
38
|
+
* formatting; anything else reads as its text (an image as nothing, raw HTML
|
|
39
|
+
* as its literal source), the way a flattened title always did.
|
|
40
|
+
*/
|
|
41
|
+
export declare const phrasingMarkdown: (parent: MdastNode) => string;
|
|
34
42
|
/**
|
|
35
43
|
* A text or leaf directive exactly as the author wrote it. The slice by
|
|
36
44
|
* offsets is the exact text — `[label]` and `{attrs}` included — and is
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A code fence's language, read the way authors coming from other docs tools
|
|
3
|
+
* write it. Shiki matches language ids exactly, so two common spellings used
|
|
4
|
+
* to fall back to plain text with only a console line:
|
|
5
|
+
*
|
|
6
|
+
* - a capitalized id (```` ```JSON ````, ```` ```Dockerfile ````): Shiki's ids
|
|
7
|
+
* and aliases are all lowercase, so the id is lowercased when that names a
|
|
8
|
+
* language and the spelling as written doesn't.
|
|
9
|
+
* - a line range glued to the id (```` ```js{2} ````, the VitePress and
|
|
10
|
+
* VuePress form): the range moves into the fence meta, ahead of any meta
|
|
11
|
+
* already there, where the line-highlight transformer reads it.
|
|
12
|
+
* - a line range glued to a bracketed title (```` ```ts [file.ts]{2} ````,
|
|
13
|
+
* the Docus form): a space splits it off, so the title is the bracketed
|
|
14
|
+
* word alone and the range stays a range.
|
|
15
|
+
*
|
|
16
|
+
* Every other fence keeps its language and meta exactly as written.
|
|
17
|
+
*/
|
|
18
|
+
import type { MdastNode } from "./mdast.ts";
|
|
19
|
+
/** Whether Shiki highlights `lang` as written: a bundled id, alias, or plain. */
|
|
20
|
+
export declare const isKnownLanguage: (lang: string) => boolean;
|
|
21
|
+
/** A fence's language and meta, after {@link normalizeFence}. */
|
|
22
|
+
export interface Fence {
|
|
23
|
+
lang: string;
|
|
24
|
+
meta: string | null;
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* The language and meta a fence means, or null when it means what it says.
|
|
28
|
+
* A range glued to the language moves into the meta and one glued to a
|
|
29
|
+
* bracketed title splits off it, then a capitalized language that only names
|
|
30
|
+
* a known language in lowercase is lowercased.
|
|
31
|
+
*/
|
|
32
|
+
export declare const normalizeFence: (lang: string | null | undefined, meta: string | null | undefined) => Fence | null;
|
|
33
|
+
/** The code node slice the plugin reads. */
|
|
34
|
+
interface CodeNode extends MdastNode {
|
|
35
|
+
lang?: string | null;
|
|
36
|
+
meta?: string | null;
|
|
37
|
+
}
|
|
38
|
+
/** The visitor context slice the plugin writes through. */
|
|
39
|
+
interface FenceContext {
|
|
40
|
+
setProperty: (node: CodeNode, key: "lang" | "meta", value: string | null) => void;
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* Satteri MDAST plugin applying {@link normalizeFence} to every fence. It runs
|
|
44
|
+
* before the plugins that read a fence's language (`package-install`, `ts2js`,
|
|
45
|
+
* mermaid) and before Shiki, so all of them see the normalized fence.
|
|
46
|
+
*/
|
|
47
|
+
export declare const fenceLanguagePlugin: () => {
|
|
48
|
+
code(node: CodeNode, ctx: FenceContext): void;
|
|
49
|
+
name: string;
|
|
50
|
+
};
|
|
51
|
+
export {};
|
|
@@ -19,5 +19,10 @@ export declare const metaTokens: (meta: string | null | undefined) => string[];
|
|
|
19
19
|
* a block title.
|
|
20
20
|
*/
|
|
21
21
|
export declare const RESERVED_META_KEYWORDS: ReadonlySet<string>;
|
|
22
|
+
export declare const RUST_META_KEYWORDS: ReadonlySet<string>;
|
|
23
|
+
/** The fence languages rustdoc's and mdBook's keywords apply to. */
|
|
24
|
+
export declare const RUST_LANGUAGES: ReadonlySet<string>;
|
|
25
|
+
/** Whether `token` is another tool's keyword in a fence of language `lang`. */
|
|
26
|
+
export declare const isForeignKeyword: (token: string, lang: string | null | undefined) => boolean;
|
|
22
27
|
/** A Shiki `{1,3-5}` line-range token. */
|
|
23
28
|
export declare const isLineRange: (token: string) => boolean;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import type { MdastNode, MdastVisitorContext } from "./mdast.ts";
|
|
2
|
+
/**
|
|
3
|
+
* The callout each GitHub alert renders as. `IMPORTANT` has no callout of its
|
|
4
|
+
* own and reads as a note (`:::important` does too), and `CAUTION` — GitHub's
|
|
5
|
+
* red "risks or negative outcomes" alert — as danger.
|
|
6
|
+
*/
|
|
7
|
+
export declare const ALERT_CALLOUTS: ReadonlyMap<string, string>;
|
|
8
|
+
/** An alert marker as written (`[!NOTE]`) and the callout it renders as. */
|
|
9
|
+
export interface AlertMarker {
|
|
10
|
+
callout: string;
|
|
11
|
+
marker: string;
|
|
12
|
+
}
|
|
13
|
+
/** The alert marker a quote's first text opens with, if any. */
|
|
14
|
+
export declare const alertMarkerOf: (text: string) => AlertMarker | undefined;
|
|
15
|
+
/** The visitor-context slice the alert visitor uses. */
|
|
16
|
+
interface AlertVisitorContext extends MdastVisitorContext {
|
|
17
|
+
parent?: (node: MdastNode) => MdastNode | undefined;
|
|
18
|
+
source?: string;
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* Satteri MDAST plugin for GitHub alerts in `.mdx`: a quote whose first line
|
|
22
|
+
* is `[!NOTE]`, `[!TIP]`, `[!IMPORTANT]`, `[!WARNING]`, or `[!CAUTION]`
|
|
23
|
+
* renders as the matching `<Callout>` (see {@link ALERT_CALLOUTS}), as on
|
|
24
|
+
* GitHub. An alert quoted inside another stays a quote, as GitHub leaves it.
|
|
25
|
+
* `.md` pages render no components, so their alerts stay quotes, which
|
|
26
|
+
* `blume check` warns about (`core/alert-diagnostics.ts`).
|
|
27
|
+
*/
|
|
28
|
+
export declare const githubAlertsPlugin: () => {
|
|
29
|
+
blockquote(node: MdastNode, ctx: AlertVisitorContext): void;
|
|
30
|
+
name: string;
|
|
31
|
+
options: {
|
|
32
|
+
position: boolean;
|
|
33
|
+
};
|
|
34
|
+
};
|
|
35
|
+
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ApiOperationRef,
|
|
1
|
+
import type { ApiOperationRef, CollectedOperations } from "./model.ts";
|
|
2
2
|
/**
|
|
3
3
|
* Blume's own AsyncAPI model — the second front-end of the API reference
|
|
4
4
|
* pipeline. Specs are normalized to AsyncAPI 3.x at parse time (see
|
|
@@ -108,10 +108,11 @@ export declare const applyAsyncApiTraits: (document: AsyncApiDocument) => AsyncA
|
|
|
108
108
|
* see plain channel/operation objects, trait-free.
|
|
109
109
|
*/
|
|
110
110
|
export declare const normalizeAsyncApiDocument: (document: AsyncApiDocument) => AsyncApiDocument;
|
|
111
|
-
/**
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
111
|
+
/**
|
|
112
|
+
* The route-mapped operations, ordered tags, moved routes, and skip warnings
|
|
113
|
+
* of one document.
|
|
114
|
+
*/
|
|
115
|
+
export interface AsyncApiOperationCatalog extends CollectedOperations {
|
|
115
116
|
warnings: string[];
|
|
116
117
|
}
|
|
117
118
|
/**
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { JsonValue } from "../core/adapter.ts";
|
|
1
2
|
import type { ApiDocument } from "./model.ts";
|
|
2
3
|
/**
|
|
3
4
|
* Targeted checks for spec mistakes that would otherwise render silently
|
|
@@ -14,14 +15,18 @@ export interface SpecIssue {
|
|
|
14
15
|
message: string;
|
|
15
16
|
suggestion: string;
|
|
16
17
|
}
|
|
17
|
-
/**
|
|
18
|
-
* How a warning names an operation: `GET /pets`, or a webhook by its name
|
|
19
|
-
* (`Webhook "newPet" (POST)`), since a webhook has no path.
|
|
20
|
-
*/
|
|
21
|
-
export declare const operationLabel: (name: string, method: string, webhook: boolean) => string;
|
|
22
18
|
/**
|
|
23
19
|
* Check a parsed document for the mistakes above, and for the OpenAPI 3.2
|
|
24
20
|
* features Blume doesn't render yet. `$ref` path items are skipped: the
|
|
25
21
|
* extractor already reports them as missing from the reference.
|
|
26
22
|
*/
|
|
27
23
|
export declare const specIssues: (document: ApiDocument) => SpecIssue[];
|
|
24
|
+
/**
|
|
25
|
+
* A spec written as OpenAPI 3.1 or later that still uses `nullable`, which
|
|
26
|
+
* 3.1 removed for `type: [T, "null"]`. Read as written (before Blume
|
|
27
|
+
* upgrades a 3.0 spec, which rewrites `nullable` itself), since that's the
|
|
28
|
+
* document the author edits. Blume still renders those values as nullable,
|
|
29
|
+
* but validators and SDK generators that follow 3.1 read them as never
|
|
30
|
+
* null. One warning per spec, naming the first few places.
|
|
31
|
+
*/
|
|
32
|
+
export declare const nullableIssues: (document: JsonValue) => SpecIssue[];
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import type { Document, OperationObject } from "@scalar/openapi-types/3.2";
|
|
2
2
|
import type { GraphqlAuthOptions } from "../reference/options.ts";
|
|
3
3
|
import type { AsyncApiAction, AsyncApiDocument, AsyncApiSpecValue } from "./asyncapi.ts";
|
|
4
|
+
import type { SpecIssue } from "./checks.ts";
|
|
4
5
|
import type { GraphqlDocument, GraphqlMember } from "./graphql.ts";
|
|
5
6
|
import type { ReferenceKind } from "./references.ts";
|
|
6
7
|
export { slugify } from "./references.ts";
|
|
@@ -150,19 +151,48 @@ export declare const withServerDefaults: (template: string, variables: AsyncApiS
|
|
|
150
151
|
* silently merges the tags' routes, sidebar groups, and overview sections.
|
|
151
152
|
* Collisions gain `-2`, `-3`, … in first-seen order. Shared with the AsyncAPI
|
|
152
153
|
* extractor (`asyncapi.ts`), whose untagged fallback groups are channel
|
|
153
|
-
* addresses.
|
|
154
|
+
* addresses. `slug` is the rule before collisions: the collector also runs
|
|
155
|
+
* the one earlier releases used (`slugify` alone, so `InboxesThreads` ->
|
|
156
|
+
* `inboxesthreads`) to redirect the routes they gave.
|
|
154
157
|
*/
|
|
155
|
-
export declare const tagSlugger: () => ((name: string) => string);
|
|
158
|
+
export declare const tagSlugger: (slug?: (name: string) => string) => ((name: string) => string);
|
|
159
|
+
/**
|
|
160
|
+
* How a warning names an operation: `GET /pets`, or a webhook by its name
|
|
161
|
+
* (`Webhook "newPet" (POST)`), since a webhook has no path.
|
|
162
|
+
*/
|
|
163
|
+
export declare const operationLabel: (name: string, method: string, webhook: boolean) => string;
|
|
156
164
|
/** An operation before the collector assigns its unique key and route. */
|
|
157
165
|
type CollectedOperation = Omit<ApiOperationRef, "route" | "tagSlug">;
|
|
166
|
+
/** What a spec's `tags` list says about one tag. */
|
|
167
|
+
export interface ApiTagMeta {
|
|
168
|
+
description: string;
|
|
169
|
+
/**
|
|
170
|
+
* The tag's label, in place of its name, from Redocly's `x-displayName`
|
|
171
|
+
* extension. Only the label changes: the tag's slug, and so its routes,
|
|
172
|
+
* still come from its name.
|
|
173
|
+
*/
|
|
174
|
+
displayName?: string;
|
|
175
|
+
}
|
|
176
|
+
/**
|
|
177
|
+
* A route an earlier release gave an operation's page, and the route the
|
|
178
|
+
* page has now: the source turns each into a redirect, so links to the old
|
|
179
|
+
* URL keep working.
|
|
180
|
+
*/
|
|
181
|
+
export interface MovedRoute {
|
|
182
|
+
from: string;
|
|
183
|
+
to: string;
|
|
184
|
+
}
|
|
158
185
|
/** The flattened output both extractors produce. */
|
|
159
186
|
export interface CollectedOperations {
|
|
160
187
|
operations: ApiOperationRef[];
|
|
161
188
|
tags: ApiTagRef[];
|
|
189
|
+
/** Operation routes that moved from what earlier slug rules gave them. */
|
|
190
|
+
moved: MovedRoute[];
|
|
162
191
|
}
|
|
163
192
|
/** The collector handle: feed operations in, read the flattened output out. */
|
|
164
193
|
export interface OperationCollector {
|
|
165
|
-
|
|
194
|
+
/** Add an operation, returning it with its key and route assigned. */
|
|
195
|
+
add: (entry: CollectedOperation) => ApiOperationRef;
|
|
166
196
|
finish: () => CollectedOperations;
|
|
167
197
|
}
|
|
168
198
|
/** {@link CollectedOperations} plus anything the extractor had to skip. */
|
|
@@ -175,15 +205,32 @@ export interface ExtractedOperations extends CollectedOperations {
|
|
|
175
205
|
* (a repeated key gains its method/action as a suffix), and the shared route
|
|
176
206
|
* template — so URL shape and slug rules can never drift between the two spec
|
|
177
207
|
* kinds.
|
|
208
|
+
*
|
|
209
|
+
* A key is unique across the spec, since it names the operation in
|
|
210
|
+
* `<Operation id>`. Its page's URL only has to be unique within its tag's
|
|
211
|
+
* folder, so the last route segment de-duplicates per tag: `list` in two
|
|
212
|
+
* tags is `/pets/list` and `/stores/list`, not `/stores/list-get`. Earlier
|
|
213
|
+
* releases de-duplicated the route like the key, and slugged tags without
|
|
214
|
+
* splitting their words; each route those rules gave differently is
|
|
215
|
+
* reported in `moved`.
|
|
178
216
|
*/
|
|
179
|
-
export declare const operationCollector: (baseRoute: string, tagMeta: ReadonlyMap<string,
|
|
217
|
+
export declare const operationCollector: (baseRoute: string, tagMeta: ReadonlyMap<string, ApiTagMeta>) => OperationCollector;
|
|
218
|
+
/** {@link ExtractedOperations} plus the spec mistakes extraction noticed. */
|
|
219
|
+
export interface ExtractedApiOperations extends ExtractedOperations {
|
|
220
|
+
issues: SpecIssue[];
|
|
221
|
+
}
|
|
180
222
|
/**
|
|
181
223
|
* Flatten a 3.1 document into a route-mapped operation list and its ordered
|
|
182
224
|
* tags, webhooks included. Operations inherit the first tag they declare; keys
|
|
183
|
-
* are de-duplicated so a repeated `operationId` still yields distinct routes
|
|
184
|
-
* `warnings` reports anything skipped (a
|
|
185
|
-
* operations aren't silent.
|
|
225
|
+
* are de-duplicated so a repeated `operationId` still yields distinct routes,
|
|
226
|
+
* with an issue naming both operations. `warnings` reports anything skipped (a
|
|
227
|
+
* `$ref` path item), so missing operations aren't silent.
|
|
228
|
+
*
|
|
229
|
+
* Operations come out in the spec's order: paths as listed, and each path's
|
|
230
|
+
* methods as written. They're keyed in the method order earlier releases
|
|
231
|
+
* walked (`HTTP_METHODS`), so a repeated id resolves to the same key, and
|
|
232
|
+
* the same route, it always did.
|
|
186
233
|
*/
|
|
187
|
-
export declare const extractOperations: (document: ApiDocument, baseRoute: string) =>
|
|
234
|
+
export declare const extractOperations: (document: ApiDocument, baseRoute: string) => ExtractedApiOperations;
|
|
188
235
|
/** Resolve the operation object for a ref out of its (OpenAPI) document. */
|
|
189
236
|
export declare const operationObject: (spec: ApiSpecData, ref: ApiOperationRef) => OperationObject | undefined;
|
|
@@ -4,7 +4,10 @@ import type { GraphqlDocument } from "./graphql.ts";
|
|
|
4
4
|
import type { ApiDocument } from "./model.ts";
|
|
5
5
|
export interface ParsedSpec {
|
|
6
6
|
document: ApiDocument;
|
|
7
|
-
/**
|
|
7
|
+
/**
|
|
8
|
+
* Issues only the spec as written shows: `nullable` in a 3.1 spec, and
|
|
9
|
+
* `x-codeSamples` entries whose `$ref` couldn't be inlined.
|
|
10
|
+
*/
|
|
8
11
|
issues: SpecIssue[];
|
|
9
12
|
warnings: string[];
|
|
10
13
|
}
|
|
@@ -3,11 +3,21 @@ import type { AdapterDescriptor } from "../core/adapter.ts";
|
|
|
3
3
|
import type { SharedSourceOptions } from "./shared.ts";
|
|
4
4
|
/** What `include` defaults to: every Markdown/MDX file under the root. */
|
|
5
5
|
export declare const DEFAULT_CONTENT_INCLUDE: string[];
|
|
6
|
-
/** What `exclude`
|
|
6
|
+
/** What `exclude` always holds: underscore- and dot-prefixed paths. */
|
|
7
7
|
export declare const DEFAULT_CONTENT_EXCLUDE: string[];
|
|
8
|
+
/**
|
|
9
|
+
* A source's `exclude` as the scan applies it: the defaults, plus the
|
|
10
|
+
* author's patterns. A `!pattern` entry takes that exact pattern back out, a
|
|
11
|
+
* default included, so `["!**\/_*"]` publishes `_`-prefixed files. The glob
|
|
12
|
+
* library can't negate an ignore pattern itself.
|
|
13
|
+
*/
|
|
14
|
+
export declare const resolveContentExclude: (patterns: readonly string[]) => string[];
|
|
8
15
|
/** Options for {@link filesystem}. */
|
|
9
16
|
export interface FilesystemOptions extends SharedSourceOptions {
|
|
10
|
-
/**
|
|
17
|
+
/**
|
|
18
|
+
* Glob patterns to ignore, on top of `["**\/_*", "**\/.*"]`. A `!pattern`
|
|
19
|
+
* entry stops ignoring that pattern, a default included.
|
|
20
|
+
*/
|
|
11
21
|
exclude?: string[];
|
|
12
22
|
/** Glob patterns to include. Defaults to `["**\/*.{md,mdx}"]`. */
|
|
13
23
|
include?: string[];
|
|
@@ -17,7 +27,7 @@ export interface FilesystemOptions extends SharedSourceOptions {
|
|
|
17
27
|
export declare const filesystemOptionsSchema: z.ZodObject<{
|
|
18
28
|
pollInterval: z.ZodOptional<z.ZodNumber>;
|
|
19
29
|
prefix: z.ZodOptional<z.ZodString>;
|
|
20
|
-
exclude: z.ZodDefault<z.ZodArray<z.ZodString>>;
|
|
30
|
+
exclude: z.ZodPipe<z.ZodDefault<z.ZodArray<z.ZodString>>, z.ZodTransform<string[], string[]>>;
|
|
21
31
|
include: z.ZodDefault<z.ZodArray<z.ZodString>>;
|
|
22
32
|
root: z.ZodDefault<z.ZodString>;
|
|
23
33
|
}, z.core.$strict>;
|
|
@@ -27,7 +37,7 @@ export declare const filesystemAdapterSchema: z.ZodObject<{
|
|
|
27
37
|
options: z.ZodObject<{
|
|
28
38
|
pollInterval: z.ZodOptional<z.ZodNumber>;
|
|
29
39
|
prefix: z.ZodOptional<z.ZodString>;
|
|
30
|
-
exclude: z.ZodDefault<z.ZodArray<z.ZodString>>;
|
|
40
|
+
exclude: z.ZodPipe<z.ZodDefault<z.ZodArray<z.ZodString>>, z.ZodTransform<string[], string[]>>;
|
|
31
41
|
include: z.ZodDefault<z.ZodArray<z.ZodString>>;
|
|
32
42
|
root: z.ZodDefault<z.ZodString>;
|
|
33
43
|
}, z.core.$strict>;
|
|
@@ -56,8 +56,11 @@ export declare const mdxRemoteAdapterSchema: z.ZodObject<{
|
|
|
56
56
|
/**
|
|
57
57
|
* Remote Markdown/MDX fetched over HTTP. Enumerate files explicitly against a
|
|
58
58
|
* raw `url` base, or from a GitHub repo subtree via `github`. A private repo's
|
|
59
|
-
* token comes from `GITHUB_TOKEN` — never inline it here.
|
|
60
|
-
* the variable
|
|
61
|
-
*
|
|
59
|
+
* token comes from `GITHUB_TOKEN` — never inline it here. Only `github`
|
|
60
|
+
* declares the variable: it lists files through GitHub's API, whose
|
|
61
|
+
* unauthenticated rate limit a build can run into even for a public
|
|
62
|
+
* repository. A raw `url` needs no token for a public repository, so a fetch
|
|
63
|
+
* that fails for want of one names the variable instead (see
|
|
64
|
+
* core/sources/mdx-remote.ts).
|
|
62
65
|
*/
|
|
63
66
|
export declare const mdxRemote: (options: MdxRemoteOptions) => MdxRemoteAdapter;
|
|
@@ -18,7 +18,7 @@ declare const sourceAdapterUnion: z.ZodDiscriminatedUnion<readonly [z.ZodObject<
|
|
|
18
18
|
options: z.ZodObject<{
|
|
19
19
|
pollInterval: z.ZodOptional<z.ZodNumber>;
|
|
20
20
|
prefix: z.ZodOptional<z.ZodString>;
|
|
21
|
-
exclude: z.ZodDefault<z.ZodArray<z.ZodString>>;
|
|
21
|
+
exclude: z.ZodPipe<z.ZodDefault<z.ZodArray<z.ZodString>>, z.ZodTransform<string[], string[]>>;
|
|
22
22
|
include: z.ZodDefault<z.ZodArray<z.ZodString>>;
|
|
23
23
|
root: z.ZodDefault<z.ZodString>;
|
|
24
24
|
}, z.core.$strict>;
|
|
@@ -193,7 +193,7 @@ export declare const resolvedSourceAdapterSchema: z.ZodPipe<z.ZodDiscriminatedUn
|
|
|
193
193
|
options: z.ZodObject<{
|
|
194
194
|
pollInterval: z.ZodOptional<z.ZodNumber>;
|
|
195
195
|
prefix: z.ZodOptional<z.ZodString>;
|
|
196
|
-
exclude: z.ZodDefault<z.ZodArray<z.ZodString>>;
|
|
196
|
+
exclude: z.ZodPipe<z.ZodDefault<z.ZodArray<z.ZodString>>, z.ZodTransform<string[], string[]>>;
|
|
197
197
|
include: z.ZodDefault<z.ZodArray<z.ZodString>>;
|
|
198
198
|
root: z.ZodDefault<z.ZodString>;
|
|
199
199
|
}, z.core.$strict>;
|
|
@@ -998,7 +998,7 @@ export declare const contentSourcesSchema: z.ZodArray<z.ZodPipe<z.ZodCustom<{
|
|
|
998
998
|
options: z.ZodObject<{
|
|
999
999
|
pollInterval: z.ZodOptional<z.ZodNumber>;
|
|
1000
1000
|
prefix: z.ZodOptional<z.ZodString>;
|
|
1001
|
-
exclude: z.ZodDefault<z.ZodArray<z.ZodString>>;
|
|
1001
|
+
exclude: z.ZodPipe<z.ZodDefault<z.ZodArray<z.ZodString>>, z.ZodTransform<string[], string[]>>;
|
|
1002
1002
|
include: z.ZodDefault<z.ZodArray<z.ZodString>>;
|
|
1003
1003
|
root: z.ZodDefault<z.ZodString>;
|
|
1004
1004
|
}, z.core.$strict>;
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Just enough CSS color math to check contrast at build time: parse the color
|
|
3
|
+
* syntaxes a theme config takes (hex, `rgb()`, `hsl()`, `hwb()`, `lab()`,
|
|
4
|
+
* `lch()`, `oklab()`, `oklch()`, and named colors) to sRGB, then measure WCAG
|
|
5
|
+
* 2 relative luminance and contrast. A color outside sRGB is clipped to it,
|
|
6
|
+
* which is what a browser shows on an sRGB display. Anything else — `var()`,
|
|
7
|
+
* `color-mix()`, `color()` — parses to `null`, and the caller says it couldn't
|
|
8
|
+
* check it rather than guessing.
|
|
9
|
+
*/
|
|
10
|
+
/** An sRGB color: gamma-encoded channels and alpha, each 0–1. */
|
|
11
|
+
export interface Rgba {
|
|
12
|
+
alpha: number;
|
|
13
|
+
blue: number;
|
|
14
|
+
green: number;
|
|
15
|
+
red: number;
|
|
16
|
+
}
|
|
17
|
+
/** Parse a CSS color to sRGB, or `null` for syntax this module doesn't read. */
|
|
18
|
+
export declare const parseColor: (value: string) => Rgba | null;
|
|
19
|
+
/**
|
|
20
|
+
* Whether `value` is a CSS color: one `parseColor` reads, or a color function
|
|
21
|
+
* or keyword it leaves unread. Words that name no color (`deep purple`), and
|
|
22
|
+
* hex values with a wrong digit count or no `#`, are not.
|
|
23
|
+
*/
|
|
24
|
+
export declare const isCssColor: (value: string) => boolean;
|
|
25
|
+
/** `color` painted over an opaque `backdrop`. */
|
|
26
|
+
export declare const composite: (color: Rgba, backdrop: Rgba) => Rgba;
|
|
27
|
+
/** WCAG 2 relative luminance of an opaque color. */
|
|
28
|
+
export declare const luminance: (color: Rgba) => number;
|
|
29
|
+
/**
|
|
30
|
+
* WCAG 2 contrast ratio of `foreground` on an opaque `background`, from 1 to
|
|
31
|
+
* 21. A translucent foreground is painted over the background first.
|
|
32
|
+
*/
|
|
33
|
+
export declare const contrastRatio: (foreground: Rgba, background: Rgba) => number;
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
import type { ResolvedConfig } from "../core/schema.ts";
|
|
2
|
+
import type { Rgba } from "./color.ts";
|
|
3
|
+
/** Per-mode CSS colors. */
|
|
4
|
+
export interface AccentColors {
|
|
5
|
+
dark: string;
|
|
6
|
+
light: string;
|
|
7
|
+
}
|
|
8
|
+
/** A color mode. */
|
|
9
|
+
export type ColorMode = keyof AccentColors;
|
|
10
|
+
/**
|
|
11
|
+
* Named accent presets mapped to OKLCH values, per mode. The single source of
|
|
12
|
+
* truth for preset colors: the theme CSS and the OG card (og/card.ts) both
|
|
13
|
+
* resolve from this table, so a site and its social cards can't disagree
|
|
14
|
+
* about "blue". Each clears WCAG AA (4.5:1) as text on its mode's page and
|
|
15
|
+
* under its button label ({@link readableOn}), with room to spare on the
|
|
16
|
+
* tinted surfaces accent text also sits on: the light shades are dark enough
|
|
17
|
+
* for white labels, the dark shades light enough to read on the dark page.
|
|
18
|
+
*/
|
|
19
|
+
export declare const ACCENTS: {
|
|
20
|
+
blue: {
|
|
21
|
+
dark: string;
|
|
22
|
+
light: string;
|
|
23
|
+
};
|
|
24
|
+
green: {
|
|
25
|
+
dark: string;
|
|
26
|
+
light: string;
|
|
27
|
+
};
|
|
28
|
+
orange: {
|
|
29
|
+
dark: string;
|
|
30
|
+
light: string;
|
|
31
|
+
};
|
|
32
|
+
pink: {
|
|
33
|
+
dark: string;
|
|
34
|
+
light: string;
|
|
35
|
+
};
|
|
36
|
+
purple: {
|
|
37
|
+
dark: string;
|
|
38
|
+
light: string;
|
|
39
|
+
};
|
|
40
|
+
red: {
|
|
41
|
+
dark: string;
|
|
42
|
+
light: string;
|
|
43
|
+
};
|
|
44
|
+
teal: {
|
|
45
|
+
dark: string;
|
|
46
|
+
light: string;
|
|
47
|
+
};
|
|
48
|
+
};
|
|
49
|
+
/** The contrast WCAG AA asks of body-size text. */
|
|
50
|
+
export declare const MIN_TEXT_CONTRAST = 4.5;
|
|
51
|
+
/**
|
|
52
|
+
* The theme's own colors a configured accent is drawn against: each mode's
|
|
53
|
+
* page background and text, and the dark ink a filled accent can carry.
|
|
54
|
+
* Mirrors the defaults in `entry.ts`.
|
|
55
|
+
*/
|
|
56
|
+
export declare const THEME_INKS: {
|
|
57
|
+
dark: {
|
|
58
|
+
background: string;
|
|
59
|
+
foreground: string;
|
|
60
|
+
ink: string;
|
|
61
|
+
mutedForeground: string;
|
|
62
|
+
};
|
|
63
|
+
light: {
|
|
64
|
+
background: string;
|
|
65
|
+
foreground: string;
|
|
66
|
+
ink: string;
|
|
67
|
+
mutedForeground: string;
|
|
68
|
+
};
|
|
69
|
+
};
|
|
70
|
+
/** {@link THEME_INKS}, parsed, for contrast math. */
|
|
71
|
+
export declare const themeInk: (mode: ColorMode, name: keyof (typeof THEME_INKS)[ColorMode]) => Rgba;
|
|
72
|
+
/**
|
|
73
|
+
* The label color for text on a filled `fill` (a button, a step number): white
|
|
74
|
+
* while it reaches AA, else the mode's dark ink when that reads better, so a
|
|
75
|
+
* light accent (every dark-mode preset) gets dark text instead of white text
|
|
76
|
+
* nobody can read.
|
|
77
|
+
*/
|
|
78
|
+
export declare const labelOn: (fill: Rgba, mode: ColorMode) => string;
|
|
79
|
+
/** {@link labelOn} for a CSS color; one this module can't parse keeps white. */
|
|
80
|
+
export declare const readableOn: (fill: string, mode: ColorMode) => string;
|
|
81
|
+
/**
|
|
82
|
+
* Whether a raw config value names an accent preset. `hasOwn` keeps a value
|
|
83
|
+
* like "constructor" from resolving an Object.prototype member — which would
|
|
84
|
+
* stringify a function into the generated CSS, breaking the rule (the exact
|
|
85
|
+
* breakout {@link safeColor} exists to prevent).
|
|
86
|
+
*/
|
|
87
|
+
export declare const isAccentPreset: (value: string) => value is keyof typeof ACCENTS;
|
|
88
|
+
/**
|
|
89
|
+
* Resolve the configured accent to per-mode CSS colors. A named accent
|
|
90
|
+
* resolves to its preset's shade for each mode; any other value is treated as
|
|
91
|
+
* a raw CSS color so users can pass arbitrary colors without a config change.
|
|
92
|
+
* A string accent has already been normalized by the config schema to the
|
|
93
|
+
* same value for both modes.
|
|
94
|
+
*/
|
|
95
|
+
export declare const resolveAccent: (theme: ResolvedConfig["theme"]) => AccentColors;
|
|
96
|
+
/** Resolve the configured `action` fill per mode, or `null` when unset. */
|
|
97
|
+
export declare const resolveAction: (theme: ResolvedConfig["theme"]) => AccentColors | null;
|
|
98
|
+
/** Resolve the configured radius preset to a CSS length. */
|
|
99
|
+
export declare const resolveRadius: (theme: ResolvedConfig["theme"]) => string;
|
|
100
|
+
/**
|
|
101
|
+
* Compile theme config into CSS custom properties. A named accent resolves to
|
|
102
|
+
* its preset; any other value is treated as a raw CSS color so users can pass
|
|
103
|
+
* arbitrary colors without a config change. Labels on accent and action fills
|
|
104
|
+
* take whichever of white or dark ink reads ({@link readableOn}).
|
|
105
|
+
*/
|
|
106
|
+
export declare const buildThemeCss: (theme: ResolvedConfig["theme"]) => string;
|
|
107
|
+
/** A configured color: where the config sets it, and its value. */
|
|
108
|
+
export interface ColorSetting {
|
|
109
|
+
/** The config path, e.g. `["theme", "accent", "dark"]`. */
|
|
110
|
+
path: string[];
|
|
111
|
+
/** Whether the field also takes an accent preset name (`teal`). */
|
|
112
|
+
presets: boolean;
|
|
113
|
+
value: string;
|
|
114
|
+
}
|
|
115
|
+
/**
|
|
116
|
+
* The configured colors that aren't CSS colors (`"deep purple"`, a hex value
|
|
117
|
+
* missing its `#`): `theme.accent`, `theme.action`, and `theme.background`,
|
|
118
|
+
* and the OG card's `seo.og.palette`. The schema takes any string, so a
|
|
119
|
+
* mistake would otherwise reach the stylesheet, where browsers drop it, or
|
|
120
|
+
* the card renderer, which rejects it. Preset names are CSS color names too.
|
|
121
|
+
*/
|
|
122
|
+
export declare const invalidColorSettings: (config: ResolvedConfig) => ColorSetting[];
|
package/docs/01-quickstart.mdx
CHANGED
|
@@ -6,7 +6,7 @@ sidebar:
|
|
|
6
6
|
order: 1
|
|
7
7
|
---
|
|
8
8
|
|
|
9
|
-
Go from an empty folder to a running docs site in a few commands. Blume needs **Node.js 22.
|
|
9
|
+
Go from an empty folder to a running docs site in a few commands. Blume needs **Node.js 22.19 or newer** and a `docs/` folder with at least one `.md` or `.mdx` file — there's nothing else to set up.
|
|
10
10
|
|
|
11
11
|
## Install and run
|
|
12
12
|
|