@dogsbay/format-mkdocs 0.2.0-beta.13 → 0.2.0-beta.131

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 (147) hide show
  1. package/dist/cli.d.ts +0 -1
  2. package/dist/cli.js +115 -5
  3. package/dist/export/capabilities.d.ts +22 -0
  4. package/dist/export/capabilities.js +213 -0
  5. package/dist/export/to-astro.d.ts +0 -1
  6. package/dist/export/to-astro.js +10 -2
  7. package/dist/export/to-mkdocs-project.d.ts +12 -1
  8. package/dist/export/to-mkdocs-project.js +279 -64
  9. package/dist/export/to-mkdocs.d.ts +53 -4
  10. package/dist/export/to-mkdocs.js +905 -104
  11. package/dist/importer.d.ts +0 -1
  12. package/dist/importer.js +3 -2
  13. package/dist/index.d.ts +21 -4
  14. package/dist/index.js +40 -4
  15. package/dist/inline-walker.d.ts +0 -1
  16. package/dist/inline-walker.js +0 -1
  17. package/dist/loader.d.ts +1 -2
  18. package/dist/loader.js +28 -9
  19. package/dist/parse.d.ts +0 -1
  20. package/dist/parse.js +0 -1
  21. package/dist/renderers/mermaid.d.ts +0 -1
  22. package/dist/renderers/mermaid.js +0 -1
  23. package/dist/rules/admonition.d.ts +0 -1
  24. package/dist/rules/admonition.js +0 -1
  25. package/dist/rules/annotations.d.ts +0 -1
  26. package/dist/rules/annotations.js +0 -1
  27. package/dist/rules/autodoc.d.ts +1 -2
  28. package/dist/rules/autodoc.js +1 -3
  29. package/dist/rules/blocks.d.ts +0 -1
  30. package/dist/rules/blocks.js +0 -1
  31. package/dist/rules/content-tabs.d.ts +0 -1
  32. package/dist/rules/content-tabs.js +0 -1
  33. package/dist/rules/docusaurus-admonitions.d.ts +0 -1
  34. package/dist/rules/docusaurus-admonitions.js +0 -1
  35. package/dist/rules/file-include.d.ts +0 -1
  36. package/dist/rules/file-include.js +0 -1
  37. package/dist/rules/footnotes.d.ts +0 -1
  38. package/dist/rules/footnotes.js +0 -1
  39. package/dist/rules/icon-shortcode.d.ts +0 -1
  40. package/dist/rules/icon-shortcode.js +0 -1
  41. package/dist/rules/keys.d.ts +0 -1
  42. package/dist/rules/keys.js +0 -1
  43. package/dist/rules/link-rewrite.d.ts +0 -1
  44. package/dist/rules/link-rewrite.js +0 -1
  45. package/dist/rules/math.d.ts +0 -1
  46. package/dist/rules/math.js +0 -1
  47. package/dist/rules/md-in-html.d.ts +0 -1
  48. package/dist/rules/md-in-html.js +0 -1
  49. package/dist/rules/snippets.d.ts +0 -1
  50. package/dist/rules/snippets.js +0 -1
  51. package/dist/rules/templates.d.ts +0 -1
  52. package/dist/rules/templates.js +0 -1
  53. package/dist/rules/variants.d.ts +0 -1
  54. package/dist/rules/variants.js +0 -1
  55. package/dist/tree.d.ts +0 -1
  56. package/dist/tree.js +0 -1
  57. package/dist/utils/indent.d.ts +0 -1
  58. package/dist/utils/indent.js +0 -1
  59. package/dist/utils/types.d.ts +0 -1
  60. package/dist/utils/types.js +0 -1
  61. package/dist/walker.d.ts +0 -1
  62. package/dist/walker.js +0 -1
  63. package/package.json +13 -12
  64. package/dist/autodoc/markdown-generator.d.ts +0 -6
  65. package/dist/autodoc/markdown-generator.d.ts.map +0 -1
  66. package/dist/autodoc/markdown-generator.js +0 -242
  67. package/dist/autodoc/markdown-generator.js.map +0 -1
  68. package/dist/autodoc/module-resolver.d.ts +0 -8
  69. package/dist/autodoc/module-resolver.d.ts.map +0 -1
  70. package/dist/autodoc/module-resolver.js +0 -218
  71. package/dist/autodoc/module-resolver.js.map +0 -1
  72. package/dist/autodoc/python-docstring.d.ts +0 -7
  73. package/dist/autodoc/python-docstring.d.ts.map +0 -1
  74. package/dist/autodoc/python-docstring.js +0 -324
  75. package/dist/autodoc/python-docstring.js.map +0 -1
  76. package/dist/autodoc/python-parser.d.ts +0 -10
  77. package/dist/autodoc/python-parser.d.ts.map +0 -1
  78. package/dist/autodoc/python-parser.js +0 -541
  79. package/dist/autodoc/python-parser.js.map +0 -1
  80. package/dist/autodoc/tree-builder.d.ts +0 -9
  81. package/dist/autodoc/tree-builder.d.ts.map +0 -1
  82. package/dist/autodoc/tree-builder.js +0 -279
  83. package/dist/autodoc/tree-builder.js.map +0 -1
  84. package/dist/autodoc/types.d.ts +0 -128
  85. package/dist/autodoc/types.d.ts.map +0 -1
  86. package/dist/autodoc/types.js +0 -2
  87. package/dist/autodoc/types.js.map +0 -1
  88. package/dist/cli.d.ts.map +0 -1
  89. package/dist/cli.js.map +0 -1
  90. package/dist/export/to-astro.d.ts.map +0 -1
  91. package/dist/export/to-astro.js.map +0 -1
  92. package/dist/export/to-mkdocs-project.d.ts.map +0 -1
  93. package/dist/export/to-mkdocs-project.js.map +0 -1
  94. package/dist/export/to-mkdocs.d.ts.map +0 -1
  95. package/dist/export/to-mkdocs.js.map +0 -1
  96. package/dist/importer.d.ts.map +0 -1
  97. package/dist/importer.js.map +0 -1
  98. package/dist/index.d.ts.map +0 -1
  99. package/dist/index.js.map +0 -1
  100. package/dist/inline-walker.d.ts.map +0 -1
  101. package/dist/inline-walker.js.map +0 -1
  102. package/dist/loader.d.ts.map +0 -1
  103. package/dist/loader.js.map +0 -1
  104. package/dist/parse.d.ts.map +0 -1
  105. package/dist/parse.js.map +0 -1
  106. package/dist/renderers/mermaid.d.ts.map +0 -1
  107. package/dist/renderers/mermaid.js.map +0 -1
  108. package/dist/rules/admonition.d.ts.map +0 -1
  109. package/dist/rules/admonition.js.map +0 -1
  110. package/dist/rules/annotations.d.ts.map +0 -1
  111. package/dist/rules/annotations.js.map +0 -1
  112. package/dist/rules/autodoc.d.ts.map +0 -1
  113. package/dist/rules/autodoc.js.map +0 -1
  114. package/dist/rules/blocks.d.ts.map +0 -1
  115. package/dist/rules/blocks.js.map +0 -1
  116. package/dist/rules/content-tabs.d.ts.map +0 -1
  117. package/dist/rules/content-tabs.js.map +0 -1
  118. package/dist/rules/docusaurus-admonitions.d.ts.map +0 -1
  119. package/dist/rules/docusaurus-admonitions.js.map +0 -1
  120. package/dist/rules/file-include.d.ts.map +0 -1
  121. package/dist/rules/file-include.js.map +0 -1
  122. package/dist/rules/footnotes.d.ts.map +0 -1
  123. package/dist/rules/footnotes.js.map +0 -1
  124. package/dist/rules/icon-shortcode.d.ts.map +0 -1
  125. package/dist/rules/icon-shortcode.js.map +0 -1
  126. package/dist/rules/keys.d.ts.map +0 -1
  127. package/dist/rules/keys.js.map +0 -1
  128. package/dist/rules/link-rewrite.d.ts.map +0 -1
  129. package/dist/rules/link-rewrite.js.map +0 -1
  130. package/dist/rules/math.d.ts.map +0 -1
  131. package/dist/rules/math.js.map +0 -1
  132. package/dist/rules/md-in-html.d.ts.map +0 -1
  133. package/dist/rules/md-in-html.js.map +0 -1
  134. package/dist/rules/snippets.d.ts.map +0 -1
  135. package/dist/rules/snippets.js.map +0 -1
  136. package/dist/rules/templates.d.ts.map +0 -1
  137. package/dist/rules/templates.js.map +0 -1
  138. package/dist/rules/variants.d.ts.map +0 -1
  139. package/dist/rules/variants.js.map +0 -1
  140. package/dist/tree.d.ts.map +0 -1
  141. package/dist/tree.js.map +0 -1
  142. package/dist/utils/indent.d.ts.map +0 -1
  143. package/dist/utils/indent.js.map +0 -1
  144. package/dist/utils/types.d.ts.map +0 -1
  145. package/dist/utils/types.js.map +0 -1
  146. package/dist/walker.d.ts.map +0 -1
  147. package/dist/walker.js.map +0 -1
