blume 2.0.1 → 2.0.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 +147 -0
- package/dist/cli/{chunk-qwsrynx5.js → chunk-1d7ve1dm.js} +38 -19
- package/dist/cli/{chunk-qwsrynx5.js.map → chunk-1d7ve1dm.js.map} +4 -4
- package/dist/cli/{chunk-s6jhgk0q.js → chunk-2eytanqx.js} +2 -2
- package/dist/cli/{chunk-kdp5q7ke.js → chunk-2hsdwb9n.js} +18 -19
- package/dist/cli/{chunk-kdp5q7ke.js.map → chunk-2hsdwb9n.js.map} +2 -2
- package/dist/cli/{chunk-hdpx1tax.js → chunk-2z928egk.js} +5 -5
- package/dist/cli/{chunk-jwyddg7y.js → chunk-35d4wj9f.js} +30 -24
- package/dist/cli/chunk-35d4wj9f.js.map +15 -0
- package/dist/cli/{chunk-ah61y8py.js → chunk-364znk6q.js} +2 -2
- package/dist/cli/{chunk-jts8mvcz.js → chunk-3em5wd2y.js} +25 -6
- package/dist/cli/{chunk-jts8mvcz.js.map → chunk-3em5wd2y.js.map} +3 -3
- package/dist/cli/{chunk-s1p84fyh.js → chunk-5f86nr5m.js} +63 -22
- package/dist/cli/chunk-5f86nr5m.js.map +11 -0
- package/dist/cli/{chunk-2hn4b8z7.js → chunk-5m5nmvyq.js} +170 -76
- package/dist/cli/chunk-5m5nmvyq.js.map +13 -0
- package/dist/cli/{chunk-epjnccmv.js → chunk-5xvm6tfj.js} +18 -15
- package/dist/cli/chunk-5xvm6tfj.js.map +10 -0
- package/dist/cli/{chunk-fz5wtpmh.js → chunk-6dsbexzp.js} +18 -15
- package/dist/cli/chunk-6dsbexzp.js.map +10 -0
- package/dist/cli/{chunk-vtk4a6dg.js → chunk-8ktnccpt.js} +1 -1
- package/dist/cli/{chunk-6hsn950k.js → chunk-9t7a85s3.js} +178 -48
- package/dist/cli/chunk-9t7a85s3.js.map +10 -0
- package/dist/cli/{chunk-fxypxtvm.js → chunk-a58773jm.js} +2 -2
- package/dist/cli/{chunk-mb2919y2.js → chunk-acanzt5p.js} +17 -6
- package/dist/cli/chunk-acanzt5p.js.map +10 -0
- package/dist/cli/{chunk-27g6wdth.js → chunk-akbpwfxc.js} +90 -26
- package/dist/cli/chunk-akbpwfxc.js.map +10 -0
- package/dist/cli/{chunk-wm7js3j9.js → chunk-b07cmahc.js} +2 -2
- package/dist/cli/{chunk-wgm7m9qk.js → chunk-c8chx29p.js} +179 -51
- package/dist/cli/chunk-c8chx29p.js.map +36 -0
- package/dist/cli/{chunk-qs4q5p4e.js → chunk-crgn1q09.js} +32 -14
- package/dist/cli/chunk-crgn1q09.js.map +10 -0
- package/dist/cli/chunk-e04dxsz1.js +39 -0
- package/dist/cli/chunk-e04dxsz1.js.map +10 -0
- package/dist/cli/{chunk-yt5n7ppj.js → chunk-ey84smr6.js} +17 -7
- package/dist/cli/chunk-ey84smr6.js.map +10 -0
- package/dist/cli/{chunk-f2z5v128.js → chunk-g4hq16wv.js} +14 -15
- package/dist/cli/{chunk-f2z5v128.js.map → chunk-g4hq16wv.js.map} +2 -2
- package/dist/cli/{chunk-fa25z98p.js → chunk-ga0pf4aj.js} +9 -8
- package/dist/cli/chunk-ga0pf4aj.js.map +11 -0
- package/dist/cli/{chunk-kpf8rrjc.js → chunk-hm3vjy5s.js} +109 -58
- package/dist/cli/chunk-hm3vjy5s.js.map +19 -0
- package/dist/cli/{chunk-fs23ddbb.js → chunk-j85vccga.js} +625 -750
- package/dist/cli/chunk-j85vccga.js.map +36 -0
- package/dist/cli/{chunk-ch6g3ar0.js → chunk-p3v96n38.js} +6 -6
- package/dist/cli/{chunk-ch6g3ar0.js.map → chunk-p3v96n38.js.map} +3 -3
- package/dist/cli/{chunk-q5163e60.js → chunk-p73c0m7w.js} +21 -19
- package/dist/cli/chunk-p73c0m7w.js.map +11 -0
- package/dist/cli/{chunk-dh8cwk36.js → chunk-pehfxfta.js} +24 -9
- package/dist/cli/chunk-pehfxfta.js.map +10 -0
- package/dist/cli/{chunk-qkqwkpte.js → chunk-pv29h0wf.js} +3688 -1313
- package/dist/cli/chunk-pv29h0wf.js.map +190 -0
- package/dist/cli/{chunk-6vm74dry.js → chunk-q58y5e6a.js} +10 -10
- package/dist/cli/{chunk-6vm74dry.js.map → chunk-q58y5e6a.js.map} +3 -3
- package/dist/cli/{chunk-zxcczpyx.js → chunk-r20tn01b.js} +1 -1
- package/dist/cli/{chunk-m3vmjgmq.js → chunk-r9rcc4w7.js} +16 -8
- package/dist/cli/chunk-r9rcc4w7.js.map +10 -0
- package/dist/cli/{chunk-5shv93fd.js → chunk-tkacnehg.js} +2 -2
- package/dist/cli/{chunk-zxh4d9vy.js → chunk-tzmab476.js} +4 -4
- package/dist/cli/{chunk-yw7dm696.js → chunk-vg9r4eb9.js} +24 -11
- package/dist/cli/chunk-vg9r4eb9.js.map +14 -0
- package/dist/cli/{chunk-79jhk4py.js → chunk-wrr3j9w9.js} +260 -132
- package/dist/cli/chunk-wrr3j9w9.js.map +35 -0
- package/dist/cli/{chunk-6crbhc3x.js → chunk-yfyb25rh.js} +54 -27
- package/dist/cli/chunk-yfyb25rh.js.map +14 -0
- package/dist/cli/index.js +162 -35
- package/dist/cli/index.js.map +4 -4
- package/dist/types/ai/agent-surface.d.ts +32 -0
- package/dist/types/ai/api-catalog.d.ts +7 -1
- package/dist/types/ai/ask-context.d.ts +7 -0
- package/dist/types/ai/component-markdown.d.ts +4 -4
- package/dist/types/ai/link-headers.d.ts +8 -1
- package/dist/types/ai/openapi-components.d.ts +5 -2
- package/dist/types/ai/relative-links.d.ts +11 -4
- package/dist/types/ai/skills.d.ts +4 -1
- package/dist/types/ai/static-expression.d.ts +28 -0
- package/dist/types/ai/tar.d.ts +1 -3
- package/dist/types/analytics/databuddy.d.ts +43 -0
- package/dist/types/analytics/index.d.ts +4 -0
- package/dist/types/analytics/one-dollar-stats.d.ts +48 -0
- package/dist/types/analytics/schema.d.ts +28 -0
- package/dist/types/astro/integration.d.ts +3 -2
- package/dist/types/cli/env.d.ts +5 -0
- package/dist/types/cli/init/scaffold.d.ts +19 -3
- package/dist/types/cli/init/starter-spec.d.ts +11 -0
- package/dist/types/core/base-path.d.ts +24 -1
- package/dist/types/core/config-input.d.ts +13 -11
- package/dist/types/core/config.d.ts +2 -2
- package/dist/types/core/directive-diagnostics.d.ts +12 -0
- package/dist/types/core/graph.d.ts +2 -0
- package/dist/types/core/heading-markers.d.ts +5 -7
- package/dist/types/core/i18n-ui.d.ts +31 -0
- package/dist/types/core/i18n.d.ts +9 -1
- package/dist/types/core/last-modified.d.ts +10 -0
- package/dist/types/core/links.d.ts +3 -1
- package/dist/types/core/load-module.d.ts +10 -0
- package/dist/types/core/locale-links.d.ts +12 -2
- package/dist/types/core/meta.d.ts +13 -1
- package/dist/types/core/nav-diagnostics.d.ts +10 -0
- package/dist/types/core/navigation.d.ts +38 -0
- package/dist/types/core/ordering-prefix.d.ts +4 -0
- package/dist/types/core/safe-links.d.ts +3 -1
- package/dist/types/core/schema.d.ts +59 -13
- package/dist/types/core/sources/github-releases.d.ts +5 -0
- package/dist/types/core/sources/lower.d.ts +38 -13
- package/dist/types/core/sources/normalize.d.ts +23 -2
- package/dist/types/core/sources/remote.d.ts +11 -1
- package/dist/types/core/sources/resolve.d.ts +12 -0
- package/dist/types/core/sources/types.d.ts +31 -0
- package/dist/types/core/sources/watch.d.ts +12 -5
- package/dist/types/core/standard-schema.d.ts +5 -0
- package/dist/types/core/types.d.ts +9 -0
- package/dist/types/deploy/adapters/node.d.ts +5 -2
- package/dist/types/deploy/adapters/types.d.ts +7 -0
- package/dist/types/deploy/artifacts.d.ts +6 -4
- package/dist/types/deploy/cloudflare-negotiation.d.ts +3 -2
- package/dist/types/deploy/headers.d.ts +36 -7
- package/dist/types/deploy/node-headers.d.ts +43 -8
- package/dist/types/deploy/platforms/netlify.d.ts +27 -2
- package/dist/types/deploy/platforms/node.d.ts +6 -5
- package/dist/types/deploy/platforms/types.d.ts +15 -0
- package/dist/types/deploy/platforms/vercel.d.ts +3 -2
- package/dist/types/deploy/redirects.d.ts +31 -15
- package/dist/types/deploy/vercel-negotiation.d.ts +3 -2
- package/dist/types/markdown/directives.d.ts +62 -0
- package/dist/types/markdown/features.d.ts +21 -0
- package/dist/types/markdown/mdast.d.ts +63 -0
- package/dist/types/openapi/asyncapi.d.ts +4 -2
- package/dist/types/openapi/model.d.ts +20 -6
- package/dist/types/search/sync/algolia.d.ts +3 -1
- package/docs/01-quickstart.mdx +3 -2
- package/docs/02-deployment.mdx +20 -9
- package/docs/08-faq.mdx +10 -3
- package/docs/advanced/changelog.mdx +1 -1
- package/docs/advanced/custom-pages.mdx +7 -5
- package/docs/cli/audit.mdx +19 -3
- package/docs/cli/doctor.mdx +2 -2
- package/docs/cli/evals.mdx +4 -4
- package/docs/cli/index.mdx +4 -1
- package/docs/cli/translate.mdx +4 -4
- package/docs/cli/version.mdx +1 -1
- package/docs/configuration/analytics.mdx +42 -2
- package/docs/configuration/assistant.mdx +1 -1
- package/docs/configuration/customization.mdx +6 -3
- package/docs/configuration/index.mdx +5 -3
- package/docs/configuration/search.mdx +2 -2
- package/docs/content/components.mdx +2 -2
- package/docs/content/frontmatter.mdx +5 -1
- package/docs/content/i18n.mdx +3 -1
- package/docs/content/index.mdx +8 -4
- package/docs/content/islands.mdx +1 -1
- package/docs/content/meta.mdx +7 -3
- package/docs/content/navigation.mdx +29 -4
- package/docs/content/sources.mdx +18 -16
- package/docs/content/syntax.mdx +14 -0
- package/docs/content/versioning.mdx +2 -1
- package/docs/discoverability/agent-discovery.mdx +22 -8
- package/docs/discoverability/index.mdx +4 -3
- package/docs/discoverability/llms-txt.mdx +2 -5
- package/docs/discoverability/markdown.mdx +6 -4
- package/docs/discoverability/mcp.mdx +4 -0
- package/docs/discoverability/metadata.mdx +3 -2
- package/docs/discoverability/open-graph.mdx +8 -4
- package/docs/discoverability/rss.mdx +4 -2
- package/docs/references/asyncapi.mdx +2 -2
- package/docs/references/graphql.mdx +2 -2
- package/docs/references/openapi.mdx +6 -4
- package/package.json +1 -1
- package/skills/blume-migrate/SKILL.md +6 -6
- package/skills/blume-migrate/references/docusaurus.md +6 -6
- package/skills/blume-migrate/references/fumadocs.md +1 -1
- package/skills/blume-migrate/references/mintlify.md +3 -3
- package/skills/blume-migrate/references/monorepo.md +1 -1
- package/skills/blume-migrate/references/nextra.md +2 -2
- package/skills/blume-migrate/references/starlight.md +5 -5
- package/skills/blume-migrate/scripts/mintlify-codemod.mjs +9 -4
- package/skills/blume-update-docs/references/audit-checklist.md +1 -1
- package/src/ai/agent-readability.ts +2 -2
- package/src/ai/agent-surface.ts +56 -0
- package/src/ai/ai-catalog.ts +6 -2
- package/src/ai/api/handlers.ts +2 -2
- package/src/ai/api/spec.ts +17 -4
- package/src/ai/api-catalog.ts +13 -3
- package/src/ai/ask-context.ts +14 -2
- package/src/ai/ask-data.ts +26 -12
- package/src/ai/changelog-markdown.ts +2 -2
- package/src/ai/component-markdown.ts +43 -37
- package/src/ai/link-headers.ts +22 -8
- package/src/ai/llms.ts +22 -10
- package/src/ai/markdown.ts +23 -11
- package/src/ai/mcp/discovery.ts +2 -2
- package/src/ai/mcp/query.ts +2 -2
- package/src/ai/mcp/server.ts +80 -9
- package/src/ai/openapi-components.ts +22 -6
- package/src/ai/relative-links.ts +99 -15
- package/src/ai/serializers.ts +2 -1
- package/src/ai/skills.ts +14 -1
- package/src/ai/static-expression.ts +416 -0
- package/src/ai/tar.ts +139 -12
- package/src/ai/visibility.ts +45 -14
- package/src/analytics/databuddy.ts +67 -0
- package/src/analytics/head.ts +8 -0
- package/src/analytics/index.ts +7 -0
- package/src/analytics/one-dollar-stats.ts +86 -0
- package/src/analytics/posthog.ts +21 -3
- package/src/analytics/schema.ts +4 -0
- package/src/astro/generate.ts +72 -28
- package/src/astro/include-hmr.ts +31 -12
- package/src/astro/include-refresh.ts +19 -8
- package/src/astro/integration.ts +108 -14
- package/src/astro/runtime-modules.ts +28 -13
- package/src/astro/templates.ts +139 -57
- package/src/audit/catalog.ts +2 -2
- package/src/audit/checks/assets.ts +25 -5
- package/src/audit/checks/content.ts +20 -2
- package/src/audit/checks/i18n.ts +46 -8
- package/src/audit/checks/indexability.ts +39 -19
- package/src/audit/checks/links.ts +22 -1
- package/src/audit/checks/llms.ts +6 -3
- package/src/audit/checks/network.ts +3 -1
- package/src/audit/checks/og-image.ts +10 -0
- package/src/audit/checks/robots.ts +6 -1
- package/src/audit/checks/sitemap.ts +56 -31
- package/src/audit/checks/social.ts +21 -2
- package/src/audit/crawl.ts +88 -15
- package/src/audit/graph.ts +3 -1
- package/src/audit/report.ts +54 -17
- package/src/audit/run.ts +13 -9
- package/src/audit/snapshot.ts +5 -0
- package/src/audit/types.ts +18 -0
- package/src/audit/url.ts +37 -6
- package/src/cli/args.ts +32 -0
- package/src/cli/build-failure.ts +50 -0
- package/src/cli/commands/audit.ts +11 -1
- package/src/cli/commands/build.ts +19 -5
- package/src/cli/commands/check.ts +2 -0
- package/src/cli/commands/doctor.ts +3 -1
- package/src/cli/commands/eval.ts +20 -18
- package/src/cli/commands/init.ts +15 -5
- package/src/cli/commands/preview.ts +15 -0
- package/src/cli/commands/sync.ts +2 -0
- package/src/cli/commands/translate.ts +18 -18
- package/src/cli/commands/upgrade.ts +11 -0
- package/src/cli/commands/validate.ts +3 -1
- package/src/cli/dev-lock.ts +157 -37
- package/src/cli/eject-scripts.ts +32 -7
- package/src/cli/env.ts +12 -1
- package/src/cli/init/scaffold.ts +117 -11
- package/src/cli/init/starter-spec.ts +235 -0
- package/src/cli/report-format.ts +11 -6
- package/src/components/colors.ts +19 -0
- package/src/components/content/AccordionItem.astro +26 -22
- package/src/components/content/Badge.astro +7 -12
- package/src/components/content/Card.astro +2 -2
- package/src/components/content/Component.astro +11 -5
- package/src/components/content/Expandable.astro +5 -1
- package/src/components/content/Frame.astro +2 -7
- package/src/components/content/GithubInfo.astro +12 -2
- package/src/components/content/Prompt.astro +2 -7
- package/src/components/content/Tab.astro +0 -1
- package/src/components/content/Tabs.astro +58 -5
- package/src/components/content/Tile.astro +1 -1
- package/src/components/content/Tooltip.astro +69 -7
- package/src/components/content/Tree.astro +7 -2
- package/src/components/content/TypeTable.astro +10 -5
- package/src/components/content/Update.astro +8 -2
- package/src/components/content/auto-type-table.ts +4 -1
- package/src/components/content/badge-color.ts +20 -0
- package/src/components/content/base-href.ts +14 -22
- package/src/components/content/inline-markdown.ts +27 -7
- package/src/components/copy-feedback.ts +35 -8
- package/src/components/islands/assistant.tsx +37 -6
- package/src/components/islands/base-path.ts +47 -10
- package/src/components/islands/hooks.ts +42 -21
- package/src/components/islands/webmcp.ts +16 -10
- package/src/components/layout/Banner.astro +23 -4
- package/src/components/layout/Breadcrumbs.astro +5 -2
- package/src/components/layout/DiscoveryLinks.astro +9 -5
- package/src/components/layout/Header.astro +23 -10
- package/src/components/layout/LanguageSwitcher.astro +2 -2
- package/src/components/layout/Logo.astro +5 -0
- package/src/components/layout/NavSelector.astro +8 -3
- package/src/components/layout/NavTabMenu.astro +133 -0
- package/src/components/layout/NavTree.astro +31 -12
- package/src/components/layout/NavTreeCache.astro +5 -2
- package/src/components/layout/NavTreeScript.astro +45 -5
- package/src/components/layout/PageActions.astro +4 -3
- package/src/components/layout/PageLayout.astro +28 -13
- package/src/components/layout/Pagination.astro +3 -3
- package/src/components/layout/ReferenceLayout.astro +4 -1
- package/src/components/layout/RootLayout.astro +25 -12
- package/src/components/layout/Search.astro +38 -14
- package/src/components/layout/VersionBanner.astro +2 -2
- package/src/components/layout/analytics-client.ts +14 -0
- package/src/components/layout/toc-active.ts +41 -0
- package/src/components/layout/toc-element.ts +8 -14
- package/src/components/openapi/ApiTagOperations.astro +2 -2
- package/src/components/openapi/AsyncApiOperation.astro +7 -4
- package/src/components/openapi/GraphqlChip.astro +2 -2
- package/src/components/openapi/GraphqlType.astro +11 -3
- package/src/components/openapi/MessageComposer.astro +1 -1
- package/src/components/openapi/Operation.astro +23 -5
- package/src/components/openapi/PanelTabs.astro +4 -1
- package/src/components/openapi/Playground.astro +8 -2
- package/src/components/openapi/RequestPanel.astro +13 -6
- package/src/components/openapi/SchemaProperty.astro +11 -33
- package/src/components/openapi/SchemaTable.astro +34 -52
- package/src/components/openapi/async.ts +38 -6
- package/src/components/openapi/helpers.ts +100 -12
- package/src/components/openapi/message-composer.ts +14 -1
- package/src/components/openapi/message-model.ts +12 -2
- package/src/components/openapi/message.ts +21 -3
- package/src/components/openapi/operation-model.ts +119 -17
- package/src/components/openapi/panel.ts +31 -5
- package/src/components/openapi/param-style.ts +181 -0
- package/src/components/openapi/playground-client.ts +110 -23
- package/src/components/openapi/playground-schema.ts +25 -6
- package/src/components/openapi/request.ts +192 -26
- package/src/components/openapi/schema-tree.ts +209 -0
- package/src/components/openapi/snippets.ts +113 -19
- package/src/components/openapi/validate-json.ts +1 -1
- package/src/components/openapi/ws-client.ts +18 -2
- package/src/core/base-path.ts +69 -8
- package/src/core/config-input.ts +13 -11
- package/src/core/config.ts +18 -4
- package/src/core/diagnostics.ts +219 -30
- package/src/core/directive-diagnostics.ts +99 -0
- package/src/core/frontmatter.ts +21 -18
- package/src/core/graph.ts +120 -11
- package/src/core/heading-markers.ts +5 -18
- package/src/core/i18n-ui.ts +39 -2
- package/src/core/i18n.ts +44 -5
- package/src/core/last-modified.ts +25 -3
- package/src/core/links.ts +7 -4
- package/src/core/load-module.ts +20 -0
- package/src/core/locale-links.ts +22 -18
- package/src/core/manifest.ts +3 -2
- package/src/core/meta.ts +89 -12
- package/src/core/nav-diagnostics.ts +56 -1
- package/src/core/navigation.ts +272 -83
- package/src/core/ordering-prefix.ts +27 -0
- package/src/core/project-graph.ts +50 -6
- package/src/core/safe-href.ts +53 -1
- package/src/core/safe-links.ts +11 -2
- package/src/core/schema.ts +94 -18
- package/src/core/sources/assets.ts +83 -41
- package/src/core/sources/contentful-rich-text.ts +28 -20
- package/src/core/sources/contentful.ts +25 -12
- package/src/core/sources/filesystem.ts +25 -3
- package/src/core/sources/github-releases.ts +131 -11
- package/src/core/sources/lexical.ts +30 -20
- package/src/core/sources/lower.ts +276 -56
- package/src/core/sources/mdx-remote.ts +52 -16
- package/src/core/sources/normalize.ts +456 -119
- package/src/core/sources/notion.ts +77 -34
- package/src/core/sources/obsidian.ts +40 -9
- package/src/core/sources/payload.ts +1 -0
- package/src/core/sources/portable-text.ts +85 -49
- package/src/core/sources/remote.ts +18 -2
- package/src/core/sources/resolve.ts +52 -33
- package/src/core/sources/sanity.ts +1 -0
- package/src/core/sources/strapi-blocks.ts +28 -19
- package/src/core/sources/strapi.ts +1 -0
- package/src/core/sources/types.ts +31 -0
- package/src/core/sources/watch.ts +20 -7
- package/src/core/standard-schema.ts +10 -6
- package/src/core/types.ts +9 -0
- package/src/core/ui-packs/ar.ts +13 -0
- package/src/core/ui-packs/bg.ts +13 -0
- package/src/core/ui-packs/bn.ts +13 -0
- package/src/core/ui-packs/ca.ts +13 -0
- package/src/core/ui-packs/cs.ts +13 -0
- package/src/core/ui-packs/da.ts +13 -0
- package/src/core/ui-packs/de.ts +13 -0
- package/src/core/ui-packs/el.ts +13 -0
- package/src/core/ui-packs/es.ts +13 -0
- package/src/core/ui-packs/fa.ts +13 -0
- package/src/core/ui-packs/fi.ts +13 -0
- package/src/core/ui-packs/fr.ts +13 -0
- package/src/core/ui-packs/he.ts +13 -0
- package/src/core/ui-packs/hi.ts +13 -0
- package/src/core/ui-packs/hr.ts +13 -0
- package/src/core/ui-packs/hu.ts +13 -0
- package/src/core/ui-packs/id.ts +13 -0
- package/src/core/ui-packs/it.ts +13 -0
- package/src/core/ui-packs/ja.ts +13 -0
- package/src/core/ui-packs/ko.ts +13 -0
- package/src/core/ui-packs/nl.ts +13 -0
- package/src/core/ui-packs/no.ts +13 -0
- package/src/core/ui-packs/pl.ts +13 -0
- package/src/core/ui-packs/pt-br.ts +13 -0
- package/src/core/ui-packs/pt.ts +13 -0
- package/src/core/ui-packs/ro.ts +13 -0
- package/src/core/ui-packs/ru.ts +13 -0
- package/src/core/ui-packs/sk.ts +13 -0
- package/src/core/ui-packs/sr.ts +13 -0
- package/src/core/ui-packs/sv.ts +13 -0
- package/src/core/ui-packs/th.ts +13 -0
- package/src/core/ui-packs/tr.ts +13 -0
- package/src/core/ui-packs/uk.ts +13 -0
- package/src/core/ui-packs/vi.ts +13 -0
- package/src/core/ui-packs/zh-tw.ts +13 -0
- package/src/core/ui-packs/zh.ts +13 -0
- package/src/core/version-cut.ts +69 -17
- package/src/core/versions.ts +4 -1
- package/src/deploy/adapters/node.ts +5 -2
- package/src/deploy/adapters/registry.ts +2 -1
- package/src/deploy/adapters/types.ts +13 -1
- package/src/deploy/artifacts.ts +52 -11
- package/src/deploy/cloudflare-negotiation.ts +27 -16
- package/src/deploy/headers.ts +75 -55
- package/src/deploy/node-headers.ts +148 -27
- package/src/deploy/platforms/cloudflare.ts +13 -3
- package/src/deploy/platforms/netlify.ts +83 -5
- package/src/deploy/platforms/node.ts +8 -5
- package/src/deploy/platforms/static.ts +2 -0
- package/src/deploy/platforms/types.ts +15 -0
- package/src/deploy/platforms/vercel.ts +10 -3
- package/src/deploy/redirects.ts +68 -21
- package/src/deploy/robots.ts +2 -2
- package/src/deploy/rss.ts +4 -3
- package/src/deploy/sitemap.ts +7 -5
- package/src/deploy/vercel-negotiation.ts +35 -3
- package/src/eval/agents.ts +10 -2
- package/src/eval/run.ts +25 -0
- package/src/markdown/base-links.ts +74 -29
- package/src/markdown/directives.ts +242 -36
- package/src/markdown/features.ts +17 -0
- package/src/markdown/index.ts +13 -9
- package/src/markdown/mdast.ts +5 -2
- package/src/markdown/relative-links.ts +15 -27
- package/src/markdown/route-snapshot.ts +37 -0
- package/src/og/card.ts +149 -9
- package/src/og/derive.ts +156 -5
- package/src/og/index.ts +1 -0
- package/src/openapi/asyncapi.ts +4 -2
- package/src/openapi/graphql-build.ts +28 -2
- package/src/openapi/model.ts +99 -27
- package/src/openapi/proxy.ts +63 -10
- package/src/openapi/render-mdx.ts +51 -3
- package/src/registry/eject.ts +297 -43
- package/src/search/adapters/version-scope.ts +30 -0
- package/src/search/documents.ts +89 -27
- package/src/search/popular.ts +2 -1
- package/src/search/sync/algolia.ts +36 -2
- package/src/seo/jsonld.ts +7 -3
- package/src/sources/registry.ts +5 -0
- package/src/theme/entry.ts +11 -4
- package/src/translate/agents.ts +6 -1
- package/src/translate/ledger.ts +26 -3
- package/src/translate/meta.ts +76 -24
- package/src/translate/run.ts +14 -8
- package/src/translate/validate.ts +14 -2
- package/src/translate/work-list.ts +91 -19
- package/src/upgrade/upgrade.ts +36 -4
- package/dist/cli/chunk-27g6wdth.js.map +0 -10
- package/dist/cli/chunk-2hn4b8z7.js.map +0 -12
- package/dist/cli/chunk-6crbhc3x.js.map +0 -14
- package/dist/cli/chunk-6hsn950k.js.map +0 -10
- package/dist/cli/chunk-79jhk4py.js.map +0 -35
- package/dist/cli/chunk-82bbrxdn.js +0 -51
- package/dist/cli/chunk-82bbrxdn.js.map +0 -10
- package/dist/cli/chunk-abh8yjkn.js +0 -31
- package/dist/cli/chunk-abh8yjkn.js.map +0 -10
- package/dist/cli/chunk-ce574jw2.js +0 -23
- package/dist/cli/chunk-ce574jw2.js.map +0 -10
- package/dist/cli/chunk-dh8cwk36.js.map +0 -10
- package/dist/cli/chunk-epjnccmv.js.map +0 -10
- package/dist/cli/chunk-fa25z98p.js.map +0 -11
- package/dist/cli/chunk-fs23ddbb.js.map +0 -35
- package/dist/cli/chunk-fz5wtpmh.js.map +0 -10
- package/dist/cli/chunk-jwyddg7y.js.map +0 -15
- package/dist/cli/chunk-kpf8rrjc.js.map +0 -19
- package/dist/cli/chunk-m3vmjgmq.js.map +0 -10
- package/dist/cli/chunk-mb2919y2.js.map +0 -10
- package/dist/cli/chunk-q5163e60.js.map +0 -11
- package/dist/cli/chunk-qkqwkpte.js.map +0 -182
- package/dist/cli/chunk-qs4q5p4e.js.map +0 -10
- package/dist/cli/chunk-s1p84fyh.js.map +0 -10
- package/dist/cli/chunk-wgm7m9qk.js.map +0 -36
- package/dist/cli/chunk-yt5n7ppj.js.map +0 -10
- package/dist/cli/chunk-yw7dm696.js.map +0 -14
- /package/dist/cli/{chunk-s6jhgk0q.js.map → chunk-2eytanqx.js.map} +0 -0
- /package/dist/cli/{chunk-hdpx1tax.js.map → chunk-2z928egk.js.map} +0 -0
- /package/dist/cli/{chunk-ah61y8py.js.map → chunk-364znk6q.js.map} +0 -0
- /package/dist/cli/{chunk-vtk4a6dg.js.map → chunk-8ktnccpt.js.map} +0 -0
- /package/dist/cli/{chunk-fxypxtvm.js.map → chunk-a58773jm.js.map} +0 -0
- /package/dist/cli/{chunk-wm7js3j9.js.map → chunk-b07cmahc.js.map} +0 -0
- /package/dist/cli/{chunk-zxcczpyx.js.map → chunk-r20tn01b.js.map} +0 -0
- /package/dist/cli/{chunk-5shv93fd.js.map → chunk-tkacnehg.js.map} +0 -0
- /package/dist/cli/{chunk-zxh4d9vy.js.map → chunk-tzmab476.js.map} +0 -0
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import type { RouteSet } from "../core/locale-links.ts";
|
|
2
|
+
import type { BlumeProject } from "../core/project-graph.ts";
|
|
1
3
|
import type { ResolvedConfig } from "../core/schema.ts";
|
|
2
4
|
import type { VercelHeader } from "./headers.ts";
|
|
3
5
|
/**
|
|
@@ -15,37 +17,51 @@ type Redirect = ResolvedConfig["redirects"][number];
|
|
|
15
17
|
* - `from` gains only `basePath`. Astro builds the match pattern with
|
|
16
18
|
* `deployment.base` already applied (`getPattern(segments, config.base)`), so
|
|
17
19
|
* adding it here would serve the redirect at `{base}{base}/from`.
|
|
18
|
-
* - `to` gains the full `{deployment.base}{basePath}` stack
|
|
19
|
-
*
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
*
|
|
20
|
+
* - `to` gains the full `{deployment.base}{basePath}` stack, or the deployment
|
|
21
|
+
* base alone for a public file (see {@link baseRedirectTarget}). Astro
|
|
22
|
+
* resolves a destination that matches a known route by regenerating it from
|
|
23
|
+
* that route's segments, which carry no base — and passes an unmatched
|
|
24
|
+
* destination through verbatim. Neither path prepends `base`, so a
|
|
25
|
+
* root-relative `to` escapes the base entirely (withastro/astro#7774, still
|
|
26
|
+
* the behavior in Astro 7).
|
|
23
27
|
*
|
|
24
|
-
* Both sides are authored as if mounted at root;
|
|
25
|
-
*
|
|
28
|
+
* Both sides are authored as if mounted at root; `routes` (the served page
|
|
29
|
+
* routes, carrying `basePath`) tell a dotted page route like `/releases/v1.2`
|
|
30
|
+
* from a file. Idempotent, so a hand-written base isn't doubled.
|
|
26
31
|
*/
|
|
27
|
-
export declare const applyBaseToAstroRedirects: (redirects: Redirect[], basePath: string, deployBase: string) => Redirect[];
|
|
32
|
+
export declare const applyBaseToAstroRedirects: (redirects: Redirect[], basePath: string, deployBase: string, routes: RouteSet) => Redirect[];
|
|
28
33
|
/**
|
|
29
34
|
* Base a redirect for the host platform files below. Unlike Astro's config,
|
|
30
|
-
* these are matched against the real served URL, so
|
|
31
|
-
* `{deployment.base}{basePath}` stack
|
|
35
|
+
* these are matched against the real served URL, so `from` carries the full
|
|
36
|
+
* `{deployment.base}{basePath}` stack, and so does `to` unless it names a
|
|
37
|
+
* public file (see {@link baseRedirectTarget}).
|
|
32
38
|
*/
|
|
33
|
-
export declare const applyBaseToPlatformRedirects: (redirects: Redirect[], basePath: string, deployBase: string) => Redirect[];
|
|
39
|
+
export declare const applyBaseToPlatformRedirects: (redirects: Redirect[], basePath: string, deployBase: string, routes: RouteSet) => Redirect[];
|
|
34
40
|
/**
|
|
35
41
|
* The configured redirects as the host platform matches them, via
|
|
36
42
|
* {@link applyBaseToPlatformRedirects}. The one basing every consumer must
|
|
37
43
|
* share: the emitted redirect files and the Cloudflare worker-first redirect
|
|
38
44
|
* exemptions both compare these paths against real served URLs.
|
|
39
45
|
*/
|
|
40
|
-
export declare const platformRedirects: (
|
|
41
|
-
|
|
42
|
-
|
|
46
|
+
export declare const platformRedirects: (project: {
|
|
47
|
+
config: ResolvedConfig;
|
|
48
|
+
manifest: Pick<BlumeProject["manifest"], "routes">;
|
|
49
|
+
}) => Redirect[];
|
|
50
|
+
/**
|
|
51
|
+
* `_redirects` text (Netlify + Cloudflare Pages): `from to status` per line.
|
|
52
|
+
* `force` appends Netlify's `!` to each status (`301!`), so the rule wins over
|
|
53
|
+
* the redirect page Astro writes at `from`; Cloudflare, which always applies
|
|
54
|
+
* its rules first, rejects a line carrying it.
|
|
55
|
+
*/
|
|
56
|
+
export declare const buildNetlifyRedirects: (redirects: Redirect[], force?: boolean) => string;
|
|
43
57
|
/**
|
|
44
58
|
* `vercel.json` contents with a `redirects` array, and a `headers` array when
|
|
45
59
|
* header rules are given (see `buildVercelHeaders`). Uses `statusCode` (Vercel's
|
|
46
60
|
* alternative to the boolean `permanent`) so the configured code ships exactly:
|
|
47
61
|
* `permanent` would silently coerce a 301 to 308 and a 302 to 307, diverging
|
|
48
|
-
* from the `_redirects` file, which preserves exact codes.
|
|
62
|
+
* from the `_redirects` file, which preserves exact codes. A `source` is a
|
|
63
|
+
* `path-to-regexp` pattern, so each exact `from` path is escaped: unescaped,
|
|
64
|
+
* `/c++-guide` fails the whole config and `/faq(old)` never matches.
|
|
49
65
|
*/
|
|
50
66
|
export declare const buildVercelConfig: (redirects: Redirect[], headers?: readonly VercelHeader[]) => string;
|
|
51
67
|
/** Structured manifest for hosts that need manual wiring. */
|
|
@@ -101,9 +101,10 @@ export declare const buildNegotiationRoutes: (routePaths: readonly string[], hom
|
|
|
101
101
|
* `404.md`, `notFound.json` for `404.json`), its routes go into the miss
|
|
102
102
|
* phase right before the adapter's `/404.html` fallback — and nowhere when
|
|
103
103
|
* that fallback is absent, since a `dest` with no file behind it would serve
|
|
104
|
-
* nothing.
|
|
104
|
+
* nothing. With `svgAssets`, a main-phase route also sandboxes the SVGs a
|
|
105
|
+
* content source downloaded (see {@link svgAssetRoute}). Returns the updated JSON
|
|
105
106
|
* text (tab-indented, like the adapter's own output), or `null` when there is
|
|
106
107
|
* nowhere safe to splice: an unparsable config, no `routes` array, or no
|
|
107
108
|
* `handle: "filesystem"` marker to anchor the splice.
|
|
108
109
|
*/
|
|
109
|
-
export declare const injectNegotiationRoutes: (configText: string, routePaths: readonly string[], homeLinkHeader?: string | null, contentTypeOverrides?: Record<string, string>, homeTokens?: number, notFound?: NotFoundVariants, corsPaths?: readonly string[]) => string | null;
|
|
110
|
+
export declare const injectNegotiationRoutes: (configText: string, routePaths: readonly string[], homeLinkHeader?: string | null, contentTypeOverrides?: Record<string, string>, homeTokens?: number, notFound?: NotFoundVariants, corsPaths?: readonly string[], svgAssets?: boolean) => string | null;
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import type { MdastNode, MdastVisitorContext } from "./mdast.ts";
|
|
2
|
+
export interface DirectiveNode extends MdastNode {
|
|
3
|
+
attributes?: Record<string, string | null | undefined> | null;
|
|
4
|
+
children?: MdastNode[] | null;
|
|
5
|
+
name: string;
|
|
6
|
+
position?: {
|
|
7
|
+
start?: {
|
|
8
|
+
offset?: number;
|
|
9
|
+
};
|
|
10
|
+
end?: {
|
|
11
|
+
offset?: number;
|
|
12
|
+
};
|
|
13
|
+
};
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* The visitor-context slice the directive visitors use. `source` is the page
|
|
17
|
+
* the directive offsets index into; without it the literal fallback rebuilds
|
|
18
|
+
* a directive from its node instead. `parent` walks up to an enclosing
|
|
19
|
+
* container directive, which renders the directives inside it itself.
|
|
20
|
+
*/
|
|
21
|
+
interface DirectiveVisitorContext extends MdastVisitorContext {
|
|
22
|
+
parent?: (node: MdastNode) => MdastNode | undefined;
|
|
23
|
+
source?: string;
|
|
24
|
+
}
|
|
25
|
+
/** Directive names that map directly onto a Callout type. */
|
|
26
|
+
export declare const CALLOUT_TYPES: ReadonlySet<string>;
|
|
27
|
+
/** Friendly aliases for the canonical Callout types. */
|
|
28
|
+
interface CalloutAliases {
|
|
29
|
+
[alias: string]: string;
|
|
30
|
+
}
|
|
31
|
+
export declare const CALLOUT_ALIASES: Readonly<CalloutAliases>;
|
|
32
|
+
/** Resolve a directive name to a Callout type, or `null` if it is not one. */
|
|
33
|
+
export declare const calloutTypeFor: (name: string) => string | null;
|
|
34
|
+
/**
|
|
35
|
+
* A text or leaf directive exactly as the author wrote it. The slice by
|
|
36
|
+
* offsets is the exact text — `[label]` and `{attrs}` included — and is
|
|
37
|
+
* trusted only when it opens with the directive's own marker and name;
|
|
38
|
+
* content an `<include>` spliced in carries no offsets into this page, so it
|
|
39
|
+
* is rebuilt from the node instead.
|
|
40
|
+
*/
|
|
41
|
+
export declare const directiveSource: (node: DirectiveNode, marker: string, source: string) => string;
|
|
42
|
+
/**
|
|
43
|
+
* Satteri MDAST plugin for directives. Container directives (`:::note`,
|
|
44
|
+
* `:::warning`, `:::tip`, …) map onto Blume's `<Callout>` component, and any
|
|
45
|
+
* other container renders its body between its literal fence lines (see
|
|
46
|
+
* {@link renderContainer}).
|
|
47
|
+
*
|
|
48
|
+
* Blume handles no text (`:name`) or leaf (`::name`) directives, and prose is
|
|
49
|
+
* full of text that parses as one — `16:9`, `10:30am`, `og:image`,
|
|
50
|
+
* `pets:read` — so both render as the literal source the author wrote instead
|
|
51
|
+
* of vanishing.
|
|
52
|
+
*/
|
|
53
|
+
export declare const directiveToCalloutPlugin: () => {
|
|
54
|
+
containerDirective(node: DirectiveNode, ctx: DirectiveVisitorContext): void;
|
|
55
|
+
leafDirective: (node: DirectiveNode, ctx: DirectiveVisitorContext) => void;
|
|
56
|
+
name: string;
|
|
57
|
+
options: {
|
|
58
|
+
position: boolean;
|
|
59
|
+
};
|
|
60
|
+
textDirective: (node: DirectiveNode, ctx: DirectiveVisitorContext) => void;
|
|
61
|
+
};
|
|
62
|
+
export {};
|
|
@@ -19,3 +19,24 @@ export declare const MDX_FEATURES: {
|
|
|
19
19
|
subscript: true;
|
|
20
20
|
superscript: true;
|
|
21
21
|
};
|
|
22
|
+
/**
|
|
23
|
+
* The feature sets for a page body, once its front matter is off. Astro reads
|
|
24
|
+
* a page's front matter itself and hands the renderer the body alone, and the
|
|
25
|
+
* search extractor strips it first too — so front matter parsing is off here:
|
|
26
|
+
* left on, a body that opens with a `---` rule read everything up to the next
|
|
27
|
+
* `---` line as front matter and dropped it from the page.
|
|
28
|
+
*/
|
|
29
|
+
export declare const MARKDOWN_BODY_FEATURES: {
|
|
30
|
+
frontmatter: false;
|
|
31
|
+
subscript: true;
|
|
32
|
+
superscript: true;
|
|
33
|
+
};
|
|
34
|
+
export declare const MDX_BODY_FEATURES: {
|
|
35
|
+
frontmatter: false;
|
|
36
|
+
directive: true;
|
|
37
|
+
math: {
|
|
38
|
+
singleDollarTextMath: false;
|
|
39
|
+
};
|
|
40
|
+
subscript: true;
|
|
41
|
+
superscript: true;
|
|
42
|
+
};
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Minimal structural types and node builders for the (alpha) Satteri MDAST
|
|
3
|
+
* plugin API. We model only what Blume's plugins read and construct; the full
|
|
4
|
+
* types live in `satteri`, a transitive dependency. Plugins are bridged to
|
|
5
|
+
* Satteri's real `MdastPlugin` type at a single boundary in `index.ts`.
|
|
6
|
+
*/
|
|
7
|
+
/**
|
|
8
|
+
* A property value on an MDAST node: primitives, nested nodes, and lists of
|
|
9
|
+
* either. Covers everything Blume's plugins read or build (positions, data
|
|
10
|
+
* flags, attribute lists) without admitting functions or class instances.
|
|
11
|
+
*/
|
|
12
|
+
export type MdastValue = string | number | boolean | null | undefined | MdastValue[] | {
|
|
13
|
+
[key: string]: MdastValue;
|
|
14
|
+
};
|
|
15
|
+
/**
|
|
16
|
+
* The visitor context Blume's plugins use to mutate the tree. A list of
|
|
17
|
+
* nodes takes the replaced node's place in order.
|
|
18
|
+
*/
|
|
19
|
+
export interface MdastVisitorContext {
|
|
20
|
+
replaceNode: (node: MdastNode, replacement: MdastNode | MdastNode[]) => void;
|
|
21
|
+
}
|
|
22
|
+
/** Any MDAST node, keyed loosely since we build a small subset by hand. */
|
|
23
|
+
export interface MdastNode {
|
|
24
|
+
type: string;
|
|
25
|
+
[key: string]: MdastValue;
|
|
26
|
+
}
|
|
27
|
+
/** Build an MDX JSX attribute. A `null` value renders as a boolean attribute. */
|
|
28
|
+
export declare const jsxAttribute: (name: string, value?: string | null) => {
|
|
29
|
+
name: string;
|
|
30
|
+
type: string;
|
|
31
|
+
value: string | null;
|
|
32
|
+
};
|
|
33
|
+
type JsxAttribute = ReturnType<typeof jsxAttribute>;
|
|
34
|
+
/** Build a block-level MDX JSX element (`<Name>…</Name>`). */
|
|
35
|
+
export declare const jsxFlowElement: (name: string, attributes: JsxAttribute[], children: MdastValue[]) => {
|
|
36
|
+
attributes: {
|
|
37
|
+
name: string;
|
|
38
|
+
type: string;
|
|
39
|
+
value: string | null;
|
|
40
|
+
}[];
|
|
41
|
+
children: MdastValue[];
|
|
42
|
+
name: string;
|
|
43
|
+
type: string;
|
|
44
|
+
};
|
|
45
|
+
/** Build an inline MDX JSX element (phrasing context). */
|
|
46
|
+
export declare const jsxTextElement: (name: string, attributes: JsxAttribute[], children?: MdastValue[]) => {
|
|
47
|
+
attributes: {
|
|
48
|
+
name: string;
|
|
49
|
+
type: string;
|
|
50
|
+
value: string | null;
|
|
51
|
+
}[];
|
|
52
|
+
children: MdastValue[];
|
|
53
|
+
name: string;
|
|
54
|
+
type: string;
|
|
55
|
+
};
|
|
56
|
+
/** Build a fenced code block node, optionally with a fence-meta string. */
|
|
57
|
+
export declare const codeBlock: (lang: string, value: string, meta?: string | null) => {
|
|
58
|
+
lang: string;
|
|
59
|
+
meta: string | null;
|
|
60
|
+
type: string;
|
|
61
|
+
value: string;
|
|
62
|
+
};
|
|
63
|
+
export {};
|
|
@@ -34,7 +34,8 @@ export interface AsyncApiChannelObject {
|
|
|
34
34
|
messages?: Record<string, AsyncApiRefLike>;
|
|
35
35
|
parameters?: Record<string, AsyncApiRefLike>;
|
|
36
36
|
servers?: AsyncApiRefLike[];
|
|
37
|
-
|
|
37
|
+
/** Protocol-keyed binding objects, or a `$ref` to a components entry. */
|
|
38
|
+
bindings?: Record<string, AsyncApiSpecValue>;
|
|
38
39
|
[key: string]: AsyncApiSpecValue;
|
|
39
40
|
}
|
|
40
41
|
/** A permissive view of an AsyncAPI 3.x operation — only the fields we render. */
|
|
@@ -51,7 +52,8 @@ export interface AsyncApiOperationObject {
|
|
|
51
52
|
}[];
|
|
52
53
|
security?: AsyncApiRefLike[];
|
|
53
54
|
messages?: AsyncApiRefLike[];
|
|
54
|
-
|
|
55
|
+
/** Protocol-keyed binding objects, or a `$ref` to a components entry. */
|
|
56
|
+
bindings?: Record<string, AsyncApiSpecValue>;
|
|
55
57
|
[key: string]: AsyncApiSpecValue;
|
|
56
58
|
}
|
|
57
59
|
/** A permissive view of an AsyncAPI 3.x server object. */
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { Document, OperationObject } from "@scalar/openapi-types/3.1";
|
|
2
|
-
import type { AsyncApiAction, AsyncApiDocument } from "./asyncapi.ts";
|
|
2
|
+
import type { AsyncApiAction, AsyncApiDocument, AsyncApiSpecValue } from "./asyncapi.ts";
|
|
3
3
|
import type { GraphqlDocument, GraphqlMember } from "./graphql.ts";
|
|
4
4
|
import type { ReferenceKind } from "./references.ts";
|
|
5
5
|
export { slugify } from "./references.ts";
|
|
@@ -46,7 +46,10 @@ export interface ApiOperationRef {
|
|
|
46
46
|
/** The channel the operation acts on (AsyncAPI only). */
|
|
47
47
|
channelId?: string;
|
|
48
48
|
}
|
|
49
|
-
/**
|
|
49
|
+
/**
|
|
50
|
+
* A tag/section: the spec's declared tags in their declared order, then any
|
|
51
|
+
* undeclared tag an operation uses, in first-seen order.
|
|
52
|
+
*/
|
|
50
53
|
export interface ApiTagRef {
|
|
51
54
|
slug: string;
|
|
52
55
|
name: string;
|
|
@@ -114,6 +117,15 @@ export interface SpecAddresses {
|
|
|
114
117
|
* live endpoint stands in.
|
|
115
118
|
*/
|
|
116
119
|
export declare const specAddresses: (spec: ApiSpecData) => SpecAddresses;
|
|
120
|
+
/**
|
|
121
|
+
* A server URL template — an OpenAPI `servers[].url`, an AsyncAPI server's
|
|
122
|
+
* `host` or `pathname` — with each `{variable}` replaced by the `default` its
|
|
123
|
+
* `variables` map declares. Code samples, the playground's Send, and the
|
|
124
|
+
* proxy allowlist all need a real address, and
|
|
125
|
+
* `https://{region}.api.example.com` is not one. A variable the map doesn't
|
|
126
|
+
* define with a default (invalid per both specs) stays templated.
|
|
127
|
+
*/
|
|
128
|
+
export declare const withServerDefaults: (template: string, variables: AsyncApiSpecValue) => string;
|
|
117
129
|
/**
|
|
118
130
|
* Assign each distinct tag name a unique slug. `slugify` can collapse
|
|
119
131
|
* different names onto one value — any two punctuation-only tags (`!!!`,
|
|
@@ -142,16 +154,18 @@ export interface ExtractedOperations extends CollectedOperations {
|
|
|
142
154
|
}
|
|
143
155
|
/**
|
|
144
156
|
* The collector behind both extractors (OpenAPI here, AsyncAPI in
|
|
145
|
-
* `asyncapi.ts`): first-seen tag ordering, key de-duplication
|
|
146
|
-
* gains its method/action as a suffix), and the shared route
|
|
147
|
-
* URL shape and slug rules can never drift between the two spec
|
|
157
|
+
* `asyncapi.ts`): declared-then-first-seen tag ordering, key de-duplication
|
|
158
|
+
* (a repeated key gains its method/action as a suffix), and the shared route
|
|
159
|
+
* template — so URL shape and slug rules can never drift between the two spec
|
|
160
|
+
* kinds.
|
|
148
161
|
*/
|
|
149
162
|
export declare const operationCollector: (baseRoute: string, tagMeta: ReadonlyMap<string, string>) => OperationCollector;
|
|
150
163
|
/**
|
|
151
164
|
* Flatten a 3.1 document into a route-mapped operation list and its ordered
|
|
152
165
|
* tags. Operations inherit the first tag they declare; keys are de-duplicated so
|
|
153
166
|
* a repeated `operationId` still yields distinct routes. `warnings` reports
|
|
154
|
-
* anything skipped (a `$ref` path item), so missing operations
|
|
167
|
+
* anything skipped (a `$ref` path item, webhooks), so missing operations
|
|
168
|
+
* aren't silent.
|
|
155
169
|
*/
|
|
156
170
|
export declare const extractOperations: (document: ApiDocument, baseRoute: string) => ExtractedOperations;
|
|
157
171
|
/** Resolve the operation object for a ref out of its (OpenAPI) document. */
|
|
@@ -9,6 +9,8 @@ export type AlgoliaSyncConfig = Pick<AlgoliaOptions, "appId" | "indexName">;
|
|
|
9
9
|
*
|
|
10
10
|
* Uses `replaceAllObjects`, which atomically replaces the index contents, so
|
|
11
11
|
* pages deleted or renamed since the last sync don't linger as stale search
|
|
12
|
-
* hits that 404 when clicked.
|
|
12
|
+
* hits that 404 when clicked. Then adds `filterOnly(locale)` and
|
|
13
|
+
* `filterOnly(version)` to the index's `attributesForFaceting`, keeping any
|
|
14
|
+
* the site declared itself, so the dialog's locale and version filters match.
|
|
13
15
|
*/
|
|
14
16
|
export declare const syncAlgolia: (records: SearchRecord[], config: AlgoliaSyncConfig) => Promise<void>;
|
package/docs/01-quickstart.mdx
CHANGED
|
@@ -23,11 +23,12 @@ Go from an empty folder to a running docs site in a few commands. Blume needs **
|
|
|
23
23
|
npx blume init
|
|
24
24
|
```
|
|
25
25
|
|
|
26
|
-
On pnpm 12, add `--allow-build=esbuild` after `pnpm dlx` (`pnpm dlx --allow-build=esbuild blume init`): pnpm 12 refuses to run the install script of esbuild, which Astro depends on, unless you approve it. Inside an existing pnpm workspace,
|
|
26
|
+
On pnpm 12, add `--allow-build=esbuild` after `pnpm dlx` (`pnpm dlx --allow-build=esbuild blume init`): pnpm 12 refuses to run the install script of esbuild, which Astro depends on, unless you approve it. Inside an existing pnpm workspace, the new folder must be listed under the workspace's `packages` (pnpm installs nothing else, so `init` skips the install until it is), and esbuild needs `allowBuilds: { esbuild: true }` in the workspace's `pnpm-workspace.yaml`; `init` reminds you of both. With Yarn 2 or later, `init` writes a `.yarnrc.yml` that switches Yarn to a `node_modules` install, which Blume needs; on Yarn 1, run `npx blume init`.
|
|
27
27
|
|
|
28
28
|
```txt
|
|
29
29
|
docs/
|
|
30
30
|
index.mdx
|
|
31
|
+
.gitignore
|
|
31
32
|
blume.config.ts
|
|
32
33
|
package.json
|
|
33
34
|
```
|
|
@@ -52,7 +53,7 @@ Go from an empty folder to a running docs site in a few commands. Blume needs **
|
|
|
52
53
|
</Step>
|
|
53
54
|
</Steps>
|
|
54
55
|
|
|
55
|
-
Adding Blume to a project that already has a `package.json`? `blume init` leaves existing files alone, so add `"dev": "blume dev"` and `"build": "blume build"` to its scripts, or run `npx blume dev` directly.
|
|
56
|
+
Adding Blume to a project that already has a `package.json`? `blume init` leaves existing files alone and skips the install, so install Blume yourself (`npm install blume`), then add `"dev": "blume dev"` and `"build": "blume build"` to its scripts, or run `npx blume dev` directly. The next steps `init` prints include both commands for your package manager.
|
|
56
57
|
|
|
57
58
|
:::tip
|
|
58
59
|
Blume works with any package manager and never requires you to set up Astro or Tailwind yourself.
|
package/docs/02-deployment.mdx
CHANGED
|
@@ -22,7 +22,8 @@ A static build includes:
|
|
|
22
22
|
|
|
23
23
|
- every docs and custom page as static HTML
|
|
24
24
|
- a local search index (Orama by default, Pagefind opt-in)
|
|
25
|
-
- a [`sitemap.xml`](/docs/discoverability/sitemap-and-robots#sitemap)
|
|
25
|
+
- a [`sitemap.xml`](/docs/discoverability/sitemap-and-robots#sitemap) when the site URL is known
|
|
26
|
+
- a [`robots.txt`](/docs/discoverability/sitemap-and-robots#robots), which points to the sitemap when the site URL is known
|
|
26
27
|
- `llms.txt` and `llms-full.txt` for AI tools
|
|
27
28
|
- redirect pages
|
|
28
29
|
- prerendered [Open Graph images](/docs/discoverability/open-graph) when `seo.og.enabled` is on
|
|
@@ -31,7 +32,7 @@ A static build includes:
|
|
|
31
32
|
|
|
32
33
|
Sitemaps, canonical tags, RSS, and Open Graph images need an absolute origin. On **Vercel**, **Netlify**, and **Cloudflare Pages**, Blume detects it from the platform's environment at build time — no config required.
|
|
33
34
|
|
|
34
|
-
Set `site` to override the detected value, or to provide one on hosts that don't expose it (GitHub Pages, S3, a custom CDN). For a static build that's the plain `deployment` object:
|
|
35
|
+
Set `site`, an absolute `http://` or `https://` URL, to override the detected value, or to provide one on hosts that don't expose it (GitHub Pages, S3, a custom CDN). For a static build that's the plain `deployment` object:
|
|
35
36
|
|
|
36
37
|
```ts blume.config.ts lineNumbers
|
|
37
38
|
deployment: {
|
|
@@ -39,7 +40,7 @@ deployment: {
|
|
|
39
40
|
}
|
|
40
41
|
```
|
|
41
42
|
|
|
42
|
-
|
|
43
|
+
On Vercel and Netlify, automatic detection prefers your stable production domain over per-deploy preview URLs, so the canonical origin stays put across deploys. Cloudflare Pages exposes only the current deployment's URL (`CF_PAGES_URL`), which changes with every deploy, so set `site` there.
|
|
43
44
|
|
|
44
45
|
During `blume dev`, the site URL falls back to your local dev server (e.g. `http://localhost:4321`) when none is set, so site-gated features — Open Graph images, canonicals, the sitemap — work out of the box. Builds never use this fallback, so production output is never pointed at localhost.
|
|
45
46
|
|
|
@@ -52,6 +53,8 @@ blume build
|
|
|
52
53
|
blume preview
|
|
53
54
|
```
|
|
54
55
|
|
|
56
|
+
`blume preview` serves static builds and `node()` and `cloudflare()` server builds. The Vercel and Netlify adapters have no local preview server, so after a `vercel()` or `netlify()` server build it stops with an error instead. Try the site with `blume dev`, or deploy a preview with `vercel deploy` or `netlify deploy`.
|
|
57
|
+
|
|
55
58
|
## Subpath deploys
|
|
56
59
|
|
|
57
60
|
Serving docs under a path like `example.com/docs`? Set `base` — common for GitHub Pages project sites. The whole site, root included, moves under the base, and internal links and assets are rewritten to include it.
|
|
@@ -64,6 +67,8 @@ deployment: {
|
|
|
64
67
|
|
|
65
68
|
`base` (and `site`) are options of every host adapter too: `vercel({ base: "/docs" })`.
|
|
66
69
|
|
|
70
|
+
Every page keeps its own path under the base, even in a content folder that shares the base's name: with `base: "/docs"`, `docs/setup.md` is served at `/docs/docs/setup`, and its canonical URL, sidebar link, and `llms.txt` entry point there. A root-relative link you write that already starts with the base is taken to include it and left as written, so link to that page with a relative link (`./docs/setup`) or its full path (`/docs/docs/setup`).
|
|
71
|
+
|
|
67
72
|
## Mount the docs under a path
|
|
68
73
|
|
|
69
74
|
`basePath` mounts every generated route under a segment (`/docs/getting-started`) while leaving the sidebar untouched — the top level is your sections, not a wrapper group. Use it when the docs live at `/docs/*` but the site root stays yours (like Docusaurus `routeBasePath` or Fumadocs `baseUrl`).
|
|
@@ -72,7 +77,7 @@ deployment: {
|
|
|
72
77
|
basePath: "/docs",
|
|
73
78
|
```
|
|
74
79
|
|
|
75
|
-
Write links as if mounted at root (`/getting-started`); Blume rewrites them, along with redirects, the sitemap, canonical URLs, Open Graph images, `llms.txt`, and the search index. Public assets (images, files under `public/`) stay at the site root.
|
|
80
|
+
Write links as if mounted at root (`/getting-started`); Blume rewrites them, along with redirects, the sitemap, canonical URLs, Open Graph images, `llms.txt`, and the search index. Public assets (images, files under `public/`) stay at the site root, or under [`base`](#subpath-deploys) when you set one.
|
|
76
81
|
|
|
77
82
|
This is a distinct concept from the two paths above:
|
|
78
83
|
|
|
@@ -117,7 +122,7 @@ Naming an adapter switches the build to server output. To keep a static build on
|
|
|
117
122
|
deployment: netlify({ output: "static" }),
|
|
118
123
|
```
|
|
119
124
|
|
|
120
|
-
A server build includes everything a static build does, plus any Astro endpoints or middleware you add. The `node()` adapter produces a standalone server you can run directly with `node dist/server/entry.mjs`. The server resolves its packages through links into your project's `node_modules`, so deploy the project with its installed dependencies, not `dist/` alone. When the site publishes discovery files, Blume puts a small wrapper in front of Astro's entry (moved to `astro-entry.mjs` beside it)
|
|
125
|
+
A server build includes everything a static build does, plus any Astro endpoints or middleware you add. The `node()` adapter produces a standalone server you can run directly with `node dist/server/entry.mjs`. It listens on `localhost:4321` unless you set the `HOST` and `PORT` environment variables when you start it (`HOST=0.0.0.0 PORT=8080 node dist/server/entry.mjs`); `host` and `port` passed to `node()` have no effect, because `@astrojs/node` replaces them with Astro's own server settings. The server resolves its packages through links into your project's `node_modules`, so deploy the project with its installed dependencies, not `dist/` alone. When the site publishes discovery files, serves images a content source downloaded, or configures redirects, Blume puts a small wrapper in front of Astro's entry (moved to `astro-entry.mjs` beside it). It sends the `.well-known` discovery files with their media types and CORS headers and downloaded SVGs sandboxed, which the standalone server's static handler can't do on its own, and answers each redirect with its configured status.
|
|
121
126
|
|
|
122
127
|
A `cloudflare()` server build deploys with `npx wrangler deploy` from the project root after `blume build`: Blume writes the redirected Wrangler config to `.wrangler/deploy/` (and adds `.wrangler/` to `.gitignore`), and names the Worker after your project — the `package.json` `name`, else the site's hostname, else the folder — unless a `wrangler.jsonc` of your own at the project root sets `name`.
|
|
123
128
|
|
|
@@ -139,19 +144,24 @@ Map old URLs to new ones in `blume.config.ts`:
|
|
|
139
144
|
redirects: [{ from: "/old", to: "/new", status: 301 }],
|
|
140
145
|
```
|
|
141
146
|
|
|
142
|
-
`status` accepts `301`, `302`, `307`, or `308` (default `301`). Server builds
|
|
147
|
+
`status` accepts `301`, `302`, `307`, or `308` (default `301`). Server builds answer redirects at request time with the configured status. Static builds emit redirect pages **and** the platform files your host reads, so it issues a real HTTP redirect: `_redirects` for `netlify()` and `cloudflare()`, `vercel.json` for `vercel()`, and — when no host is named — both of those plus `blume-redirects.json`, a structured manifest for anything else (nginx/Apache rules, an edge worker). A `_redirects` or `vercel.json` you ship in `public/` is left untouched.
|
|
148
|
+
|
|
149
|
+
Two hosts need more than the file:
|
|
150
|
+
|
|
151
|
+
- **Netlify** serves a file that exists ahead of a redirect rule unless the rule is forced, and a static build has a redirect page at every `from`. The `_redirects` for `netlify()` forces its rules (`/old /new 301!`). Cloudflare rejects that flag, so the file a build for no named host writes leaves it off, and on Netlify that build answers with the redirect page instead; name the host with `netlify({ output: "static" })` to get the HTTP redirect.
|
|
152
|
+
- **Vercel** reads `vercel.json` from the project's root directory, never from the output directory, so the copy in `dist/` applies only when you deploy that folder itself with the Vercel CLI (`vercel deploy dist`). A Git-connected project never reads it: it serves the redirect pages and none of the headers from [Content types](#content-types). Copy the `redirects` and `headers` from `dist/vercel.json` into the `vercel.json` in your project's root directory, or use `vercel()` for a server build, whose routing config carries the redirects and the discovery headers.
|
|
143
153
|
|
|
144
154
|
:::note
|
|
145
155
|
`from` and `to` are exact paths — a `:param` segment or `*` wildcard (e.g. `/blog/:slug` or `/old/*`) fails config validation, since hosts disagree on patterns. If you need pattern-based rules, handle them in an infrastructure file like `vercel.json` (which supports wildcard `source` patterns) or your host's redirect config instead. A `vercel.json` you ship in `public/` is preserved as-is.
|
|
146
156
|
:::
|
|
147
157
|
|
|
148
158
|
:::note
|
|
149
|
-
Write both `from` and `to` as if mounted at root — under [`base`](#subpath-deploys) and [`basePath`](#mount-the-docs-under-a-path) alike, Blume rewrites both sides for you, so a redirect lands inside the base. A base you've already written into `to` by hand is preserved rather than doubled.
|
|
159
|
+
Write both `from` and `to` as if mounted at root, starting with `/` (`to` can also be a full `https://` URL) — under [`base`](#subpath-deploys) and [`basePath`](#mount-the-docs-under-a-path) alike, Blume rewrites both sides for you, so a redirect lands inside the base. A `to` that names a file in `public/` (`/files/guide.pdf`) gains `base` but not `basePath`, since that's where the file is served. A base you've already written into `to` by hand is preserved rather than doubled.
|
|
150
160
|
:::
|
|
151
161
|
|
|
152
162
|
## Content types
|
|
153
163
|
|
|
154
|
-
Where the host reads one, a build also emits a `_headers` file that pins `charset=utf-8` onto the raw AI-ready endpoints — `/<route>.md`, `/<route>.mdx`, and the `.txt` files (`llms.txt`, `llms-full.txt`). Those responses are valid UTF-8, but many static hosts serve them as `text/markdown` / `text/plain` with **no** charset, and browsers then fall back to Windows-1252 — so non-ASCII docs (Japanese, accented Latin, …) render as mojibake when the raw URL is opened directly. HTML pages are unaffected because they carry `<meta charset>`. Netlify reads `_headers` on a static deploy and Cloudflare (Pages, and Workers static assets) on both static and server builds, so those adapters and an unnamed static host get the file; Vercel (whose headers ride the routing config) and Node (whose server ignores the file) don't. A `_headers` you ship in `public/` is left untouched.
|
|
164
|
+
Where the host reads one, a build also emits a `_headers` file that pins `charset=utf-8` onto the raw AI-ready endpoints — `/<route>.md`, `/<route>.mdx`, and the `.txt` files (`llms.txt`, `llms-full.txt`). Those responses are valid UTF-8, but many static hosts serve them as `text/markdown` / `text/plain` with **no** charset, and browsers then fall back to Windows-1252 — so non-ASCII docs (Japanese, accented Latin, …) render as mojibake when the raw URL is opened directly. HTML pages are unaffected because they carry `<meta charset>`. Netlify reads `_headers` on a static deploy and Cloudflare (Pages, and Workers static assets) on both static and server builds, so those adapters and an unnamed static host get the file; Vercel (whose headers ride the routing config) and Node (whose server ignores the file) don't. A Netlify server build writes the same rules into the `headers` of its Frameworks API config (`.netlify/v1/config.json`) instead. A static Vercel build writes the same rules into `dist/vercel.json` instead, which a Git-connected project doesn't read (see [Redirects](#redirects)). A `_headers` you ship in `public/` is left untouched.
|
|
155
165
|
|
|
156
166
|
## Environment variables
|
|
157
167
|
|
|
@@ -162,8 +172,9 @@ When a feature needs a runtime secret, Blume warns at `blume dev`/`build` if it'
|
|
|
162
172
|
| Assistant (AI Gateway) | `AI_GATEWAY_API_KEY` (or Vercel OIDC) |
|
|
163
173
|
| Assistant (other adapters) | the adapter's default key env var (`OPENROUTER_API_KEY`, `LLMGATEWAY_API_KEY`, `INKEEP_API_KEY`), or the `apiKeyEnv` you passed it |
|
|
164
174
|
| Mixedbread search | `MIXEDBREAD_API_KEY` |
|
|
175
|
+
| [Content sources](/docs/content/sources) | `NOTION_TOKEN` (`notion()`), `SANITY_TOKEN` (`sanity()`), `CONTENTFUL_ACCESS_TOKEN` (`contentful()`), `PAYLOAD_API_KEY` (`payload()`), `STRAPI_API_TOKEN` (`strapi()`), `GITHUB_TOKEN` (`githubReleases()`, and `mdxRemote()` reading from GitHub) |
|
|
165
176
|
|
|
166
|
-
Set them in `.env.local` for local dev and in your host's environment for production. Build-time secrets for search-index sync (Algolia, Orama Cloud, Typesense) are warned about separately during the sync step.
|
|
177
|
+
Set them in `.env.local` for local dev and in your host's environment for production. A content source reads its token when it fetches, during `blume dev` and `blume build`, so set it where your site builds. Build-time secrets for search-index sync (Algolia, Orama Cloud, Typesense) are warned about separately during the sync step.
|
|
167
178
|
|
|
168
179
|
## Build cache
|
|
169
180
|
|
package/docs/08-faq.mdx
CHANGED
|
@@ -45,7 +45,7 @@ No. A folder of Markdown is a complete site — navigation, search, and theming
|
|
|
45
45
|
|
|
46
46
|
## Can I use React components and MDX?
|
|
47
47
|
|
|
48
|
-
Yes. Any page can be `.md` or `.mdx`, and MDX lets you drop in the [built-in components](/docs/content/components) with no imports. You can also add your own `.tsx`/`.jsx` [islands](/docs/content/islands)
|
|
48
|
+
Yes. Any page can be `.md` or `.mdx`, and MDX lets you drop in the [built-in components](/docs/content/components) with no imports. You can also add your own `.tsx`/`.jsx` [islands](/docs/content/islands). Blume switches React on only when your project uses it — any `.tsx` or `.jsx` file in the project (your islands included), a React [`<Component>`](/docs/content/components#component) example, a [component override](/docs/configuration/customization), or the [assistant](/docs/configuration/assistant) — so a site with none of those ships no framework JavaScript.
|
|
49
49
|
|
|
50
50
|
## Where can I deploy it?
|
|
51
51
|
|
|
@@ -57,7 +57,7 @@ No. [Orama](/docs/configuration/search) builds a local index that works in both
|
|
|
57
57
|
|
|
58
58
|
## How do I customize the look?
|
|
59
59
|
|
|
60
|
-
Start with [theme tokens](/docs/configuration/theming) — accent color, fonts, radius, and a `theme.css` for anything else Tailwind can express. Go further by [overriding built-in components](/docs/configuration/customization) or adding [custom pages](/docs/configuration/customization#custom-pages). When you want the Astro project itself, [`blume eject`](/docs/
|
|
60
|
+
Start with [theme tokens](/docs/configuration/theming) — accent color, fonts, radius, and a `theme.css` for anything else Tailwind can express. Go further by [overriding built-in components](/docs/configuration/customization) or adding [custom pages](/docs/configuration/customization#custom-pages). When you want the Astro project itself, [`blume eject`](/docs/configuration/customization#eject) hands you a standalone app that still uses the `blume` package.
|
|
61
61
|
|
|
62
62
|
## Why is oxfmt / Ultracite collapsing my directives?
|
|
63
63
|
|
|
@@ -141,7 +141,7 @@ Patch oxfmt so it preserves the line break that sits directly against a `:::` fe
|
|
|
141
141
|
case "emphasis": {
|
|
142
142
|
```
|
|
143
143
|
|
|
144
|
-
2. Register it with your package manager's `patchedDependencies`. With Bun
|
|
144
|
+
2. Register it with your package manager's `patchedDependencies`. With Bun, add to `package.json`:
|
|
145
145
|
|
|
146
146
|
```json package.json
|
|
147
147
|
{
|
|
@@ -151,6 +151,13 @@ Patch oxfmt so it preserves the line break that sits directly against a `:::` fe
|
|
|
151
151
|
}
|
|
152
152
|
```
|
|
153
153
|
|
|
154
|
+
With pnpm, add to `pnpm-workspace.yaml` (pnpm 11 and later no longer read settings from `package.json`):
|
|
155
|
+
|
|
156
|
+
```yaml pnpm-workspace.yaml
|
|
157
|
+
patchedDependencies:
|
|
158
|
+
oxfmt@0.67.0: patches/oxfmt@0.67.0.patch
|
|
159
|
+
```
|
|
160
|
+
|
|
154
161
|
3. Reinstall so the patch is applied:
|
|
155
162
|
|
|
156
163
|
```package-install
|
|
@@ -62,7 +62,7 @@ Once you have at least one `type: changelog` entry, Blume generates a **`/change
|
|
|
62
62
|
- The date follows the configured [`dateFormat`](/docs/configuration#date-format), minus the year the row's group already shows.
|
|
63
63
|
- Drafts and `sidebar.hidden` entries are skipped.
|
|
64
64
|
|
|
65
|
-
The page appears only when nothing already occupies the `/changelog` route. To replace it with your own design, add a [custom page](/docs/advanced/custom-pages) at `pages/changelog.astro` — it takes over and Blume stops generating the default index. The `<Update>` component the previous timeline was built from
|
|
65
|
+
The page appears only when nothing already occupies the `/changelog` route. To replace it with your own design, add a [custom page](/docs/advanced/custom-pages) at `pages/changelog.astro` — it takes over and Blume stops generating the default index. The `<Update>` component the previous timeline was built from still ships for a custom page that wants inline release notes. It isn't one of the MDX components, so import it in the `.astro` page itself: `import Update from "blume/components/content/Update.astro";`.
|
|
66
66
|
|
|
67
67
|
A header [tab](/docs/content/navigation#tabs) pointing at `/changelog` opens this index — no `href` needed.
|
|
68
68
|
|
|
@@ -102,10 +102,10 @@ The module exposes:
|
|
|
102
102
|
description: "Generated RSS feeds: { href, title }.",
|
|
103
103
|
},
|
|
104
104
|
fontCssVars: {
|
|
105
|
-
type: "
|
|
105
|
+
type: "FontHead[]",
|
|
106
106
|
required: true,
|
|
107
107
|
description:
|
|
108
|
-
"
|
|
108
|
+
"The configured fonts for Astro's <Font> component in the head, one per family: { cssVariable, preloadWeights, preloadSubsets? }.",
|
|
109
109
|
},
|
|
110
110
|
ui: {
|
|
111
111
|
type: "UIStrings",
|
|
@@ -230,13 +230,15 @@ const { config } = data;
|
|
|
230
230
|
</PageLayout>
|
|
231
231
|
```
|
|
232
232
|
|
|
233
|
-
The header a custom page gets is the same one the docs pages get, so the chrome that lives in it comes along: search, the theme toggle,
|
|
233
|
+
The header a custom page gets is the same one the docs pages get, so the chrome that lives in it comes along: search, the theme toggle, and — when the [assistant](/docs/configuration/assistant) is configured — its trigger. None of it needs wiring up per page. Pass `assistantEnabled={false}` to leave the assistant trigger off one page while keeping it everywhere else.
|
|
234
|
+
|
|
235
|
+
The language switcher is the exception. A custom page is served only at its own route, so Blume can't know which other locales have a version of it, and the header shows no switcher unless you pass one: `localeSwitch` takes an entry per locale — `{ code, label, dir, href, current, untranslated }` — pointing at the page you built for each language.
|
|
234
236
|
|
|
235
237
|
The [agent-discovery head links](/docs/discoverability/agent-discovery#discovery-link-header) come along too: the layout reads the resolved config, so a custom page carries the same `describedby`, `ai-catalog`, and `ard` links the docs pages do without passing a prop. The homepage also advertises its `/index.md` Markdown mirror as a `text/markdown` alternate, since that mirror always exists; other custom pages have none, so none is advertised. Pass `discovery={null}` to drop the links from one page.
|
|
236
238
|
|
|
237
239
|
Pass `transparentHeader` to start the header see-through with its chrome in white, so it can sit over a dark hero at the top of the page; it becomes the usual frosted bar as soon as the page scrolls, and the search dialog keeps the page's own colors throughout. The hero has to run under the header for this to show — pull it up by the header's height (`-mt-16`) and pad its top to compensate.
|
|
238
240
|
|
|
239
|
-
Passing `siteUrl` (and `ogEnabled`) derives the page's `canonical` and a generated `og:image` automatically: Blume renders an Open Graph card for every static custom page (not a dynamic `[param]` one) — the home included, the most-shared URL — served at `/og/<route>.png` (`/og/index.png` for `/`). The home card
|
|
241
|
+
Passing `siteUrl` (and `ogEnabled`) derives the page's `canonical` and a generated `og:image` automatically: Blume renders an Open Graph card for every static custom page (not a dynamic `[param]` one) — the home included, the most-shared URL — served at `/og/<route>.png` (`/og/index.png` for `/`). The home card's headline is the site title, with the site description as the subtitle beneath it; a deeper page is titled from its last path segment. Set `ogImage` or `canonical` explicitly to override either. `ogImage` takes a root-relative path — a file in `public/`, resolved against [`deployment.site`](/docs/deployment) to the absolute URL crawlers need — or an external URL, which passes through untouched:
|
|
240
242
|
|
|
241
243
|
```astro pages/index.astro lineNumbers
|
|
242
244
|
<PageLayout
|
|
@@ -288,7 +290,7 @@ Blume ships a default **not found** page out of the box: a centered "404" messag
|
|
|
288
290
|
|
|
289
291
|
The page also has a Markdown twin at `/404.md` and a JSON twin at `/404.json` ([RFC 9457](https://www.rfc-editor.org/rfc/rfc9457) problem details) with the same recovery links (absolute URLs once [`deployment.site`](/docs/deployment) is set), plus the [`openapi.json`](/docs/discoverability/json-api) description when the JSON API is on. On a [Vercel or Cloudflare server build](/docs/deployment#server-rendering), a request for a missing page that sends [`Accept: text/markdown`](/docs/discoverability/markdown#content-negotiation) gets the Markdown body with the `404` status instead of the HTML shell, and one that sends `Accept: application/json` gets the problem document — so an agent never has to parse a page of chrome to learn where to go next. On Vercel the same goes for a `.md` or `.json` URL no file backs.
|
|
290
292
|
|
|
291
|
-
To replace it with your own, add a `pages/404.astro`. It owns the `/404` route the same way `pages/changelog.astro` takes over the changelog — your page wins and the default is dropped. Build it like any other custom page, in `PageLayout` or `RootLayout`:
|
|
293
|
+
To replace it with your own, add a `pages/404.astro`. It owns the `/404` route the same way `pages/changelog.astro` takes over the changelog — your page wins and the default is dropped, along with its `/404.md` and `/404.json` twins. Build it like any other custom page, in `PageLayout` or `RootLayout`:
|
|
292
294
|
|
|
293
295
|
```astro pages/404.astro lineNumbers
|
|
294
296
|
---
|
package/docs/cli/audit.mdx
CHANGED
|
@@ -83,7 +83,23 @@ Anything the audit did not run is reported as skipped rather than silently passi
|
|
|
83
83
|
|
|
84
84
|
## Check catalog
|
|
85
85
|
|
|
86
|
-
Every check `blume audit` can report, grouped by category, with its default severity, the tier it runs in, and the fix the report suggests. `--only` and `--skip` accept these ids (without the `BLUME_AUDIT_` prefix is fine too) or the category
|
|
86
|
+
Every check `blume audit` can report, grouped by category, with its default severity, the tier it runs in, and the fix the report suggests. `--only` and `--skip` accept these ids (without the `BLUME_AUDIT_` prefix is fine too) or a category's key. The key isn't always the category's heading, so use this table: `blume audit --only i18n`, not `--only Internationalization`.
|
|
87
|
+
|
|
88
|
+
| Category | Key |
|
|
89
|
+
| -------------------- | ----------------- |
|
|
90
|
+
| Content | `content` |
|
|
91
|
+
| Duplicates | `duplicates` |
|
|
92
|
+
| Indexability | `indexability` |
|
|
93
|
+
| Links | `links` |
|
|
94
|
+
| Redirects | `redirects` |
|
|
95
|
+
| Social cards | `social` |
|
|
96
|
+
| Internationalization | `i18n` |
|
|
97
|
+
| Assets | `assets` |
|
|
98
|
+
| Sitemap | `sitemap` |
|
|
99
|
+
| robots.txt | `robots` |
|
|
100
|
+
| AI discoverability | `ai` |
|
|
101
|
+
| Structured data | `structured-data` |
|
|
102
|
+
| Live deployment | `network` |
|
|
87
103
|
|
|
88
104
|
### Content
|
|
89
105
|
|
|
@@ -497,7 +513,7 @@ Fix: Remove the URL from the sitemap, or build the page it names.
|
|
|
497
513
|
|
|
498
514
|
`BLUME_AUDIT_SITEMAP_INVALID` · error · from the built HTML
|
|
499
515
|
|
|
500
|
-
Fix: Sitemaps must be valid XML in the sitemaps.org urlset format.
|
|
516
|
+
Fix: Sitemaps must be valid XML in the sitemaps.org urlset or sitemap index format.
|
|
501
517
|
|
|
502
518
|
#### Sitemap exceeds 50 MB or 50,000 URLs [#sitemap-too-large]
|
|
503
519
|
|
|
@@ -573,7 +589,7 @@ Fix: Rebuild so llms.txt matches the site — a stale entry sends an AI agent to
|
|
|
573
589
|
|
|
574
590
|
`BLUME_AUDIT_LLMS_TXT_PAGE_MISSING` · warning · from the built HTML
|
|
575
591
|
|
|
576
|
-
Fix: Rebuild so llms.txt matches the site; if the page is deliberately excluded,
|
|
592
|
+
Fix: Rebuild so llms.txt matches the site; if the page is deliberately excluded, set `ai.exclude: true` in its front matter.
|
|
577
593
|
|
|
578
594
|
#### No DNS-AID agent-discovery records [#dns-aid-missing]
|
|
579
595
|
|
package/docs/cli/doctor.mdx
CHANGED
|
@@ -14,11 +14,11 @@ blume doctor
|
|
|
14
14
|
- **The Node version** against the range the installed `blume` package supports, read from its own `engines` field. A version outside it is a warning: things may work, but it isn't a combination Blume tests.
|
|
15
15
|
- **`blume.config.ts`**, with the same validation a build runs. A removed or renamed key fails with a hint naming its replacement rather than a bare "unrecognized key".
|
|
16
16
|
- **Every content page and folder meta**: the diagnostics `blume dev` and `blume build` print as they load the project — invalid frontmatter, navigation problems, missing include targets, and the rest — collected in one report.
|
|
17
|
-
- **Features that need a server** on a site configured for static output — the assistant, the MCP server,
|
|
17
|
+
- **Features that need a server** on a site configured for static output — the assistant, the MCP server, the Try it playground's built-in proxy, or server-mode search (Mixedbread): an error naming the feature, with the deployment adapter to switch to (or, when a host adapter is set to `output: "static"`, telling you to drop that option).
|
|
18
18
|
- **Packages your config needs** that aren't installed — the SDK a search, content source, or assistant adapter imports, a deployment adapter's `@astrojs/*` package, or the renderer for Vue or Svelte islands: an error naming each package, with the install command for your package manager. `blume build` stops on the same check.
|
|
19
19
|
- **`components.ts` overrides** Blume can't plan — an inline or computed entry, or an import whose file doesn't exist: an error for each, at its line.
|
|
20
20
|
- **A version-shaped folder** (`v1.0/`) on a site with no `versions` configured, which would otherwise build as ordinary content: a warning pointing at [`blume version`](/docs/cli/version).
|
|
21
|
-
- **Secrets an enabled feature reads** that aren't set, such as `
|
|
21
|
+
- **Secrets an enabled feature reads** that aren't set, such as `MIXEDBREAD_API_KEY` or `OPENROUTER_API_KEY`: a warning naming the variable. Doctor loads `.env` and `.env.local` first, like `blume dev` and `blume build`.
|
|
22
22
|
|
|
23
23
|
## The summary
|
|
24
24
|
|