dogsbay 0.2.0-beta.84 → 0.2.0-beta.86
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/config/load.js +7 -1
- package/dist/config/schema.js +6 -0
- package/dist/config/to-astro-options.js +1 -0
- package/package.json +15 -15
package/dist/config/load.js
CHANGED
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
import { readFileSync, existsSync } from "node:fs";
|
|
10
10
|
import { extname, isAbsolute, resolve } from "node:path";
|
|
11
11
|
import { parse as parseYaml } from "yaml";
|
|
12
|
-
import { CURRENT_SCHEMA_VERSION, LLM_ACTIONS_PLACEMENTS, LLM_PROVIDER_NAMES, PALETTE_NAMES, } from "./schema.js";
|
|
12
|
+
import { CURRENT_SCHEMA_VERSION, LLM_ACTIONS_PLACEMENTS, LLM_PROVIDER_NAMES, PALETTE_NAMES, TOC_MODES, } from "./schema.js";
|
|
13
13
|
import { applyDefaults } from "./defaults.js";
|
|
14
14
|
/**
|
|
15
15
|
* Load + validate config at the given path. Returns a `DogsbayConfig`
|
|
@@ -79,6 +79,11 @@ function validate(parsed, sourcePath) {
|
|
|
79
79
|
if (obj.theme !== undefined && obj.theme !== "default" && obj.theme !== "material") {
|
|
80
80
|
throw new Error(`theme must be "default" or "material" in ${sourcePath}; got ${JSON.stringify(obj.theme)}`);
|
|
81
81
|
}
|
|
82
|
+
if (obj.toc !== undefined &&
|
|
83
|
+
!TOC_MODES.includes(obj.toc)) {
|
|
84
|
+
throw new Error(`toc must be one of ${TOC_MODES.map((t) => `"${t}"`).join(" | ")} ` +
|
|
85
|
+
`in ${sourcePath}; got ${JSON.stringify(obj.toc)}`);
|
|
86
|
+
}
|
|
82
87
|
if (obj.output !== undefined && typeof obj.output !== "string") {
|
|
83
88
|
throw new Error(`output must be a string path in ${sourcePath}; got ${describe(obj.output)}`);
|
|
84
89
|
}
|
|
@@ -105,6 +110,7 @@ function validate(parsed, sourcePath) {
|
|
|
105
110
|
schemaVersion: CURRENT_SCHEMA_VERSION,
|
|
106
111
|
site,
|
|
107
112
|
theme: obj.theme,
|
|
113
|
+
toc: obj.toc,
|
|
108
114
|
content,
|
|
109
115
|
output: obj.output,
|
|
110
116
|
deploy: obj.deploy,
|
package/dist/config/schema.js
CHANGED
|
@@ -21,6 +21,7 @@ export function configToAstroOptions(config) {
|
|
|
21
21
|
noindex: config.site.noindex,
|
|
22
22
|
nofollow: config.site.nofollow,
|
|
23
23
|
theme: config.theme,
|
|
24
|
+
toc: config.toc,
|
|
24
25
|
plausibleDomain: config.analytics?.plausible?.domain,
|
|
25
26
|
plausibleScriptUrl: config.analytics?.plausible?.scriptUrl,
|
|
26
27
|
deploy: config.deploy?.target,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dogsbay",
|
|
3
|
-
"version": "0.2.0-beta.
|
|
3
|
+
"version": "0.2.0-beta.86",
|
|
4
4
|
"description": "CLI for Dogsbay — scaffold, build, and serve documentation sites with markdown / MkDocs / Obsidian / OpenAPI sources",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -33,20 +33,20 @@
|
|
|
33
33
|
"picocolors": "^1.1.0",
|
|
34
34
|
"prompts": "^2.4.2",
|
|
35
35
|
"yaml": "^2.8.3",
|
|
36
|
-
"@dogsbay/autodoc-python": "0.2.0-beta.
|
|
37
|
-
"@dogsbay/format-mkdocs": "0.2.0-beta.
|
|
38
|
-
"@dogsbay/format-
|
|
39
|
-
"@dogsbay/format-obsidian": "0.2.0-beta.
|
|
40
|
-
"@dogsbay/format-
|
|
41
|
-
"@dogsbay/format-
|
|
42
|
-
"@dogsbay/format-docusaurus": "0.2.0-beta.
|
|
43
|
-
"@dogsbay/docusaurus-adapter-tigera": "0.2.0-beta.
|
|
44
|
-
"@dogsbay/format-dogsbay-md": "0.2.0-beta.
|
|
45
|
-
"@dogsbay/format-openapi": "0.2.0-beta.
|
|
46
|
-
"@dogsbay/adoc2md-modular": "0.2.0-beta.
|
|
47
|
-
"@dogsbay/format-asciidoc": "0.2.0-beta.
|
|
48
|
-
"@dogsbay/
|
|
49
|
-
"@dogsbay/
|
|
36
|
+
"@dogsbay/autodoc-python": "0.2.0-beta.86",
|
|
37
|
+
"@dogsbay/format-mkdocs": "0.2.0-beta.86",
|
|
38
|
+
"@dogsbay/format-mdx": "0.2.0-beta.86",
|
|
39
|
+
"@dogsbay/format-obsidian": "0.2.0-beta.86",
|
|
40
|
+
"@dogsbay/format-starlight": "0.2.0-beta.86",
|
|
41
|
+
"@dogsbay/format-astro": "0.2.0-beta.86",
|
|
42
|
+
"@dogsbay/format-docusaurus": "0.2.0-beta.86",
|
|
43
|
+
"@dogsbay/docusaurus-adapter-tigera": "0.2.0-beta.86",
|
|
44
|
+
"@dogsbay/format-dogsbay-md": "0.2.0-beta.86",
|
|
45
|
+
"@dogsbay/format-openapi": "0.2.0-beta.86",
|
|
46
|
+
"@dogsbay/adoc2md-modular": "0.2.0-beta.86",
|
|
47
|
+
"@dogsbay/format-asciidoc": "0.2.0-beta.86",
|
|
48
|
+
"@dogsbay/minja": "0.2.0-beta.86",
|
|
49
|
+
"@dogsbay/types": "0.2.0-beta.86"
|
|
50
50
|
},
|
|
51
51
|
"devDependencies": {
|
|
52
52
|
"@types/markdown-it": "^14.1.0",
|