@powerlines/plugin-alloy 0.15.1 → 0.15.2
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/builtin-file-BDc5-4_L.mjs +43 -0
- package/dist/{builtin-file-CIBzJ6jy.d.mts → builtin-file-CUUY0eVB.d.cts} +4 -4
- package/dist/{builtin-file-DLVCgiye.cjs → builtin-file-Cey2cJy9.cjs} +20 -14
- package/dist/{builtin-file-C-AX3Zai.d.cts → builtin-file-EfQHLZ8F.d.mts} +2 -2
- package/dist/{capnp-CbBwObRD.d.mts → capnp-DkidugOV.d.mts} +1 -1
- package/dist/{components-IB9A7YaB.d.mts → components-ixU_ICbr.d.mts} +5 -5
- package/dist/{context-D-UHaRnr.d.mts → context-BApo1nhP.d.mts} +1 -1
- package/dist/{context-0Spyyas6.d.mts → context-DXy7MPku.d.mts} +0 -2
- package/dist/core/components/index.cjs +3 -3
- package/dist/core/components/index.d.cts +3 -3
- package/dist/core/components/index.d.mts +5 -5
- package/dist/core/components/index.mjs +3 -3
- package/dist/core/components/output.cjs +1 -1
- package/dist/core/components/output.d.cts +1 -1
- package/dist/core/components/output.d.mts +2 -2
- package/dist/core/components/output.mjs +1 -1
- package/dist/core/components/single-line-comment.cjs +1 -1
- package/dist/core/components/single-line-comment.d.cts +1 -1
- package/dist/core/components/single-line-comment.d.mts +3 -3
- package/dist/core/components/single-line-comment.mjs +1 -1
- package/dist/core/components/source-file.cjs +1 -1
- package/dist/core/components/source-file.d.cts +1 -1
- package/dist/core/components/source-file.d.mts +3 -3
- package/dist/core/components/source-file.mjs +1 -1
- package/dist/core/contexts/context.d.mts +2 -2
- package/dist/core/contexts/index.d.mts +4 -4
- package/dist/core/contexts/reflection.d.mts +3 -3
- package/dist/core/index.cjs +3 -3
- package/dist/core/index.d.cts +3 -3
- package/dist/core/index.d.mts +7 -7
- package/dist/core/index.mjs +3 -3
- package/dist/{dynamic-import-statement-DO0ewx0l.d.cts → dynamic-import-statement-BhY2a13r.d.cts} +2 -2
- package/dist/{dynamic-import-statement-DoTHSt57.mjs → dynamic-import-statement-CWK5I_yt.mjs} +2 -6
- package/dist/{dynamic-import-statement-tQyMvDe7.d.mts → dynamic-import-statement-D6f1SnIf.d.mts} +2 -2
- package/dist/{dynamic-import-statement-JVLyMPXr.cjs → dynamic-import-statement-DVGp5Cvq.cjs} +2 -6
- package/dist/{entry-file-BgTZY0YN.d.mts → entry-file-B46yUHra.d.mts} +4 -4
- package/dist/{entry-file-BEHDg4dR.d.cts → entry-file-DSW6oClr.d.cts} +3 -3
- package/dist/{entry-file-BA75rAwb.cjs → entry-file-DijEelFv.cjs} +10 -7
- package/dist/{entry-file-Bw1mgMP3.mjs → entry-file-DtjJPVZY.mjs} +10 -7
- package/dist/helpers/capnp.d.mts +2 -2
- package/dist/helpers/index.d.mts +2 -2
- package/dist/index.cjs +61 -230
- package/dist/index.d.cts +9 -9
- package/dist/index.d.mts +19 -19
- package/dist/index.mjs +60 -224
- package/dist/markdown/components/index.cjs +4 -4
- package/dist/markdown/components/index.d.cts +3 -3
- package/dist/markdown/components/index.d.mts +5 -5
- package/dist/markdown/components/index.mjs +4 -4
- package/dist/markdown/components/markdown-file.cjs +3 -3
- package/dist/markdown/components/markdown-file.d.cts +2 -2
- package/dist/markdown/components/markdown-file.d.mts +4 -4
- package/dist/markdown/components/markdown-file.mjs +3 -3
- package/dist/markdown/components/markdown-table.cjs +1 -1
- package/dist/markdown/components/markdown-table.d.cts +1 -1
- package/dist/markdown/components/markdown-table.d.mts +3 -3
- package/dist/markdown/components/markdown-table.mjs +1 -1
- package/dist/markdown/index.cjs +4 -4
- package/dist/markdown/index.d.cts +3 -3
- package/dist/markdown/index.d.mts +5 -5
- package/dist/markdown/index.mjs +4 -4
- package/dist/markdown-file-BVSRcpXO.cjs +128 -0
- package/dist/{markdown-file-BjhcGybj.d.cts → markdown-file-C72aDdPi.d.cts} +4 -4
- package/dist/markdown-file-Clh5iU1_.mjs +116 -0
- package/dist/{markdown-file-BhMk-_1z.d.mts → markdown-file-DIkSXG43.d.mts} +5 -5
- package/dist/{markdown-table-DxL06EFD.d.mts → markdown-table-3trTm6Ef.d.mts} +5 -5
- package/dist/{markdown-table-DFaNSBRn.cjs → markdown-table-B40X-Kp1.cjs} +49 -28
- package/dist/{markdown-table-BUxH6aRh.mjs → markdown-table-D-YnljE7.mjs} +49 -28
- package/dist/{markdown-table-DhDqQVt_.d.cts → markdown-table-ZiuZZY5T.d.cts} +4 -4
- package/dist/{output-Cos2Dz1j.d.mts → output-BKZklKl1.d.mts} +1 -1
- package/dist/{output-CnofBsl0.cjs → output-BlHZS50Y.cjs} +19 -12
- package/dist/{output-C2C9L6Ho.d.cts → output-BmJnrELo.d.cts} +2 -2
- package/dist/{output-DEdXZ94G.mjs → output-CNnPjQlW.mjs} +19 -12
- package/dist/{plugin-DmLCIqx0.d.mts → plugin-LknisCLa.d.mts} +3 -3
- package/dist/{reflection-BiWgd3An.d.mts → reflection-DLJST1Z7.d.mts} +1 -1
- package/dist/{single-line-comment-C5CtHQhi.mjs → single-line-comment-Biwa95Py.mjs} +6 -4
- package/dist/{single-line-comment-CuFhTxLD.d.cts → single-line-comment-CYYKKXc2.d.cts} +2 -2
- package/dist/{single-line-comment-DRU3a4Qy.d.mts → single-line-comment-DGby6ABI.d.mts} +1 -1
- package/dist/{single-line-comment-BMPq6OR0.cjs → single-line-comment-DvU69OGj.cjs} +6 -4
- package/dist/{source-file-dpP3BrmV.d.mts → source-file-B2MkzzGR.d.mts} +4 -4
- package/dist/{source-file-DK_PJbR-.d.cts → source-file-BrxGhMOh.d.cts} +2 -2
- package/dist/{source-file-DTd1KgD5.cjs → source-file-DK_nFwAK.cjs} +10 -6
- package/dist/{source-file-CCYwl5pI.mjs → source-file-Dna2E0ro.mjs} +10 -6
- package/dist/tsdoc-B0TNs3dK.cjs +576 -0
- package/dist/{tsdoc-DzCqaUAX.d.mts → tsdoc-QH5nHvck.d.mts} +1 -1
- package/dist/tsdoc-XXdq_9iS.mjs +456 -0
- package/dist/{tsdoc-reflection-BbLwFCUm.d.mts → tsdoc-reflection-Bhk9KvVe.d.mts} +1 -1
- package/dist/tsdoc-reflection-BizVi_gn.cjs +188 -0
- package/dist/tsdoc-reflection-IWtPMJjw.mjs +170 -0
- package/dist/types/components.d.mts +2 -2
- package/dist/types/index.d.mts +3 -3
- package/dist/types/plugin.d.mts +2 -2
- package/dist/typescript/components/builtin-file.cjs +5 -5
- package/dist/typescript/components/builtin-file.d.cts +3 -3
- package/dist/typescript/components/builtin-file.d.mts +6 -6
- package/dist/typescript/components/builtin-file.mjs +5 -5
- package/dist/typescript/components/dynamic-import-statement.cjs +1 -1
- package/dist/typescript/components/dynamic-import-statement.d.cts +1 -1
- package/dist/typescript/components/dynamic-import-statement.d.mts +1 -1
- package/dist/typescript/components/dynamic-import-statement.mjs +1 -1
- package/dist/typescript/components/entry-file.cjs +4 -4
- package/dist/typescript/components/entry-file.d.cts +3 -3
- package/dist/typescript/components/entry-file.d.mts +5 -5
- package/dist/typescript/components/entry-file.mjs +4 -4
- package/dist/typescript/components/index.cjs +10 -10
- package/dist/typescript/components/index.d.cts +5 -5
- package/dist/typescript/components/index.d.mts +11 -11
- package/dist/typescript/components/index.mjs +10 -10
- package/dist/typescript/components/tsdoc-reflection.cjs +2 -2
- package/dist/typescript/components/tsdoc-reflection.d.mts +4 -4
- package/dist/typescript/components/tsdoc-reflection.mjs +2 -2
- package/dist/typescript/components/tsdoc.cjs +1 -1
- package/dist/typescript/components/tsdoc.d.mts +3 -3
- package/dist/typescript/components/tsdoc.mjs +1 -1
- package/dist/typescript/components/typescript-file.cjs +3 -3
- package/dist/typescript/components/typescript-file.d.cts +2 -2
- package/dist/typescript/components/typescript-file.d.mts +4 -4
- package/dist/typescript/components/typescript-file.mjs +3 -3
- package/dist/typescript/components/typescript-interface.cjs +3 -3
- package/dist/typescript/components/typescript-interface.d.mts +3 -3
- package/dist/typescript/components/typescript-interface.mjs +3 -3
- package/dist/typescript/components/typescript-object.cjs +3 -3
- package/dist/typescript/components/typescript-object.d.mts +3 -3
- package/dist/typescript/components/typescript-object.mjs +3 -3
- package/dist/typescript/index.cjs +10 -10
- package/dist/typescript/index.d.cts +5 -5
- package/dist/typescript/index.d.mts +11 -11
- package/dist/typescript/index.mjs +10 -10
- package/dist/{typescript-file-BjpHsTUl.d.cts → typescript-file-BK8Ohw9s.d.cts} +1 -1
- package/dist/{typescript-file-CxHfiE2u.d.mts → typescript-file-CFNjXsdz.d.mts} +2 -2
- package/dist/typescript-file-CLL-ELi0.mjs +190 -0
- package/dist/typescript-file-HsAUWnQY.cjs +208 -0
- package/dist/{typescript-interface-Codd49Sl.cjs → typescript-interface-DwHJ9in_.cjs} +38 -23
- package/dist/{typescript-interface-AydoCmGY.mjs → typescript-interface-FVDsEsu0.mjs} +38 -23
- package/dist/{typescript-interface-D8u8bgxN.d.mts → typescript-interface-XIwwFVdf.d.mts} +1 -1
- package/dist/{typescript-object-qZFhyXJU.d.mts → typescript-object-BTawaBJa.d.mts} +1 -1
- package/dist/{typescript-object-DOrJkpcM.cjs → typescript-object-D8MHeFId.cjs} +75 -45
- package/dist/{typescript-object-C-BmpHfk.mjs → typescript-object-Ju07nQg9.mjs} +75 -45
- package/package.json +11 -11
- package/dist/builtin-file-CkwxD4el.mjs +0 -37
- package/dist/markdown-file-BFbbzD59.mjs +0 -90
- package/dist/markdown-file-CzGNj_Ex.cjs +0 -102
- package/dist/tsdoc-BFPYF-Fh.cjs +0 -487
- package/dist/tsdoc-BmyOQBxT.mjs +0 -367
- package/dist/tsdoc-reflection-3hSdGY1e.mjs +0 -97
- package/dist/tsdoc-reflection-BQN8iUG1.cjs +0 -115
- package/dist/typescript-file-6Y81yLyB.cjs +0 -157
- package/dist/typescript-file-y6oF016h.mjs +0 -139
|
@@ -0,0 +1,128 @@
|
|
|
1
|
+
const require_chunk = require('./chunk-CbDLau6x.cjs');
|
|
2
|
+
const require_context = require('./context-BIduC1bB.cjs');
|
|
3
|
+
const require_single_line_comment = require('./single-line-comment-DvU69OGj.cjs');
|
|
4
|
+
const require_source_file = require('./source-file-DK_nFwAK.cjs');
|
|
5
|
+
let __alloy_js_core_jsx_runtime = require("@alloy-js/core/jsx-runtime");
|
|
6
|
+
let __alloy_js_core = require("@alloy-js/core");
|
|
7
|
+
let __stryke_string_format_title_case = require("@stryke/string-format/title-case");
|
|
8
|
+
let __alloy_js_markdown = require("@alloy-js/markdown");
|
|
9
|
+
|
|
10
|
+
//#region src/markdown/components/markdown-file.tsx
|
|
11
|
+
/**
|
|
12
|
+
* A base component representing a Powerlines generated markdown source file.
|
|
13
|
+
*
|
|
14
|
+
* @param props - The properties for the source file.
|
|
15
|
+
* @returns The rendered source file component.
|
|
16
|
+
*/
|
|
17
|
+
function MarkdownFile(props) {
|
|
18
|
+
const [{ children, preset }, rest] = (0, __alloy_js_core.splitProps)(props, ["children", "preset"]);
|
|
19
|
+
const nodeContext = (0, __alloy_js_core.getContext)();
|
|
20
|
+
nodeContext.meta ??= {};
|
|
21
|
+
nodeContext.meta.output = { preset };
|
|
22
|
+
return (0, __alloy_js_core_jsx_runtime.createComponent)(require_source_file.SourceFile, (0, __alloy_js_core_jsx_runtime.mergeProps)({ get header() {
|
|
23
|
+
return (0, __alloy_js_core_jsx_runtime.createComponent)(MarkdownFileHeader, {});
|
|
24
|
+
} }, rest, {
|
|
25
|
+
filetype: "md",
|
|
26
|
+
reference: __alloy_js_markdown.Link,
|
|
27
|
+
get children() {
|
|
28
|
+
return (0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Show, {
|
|
29
|
+
get when() {
|
|
30
|
+
return Boolean(children);
|
|
31
|
+
},
|
|
32
|
+
children
|
|
33
|
+
});
|
|
34
|
+
}
|
|
35
|
+
}));
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* Renders the header for a Powerlines Typescript source file.
|
|
39
|
+
*
|
|
40
|
+
* @param props - The properties for the source file header.
|
|
41
|
+
* @returns The rendered source file header.
|
|
42
|
+
*/
|
|
43
|
+
function MarkdownFileHeader(props) {
|
|
44
|
+
const [{ children, disableEslint = true, disableBiome = true, disablePrettier = false }] = (0, __alloy_js_core.splitProps)(props, [
|
|
45
|
+
"children",
|
|
46
|
+
"disableEslint",
|
|
47
|
+
"disableBiome",
|
|
48
|
+
"disablePrettier"
|
|
49
|
+
]);
|
|
50
|
+
const context = require_context.usePowerlines();
|
|
51
|
+
return [
|
|
52
|
+
(0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Show, {
|
|
53
|
+
get when() {
|
|
54
|
+
return Boolean(disableEslint);
|
|
55
|
+
},
|
|
56
|
+
get children() {
|
|
57
|
+
return [(0, __alloy_js_core_jsx_runtime.createComponent)(require_single_line_comment.SingleLineComment, {
|
|
58
|
+
variant: "markdown",
|
|
59
|
+
children: "eslint-disable"
|
|
60
|
+
}), (0, __alloy_js_core_jsx_runtime.createIntrinsic)("hbr", {})];
|
|
61
|
+
}
|
|
62
|
+
}),
|
|
63
|
+
(0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Show, {
|
|
64
|
+
get when() {
|
|
65
|
+
return Boolean(disablePrettier);
|
|
66
|
+
},
|
|
67
|
+
get children() {
|
|
68
|
+
return [(0, __alloy_js_core_jsx_runtime.createComponent)(require_single_line_comment.SingleLineComment, {
|
|
69
|
+
variant: "markdown",
|
|
70
|
+
children: "prettier-ignore"
|
|
71
|
+
}), (0, __alloy_js_core_jsx_runtime.createIntrinsic)("hbr", {})];
|
|
72
|
+
}
|
|
73
|
+
}),
|
|
74
|
+
(0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Show, {
|
|
75
|
+
get when() {
|
|
76
|
+
return Boolean(disableBiome);
|
|
77
|
+
},
|
|
78
|
+
get children() {
|
|
79
|
+
return [(0, __alloy_js_core_jsx_runtime.createComponent)(require_single_line_comment.SingleLineComment, {
|
|
80
|
+
variant: "markdown",
|
|
81
|
+
children: "biome-ignore lint: disable"
|
|
82
|
+
}), (0, __alloy_js_core_jsx_runtime.createIntrinsic)("hbr", {})];
|
|
83
|
+
}
|
|
84
|
+
}),
|
|
85
|
+
(0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Show, {
|
|
86
|
+
get when() {
|
|
87
|
+
return Boolean(disableEslint) || Boolean(disablePrettier) || Boolean(disableBiome);
|
|
88
|
+
},
|
|
89
|
+
get children() {
|
|
90
|
+
return (0, __alloy_js_core_jsx_runtime.createIntrinsic)("hbr", {});
|
|
91
|
+
}
|
|
92
|
+
}),
|
|
93
|
+
(0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Show, {
|
|
94
|
+
get when() {
|
|
95
|
+
return Boolean(children);
|
|
96
|
+
},
|
|
97
|
+
get children() {
|
|
98
|
+
return [children, (0, __alloy_js_core_jsx_runtime.createIntrinsic)("hbr", {})];
|
|
99
|
+
}
|
|
100
|
+
}),
|
|
101
|
+
(0, __alloy_js_core_jsx_runtime.createComponent)(require_single_line_comment.SingleLineComment, {
|
|
102
|
+
variant: "markdown",
|
|
103
|
+
get children() {
|
|
104
|
+
return __alloy_js_core.code`Generated by ${(0, __stryke_string_format_title_case.titleCase)(context?.config.framework) || "Powerlines"}`;
|
|
105
|
+
}
|
|
106
|
+
}),
|
|
107
|
+
(0, __alloy_js_core_jsx_runtime.createIntrinsic)("hbr", {}),
|
|
108
|
+
(0, __alloy_js_core_jsx_runtime.createComponent)(require_single_line_comment.SingleLineComment, {
|
|
109
|
+
variant: "markdown",
|
|
110
|
+
children: __alloy_js_core.code`NOTE: Do not edit this file manually - it will be overwritten automatically by the "prepare" command`
|
|
111
|
+
}),
|
|
112
|
+
(0, __alloy_js_core_jsx_runtime.createIntrinsic)("hbr", {})
|
|
113
|
+
];
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
//#endregion
|
|
117
|
+
Object.defineProperty(exports, 'MarkdownFile', {
|
|
118
|
+
enumerable: true,
|
|
119
|
+
get: function () {
|
|
120
|
+
return MarkdownFile;
|
|
121
|
+
}
|
|
122
|
+
});
|
|
123
|
+
Object.defineProperty(exports, 'MarkdownFileHeader', {
|
|
124
|
+
enumerable: true,
|
|
125
|
+
get: function () {
|
|
126
|
+
return MarkdownFileHeader;
|
|
127
|
+
}
|
|
128
|
+
});
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { n as ComponentProps, p as SourceFileHeaderProps } from "./components-C8Qs2PB0.cjs";
|
|
2
|
-
import { n as SourceFileProps$1 } from "./source-file-
|
|
3
|
-
import * as
|
|
2
|
+
import { n as SourceFileProps$1 } from "./source-file-BrxGhMOh.cjs";
|
|
3
|
+
import * as _alloy_js_core9 from "@alloy-js/core";
|
|
4
4
|
|
|
5
5
|
//#region src/markdown/components/markdown-file.d.ts
|
|
6
6
|
type MarkdownFileProps = Omit<SourceFileProps$1, "filetype"> & ComponentProps;
|
|
@@ -10,14 +10,14 @@ type MarkdownFileProps = Omit<SourceFileProps$1, "filetype"> & ComponentProps;
|
|
|
10
10
|
* @param props - The properties for the source file.
|
|
11
11
|
* @returns The rendered source file component.
|
|
12
12
|
*/
|
|
13
|
-
declare function MarkdownFile(props: MarkdownFileProps):
|
|
13
|
+
declare function MarkdownFile(props: MarkdownFileProps): _alloy_js_core9.Children;
|
|
14
14
|
/**
|
|
15
15
|
* Renders the header for a Powerlines Typescript source file.
|
|
16
16
|
*
|
|
17
17
|
* @param props - The properties for the source file header.
|
|
18
18
|
* @returns The rendered source file header.
|
|
19
19
|
*/
|
|
20
|
-
declare function MarkdownFileHeader(props: SourceFileHeaderProps):
|
|
20
|
+
declare function MarkdownFileHeader(props: SourceFileHeaderProps): _alloy_js_core9.Children;
|
|
21
21
|
declare type __ΩMarkdownFileProps = any[];
|
|
22
22
|
//#endregion
|
|
23
23
|
export { __ΩMarkdownFileProps as i, MarkdownFileHeader as n, MarkdownFileProps as r, MarkdownFile as t };
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
import { n as usePowerlines } from "./context-Cx38_mgI.mjs";
|
|
2
|
+
import { t as SingleLineComment } from "./single-line-comment-Biwa95Py.mjs";
|
|
3
|
+
import { t as SourceFile } from "./source-file-Dna2E0ro.mjs";
|
|
4
|
+
import { createComponent, createIntrinsic, mergeProps } from "@alloy-js/core/jsx-runtime";
|
|
5
|
+
import { Show, code, getContext, splitProps } from "@alloy-js/core";
|
|
6
|
+
import { titleCase } from "@stryke/string-format/title-case";
|
|
7
|
+
import { Link } from "@alloy-js/markdown";
|
|
8
|
+
|
|
9
|
+
//#region src/markdown/components/markdown-file.tsx
|
|
10
|
+
/**
|
|
11
|
+
* A base component representing a Powerlines generated markdown source file.
|
|
12
|
+
*
|
|
13
|
+
* @param props - The properties for the source file.
|
|
14
|
+
* @returns The rendered source file component.
|
|
15
|
+
*/
|
|
16
|
+
function MarkdownFile(props) {
|
|
17
|
+
const [{ children, preset }, rest] = splitProps(props, ["children", "preset"]);
|
|
18
|
+
const nodeContext = getContext();
|
|
19
|
+
nodeContext.meta ??= {};
|
|
20
|
+
nodeContext.meta.output = { preset };
|
|
21
|
+
return createComponent(SourceFile, mergeProps({ get header() {
|
|
22
|
+
return createComponent(MarkdownFileHeader, {});
|
|
23
|
+
} }, rest, {
|
|
24
|
+
filetype: "md",
|
|
25
|
+
reference: Link,
|
|
26
|
+
get children() {
|
|
27
|
+
return createComponent(Show, {
|
|
28
|
+
get when() {
|
|
29
|
+
return Boolean(children);
|
|
30
|
+
},
|
|
31
|
+
children
|
|
32
|
+
});
|
|
33
|
+
}
|
|
34
|
+
}));
|
|
35
|
+
}
|
|
36
|
+
/**
|
|
37
|
+
* Renders the header for a Powerlines Typescript source file.
|
|
38
|
+
*
|
|
39
|
+
* @param props - The properties for the source file header.
|
|
40
|
+
* @returns The rendered source file header.
|
|
41
|
+
*/
|
|
42
|
+
function MarkdownFileHeader(props) {
|
|
43
|
+
const [{ children, disableEslint = true, disableBiome = true, disablePrettier = false }] = splitProps(props, [
|
|
44
|
+
"children",
|
|
45
|
+
"disableEslint",
|
|
46
|
+
"disableBiome",
|
|
47
|
+
"disablePrettier"
|
|
48
|
+
]);
|
|
49
|
+
const context = usePowerlines();
|
|
50
|
+
return [
|
|
51
|
+
createComponent(Show, {
|
|
52
|
+
get when() {
|
|
53
|
+
return Boolean(disableEslint);
|
|
54
|
+
},
|
|
55
|
+
get children() {
|
|
56
|
+
return [createComponent(SingleLineComment, {
|
|
57
|
+
variant: "markdown",
|
|
58
|
+
children: "eslint-disable"
|
|
59
|
+
}), createIntrinsic("hbr", {})];
|
|
60
|
+
}
|
|
61
|
+
}),
|
|
62
|
+
createComponent(Show, {
|
|
63
|
+
get when() {
|
|
64
|
+
return Boolean(disablePrettier);
|
|
65
|
+
},
|
|
66
|
+
get children() {
|
|
67
|
+
return [createComponent(SingleLineComment, {
|
|
68
|
+
variant: "markdown",
|
|
69
|
+
children: "prettier-ignore"
|
|
70
|
+
}), createIntrinsic("hbr", {})];
|
|
71
|
+
}
|
|
72
|
+
}),
|
|
73
|
+
createComponent(Show, {
|
|
74
|
+
get when() {
|
|
75
|
+
return Boolean(disableBiome);
|
|
76
|
+
},
|
|
77
|
+
get children() {
|
|
78
|
+
return [createComponent(SingleLineComment, {
|
|
79
|
+
variant: "markdown",
|
|
80
|
+
children: "biome-ignore lint: disable"
|
|
81
|
+
}), createIntrinsic("hbr", {})];
|
|
82
|
+
}
|
|
83
|
+
}),
|
|
84
|
+
createComponent(Show, {
|
|
85
|
+
get when() {
|
|
86
|
+
return Boolean(disableEslint) || Boolean(disablePrettier) || Boolean(disableBiome);
|
|
87
|
+
},
|
|
88
|
+
get children() {
|
|
89
|
+
return createIntrinsic("hbr", {});
|
|
90
|
+
}
|
|
91
|
+
}),
|
|
92
|
+
createComponent(Show, {
|
|
93
|
+
get when() {
|
|
94
|
+
return Boolean(children);
|
|
95
|
+
},
|
|
96
|
+
get children() {
|
|
97
|
+
return [children, createIntrinsic("hbr", {})];
|
|
98
|
+
}
|
|
99
|
+
}),
|
|
100
|
+
createComponent(SingleLineComment, {
|
|
101
|
+
variant: "markdown",
|
|
102
|
+
get children() {
|
|
103
|
+
return code`Generated by ${titleCase(context?.config.framework) || "Powerlines"}`;
|
|
104
|
+
}
|
|
105
|
+
}),
|
|
106
|
+
createIntrinsic("hbr", {}),
|
|
107
|
+
createComponent(SingleLineComment, {
|
|
108
|
+
variant: "markdown",
|
|
109
|
+
children: code`NOTE: Do not edit this file manually - it will be overwritten automatically by the "prepare" command`
|
|
110
|
+
}),
|
|
111
|
+
createIntrinsic("hbr", {})
|
|
112
|
+
];
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
//#endregion
|
|
116
|
+
export { MarkdownFileHeader as n, MarkdownFile as t };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { n as ComponentProps, p as SourceFileHeaderProps } from "./components-
|
|
2
|
-
import { n as SourceFileProps$1 } from "./source-file-
|
|
3
|
-
import * as
|
|
1
|
+
import { n as ComponentProps, p as SourceFileHeaderProps } from "./components-ixU_ICbr.mjs";
|
|
2
|
+
import { n as SourceFileProps$1 } from "./source-file-B2MkzzGR.mjs";
|
|
3
|
+
import * as _alloy_js_core13 from "@alloy-js/core";
|
|
4
4
|
|
|
5
5
|
//#region src/markdown/components/markdown-file.d.ts
|
|
6
6
|
type MarkdownFileProps = Omit<SourceFileProps$1, "filetype"> & ComponentProps;
|
|
@@ -10,14 +10,14 @@ type MarkdownFileProps = Omit<SourceFileProps$1, "filetype"> & ComponentProps;
|
|
|
10
10
|
* @param props - The properties for the source file.
|
|
11
11
|
* @returns The rendered source file component.
|
|
12
12
|
*/
|
|
13
|
-
declare function MarkdownFile(props: MarkdownFileProps):
|
|
13
|
+
declare function MarkdownFile(props: MarkdownFileProps): _alloy_js_core13.Children;
|
|
14
14
|
/**
|
|
15
15
|
* Renders the header for a Powerlines Typescript source file.
|
|
16
16
|
*
|
|
17
17
|
* @param props - The properties for the source file header.
|
|
18
18
|
* @returns The rendered source file header.
|
|
19
19
|
*/
|
|
20
|
-
declare function MarkdownFileHeader(props: SourceFileHeaderProps):
|
|
20
|
+
declare function MarkdownFileHeader(props: SourceFileHeaderProps): _alloy_js_core13.Children;
|
|
21
21
|
declare type __ΩMarkdownFileProps = any[];
|
|
22
22
|
//#endregion
|
|
23
23
|
export { __ΩMarkdownFileProps as i, MarkdownFileHeader as n, MarkdownFileProps as r, MarkdownFile as t };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { n as ComponentProps } from "./components-
|
|
1
|
+
import { n as ComponentProps } from "./components-ixU_ICbr.mjs";
|
|
2
2
|
import { n as MarkdownTableColumnContextInterface } from "./markdown-table-kFQoqKQt.mjs";
|
|
3
|
-
import * as
|
|
3
|
+
import * as _alloy_js_core9 from "@alloy-js/core";
|
|
4
4
|
|
|
5
5
|
//#region src/markdown/components/markdown-table.d.ts
|
|
6
6
|
interface MarkdownTableProps<T extends Record<string, any> = Record<string, any>> extends ComponentProps {
|
|
@@ -9,18 +9,18 @@ interface MarkdownTableProps<T extends Record<string, any> = Record<string, any>
|
|
|
9
9
|
/**
|
|
10
10
|
* Component that provides a context for rendering markdown tables.
|
|
11
11
|
*/
|
|
12
|
-
declare function MarkdownTable<T extends Record<string, any> = Record<string, any>>(props: MarkdownTableProps<T>):
|
|
12
|
+
declare function MarkdownTable<T extends Record<string, any> = Record<string, any>>(props: MarkdownTableProps<T>): _alloy_js_core9.Children;
|
|
13
13
|
type MarkdownTableColumnProps = ComponentProps & Partial<Pick<MarkdownTableColumnContextInterface, "align">> & Required<Pick<MarkdownTableColumnContextInterface, "name">> & {
|
|
14
14
|
width?: number;
|
|
15
15
|
};
|
|
16
16
|
/**
|
|
17
17
|
* Component that provides a context for rendering markdown tables.
|
|
18
18
|
*/
|
|
19
|
-
declare function MarkdownTableColumn(props: MarkdownTableColumnProps):
|
|
19
|
+
declare function MarkdownTableColumn(props: MarkdownTableColumnProps): _alloy_js_core9.Children;
|
|
20
20
|
/**
|
|
21
21
|
* Component that provides a context for rendering markdown tables.
|
|
22
22
|
*/
|
|
23
|
-
declare function MarkdownTableColumnHeader(props: MarkdownTableColumnProps):
|
|
23
|
+
declare function MarkdownTableColumnHeader(props: MarkdownTableColumnProps): _alloy_js_core9.Children;
|
|
24
24
|
declare type __ΩMarkdownTableProps = any[];
|
|
25
25
|
declare type __ΩMarkdownTableColumnProps = any[];
|
|
26
26
|
//#endregion
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
const require_chunk = require('./chunk-CbDLau6x.cjs');
|
|
2
2
|
const require_markdown_table = require('./markdown-table-BOWM26Kb.cjs');
|
|
3
|
+
let __alloy_js_core_jsx_runtime = require("@alloy-js/core/jsx-runtime");
|
|
3
4
|
let __alloy_js_core = require("@alloy-js/core");
|
|
4
5
|
let __stryke_type_checks_is_undefined = require("@stryke/type-checks/is-undefined");
|
|
5
|
-
let __alloy_js_core_jsx_runtime = require("@alloy-js/core/jsx-runtime");
|
|
6
6
|
let __stryke_string_format_title_case = require("@stryke/string-format/title-case");
|
|
7
7
|
|
|
8
8
|
//#region src/markdown/components/markdown-table.tsx
|
|
@@ -17,15 +17,21 @@ function MarkdownTable(props) {
|
|
|
17
17
|
align: "left",
|
|
18
18
|
width: 20
|
|
19
19
|
})));
|
|
20
|
-
return
|
|
21
|
-
value
|
|
22
|
-
|
|
23
|
-
|
|
20
|
+
return (0, __alloy_js_core_jsx_runtime.createComponent)(require_markdown_table.MarkdownTableContext.Provider, {
|
|
21
|
+
get value() {
|
|
22
|
+
return {
|
|
23
|
+
columns: columns.value,
|
|
24
|
+
data
|
|
25
|
+
};
|
|
24
26
|
},
|
|
25
|
-
children
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
27
|
+
get children() {
|
|
28
|
+
return (0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Show, {
|
|
29
|
+
get when() {
|
|
30
|
+
return Boolean(children);
|
|
31
|
+
},
|
|
32
|
+
children
|
|
33
|
+
});
|
|
34
|
+
}
|
|
29
35
|
});
|
|
30
36
|
}
|
|
31
37
|
/**
|
|
@@ -46,32 +52,47 @@ function MarkdownTableColumn(props) {
|
|
|
46
52
|
const textLength = (0, __alloy_js_core.computed)(() => {
|
|
47
53
|
return (children ? children.toString() : "").length;
|
|
48
54
|
});
|
|
49
|
-
return
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
55
|
+
return (0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Prose, { get children() {
|
|
56
|
+
return [
|
|
57
|
+
(0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Show, {
|
|
58
|
+
get when() {
|
|
59
|
+
return indexRef.value === 0;
|
|
60
|
+
},
|
|
61
|
+
children: "|"
|
|
62
|
+
}),
|
|
63
|
+
(0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Show, {
|
|
64
|
+
get when() {
|
|
65
|
+
return Boolean(children);
|
|
66
|
+
},
|
|
67
|
+
get children() {
|
|
68
|
+
return (0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Prose, { get children() {
|
|
69
|
+
return __alloy_js_core.code`${alignRef.value === "left" ? " ".repeat(widthRef.value - textLength.value - 1) : " "}${children}${alignRef.value === "right" ? " ".repeat(widthRef.value - textLength.value - 1) : " "}`;
|
|
70
|
+
} });
|
|
71
|
+
}
|
|
72
|
+
}),
|
|
73
|
+
"|"
|
|
74
|
+
];
|
|
75
|
+
} });
|
|
60
76
|
}
|
|
61
77
|
/**
|
|
62
78
|
* Component that provides a context for rendering markdown tables.
|
|
63
79
|
*/
|
|
64
80
|
function MarkdownTableColumnHeader(props) {
|
|
65
81
|
const [{ children, name }, rest] = (0, __alloy_js_core.splitProps)(props, ["children", "name"]);
|
|
66
|
-
return
|
|
67
|
-
...rest,
|
|
82
|
+
return [(0, __alloy_js_core_jsx_runtime.createComponent)(MarkdownTableColumn, (0, __alloy_js_core_jsx_runtime.mergeProps)(rest, {
|
|
68
83
|
name,
|
|
69
|
-
children
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
84
|
+
get children() {
|
|
85
|
+
return (0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Show, {
|
|
86
|
+
get fallback() {
|
|
87
|
+
return (0, __stryke_string_format_title_case.titleCase)(name, { useDescriptions: false });
|
|
88
|
+
},
|
|
89
|
+
get when() {
|
|
90
|
+
return !(0, __stryke_type_checks_is_undefined.isUndefined)(children);
|
|
91
|
+
},
|
|
92
|
+
children
|
|
93
|
+
});
|
|
94
|
+
}
|
|
95
|
+
}))];
|
|
75
96
|
}
|
|
76
97
|
|
|
77
98
|
//#endregion
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { n as MarkdownTableContext, r as useMarkdownTable } from "./markdown-table-2qP_4eLk.mjs";
|
|
2
|
+
import { createComponent, mergeProps } from "@alloy-js/core/jsx-runtime";
|
|
2
3
|
import { Prose, Show, code, computed, splitProps } from "@alloy-js/core";
|
|
3
4
|
import { isUndefined } from "@stryke/type-checks/is-undefined";
|
|
4
|
-
import { Fragment, jsx, jsxs } from "@alloy-js/core/jsx-runtime";
|
|
5
5
|
import { titleCase } from "@stryke/string-format/title-case";
|
|
6
6
|
|
|
7
7
|
//#region src/markdown/components/markdown-table.tsx
|
|
@@ -16,15 +16,21 @@ function MarkdownTable(props) {
|
|
|
16
16
|
align: "left",
|
|
17
17
|
width: 20
|
|
18
18
|
})));
|
|
19
|
-
return
|
|
20
|
-
value
|
|
21
|
-
|
|
22
|
-
|
|
19
|
+
return createComponent(MarkdownTableContext.Provider, {
|
|
20
|
+
get value() {
|
|
21
|
+
return {
|
|
22
|
+
columns: columns.value,
|
|
23
|
+
data
|
|
24
|
+
};
|
|
23
25
|
},
|
|
24
|
-
children
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
26
|
+
get children() {
|
|
27
|
+
return createComponent(Show, {
|
|
28
|
+
get when() {
|
|
29
|
+
return Boolean(children);
|
|
30
|
+
},
|
|
31
|
+
children
|
|
32
|
+
});
|
|
33
|
+
}
|
|
28
34
|
});
|
|
29
35
|
}
|
|
30
36
|
/**
|
|
@@ -45,32 +51,47 @@ function MarkdownTableColumn(props) {
|
|
|
45
51
|
const textLength = computed(() => {
|
|
46
52
|
return (children ? children.toString() : "").length;
|
|
47
53
|
});
|
|
48
|
-
return
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
54
|
+
return createComponent(Prose, { get children() {
|
|
55
|
+
return [
|
|
56
|
+
createComponent(Show, {
|
|
57
|
+
get when() {
|
|
58
|
+
return indexRef.value === 0;
|
|
59
|
+
},
|
|
60
|
+
children: "|"
|
|
61
|
+
}),
|
|
62
|
+
createComponent(Show, {
|
|
63
|
+
get when() {
|
|
64
|
+
return Boolean(children);
|
|
65
|
+
},
|
|
66
|
+
get children() {
|
|
67
|
+
return createComponent(Prose, { get children() {
|
|
68
|
+
return code`${alignRef.value === "left" ? " ".repeat(widthRef.value - textLength.value - 1) : " "}${children}${alignRef.value === "right" ? " ".repeat(widthRef.value - textLength.value - 1) : " "}`;
|
|
69
|
+
} });
|
|
70
|
+
}
|
|
71
|
+
}),
|
|
72
|
+
"|"
|
|
73
|
+
];
|
|
74
|
+
} });
|
|
59
75
|
}
|
|
60
76
|
/**
|
|
61
77
|
* Component that provides a context for rendering markdown tables.
|
|
62
78
|
*/
|
|
63
79
|
function MarkdownTableColumnHeader(props) {
|
|
64
80
|
const [{ children, name }, rest] = splitProps(props, ["children", "name"]);
|
|
65
|
-
return
|
|
66
|
-
...rest,
|
|
81
|
+
return [createComponent(MarkdownTableColumn, mergeProps(rest, {
|
|
67
82
|
name,
|
|
68
|
-
children
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
83
|
+
get children() {
|
|
84
|
+
return createComponent(Show, {
|
|
85
|
+
get fallback() {
|
|
86
|
+
return titleCase(name, { useDescriptions: false });
|
|
87
|
+
},
|
|
88
|
+
get when() {
|
|
89
|
+
return !isUndefined(children);
|
|
90
|
+
},
|
|
91
|
+
children
|
|
92
|
+
});
|
|
93
|
+
}
|
|
94
|
+
}))];
|
|
74
95
|
}
|
|
75
96
|
|
|
76
97
|
//#endregion
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { n as ComponentProps } from "./components-C8Qs2PB0.cjs";
|
|
2
2
|
import { n as MarkdownTableColumnContextInterface } from "./markdown-table-CZMEY6IR.cjs";
|
|
3
|
-
import * as
|
|
3
|
+
import * as _alloy_js_core13 from "@alloy-js/core";
|
|
4
4
|
|
|
5
5
|
//#region src/markdown/components/markdown-table.d.ts
|
|
6
6
|
interface MarkdownTableProps<T extends Record<string, any> = Record<string, any>> extends ComponentProps {
|
|
@@ -9,18 +9,18 @@ interface MarkdownTableProps<T extends Record<string, any> = Record<string, any>
|
|
|
9
9
|
/**
|
|
10
10
|
* Component that provides a context for rendering markdown tables.
|
|
11
11
|
*/
|
|
12
|
-
declare function MarkdownTable<T extends Record<string, any> = Record<string, any>>(props: MarkdownTableProps<T>):
|
|
12
|
+
declare function MarkdownTable<T extends Record<string, any> = Record<string, any>>(props: MarkdownTableProps<T>): _alloy_js_core13.Children;
|
|
13
13
|
type MarkdownTableColumnProps = ComponentProps & Partial<Pick<MarkdownTableColumnContextInterface, "align">> & Required<Pick<MarkdownTableColumnContextInterface, "name">> & {
|
|
14
14
|
width?: number;
|
|
15
15
|
};
|
|
16
16
|
/**
|
|
17
17
|
* Component that provides a context for rendering markdown tables.
|
|
18
18
|
*/
|
|
19
|
-
declare function MarkdownTableColumn(props: MarkdownTableColumnProps):
|
|
19
|
+
declare function MarkdownTableColumn(props: MarkdownTableColumnProps): _alloy_js_core13.Children;
|
|
20
20
|
/**
|
|
21
21
|
* Component that provides a context for rendering markdown tables.
|
|
22
22
|
*/
|
|
23
|
-
declare function MarkdownTableColumnHeader(props: MarkdownTableColumnProps):
|
|
23
|
+
declare function MarkdownTableColumnHeader(props: MarkdownTableColumnProps): _alloy_js_core13.Children;
|
|
24
24
|
declare type __ΩMarkdownTableProps = any[];
|
|
25
25
|
declare type __ΩMarkdownTableColumnProps = any[];
|
|
26
26
|
//#endregion
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
const require_chunk = require('./chunk-CbDLau6x.cjs');
|
|
2
2
|
const require_context = require('./context-BIduC1bB.cjs');
|
|
3
|
-
let __alloy_js_core = require("@alloy-js/core");
|
|
4
3
|
let __alloy_js_core_jsx_runtime = require("@alloy-js/core/jsx-runtime");
|
|
4
|
+
let __alloy_js_core = require("@alloy-js/core");
|
|
5
5
|
let __stryke_path_replace = require("@stryke/path/replace");
|
|
6
6
|
|
|
7
7
|
//#region src/core/components/output.tsx
|
|
@@ -16,17 +16,24 @@ function Output(props) {
|
|
|
16
16
|
]);
|
|
17
17
|
const contextRef = (0, __alloy_js_core.ref)(context);
|
|
18
18
|
const basePathRef = (0, __alloy_js_core.computed)(() => basePath ? (0, __stryke_path_replace.replacePath)(basePath, contextRef.value.workspaceConfig.workspaceRoot) : contextRef.value.workspaceConfig.workspaceRoot);
|
|
19
|
-
return
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
children
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
19
|
+
return (0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Output, (0, __alloy_js_core_jsx_runtime.mergeProps)(rest, {
|
|
20
|
+
get basePath() {
|
|
21
|
+
return basePathRef.value;
|
|
22
|
+
},
|
|
23
|
+
get children() {
|
|
24
|
+
return (0, __alloy_js_core_jsx_runtime.createComponent)(require_context.PowerlinesContext.Provider, {
|
|
25
|
+
value: { ref: contextRef },
|
|
26
|
+
get children() {
|
|
27
|
+
return (0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Show, {
|
|
28
|
+
get when() {
|
|
29
|
+
return Boolean(contextRef.value);
|
|
30
|
+
},
|
|
31
|
+
children
|
|
32
|
+
});
|
|
33
|
+
}
|
|
34
|
+
});
|
|
35
|
+
}
|
|
36
|
+
}));
|
|
30
37
|
}
|
|
31
38
|
|
|
32
39
|
//#endregion
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { n as PluginContext } from "./context-BsDdxy5g.cjs";
|
|
2
|
-
import * as
|
|
2
|
+
import * as _alloy_js_core6 from "@alloy-js/core";
|
|
3
3
|
import { OutputProps } from "@alloy-js/core";
|
|
4
4
|
|
|
5
5
|
//#region src/core/components/output.d.ts
|
|
@@ -12,7 +12,7 @@ interface OutputProps$1<TContext extends PluginContext = PluginContext> extends
|
|
|
12
12
|
/**
|
|
13
13
|
* Output component for rendering the Powerlines plugin's output files via templates.
|
|
14
14
|
*/
|
|
15
|
-
declare function Output<TContext extends PluginContext = PluginContext>(props: OutputProps$1<TContext>):
|
|
15
|
+
declare function Output<TContext extends PluginContext = PluginContext>(props: OutputProps$1<TContext>): _alloy_js_core6.Children;
|
|
16
16
|
declare type __ΩOutputProps = any[];
|
|
17
17
|
//#endregion
|
|
18
18
|
export { OutputProps$1 as n, __ΩOutputProps as r, Output as t };
|