@@ -27,4 +27,3 @@ export declare function readMkdocsConfig(sourceDir: string): MkdocsConfig;
27
27
  * Import a MkDocs project: parse all pages and extract navigation.
28
28
  */
29
29
  export declare function importMkdocsProject(sourceDir: string, opts?: Record<string, unknown>): Promise<MkdocsImportResult>;
30
- //# sourceMappingURL=importer.d.ts.map
package/dist/importer.js CHANGED
@@ -75,7 +75,9 @@ export async function importMkdocsProject(sourceDir, opts = {}) {
75
75
  const parseOpts = {
76
76
  collapse: false,
77
77
  youtubeEmbed: true,
78
- diagrams: true,
78
+ // `content.diagrams` (false, true, "mermaid-cli" or "pele"); it was always true here, so
79
+ // `content.diagrams: false` did not reach MkDocs sources
80
+ diagrams: opts.diagrams ?? true,
79
81
  };
80
82
  // Detect mkdocstrings autodoc config
81
83
  const mkdocstringsConfig = extractMkdocstringsConfig(config.raw, sourceDir);
@@ -373,4 +375,3 @@ function extractMacrosData(config, sourceDir) {
373
375
  }
374
376
  return Object.keys(result).length > 0 ? result : null;
375
377
  }
376
- //# sourceMappingURL=importer.js.map
package/dist/index.d.ts CHANGED
@@ -7,6 +7,7 @@ export { parseToTree } from "./parse.js";
7
7
  export { parseShortcode } from "./rules/icon-shortcode.js";
