@lupinum/ginko-content 0.4.0-rc.1 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (502) hide show
  1. package/CHANGELOG.md +75 -0
  2. package/LICENSE +1 -2
  3. package/README.md +28 -153
  4. package/dist/index.d.mts +74 -0
  5. package/dist/index.d.ts +74 -0
  6. package/dist/index.mjs +822 -0
  7. package/package.json +33 -165
  8. package/dist/cli.d.mts +0 -1
  9. package/dist/cli.mjs +0 -939
  10. package/dist/cms-contract/asset-bytes.d.ts +0 -10
  11. package/dist/cms-contract/asset-bytes.js +0 -266
  12. package/dist/cms-contract/build.d.ts +0 -15
  13. package/dist/cms-contract/build.js +0 -432
  14. package/dist/cms-contract/hash.d.ts +0 -16
  15. package/dist/cms-contract/hash.js +0 -248
  16. package/dist/cms-contract/index.d.ts +0 -33
  17. package/dist/cms-contract/index.js +0 -62
  18. package/dist/cms-contract/limits.d.ts +0 -14
  19. package/dist/cms-contract/limits.js +0 -13
  20. package/dist/cms-contract/mdc.d.ts +0 -28
  21. package/dist/cms-contract/mdc.js +0 -54
  22. package/dist/cms-contract/path.d.ts +0 -10
  23. package/dist/cms-contract/path.js +0 -17
  24. package/dist/cms-contract/provider-wire.d.ts +0 -1074
  25. package/dist/cms-contract/provider-wire.js +0 -303
  26. package/dist/cms-contract/render-policy.d.ts +0 -46
  27. package/dist/cms-contract/render-policy.js +0 -402
  28. package/dist/cms-contract/schema.d.ts +0 -18
  29. package/dist/cms-contract/schema.js +0 -15
  30. package/dist/cms-contract/types.d.ts +0 -95
  31. package/dist/cms-contract/types.js +0 -0
  32. package/dist/cms-contract/validate.d.ts +0 -3
  33. package/dist/cms-contract/validate.js +0 -283
  34. package/dist/config.d.mts +0 -3
  35. package/dist/config.mjs +0 -3
  36. package/dist/core/cache-hints.d.ts +0 -11
  37. package/dist/core/cache-hints.js +0 -55
  38. package/dist/core/cache.d.ts +0 -29
  39. package/dist/core/cache.js +0 -0
  40. package/dist/core/content/collection.d.ts +0 -3
  41. package/dist/core/content/collection.js +0 -52
  42. package/dist/core/content/document.d.ts +0 -16
  43. package/dist/core/content/document.js +0 -2
  44. package/dist/core/content/graph.d.ts +0 -150
  45. package/dist/core/content/graph.js +0 -232
  46. package/dist/core/content/ignore.d.ts +0 -5
  47. package/dist/core/content/ignore.js +0 -10
  48. package/dist/core/content/locale.d.ts +0 -72
  49. package/dist/core/content/locale.js +0 -97
  50. package/dist/core/content/path.d.ts +0 -69
  51. package/dist/core/content/path.js +0 -190
  52. package/dist/core/content/slug.d.ts +0 -4
  53. package/dist/core/content/slug.js +0 -41
  54. package/dist/core/content/snapshot.d.ts +0 -35
  55. package/dist/core/content/snapshot.js +0 -46
  56. package/dist/core/content/sources.d.ts +0 -2
  57. package/dist/core/content/sources.js +0 -6
  58. package/dist/core/content/structural.d.ts +0 -6
  59. package/dist/core/content/structural.js +0 -1
  60. package/dist/core/data-source-error.d.ts +0 -5
  61. package/dist/core/data-source-error.js +0 -10
  62. package/dist/core/errors.d.ts +0 -15
  63. package/dist/core/errors.js +0 -14
  64. package/dist/core/json-value.d.ts +0 -41
  65. package/dist/core/json-value.js +0 -99
  66. package/dist/core/markdown/builtin-render-contracts.d.ts +0 -35
  67. package/dist/core/markdown/builtin-render-contracts.js +0 -25
  68. package/dist/core/markdown/html-tags.d.ts +0 -1
  69. package/dist/core/markdown/html-tags.js +0 -119
  70. package/dist/core/markdown/normalize-comark.d.ts +0 -14
  71. package/dist/core/markdown/normalize-comark.js +0 -67
  72. package/dist/core/markdown/parse-comark.d.ts +0 -7
  73. package/dist/core/markdown/parse-comark.js +0 -29
  74. package/dist/core/markdown/tree.d.ts +0 -9
  75. package/dist/core/markdown/tree.js +0 -47
  76. package/dist/core/provider-errors.d.ts +0 -10
  77. package/dist/core/provider-errors.js +0 -29
  78. package/dist/core/provider-result.d.ts +0 -11
  79. package/dist/core/provider-result.js +0 -7
  80. package/dist/core/provider-route-record.d.ts +0 -18
  81. package/dist/core/provider-route-record.js +0 -106
  82. package/dist/core/query/execute.d.ts +0 -45
  83. package/dist/core/query/execute.js +0 -377
  84. package/dist/core/query/filter.d.ts +0 -41
  85. package/dist/core/query/filter.js +0 -210
  86. package/dist/core/query/limits.d.ts +0 -10
  87. package/dist/core/query/limits.js +0 -27
  88. package/dist/core/query/lower.d.ts +0 -20
  89. package/dist/core/query/lower.js +0 -467
  90. package/dist/core/query/operators.d.ts +0 -37
  91. package/dist/core/query/operators.js +0 -155
  92. package/dist/core/query/params.d.ts +0 -12
  93. package/dist/core/query/params.js +0 -101
  94. package/dist/core/query/plan.d.ts +0 -170
  95. package/dist/core/query/plan.js +0 -7
  96. package/dist/core/references/resolve.d.ts +0 -50
  97. package/dist/core/references/resolve.js +0 -188
  98. package/dist/core/references/schema.d.ts +0 -11
  99. package/dist/core/references/schema.js +0 -91
  100. package/dist/core/result.d.ts +0 -27
  101. package/dist/core/result.js +0 -2
  102. package/dist/core/runtime-diagnostics.d.ts +0 -7
  103. package/dist/core/runtime-diagnostics.js +0 -9
  104. package/dist/core/visibility.d.ts +0 -64
  105. package/dist/core/visibility.js +0 -18
  106. package/dist/features/agent/agent-markdown.d.ts +0 -116
  107. package/dist/features/agent/agent-markdown.js +0 -148
  108. package/dist/features/agent/agent-paths.d.ts +0 -5
  109. package/dist/features/agent/agent-paths.js +0 -37
  110. package/dist/features/agent/walker.d.ts +0 -10
  111. package/dist/features/agent/walker.js +0 -198
  112. package/dist/features/collections/resolve.d.ts +0 -28
  113. package/dist/features/collections/resolve.js +0 -23
  114. package/dist/features/localization/config.d.ts +0 -26
  115. package/dist/features/localization/config.js +0 -30
  116. package/dist/features/localization/links.d.ts +0 -1
  117. package/dist/features/localization/links.js +0 -69
  118. package/dist/features/localization/locale-policy.d.ts +0 -107
  119. package/dist/features/localization/locale-policy.js +0 -184
  120. package/dist/features/localization/path.d.ts +0 -32
  121. package/dist/features/localization/path.js +0 -79
  122. package/dist/features/localization/reference-path.d.ts +0 -7
  123. package/dist/features/localization/reference-path.js +0 -10
  124. package/dist/features/localization/results.d.ts +0 -40
  125. package/dist/features/localization/results.js +0 -64
  126. package/dist/features/localization/route-projector.d.ts +0 -155
  127. package/dist/features/localization/route-projector.js +0 -157
  128. package/dist/features/localization/translated-slugs.d.ts +0 -11
  129. package/dist/features/localization/translated-slugs.js +0 -80
  130. package/dist/features/navigation/build.d.ts +0 -33
  131. package/dist/features/navigation/build.js +0 -122
  132. package/dist/features/navigation/canonical.d.ts +0 -26
  133. package/dist/features/navigation/canonical.js +0 -114
  134. package/dist/features/navigation/diagnostics.d.ts +0 -11
  135. package/dist/features/navigation/diagnostics.js +0 -52
  136. package/dist/features/navigation/query.d.ts +0 -24
  137. package/dist/features/navigation/query.js +0 -30
  138. package/dist/features/navigation/resolve.d.ts +0 -34
  139. package/dist/features/navigation/resolve.js +0 -101
  140. package/dist/features/navigation/tree.d.ts +0 -5
  141. package/dist/features/navigation/tree.js +0 -32
  142. package/dist/features/query/backlinks.d.ts +0 -8
  143. package/dist/features/query/backlinks.js +0 -87
  144. package/dist/features/query/context.d.ts +0 -30
  145. package/dist/features/query/context.js +0 -0
  146. package/dist/features/query/diagnostics.d.ts +0 -4
  147. package/dist/features/query/diagnostics.js +0 -22
  148. package/dist/features/query/documents.d.ts +0 -6
  149. package/dist/features/query/documents.js +0 -93
  150. package/dist/features/query/errors.d.ts +0 -1
  151. package/dist/features/query/errors.js +0 -4
  152. package/dist/features/query/handles.d.ts +0 -2
  153. package/dist/features/query/handles.js +0 -7
  154. package/dist/features/query/locale-options.d.ts +0 -5
  155. package/dist/features/query/locale-options.js +0 -15
  156. package/dist/features/query/localized-docs.d.ts +0 -6
  157. package/dist/features/query/localized-docs.js +0 -14
  158. package/dist/features/query/navigation.d.ts +0 -31
  159. package/dist/features/query/navigation.js +0 -77
  160. package/dist/features/query/pagination.d.ts +0 -13
  161. package/dist/features/query/pagination.js +0 -132
  162. package/dist/features/query/populate.d.ts +0 -10
  163. package/dist/features/query/populate.js +0 -161
  164. package/dist/features/query/query-plan-boundary.d.ts +0 -9
  165. package/dist/features/query/query-plan-boundary.js +0 -137
  166. package/dist/features/query/responses.d.ts +0 -42
  167. package/dist/features/query/responses.js +0 -48
  168. package/dist/features/query/routes.d.ts +0 -26
  169. package/dist/features/query/routes.js +0 -39
  170. package/dist/features/query/unified.d.ts +0 -69
  171. package/dist/features/query/unified.js +0 -28
  172. package/dist/features/search/navigation.d.ts +0 -6
  173. package/dist/features/search/navigation.js +0 -20
  174. package/dist/features/search/options.d.ts +0 -4
  175. package/dist/features/search/options.js +0 -30
  176. package/dist/features/search/records.d.ts +0 -9
  177. package/dist/features/search/records.js +0 -18
  178. package/dist/features/search/sections.d.ts +0 -21
  179. package/dist/features/search/sections.js +0 -94
  180. package/dist/features/search/snippet.d.ts +0 -6
  181. package/dist/features/search/snippet.js +0 -52
  182. package/dist/features/sitemap/counts.d.ts +0 -29
  183. package/dist/features/sitemap/counts.js +0 -50
  184. package/dist/features/sitemap/metadata.d.ts +0 -16
  185. package/dist/features/sitemap/metadata.js +0 -47
  186. package/dist/features/sitemap/query.d.ts +0 -29
  187. package/dist/features/sitemap/query.js +0 -34
  188. package/dist/features/validation/links.d.ts +0 -16
  189. package/dist/features/validation/links.js +0 -171
  190. package/dist/features/validation/report.d.ts +0 -14
  191. package/dist/features/validation/report.js +0 -10
  192. package/dist/integrations/nitro/build.d.ts +0 -40
  193. package/dist/integrations/nitro/build.js +0 -216
  194. package/dist/integrations/nitro/context.d.ts +0 -59
  195. package/dist/integrations/nitro/context.js +0 -28
  196. package/dist/integrations/nitro/ingest.d.ts +0 -18
  197. package/dist/integrations/nitro/ingest.js +0 -125
  198. package/dist/integrations/nitro/preview.d.ts +0 -5
  199. package/dist/integrations/nitro/preview.js +0 -38
  200. package/dist/integrations/nitro/runtime-config.d.ts +0 -1
  201. package/dist/integrations/nitro/runtime-config.js +0 -4
  202. package/dist/integrations/nitro/storage.d.ts +0 -10
  203. package/dist/integrations/nitro/storage.js +0 -102
  204. package/dist/integrations/vue/content-components.d.ts +0 -24
  205. package/dist/integrations/vue/content-components.js +0 -67
  206. package/dist/module.d.mts +0 -1116
  207. package/dist/module.json +0 -12
  208. package/dist/module.mjs +0 -2150
  209. package/dist/parsers/csv.d.ts +0 -2
  210. package/dist/parsers/csv.js +0 -40
  211. package/dist/parsers/from-csv.d.ts +0 -20
  212. package/dist/parsers/from-csv.js +0 -85
  213. package/dist/parsers/index.d.ts +0 -7
  214. package/dist/parsers/index.js +0 -50
  215. package/dist/parsers/json.d.ts +0 -2
  216. package/dist/parsers/json.js +0 -31
  217. package/dist/parsers/markdown-plugin-options.d.ts +0 -1
  218. package/dist/parsers/markdown-plugin-options.js +0 -8
  219. package/dist/parsers/markdown-plugins.d.ts +0 -5
  220. package/dist/parsers/markdown-plugins.js +0 -91
  221. package/dist/parsers/markdown.d.ts +0 -6
  222. package/dist/parsers/markdown.js +0 -83
  223. package/dist/parsers/path-meta.d.ts +0 -4
  224. package/dist/parsers/path-meta.js +0 -49
  225. package/dist/parsers/reserved.d.ts +0 -14
  226. package/dist/parsers/reserved.js +0 -35
  227. package/dist/parsers/utils.d.ts +0 -2
  228. package/dist/parsers/utils.js +0 -3
  229. package/dist/parsers/yaml.d.ts +0 -2
  230. package/dist/parsers/yaml.js +0 -36
  231. package/dist/portability/assets.d.ts +0 -17
  232. package/dist/portability/assets.js +0 -205
  233. package/dist/portability/documents.d.ts +0 -6
  234. package/dist/portability/documents.js +0 -307
  235. package/dist/portability/errors.d.ts +0 -26
  236. package/dist/portability/errors.js +0 -22
  237. package/dist/portability/index.d.ts +0 -13
  238. package/dist/portability/index.js +0 -32
  239. package/dist/portability/json.d.ts +0 -2
  240. package/dist/portability/json.js +0 -102
  241. package/dist/portability/manifest.d.ts +0 -16
  242. package/dist/portability/manifest.js +0 -72
  243. package/dist/portability/mdc.d.ts +0 -31
  244. package/dist/portability/mdc.js +0 -53
  245. package/dist/portability/model.d.ts +0 -70
  246. package/dist/portability/model.js +0 -0
  247. package/dist/portability/references.d.ts +0 -4
  248. package/dist/portability/references.js +0 -61
  249. package/dist/portability/segments.d.ts +0 -2
  250. package/dist/portability/segments.js +0 -45
  251. package/dist/portability/semantic-equality.d.ts +0 -3
  252. package/dist/portability/semantic-equality.js +0 -12
  253. package/dist/portability/yaml.d.ts +0 -3
  254. package/dist/portability/yaml.js +0 -53
  255. package/dist/portability-node/index.d.ts +0 -3
  256. package/dist/portability-node/index.js +0 -9
  257. package/dist/portability-node/read-directory.d.ts +0 -23
  258. package/dist/portability-node/read-directory.js +0 -320
  259. package/dist/portability-node/safe-path.d.ts +0 -3
  260. package/dist/portability-node/safe-path.js +0 -29
  261. package/dist/portability-node/streams.d.ts +0 -2
  262. package/dist/portability-node/streams.js +0 -26
  263. package/dist/portability-node/write-directory.d.ts +0 -11
  264. package/dist/portability-node/write-directory.js +0 -92
  265. package/dist/public/agent-paths.d.ts +0 -2
  266. package/dist/public/agent-paths.js +0 -5
  267. package/dist/public/agent-registry.d.ts +0 -4
  268. package/dist/public/agent-registry.js +0 -18
  269. package/dist/public/agent.d.ts +0 -16
  270. package/dist/public/agent.js +0 -26
  271. package/dist/public/client.d.ts +0 -23
  272. package/dist/public/client.js +0 -15
  273. package/dist/public/data-source.d.ts +0 -105
  274. package/dist/public/data-source.js +0 -19
  275. package/dist/public/navigation.d.ts +0 -7
  276. package/dist/public/navigation.js +0 -8
  277. package/dist/public/provider-binder.d.ts +0 -7
  278. package/dist/public/provider-binder.js +0 -356
  279. package/dist/public/provider-contract.d.ts +0 -96
  280. package/dist/public/provider-contract.js +0 -8
  281. package/dist/public/provider-document.d.ts +0 -46
  282. package/dist/public/provider-document.js +0 -109
  283. package/dist/public/provider-errors.d.ts +0 -5
  284. package/dist/public/provider-errors.js +0 -20
  285. package/dist/public/provider-query.d.ts +0 -104
  286. package/dist/public/provider-query.js +0 -48
  287. package/dist/public/provider.d.ts +0 -11
  288. package/dist/public/provider.js +0 -5
  289. package/dist/public/server.d.ts +0 -16
  290. package/dist/public/server.js +0 -24
  291. package/dist/runtime/app/components/ContentRenderer.d.vue.ts +0 -53
  292. package/dist/runtime/app/components/ContentRenderer.vue +0 -85
  293. package/dist/runtime/app/components/ContentRenderer.vue.d.ts +0 -53
  294. package/dist/runtime/app/components/ContentRendererInline.d.vue.ts +0 -50
  295. package/dist/runtime/app/components/ContentRendererInline.vue +0 -90
  296. package/dist/runtime/app/components/ContentRendererInline.vue.d.ts +0 -50
  297. package/dist/runtime/app/components/Prose/ProseCode.d.vue.ts +0 -61
  298. package/dist/runtime/app/components/Prose/ProseCode.vue +0 -32
  299. package/dist/runtime/app/components/Prose/ProseCode.vue.d.ts +0 -61
  300. package/dist/runtime/app/components/Prose/ProseCodeInline.d.vue.ts +0 -13
  301. package/dist/runtime/app/components/Prose/ProseCodeInline.vue +0 -3
  302. package/dist/runtime/app/components/Prose/ProseCodeInline.vue.d.ts +0 -13
  303. package/dist/runtime/app/components/Prose/ProseImg.d.vue.ts +0 -59
  304. package/dist/runtime/app/components/Prose/ProseImg.vue +0 -59
  305. package/dist/runtime/app/components/Prose/ProseImg.vue.d.ts +0 -59
  306. package/dist/runtime/app/components/Prose/ProsePre.d.vue.ts +0 -79
  307. package/dist/runtime/app/components/Prose/ProsePre.vue +0 -42
  308. package/dist/runtime/app/components/Prose/ProsePre.vue.d.ts +0 -79
  309. package/dist/runtime/app/components/internal/ContentRendererMarkdown.d.vue.ts +0 -68
  310. package/dist/runtime/app/components/internal/ContentRendererMarkdown.vue +0 -127
  311. package/dist/runtime/app/components/internal/ContentRendererMarkdown.vue.d.ts +0 -68
  312. package/dist/runtime/app/components/internal/MarkdownRenderer.d.ts +0 -113
  313. package/dist/runtime/app/components/internal/MarkdownRenderer.js +0 -210
  314. package/dist/runtime/app/composables/content-i18n.d.ts +0 -3
  315. package/dist/runtime/app/composables/content-i18n.js +0 -1
  316. package/dist/runtime/app/composables/locale-context.d.ts +0 -5
  317. package/dist/runtime/app/composables/locale-context.js +0 -9
  318. package/dist/runtime/app/composables/locale.d.ts +0 -8
  319. package/dist/runtime/app/composables/locale.js +0 -15
  320. package/dist/runtime/app/composables/preview.d.ts +0 -5
  321. package/dist/runtime/app/composables/preview.js +0 -35
  322. package/dist/runtime/app/composables/query-api.d.ts +0 -22
  323. package/dist/runtime/app/composables/query-api.js +0 -55
  324. package/dist/runtime/app/composables/runtime.d.ts +0 -2
  325. package/dist/runtime/app/composables/runtime.js +0 -7
  326. package/dist/runtime/app/composables/search.d.ts +0 -60
  327. package/dist/runtime/app/composables/search.js +0 -281
  328. package/dist/runtime/app/composables/site-data.d.ts +0 -12
  329. package/dist/runtime/app/composables/site-data.js +0 -12
  330. package/dist/runtime/app/composables/toc.d.ts +0 -8
  331. package/dist/runtime/app/composables/toc.js +0 -23
  332. package/dist/runtime/app/composables/use-content-page.d.ts +0 -49
  333. package/dist/runtime/app/composables/use-content-page.js +0 -91
  334. package/dist/runtime/app/composables/use-content-shared.d.ts +0 -13
  335. package/dist/runtime/app/composables/use-content-shared.js +0 -29
  336. package/dist/runtime/app/composables/useUnwrap.d.ts +0 -8
  337. package/dist/runtime/app/composables/useUnwrap.js +0 -35
  338. package/dist/runtime/app/composables/utils.d.ts +0 -23
  339. package/dist/runtime/app/composables/utils.js +0 -62
  340. package/dist/runtime/app/pagefind-client.d.ts +0 -32
  341. package/dist/runtime/app/pagefind-client.js +0 -100
  342. package/dist/runtime/app/plugins/hot-reload.d.ts +0 -6
  343. package/dist/runtime/app/plugins/hot-reload.js +0 -14
  344. package/dist/runtime/app.d.vue.ts +0 -3
  345. package/dist/runtime/app.vue +0 -3
  346. package/dist/runtime/app.vue.d.ts +0 -3
  347. package/dist/runtime/markdown/plugins.d.ts +0 -6
  348. package/dist/runtime/markdown/plugins.js +0 -11
  349. package/dist/runtime/pagefind-manifest.d.ts +0 -8
  350. package/dist/runtime/pagefind-manifest.js +0 -15
  351. package/dist/runtime/server/agent-http.d.ts +0 -7
  352. package/dist/runtime/server/agent-http.js +0 -36
  353. package/dist/runtime/server/agent-markdown.d.ts +0 -17
  354. package/dist/runtime/server/agent-markdown.js +0 -167
  355. package/dist/runtime/server/agent-registry.d.ts +0 -7
  356. package/dist/runtime/server/agent-registry.js +0 -10
  357. package/dist/runtime/server/agent-site.d.ts +0 -36
  358. package/dist/runtime/server/agent-site.js +0 -269
  359. package/dist/runtime/server/api/agent-llms-full.d.ts +0 -2
  360. package/dist/runtime/server/api/agent-llms-full.js +0 -13
  361. package/dist/runtime/server/api/agent-llms.d.ts +0 -2
  362. package/dist/runtime/server/api/agent-llms.js +0 -14
  363. package/dist/runtime/server/api/agent-raw.d.ts +0 -2
  364. package/dist/runtime/server/api/agent-raw.js +0 -17
  365. package/dist/runtime/server/api/cache.d.ts +0 -43
  366. package/dist/runtime/server/api/cache.js +0 -88
  367. package/dist/runtime/server/api/locales.d.ts +0 -6
  368. package/dist/runtime/server/api/locales.js +0 -52
  369. package/dist/runtime/server/api/navigation.d.ts +0 -2
  370. package/dist/runtime/server/api/navigation.js +0 -60
  371. package/dist/runtime/server/api/query.d.ts +0 -2
  372. package/dist/runtime/server/api/query.js +0 -39
  373. package/dist/runtime/server/api/revalidate.d.ts +0 -9
  374. package/dist/runtime/server/api/revalidate.js +0 -231
  375. package/dist/runtime/server/api/search-index.d.ts +0 -2
  376. package/dist/runtime/server/api/search-index.js +0 -20
  377. package/dist/runtime/server/api/search.d.ts +0 -2
  378. package/dist/runtime/server/api/search.js +0 -48
  379. package/dist/runtime/server/api/site-data.d.ts +0 -7
  380. package/dist/runtime/server/api/site-data.js +0 -53
  381. package/dist/runtime/server/api/sitemap.d.ts +0 -2
  382. package/dist/runtime/server/api/sitemap.js +0 -11
  383. package/dist/runtime/server/cache-adapter.d.ts +0 -2
  384. package/dist/runtime/server/cache-adapter.js +0 -11
  385. package/dist/runtime/server/cache-adapters.d.ts +0 -8
  386. package/dist/runtime/server/cache-adapters.js +0 -27
  387. package/dist/runtime/server/cache-hints.d.ts +0 -5
  388. package/dist/runtime/server/cache-hints.js +0 -17
  389. package/dist/runtime/server/collection-helpers.d.ts +0 -4
  390. package/dist/runtime/server/collection-helpers.js +0 -33
  391. package/dist/runtime/server/index.d.ts +0 -5
  392. package/dist/runtime/server/index.js +0 -12
  393. package/dist/runtime/server/middleware/agent-link-headers.d.ts +0 -2
  394. package/dist/runtime/server/middleware/agent-link-headers.js +0 -44
  395. package/dist/runtime/server/middleware/agent-markdown.d.ts +0 -2
  396. package/dist/runtime/server/middleware/agent-markdown.js +0 -43
  397. package/dist/runtime/server/middleware/preview.d.ts +0 -2
  398. package/dist/runtime/server/middleware/preview.js +0 -7
  399. package/dist/runtime/server/navigation-query.d.ts +0 -8
  400. package/dist/runtime/server/navigation-query.js +0 -137
  401. package/dist/runtime/server/pagefind.d.ts +0 -2
  402. package/dist/runtime/server/pagefind.js +0 -59
  403. package/dist/runtime/server/plugins/cache.d.ts +0 -2
  404. package/dist/runtime/server/plugins/cache.js +0 -17
  405. package/dist/runtime/server/plugins/sitemap.d.ts +0 -2
  406. package/dist/runtime/server/plugins/sitemap.js +0 -25
  407. package/dist/runtime/server/provider-query.d.ts +0 -39
  408. package/dist/runtime/server/provider-query.js +0 -423
  409. package/dist/runtime/server/provider-result.d.ts +0 -21
  410. package/dist/runtime/server/provider-result.js +0 -24
  411. package/dist/runtime/server/provider-route-facts.d.ts +0 -9
  412. package/dist/runtime/server/provider-route-facts.js +0 -205
  413. package/dist/runtime/server/providers/filesystem.d.ts +0 -2
  414. package/dist/runtime/server/providers/filesystem.js +0 -209
  415. package/dist/runtime/server/providers/index.d.ts +0 -23
  416. package/dist/runtime/server/providers/index.js +0 -189
  417. package/dist/runtime/server/query-api.d.ts +0 -23
  418. package/dist/runtime/server/query-api.js +0 -103
  419. package/dist/runtime/server/query-executor.d.ts +0 -4
  420. package/dist/runtime/server/query-executor.js +0 -125
  421. package/dist/runtime/server/query-http-validation.d.ts +0 -36
  422. package/dist/runtime/server/query-http-validation.js +0 -154
  423. package/dist/runtime/server/runtime-config.d.ts +0 -1
  424. package/dist/runtime/server/runtime-config.js +0 -1
  425. package/dist/runtime/server/search.d.ts +0 -22
  426. package/dist/runtime/server/search.js +0 -72
  427. package/dist/runtime/server/sitemap-provider.d.ts +0 -5
  428. package/dist/runtime/server/sitemap-provider.js +0 -85
  429. package/dist/runtime/server/storage-access.d.ts +0 -4
  430. package/dist/runtime/server/storage-access.js +0 -34
  431. package/dist/runtime/server/validation.d.ts +0 -1
  432. package/dist/runtime/server/validation.js +0 -7
  433. package/dist/runtime/shared/search.d.ts +0 -11
  434. package/dist/runtime/shared/search.js +0 -62
  435. package/dist/runtime/transformers/define.d.ts +0 -1
  436. package/dist/runtime/transformers/define.js +0 -1
  437. package/dist/runtime/utils/content-components.d.ts +0 -1
  438. package/dist/runtime/utils/content-components.js +0 -5
  439. package/dist/runtime/utils/query.d.ts +0 -5
  440. package/dist/runtime/utils/query.js +0 -18
  441. package/dist/runtime/utils/sitemap-source.d.ts +0 -2
  442. package/dist/runtime/utils/sitemap-source.js +0 -6
  443. package/dist/runtime/virtual/transformers.d.ts +0 -4
  444. package/dist/runtime/virtual.d.ts +0 -10
  445. package/dist/storage/cache.d.ts +0 -25
  446. package/dist/storage/cache.js +0 -22
  447. package/dist/storage/contents.d.ts +0 -13
  448. package/dist/storage/contents.js +0 -113
  449. package/dist/storage/driver.d.ts +0 -13
  450. package/dist/storage/driver.js +0 -23
  451. package/dist/storage/graph.d.ts +0 -28
  452. package/dist/storage/graph.js +0 -59
  453. package/dist/storage/references.d.ts +0 -6
  454. package/dist/storage/references.js +0 -128
  455. package/dist/storage/snapshot-runtime.d.ts +0 -11
  456. package/dist/storage/snapshot-runtime.js +0 -57
  457. package/dist/storage/validation.d.ts +0 -63
  458. package/dist/storage/validation.js +0 -388
  459. package/dist/testing/data-source-contract.d.ts +0 -25
  460. package/dist/testing/data-source-contract.js +0 -70
  461. package/dist/testing/portability-contract.d.ts +0 -45
  462. package/dist/testing/portability-contract.js +0 -150
  463. package/dist/testing/provider-contract.d.ts +0 -40
  464. package/dist/testing/provider-contract.js +0 -142
  465. package/dist/testing/provider-fixture.d.ts +0 -73
  466. package/dist/testing/provider-fixture.js +0 -524
  467. package/dist/types/api.d.ts +0 -81
  468. package/dist/types/api.js +0 -1
  469. package/dist/types/component-policy.d.ts +0 -16
  470. package/dist/types/component-policy.js +0 -0
  471. package/dist/types/config.d.ts +0 -402
  472. package/dist/types/config.js +0 -77
  473. package/dist/types/content.d.ts +0 -362
  474. package/dist/types/content.js +0 -1
  475. package/dist/types/fields.d.ts +0 -63
  476. package/dist/types/fields.js +0 -180
  477. package/dist/types/index.d.ts +0 -6
  478. package/dist/types/index.js +0 -6
  479. package/dist/types/module.d.ts +0 -522
  480. package/dist/types/module.js +0 -0
  481. package/dist/types/navigation.d.ts +0 -13
  482. package/dist/types/navigation.js +0 -28
  483. package/dist/types/picomatch.d.ts +0 -8
  484. package/dist/types/query-parts/collections.d.ts +0 -15
  485. package/dist/types/query-parts/collections.js +0 -0
  486. package/dist/types/query-parts/public.d.ts +0 -295
  487. package/dist/types/query-parts/public.js +0 -7
  488. package/dist/types/query-parts/results.d.ts +0 -83
  489. package/dist/types/query-parts/results.js +0 -0
  490. package/dist/types/query-parts/transport.d.ts +0 -74
  491. package/dist/types/query-parts/transport.js +0 -18
  492. package/dist/types/query.d.ts +0 -5
  493. package/dist/types/query.js +0 -5
  494. package/dist/types/reference.d.ts +0 -14
  495. package/dist/types/reference.js +0 -13
  496. package/dist/types/runtime.d.ts +0 -40
  497. package/dist/types/runtime.js +0 -1
  498. package/dist/types/search.d.ts +0 -67
  499. package/dist/types/search.js +0 -0
  500. package/dist/types/virtual.d.ts +0 -92
  501. package/dist/types.d.mts +0 -11
  502. package/dist/web-types.json +0 -474
