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.
Files changed (492) hide show
  1. package/CHANGELOG.md +147 -0
  2. package/dist/cli/{chunk-qwsrynx5.js → chunk-1d7ve1dm.js} +38 -19
  3. package/dist/cli/{chunk-qwsrynx5.js.map → chunk-1d7ve1dm.js.map} +4 -4
  4. package/dist/cli/{chunk-s6jhgk0q.js → chunk-2eytanqx.js} +2 -2
  5. package/dist/cli/{chunk-kdp5q7ke.js → chunk-2hsdwb9n.js} +18 -19
  6. package/dist/cli/{chunk-kdp5q7ke.js.map → chunk-2hsdwb9n.js.map} +2 -2
  7. package/dist/cli/{chunk-hdpx1tax.js → chunk-2z928egk.js} +5 -5
  8. package/dist/cli/{chunk-jwyddg7y.js → chunk-35d4wj9f.js} +30 -24
  9. package/dist/cli/chunk-35d4wj9f.js.map +15 -0
  10. package/dist/cli/{chunk-ah61y8py.js → chunk-364znk6q.js} +2 -2
  11. package/dist/cli/{chunk-jts8mvcz.js → chunk-3em5wd2y.js} +25 -6
  12. package/dist/cli/{chunk-jts8mvcz.js.map → chunk-3em5wd2y.js.map} +3 -3
  13. package/dist/cli/{chunk-s1p84fyh.js → chunk-5f86nr5m.js} +63 -22
  14. package/dist/cli/chunk-5f86nr5m.js.map +11 -0
  15. package/dist/cli/{chunk-2hn4b8z7.js → chunk-5m5nmvyq.js} +170 -76
  16. package/dist/cli/chunk-5m5nmvyq.js.map +13 -0
  17. package/dist/cli/{chunk-epjnccmv.js → chunk-5xvm6tfj.js} +18 -15
  18. package/dist/cli/chunk-5xvm6tfj.js.map +10 -0
  19. package/dist/cli/{chunk-fz5wtpmh.js → chunk-6dsbexzp.js} +18 -15
  20. package/dist/cli/chunk-6dsbexzp.js.map +10 -0
  21. package/dist/cli/{chunk-vtk4a6dg.js → chunk-8ktnccpt.js} +1 -1
  22. package/dist/cli/{chunk-6hsn950k.js → chunk-9t7a85s3.js} +178 -48
  23. package/dist/cli/chunk-9t7a85s3.js.map +10 -0
  24. package/dist/cli/{chunk-fxypxtvm.js → chunk-a58773jm.js} +2 -2
  25. package/dist/cli/{chunk-mb2919y2.js → chunk-acanzt5p.js} +17 -6
  26. package/dist/cli/chunk-acanzt5p.js.map +10 -0
  27. package/dist/cli/{chunk-27g6wdth.js → chunk-akbpwfxc.js} +90 -26
  28. package/dist/cli/chunk-akbpwfxc.js.map +10 -0
  29. package/dist/cli/{chunk-wm7js3j9.js → chunk-b07cmahc.js} +2 -2
  30. package/dist/cli/{chunk-wgm7m9qk.js → chunk-c8chx29p.js} +179 -51
  31. package/dist/cli/chunk-c8chx29p.js.map +36 -0
  32. package/dist/cli/{chunk-qs4q5p4e.js → chunk-crgn1q09.js} +32 -14
  33. package/dist/cli/chunk-crgn1q09.js.map +10 -0
  34. package/dist/cli/chunk-e04dxsz1.js +39 -0
  35. package/dist/cli/chunk-e04dxsz1.js.map +10 -0
  36. package/dist/cli/{chunk-yt5n7ppj.js → chunk-ey84smr6.js} +17 -7
  37. package/dist/cli/chunk-ey84smr6.js.map +10 -0
  38. package/dist/cli/{chunk-f2z5v128.js → chunk-g4hq16wv.js} +14 -15
  39. package/dist/cli/{chunk-f2z5v128.js.map → chunk-g4hq16wv.js.map} +2 -2
  40. package/dist/cli/{chunk-fa25z98p.js → chunk-ga0pf4aj.js} +9 -8
  41. package/dist/cli/chunk-ga0pf4aj.js.map +11 -0
  42. package/dist/cli/{chunk-kpf8rrjc.js → chunk-hm3vjy5s.js} +109 -58
  43. package/dist/cli/chunk-hm3vjy5s.js.map +19 -0
  44. package/dist/cli/{chunk-fs23ddbb.js → chunk-j85vccga.js} +625 -750
  45. package/dist/cli/chunk-j85vccga.js.map +36 -0
  46. package/dist/cli/{chunk-ch6g3ar0.js → chunk-p3v96n38.js} +6 -6
  47. package/dist/cli/{chunk-ch6g3ar0.js.map → chunk-p3v96n38.js.map} +3 -3
  48. package/dist/cli/{chunk-q5163e60.js → chunk-p73c0m7w.js} +21 -19
  49. package/dist/cli/chunk-p73c0m7w.js.map +11 -0
  50. package/dist/cli/{chunk-dh8cwk36.js → chunk-pehfxfta.js} +24 -9
  51. package/dist/cli/chunk-pehfxfta.js.map +10 -0
  52. package/dist/cli/{chunk-qkqwkpte.js → chunk-pv29h0wf.js} +3688 -1313
  53. package/dist/cli/chunk-pv29h0wf.js.map +190 -0
  54. package/dist/cli/{chunk-6vm74dry.js → chunk-q58y5e6a.js} +10 -10
  55. package/dist/cli/{chunk-6vm74dry.js.map → chunk-q58y5e6a.js.map} +3 -3
  56. package/dist/cli/{chunk-zxcczpyx.js → chunk-r20tn01b.js} +1 -1
  57. package/dist/cli/{chunk-m3vmjgmq.js → chunk-r9rcc4w7.js} +16 -8
  58. package/dist/cli/chunk-r9rcc4w7.js.map +10 -0
  59. package/dist/cli/{chunk-5shv93fd.js → chunk-tkacnehg.js} +2 -2
  60. package/dist/cli/{chunk-zxh4d9vy.js → chunk-tzmab476.js} +4 -4
  61. package/dist/cli/{chunk-yw7dm696.js → chunk-vg9r4eb9.js} +24 -11
  62. package/dist/cli/chunk-vg9r4eb9.js.map +14 -0
  63. package/dist/cli/{chunk-79jhk4py.js → chunk-wrr3j9w9.js} +260 -132
  64. package/dist/cli/chunk-wrr3j9w9.js.map +35 -0
  65. package/dist/cli/{chunk-6crbhc3x.js → chunk-yfyb25rh.js} +54 -27
  66. package/dist/cli/chunk-yfyb25rh.js.map +14 -0
  67. package/dist/cli/index.js +162 -35
  68. package/dist/cli/index.js.map +4 -4
  69. package/dist/types/ai/agent-surface.d.ts +32 -0
  70. package/dist/types/ai/api-catalog.d.ts +7 -1
  71. package/dist/types/ai/ask-context.d.ts +7 -0
  72. package/dist/types/ai/component-markdown.d.ts +4 -4
  73. package/dist/types/ai/link-headers.d.ts +8 -1
  74. package/dist/types/ai/openapi-components.d.ts +5 -2
  75. package/dist/types/ai/relative-links.d.ts +11 -4
  76. package/dist/types/ai/skills.d.ts +4 -1
  77. package/dist/types/ai/static-expression.d.ts +28 -0
  78. package/dist/types/ai/tar.d.ts +1 -3
  79. package/dist/types/analytics/databuddy.d.ts +43 -0
  80. package/dist/types/analytics/index.d.ts +4 -0
  81. package/dist/types/analytics/one-dollar-stats.d.ts +48 -0
  82. package/dist/types/analytics/schema.d.ts +28 -0
  83. package/dist/types/astro/integration.d.ts +3 -2
  84. package/dist/types/cli/env.d.ts +5 -0
  85. package/dist/types/cli/init/scaffold.d.ts +19 -3
  86. package/dist/types/cli/init/starter-spec.d.ts +11 -0
  87. package/dist/types/core/base-path.d.ts +24 -1
  88. package/dist/types/core/config-input.d.ts +13 -11
  89. package/dist/types/core/config.d.ts +2 -2
  90. package/dist/types/core/directive-diagnostics.d.ts +12 -0
  91. package/dist/types/core/graph.d.ts +2 -0
  92. package/dist/types/core/heading-markers.d.ts +5 -7
  93. package/dist/types/core/i18n-ui.d.ts +31 -0
  94. package/dist/types/core/i18n.d.ts +9 -1
  95. package/dist/types/core/last-modified.d.ts +10 -0
  96. package/dist/types/core/links.d.ts +3 -1
  97. package/dist/types/core/load-module.d.ts +10 -0
  98. package/dist/types/core/locale-links.d.ts +12 -2
  99. package/dist/types/core/meta.d.ts +13 -1
  100. package/dist/types/core/nav-diagnostics.d.ts +10 -0
  101. package/dist/types/core/navigation.d.ts +38 -0
  102. package/dist/types/core/ordering-prefix.d.ts +4 -0
  103. package/dist/types/core/safe-links.d.ts +3 -1
  104. package/dist/types/core/schema.d.ts +59 -13
  105. package/dist/types/core/sources/github-releases.d.ts +5 -0
  106. package/dist/types/core/sources/lower.d.ts +38 -13
  107. package/dist/types/core/sources/normalize.d.ts +23 -2
  108. package/dist/types/core/sources/remote.d.ts +11 -1
  109. package/dist/types/core/sources/resolve.d.ts +12 -0
  110. package/dist/types/core/sources/types.d.ts +31 -0
  111. package/dist/types/core/sources/watch.d.ts +12 -5
  112. package/dist/types/core/standard-schema.d.ts +5 -0
  113. package/dist/types/core/types.d.ts +9 -0
  114. package/dist/types/deploy/adapters/node.d.ts +5 -2
  115. package/dist/types/deploy/adapters/types.d.ts +7 -0
  116. package/dist/types/deploy/artifacts.d.ts +6 -4
  117. package/dist/types/deploy/cloudflare-negotiation.d.ts +3 -2
  118. package/dist/types/deploy/headers.d.ts +36 -7
  119. package/dist/types/deploy/node-headers.d.ts +43 -8
  120. package/dist/types/deploy/platforms/netlify.d.ts +27 -2
  121. package/dist/types/deploy/platforms/node.d.ts +6 -5
  122. package/dist/types/deploy/platforms/types.d.ts +15 -0
  123. package/dist/types/deploy/platforms/vercel.d.ts +3 -2
  124. package/dist/types/deploy/redirects.d.ts +31 -15
  125. package/dist/types/deploy/vercel-negotiation.d.ts +3 -2
  126. package/dist/types/markdown/directives.d.ts +62 -0
  127. package/dist/types/markdown/features.d.ts +21 -0
  128. package/dist/types/markdown/mdast.d.ts +63 -0
  129. package/dist/types/openapi/asyncapi.d.ts +4 -2
  130. package/dist/types/openapi/model.d.ts +20 -6
  131. package/dist/types/search/sync/algolia.d.ts +3 -1
  132. package/docs/01-quickstart.mdx +3 -2
  133. package/docs/02-deployment.mdx +20 -9
  134. package/docs/08-faq.mdx +10 -3
  135. package/docs/advanced/changelog.mdx +1 -1
  136. package/docs/advanced/custom-pages.mdx +7 -5
  137. package/docs/cli/audit.mdx +19 -3
  138. package/docs/cli/doctor.mdx +2 -2
  139. package/docs/cli/evals.mdx +4 -4
  140. package/docs/cli/index.mdx +4 -1
  141. package/docs/cli/translate.mdx +4 -4
  142. package/docs/cli/version.mdx +1 -1
  143. package/docs/configuration/analytics.mdx +42 -2
  144. package/docs/configuration/assistant.mdx +1 -1
  145. package/docs/configuration/customization.mdx +6 -3
  146. package/docs/configuration/index.mdx +5 -3
  147. package/docs/configuration/search.mdx +2 -2
  148. package/docs/content/components.mdx +2 -2
  149. package/docs/content/frontmatter.mdx +5 -1
  150. package/docs/content/i18n.mdx +3 -1
  151. package/docs/content/index.mdx +8 -4
  152. package/docs/content/islands.mdx +1 -1
  153. package/docs/content/meta.mdx +7 -3
  154. package/docs/content/navigation.mdx +29 -4
  155. package/docs/content/sources.mdx +18 -16
  156. package/docs/content/syntax.mdx +14 -0
  157. package/docs/content/versioning.mdx +2 -1
  158. package/docs/discoverability/agent-discovery.mdx +22 -8
  159. package/docs/discoverability/index.mdx +4 -3
  160. package/docs/discoverability/llms-txt.mdx +2 -5
  161. package/docs/discoverability/markdown.mdx +6 -4
  162. package/docs/discoverability/mcp.mdx +4 -0
  163. package/docs/discoverability/metadata.mdx +3 -2
  164. package/docs/discoverability/open-graph.mdx +8 -4
  165. package/docs/discoverability/rss.mdx +4 -2
  166. package/docs/references/asyncapi.mdx +2 -2
  167. package/docs/references/graphql.mdx +2 -2
  168. package/docs/references/openapi.mdx +6 -4
  169. package/package.json +1 -1
  170. package/skills/blume-migrate/SKILL.md +6 -6
  171. package/skills/blume-migrate/references/docusaurus.md +6 -6
  172. package/skills/blume-migrate/references/fumadocs.md +1 -1
  173. package/skills/blume-migrate/references/mintlify.md +3 -3
  174. package/skills/blume-migrate/references/monorepo.md +1 -1
  175. package/skills/blume-migrate/references/nextra.md +2 -2
  176. package/skills/blume-migrate/references/starlight.md +5 -5
  177. package/skills/blume-migrate/scripts/mintlify-codemod.mjs +9 -4
  178. package/skills/blume-update-docs/references/audit-checklist.md +1 -1
  179. package/src/ai/agent-readability.ts +2 -2
  180. package/src/ai/agent-surface.ts +56 -0
  181. package/src/ai/ai-catalog.ts +6 -2
  182. package/src/ai/api/handlers.ts +2 -2
  183. package/src/ai/api/spec.ts +17 -4
  184. package/src/ai/api-catalog.ts +13 -3
  185. package/src/ai/ask-context.ts +14 -2
  186. package/src/ai/ask-data.ts +26 -12
  187. package/src/ai/changelog-markdown.ts +2 -2
  188. package/src/ai/component-markdown.ts +43 -37
  189. package/src/ai/link-headers.ts +22 -8
  190. package/src/ai/llms.ts +22 -10
  191. package/src/ai/markdown.ts +23 -11
  192. package/src/ai/mcp/discovery.ts +2 -2
  193. package/src/ai/mcp/query.ts +2 -2
  194. package/src/ai/mcp/server.ts +80 -9
  195. package/src/ai/openapi-components.ts +22 -6
  196. package/src/ai/relative-links.ts +99 -15
  197. package/src/ai/serializers.ts +2 -1
  198. package/src/ai/skills.ts +14 -1
  199. package/src/ai/static-expression.ts +416 -0
  200. package/src/ai/tar.ts +139 -12
  201. package/src/ai/visibility.ts +45 -14
  202. package/src/analytics/databuddy.ts +67 -0
  203. package/src/analytics/head.ts +8 -0
  204. package/src/analytics/index.ts +7 -0
  205. package/src/analytics/one-dollar-stats.ts +86 -0
  206. package/src/analytics/posthog.ts +21 -3
  207. package/src/analytics/schema.ts +4 -0
  208. package/src/astro/generate.ts +72 -28
  209. package/src/astro/include-hmr.ts +31 -12
  210. package/src/astro/include-refresh.ts +19 -8
  211. package/src/astro/integration.ts +108 -14
  212. package/src/astro/runtime-modules.ts +28 -13
  213. package/src/astro/templates.ts +139 -57
  214. package/src/audit/catalog.ts +2 -2
  215. package/src/audit/checks/assets.ts +25 -5
  216. package/src/audit/checks/content.ts +20 -2
  217. package/src/audit/checks/i18n.ts +46 -8
  218. package/src/audit/checks/indexability.ts +39 -19
  219. package/src/audit/checks/links.ts +22 -1
  220. package/src/audit/checks/llms.ts +6 -3
  221. package/src/audit/checks/network.ts +3 -1
  222. package/src/audit/checks/og-image.ts +10 -0
  223. package/src/audit/checks/robots.ts +6 -1
  224. package/src/audit/checks/sitemap.ts +56 -31
  225. package/src/audit/checks/social.ts +21 -2
  226. package/src/audit/crawl.ts +88 -15
  227. package/src/audit/graph.ts +3 -1
  228. package/src/audit/report.ts +54 -17
  229. package/src/audit/run.ts +13 -9
  230. package/src/audit/snapshot.ts +5 -0
  231. package/src/audit/types.ts +18 -0
  232. package/src/audit/url.ts +37 -6
  233. package/src/cli/args.ts +32 -0
  234. package/src/cli/build-failure.ts +50 -0
  235. package/src/cli/commands/audit.ts +11 -1
  236. package/src/cli/commands/build.ts +19 -5
  237. package/src/cli/commands/check.ts +2 -0
  238. package/src/cli/commands/doctor.ts +3 -1
  239. package/src/cli/commands/eval.ts +20 -18
  240. package/src/cli/commands/init.ts +15 -5
  241. package/src/cli/commands/preview.ts +15 -0
  242. package/src/cli/commands/sync.ts +2 -0
  243. package/src/cli/commands/translate.ts +18 -18
  244. package/src/cli/commands/upgrade.ts +11 -0
  245. package/src/cli/commands/validate.ts +3 -1
  246. package/src/cli/dev-lock.ts +157 -37
  247. package/src/cli/eject-scripts.ts +32 -7
  248. package/src/cli/env.ts +12 -1
  249. package/src/cli/init/scaffold.ts +117 -11
  250. package/src/cli/init/starter-spec.ts +235 -0
  251. package/src/cli/report-format.ts +11 -6
  252. package/src/components/colors.ts +19 -0
  253. package/src/components/content/AccordionItem.astro +26 -22
  254. package/src/components/content/Badge.astro +7 -12
  255. package/src/components/content/Card.astro +2 -2
  256. package/src/components/content/Component.astro +11 -5
  257. package/src/components/content/Expandable.astro +5 -1
  258. package/src/components/content/Frame.astro +2 -7
  259. package/src/components/content/GithubInfo.astro +12 -2
  260. package/src/components/content/Prompt.astro +2 -7
  261. package/src/components/content/Tab.astro +0 -1
  262. package/src/components/content/Tabs.astro +58 -5
  263. package/src/components/content/Tile.astro +1 -1
  264. package/src/components/content/Tooltip.astro +69 -7
  265. package/src/components/content/Tree.astro +7 -2
  266. package/src/components/content/TypeTable.astro +10 -5
  267. package/src/components/content/Update.astro +8 -2
  268. package/src/components/content/auto-type-table.ts +4 -1
  269. package/src/components/content/badge-color.ts +20 -0
  270. package/src/components/content/base-href.ts +14 -22
  271. package/src/components/content/inline-markdown.ts +27 -7
  272. package/src/components/copy-feedback.ts +35 -8
  273. package/src/components/islands/assistant.tsx +37 -6
  274. package/src/components/islands/base-path.ts +47 -10
  275. package/src/components/islands/hooks.ts +42 -21
  276. package/src/components/islands/webmcp.ts +16 -10
  277. package/src/components/layout/Banner.astro +23 -4
  278. package/src/components/layout/Breadcrumbs.astro +5 -2
  279. package/src/components/layout/DiscoveryLinks.astro +9 -5
  280. package/src/components/layout/Header.astro +23 -10
  281. package/src/components/layout/LanguageSwitcher.astro +2 -2
  282. package/src/components/layout/Logo.astro +5 -0
  283. package/src/components/layout/NavSelector.astro +8 -3
  284. package/src/components/layout/NavTabMenu.astro +133 -0
  285. package/src/components/layout/NavTree.astro +31 -12
  286. package/src/components/layout/NavTreeCache.astro +5 -2
  287. package/src/components/layout/NavTreeScript.astro +45 -5
  288. package/src/components/layout/PageActions.astro +4 -3
  289. package/src/components/layout/PageLayout.astro +28 -13
  290. package/src/components/layout/Pagination.astro +3 -3
  291. package/src/components/layout/ReferenceLayout.astro +4 -1
  292. package/src/components/layout/RootLayout.astro +25 -12
  293. package/src/components/layout/Search.astro +38 -14
  294. package/src/components/layout/VersionBanner.astro +2 -2
  295. package/src/components/layout/analytics-client.ts +14 -0
  296. package/src/components/layout/toc-active.ts +41 -0
  297. package/src/components/layout/toc-element.ts +8 -14
  298. package/src/components/openapi/ApiTagOperations.astro +2 -2
  299. package/src/components/openapi/AsyncApiOperation.astro +7 -4
  300. package/src/components/openapi/GraphqlChip.astro +2 -2
  301. package/src/components/openapi/GraphqlType.astro +11 -3
  302. package/src/components/openapi/MessageComposer.astro +1 -1
  303. package/src/components/openapi/Operation.astro +23 -5
  304. package/src/components/openapi/PanelTabs.astro +4 -1
  305. package/src/components/openapi/Playground.astro +8 -2
  306. package/src/components/openapi/RequestPanel.astro +13 -6
  307. package/src/components/openapi/SchemaProperty.astro +11 -33
  308. package/src/components/openapi/SchemaTable.astro +34 -52
  309. package/src/components/openapi/async.ts +38 -6
  310. package/src/components/openapi/helpers.ts +100 -12
  311. package/src/components/openapi/message-composer.ts +14 -1
  312. package/src/components/openapi/message-model.ts +12 -2
  313. package/src/components/openapi/message.ts +21 -3
  314. package/src/components/openapi/operation-model.ts +119 -17
  315. package/src/components/openapi/panel.ts +31 -5
  316. package/src/components/openapi/param-style.ts +181 -0
  317. package/src/components/openapi/playground-client.ts +110 -23
  318. package/src/components/openapi/playground-schema.ts +25 -6
  319. package/src/components/openapi/request.ts +192 -26
  320. package/src/components/openapi/schema-tree.ts +209 -0
  321. package/src/components/openapi/snippets.ts +113 -19
  322. package/src/components/openapi/validate-json.ts +1 -1
  323. package/src/components/openapi/ws-client.ts +18 -2
  324. package/src/core/base-path.ts +69 -8
  325. package/src/core/config-input.ts +13 -11
  326. package/src/core/config.ts +18 -4
  327. package/src/core/diagnostics.ts +219 -30
  328. package/src/core/directive-diagnostics.ts +99 -0
  329. package/src/core/frontmatter.ts +21 -18
  330. package/src/core/graph.ts +120 -11
  331. package/src/core/heading-markers.ts +5 -18
  332. package/src/core/i18n-ui.ts +39 -2
  333. package/src/core/i18n.ts +44 -5
  334. package/src/core/last-modified.ts +25 -3
  335. package/src/core/links.ts +7 -4
  336. package/src/core/load-module.ts +20 -0
  337. package/src/core/locale-links.ts +22 -18
  338. package/src/core/manifest.ts +3 -2
  339. package/src/core/meta.ts +89 -12
  340. package/src/core/nav-diagnostics.ts +56 -1
  341. package/src/core/navigation.ts +272 -83
  342. package/src/core/ordering-prefix.ts +27 -0
  343. package/src/core/project-graph.ts +50 -6
  344. package/src/core/safe-href.ts +53 -1
  345. package/src/core/safe-links.ts +11 -2
  346. package/src/core/schema.ts +94 -18
  347. package/src/core/sources/assets.ts +83 -41
  348. package/src/core/sources/contentful-rich-text.ts +28 -20
  349. package/src/core/sources/contentful.ts +25 -12
  350. package/src/core/sources/filesystem.ts +25 -3
  351. package/src/core/sources/github-releases.ts +131 -11
  352. package/src/core/sources/lexical.ts +30 -20
  353. package/src/core/sources/lower.ts +276 -56
  354. package/src/core/sources/mdx-remote.ts +52 -16
  355. package/src/core/sources/normalize.ts +456 -119
  356. package/src/core/sources/notion.ts +77 -34
  357. package/src/core/sources/obsidian.ts +40 -9
  358. package/src/core/sources/payload.ts +1 -0
  359. package/src/core/sources/portable-text.ts +85 -49
  360. package/src/core/sources/remote.ts +18 -2
  361. package/src/core/sources/resolve.ts +52 -33
  362. package/src/core/sources/sanity.ts +1 -0
  363. package/src/core/sources/strapi-blocks.ts +28 -19
  364. package/src/core/sources/strapi.ts +1 -0
  365. package/src/core/sources/types.ts +31 -0
  366. package/src/core/sources/watch.ts +20 -7
  367. package/src/core/standard-schema.ts +10 -6
  368. package/src/core/types.ts +9 -0
  369. package/src/core/ui-packs/ar.ts +13 -0
  370. package/src/core/ui-packs/bg.ts +13 -0
  371. package/src/core/ui-packs/bn.ts +13 -0
  372. package/src/core/ui-packs/ca.ts +13 -0
  373. package/src/core/ui-packs/cs.ts +13 -0
  374. package/src/core/ui-packs/da.ts +13 -0
  375. package/src/core/ui-packs/de.ts +13 -0
  376. package/src/core/ui-packs/el.ts +13 -0
  377. package/src/core/ui-packs/es.ts +13 -0
  378. package/src/core/ui-packs/fa.ts +13 -0
  379. package/src/core/ui-packs/fi.ts +13 -0
  380. package/src/core/ui-packs/fr.ts +13 -0
  381. package/src/core/ui-packs/he.ts +13 -0
  382. package/src/core/ui-packs/hi.ts +13 -0
  383. package/src/core/ui-packs/hr.ts +13 -0
  384. package/src/core/ui-packs/hu.ts +13 -0
  385. package/src/core/ui-packs/id.ts +13 -0
  386. package/src/core/ui-packs/it.ts +13 -0
  387. package/src/core/ui-packs/ja.ts +13 -0
  388. package/src/core/ui-packs/ko.ts +13 -0
  389. package/src/core/ui-packs/nl.ts +13 -0
  390. package/src/core/ui-packs/no.ts +13 -0
  391. package/src/core/ui-packs/pl.ts +13 -0
  392. package/src/core/ui-packs/pt-br.ts +13 -0
  393. package/src/core/ui-packs/pt.ts +13 -0
  394. package/src/core/ui-packs/ro.ts +13 -0
  395. package/src/core/ui-packs/ru.ts +13 -0
  396. package/src/core/ui-packs/sk.ts +13 -0
  397. package/src/core/ui-packs/sr.ts +13 -0
  398. package/src/core/ui-packs/sv.ts +13 -0
  399. package/src/core/ui-packs/th.ts +13 -0
  400. package/src/core/ui-packs/tr.ts +13 -0
  401. package/src/core/ui-packs/uk.ts +13 -0
  402. package/src/core/ui-packs/vi.ts +13 -0
  403. package/src/core/ui-packs/zh-tw.ts +13 -0
  404. package/src/core/ui-packs/zh.ts +13 -0
  405. package/src/core/version-cut.ts +69 -17
  406. package/src/core/versions.ts +4 -1
  407. package/src/deploy/adapters/node.ts +5 -2
  408. package/src/deploy/adapters/registry.ts +2 -1
  409. package/src/deploy/adapters/types.ts +13 -1
  410. package/src/deploy/artifacts.ts +52 -11
  411. package/src/deploy/cloudflare-negotiation.ts +27 -16
  412. package/src/deploy/headers.ts +75 -55
  413. package/src/deploy/node-headers.ts +148 -27
  414. package/src/deploy/platforms/cloudflare.ts +13 -3
  415. package/src/deploy/platforms/netlify.ts +83 -5
  416. package/src/deploy/platforms/node.ts +8 -5
  417. package/src/deploy/platforms/static.ts +2 -0
  418. package/src/deploy/platforms/types.ts +15 -0
  419. package/src/deploy/platforms/vercel.ts +10 -3
  420. package/src/deploy/redirects.ts +68 -21
  421. package/src/deploy/robots.ts +2 -2
  422. package/src/deploy/rss.ts +4 -3
  423. package/src/deploy/sitemap.ts +7 -5
  424. package/src/deploy/vercel-negotiation.ts +35 -3
  425. package/src/eval/agents.ts +10 -2
  426. package/src/eval/run.ts +25 -0
  427. package/src/markdown/base-links.ts +74 -29
  428. package/src/markdown/directives.ts +242 -36
  429. package/src/markdown/features.ts +17 -0
  430. package/src/markdown/index.ts +13 -9
  431. package/src/markdown/mdast.ts +5 -2
  432. package/src/markdown/relative-links.ts +15 -27
  433. package/src/markdown/route-snapshot.ts +37 -0
  434. package/src/og/card.ts +149 -9
  435. package/src/og/derive.ts +156 -5
  436. package/src/og/index.ts +1 -0
  437. package/src/openapi/asyncapi.ts +4 -2
  438. package/src/openapi/graphql-build.ts +28 -2
  439. package/src/openapi/model.ts +99 -27
  440. package/src/openapi/proxy.ts +63 -10
  441. package/src/openapi/render-mdx.ts +51 -3
  442. package/src/registry/eject.ts +297 -43
  443. package/src/search/adapters/version-scope.ts +30 -0
  444. package/src/search/documents.ts +89 -27
  445. package/src/search/popular.ts +2 -1
  446. package/src/search/sync/algolia.ts +36 -2
  447. package/src/seo/jsonld.ts +7 -3
  448. package/src/sources/registry.ts +5 -0
  449. package/src/theme/entry.ts +11 -4
  450. package/src/translate/agents.ts +6 -1
  451. package/src/translate/ledger.ts +26 -3
  452. package/src/translate/meta.ts +76 -24
  453. package/src/translate/run.ts +14 -8
  454. package/src/translate/validate.ts +14 -2
  455. package/src/translate/work-list.ts +91 -19
  456. package/src/upgrade/upgrade.ts +36 -4
  457. package/dist/cli/chunk-27g6wdth.js.map +0 -10
  458. package/dist/cli/chunk-2hn4b8z7.js.map +0 -12
  459. package/dist/cli/chunk-6crbhc3x.js.map +0 -14
  460. package/dist/cli/chunk-6hsn950k.js.map +0 -10
  461. package/dist/cli/chunk-79jhk4py.js.map +0 -35
  462. package/dist/cli/chunk-82bbrxdn.js +0 -51
  463. package/dist/cli/chunk-82bbrxdn.js.map +0 -10
  464. package/dist/cli/chunk-abh8yjkn.js +0 -31
  465. package/dist/cli/chunk-abh8yjkn.js.map +0 -10
  466. package/dist/cli/chunk-ce574jw2.js +0 -23
  467. package/dist/cli/chunk-ce574jw2.js.map +0 -10
  468. package/dist/cli/chunk-dh8cwk36.js.map +0 -10
  469. package/dist/cli/chunk-epjnccmv.js.map +0 -10
  470. package/dist/cli/chunk-fa25z98p.js.map +0 -11
  471. package/dist/cli/chunk-fs23ddbb.js.map +0 -35
  472. package/dist/cli/chunk-fz5wtpmh.js.map +0 -10
  473. package/dist/cli/chunk-jwyddg7y.js.map +0 -15
  474. package/dist/cli/chunk-kpf8rrjc.js.map +0 -19
  475. package/dist/cli/chunk-m3vmjgmq.js.map +0 -10
  476. package/dist/cli/chunk-mb2919y2.js.map +0 -10
  477. package/dist/cli/chunk-q5163e60.js.map +0 -11
  478. package/dist/cli/chunk-qkqwkpte.js.map +0 -182
  479. package/dist/cli/chunk-qs4q5p4e.js.map +0 -10
  480. package/dist/cli/chunk-s1p84fyh.js.map +0 -10
  481. package/dist/cli/chunk-wgm7m9qk.js.map +0 -36
  482. package/dist/cli/chunk-yt5n7ppj.js.map +0 -10
  483. package/dist/cli/chunk-yw7dm696.js.map +0 -14
  484. /package/dist/cli/{chunk-s6jhgk0q.js.map → chunk-2eytanqx.js.map} +0 -0
  485. /package/dist/cli/{chunk-hdpx1tax.js.map → chunk-2z928egk.js.map} +0 -0
  486. /package/dist/cli/{chunk-ah61y8py.js.map → chunk-364znk6q.js.map} +0 -0
  487. /package/dist/cli/{chunk-vtk4a6dg.js.map → chunk-8ktnccpt.js.map} +0 -0
  488. /package/dist/cli/{chunk-fxypxtvm.js.map → chunk-a58773jm.js.map} +0 -0
  489. /package/dist/cli/{chunk-wm7js3j9.js.map → chunk-b07cmahc.js.map} +0 -0
  490. /package/dist/cli/{chunk-zxcczpyx.js.map → chunk-r20tn01b.js.map} +0 -0
  491. /package/dist/cli/{chunk-5shv93fd.js.map → chunk-tkacnehg.js.map} +0 -0
  492. /package/dist/cli/{chunk-zxh4d9vy.js.map → chunk-tzmab476.js.map} +0 -0
