@powerlines/plugin-automd 0.1.361 → 0.1.363

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@powerlines/plugin-automd",
3
- "version": "0.1.361",
3
+ "version": "0.1.363",
4
4
  "private": false,
5
5
  "description": "A Powerlines plugin to maintain a project's markdown files using AutoMD generators.",
6
6
  "keywords": ["automd", "powerlines", "storm-software", "powerlines-plugin"],
@@ -114,12 +114,12 @@
114
114
  "markdown-toc": "^1.2.0"
115
115
  },
116
116
  "devDependencies": {
117
- "@powerlines/plugin-plugin": "^0.12.312",
117
+ "@powerlines/plugin-plugin": "^0.12.314",
118
118
  "@types/node": "^25.5.0",
119
119
  "automd": "^0.4.3"
120
120
  },
121
121
  "peerDependencies": { "automd": ">=0.4.3" },
122
122
  "peerDependenciesMeta": { "automd": { "optional": false } },
123
123
  "publishConfig": { "access": "public" },
124
- "gitHead": "d00a8306c2e4bc7b8fd853b0f935b5ef5f32d845"
124
+ "gitHead": "c3243c1ec0fbacb4afd4bd3db20432f443334076"
125
125
  }
@@ -1,29 +0,0 @@
1
- //#region \0rolldown/runtime.js
2
- var __create = Object.create;
3
- var __defProp = Object.defineProperty;
4
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
- var __getOwnPropNames = Object.getOwnPropertyNames;
6
- var __getProtoOf = Object.getPrototypeOf;
7
- var __hasOwnProp = Object.prototype.hasOwnProperty;
8
- var __copyProps = (to, from, except, desc) => {
9
- if (from && typeof from === "object" || typeof from === "function") {
10
- for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
11
- key = keys[i];
12
- if (!__hasOwnProp.call(to, key) && key !== except) {
13
- __defProp(to, key, {
14
- get: ((k) => from[k]).bind(null, key),
15
- enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
16
- });
17
- }
18
- }
19
- }
20
- return to;
21
- };
22
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
23
- value: mod,
24
- enumerable: true
25
- }) : target, mod));
26
-
27
- //#endregion
28
-
29
- exports.__toESM = __toESM;
@@ -1,3 +0,0 @@
1
- import "node:module";
2
-
3
- export { };
package/dist/index.cjs DELETED
@@ -1,102 +0,0 @@
1
- Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: 'Module' } });
2
- const require_runtime = require('./_virtual/_rolldown/runtime.cjs');
3
- let _stryke_convert_to_array = require("@stryke/convert/to-array");
4
- let _stryke_fs_is_file = require("@stryke/fs/is-file");
5
- let _stryke_fs_list_files = require("@stryke/fs/list-files");
6
- let _stryke_path_append = require("@stryke/path/append");
7
- let _stryke_path_is_type = require("@stryke/path/is-type");
8
- let _stryke_path_join_paths = require("@stryke/path/join-paths");
9
- let _stryke_path_replace = require("@stryke/path/replace");
10
- let automd = require("automd");
11
- let c12 = require("c12");
12
- let defu = require("defu");
13
- defu = require_runtime.__toESM(defu);
14
- let markdown_toc = require("markdown-toc");
15
- markdown_toc = require_runtime.__toESM(markdown_toc);
16
-
17
- //#region src/index.ts
18
- /**
19
- * AutoMD Plugin
20
- *
21
- * @remarks
22
- * A Powerlines plugin to use the AutoMD markdown transformer during the prepare task.
23
- *
24
- * @see https://automd.unjs.io/
25
- *
26
- * @param options - The plugin options.
27
- * @returns A Powerlines plugin instance.
28
- */
29
- const plugin = (options = {}) => {
30
- return {
31
- name: "automd",
32
- async config() {
33
- const config = await (0, automd.loadConfig)((0, _stryke_path_join_paths.joinPaths)(this.workspaceConfig.workspaceRoot, this.config.root), options);
34
- if (!config.prefix || !Array.isArray(config.prefix)) config.prefix = (0, _stryke_convert_to_array.toArray)(config.prefix ?? []);
35
- if (!config.prefix.includes("automd")) config.prefix.push("automd");
36
- if (!config.prefix.includes("powerlines")) config.prefix.push("powerlines");
37
- return { automd: (0, defu.default)(config ?? {}, {
38
- configFile: options.configFile,
39
- allowIssues: true,
40
- dir: this.config.root,
41
- watch: false,
42
- input: "README.md",
43
- toc: {
44
- maxDepth: 6,
45
- bullets: "-"
46
- }
47
- }) };
48
- },
49
- async configResolved() {
50
- if (this.config.framework && !(0, _stryke_convert_to_array.toArray)(this.config.automd.prefix).includes(this.config.framework)) this.config.automd.prefix = (0, _stryke_convert_to_array.toArray)(this.config.automd.prefix).concat(this.config.framework);
51
- if (this.config.automd.configFile) {
52
- const { config } = await (0, c12.loadConfig)({
53
- cwd: this.config.automd.dir,
54
- configFile: this.config.automd.configFile,
55
- defaults: {
56
- ignore: [
57
- "**/node_modules",
58
- "**/dist",
59
- "**/.*"
60
- ],
61
- dir: this.config.automd.dir
62
- }
63
- });
64
- this.config.automd = (0, automd.resolveConfig)((0, defu.default)(this.config.automd, {
65
- ...config,
66
- prefix: (0, _stryke_convert_to_array.toArray)(config.prefix ?? [])
67
- }));
68
- }
69
- this.config.automd.input = (await Promise.all((0, _stryke_convert_to_array.toArray)(this.config.automd.input).map(async (input) => {
70
- if (input.includes("*")) return (0, _stryke_fs_list_files.listFiles)((0, _stryke_path_is_type.isAbsolutePath)(input) ? input : (0, _stryke_path_append.appendPath)(input, this.config.root), { ignore: this.config.automd.ignore });
71
- return (0, _stryke_path_is_type.isAbsolutePath)(input) ? input : (0, _stryke_path_append.appendPath)(input, this.config.root);
72
- }))).flat();
73
- if (this.config.automd.output && !(0, _stryke_path_is_type.isAbsolutePath)(this.config.automd.output)) this.config.automd.output = (0, _stryke_path_append.appendPath)(this.config.automd.output, this.config.root);
74
- this.config.automd.generators ??= {};
75
- if (this.config.automd.toc !== false) this.config.automd.generators.toc ??= {
76
- name: "toc",
77
- generate: (ctx) => {
78
- const opts = this.config.automd.toc ?? {};
79
- return { contents: (0, markdown_toc.default)(ctx.block.contents, {
80
- ...opts,
81
- maxdepth: opts.maxDepth,
82
- first1: opts.firstH1
83
- }).content };
84
- }
85
- };
86
- },
87
- async docs() {
88
- await Promise.all((0, _stryke_convert_to_array.toArray)(this.config.automd.input).map(async (input) => {
89
- const contents = await this.fs.read(input);
90
- if (contents) {
91
- const result = await (0, automd.transform)(contents, this.config.automd);
92
- if (result.hasIssues && this.config.automd.allowIssues === false) throw new Error(`AutoMD found issues in file "${input}". Please resolve the issues or set \`allowIssues\` to true in the plugin configuration to ignore them.`);
93
- if (result.hasChanged) await this.fs.write((0, _stryke_path_append.appendPath)(this.config.automd.output ? (0, _stryke_fs_is_file.isDirectory)(this.config.automd.output) ? (0, _stryke_path_replace.replacePath)(input, this.config.automd.output) : this.config.automd.output : input, this.config.root), result.contents);
94
- }
95
- }));
96
- }
97
- };
98
- };
99
-
100
- //#endregion
101
- exports.default = plugin;
102
- exports.plugin = plugin;
package/dist/index.d.cts DELETED
@@ -1,25 +0,0 @@
1
- import { TOCOptions, __ΩTOCOptions } from "./types/toc.cjs";
2
- import { AutoMDPluginContext, AutoMDPluginOptions, AutoMDPluginResolvedConfig, AutoMDPluginUserConfig, __ΩAutoMDPluginContext, __ΩAutoMDPluginOptions, __ΩAutoMDPluginResolvedConfig, __ΩAutoMDPluginUserConfig } from "./types/plugin.cjs";
3
- import { Plugin } from "powerlines";
4
-
5
- //#region src/index.d.ts
6
- declare module "powerlines" {
7
- interface Config {
8
- automd?: AutoMDPluginOptions;
9
- }
10
- }
11
- /**
12
- * AutoMD Plugin
13
- *
14
- * @remarks
15
- * A Powerlines plugin to use the AutoMD markdown transformer during the prepare task.
16
- *
17
- * @see https://automd.unjs.io/
18
- *
19
- * @param options - The plugin options.
20
- * @returns A Powerlines plugin instance.
21
- */
22
- declare const plugin: <TContext extends AutoMDPluginContext = AutoMDPluginContext>(options?: AutoMDPluginOptions) => Plugin<TContext>;
23
- //#endregion
24
- export { AutoMDPluginContext, AutoMDPluginOptions, AutoMDPluginResolvedConfig, AutoMDPluginUserConfig, TOCOptions, __ΩAutoMDPluginContext, __ΩAutoMDPluginOptions, __ΩAutoMDPluginResolvedConfig, __ΩAutoMDPluginUserConfig, __ΩTOCOptions, plugin as default, plugin };
25
- //# sourceMappingURL=index.d.cts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.cts","names":[],"sources":["../src/index.ts"],"mappings":";;;;;;YA+CY,MAAA;IACR,MAAA,GAAS,mBAAA;EAAA;AAAA;;;;;;;;;AAeb;;;cAAa,MAAA,oBACM,mBAAA,GAAsB,mBAAA,EAEvC,OAAA,GAAS,mBAAA,KACR,MAAA,CAAO,QAAA"}
package/dist/index.d.mts DELETED
@@ -1,25 +0,0 @@
1
- import { TOCOptions, __ΩTOCOptions } from "./types/toc.mjs";
2
- import { AutoMDPluginContext, AutoMDPluginOptions, AutoMDPluginResolvedConfig, AutoMDPluginUserConfig, __ΩAutoMDPluginContext, __ΩAutoMDPluginOptions, __ΩAutoMDPluginResolvedConfig, __ΩAutoMDPluginUserConfig } from "./types/plugin.mjs";
3
- import { Plugin } from "powerlines";
4
-
5
- //#region src/index.d.ts
6
- declare module "powerlines" {
7
- interface Config {
8
- automd?: AutoMDPluginOptions;
9
- }
10
- }
11
- /**
12
- * AutoMD Plugin
13
- *
14
- * @remarks
15
- * A Powerlines plugin to use the AutoMD markdown transformer during the prepare task.
16
- *
17
- * @see https://automd.unjs.io/
18
- *
19
- * @param options - The plugin options.
20
- * @returns A Powerlines plugin instance.
21
- */
22
- declare const plugin: <TContext extends AutoMDPluginContext = AutoMDPluginContext>(options?: AutoMDPluginOptions) => Plugin<TContext>;
23
- //#endregion
24
- export { AutoMDPluginContext, AutoMDPluginOptions, AutoMDPluginResolvedConfig, AutoMDPluginUserConfig, TOCOptions, __ΩAutoMDPluginContext, __ΩAutoMDPluginOptions, __ΩAutoMDPluginResolvedConfig, __ΩAutoMDPluginUserConfig, __ΩTOCOptions, plugin as default, plugin };
25
- //# sourceMappingURL=index.d.mts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.mts","names":[],"sources":["../src/index.ts"],"mappings":";;;;;;YA+CY,MAAA;IACR,MAAA,GAAS,mBAAA;EAAA;AAAA;;;;;;;;;AAeb;;;cAAa,MAAA,oBACM,mBAAA,GAAsB,mBAAA,EAEvC,OAAA,GAAS,mBAAA,KACR,MAAA,CAAO,QAAA"}
package/dist/index.mjs DELETED
@@ -1,98 +0,0 @@
1
- import { toArray } from "@stryke/convert/to-array";
2
- import { isDirectory } from "@stryke/fs/is-file";
3
- import { listFiles } from "@stryke/fs/list-files";
4
- import { appendPath } from "@stryke/path/append";
5
- import { isAbsolutePath } from "@stryke/path/is-type";
6
- import { joinPaths } from "@stryke/path/join-paths";
7
- import { replacePath } from "@stryke/path/replace";
8
- import { loadConfig, resolveConfig, transform } from "automd";
9
- import { loadConfig as loadConfig$1 } from "c12";
10
- import defu from "defu";
11
- import toc from "markdown-toc";
12
-
13
- //#region src/index.ts
14
- /**
15
- * AutoMD Plugin
16
- *
17
- * @remarks
18
- * A Powerlines plugin to use the AutoMD markdown transformer during the prepare task.
19
- *
20
- * @see https://automd.unjs.io/
21
- *
22
- * @param options - The plugin options.
23
- * @returns A Powerlines plugin instance.
24
- */
25
- const plugin = (options = {}) => {
26
- return {
27
- name: "automd",
28
- async config() {
29
- const config = await loadConfig(joinPaths(this.workspaceConfig.workspaceRoot, this.config.root), options);
30
- if (!config.prefix || !Array.isArray(config.prefix)) config.prefix = toArray(config.prefix ?? []);
31
- if (!config.prefix.includes("automd")) config.prefix.push("automd");
32
- if (!config.prefix.includes("powerlines")) config.prefix.push("powerlines");
33
- return { automd: defu(config ?? {}, {
34
- configFile: options.configFile,
35
- allowIssues: true,
36
- dir: this.config.root,
37
- watch: false,
38
- input: "README.md",
39
- toc: {
40
- maxDepth: 6,
41
- bullets: "-"
42
- }
43
- }) };
44
- },
45
- async configResolved() {
46
- if (this.config.framework && !toArray(this.config.automd.prefix).includes(this.config.framework)) this.config.automd.prefix = toArray(this.config.automd.prefix).concat(this.config.framework);
47
- if (this.config.automd.configFile) {
48
- const { config } = await loadConfig$1({
49
- cwd: this.config.automd.dir,
50
- configFile: this.config.automd.configFile,
51
- defaults: {
52
- ignore: [
53
- "**/node_modules",
54
- "**/dist",
55
- "**/.*"
56
- ],
57
- dir: this.config.automd.dir
58
- }
59
- });
60
- this.config.automd = resolveConfig(defu(this.config.automd, {
61
- ...config,
62
- prefix: toArray(config.prefix ?? [])
63
- }));
64
- }
65
- this.config.automd.input = (await Promise.all(toArray(this.config.automd.input).map(async (input) => {
66
- if (input.includes("*")) return listFiles(isAbsolutePath(input) ? input : appendPath(input, this.config.root), { ignore: this.config.automd.ignore });
67
- return isAbsolutePath(input) ? input : appendPath(input, this.config.root);
68
- }))).flat();
69
- if (this.config.automd.output && !isAbsolutePath(this.config.automd.output)) this.config.automd.output = appendPath(this.config.automd.output, this.config.root);
70
- this.config.automd.generators ??= {};
71
- if (this.config.automd.toc !== false) this.config.automd.generators.toc ??= {
72
- name: "toc",
73
- generate: (ctx) => {
74
- const opts = this.config.automd.toc ?? {};
75
- return { contents: toc(ctx.block.contents, {
76
- ...opts,
77
- maxdepth: opts.maxDepth,
78
- first1: opts.firstH1
79
- }).content };
80
- }
81
- };
82
- },
83
- async docs() {
84
- await Promise.all(toArray(this.config.automd.input).map(async (input) => {
85
- const contents = await this.fs.read(input);
86
- if (contents) {
87
- const result = await transform(contents, this.config.automd);
88
- if (result.hasIssues && this.config.automd.allowIssues === false) throw new Error(`AutoMD found issues in file "${input}". Please resolve the issues or set \`allowIssues\` to true in the plugin configuration to ignore them.`);
89
- if (result.hasChanged) await this.fs.write(appendPath(this.config.automd.output ? isDirectory(this.config.automd.output) ? replacePath(input, this.config.automd.output) : this.config.automd.output : input, this.config.root), result.contents);
90
- }
91
- }));
92
- }
93
- };
94
- };
95
-
96
- //#endregion
97
- export { plugin as default, plugin };
98
- //# sourceMappingURL=index.mjs.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.mjs","names":["loadConfigFile"],"sources":["../src/index.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Powerlines\n\n This code was released as part of the Powerlines project. Powerlines\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/powerlines.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/powerlines\n Documentation: https://docs.stormsoftware.com/projects/powerlines\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { toArray } from \"@stryke/convert/to-array\";\nimport { isDirectory } from \"@stryke/fs/is-file\";\nimport { listFiles } from \"@stryke/fs/list-files\";\nimport { appendPath } from \"@stryke/path/append\";\nimport { isAbsolutePath } from \"@stryke/path/is-type\";\nimport { joinPaths } from \"@stryke/path/join-paths\";\nimport { replacePath } from \"@stryke/path/replace\";\nimport {\n Config,\n GenerateContext,\n GenerateResult,\n loadConfig,\n resolveConfig,\n transform\n} from \"automd\";\nimport { loadConfig as loadConfigFile } from \"c12\";\nimport defu from \"defu\";\nimport toc from \"markdown-toc\";\nimport type { Plugin } from \"powerlines\";\nimport {\n AutoMDPluginContext,\n AutoMDPluginOptions,\n AutoMDPluginUserConfig\n} from \"./types/plugin\";\nimport { TOCOptions } from \"./types/toc\";\n\nexport * from \"./types\";\n\ndeclare module \"powerlines\" {\n interface Config {\n automd?: AutoMDPluginOptions;\n }\n}\n\n/**\n * AutoMD Plugin\n *\n * @remarks\n * A Powerlines plugin to use the AutoMD markdown transformer during the prepare task.\n *\n * @see https://automd.unjs.io/\n *\n * @param options - The plugin options.\n * @returns A Powerlines plugin instance.\n */\nexport const plugin = <\n TContext extends AutoMDPluginContext = AutoMDPluginContext\n>(\n options: AutoMDPluginOptions = {}\n): Plugin<TContext> => {\n return {\n name: \"automd\",\n async config() {\n const config = await loadConfig(\n joinPaths(this.workspaceConfig.workspaceRoot, this.config.root),\n options\n );\n\n if (!config.prefix || !Array.isArray(config.prefix)) {\n config.prefix = toArray(config.prefix ?? []);\n }\n\n if (!config.prefix.includes(\"automd\")) {\n config.prefix.push(\"automd\");\n }\n if (!config.prefix.includes(\"powerlines\")) {\n config.prefix.push(\"powerlines\");\n }\n\n return {\n automd: defu(config ?? {}, {\n configFile: options.configFile,\n allowIssues: true,\n dir: this.config.root,\n watch: false,\n input: \"README.md\",\n toc: {\n maxDepth: 6,\n bullets: \"-\"\n }\n })\n } as Partial<AutoMDPluginUserConfig>;\n },\n async configResolved() {\n if (\n this.config.framework &&\n !toArray(this.config.automd.prefix).includes(this.config.framework)\n ) {\n this.config.automd.prefix = toArray(this.config.automd.prefix).concat(\n this.config.framework\n );\n }\n\n if (this.config.automd.configFile) {\n const { config } = await loadConfigFile<Config>({\n cwd: this.config.automd.dir,\n configFile: this.config.automd.configFile,\n defaults: {\n ignore: [\"**/node_modules\", \"**/dist\", \"**/.*\"],\n dir: this.config.automd.dir\n }\n });\n\n this.config.automd = resolveConfig(\n defu(this.config.automd, {\n ...config,\n prefix: toArray(config.prefix ?? [])\n }) as Config\n );\n }\n\n this.config.automd.input = (\n await Promise.all(\n toArray(this.config.automd.input).map(async input => {\n if (input.includes(\"*\")) {\n return listFiles(\n isAbsolutePath(input)\n ? input\n : appendPath(input, this.config.root),\n {\n ignore: this.config.automd.ignore\n }\n );\n }\n\n return isAbsolutePath(input)\n ? input\n : appendPath(input, this.config.root);\n })\n )\n ).flat();\n\n if (\n this.config.automd.output &&\n !isAbsolutePath(this.config.automd.output)\n ) {\n this.config.automd.output = appendPath(\n this.config.automd.output,\n this.config.root\n );\n }\n\n this.config.automd.generators ??= {};\n\n if (this.config.automd.toc !== false) {\n this.config.automd.generators.toc ??= {\n name: \"toc\",\n generate: (ctx: GenerateContext): GenerateResult => {\n const opts = (this.config.automd.toc ?? {}) as TOCOptions;\n\n return {\n contents: toc(ctx.block.contents, {\n ...opts,\n maxdepth: opts.maxDepth,\n first1: opts.firstH1\n }).content\n };\n }\n };\n }\n },\n async docs() {\n await Promise.all(\n toArray(this.config.automd.input).map(async input => {\n const contents = await this.fs.read(input);\n if (contents) {\n const result = await transform(contents, this.config.automd);\n if (result.hasIssues && this.config.automd.allowIssues === false) {\n throw new Error(\n `AutoMD found issues in file \"${\n input\n }\". Please resolve the issues or set \\`allowIssues\\` to true in the plugin configuration to ignore them.`\n );\n }\n\n if (result.hasChanged) {\n await this.fs.write(\n appendPath(\n this.config.automd.output\n ? isDirectory(this.config.automd.output)\n ? replacePath(input, this.config.automd.output)\n : this.config.automd.output\n : input,\n this.config.root\n ),\n result.contents\n );\n }\n }\n })\n );\n }\n };\n};\n\nexport default plugin;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AA+DA,MAAa,UAGX,UAA+B,EAAE,KACZ;AACrB,QAAO;EACL,MAAM;EACN,MAAM,SAAS;GACb,MAAM,SAAS,MAAM,WACnB,UAAU,KAAK,gBAAgB,eAAe,KAAK,OAAO,KAAK,EAC/D,QACD;AAED,OAAI,CAAC,OAAO,UAAU,CAAC,MAAM,QAAQ,OAAO,OAAO,CACjD,QAAO,SAAS,QAAQ,OAAO,UAAU,EAAE,CAAC;AAG9C,OAAI,CAAC,OAAO,OAAO,SAAS,SAAS,CACnC,QAAO,OAAO,KAAK,SAAS;AAE9B,OAAI,CAAC,OAAO,OAAO,SAAS,aAAa,CACvC,QAAO,OAAO,KAAK,aAAa;AAGlC,UAAO,EACL,QAAQ,KAAK,UAAU,EAAE,EAAE;IACzB,YAAY,QAAQ;IACpB,aAAa;IACb,KAAK,KAAK,OAAO;IACjB,OAAO;IACP,OAAO;IACP,KAAK;KACH,UAAU;KACV,SAAS;KACV;IACF,CAAC,EACH;;EAEH,MAAM,iBAAiB;AACrB,OACE,KAAK,OAAO,aACZ,CAAC,QAAQ,KAAK,OAAO,OAAO,OAAO,CAAC,SAAS,KAAK,OAAO,UAAU,CAEnE,MAAK,OAAO,OAAO,SAAS,QAAQ,KAAK,OAAO,OAAO,OAAO,CAAC,OAC7D,KAAK,OAAO,UACb;AAGH,OAAI,KAAK,OAAO,OAAO,YAAY;IACjC,MAAM,EAAE,WAAW,MAAMA,aAAuB;KAC9C,KAAK,KAAK,OAAO,OAAO;KACxB,YAAY,KAAK,OAAO,OAAO;KAC/B,UAAU;MACR,QAAQ;OAAC;OAAmB;OAAW;OAAQ;MAC/C,KAAK,KAAK,OAAO,OAAO;MACzB;KACF,CAAC;AAEF,SAAK,OAAO,SAAS,cACnB,KAAK,KAAK,OAAO,QAAQ;KACvB,GAAG;KACH,QAAQ,QAAQ,OAAO,UAAU,EAAE,CAAC;KACrC,CAAC,CACH;;AAGH,QAAK,OAAO,OAAO,SACjB,MAAM,QAAQ,IACZ,QAAQ,KAAK,OAAO,OAAO,MAAM,CAAC,IAAI,OAAM,UAAS;AACnD,QAAI,MAAM,SAAS,IAAI,CACrB,QAAO,UACL,eAAe,MAAM,GACjB,QACA,WAAW,OAAO,KAAK,OAAO,KAAK,EACvC,EACE,QAAQ,KAAK,OAAO,OAAO,QAC5B,CACF;AAGH,WAAO,eAAe,MAAM,GACxB,QACA,WAAW,OAAO,KAAK,OAAO,KAAK;KACvC,CACH,EACD,MAAM;AAER,OACE,KAAK,OAAO,OAAO,UACnB,CAAC,eAAe,KAAK,OAAO,OAAO,OAAO,CAE1C,MAAK,OAAO,OAAO,SAAS,WAC1B,KAAK,OAAO,OAAO,QACnB,KAAK,OAAO,KACb;AAGH,QAAK,OAAO,OAAO,eAAe,EAAE;AAEpC,OAAI,KAAK,OAAO,OAAO,QAAQ,MAC7B,MAAK,OAAO,OAAO,WAAW,QAAQ;IACpC,MAAM;IACN,WAAW,QAAyC;KAClD,MAAM,OAAQ,KAAK,OAAO,OAAO,OAAO,EAAE;AAE1C,YAAO,EACL,UAAU,IAAI,IAAI,MAAM,UAAU;MAChC,GAAG;MACH,UAAU,KAAK;MACf,QAAQ,KAAK;MACd,CAAC,CAAC,SACJ;;IAEJ;;EAGL,MAAM,OAAO;AACX,SAAM,QAAQ,IACZ,QAAQ,KAAK,OAAO,OAAO,MAAM,CAAC,IAAI,OAAM,UAAS;IACnD,MAAM,WAAW,MAAM,KAAK,GAAG,KAAK,MAAM;AAC1C,QAAI,UAAU;KACZ,MAAM,SAAS,MAAM,UAAU,UAAU,KAAK,OAAO,OAAO;AAC5D,SAAI,OAAO,aAAa,KAAK,OAAO,OAAO,gBAAgB,MACzD,OAAM,IAAI,MACR,gCACE,MACD,yGACF;AAGH,SAAI,OAAO,WACT,OAAM,KAAK,GAAG,MACZ,WACE,KAAK,OAAO,OAAO,SACf,YAAY,KAAK,OAAO,OAAO,OAAO,GACpC,YAAY,OAAO,KAAK,OAAO,OAAO,OAAO,GAC7C,KAAK,OAAO,OAAO,SACrB,OACJ,KAAK,OAAO,KACb,EACD,OAAO,SACR;;KAGL,CACH;;EAEJ"}
File without changes
@@ -1,3 +0,0 @@
1
- import { TOCOptions, __ΩTOCOptions } from "./toc.cjs";
2
- import { AutoMDPluginContext, AutoMDPluginOptions, AutoMDPluginResolvedConfig, AutoMDPluginUserConfig, __ΩAutoMDPluginContext, __ΩAutoMDPluginOptions, __ΩAutoMDPluginResolvedConfig, __ΩAutoMDPluginUserConfig } from "./plugin.cjs";
3
- export { AutoMDPluginContext, AutoMDPluginOptions, AutoMDPluginResolvedConfig, AutoMDPluginUserConfig, TOCOptions, __ΩAutoMDPluginContext, __ΩAutoMDPluginOptions, __ΩAutoMDPluginResolvedConfig, __ΩAutoMDPluginUserConfig, __ΩTOCOptions };
@@ -1,3 +0,0 @@
1
- import { TOCOptions, __ΩTOCOptions } from "./toc.mjs";
2
- import { AutoMDPluginContext, AutoMDPluginOptions, AutoMDPluginResolvedConfig, AutoMDPluginUserConfig, __ΩAutoMDPluginContext, __ΩAutoMDPluginOptions, __ΩAutoMDPluginResolvedConfig, __ΩAutoMDPluginUserConfig } from "./plugin.mjs";
3
- export { AutoMDPluginContext, AutoMDPluginOptions, AutoMDPluginResolvedConfig, AutoMDPluginUserConfig, TOCOptions, __ΩAutoMDPluginContext, __ΩAutoMDPluginOptions, __ΩAutoMDPluginResolvedConfig, __ΩAutoMDPluginUserConfig, __ΩTOCOptions };
@@ -1 +0,0 @@
1
- export { };
File without changes
@@ -1,50 +0,0 @@
1
- import { TOCOptions } from "./toc.cjs";
2
- import { PluginContext, ResolvedConfig, UserConfig } from "powerlines";
3
- import { Config } from "automd";
4
-
5
- //#region src/types/plugin.d.ts
6
- type AutoMDPluginOptions = Omit<Config, "dir" | "watch" | "onWatch" | "prefix"> & {
7
- /**
8
- * Path to the AutoMD configuration file.
9
- *
10
- * @remarks
11
- * If not provided, the plugin will use the default AutoMD configuration resolution mechanism.
12
- */
13
- configFile?: string;
14
- /**
15
- * An indicator specifying whether or not issues found by AutoMD during the prepare task are considered fatal.
16
- *
17
- * @defaultValue true
18
- */
19
- allowIssues?: boolean;
20
- /**
21
- * Alternate prefix strings to use for finding generators
22
- *
23
- * @remarks
24
- * By default, AutoMD looks for generators with the "automd" prefix, so that any `<!-- automd:generator [...args] --> ... <!-- /automd -->` comments will be picked up. If you want to use different prefixes (for example, to avoid conflicts with other tools), you would provide a value like "myPrefix" and AutoMD would also look for `<!-- myPrefix:generator [...args] --> ... <!-- /myPrefix -->` comments.
25
- *
26
- * @defaultValue ["automd", "powerlines", "\{framework\}"]
27
- */
28
- prefix?: string | string[];
29
- /**
30
- * Table of Contents generator options
31
- *
32
- * @remarks
33
- * If set to `false`, the built-in Table of Contents generator will be disabled.
34
- */
35
- toc?: false | TOCOptions;
36
- };
37
- type AutoMDPluginUserConfig = UserConfig & {
38
- automd?: Config & Pick<AutoMDPluginOptions, "configFile" | "allowIssues" | "toc">;
39
- };
40
- type AutoMDPluginResolvedConfig = ResolvedConfig & {
41
- automd: Config & Pick<AutoMDPluginOptions, "configFile" | "allowIssues" | "toc">;
42
- };
43
- type AutoMDPluginContext<TResolvedConfig extends AutoMDPluginResolvedConfig = AutoMDPluginResolvedConfig> = PluginContext<TResolvedConfig>;
44
- declare type __ΩAutoMDPluginOptions = any[];
45
- declare type __ΩAutoMDPluginUserConfig = any[];
46
- declare type __ΩAutoMDPluginResolvedConfig = any[];
47
- declare type __ΩAutoMDPluginContext = any[];
48
- //#endregion
49
- export { AutoMDPluginContext, AutoMDPluginOptions, AutoMDPluginResolvedConfig, AutoMDPluginUserConfig, __ΩAutoMDPluginContext, __ΩAutoMDPluginOptions, __ΩAutoMDPluginResolvedConfig, __ΩAutoMDPluginUserConfig };
50
- //# sourceMappingURL=plugin.d.cts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"plugin.d.cts","names":[],"sources":["../../src/types/plugin.ts"],"mappings":";;;;;KAsBY,mBAAA,GAAsB,IAAA,CAChC,MAAA;;AADF;;;;;EAUE,UAAA;EAyBwB;;;;;EAlBxB,WAAA;EAUA;;;;;AAWF;;;EAXE,MAAA;EAYS;;;;;;EAJT,GAAA,WAAc,UAAA;AAAA;AAAA,KAGJ,sBAAA,GAAyB,UAAA;EACnC,MAAA,GAAS,MAAA,GACP,IAAA,CAAK,mBAAA;AAAA;AAAA,KAGG,0BAAA,GAA6B,cAAA;EACvC,MAAA,EAAQ,MAAA,GACN,IAAA,CAAK,mBAAA;AAAA;AAAA,KAGG,mBAAA,yBACc,0BAAA,GACtB,0BAAA,IACA,aAAA,CAAc,eAAA;AAAA"}
@@ -1,50 +0,0 @@
1
- import { TOCOptions } from "./toc.mjs";
2
- import { Config } from "automd";
3
- import { PluginContext, ResolvedConfig, UserConfig } from "powerlines";
4
-
5
- //#region src/types/plugin.d.ts
6
- type AutoMDPluginOptions = Omit<Config, "dir" | "watch" | "onWatch" | "prefix"> & {
7
- /**
8
- * Path to the AutoMD configuration file.
9
- *
10
- * @remarks
11
- * If not provided, the plugin will use the default AutoMD configuration resolution mechanism.
12
- */
13
- configFile?: string;
14
- /**
15
- * An indicator specifying whether or not issues found by AutoMD during the prepare task are considered fatal.
16
- *
17
- * @defaultValue true
18
- */
19
- allowIssues?: boolean;
20
- /**
21
- * Alternate prefix strings to use for finding generators
22
- *
23
- * @remarks
24
- * By default, AutoMD looks for generators with the "automd" prefix, so that any `<!-- automd:generator [...args] --> ... <!-- /automd -->` comments will be picked up. If you want to use different prefixes (for example, to avoid conflicts with other tools), you would provide a value like "myPrefix" and AutoMD would also look for `<!-- myPrefix:generator [...args] --> ... <!-- /myPrefix -->` comments.
25
- *
26
- * @defaultValue ["automd", "powerlines", "\{framework\}"]
27
- */
28
- prefix?: string | string[];
29
- /**
30
- * Table of Contents generator options
31
- *
32
- * @remarks
33
- * If set to `false`, the built-in Table of Contents generator will be disabled.
34
- */
35
- toc?: false | TOCOptions;
36
- };
37
- type AutoMDPluginUserConfig = UserConfig & {
38
- automd?: Config & Pick<AutoMDPluginOptions, "configFile" | "allowIssues" | "toc">;
39
- };
40
- type AutoMDPluginResolvedConfig = ResolvedConfig & {
41
- automd: Config & Pick<AutoMDPluginOptions, "configFile" | "allowIssues" | "toc">;
42
- };
43
- type AutoMDPluginContext<TResolvedConfig extends AutoMDPluginResolvedConfig = AutoMDPluginResolvedConfig> = PluginContext<TResolvedConfig>;
44
- declare type __ΩAutoMDPluginOptions = any[];
45
- declare type __ΩAutoMDPluginUserConfig = any[];
46
- declare type __ΩAutoMDPluginResolvedConfig = any[];
47
- declare type __ΩAutoMDPluginContext = any[];
48
- //#endregion
49
- export { AutoMDPluginContext, AutoMDPluginOptions, AutoMDPluginResolvedConfig, AutoMDPluginUserConfig, __ΩAutoMDPluginContext, __ΩAutoMDPluginOptions, __ΩAutoMDPluginResolvedConfig, __ΩAutoMDPluginUserConfig };
50
- //# sourceMappingURL=plugin.d.mts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"plugin.d.mts","names":[],"sources":["../../src/types/plugin.ts"],"mappings":";;;;;KAsBY,mBAAA,GAAsB,IAAA,CAChC,MAAA;;AADF;;;;;EAUE,UAAA;EAyBwB;;;;;EAlBxB,WAAA;EAUA;;;;;AAWF;;;EAXE,MAAA;EAYS;;;;;;EAJT,GAAA,WAAc,UAAA;AAAA;AAAA,KAGJ,sBAAA,GAAyB,UAAA;EACnC,MAAA,GAAS,MAAA,GACP,IAAA,CAAK,mBAAA;AAAA;AAAA,KAGG,0BAAA,GAA6B,cAAA;EACvC,MAAA,EAAQ,MAAA,GACN,IAAA,CAAK,mBAAA;AAAA;AAAA,KAGG,mBAAA,yBACc,0BAAA,GACtB,0BAAA,IACA,aAAA,CAAc,eAAA;AAAA"}
@@ -1 +0,0 @@
1
- export { };
File without changes
@@ -1,35 +0,0 @@
1
- //#region src/types/toc.d.ts
2
- interface TOCOptions {
3
- /**
4
- * A slugify function to generate slugs for the headings.
5
- */
6
- slugify?: (str: string) => string;
7
- /**
8
- * The maximum depth of headings to include in the TOC.
9
- *
10
- * @defaultValue 6
11
- */
12
- maxDepth?: number;
13
- /**
14
- * Whether to include the first H1 heading in the TOC.
15
- */
16
- firstH1?: boolean;
17
- /**
18
- * The bullet character to use for list items in the TOC.
19
- *
20
- * @defaultValue "-"
21
- */
22
- bullets?: string;
23
- /**
24
- * A prefix to add to each heading in the TOC.
25
- */
26
- prefix?: string;
27
- /**
28
- * A filter function to determine which headings to include in the TOC.
29
- */
30
- filter?: (str: string, level: number) => boolean;
31
- }
32
- declare type __ΩTOCOptions = any[];
33
- //#endregion
34
- export { TOCOptions, __ΩTOCOptions };
35
- //# sourceMappingURL=toc.d.cts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"toc.d.cts","names":[],"sources":["../../src/types/toc.ts"],"mappings":";UAkBiB,UAAA;EAAA;;;EAIf,OAAA,IAAW,GAAA;EAAX;;;;;EAOA,QAAA;EAsBA;;;EAjBA,OAAA;EAiBoC;;;;;EAVpC,OAAA;;;;EAKA,MAAA;;;;EAKA,MAAA,IAAU,GAAA,UAAa,KAAA;AAAA;AAAA"}
@@ -1,35 +0,0 @@
1
- //#region src/types/toc.d.ts
2
- interface TOCOptions {
3
- /**
4
- * A slugify function to generate slugs for the headings.
5
- */
6
- slugify?: (str: string) => string;
7
- /**
8
- * The maximum depth of headings to include in the TOC.
9
- *
10
- * @defaultValue 6
11
- */
12
- maxDepth?: number;
13
- /**
14
- * Whether to include the first H1 heading in the TOC.
15
- */
16
- firstH1?: boolean;
17
- /**
18
- * The bullet character to use for list items in the TOC.
19
- *
20
- * @defaultValue "-"
21
- */
22
- bullets?: string;
23
- /**
24
- * A prefix to add to each heading in the TOC.
25
- */
26
- prefix?: string;
27
- /**
28
- * A filter function to determine which headings to include in the TOC.
29
- */
30
- filter?: (str: string, level: number) => boolean;
31
- }
32
- declare type __ΩTOCOptions = any[];
33
- //#endregion
34
- export { TOCOptions, __ΩTOCOptions };
35
- //# sourceMappingURL=toc.d.mts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"toc.d.mts","names":[],"sources":["../../src/types/toc.ts"],"mappings":";UAkBiB,UAAA;EAAA;;;EAIf,OAAA,IAAW,GAAA;EAAX;;;;;EAOA,QAAA;EAsBA;;;EAjBA,OAAA;EAiBoC;;;;;EAVpC,OAAA;;;;EAKA,MAAA;;;;EAKA,MAAA,IAAU,GAAA,UAAa,KAAA;AAAA;AAAA"}
@@ -1 +0,0 @@
1
- export { };