8
8
  export { treeToMkdocs } from "./export/to-mkdocs.js";
9
9
  export { exportMkdocsProject } from "./export/to-mkdocs-project.js";
10
+ export { MKDOCS_CAPABILITIES } from "./export/capabilities.js";
10
11
  export type { MkdocsProjectOptions, MkdocsProjectExport } from "./export/to-mkdocs-project.js";
11
12
  export interface MkdocsPluginOptions {
12
13
  admonitions?: boolean;
@@ -50,8 +51,24 @@ export interface MkdocsPluginOptions {
50
51
  */
51
52
  export declare function mkdocsPlugin(md: MarkdownIt, options?: MkdocsPluginOptions): void;
52
53
  /**
53
- * Build plugin options from a mkdocs.yml `markdown_extensions` array.
54
- * Each entry can be a string or an object with a single key.
54
+ * Build plugin options from a mkdocs.yml `markdown_extensions`
55
+ * declaration. MkDocs accepts two shapes — list (canonical) and
56
+ * mapping (FastAPI-style):
57
+ *
58
+ * markdown_extensions:
59
+ * - admonition
60
+ * - pymdownx.tabbed:
61
+ * alternate_style: true
62
+ *
63
+ * markdown_extensions:
64
+ * admonition: null
65
+ * pymdownx.tabbed:
66
+ * alternate_style: true
67
+ *
68
+ * We accept either, plus `null` / `undefined` (no extensions
69
+ * declared). Without the mapping-form handling, FastAPI-style
70
+ * mkdocs.yml silently skips PyMdownX Blocks (`/// note`, etc.) and
71
+ * downstream parses fall through to raw paragraphs — surfaced by
72
+ * the migrate-mkdocs FastAPI smoke.
55
73
  */
56
- export declare function configureFromMkdocs(extensions: (string | Record<string, unknown>)[]): MkdocsPluginOptions;
57
- //# sourceMappingURL=index.d.ts.map
74
+ export declare function configureFromMkdocs(extensions: unknown): MkdocsPluginOptions;
package/dist/index.js CHANGED
@@ -7,6 +7,7 @@ export { parseShortcode } from "./rules/icon-shortcode.js";
7
7
  // MkDocs serializer (TreeNode[] → MkDocs markdown)
8
8
  export { treeToMkdocs } from "./export/to-mkdocs.js";
9
9
  export { exportMkdocsProject } from "./export/to-mkdocs-project.js";
10
+ export { MKDOCS_CAPABILITIES } from "./export/capabilities.js";
10
11
  import { admonitionPlugin } from "./rules/admonition.js";
11
12
  import { blocksPlugin } from "./rules/blocks.js";
12
13
  import { contentTabsPlugin } from "./rules/content-tabs.js";
@@ -150,8 +151,25 @@ const EXTENSION_MAP = {
150
151
  },
151
152
  };
152
153
  /**
153
- * Build plugin options from a mkdocs.yml `markdown_extensions` array.
154
- * Each entry can be a string or an object with a single key.
154
+ * Build plugin options from a mkdocs.yml `markdown_extensions`
155
+ * declaration. MkDocs accepts two shapes — list (canonical) and
156
+ * mapping (FastAPI-style):
157
+ *
158
+ * markdown_extensions:
159
+ * - admonition
160
+ * - pymdownx.tabbed:
161
+ * alternate_style: true
162
+ *
163
+ * markdown_extensions:
164
+ * admonition: null
165
+ * pymdownx.tabbed:
166
+ * alternate_style: true
167
+ *
168
+ * We accept either, plus `null` / `undefined` (no extensions
169
+ * declared). Without the mapping-form handling, FastAPI-style
170
+ * mkdocs.yml silently skips PyMdownX Blocks (`/// note`, etc.) and
171
+ * downstream parses fall through to raw paragraphs — surfaced by
172
+ * the migrate-mkdocs FastAPI smoke.
155
173
  */
156
174
  export function configureFromMkdocs(extensions) {
157
175
  const opts = {
@@ -161,10 +179,28 @@ export function configureFromMkdocs(extensions) {
161
179
  snippets: false,
162
180
  annotations: false,
163
181
  };
164
- for (const ext of extensions) {
182
+ const entries = normalizeExtensions(extensions);
183
+ for (const ext of entries) {
165
184
  const name = typeof ext === "string" ? ext : Object.keys(ext)[0];
166
185
  EXTENSION_MAP[name]?.(opts);
167
186
  }
168
187
  return opts;
169
188
  }
170
- //# sourceMappingURL=index.js.map
189
+ /**
190
+ * Normalize the two forms of mkdocs.yml `markdown_extensions` into
191
+ * the canonical list shape EXTENSION_MAP expects.
192
+ */
193
+ function normalizeExtensions(raw) {
194
+ if (raw == null)
195
+ return [];
196
+ if (Array.isArray(raw)) {
197
+ return raw;
198
+ }
199
+ if (typeof raw === "object") {
200
+ // Mapping form → list of single-key objects (or bare strings
201
+ // when the value is null, matching the canonical bare-string
202
+ // entry).
203
+ return Object.entries(raw).map(([name, value]) => (value == null ? name : { [name]: value }));
204
+ }
205
+ return [];
206
+ }
@@ -14,4 +14,3 @@ import type { InlineNode } from "@dogsbay/types";
14
14
  * Convert markdown-it inline token children into structured InlineNode[].
15
15
  */
16
16
  export declare function walkInlineTokens(tokens: Token[] | null): InlineNode[];
17
- //# sourceMappingURL=inline-walker.d.ts.map
@@ -164,4 +164,3 @@ export function walkInlineTokens(tokens) {
164
164
  }
165
165
  return result;
166
166
  }
167
- //# sourceMappingURL=inline-walker.js.map
package/dist/loader.d.ts CHANGED
@@ -33,10 +33,9 @@ export declare function parseMkdocsMarkdown(source: string, md: MarkdownIt, opti
33
33
  collapse?: boolean;
34
34
  env?: Record<string, unknown>;
35
35
  youtubeEmbed?: boolean;
36
- diagrams?: boolean;
36
+ diagrams?: boolean | "mermaid-cli" | "pele";
37
37
  autodoc?: {
38
38
  sourceRoot: string;
39
39
  globalOptions?: Record<string, unknown>;
40
40
  };
41
41
  }): Promise<MkdocsParseResult>;
42
- //# sourceMappingURL=loader.d.ts.map
package/dist/loader.js CHANGED
@@ -37,9 +37,10 @@ export async function parseMkdocsMarkdown(source, md, options) {
37
37
  if (options?.youtubeEmbed) {
38
38
  liftYouTubeEmbeds(tree);
39
39
  }
40
- // Render diagram code blocks (mermaid etc.) to SVG (opt-in)
40
+ // Render diagram code blocks (mermaid etc.) to SVG (opt-in): mmdc, or Pele
41
+ // (`content.diagrams: pele`, plans/pele-diagrams.md)
41
42
  if (options?.diagrams) {
42
- await renderDiagrams(tree);
43
+ await renderDiagrams(tree, options.diagrams === "pele" ? "pele" : "mermaid-cli");
43
44
  }
44
45
  // Convert api-params HTML comments into structured TreeNodes
45
46
  convertApiParams(tree, md);
@@ -93,8 +94,7 @@ function convertApiParams(nodes, md) {
93
94
  */
94
95
  const DIRECTIVE_RE = /^:::\s+(\S+)\s*$/;
95
96
  async function processAutodocDirectives(nodes, options, md) {
96
- const { resolveIdentifier } = await import("./autodoc/module-resolver.js");
97
- const { symbolToTreeNode } = await import("./autodoc/tree-builder.js");
97
+ const { resolveIdentifier, symbolToTreeNode } = await import("@dogsbay/autodoc-python");
98
98
  const YAML = (await import("yaml")).default;
99
99
  // Defaults match mkdocstrings Python handler defaults.
100
100
  // Projects override these via mkdocs.yml handler options (passed as globalOptions).
@@ -183,14 +183,31 @@ const DIAGRAM_LANGS = new Set(["mermaid"]);
183
183
  * into { type: "diagram", props: { lang: "mermaid", code: "...", svg: "..." } }.
184
184
  * Source code is preserved for round-trip export and search.
185
185
  */
186
- async function renderDiagrams(nodes) {
186
+ async function renderDiagrams(nodes, engine) {
187
187
  let renderMermaidSvg;
188
+ const failed = [];
188
189
  try {
189
- const mod = await import("./renderers/mermaid.js");
190
- renderMermaidSvg = mod.renderMermaidSvg;
190
+ if (engine === "pele") {
191
+ // format-dogsbay-md's Pele renderer: one per page, so a repeated diagram gets its own ids
192
+ const { renderPeleSvg, diagramId } = await import("@dogsbay/format-dogsbay-md");
193
+ const seen = new Map();
194
+ renderMermaidSvg = async (code) => {
195
+ const base = diagramId(code);
196
+ const n = (seen.get(base) ?? 0) + 1;
197
+ seen.set(base, n);
198
+ const r = await renderPeleSvg(code, n === 1 ? base : `${base}-${n}`);
199
+ if ("error" in r)
200
+ failed.push(r.error);
201
+ return "svg" in r ? r.svg : null;
202
+ };
203
+ }
204
+ else {
205
+ const mod = await import("./renderers/mermaid.js");
206
+ renderMermaidSvg = mod.renderMermaidSvg;
207
+ }
191
208
  }
192
209
  catch (e) {
193
- console.warn("[diagrams] could not load mermaid renderer:", e);
210
+ console.warn("[diagrams] could not load the diagram renderer:", e);
194
211
  return;
195
212
  }
196
213
  async function walk(nodes) {
@@ -218,6 +235,9 @@ async function renderDiagrams(nodes) {
218
235
  }
219
236
  }
220
237
  await walk(nodes);
238
+ if (failed.length > 0) {
239
+ console.warn(`[diagrams] Pele could not draw ${failed.length} diagram(s), left as code blocks: ${failed[0].split("\n")[0].slice(0, 160)}`);
240
+ }
221
241
  }
222
242
  /**
223
243
  * Extract heading info for table of contents.
@@ -762,4 +782,3 @@ function slugify(text) {
762
782
  .trim()
763
783
  || "tab"; // fallback for titles that are entirely punctuation
764
784
  }
765
- //# sourceMappingURL=loader.js.map
package/dist/parse.d.ts CHANGED
@@ -9,4 +9,3 @@ export declare function parseToTree(md: MarkdownIt, src: string, envOverrides?:
9
9
  tree: TreeNode[];
10
10
  env: Record<string, unknown>;
11
11
  };
12
- //# sourceMappingURL=parse.d.ts.map
package/dist/parse.js CHANGED
@@ -43,4 +43,3 @@ export function parseToTree(md, src, envOverrides) {
43
43
  }
44
44
  return { tree, env };
45
45
  }
46
- //# sourceMappingURL=parse.js.map
@@ -6,4 +6,3 @@
6
6
  * identical diagrams across pages.
7
7
  */
8
8
  export declare function renderMermaidSvg(code: string): Promise<string | null>;
9
- //# sourceMappingURL=mermaid.d.ts.map
@@ -114,4 +114,3 @@ export async function renderMermaidSvg(code) {
114
114
  catch { /* ignore */ }
115
115
  }
116
116
  }
117
- //# sourceMappingURL=mermaid.js.map
@@ -3,4 +3,3 @@ import type MarkdownIt from "markdown-it";
3
3
  * Register the admonition block rule with markdown-it.
4
4
  */
5
5
  export declare function admonitionPlugin(md: MarkdownIt): void;
6
- //# sourceMappingURL=admonition.d.ts.map
@@ -70,4 +70,3 @@ export function admonitionPlugin(md) {
70
70
  alt: ["paragraph", "reference", "blockquote", "list"],
71
71
  });
72
72
  }
73
- //# sourceMappingURL=admonition.js.map
@@ -3,4 +3,3 @@ import type MarkdownIt from "markdown-it";
3
3
  * Register the annotations post-process rule with markdown-it.
4
4
  */
5
5
  export declare function annotationsPlugin(md: MarkdownIt): void;
6
- //# sourceMappingURL=annotations.d.ts.map
@@ -54,4 +54,3 @@ function annotationsRule(state) {
54
54
  export function annotationsPlugin(md) {
55
55
  md.core.ruler.push("annotations", annotationsRule);
56
56
  }
57
- //# sourceMappingURL=annotations.js.map
@@ -1,7 +1,6 @@
1
- import type { AutodocOptions } from "../autodoc/types.js";
1
+ import { type AutodocOptions } from "@dogsbay/autodoc-python";
2
2
  /**
3
3
  * Preprocess markdown source: replace ::: directives with generated API docs.
4
4
  * Called from the loader (async context) before md.parse().
5
5
  */
6
6
  export declare function preprocessAutodoc(source: string, options: AutodocOptions): Promise<string>;
7
- //# sourceMappingURL=autodoc.d.ts.map
@@ -1,6 +1,5 @@
1
1
  import YAML from "yaml";
2
- import { resolveIdentifier } from "../autodoc/module-resolver.js";
3
- import { generateMarkdown } from "../autodoc/markdown-generator.js";
2
+ import { resolveIdentifier, generateMarkdown, } from "@dogsbay/autodoc-python";
4
3
  /**
5
4
  * Match ::: identifier (mkdocstrings directive)
6
5
  */
@@ -99,4 +98,3 @@ export async function preprocessAutodoc(source, options) {
99
98
  }
100
99
  return changed ? lines.join("\n") : source;
101
100
  }
102
- //# sourceMappingURL=autodoc.js.map
@@ -3,4 +3,3 @@ import type MarkdownIt from "markdown-it";
3
3
  * Register the blocks syntax rule with markdown-it.
4
4
  */
5
5
  export declare function blocksPlugin(md: MarkdownIt): void;
6
- //# sourceMappingURL=blocks.d.ts.map
@@ -169,4 +169,3 @@ export function blocksPlugin(md) {
169
169
  alt: ["paragraph", "reference", "blockquote", "list"],
170
170
  });
171
171
  }