@@ -33,6 +33,10 @@ export declare const STARTERS: {
33
33
  content: string;
34
34
  path: string;
35
35
  }[];
36
+ projectFiles: {
37
+ content: string;
38
+ path: string;
39
+ }[];
36
40
  };
37
41
  changelog: {
38
42
  configExtra: string;
@@ -71,6 +75,11 @@ export declare const commandsFor: (pm: PackageManager) => {
71
75
  exec: string;
72
76
  install: string;
73
77
  };
78
+ /**
79
+ * The `cd` into the new project, quoting a directory a shell would split or
80
+ * expand: `blume init "my docs"` prints `cd "my docs"`, not `cd my docs`.
81
+ */
82
+ export declare const cdCommand: (directory: string) => string;
74
83
  /**
75
84
  * Derive the package manager from an npm user-agent string (the first
76
85
  * `name/version` token of `npm_config_user_agent`), falling back to npm.
@@ -97,6 +106,12 @@ export declare const validateContentDir: (root: string, dir: string) => string |
97
106
  export declare const titleize: (raw: string) => string;
98
107
  /** The full `blume.config.ts` text for the chosen answers. */
99
108
  export declare const buildConfig: (answers: InitAnswers) => string;
109
+ /**
110
+ * Whether `init` installs with pnpm into a folder that sits inside a pnpm
111
+ * workspace without being one of its packages. pnpm would install that
112
+ * workspace's own packages from there and exit 0, leaving `blume` uninstalled.
113
+ */
114
+ export declare const outsidePnpmWorkspace: (root: string, answers: InitAnswers) => boolean;
100
115
  /**
101
116
  * The major version of the Yarn that ran `init`, read off the npm user agent
102
117
  * (`yarn/4.5.1 npm/? node/v22…`), or undefined when something else ran it.
@@ -108,9 +123,10 @@ export interface PlanEnvironment {
108
123
  userAgent?: string;
109
124
  }
110
125
  /**
111
- * What the project still needs from a workspace it joins, when `init` left
112
- * that workspace's config alone: pnpm's approval for esbuild's build script
113
- * (pnpm 10 and later fail the install without it), or Yarn Berry's
126
+ * What the project still needs from a workspace it sits in, when `init` left
127
+ * that workspace's config alone: a place in a pnpm workspace's `packages`
128
+ * (pnpm skips a folder it doesn't list), pnpm's approval for esbuild's build
129
+ * script (pnpm 10 and later fail the install without it), or Yarn Berry's
114
130
  * `node_modules` linker. Undefined when the workspace already has it, or the
115
131
  * project doesn't sit in one.
116
132
  */
@@ -0,0 +1,11 @@
1
+ /**
2
+ * The OpenAPI document the `api` starter writes beside `blume.config.ts`, so a
3
+ * new project's first build reads a local file instead of depending on a
4
+ * third-party server. Small, but it exercises what a real reference renders:
5
+ * path and query parameters, request bodies, shared schemas, error responses,
6
+ * and bearer auth. Each operation's description is sized so its page's meta
7
+ * description, with the endpoint sentence Blume appends, fits the range
8
+ * `blume audit` checks.
9
+ */
10
+ /** The starter spec as the `openapi.json` text `init` writes. */
11
+ export declare const STARTER_OPENAPI_JSON: string;
@@ -48,9 +48,20 @@ export declare const isExternalUrl: (target: string) => boolean;
48
48
  /**
49
49
  * Idempotently prepend `basePath` to a root-relative route. A route already
50
50
  * equal to or nested under the base is returned unchanged, so authors who write
51
- * the base by hand (`/docs/x`) aren't double-prefixed to `/docs/docs/x`.
51
+ * the base by hand (`/docs/x`, `/docs#install`) aren't double-prefixed to
52
+ * `/docs/docs/x`.
52
53
  */
53
54
  export declare const withBasePath: (basePath: string, route: string) => string;
55
+ /**
56
+ * Mount a route Blume generates under a base, unconditionally: `basePath` for
57
+ * a content route, `deployment.base` for any generated URL (a sitemap entry,
58
+ * a feed item). {@link withBasePath} leaves a route that already starts with
59
+ * the base alone, which is right for a link an author based by hand but wrong
60
+ * for a generated route: with `basePath: "/docs"`, `docs/guide.md` routes to
61
+ * `/docs/guide` before the base and publishes at `/docs/docs/guide`, not on
62
+ * top of the root `guide.md` — and likewise under `deployment.base: "/docs"`.
63
+ */
64
+ export declare const mountBasePath: (basePath: string, route: string) => string;
54
65
  /**
55
66
  * {@link withBasePath} for the composed `deployment.base` + `basePath` stack
56
67
  * (`/base` + `/docs` serves pages at `/base/docs/x`). The hand-written-base
@@ -60,6 +71,18 @@ export declare const withBasePath: (basePath: string, route: string) => string;
60
71
  * and a route already under the full composite is returned unchanged.
61
72
  */
62
73
  export declare const withComposedBasePath: (deployBase: string, basePath: string, route: string) => string;
74
+ /**
75
+ * Base a root-relative link an author wrote as if mounted at root — a content
76
+ * link (`markdown/base-links.ts`, `components/content/base-href.ts`) or a
77
+ * redirect target (`deploy/redirects.ts`) — by what it names. A page gains the
78
+ * composed stack ({@link withComposedBasePath}). A public asset — a path whose
79
+ * final segment carries a file extension, with no page served there (a dotted
80
+ * route like `/releases/v1.2` is still a page) — gains the deployment base
81
+ * alone: Astro serves `public/` under `deployment.base`, but never under
82
+ * `basePath`. `servesPage` answers whether a page is served at a
83
+ * `basePath`-prefixed, fragment-less path. Other targets pass through.
84
+ */
85
+ export declare const withAuthoredBasePath: (deployBase: string, basePath: string, target: string, servesPage: (route: string) => boolean) => string;
63
86
  /**
64
87
  * Remove `basePath` from the front of a route (`/docs/guide` -> `/guide`,
65
88
  * `/docs` -> `/`). A route not under the base is returned unchanged. Inverse of
@@ -524,14 +524,14 @@ export interface LlmsTxtConfig {
524
524
  /**
525
525
  * Markdown placed after the title and summary in `llms.txt`, before the
526
526
  * page sections — the llms.txt spec's "details" block. Use it to tell
527
- * agents when to reach for the product and how to call it (a "When to use"
528
- * heading, the install command, the package name). Blank values are
529
- * dropped.
527
+ * agents when to reach for the product and how to call it (the install
528
+ * command, the package name). The spec allows any Markdown there but
529
+ * headings. Blank values are dropped.
530
530
  *
531
531
  * ```ts
532
532
  * agents: {
533
533
  * llmsTxt: {
534
- * details: "## When to use Acme\n\nUse Acme when…",
534
+ * details: "Use Acme when…",
535
535
  * },
536
536
  * }
537
537
  * ```
@@ -850,13 +850,15 @@ export interface OgConfig {
850
850
  */
851
851
  enabled?: boolean;
852
852
  /**
853
- * Fonts for the generated card, extending Takumi's Latin-only default so
854
- * non-Latin titles (CJK, and so on) render instead of tofu. A bare string is
855
- * a Google Fonts family fetched at build; the name-only object form pins
856
- * weights (`700`, `[400, 700]`, or a `"100..900"` variable range) and
857
- * styles; the `src` form reads a local font file from the project instead.
858
- * When omitted and `theme.fonts` is explicitly configured, the theme's
859
- * display and body fonts are used automatically — pass `[]` to opt out.
853
+ * Fonts for the generated card, replacing the default stack: Takumi's
854
+ * Latin-only built-in font plus a Noto fallback per script, which a card
855
+ * fetches only when its text needs one. A bare string is a Google Fonts
856
+ * family fetched at build; the name-only object form pins weights (`700`,
857
+ * `[400, 700]`, or a `"100..900"` variable range) and styles; the `src`
858
+ * form reads a local font file from the project instead. When omitted and
859
+ * `theme.fonts` is explicitly configured, the theme's display and body
860
+ * fonts are used automatically, ahead of the fallbacks — pass `[]` to opt
861
+ * out of both.
860
862
  */
861
863
  fonts?: (string | {
862
864
  name: string;
@@ -55,8 +55,8 @@ import type { Diagnostic } from "./types.ts";
55
55
  * - `theme` — `accent` color, `fonts` (curated slugs, any provider family, or
56
56
  * local font files), `radius`,
57
57
  * `mode` (`system`/`light`/`dark`), and `background`.
58
- * - `markdown` — `code` (language icons, inline highlighting, line wrap),
59
- * `headingAnchors`, `imageZoom`, and opt-in KaTeX `math`.
58
+ * - `markdown` — `code` (language icons, light/dark Shiki `theme`, line
59
+ * `wrap`), `externalLinks`, `headingAnchors`, and `imageZoom`.
60
60
  * - `toc` — on-page table of contents; `true`/`false` or a heading-level range.
61
61
  * - `lastModified` — "Last updated" stamps from `git` history or frontmatter.
62
62
  * - `feedback` — the per-page "Was this helpful?" widget (on by default).
@@ -0,0 +1,12 @@
1
+ import type { SourceEntry } from "./sources/types.ts";
2
+ import type { Diagnostic } from "./types.ts";
3
+ /**
4
+ * Warn about each `:::name` container in an `.mdx` entry that isn't a callout.
5
+ * The page keeps its content — the body renders between the literal `:::`
6
+ * lines (see `markdown/directives.ts`) — but a typo like `:::warnig`, or a
7
+ * `:::details` carried over from another docs tool, should read as the
8
+ * mistake it is rather than as a finished page. Lines point into the file
9
+ * the author wrote, a partial's own file for a container an `<include>`
10
+ * brought in.
11
+ */
12
+ export declare const unknownDirectiveDiagnostics: (entry: SourceEntry, sourceName: string) => Diagnostic[];
@@ -1,6 +1,8 @@
1
1
  import type { FolderMeta, ResolvedConfig, ResolvedI18nConfig, ResolvedVersionsConfig } from "./schema.ts";
2
2
  import type { ContentGraph, PageRecord } from "./types.ts";
3
3
  interface BuildContentGraphOptions {
4
+ /** The banner's link target as configured (`banner.link.href`), if any. */
5
+ bannerHref?: string;
4
6
  /** Site-wide route mount point (`""` or `/seg`); invisible to the nav tree. */
5
7
  basePath?: string;
6
8
  /** The header brand link as configured (`logo.href`, default `/`). */
@@ -44,11 +44,9 @@ export interface HeadingMarkers {
44
44
  * the heading count (mid-text brackets are ordinary prose); when a marker kind
45
45
  * repeats, the last one written wins.
46
46
  *
47
- * `isRefDefined` reports whether a link-reference definition exists for a
48
- * bracket's label (`toc`, `!toc`, `#id`): a defined bracket is a CommonMark
49
- * shortcut link, not a marker — the renderer sees a resolved `<a>` element
50
- * there and strips nothing at or before it, so the parse stops the same way.
51
- * The render-time hast plugin never passes it (resolved links are already
52
- * elements by the time it runs); the raw-source scanner does.
47
+ * Callers pass the heading's trailing text node after a Markdown parse, so a
48
+ * bracket that a link-reference definition turns into a CommonMark shortcut
49
+ * link (`[toc]` with a `[toc]: …` definition) is already an element there and
50
+ * never reaches this parse.
53
51
  */
54
- export declare const parseHeadingMarkers: (text: string, isRefDefined?: (label: string) => boolean) => HeadingMarkers;
52
+ export declare const parseHeadingMarkers: (text: string) => HeadingMarkers;
@@ -51,9 +51,20 @@ declare const uiStringsObject: z.ZodObject<{
51
51
  title: z.ZodDefault<z.ZodString>;
52
52
  }, z.core.$strip>>;
53
53
  content: z.ZodPrefault<z.ZodObject<{
54
+ code: z.ZodDefault<z.ZodString>;
54
55
  copyColor: z.ZodDefault<z.ZodString>;
55
56
  copyPrompt: z.ZodDefault<z.ZodString>;
57
+ default: z.ZodDefault<z.ZodString>;
56
58
  diagramError: z.ZodDefault<z.ZodString>;
59
+ forks: z.ZodDefault<z.ZodString>;
60
+ preview: z.ZodDefault<z.ZodString>;
61
+ prop: z.ZodDefault<z.ZodString>;
62
+ selectTab: z.ZodDefault<z.ZodString>;
63
+ showMore: z.ZodDefault<z.ZodString>;
64
+ stars: z.ZodDefault<z.ZodString>;
65
+ tab: z.ZodDefault<z.ZodString>;
66
+ type: z.ZodDefault<z.ZodString>;
67
+ update: z.ZodDefault<z.ZodString>;
57
68
  }, z.core.$strip>>;
58
69
  feedback: z.ZodPrefault<z.ZodObject<{
59
70
  no: z.ZodDefault<z.ZodString>;
@@ -103,8 +114,10 @@ declare const uiStringsObject: z.ZodObject<{
103
114
  assistantHint: z.ZodDefault<z.ZodString>;
104
115
  button: z.ZodDefault<z.ZodString>;
105
116
  devOnly: z.ZodDefault<z.ZodString>;
117
+ docs: z.ZodDefault<z.ZodString>;
106
118
  error: z.ZodDefault<z.ZodString>;
107
119
  label: z.ZodDefault<z.ZodString>;
120
+ latest: z.ZodDefault<z.ZodString>;
108
121
  navigate: z.ZodDefault<z.ZodString>;
109
122
  noResults: z.ZodDefault<z.ZodString>;
110
123
  open: z.ZodDefault<z.ZodString>;
@@ -166,9 +179,20 @@ export declare const uiStringsSchema: z.ZodPrefault<z.ZodObject<{
166
179
  title: z.ZodDefault<z.ZodString>;
167
180
  }, z.core.$strip>>;
168
181
  content: z.ZodPrefault<z.ZodObject<{
182
+ code: z.ZodDefault<z.ZodString>;
169
183
  copyColor: z.ZodDefault<z.ZodString>;
170
184
  copyPrompt: z.ZodDefault<z.ZodString>;
185
+ default: z.ZodDefault<z.ZodString>;
171
186
  diagramError: z.ZodDefault<z.ZodString>;
187
+ forks: z.ZodDefault<z.ZodString>;
188
+ preview: z.ZodDefault<z.ZodString>;
189
+ prop: z.ZodDefault<z.ZodString>;
190
+ selectTab: z.ZodDefault<z.ZodString>;
191
+ showMore: z.ZodDefault<z.ZodString>;
192
+ stars: z.ZodDefault<z.ZodString>;
193
+ tab: z.ZodDefault<z.ZodString>;
194
+ type: z.ZodDefault<z.ZodString>;
195
+ update: z.ZodDefault<z.ZodString>;
172
196
  }, z.core.$strip>>;
173
197
  feedback: z.ZodPrefault<z.ZodObject<{
174
198
  no: z.ZodDefault<z.ZodString>;
@@ -218,8 +242,10 @@ export declare const uiStringsSchema: z.ZodPrefault<z.ZodObject<{
218
242
  assistantHint: z.ZodDefault<z.ZodString>;
219
243
  button: z.ZodDefault<z.ZodString>;
220
244
  devOnly: z.ZodDefault<z.ZodString>;
245
+ docs: z.ZodDefault<z.ZodString>;
221
246
  error: z.ZodDefault<z.ZodString>;
222
247
  label: z.ZodDefault<z.ZodString>;
248
+ latest: z.ZodDefault<z.ZodString>;
223
249
  navigate: z.ZodDefault<z.ZodString>;
224
250
  noResults: z.ZodDefault<z.ZodString>;
225
251
  open: z.ZodDefault<z.ZodString>;
@@ -268,6 +294,11 @@ export { UI_PACKS } from "./ui-packs/index.ts";
268
294
  * English baseline ← default-locale pack ← default-locale override ←
269
295
  * locale pack ← locale override. So a missing key falls back to the default
270
296
  * locale's translation, then to English.
297
+ *
298
+ * English has no pack because the baseline is its complete translation, so an
299
+ * English locale (`en`, `en-GB`) skips the default-locale layers: on a site
300
+ * whose default is German, English pages keep English chrome instead of
301
+ * inheriting the German strings.
271
302
  */
272
303
  export declare const resolveUIStrings: (locale: string, options: {
273
304
  defaultLocale: string;
@@ -76,12 +76,20 @@ export declare const localePlacement: (rel: string, ext: string, i18n: ResolvedI
76
76
  * (`x.en.mdx`) swaps it for the target's (`x.fr.mdx`) — same case-insensitive
77
77
  * last-dot-inside-filename logic as `localePlacement`, so both spellings of a
78
78
  * default-locale file resolve to one canonical target.
79
+ *
80
+ * Under `dir`, `folders` are the content root's existing top-level folders: one
81
+ * that names the locale in another casing (`pt-br/` for a configured `pt-BR`)
82
+ * is the locale's folder already, since {@link detectLocale} matches it case-
83
+ * insensitively. Writing beside it into a second `pt-BR/` would, on a case-
84
+ * sensitive filesystem, publish the page twice.
79
85
  */
80
- export declare const localeTargetPath: (rel: string, ext: string, locale: string, i18n: ResolvedI18nConfig) => string;
86
+ export declare const localeTargetPath: (rel: string, ext: string, locale: string, i18n: ResolvedI18nConfig, folders?: readonly string[]) => string;
81
87
  /**
82
88
  * Warn about top-level content folders that look like a locale (a code Blume
83
89
  * recognizes) but aren't declared in `i18n.locales`. Without this they're
84
90
  * silently treated as default-locale content under a `/<code>/…` route, which
85
91
  * is almost never intended — usually a translation that wasn't registered.
92
+ * A folder named after the default locale gets the same treatment (see
93
+ * {@link defaultLocaleFolderDiagnostic}).
86
94
  */
87
95
  export declare const i18nDiagnostics: (pages: PageRecord[], i18n: ResolvedI18nConfig, versions?: ResolvedVersionsConfig) => Diagnostic[];
@@ -13,6 +13,16 @@ export declare const resolveLastModifiedConfig: (value: false | "git" | "frontma
13
13
  * newest-first, the first date seen for a path wins. Blank lines are ignored.
14
14
  */
15
15
  export declare const parseGitLog: (output: string) => Map<string, string>;
16
+ /**
17
+ * `path` with every symlink resolved, the spelling git prints paths in: a
18
+ * project opened through a link (`/tmp/site` on macOS, where `/tmp` links to
19
+ * `/private/tmp`) gets `/private/tmp/site` from `rev-parse --show-toplevel`,
20
+ * so the project's own spelling would compare as outside the repository and
21
+ * every page would go undated. The native realpath also expands a Windows
22
+ * 8.3 short name (`RUNNER~1`), which git does too. A path that doesn't exist
23
+ * stays as written.
24
+ */
25
+ export declare const realPath: (path: string) => string;
16
26
  /**
17
27
  * The toplevel of the repository containing `root`, or null when git is
18
28
  * unavailable or the project isn't a repo. Callers use it to decide which
@@ -35,7 +35,9 @@ export declare const resolveRelativeHref: (href: string, from: RelativeLinkBase,
35
35
  * Whether a content file is its folder's index, from its name as written on
36
36
  * disk: `index.md(x)` after an ordering prefix, optionally carrying one of
37
37
  * `localeTokens` before the extension (`index.fr.mdx` under the `dot` locale
38
- * parser, `index.$.mdx` for a file shared by every locale).
38
+ * parser, `index.$.mdx` for a file shared by every locale). The `index` itself
39
+ * is case-sensitive, as route mapping reads it: `Index.md` is a page named
40
+ * `Index`, not its folder's index.
39
41
  */
40
42
  export declare const isIndexFileName: (name: string, localeTokens?: readonly string[]) => boolean;
41
43
  /** Where content files publish, for resolving file links (`./setup.mdx`). */
@@ -5,3 +5,13 @@
5
5
  * which is what makes dev-server regeneration reflect config/meta changes.
6
6
  */
7
7
  export declare const createModuleLoader: () => ((file: string) => Promise<unknown>);
8
+ /**
9
+ * Create a loader for a module whose default export is its whole value
10
+ * (`blume.config.ts`). Unlike {@link createModuleLoader}, it never falls back
11
+ * to the module's namespace: a module with no default export, or one that
12
+ * exports `null`/`undefined`, resolves to `undefined` so the caller can say
13
+ * so, instead of validating `{}` (a bare `defineConfig({…})` call) or
14
+ * `{ config }` (a named export). jiti's default interop is off because it
15
+ * throws on `export default null`.
16
+ */
17
+ export declare const createDefaultExportLoader: typeof createModuleLoader;
@@ -33,6 +33,11 @@ export interface LocalizeLinkOptions {
33
33
  /** Every served route, base-prefixed like `path` (no `deployment.base`). */
34
34
  routes: RouteSet;
35
35
  }
36
+ /**
37
+ * Whether `routes` serves `route` (base-prefixed, fragment-less). Routes are
38
+ * stored decoded, so a browser-copied `/caf%C3%A9` still finds its page.
39
+ */
40
+ export declare const servesRoute: (routes: RouteSet, route: string) => boolean;
36
41
  /**
37
42
  * Move a base-prefixed, fragment-less internal path into `locale` when that
38
43
  * route is served, else return it unchanged. Idempotent: a path already under
@@ -44,9 +49,14 @@ export interface LocalizeHrefOptions extends LocalizeLinkOptions {
44
49
  deployBase: string;
45
50
  }
46
51
  /**
47
- * Localize a rendered `href`: external URLs, relative paths, bare fragments, and
48
- * asset links pass through; a root-relative page link keeps its `?query` and
52
+ * Localize a rendered `href`: external URLs, relative paths, and bare
53
+ * fragments pass through; a root-relative page link keeps its `?query` and
49
54
  * `#fragment` and its `deployment.base` layer around the localized path.
55
+ *
56
+ * Asset links (`/logo.png`, a raw `.md` twin) pass through too, because no
57
+ * page is served at their localized path — the same served-route test the
58
+ * link checker applies. A file extension alone doesn't mark an asset: a
59
+ * dotted page route (`/releases/v1.2`) is localized like any other page.
50
60
  */
51
61
  export declare const localizeHref: (href: string, options: LocalizeHrefOptions) => string;
52
62
  /**
@@ -2,11 +2,23 @@ import type { FolderMeta } from "./schema.ts";
2
2
  import type { Diagnostic } from "./types.ts";
3
3
  /** A filesystem content source to scan for folder meta: its on-disk root and
4
4
  * optional route prefix. The prefix is folded into every key so meta lines up
5
- * with the sidebar group path, which carries the same prefix. */
5
+ * with the sidebar group path, which carries the same prefix. `include` and
6
+ * `exclude` are the source's content globs, which scope the scan to the
7
+ * folders the source reads. */
6
8
  export interface FolderMetaSource {
7
9
  root: string;
8
10
  prefix?: string;
11
+ include?: readonly string[];
12
+ exclude?: readonly string[];
9
13
  }
14
+ /**
15
+ * The folder-meta files a filesystem source contributes: `patterns` (every
16
+ * meta module name, shared `meta.$.*` included, by default) under the source's
17
+ * root, minus its `exclude` globs, dependencies, and build output, and only in
18
+ * folders its `include` globs reach. `blume translate` finds the meta files it
19
+ * translates through this too, so it covers exactly the ones the scan reads.
20
+ */
21
+ export declare const findFolderMetaFiles: (source: FolderMetaSource, patterns?: readonly string[]) => Promise<string[]>;
10
22
  /**
11
23
  * Discover `meta.{ts,js,mjs}` files across the given filesystem sources. Keys are
12
24
  * the source's route prefix joined with the directory relative to that source's
@@ -1,3 +1,4 @@
1
+ import type { SidebarItemConfig } from "./schema.ts";
1
2
  import type { Diagnostic, Navigation, PageRecord } from "./types.ts";
2
3
  /** Warn about icon names that aren't in Blume's set (skipping image/SVG icons). */
3
4
  export declare const validateNavIcons: (navigation: Navigation) => Diagnostic[];
@@ -16,6 +17,15 @@ export declare const validateSearchPopularIcons: (popular: {
16
17
  * not in the content-only graph build.
17
18
  */
18
19
  export declare const validateNavTargets: (navigation: Navigation, routes: Set<string>) => Diagnostic[];
20
+ /**
21
+ * Warn about explicit `navigation.sidebar` items that can't render as written,
22
+ * instead of dropping them without a word: a page ref that matches no page
23
+ * (left out of the sidebar), a `root` that matches no page (its link leads
24
+ * nowhere), and an item with no page, `href`, `root`, or `items` (left out).
25
+ * `resolves` answers whether a normalized ref (`/guides`) names a page — in
26
+ * any locale — or a route served outside the content tree.
27
+ */
28
+ export declare const validateSidebarItems: (items: SidebarItemConfig[], resolves: (route: string) => boolean) => Diagnostic[];
19
29
  /**
20
30
  * Structural navigation diagnostics that need only the built navigation +
21
31
  * content pages: duplicate sidebar labels at a level, and hidden pages that
@@ -18,6 +18,29 @@ export declare const isUnderPath: (route: string, base: string) => boolean;
18
18
  * sidebar or highlight the wrong tab over it.
19
19
  */
20
20
  export declare const isRootTab: (tab: NavTab, root: string) => boolean;
21
+ /**
22
+ * Capitalize one word of a slug-like name for display, spelling the acronyms
23
+ * and brand casings in {@link WORD_FORMS} their own way (`api` → "API").
24
+ * Shared with page titles derived from file names, so a page and a folder
25
+ * named alike read alike.
26
+ */
27
+ export declare const titleWord: (word: string) => string;
28
+ /**
29
+ * An explicit-sidebar ref (`"guides/"`, `"/guides/index"`, `"index"`) in the
30
+ * slashless route form pages are keyed by (`/guides`, `/`).
31
+ */
32
+ export declare const normalizeRef: (ref: string) => string;
33
+ /** An explicit-config sidebar item written as a bare page-ref string. */
34
+ export declare const isPageRef: (item: SidebarItemConfig) => item is string;
35
+ /**
36
+ * Pages keyed the way explicit-sidebar refs look them up: by the
37
+ * locale-agnostic `translationKey` under i18n (`byLogical`), so one authored
38
+ * sidebar maps onto every locale's pages, else by route. Refs are authored as
39
+ * if mounted at root while `page.route` carries the base, so each page is also
40
+ * aliased under its base-less route (the `translationKey` is base-less
41
+ * already).
42
+ */
43
+ export declare const pagesByRef: (pages: PageRecord[], basePath: string, byLogical: boolean) => Map<string, PageRecord>;
21
44
  /** Build the complete navigation model from pages, meta, and config. */
22
45
  export declare const buildNavigation: (pages: PageRecord[], options: {
23
46
  /** Plain links in the header, left of the icon buttons. */
@@ -39,6 +62,13 @@ export declare const buildNavigation: (pages: PageRecord[], options: {
39
62
  * group path, e.g. `fr`, `v1.0`, or `v1.0/fr`.
40
63
  */
41
64
  metaPrefix?: string;
65
+ /**
66
+ * Folder-meta lookup prefix of the i18n fallback locale, whose untranslated
67
+ * pages pad this tree (`""` for the default locale of the current
68
+ * version). A group with no meta of this locale's mirrors the fallback
69
+ * locale's. Unset for the fallback locale itself, and without i18n.
70
+ */
71
+ fallbackMetaPrefix?: string;
42
72
  /**
43
73
  * Prefix for shared `meta.$.*` lookups — the version dir inside a
44
74
  * snapshot (`v1.0`), since shared meta is locale-agnostic but still
@@ -60,6 +90,14 @@ export declare const buildNavigation: (pages: PageRecord[], options: {
60
90
  * scoping.
61
91
  */
62
92
  localizedRoot?: string;
93
+ /**
94
+ * The root of the space tab paths are written in, before `basePath`: the
95
+ * current docs' localized root (`"/"`, `/fr`). Defaults to
96
+ * `localizedRoot`; an archived version tree passes it because its own
97
+ * root is versionized (`/fr/v1.0`) while tab paths are not, so a tab's
98
+ * section can be found under the version.
99
+ */
100
+ tabRoot?: string;
63
101
  /**
64
102
  * Sink for diagnostics produced while building the tree (duplicate sidebar
65
103
  * `order` values, index-page title/folder-meta-title mismatches). Pushed
@@ -0,0 +1,4 @@
1
+ /** The digits of `name`'s ordering prefix (`01` of `01-intro`), if it has one. */
2
+ export declare const orderingPrefix: (name: string) => string | undefined;
3
+ /** `name` without its ordering prefix (`01-intro` -> `intro`). */
4
+ export declare const stripOrderingPrefix: (name: string) => string;
@@ -21,6 +21,8 @@ export declare const unsafeLinkSpans: (tree: Root) => UnsafeLinkSpan[];
21
21
  /**
22
22
  * Markdown with every unsafe link reduced to its label text and every unsafe
23
23
  * link definition removed. Everything else — safe links, raw HTML, code —
24
- * passes through as written.
24
+ * passes through as written. The Markdown is read as GitHub-flavored, the way
25
+ * the site renders it: a link inside a footnote definition or a table cell is
26
+ * only a link to a GFM parser.
25
27
  */
26
28
  export declare const neutralizeUnsafeLinks: (markdown: string) => string;
@@ -687,15 +687,7 @@ declare const contentSignalsSchema: z.ZodPipe<z.ZodUnion<readonly [z.ZodBoolean,
687
687
  aiTrain: boolean;
688
688
  search: boolean;
689
689
  }>>;
690
- /**
691
- * How the "last updated" stamp and the changelog timeline render their dates —
692
- * a curated pass-through to `Intl.DateTimeFormat`, shared by both surfaces so
693
- * they read alike. Defaults to `{ dateStyle: "long" }`. Both stamps format in
694
- * UTC unless a `timeZone` is given, so a date reads the same regardless of the
695
- * build machine's zone. `dateStyle` is a preset that can't be combined with the
696
- * individual component fields (`year`, `month`, …), matching `Intl`'s own rule.
697
- */
698
- declare const dateFormatConfigSchema: z.ZodObject<{
690
+ declare const dateFormatConfigSchema: z.ZodPipe<z.ZodObject<{
699
691
  calendar: z.ZodOptional<z.ZodString>;
700
692
  dateStyle: z.ZodOptional<z.ZodEnum<{
701
693
  medium: "medium";
@@ -730,7 +722,27 @@ declare const dateFormatConfigSchema: z.ZodObject<{
730
722
  numeric: "numeric";
731
723
  "2-digit": "2-digit";
732
724
  }>>;
733
- }, z.core.$strict>;
725
+ }, z.core.$strict>, z.ZodTransform<{
726
+ calendar?: string | undefined;
727
+ dateStyle?: "medium" | "full" | "long" | "short" | undefined;
728
+ day?: "numeric" | "2-digit" | undefined;
729
+ era?: "long" | "short" | "narrow" | undefined;
730
+ month?: "long" | "short" | "numeric" | "2-digit" | "narrow" | undefined;
731
+ numberingSystem?: string | undefined;
732
+ timeZone?: string | undefined;
733
+ weekday?: "long" | "short" | "narrow" | undefined;
734
+ year?: "numeric" | "2-digit" | undefined;
735
+ }, {
736
+ calendar?: string | undefined;
737
+ dateStyle?: "medium" | "full" | "long" | "short" | undefined;
738
+ day?: "numeric" | "2-digit" | undefined;
739
+ era?: "long" | "short" | "narrow" | undefined;
740
+ month?: "long" | "short" | "numeric" | "2-digit" | "narrow" | undefined;
741
+ numberingSystem?: string | undefined;
742
+ timeZone?: string | undefined;
743
+ weekday?: "long" | "short" | "narrow" | undefined;
744
+ year?: "numeric" | "2-digit" | undefined;
745
+ }>>;
734
746
  export declare const blumeConfigSchema: z.ZodObject<{
735
747
  agents: z.ZodPrefault<z.ZodObject<{
736
748
  agentReadability: z.ZodDefault<z.ZodBoolean>;
@@ -931,6 +943,13 @@ export declare const blumeConfigSchema: z.ZodObject<{
931
943
  }, z.core.$catchall<z.ZodJSONSchema>>;
932
944
  requiredSecrets: z.ZodArray<z.ZodString>;
933
945
  runtimeDeps: z.ZodArray<z.ZodString>;
946
+ }, z.core.$strict>, z.ZodObject<{
947
+ kind: z.ZodLiteral<"databuddy">;
948
+ options: z.ZodObject<{
949
+ clientId: z.ZodString;
950
+ }, z.core.$catchall<z.ZodString>>;
951
+ requiredSecrets: z.ZodArray<z.ZodString>;
952
+ runtimeDeps: z.ZodArray<z.ZodString>;
934
953
  }, z.core.$strict>, z.ZodObject<{
935
954
  kind: z.ZodLiteral<"fathom">;
936
955
  options: z.ZodObject<{
@@ -995,6 +1014,13 @@ export declare const blumeConfigSchema: z.ZodObject<{
995
1014
  }, z.core.$catchall<z.ZodJSONSchema>>;
996
1015
  requiredSecrets: z.ZodArray<z.ZodString>;
997
1016
  runtimeDeps: z.ZodArray<z.ZodString>;
1017
+ }, z.core.$strict>, z.ZodObject<{
1018
+ kind: z.ZodLiteral<"one-dollar-stats">;
1019
+ options: z.ZodObject<{
1020
+ hostname: z.ZodOptional<z.ZodString>;
1021
+ }, z.core.$catchall<z.ZodString>>;
1022
+ requiredSecrets: z.ZodArray<z.ZodString>;
1023
+ runtimeDeps: z.ZodArray<z.ZodString>;
998
1024
  }, z.core.$strict>, z.ZodObject<{
999
1025
  kind: z.ZodLiteral<"pirsch">;
1000
1026
  options: z.ZodObject<{
@@ -2164,7 +2190,7 @@ export declare const blumeConfigSchema: z.ZodObject<{
2164
2190
  runtimeDeps: string[];
2165
2191
  })[] | undefined;
2166
2192
  }>>>;
2167
- dateFormat: z.ZodDefault<z.ZodObject<{
2193
+ dateFormat: z.ZodDefault<z.ZodPipe<z.ZodObject<{
2168
2194
  calendar: z.ZodOptional<z.ZodString>;
2169
2195
  dateStyle: z.ZodOptional<z.ZodEnum<{
2170
2196
  medium: "medium";
@@ -2199,7 +2225,27 @@ export declare const blumeConfigSchema: z.ZodObject<{
2199
2225
  numeric: "numeric";
2200
2226
  "2-digit": "2-digit";
2201
2227
  }>>;
2202
- }, z.core.$strict>>;
2228
+ }, z.core.$strict>, z.ZodTransform<{
2229
+ calendar?: string | undefined;
2230
+ dateStyle?: "medium" | "full" | "long" | "short" | undefined;
2231
+ day?: "numeric" | "2-digit" | undefined;
2232
+ era?: "long" | "short" | "narrow" | undefined;
2233
+ month?: "long" | "short" | "numeric" | "2-digit" | "narrow" | undefined;
2234
+ numberingSystem?: string | undefined;
2235
+ timeZone?: string | undefined;
2236
+ weekday?: "long" | "short" | "narrow" | undefined;
2237
+ year?: "numeric" | "2-digit" | undefined;
2238
+ }, {
2239
+ calendar?: string | undefined;
2240
+ dateStyle?: "medium" | "full" | "long" | "short" | undefined;
2241
+ day?: "numeric" | "2-digit" | undefined;
2242
+ era?: "long" | "short" | "narrow" | undefined;
2243
+ month?: "long" | "short" | "numeric" | "2-digit" | "narrow" | undefined;
2244
+ numberingSystem?: string | undefined;
2245
+ timeZone?: string | undefined;
2246
+ weekday?: "long" | "short" | "narrow" | undefined;
2247
+ year?: "numeric" | "2-digit" | undefined;
2248
+ }>>>;
2203
2249
  deployment: z.ZodPrefault<z.ZodPipe<z.ZodDiscriminatedUnion<[z.ZodObject<{
2204
2250
  kind: z.ZodLiteral<"cloudflare">;
2205
2251
  options: z.ZodObject<{
@@ -2441,7 +2487,7 @@ export declare const blumeConfigSchema: z.ZodObject<{
2441
2487
  tag: z.ZodOptional<z.ZodString>;
2442
2488
  }, z.core.$strict>>>;
2443
2489
  label: z.ZodUnion<readonly [z.ZodString, z.ZodRecord<z.ZodString, z.ZodString>]>;
2444
- path: z.ZodString;
2490
+ path: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
2445
2491
  }, z.core.$strict>>>;
2446
2492
  }, z.core.$strict>>;
2447
2493
  react: z.ZodPrefault<z.ZodObject<{
@@ -20,6 +20,11 @@ export interface GithubReleasesSourceOptions {
20
20
  prereleases?: boolean;
21
21
  /** Repository name. */
22
22
  repo: string;
23
+ /**
24
+ * The site's own URL (`deployment.site`). A link in the notes back to it
25
+ * becomes root-relative, the way a page links to another page.
26
+ */
27
+ site?: string;
23
28
  }
24
29
  /**
25
30
  * GitHub Releases content source. Pulls a repo's releases from the REST API and