package/CHANGELOG.md ADDED
@@ -0,0 +1,75 @@
1
+ # @lupinum/ginko-content
2
+
3
+ ## 0.4.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [`ea2ea13`](https://github.com/lupinum-dev/ginko/commit/ea2ea133997f2011ad0d43f77a0f1dc75605923e) Thanks [@Mat4m0](https://github.com/Mat4m0)! - Add Ginko 0.4, the first release: one content system for Nuxt websites, from Markdown files in Git to a hosted platform.
8
+
9
+ Owners, staff and AI agents edit the same content. All seven packages release together under one version. It starts at 0.4 because `@lupinum/ginko-content` and `@lupinum/ginko-docs` already published an older, unrelated line up to 0.3. Until 1.0, a minor version (0.4 → 0.5) may contain breaking changes; the changelog names each one and how to update.
10
+
11
+ Requirements: Node 22.18+, 24 or 26, and Nuxt 4.6+ or Nuxt 5 (tested on its nightly until it is released). Start a site with `npm create ginko@latest my-site`; the documentation explains every step.
12
+
13
+ **Public API**
14
+
15
+ - `@lupinum/ginko`: `defineSite`, `single`, `collection`, `f`, `defineComponents`, `formatMoney`, `plainText`, `safeHref`, `startOfWeek` and the documented types. Imported, not auto-imported.
16
+ - `@lupinum/ginko/nuxt`: the module, the `useGinko*` composables (everything that needs a Nuxt app starts with `useGinko`), `<GinkoMarkdown>` and `<GinkoImage>`. `@lupinum/ginko/vue`: `<GinkoMarkdown>` for any Vue app. `@lupinum/ginko/search`: `loadIndex` and `search`.
17
+ - `@lupinum/ginko/internal` and `@lupinum/ginko/internal/search` are for Ginko's own packages and have no stability promise.
18
+ - The `ginko` CLI: `check [--offline]`, `release` and `export [folder]`, plus `--version`. Every command run prints one JSON line, `{ "ok": true, … }` or `{ "ok": false, "error": { code, message } }` (`--help` and `--version` print plain text), and ends with exit code 0 (ok), 1 (fix the code), 2 (usage), 3 (platform unreachable, retry) or 4 (key not allowed). CI deploys the site only when `release` prints `"deploy": true` (a superseded run exits 0 with `"deploy": false`). The CLI reads `GINKO_PLATFORM` (or `NUXT_PUBLIC_GINKO_PLATFORM`), `GINKO_KEY`, `GINKO_COMMIT` (or `GITHUB_SHA`), `GINKO_BRANCH` and `GINKO_REMOTE`; it does not read `.env` files. `ginko-i18n --json` uses the same output shape, error codes (`USAGE`, `INVALID`) and exit codes.
19
+ - Config names: `f.ref` (one entry) and `f.refs` (several); `visible: { mode: 'until', field, days?, deleteExpired? }`; prefill tokens `@today`, `@workWeek`, `@nextWorkWeek`; `firstDayOfWeek`, `linkCheck`, `untranslated`, `maxBytes`, `Migration.compute`, `retired` rule `{ drop: true }`. Options and defaults are typed per field, and an unknown top-level key fails the build.
20
+ - Markdown components: `embed`, `frame` (`none`, `card`, `border`, …), `background` (`none`, `muted`, `tint`), `appearance` (`quiet`, `tint`), `quiz-question{mode}`, `code-tree{file}`.
21
+
22
+ **Content (`@lupinum/ginko`, `@lupinum/ginko-content`)**
23
+
24
+ - One text format: Markdown (comark 0.7) everywhere, with field profiles that limit what a field may contain. Footnotes, emoji, alerts, Shiki code, task lists, route links (`$blog.my-post`), reusable snippets and heading anchors.
25
+ - Data files: YAML and JSON (one file, one entry) and CSV (one file, many entries), checked against the field schema; every error names the file and field, and the line for CSV rows and unreadable files. Entries with `draft: true` stay out of production builds.
26
+ - Query engine in the site, over the loaded bundle: `where`, `order`, `limit`, pagination with totals, field selection, `include` for references, previous/next and facet counts.
27
+ - References (`f.ref`, `f.refs`), navigation trees and breadcrumbs, and a URL for every entry in every language; two entries on one URL fail the build.
28
+ - Link check before any HTML exists: route links, anchors, snippets and redirected paths, in the build, the dev terminal, `ginko check` and the agent tools. On the platform a save, a new entry or a scheduled publish that adds a broken link is stopped, and History says why. External links are checked on request (`linkCheck.external`), at build and in `ginko check` (never in dev), with a 7-day cache.
29
+ - Images: WebP copies at 480, 960 and 1600 px, made at upload on the platform and at build for files. `<GinkoImage>` and Markdown images get `srcset` and `sizes`.
30
+ - Redirects from `redirectFrom` (301) and site rules in `redirects` (301 by default, `status` 302/307/308 per rule).
31
+ - SEO from the bundle, with no other module: title template, canonical, Open Graph with `og:url`, `<html lang>`, hreflang with `x-default`, sitemap with `lastmod`, images and alternates, robots.txt with `noindex` on preview hosts, JSON-LD. With `nuxt-og-image` (in every starter), every page gets a generated share card in the brand colour `seo.color`, with the site's logo and the page's image.
32
+ - Works with the Nuxt SEO modules (`@nuxtjs/seo` or single ones, in any order): Ginko leaves them sitemap, robots.txt and JSON-LD defaults and hands them its pages with hreflang, the site's address, name and languages, and `noindex` on preview hosts. `nuxt-ai-ready` stays off while Ginko serves `/llms.txt`. Requires `nuxt-og-image` 7.
33
+ - Search index built in plain JS at build time, one record per heading section, loaded lazily per language.
34
+ - Agent output: `/llms.txt`, `/llms-full.txt`, a `.md` twin for every entry page (collections with a `route`), and a Markdown 404 that suggests pages. The normal address always answers with HTML.
35
+ - Render modes: Git-only sites prerender everything; platform sites refresh changed pages after a publish; previews render with `noindex`.
36
+ - In dev, `nuxt dev` restarts when `ginko.config.ts` changes, and a brick that cannot reach the platform names itself and the fix.
37
+ - CLI `ginko`: `check` (schema, links and the share image, for every site; `--offline` without the platform) and `release` for CI, `export` for backups; `pnpm local:dev|import|pull` run only in the Ginko monorepo.
38
+
39
+ **Languages (`@lupinum/ginko-i18n`)**
40
+
41
+ - The only locale authority: routes, alternates, hreflang, messages with plurals, and formatters for dates, ranges, relative time, numbers, currency and lists, each in the site's time zone.
42
+ - Works on its own in any Nuxt 4.6+ or Nuxt 5 app, without the rest of Ginko.
43
+
44
+ **Components and docs (`@lupinum/ginko-components`, `@lupinum/ginko-docs`)**
45
+
46
+ - Content components with props defined as Ginko fields: callouts, tabs, code groups, steps, cards, accordion, figures, embeds (click to load), timeline, quiz and more. Each one can also be copied into an app with the shadcn-vue CLI, from a registry the docs build generates.
47
+ - Docs layer (`@lupinum/ginko-docs`; `npm create ginko@latest my-docs -- --preset docs` starts a site with it): navigation, section tabs, breadcrumbs, table of contents with scroll spy, previous/next, ⌘K search with heading results, blog with authors and RSS, changelog, copy page as Markdown, dark mode. A guide for switching from Nuxt Content and `@nuxtjs/i18n`. Math (KaTeX) and mermaid diagrams render and load only on pages that use them.
48
+
49
+ **Platform and Studio (hosted by Lupinum)**
50
+
51
+ The platform is a hosted service, not an npm package. A site connects to it with one setting; without it, the site reads its content from files.
52
+
53
+ - Quick tasks for the jobs owners do most ("Heute geschlossen", "Preis ändern"), phone first, with the full form behind "Alles bearbeiten".
54
+ - Files library: All, Recent, Unused, Missing alt text, Duplicates and folders; icon and list views; "used in" with links; replace a file and keep its references; a used file cannot be removed by mistake. Alt text set in the library is the default for every use, per language.
55
+ - Approvals, off by default: a task or agent key can need a yes. Reviewers see the change, approve, approve for a time, or reject with a sentence; the author sees the reason. Releases publish several changes together.
56
+ - History with "show changes", "back to this version" and undo; drafts and scheduled publishing; trash with restore; translation status per language; "why is this not on the website?".
57
+ - Team and invitations with per-task rights, sign-in with an emailed code, AI agent keys with an MCP tool catalog derived from the operations, and weekly reminder mails.
58
+ - Long forms group their fields under headings or in tabs (`group` on a field, `layout: 'tabs'` on a brick); phones always show headings.
59
+ - A rich text editor (TipTap 3) that writes Markdown, where untouched text stays byte for byte. Headings, lists, task lists, quotes, code blocks, tables, images from the library, embeds, registry components with prop forms, slash and bubble menus, Markdown shortcuts and paste, source mode, find and replace (⌘F), a drag handle and Alt+↑/↓ to move blocks, character counter, a link card for pasted URLs, uploads with progress, and a formatting bar above the phone keyboard.
60
+ - Delete a site, with seven days to cancel, and delete your own account. The last owner of a site must hand it over or delete it first.
61
+ - Studio in German, English and Spanish (beta), light and dark.
62
+
63
+ **Presets (`@lupinum/ginko-preset-gastro`, `create-ginko`)**
64
+
65
+ - Gastro: opening hours with exceptions, seasons, holidays and new hours from a date; lunch week with planning ahead and an optional PDF; menu with prices from a date; notices that expire; events; JSON-LD for Restaurant, Menu, opening hours and Event; a printable lunch sheet.
66
+ - `create-ginko` starts a new site, plain or with `--preset gastro|docs`. Starters install with npm, pnpm 11 and bun, carry a `typecheck` script, a page description and share cards (`nuxt-og-image` with Takumi, Nuxt 4.6.1 or later; set `NUXT_APP_SECRET` where the site runs, `.env` has one), and create-ginko warns on an unsupported Node.
67
+
68
+ **Not in 0.4**
69
+
70
+ Real-time co-editing comes next. Also not included: an agency preset, the editor UI as a shadcn-vue registry, OAuth for agent connectors, and a Google Business sync.
71
+
72
+ ### Patch Changes
73
+
74
+ - Updated dependencies [[`ea2ea13`](https://github.com/lupinum-dev/ginko/commit/ea2ea133997f2011ad0d43f77a0f1dc75605923e)]:
75
+ - @lupinum/ginko@0.4.0
package/LICENSE CHANGED
@@ -1,7 +1,6 @@
1
1
  MIT License
2
2
 
3
- Copyright (c) 2026-present Lupinum OG
4
- Copyright (c) Nuxt Project
3
+ Copyright (c) 2025-2026 Lupinum OG
5
4
 
6
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
7
6
  of this software and associated documentation files (the "Software"), to deal
package/README.md CHANGED
@@ -1,173 +1,48 @@
1
1
  # @lupinum/ginko-content
2
2
 
3
- Filesystem-first content for Nuxt 4.
3
+ Files as a content source for [`@lupinum/ginko`](https://github.com/lupinum-dev/ginko/tree/main/packages/ginko).
4
+ At build time it reads `content/` and builds the same bundle the Ginko platform serves, so a site
5
+ reads files and platform content the same way, with `useGinko`. Use it for content that developers
6
+ maintain: docs, a blog, legal pages, a price list. It reads Markdown, YAML, JSON and CSV.
4
7
 
5
- Write Markdown and data files in `content/`, define collections once in
6
- `content.config.ts`, then use those collection handles for route pages, lists,
7
- navigation, search, i18n, and sitemap output.
8
-
9
- Use it when you want content files to stay simple, but your Nuxt app still
10
- needs explicit APIs for route resolution, typed frontmatter, localized content,
11
- and server-side reads.
12
-
13
- This README describes the `0.4.0-rc.1` release candidate. Install it from npm's
14
- `next` channel; the stable line remains `0.3` until the RC is promoted.
15
-
16
- ## Requirements
17
-
18
- - Node.js 22.18–22.x, 24.11–24.x, or 26+
19
- - Nuxt 4.4.7 through Nuxt 4.x
20
- - Vue 3.5.35 through Vue 3.x
21
- - ESM; CommonJS `require()` is not supported
22
-
23
- ## Install
24
-
25
- ```bash
26
- npx nuxi module add @lupinum/ginko-content@0.4.0-rc.1
27
- ```
28
-
29
- The Nuxt CLI installs the package and registers the module in `nuxt.config.ts`.
30
- If you prefer to install by hand:
8
+ ## Use
31
9
 
32
10
  ```bash
33
- pnpm add @lupinum/ginko-content@0.4.0-rc.1
11
+ npm install @lupinum/ginko @lupinum/ginko-content
34
12
  ```
35
13
 
36
- ```ts
37
- export default defineNuxtConfig({
38
- modules: ['@lupinum/ginko-content'],
39
- imports: {
40
- autoImport: true
41
- }
42
- })
43
- ```
44
-
45
- ## Quick Start
14
+ `@lupinum/ginko` is a peer dependency. Images get WebP variants through `sharp`, an optional peer dependency: install it
15
+ (`npm install sharp`, version 0.33 to 0.35) if your site has image files. `ginko check` runs without it.
46
16
 
47
- Define a collection:
17
+ Give a brick `source: 'files'` and one `f.markdown` field:
48
18
 
49
19
  ```ts
50
- // content.config.ts
51
- import { defineCollection, defineContentConfig } from '@lupinum/ginko-content/config'
52
-
53
- export const pages = defineCollection({
54
- type: 'page',
55
- source: '**/*.md'
56
- })
57
-
58
- export default defineContentConfig({
59
- collections: {
60
- pages
61
- }
62
- })
63
- ```
64
-
65
- Create `content/index.md`:
66
-
67
- ```md
68
- ---
69
- title: Welcome
70
- ---
71
-
72
- # Welcome
73
-
74
- This file renders at `/`.
20
+ // ginko.config.ts
21
+ docs: collection({
22
+ label: 'Docs',
23
+ source: 'files',
24
+ max: 500,
25
+ order: 'manual',
26
+ route: { en: '/docs/[slug]' },
27
+ fields: { title: f.text('Title'), slug: f.slug('Address', { from: 'title' }), body: f.markdown('Text') },
28
+ }),
75
29
  ```
76
30
 
77
- Render the current route through the collection:
78
-
79
- ```vue
80
- <!-- pages/[...slug].vue -->
81
- <script setup lang="ts">
82
- import { pages } from '~~/content.config'
83
-
84
- definePageMeta({ key: route => route.path })
85
-
86
- const { page } = await useContentPage(pages)
87
-
88
- if (!page.value) {
89
- throw createError({ statusCode: 404, statusMessage: 'Page not found', fatal: true })
90
- }
91
- </script>
92
-
93
- <template>
94
- <ContentRenderer v-if="page" :value="page" />
95
- </template>
31
+ ```text
32
+ content/docs/1.getting-started.md one entry; the number is the order
33
+ content/docs/1.getting-started.de.md its translation
96
34
  ```
97
35
 
98
- ## Features
99
-
100
- - file-authored pages and navigation from `content/`
101
- - collection definitions as the source of truth for content shape and source
102
- files
103
- - Markdown, Comark component tags, YAML, JSON, and CSV ingestion
104
- - locale-aware content routing
105
- - route-aware page loading with `useContentPage(pages)`
106
- - semantic previous/next route-page data through `useContentPage(pages, { surround })`
107
- - server reads through `one`, `many`, `paginate`, `resolveOne`, `navigation`,
108
- and `surround`
109
- - route and search composables, plus one-shot async client query functions for other
110
- reads
111
- - search helpers for MiniSearch, Pagefind, and provider-owned search
112
- - sitemap integration for public content routes
113
- - a server-side provider contract for advanced custom sources
114
-
115
- ## I18n, Sitemap, and Prerender Ownership
116
-
117
- For localized Nuxt apps, keep one source of truth per route type:
118
-
119
- - Static Nuxt page paths belong in Nuxt I18n `i18n.pages`.
120
- - Content page paths belong in Ginko collection routes and content files.
121
- - Sitemap XML is generated by `@nuxtjs/sitemap`.
122
- - Ginko registers the content sitemap source and contributes content prerender
123
- routes.
124
-
125
- Do not duplicate docs, blog, pricing, privacy, or translated locale paths in
126
- `sitemap.urls` or app-owned `nitro.prerender.routes` arrays. Use
127
- `@nuxtjs/sitemap >= 8.0.15 < 9` when translated static app slugs such as `/preise`
128
- and `/en/pricing` need cross-locale sitemap alternates.
129
-
130
- See the public guide:
131
- [Sitemap and prerender](https://github.com/lupinum-dev/ginko-content/blob/main/docs/content/docs/4.guides/9.sitemap-and-prerender.md).
132
-
133
- ## Integration Dependencies
134
-
135
- | Feature | Dependency model |
136
- | --- | --- |
137
- | Markdown highlighting and built-in Shiki transformers | Included as runtime dependencies of `@lupinum/ginko-content`. |
138
- | Math Markdown | Install the optional `katex` peer and add `katex/dist/katex.min.css` to Nuxt's `css` array. |
139
- | Mermaid Markdown | Install the optional `beautiful-mermaid` peer. |
140
- | MiniSearch backend | Included as a runtime dependency and used by the default search backend. |
141
- | Pagefind backend | Install the optional `pagefind` peer when `content.search.engine` is `'pagefind'`. |
142
- | Provider-owned search | No extra package. The active content provider must advertise and implement `search`. |
143
- | Content i18n | Install and configure `@nuxtjs/i18n` 10.x when the app uses Nuxt locale routes. |
144
- | Sitemap XML output | Install and configure `@nuxtjs/sitemap`; Ginko contributes the content sitemap source. |
145
-
146
- Markdown plugins are opt-in. Omitting `content.markdown.plugins` is identical
147
- to `plugins: []`; add `shiki`, `math`, `mermaid`, `toc`, or `summary` only when
148
- the application needs that behavior.
149
-
150
- ## Scope
151
-
152
- The default provider reads files from your Nuxt project. The package does not
153
- include a CMS UI, Studio, admin panel, or content editing workflow.
154
-
155
- ## Project links
36
+ The Ginko Nuxt module finds this package by itself. It serves the Markdown of a page with the page,
37
+ adds `<GinkoMarkdown>` and a search index. A file error fails the build and names the file.
156
38
 
157
- - Documentation source: [Getting started](https://github.com/lupinum-dev/ginko-content/blob/main/docs/content/docs/1.get-started/1.quickstart.md)
158
- - Repository: [github.com/lupinum-dev/ginko-content](https://github.com/lupinum-dev/ginko-content)
159
- - Issues: [GitHub issues](https://github.com/lupinum-dev/ginko-content/issues)
160
- - Contributing: [CONTRIBUTING.md](https://github.com/lupinum-dev/ginko-content/blob/main/CONTRIBUTING.md)
161
- - Security: [SECURITY.md](https://github.com/lupinum-dev/ginko-content/blob/main/SECURITY.md)
39
+ Full guide: [Content from files](https://ginko-docs.vercel.app/en/docs/content-from-files).
162
40
 
163
- ## Credits
41
+ ## Stability
164
42
 
165
- Ginko Content is an independently maintained fork derived from
166
- [Nuxt Content](https://content.nuxt.com/). It has substantially diverged while
167
- retaining upstream-derived parser, MDC, and rendering foundations. Credits also
168
- go to [Nuxt UI](https://ui.nuxt.com/) and [Comark](https://comark.dev/), the
169
- successor to the previous MDC work.
43
+ You install this package; you do not import it. The Ginko module and `ginko check` load it. Its
44
+ exports are the contract between the Ginko packages and can change in any release.
170
45
 
171
46
  ## License
172
47
 
173
- [MIT](./LICENSE)
48
+ MIT © Lupinum OG
@@ -0,0 +1,74 @@
1
+ import { Locale, MarkdownValue, MarkdownTree } from '@lupinum/ginko';
2
+ import { Schema, Bundle } from '@lupinum/ginko/internal';
3
+ import { SearchIndexJson } from '@lupinum/ginko/search';
4
+
5
+ interface ContentError {
6
+ /** Path relative to the content directory, e.g. `docs/1.einstieg.en.md`. */
7
+ file: string;
8
+ /** Field path as in validate() issues, when the error belongs to one field. */
9
+ path?: string;
10
+ message: string;
11
+ /** 1-based line in the file, when the error belongs to one (YAML, JSON and CSV parse errors, CSV rows). */
12
+ line?: number;
13
+ }
14
+ /**
15
+ * One error as `ginko check` and the build print it: `content/<file>:<line> (<field>): <message>`.
16
+ * @internal Loaded by the Ginko module and CLI; sites do not import it.
17
+ */
18
+ declare function errorLine(e: ContentError): string;
19
+ interface ReadOptions {
20
+ /** `false` leaves out entries marked `draft: true`. Default `true` (dev shows drafts). */
21
+ drafts?: boolean;
22
+ }
23
+
24
+ /**
25
+ * The bundle for page state: every markdown tree replaced by `{ ref, toc }` (CONTENT.md, Phase 14).
26
+ * `trees` collects the trees by their ref, for the route that serves them.
27
+ * @internal Loaded by the Ginko module and CLI; sites do not import it.
28
+ */
29
+ declare function withMarkdownRefs(bundle: Bundle, schema: Schema, trees: Map<string, MarkdownValue>): Bundle;
30
+ /**
31
+ * The bundle a site serves to everyone (`/__ginko/files/*`, page state, search): items whose visibility window
32
+ * ended before `now` are left out (an expired offer is not private data to publish), and the repo path
33
+ * `source` is dropped unless `keepSource` is set (docs pages need it for their "Edit this page" link).
34
+ * Items whose window is current or still to come stay: the page filters them by date in the browser.
35
+ * @internal Loaded by the Ginko module and CLI; sites do not import it.
36
+ */
37
+ declare function publicBundle(bundle: Bundle, schema: Schema, now: Date, options?: {
38
+ keepSource?: boolean;
39
+ }): Bundle;
40
+ /**
41
+ * One bundle per locale from the files, built by the core's buildBundle, so visibility, order, URLs
42
+ * and fallbacks follow the same rules as platform content. Revisions are 0: files have no history.
43
+ * @internal Loaded by the Ginko module and CLI; sites do not import it.
44
+ */
45
+ declare function buildFileBundles(options: BuildOptions): Promise<BuildResult>;
46
+ interface BuildOptions extends ReadOptions {
47
+ /** The site's `content/` folder. */
48
+ contentDir: string;
49
+ /** The site's `public/` folder. */
50
+ publicDir: string;
51
+ schema: Schema;
52
+ /** The time the build counts as "now" (visibility windows, `generatedAt`). Default: the current time. */
53
+ now?: Date;
54
+ /** Where the WebP variants of the site's images are written (the folder served at `/_ginko/img`). Without it, no variants are made. */
55
+ imageDir?: string;
56
+ }
57
+ interface BuildResult {
58
+ /** One bundle per locale of the schema. */
59
+ bundles: Partial<Record<Locale, Bundle>>;
60
+ /** Co-located Markdown images: served URL to absolute path. */
61
+ images: Map<string, string>;
62
+ /** Every WebP variant file name that was written to `imageDir`. */
63
+ imageFiles: Set<string>;
64
+ errors: ContentError[];
65
+ }
66
+
67
+ /**
68
+ * The serialized search index of one locale's bundle (see searchSections). `bundle` must hold the `{ ref }`
69
+ * markdown values that withMarkdownRefs wrote, and `trees` the trees behind those refs.
70
+ * @internal Loaded by the Ginko module and CLI; sites do not import it.
71
+ */
72
+ declare function searchIndex(bundle: Bundle, trees: Map<string, MarkdownTree>, schema: Schema): Promise<SearchIndexJson>;
73
+
74
+ export { buildFileBundles, errorLine, publicBundle, searchIndex, withMarkdownRefs };
@@ -0,0 +1,74 @@
1
+ import { Locale, MarkdownValue, MarkdownTree } from '@lupinum/ginko';
2
+ import { Schema, Bundle } from '@lupinum/ginko/internal';
3
+ import { SearchIndexJson } from '@lupinum/ginko/search';
4
+
5
+ interface ContentError {
6
+ /** Path relative to the content directory, e.g. `docs/1.einstieg.en.md`. */
7
+ file: string;
8
+ /** Field path as in validate() issues, when the error belongs to one field. */
9
+ path?: string;
10
+ message: string;
11
+ /** 1-based line in the file, when the error belongs to one (YAML, JSON and CSV parse errors, CSV rows). */
12
+ line?: number;
13
+ }
14
+ /**
15
+ * One error as `ginko check` and the build print it: `content/<file>:<line> (<field>): <message>`.
16
+ * @internal Loaded by the Ginko module and CLI; sites do not import it.
17
+ */
18
+ declare function errorLine(e: ContentError): string;
19
+ interface ReadOptions {
20
+ /** `false` leaves out entries marked `draft: true`. Default `true` (dev shows drafts). */
21
+ drafts?: boolean;
22
+ }
23
+
24
+ /**
25
+ * The bundle for page state: every markdown tree replaced by `{ ref, toc }` (CONTENT.md, Phase 14).
26
+ * `trees` collects the trees by their ref, for the route that serves them.
27
+ * @internal Loaded by the Ginko module and CLI; sites do not import it.
28
+ */
29
+ declare function withMarkdownRefs(bundle: Bundle, schema: Schema, trees: Map<string, MarkdownValue>): Bundle;
30
+ /**
31
+ * The bundle a site serves to everyone (`/__ginko/files/*`, page state, search): items whose visibility window
32
+ * ended before `now` are left out (an expired offer is not private data to publish), and the repo path
33
+ * `source` is dropped unless `keepSource` is set (docs pages need it for their "Edit this page" link).
34
+ * Items whose window is current or still to come stay: the page filters them by date in the browser.
35
+ * @internal Loaded by the Ginko module and CLI; sites do not import it.
36
+ */
37
+ declare function publicBundle(bundle: Bundle, schema: Schema, now: Date, options?: {
38
+ keepSource?: boolean;
39
+ }): Bundle;
40
+ /**
41
+ * One bundle per locale from the files, built by the core's buildBundle, so visibility, order, URLs
42
+ * and fallbacks follow the same rules as platform content. Revisions are 0: files have no history.
43
+ * @internal Loaded by the Ginko module and CLI; sites do not import it.
44
+ */
45
+ declare function buildFileBundles(options: BuildOptions): Promise<BuildResult>;
46
+ interface BuildOptions extends ReadOptions {
47
+ /** The site's `content/` folder. */
48
+ contentDir: string;
49
+ /** The site's `public/` folder. */
50
+ publicDir: string;
51
+ schema: Schema;
52
+ /** The time the build counts as "now" (visibility windows, `generatedAt`). Default: the current time. */
53
+ now?: Date;
54
+ /** Where the WebP variants of the site's images are written (the folder served at `/_ginko/img`). Without it, no variants are made. */
55
+ imageDir?: string;
56
+ }
57
+ interface BuildResult {
58
+ /** One bundle per locale of the schema. */
59
+ bundles: Partial<Record<Locale, Bundle>>;
60
+ /** Co-located Markdown images: served URL to absolute path. */
61
+ images: Map<string, string>;
62
+ /** Every WebP variant file name that was written to `imageDir`. */
63
+ imageFiles: Set<string>;
64
+ errors: ContentError[];
65
+ }
66
+
67
+ /**
68
+ * The serialized search index of one locale's bundle (see searchSections). `bundle` must hold the `{ ref }`
69
+ * markdown values that withMarkdownRefs wrote, and `trees` the trees behind those refs.
70
+ * @internal Loaded by the Ginko module and CLI; sites do not import it.
71
+ */
72
+ declare function searchIndex(bundle: Bundle, trees: Map<string, MarkdownTree>, schema: Schema): Promise<SearchIndexJson>;
73
+
74
+ export { buildFileBundles, errorLine, publicBundle, searchIndex, withMarkdownRefs };