172
- //# sourceMappingURL=blocks.js.map
@@ -3,4 +3,3 @@ import type MarkdownIt from "markdown-it";
3
3
  * Register the content tabs block rule with markdown-it.
4
4
  */
5
5
  export declare function contentTabsPlugin(md: MarkdownIt): void;
6
- //# sourceMappingURL=content-tabs.d.ts.map
@@ -64,4 +64,3 @@ export function contentTabsPlugin(md) {
64
64
  alt: ["paragraph", "reference", "blockquote", "list"],
65
65
  });
66
66
  }
67
- //# sourceMappingURL=content-tabs.js.map
@@ -4,4 +4,3 @@ import type MarkdownIt from "markdown-it";
4
4
  * Opt-in only — conflicts with mkdocstrings ::: directive.
5
5
  */
6
6
  export declare function docusaurusAdmonitionsPlugin(md: MarkdownIt): void;
7
- //# sourceMappingURL=docusaurus-admonitions.d.ts.map
@@ -98,4 +98,3 @@ export function docusaurusAdmonitionsPlugin(md) {
98
98
  alt: ["paragraph", "reference", "blockquote", "list"],
99
99
  });
100
100
  }
101
- //# sourceMappingURL=docusaurus-admonitions.js.map
@@ -25,4 +25,3 @@ export declare function remapHighlights(hlNums: number[], lnNums: number[]): num
25
25
  * Runs after snippets but before normalize.
26
26
  */
27
27
  export declare function fileIncludePlugin(md: MarkdownIt, options: FileIncludeOptions): void;
28
- //# sourceMappingURL=file-include.d.ts.map
@@ -195,4 +195,3 @@ function createFileIncludeRule(options) {
195
195
  export function fileIncludePlugin(md, options) {
196
196
  md.core.ruler.before("normalize", "file_include", createFileIncludeRule(options));
197
197
  }
198
- //# sourceMappingURL=file-include.js.map
@@ -3,4 +3,3 @@ import type MarkdownIt from "markdown-it";
3
3
  * Register footnote block + inline rules with markdown-it.
4
4
  */
5
5
  export declare function footnotesPlugin(md: MarkdownIt): void;
6
- //# sourceMappingURL=footnotes.d.ts.map
@@ -158,4 +158,3 @@ export function footnotesPlugin(md) {
158
158
  return `<fn-ref data-label="${label}"></fn-ref>`;
159
159
  };
160
160
  }
161
- //# sourceMappingURL=footnotes.js.map
@@ -27,4 +27,3 @@ export declare function parseShortcode(raw: string): ParsedShortcode;
27
27
  */
28
28
  export declare function iconShortcodePlugin(md: MarkdownIt): void;
29
29
  export {};
30
- //# sourceMappingURL=icon-shortcode.d.ts.map
@@ -166,4 +166,3 @@ function iconShortcodeRule(state, silent) {
166
166
  export function iconShortcodePlugin(md) {
167
167
  md.inline.ruler.after("image", "icon_shortcode", iconShortcodeRule);
168
168
  }
169
- //# sourceMappingURL=icon-shortcode.js.map
@@ -3,4 +3,3 @@ import type MarkdownIt from "markdown-it";
3
3
  * Register the keyboard keys inline rule with markdown-it.
4
4
  */
5
5
  export declare function keysPlugin(md: MarkdownIt): void;
6
- //# sourceMappingURL=keys.d.ts.map
@@ -27,4 +27,3 @@ function keysRule(state, silent) {
27
27
  export function keysPlugin(md) {
28
28
  md.inline.ruler.before("escape", "keys", keysRule);
29
29
  }
30
- //# sourceMappingURL=keys.js.map
@@ -4,4 +4,3 @@ export interface LinkRewriteOptions {
4
4
  baseUrl?: string;
5
5
  }
6
6
  export declare function linkRewritePlugin(md: MarkdownIt, options?: LinkRewriteOptions): void;
7
- //# sourceMappingURL=link-rewrite.d.ts.map
@@ -90,4 +90,3 @@ function rewriteAssetPath(src, fileDir) {
90
90
  export function linkRewritePlugin(md, options = {}) {
91
91
  md.core.ruler.push("link_rewrite", createLinkRewriteRule(options));
92
92
  }
93
- //# sourceMappingURL=link-rewrite.js.map
@@ -11,4 +11,3 @@ import type MarkdownIt from "markdown-it";
11
11
  * Register math rules with markdown-it.
12
12
  */
13
13
  export declare function mathPlugin(md: MarkdownIt): void;
14
- //# sourceMappingURL=math.d.ts.map
@@ -111,4 +111,3 @@ export function mathPlugin(md) {
111
111
  alt: ["paragraph", "reference", "blockquote"],
112
112
  });
113
113
  }
114
- //# sourceMappingURL=math.js.map
@@ -3,4 +3,3 @@ import type MarkdownIt from "markdown-it";
3
3
  * Register the md_in_html core rule with markdown-it.
4
4
  */
5
5
  export declare function mdInHtmlPlugin(md: MarkdownIt): void;
6
- //# sourceMappingURL=md-in-html.d.ts.map
@@ -132,4 +132,3 @@ function mdInHtmlRule(state) {
132
132
  export function mdInHtmlPlugin(md) {
133
133
  md.core.ruler.push("md_in_html", mdInHtmlRule);
134
134
  }
135
- //# sourceMappingURL=md-in-html.js.map
@@ -7,4 +7,3 @@ export interface SnippetsOptions {
7
7
  * Register the snippets core rule with markdown-it.
8
8
  */
9
9
  export declare function snippetsPlugin(md: MarkdownIt, options: SnippetsOptions): void;
10
- //# sourceMappingURL=snippets.d.ts.map
@@ -106,4 +106,3 @@ function createSnippetsRule(options) {
106
106
  export function snippetsPlugin(md, options) {
107
107
  md.core.ruler.before("normalize", "snippets", createSnippetsRule(options));
108
108
  }
109
- //# sourceMappingURL=snippets.js.map
@@ -12,4 +12,3 @@ export interface TemplatesOptions {
12
12
  * Must run BEFORE all other core rules (templates expand first).
13
13
  */
14
14
  export declare function templatesPlugin(md: MarkdownIt, options: TemplatesOptions): void;
15
- //# sourceMappingURL=templates.d.ts.map
@@ -102,4 +102,3 @@ function createTemplatesRule(options) {
102
102
  export function templatesPlugin(md, options) {
103
103
  md.core.ruler.before("normalize", "templates", createTemplatesRule(options));
104
104
  }
105
- //# sourceMappingURL=templates.js.map
@@ -9,4 +9,3 @@ export interface VariantsOptions {
9
9
  * get their {* *} includes resolved.
10
10
  */
11
11
  export declare function variantsPlugin(md: MarkdownIt, options: VariantsOptions): void;
12
- //# sourceMappingURL=variants.d.ts.map
@@ -145,4 +145,3 @@ function createVariantsRule(options) {
145
145
  export function variantsPlugin(md, options) {
146
146
  md.core.ruler.before("normalize", "variants", createVariantsRule(options));
147
147
  }
148
- //# sourceMappingURL=variants.js.map
package/dist/tree.d.ts CHANGED
@@ -1,2 +1 @@
1
1
  export type { TreeNode } from "@dogsbay/types";
2
- //# sourceMappingURL=tree.d.ts.map
package/dist/tree.js CHANGED
@@ -1,2 +1 @@
1
1
  export {};
2
- //# sourceMappingURL=tree.js.map
@@ -15,4 +15,3 @@ export declare function findIndentedBlockEnd(state: StateBlock, startLine: numbe
15
15
  * become top-level blocks in the inner parse pass.
16
16
  */
17
17
  export declare function dedentAndTokenize(state: StateBlock, startLine: number, endLine: number, indent: number): void;
18
- //# sourceMappingURL=indent.d.ts.map
@@ -53,4 +53,3 @@ export function dedentAndTokenize(state, startLine, endLine, indent) {
53
53
  }
54
54
  state.blkIndent = savedBlkIndent;
55
55
  }
56
- //# sourceMappingURL=indent.js.map
@@ -16,4 +16,3 @@ export declare function resolveType(raw: string): string;
16
16
  * Auto-capitalize a type keyword for default title.
17
17
  */
18
18
  export declare function autoTitle(type: string): string;
19
- //# sourceMappingURL=types.d.ts.map
@@ -60,4 +60,3 @@ export function resolveType(raw) {
60
60
  export function autoTitle(type) {
61
61
  return type.charAt(0).toUpperCase() + type.slice(1);
62
62
  }
63
- //# sourceMappingURL=types.js.map
package/dist/walker.d.ts CHANGED
@@ -5,4 +5,3 @@ import type { TreeNode } from "./tree.js";
5
5
  * Handles open/close token pairs by recursively collecting children.
6
6
  */
7
7
  export declare function tokensToTree(tokens: Token[]): TreeNode[];
8
- //# sourceMappingURL=walker.d.ts.map
package/dist/walker.js CHANGED
@@ -190,4 +190,3 @@ function parseFenceInfo(info) {
190
190
  const lang = firstWord && !firstWord.includes("=") ? firstWord : null;
191
191
  return { lang, title, highlights, lineNumbers };
192
192
  }
193
- //# sourceMappingURL=walker.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dogsbay/format-mkdocs",
3
- "version": "0.2.0-beta.13",
3
+ "version": "0.2.0-beta.131",
4
4
  "description": "MkDocs format plugin for Dogsbay — import/export MkDocs projects via TreeNode[]",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -31,24 +31,25 @@
31
31
  "markdown-it": "^14.0.0"
32
32
  },
33
33
  "devDependencies": {
34
- "@mermaid-js/mermaid-cli": "^11.12.0",
34
+ "@mermaid-js/mermaid-cli": "^11.16.0",
35
35
  "@types/markdown-it": "^14.1.2",
36
- "@types/node": "^25.5.0",
36
+ "@types/node": "^25.9.5",
37
37
  "@types/nunjucks": "^3.2.6",
38
38
  "markdown-it": "^14.1.0",
39
- "tsx": "^4.21.0",
40
- "typescript": "^5.7.0",
41
- "vitest": "^3.0.0"
39
+ "tsx": "^4.23.1",
40
+ "typescript": "^5.9.3",
41
+ "vitest": "^4.1.10"
42
42
  },
43
43
  "license": "MIT",
44
44
  "dependencies": {
45
- "markdown-it": "^14.1.0",
46
- "markdown-it-deflist": "^3.0.0",
45
+ "markdown-it": "^14.3.0",
46
+ "markdown-it-deflist": "^3.0.1",
47
47
  "nunjucks": "^3.2.4",
48
- "tree-sitter-python": "^0.25.0",
49
- "web-tree-sitter": "^0.26.8",
50
- "yaml": "^2.8.3",
51
- "@dogsbay/types": "0.2.0-beta.13"
48
+ "yaml": "^2.9.0",
49
+ "@dogsbay/autodoc-python": "0.2.0-beta.131",
50
+ "@dogsbay/types": "0.2.0-beta.131",
51
+ "@dogsbay/format-dogsbay-md": "0.2.0-beta.131",
52
+ "@dogsbay/serialize-core": "0.2.0-beta.131"
52
53
  },
53
54
  "repository": {
54
55
  "type": "git",
@@ -1,6 +0,0 @@
1
- import type { SymbolInfo, AutodocDirectiveOptions } from "./types.js";
2
- /**
3
- * Generate markdown documentation for a symbol.
4
- */
5
- export declare function generateMarkdown(symbol: SymbolInfo, options?: AutodocDirectiveOptions): string;
6
- //# sourceMappingURL=markdown-generator.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"markdown-generator.d.ts","sourceRoot":"","sources":["../../src/autodoc/markdown-generator.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAa,uBAAuB,EAAE,MAAM,YAAY,CAAC;AAEjF;;GAEG;AACH,wBAAgB,gBAAgB,CAC9B,MAAM,EAAE,UAAU,EAClB,OAAO,GAAE,uBAA4B,GACpC,MAAM,CAaR"}