@powerlines/plugin-env 0.15.2 → 0.15.4

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 (231) hide show
  1. package/dist/components/docs.cjs +3 -70
  2. package/dist/components/docs.d.cts +1 -8
  3. package/dist/components/docs.d.mts +1 -8
  4. package/dist/components/docs.mjs +2 -68
  5. package/dist/components/env.cjs +4 -574
  6. package/dist/components/env.d.cts +2 -19
  7. package/dist/components/env.d.mts +3 -19
  8. package/dist/components/env.mjs +2 -570
  9. package/dist/components/index.cjs +7 -5
  10. package/dist/components/index.d.cts +4 -2
  11. package/dist/components/index.d.mts +5 -2
  12. package/dist/components/index.mjs +4 -2
  13. package/dist/{plugin-alloy/src/types/components.d.cts → components-8W0Zgj0y.d.mts} +2 -1
  14. package/dist/components-C9bYrQVK.cjs +0 -0
  15. package/dist/components-CNIQFfeK.mjs +1 -0
  16. package/dist/create-reflection-resource-BNYxBgW2.mjs +9846 -0
  17. package/dist/create-reflection-resource-BWYhmX7O.cjs +10085 -0
  18. package/dist/docs-5r844zC1.d.mts +9 -0
  19. package/dist/docs-B66b9li3.mjs +219 -0
  20. package/dist/docs-_MmTNBQX.d.cts +9 -0
  21. package/dist/docs-hBlKCRWK.cjs +224 -0
  22. package/dist/env-BPodCdD1.d.cts +116 -0
  23. package/dist/env-IQvgnabX.mjs +1578 -0
  24. package/dist/env-cO4BUDn1.cjs +1596 -0
  25. package/dist/env-zhzvpUI5.d.mts +98 -0
  26. package/dist/index-BXxhKmeA.d.mts +1 -0
  27. package/dist/index-Cc7fCJU9.d.mts +1 -0
  28. package/dist/index-CqdNToYT.d.cts +1 -0
  29. package/dist/index-DWPDThxu.d.cts +1 -0
  30. package/dist/index.cjs +702 -77
  31. package/dist/index.d.cts +185 -12
  32. package/dist/index.d.mts +190 -17
  33. package/dist/index.mjs +648 -28
  34. package/dist/{deepkit/schemas/reflection.d.mts → plugin-BaInAuAh.d.mts} +326 -59
  35. package/dist/{deepkit/schemas/reflection.d.cts → plugin-BwuEBScL.d.cts} +268 -1
  36. package/dist/plugin-D3B5E_Hg.mjs +1 -0
  37. package/dist/plugin-D5qyQPqC.cjs +0 -0
  38. package/dist/resolved-BZG2cwRG.d.cts +1789 -0
  39. package/dist/resolved-V5COsfDu.d.mts +1791 -0
  40. package/dist/runtime-Bisl_1Ja.cjs +0 -0
  41. package/dist/runtime-Q8Ni8SeN.d.cts +794 -0
  42. package/dist/runtime-azNoeKr-.mjs +1 -0
  43. package/dist/runtime-qZ0Z2kEd.d.mts +794 -0
  44. package/dist/types/index.cjs +3 -0
  45. package/dist/types/index.d.cts +4 -2
  46. package/dist/types/index.d.mts +5 -2
  47. package/dist/types/index.mjs +4 -0
  48. package/dist/types/plugin.cjs +1 -0
  49. package/dist/types/plugin.d.cts +3 -156
  50. package/dist/types/plugin.d.mts +4 -158
  51. package/dist/types/plugin.mjs +2 -0
  52. package/dist/types/runtime.cjs +1 -0
  53. package/dist/types/runtime.d.cts +2 -793
  54. package/dist/types/runtime.d.mts +2 -793
  55. package/dist/types/runtime.mjs +2 -0
  56. package/dist/types-DwElXV6q.mjs +1 -0
  57. package/dist/types-MYBaygjr.cjs +0 -0
  58. package/package.json +7 -7
  59. package/dist/_virtual/rolldown_runtime.cjs +0 -37
  60. package/dist/_virtual/rolldown_runtime.mjs +0 -29
  61. package/dist/babel/index.cjs +0 -1
  62. package/dist/babel/index.d.mts +0 -1
  63. package/dist/babel/index.mjs +0 -3
  64. package/dist/babel/plugin.cjs +0 -121
  65. package/dist/babel/plugin.d.cts +0 -7
  66. package/dist/babel/plugin.d.mts +0 -9
  67. package/dist/babel/plugin.mjs +0 -119
  68. package/dist/deepkit/schemas/reflection.cjs +0 -3940
  69. package/dist/deepkit/schemas/reflection.mjs +0 -3938
  70. package/dist/deepkit/schemas/reflection2.cjs +0 -4112
  71. package/dist/deepkit/schemas/reflection2.mjs +0 -4110
  72. package/dist/deepkit/src/capnp.cjs +0 -913
  73. package/dist/deepkit/src/capnp.mjs +0 -911
  74. package/dist/deepkit/src/esbuild-plugin.cjs +0 -47
  75. package/dist/deepkit/src/esbuild-plugin.mjs +0 -46
  76. package/dist/deepkit/src/reflect-type.cjs +0 -22
  77. package/dist/deepkit/src/reflect-type.mjs +0 -20
  78. package/dist/deepkit/src/resolve-reflections.cjs +0 -16
  79. package/dist/deepkit/src/resolve-reflections.mjs +0 -15
  80. package/dist/deepkit/src/transformer.cjs +0 -52
  81. package/dist/deepkit/src/transformer.mjs +0 -49
  82. package/dist/deepkit/src/transpile.cjs +0 -29
  83. package/dist/deepkit/src/transpile.mjs +0 -27
  84. package/dist/deepkit/src/types.d.cts +0 -10
  85. package/dist/deepkit/src/types.d.mts +0 -10
  86. package/dist/deepkit/src/utilities.cjs +0 -66
  87. package/dist/deepkit/src/utilities.mjs +0 -65
  88. package/dist/deepkit/src/vendor/type-compiler/index.cjs +0 -38
  89. package/dist/deepkit/src/vendor/type-compiler/index.mjs +0 -19
  90. package/dist/deepkit/src/vendor/type.cjs +0 -20
  91. package/dist/deepkit/src/vendor/type.d.cts +0 -7
  92. package/dist/deepkit/src/vendor/type.d.mts +0 -7
  93. package/dist/deepkit/src/vendor/type.mjs +0 -11
  94. package/dist/helpers/automd-generator.cjs +0 -22
  95. package/dist/helpers/automd-generator.mjs +0 -21
  96. package/dist/helpers/create-reflection-resource.cjs +0 -55
  97. package/dist/helpers/create-reflection-resource.d.cts +0 -15
  98. package/dist/helpers/create-reflection-resource.d.mts +0 -15
  99. package/dist/helpers/create-reflection-resource.mjs +0 -54
  100. package/dist/helpers/index.cjs +0 -6
  101. package/dist/helpers/index.d.mts +0 -6
  102. package/dist/helpers/index.mjs +0 -8
  103. package/dist/helpers/load.cjs +0 -83
  104. package/dist/helpers/load.d.cts +0 -35
  105. package/dist/helpers/load.d.mts +0 -36
  106. package/dist/helpers/load.mjs +0 -80
  107. package/dist/helpers/persistence.cjs +0 -214
  108. package/dist/helpers/persistence.d.cts +0 -84
  109. package/dist/helpers/persistence.d.mts +0 -84
  110. package/dist/helpers/persistence.mjs +0 -202
  111. package/dist/helpers/reflect.cjs +0 -111
  112. package/dist/helpers/reflect.d.cts +0 -46
  113. package/dist/helpers/reflect.d.mts +0 -46
  114. package/dist/helpers/reflect.mjs +0 -103
  115. package/dist/helpers/source-file-env.cjs +0 -28
  116. package/dist/helpers/source-file-env.d.cts +0 -8
  117. package/dist/helpers/source-file-env.d.mts +0 -8
  118. package/dist/helpers/source-file-env.mjs +0 -26
  119. package/dist/helpers/template-helpers.cjs +0 -42
  120. package/dist/helpers/template-helpers.d.cts +0 -15
  121. package/dist/helpers/template-helpers.d.mts +0 -15
  122. package/dist/helpers/template-helpers.mjs +0 -41
  123. package/dist/plugin-alloy/src/core/components/output.cjs +0 -45
  124. package/dist/plugin-alloy/src/core/components/output.mjs +0 -44
  125. package/dist/plugin-alloy/src/core/components/single-line-comment.cjs +0 -22
  126. package/dist/plugin-alloy/src/core/components/single-line-comment.mjs +0 -21
  127. package/dist/plugin-alloy/src/core/components/source-file.cjs +0 -64
  128. package/dist/plugin-alloy/src/core/components/source-file.d.cts +0 -23
  129. package/dist/plugin-alloy/src/core/components/source-file.d.mts +0 -23
  130. package/dist/plugin-alloy/src/core/components/source-file.mjs +0 -62
  131. package/dist/plugin-alloy/src/core/contexts/context.cjs +0 -60
  132. package/dist/plugin-alloy/src/core/contexts/context.mjs +0 -54
  133. package/dist/plugin-alloy/src/core/contexts/index.cjs +0 -2
  134. package/dist/plugin-alloy/src/core/contexts/index.mjs +0 -4
  135. package/dist/plugin-alloy/src/core/contexts/reflection.cjs +0 -46
  136. package/dist/plugin-alloy/src/core/contexts/reflection.mjs +0 -42
  137. package/dist/plugin-alloy/src/helpers/refkey.cjs +0 -16
  138. package/dist/plugin-alloy/src/helpers/refkey.mjs +0 -15
  139. package/dist/plugin-alloy/src/index.cjs +0 -93
  140. package/dist/plugin-alloy/src/index.mjs +0 -91
  141. package/dist/plugin-alloy/src/markdown/components/markdown-file.cjs +0 -115
  142. package/dist/plugin-alloy/src/markdown/components/markdown-file.mjs +0 -114
  143. package/dist/plugin-alloy/src/markdown/components/markdown-table.cjs +0 -39
  144. package/dist/plugin-alloy/src/markdown/components/markdown-table.mjs +0 -38
  145. package/dist/plugin-alloy/src/markdown/contexts/markdown-table.cjs +0 -18
  146. package/dist/plugin-alloy/src/markdown/contexts/markdown-table.mjs +0 -17
  147. package/dist/plugin-alloy/src/types/components.d.mts +0 -25
  148. package/dist/plugin-alloy/src/types/index.d.mts +0 -2
  149. package/dist/plugin-alloy/src/types/plugin.d.cts +0 -37
  150. package/dist/plugin-alloy/src/types/plugin.d.mts +0 -37
  151. package/dist/plugin-alloy/src/typescript/components/builtin-file.cjs +0 -57
  152. package/dist/plugin-alloy/src/typescript/components/builtin-file.d.cts +0 -25
  153. package/dist/plugin-alloy/src/typescript/components/builtin-file.d.mts +0 -26
  154. package/dist/plugin-alloy/src/typescript/components/builtin-file.mjs +0 -56
  155. package/dist/plugin-alloy/src/typescript/components/tsdoc-reflection.cjs +0 -126
  156. package/dist/plugin-alloy/src/typescript/components/tsdoc-reflection.mjs +0 -124
  157. package/dist/plugin-alloy/src/typescript/components/tsdoc.cjs +0 -442
  158. package/dist/plugin-alloy/src/typescript/components/tsdoc.d.cts +0 -27
  159. package/dist/plugin-alloy/src/typescript/components/tsdoc.d.mts +0 -28
  160. package/dist/plugin-alloy/src/typescript/components/tsdoc.mjs +0 -433
  161. package/dist/plugin-alloy/src/typescript/components/typescript-file.cjs +0 -194
  162. package/dist/plugin-alloy/src/typescript/components/typescript-file.d.cts +0 -14
  163. package/dist/plugin-alloy/src/typescript/components/typescript-file.d.mts +0 -15
  164. package/dist/plugin-alloy/src/typescript/components/typescript-file.mjs +0 -191
  165. package/dist/plugin-alloy/src/typescript/components/typescript-interface.cjs +0 -68
  166. package/dist/plugin-alloy/src/typescript/components/typescript-interface.d.cts +0 -11
  167. package/dist/plugin-alloy/src/typescript/components/typescript-interface.d.mts +0 -12
  168. package/dist/plugin-alloy/src/typescript/components/typescript-interface.mjs +0 -67
  169. package/dist/plugin-alloy/src/typescript/components/typescript-object.cjs +0 -124
  170. package/dist/plugin-alloy/src/typescript/components/typescript-object.mjs +0 -123
  171. package/dist/plugin-automd/src/index.cjs +0 -101
  172. package/dist/plugin-automd/src/index.mjs +0 -98
  173. package/dist/plugin-automd/src/types/plugin.d.cts +0 -38
  174. package/dist/plugin-automd/src/types/plugin.d.mts +0 -40
  175. package/dist/plugin-automd/src/types/toc.d.cts +0 -33
  176. package/dist/plugin-automd/src/types/toc.d.mts +0 -33
  177. package/dist/plugin-babel/src/helpers/ast-utils.cjs +0 -10
  178. package/dist/plugin-babel/src/helpers/ast-utils.mjs +0 -9
  179. package/dist/plugin-babel/src/helpers/create-plugin.cjs +0 -41
  180. package/dist/plugin-babel/src/helpers/create-plugin.mjs +0 -39
  181. package/dist/plugin-babel/src/helpers/filters.cjs +0 -23
  182. package/dist/plugin-babel/src/helpers/filters.mjs +0 -21
  183. package/dist/plugin-babel/src/helpers/index.cjs +0 -5
  184. package/dist/plugin-babel/src/helpers/index.mjs +0 -7
  185. package/dist/plugin-babel/src/helpers/module-helpers.cjs +0 -38
  186. package/dist/plugin-babel/src/helpers/module-helpers.mjs +0 -35
  187. package/dist/plugin-babel/src/helpers/options.cjs +0 -50
  188. package/dist/plugin-babel/src/helpers/options.mjs +0 -47
  189. package/dist/plugin-babel/src/index.cjs +0 -91
  190. package/dist/plugin-babel/src/index.mjs +0 -89
  191. package/dist/plugin-babel/src/types/index.d.mts +0 -1
  192. package/dist/plugin-babel/src/types/plugin.d.cts +0 -15
  193. package/dist/plugin-babel/src/types/plugin.d.mts +0 -15
  194. package/dist/powerlines/schemas/fs.d.mts +0 -1
  195. package/dist/powerlines/src/api.d.mts +0 -7
  196. package/dist/powerlines/src/index.d.mts +0 -12
  197. package/dist/powerlines/src/internal/helpers/hooks.d.mts +0 -5
  198. package/dist/powerlines/src/lib/build/esbuild.cjs +0 -102
  199. package/dist/powerlines/src/lib/build/esbuild.mjs +0 -100
  200. package/dist/powerlines/src/lib/entry.cjs +0 -12
  201. package/dist/powerlines/src/lib/entry.mjs +0 -14
  202. package/dist/powerlines/src/lib/logger.cjs +0 -41
  203. package/dist/powerlines/src/lib/logger.mjs +0 -39
  204. package/dist/powerlines/src/lib/utilities/bundle.cjs +0 -35
  205. package/dist/powerlines/src/lib/utilities/bundle.mjs +0 -34
  206. package/dist/powerlines/src/lib/utilities/resolve.cjs +0 -30
  207. package/dist/powerlines/src/lib/utilities/resolve.mjs +0 -29
  208. package/dist/powerlines/src/plugin-utils/paths.cjs +0 -1
  209. package/dist/powerlines/src/plugin-utils/paths.mjs +0 -3
  210. package/dist/powerlines/src/types/api.d.mts +0 -5
  211. package/dist/powerlines/src/types/babel.d.cts +0 -23
  212. package/dist/powerlines/src/types/babel.d.mts +0 -23
  213. package/dist/powerlines/src/types/build.d.cts +0 -145
  214. package/dist/powerlines/src/types/build.d.mts +0 -147
  215. package/dist/powerlines/src/types/commands.d.cts +0 -8
  216. package/dist/powerlines/src/types/commands.d.mts +0 -9
  217. package/dist/powerlines/src/types/config.d.cts +0 -380
  218. package/dist/powerlines/src/types/config.d.mts +0 -381
  219. package/dist/powerlines/src/types/context.d.cts +0 -414
  220. package/dist/powerlines/src/types/context.d.mts +0 -416
  221. package/dist/powerlines/src/types/fs.d.cts +0 -486
  222. package/dist/powerlines/src/types/fs.d.mts +0 -486
  223. package/dist/powerlines/src/types/hooks.d.mts +0 -2
  224. package/dist/powerlines/src/types/index.d.mts +0 -12
  225. package/dist/powerlines/src/types/plugin.d.cts +0 -231
  226. package/dist/powerlines/src/types/plugin.d.mts +0 -231
  227. package/dist/powerlines/src/types/resolved.d.cts +0 -82
  228. package/dist/powerlines/src/types/resolved.d.mts +0 -83
  229. package/dist/powerlines/src/types/tsconfig.d.cts +0 -69
  230. package/dist/powerlines/src/types/tsconfig.d.mts +0 -69
  231. package/dist/powerlines/src/types/unplugin.d.mts +0 -7
@@ -1,18 +0,0 @@
1
- const require_rolldown_runtime = require('../../../../_virtual/rolldown_runtime.cjs');
2
- let __alloy_js_core = require("@alloy-js/core");
3
-
4
- //#region ../plugin-alloy/src/markdown/contexts/markdown-table.ts
5
- /**
6
- * The Powerlines context used in template rendering.
7
- */
8
- const MarkdownTableColumnContext = (0, __alloy_js_core.createNamedContext)("markdown-table-column", {});
9
- /**
10
- * The Powerlines context used in template rendering.
11
- */
12
- const MarkdownTableContext = (0, __alloy_js_core.createContext)({
13
- columns: [],
14
- data: []
15
- });
16
-
17
- //#endregion
18
- exports.MarkdownTableContext = MarkdownTableContext;
@@ -1,17 +0,0 @@
1
- import { createContext, createNamedContext, useContext } from "@alloy-js/core";
2
-
3
- //#region ../plugin-alloy/src/markdown/contexts/markdown-table.ts
4
- /**
5
- * The Powerlines context used in template rendering.
6
- */
7
- const MarkdownTableColumnContext = createNamedContext("markdown-table-column", {});
8
- /**
9
- * The Powerlines context used in template rendering.
10
- */
11
- const MarkdownTableContext = createContext({
12
- columns: [],
13
- data: []
14
- });
15
-
16
- //#endregion
17
- export { MarkdownTableContext };
@@ -1,25 +0,0 @@
1
- import "../../../powerlines/src/types/fs.mjs";
2
- import "../../../powerlines/src/types/resolved.mjs";
3
- import { Children } from "@alloy-js/core";
4
- import { SourceFileContext as SourceFileContext$1 } from "@alloy-js/typescript";
5
-
6
- //#region ../plugin-alloy/src/types/components.d.ts
7
-
8
- /**
9
- * A type that represents the props of a component that can have children.
10
- */
11
- interface ComponentProps {
12
- children?: Children;
13
- }
14
- interface TypescriptFileImportItem {
15
- name: string;
16
- default?: boolean;
17
- alias?: string;
18
- type?: boolean;
19
- }
20
- type TypescriptFileImportList = Record<string, null | Array<TypescriptFileImportItem | string>>;
21
- type TypescriptFileImports = TypescriptFileImportList & {
22
- $builtins?: TypescriptFileImportList;
23
- };
24
- //#endregion
25
- export { ComponentProps, TypescriptFileImportItem, TypescriptFileImportList, TypescriptFileImports };
@@ -1,2 +0,0 @@
1
- import { ComponentProps, TypescriptFileImportItem, TypescriptFileImportList, TypescriptFileImports } from "./components.mjs";
2
- import { AlloyPluginContext, AlloyPluginOptions, AlloyPluginResolvedConfig, AlloyPluginUserConfig } from "./plugin.mjs";
@@ -1,37 +0,0 @@
1
- import { PluginContext } from "../../../powerlines/src/types/context.cjs";
2
- import { UserConfig } from "../../../powerlines/src/types/config.cjs";
3
- import { ResolvedConfig } from "../../../powerlines/src/types/resolved.cjs";
4
- import { Children, PrintTreeOptions } from "@alloy-js/core";
5
-
6
- //#region ../plugin-alloy/src/types/plugin.d.ts
7
- type AlloyPluginOptions = Partial<PrintTreeOptions> & {
8
- /**
9
- * If true, the Alloy framework is used to generate Typescript output files.
10
- *
11
- * @defaultValue true
12
- */
13
- typescript?: boolean;
14
- /**
15
- * If true, the Alloy framework is used to generate JSON output files.
16
- *
17
- * @defaultValue false
18
- */
19
- json?: boolean;
20
- /**
21
- * If true, the Alloy framework is used to generate Markdown output files.
22
- *
23
- * @defaultValue false
24
- */
25
- markdown?: boolean;
26
- };
27
- type AlloyPluginUserConfig = UserConfig & {
28
- alloy?: AlloyPluginOptions;
29
- };
30
- type AlloyPluginResolvedConfig = ResolvedConfig & {
31
- alloy: AlloyPluginOptions;
32
- };
33
- type AlloyPluginContext<TResolvedConfig extends AlloyPluginResolvedConfig = AlloyPluginResolvedConfig> = PluginContext<TResolvedConfig> & {
34
- render: <TContext extends AlloyPluginContext>(this: TContext, children: Children) => Promise<void>;
35
- };
36
- //#endregion
37
- export { AlloyPluginContext, AlloyPluginOptions, AlloyPluginResolvedConfig, AlloyPluginUserConfig };
@@ -1,37 +0,0 @@
1
- import { PluginContext } from "../../../powerlines/src/types/context.mjs";
2
- import { UserConfig } from "../../../powerlines/src/types/config.mjs";
3
- import { ResolvedConfig } from "../../../powerlines/src/types/resolved.mjs";
4
- import { Children, PrintTreeOptions } from "@alloy-js/core";
5
-
6
- //#region ../plugin-alloy/src/types/plugin.d.ts
7
- type AlloyPluginOptions = Partial<PrintTreeOptions> & {
8
- /**
9
- * If true, the Alloy framework is used to generate Typescript output files.
10
- *
11
- * @defaultValue true
12
- */
13
- typescript?: boolean;
14
- /**
15
- * If true, the Alloy framework is used to generate JSON output files.
16
- *
17
- * @defaultValue false
18
- */
19
- json?: boolean;
20
- /**
21
- * If true, the Alloy framework is used to generate Markdown output files.
22
- *
23
- * @defaultValue false
24
- */
25
- markdown?: boolean;
26
- };
27
- type AlloyPluginUserConfig = UserConfig & {
28
- alloy?: AlloyPluginOptions;
29
- };
30
- type AlloyPluginResolvedConfig = ResolvedConfig & {
31
- alloy: AlloyPluginOptions;
32
- };
33
- type AlloyPluginContext<TResolvedConfig extends AlloyPluginResolvedConfig = AlloyPluginResolvedConfig> = PluginContext<TResolvedConfig> & {
34
- render: <TContext extends AlloyPluginContext>(this: TContext, children: Children) => Promise<void>;
35
- };
36
- //#endregion
37
- export { AlloyPluginContext, AlloyPluginOptions, AlloyPluginResolvedConfig, AlloyPluginUserConfig };
@@ -1,57 +0,0 @@
1
- const require_rolldown_runtime = require('../../../../_virtual/rolldown_runtime.cjs');
2
- const require_context = require('../../core/contexts/context.cjs');
3
- const require_tsdoc = require('./tsdoc.cjs');
4
- const require_typescript_file = require('./typescript-file.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_path_replace = require("@stryke/path/replace");
8
- let __stryke_path_file_path_fns = require("@stryke/path/file-path-fns");
9
- let __stryke_type_checks_is_set = require("@stryke/type-checks/is-set");
10
-
11
- //#region ../plugin-alloy/src/typescript/components/builtin-file.tsx
12
- /**
13
- * A base component representing a Powerlines generated Typescript source file.
14
- *
15
- * @param props - The properties for the source file.
16
- * @returns The rendered source file component.
17
- */
18
- function BuiltinFile(props) {
19
- const [{ children, imports, id, description, tsx }, rest] = (0, __alloy_js_core.splitProps)(props, [
20
- "children",
21
- "imports",
22
- "id",
23
- "description",
24
- "tsx"
25
- ]);
26
- const context = require_context.usePowerlines();
27
- const path = (0, __alloy_js_core.computed)(() => (0, __stryke_path_replace.replacePath)(`${!(0, __stryke_type_checks_is_set.isSet)(tsx) ? id : (0, __stryke_path_replace.replaceExtension)(id)}${(0, __stryke_path_file_path_fns.hasFileExtension)(id) && !(0, __stryke_type_checks_is_set.isSet)(tsx) ? "" : tsx ? ".tsx" : ".ts"}`, context.builtinsPath));
28
- return (0, __alloy_js_core_jsx_runtime.createComponent)(require_typescript_file.TypescriptFile, (0, __alloy_js_core_jsx_runtime.mergeProps)({
29
- get header() {
30
- return (0, __alloy_js_core_jsx_runtime.createComponent)(require_typescript_file.TypescriptFileHeader, {
31
- get header() {
32
- return (0, __alloy_js_core_jsx_runtime.createComponent)(require_tsdoc.TSDocModule, {
33
- name: id,
34
- children: description
35
- });
36
- },
37
- get children() {
38
- return (0, __alloy_js_core_jsx_runtime.createComponent)(require_typescript_file.TypescriptFileHeaderImports, { imports });
39
- }
40
- });
41
- },
42
- get meta() {
43
- return {
44
- kind: "builtin",
45
- id: (0, __stryke_path_replace.replaceExtension)(id)
46
- };
47
- }
48
- }, rest, {
49
- get path() {
50
- return path.value;
51
- },
52
- children
53
- }));
54
- }
55
-
56
- //#endregion
57
- exports.BuiltinFile = BuiltinFile;
@@ -1,25 +0,0 @@
1
- import { TSDocModuleProps } from "./tsdoc.cjs";
2
- import { TypescriptFileProps } from "./typescript-file.cjs";
3
-
4
- //#region ../plugin-alloy/src/typescript/components/builtin-file.d.ts
5
- type BuiltinFileProps = Omit<TypescriptFileProps, "path"> & Omit<TSDocModuleProps, "name"> & {
6
- /**
7
- * The runtime module identifier.
8
- *
9
- * @remarks
10
- * This value will be included after the \`storm:\` prefix in the import statement.
11
- */
12
- id: string;
13
- /**
14
- * The description for the builtin module.
15
- */
16
- description?: string;
17
- /**
18
- * Whether the file is a TSX file.
19
- *
20
- * @defaultValue false
21
- */
22
- tsx?: boolean;
23
- };
24
- //#endregion
25
- export { BuiltinFileProps };
@@ -1,26 +0,0 @@
1
- import { TSDocModuleProps } from "./tsdoc.mjs";
2
- import { TypescriptFileProps } from "./typescript-file.mjs";
3
- import "@alloy-js/core";
4
-
5
- //#region ../plugin-alloy/src/typescript/components/builtin-file.d.ts
6
- type BuiltinFileProps = Omit<TypescriptFileProps, "path"> & Omit<TSDocModuleProps, "name"> & {
7
- /**
8
- * The runtime module identifier.
9
- *
10
- * @remarks
11
- * This value will be included after the \`storm:\` prefix in the import statement.
12
- */
13
- id: string;
14
- /**
15
- * The description for the builtin module.
16
- */
17
- description?: string;
18
- /**
19
- * Whether the file is a TSX file.
20
- *
21
- * @defaultValue false
22
- */
23
- tsx?: boolean;
24
- };
25
- //#endregion
26
- export { BuiltinFileProps };
@@ -1,56 +0,0 @@
1
- import { usePowerlines } from "../../core/contexts/context.mjs";
2
- import { TSDocModule } from "./tsdoc.mjs";
3
- import { TypescriptFile, TypescriptFileHeader, TypescriptFileHeaderImports } from "./typescript-file.mjs";
4
- import { createComponent, mergeProps } from "@alloy-js/core/jsx-runtime";
5
- import { computed, splitProps } from "@alloy-js/core";
6
- import { replaceExtension, replacePath } from "@stryke/path/replace";
7
- import { hasFileExtension } from "@stryke/path/file-path-fns";
8
- import { isSet } from "@stryke/type-checks/is-set";
9
-
10
- //#region ../plugin-alloy/src/typescript/components/builtin-file.tsx
11
- /**
12
- * A base component representing a Powerlines generated Typescript source file.
13
- *
14
- * @param props - The properties for the source file.
15
- * @returns The rendered source file component.
16
- */
17
- function BuiltinFile(props) {
18
- const [{ children, imports, id, description, tsx }, rest] = splitProps(props, [
19
- "children",
20
- "imports",
21
- "id",
22
- "description",
23
- "tsx"
24
- ]);
25
- const context = usePowerlines();
26
- const path = computed(() => replacePath(`${!isSet(tsx) ? id : replaceExtension(id)}${hasFileExtension(id) && !isSet(tsx) ? "" : tsx ? ".tsx" : ".ts"}`, context.builtinsPath));
27
- return createComponent(TypescriptFile, mergeProps({
28
- get header() {
29
- return createComponent(TypescriptFileHeader, {
30
- get header() {
31
- return createComponent(TSDocModule, {
32
- name: id,
33
- children: description
34
- });
35
- },
36
- get children() {
37
- return createComponent(TypescriptFileHeaderImports, { imports });
38
- }
39
- });
40
- },
41
- get meta() {
42
- return {
43
- kind: "builtin",
44
- id: replaceExtension(id)
45
- };
46
- }
47
- }, rest, {
48
- get path() {
49
- return path.value;
50
- },
51
- children
52
- }));
53
- }
54
-
55
- //#endregion
56
- export { BuiltinFile };
@@ -1,126 +0,0 @@
1
- const require_rolldown_runtime = require('../../../../_virtual/rolldown_runtime.cjs');
2
- const require_tsdoc = require('./tsdoc.cjs');
3
- const require_reflection = require('../../core/contexts/reflection.cjs');
4
- let __alloy_js_core_jsx_runtime = require("@alloy-js/core/jsx-runtime");
5
- let __alloy_js_core = require("@alloy-js/core");
6
- let __stryke_type_checks_is_set_string = require("@stryke/type-checks/is-set-string");
7
- let __stryke_string_format_title_case = require("@stryke/string-format/title-case");
8
- let __stryke_type_checks_is_string = require("@stryke/type-checks/is-string");
9
- let __stryke_type_checks_is_undefined = require("@stryke/type-checks/is-undefined");
10
-
11
- //#region ../plugin-alloy/src/typescript/components/tsdoc-reflection.tsx
12
- /**
13
- * Generates a TypeScript interface property for the given reflection class.
14
- */
15
- function TSDocReflectionClass(props) {
16
- const [{ children }, rest] = (0, __alloy_js_core.splitProps)(props, ["children"]);
17
- const reflectionClass = require_reflection.useReflectionClass();
18
- const title = (0, __alloy_js_core.computed)(() => reflectionClass.reflection.getTitle() || (0, __stryke_string_format_title_case.titleCase)(reflectionClass.reflection.getName()));
19
- const alias = (0, __alloy_js_core.computed)(() => reflectionClass.reflection.getAlias());
20
- const domain = (0, __alloy_js_core.computed)(() => reflectionClass.reflection.getDomain());
21
- const permission = (0, __alloy_js_core.computed)(() => reflectionClass.reflection.getPermission());
22
- const readonly = (0, __alloy_js_core.computed)(() => reflectionClass.reflection.isReadonly());
23
- const internal = (0, __alloy_js_core.computed)(() => reflectionClass.reflection.isInternal());
24
- const ignore = (0, __alloy_js_core.computed)(() => reflectionClass.reflection.isIgnored());
25
- const hidden = (0, __alloy_js_core.computed)(() => reflectionClass.reflection.isHidden());
26
- if (!reflectionClass.reflection.getName()) return null;
27
- return (0, __alloy_js_core_jsx_runtime.createComponent)(require_tsdoc.TSDoc, (0, __alloy_js_core_jsx_runtime.mergeProps)(rest, {
28
- get heading() {
29
- return reflectionClass.reflection.getDescription();
30
- },
31
- get children() {
32
- return [(0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Show, {
33
- get when() {
34
- return (0, __stryke_type_checks_is_set_string.isSetString)(title.value) || !(0, __stryke_type_checks_is_undefined.isUndefined)(alias.value) && alias.value.length > 0 || !(0, __stryke_type_checks_is_undefined.isUndefined)(permission.value) && permission.value.length > 0 || (0, __stryke_type_checks_is_set_string.isSetString)(domain.value) || !(0, __stryke_type_checks_is_undefined.isUndefined)(readonly.value) || !(0, __stryke_type_checks_is_undefined.isUndefined)(internal.value) || !(0, __stryke_type_checks_is_undefined.isUndefined)(ignore.value) || !(0, __stryke_type_checks_is_undefined.isUndefined)(hidden.value);
35
- },
36
- get children() {
37
- return (0, __alloy_js_core_jsx_runtime.createComponent)(require_tsdoc.TSDocAttributesTags, {
38
- get title() {
39
- return title.value;
40
- },
41
- get alias() {
42
- return alias.value;
43
- },
44
- get domain() {
45
- return domain.value;
46
- },
47
- get permission() {
48
- return permission.value;
49
- },
50
- get readonly() {
51
- return readonly.value;
52
- },
53
- get internal() {
54
- return internal.value;
55
- },
56
- get ignore() {
57
- return ignore.value;
58
- },
59
- get hidden() {
60
- return hidden.value;
61
- }
62
- });
63
- }
64
- }), (0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Show, {
65
- get when() {
66
- return (0, __alloy_js_core_jsx_runtime.memo)(() => !!Boolean(children))() && (0, __alloy_js_core.childrenArray)(() => children).length > 0;
67
- },
68
- get children() {
69
- return (0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.List, { get children() {
70
- return (0, __alloy_js_core.childrenArray)(() => children);
71
- } });
72
- }
73
- })];
74
- }
75
- }));
76
- }
77
- /**
78
- * Generates a TypeScript interface property for the given reflection class.
79
- */
80
- function TSDocReflectionProperty(props) {
81
- const [{ children }, rest] = (0, __alloy_js_core.splitProps)(props, ["children"]);
82
- const context = require_reflection.useReflectionProperty();
83
- return (0, __alloy_js_core_jsx_runtime.createComponent)(require_tsdoc.TSDoc, (0, __alloy_js_core_jsx_runtime.mergeProps)({ get heading() {
84
- return context.getDescription();
85
- } }, rest, { get children() {
86
- return [(0, __alloy_js_core_jsx_runtime.createComponent)(require_tsdoc.TSDocAttributesTags, {
87
- get title() {
88
- return context.getTitle();
89
- },
90
- get alias() {
91
- return context.getAlias();
92
- },
93
- get domain() {
94
- return context.getDomain();
95
- },
96
- get permission() {
97
- return context.getPermission();
98
- },
99
- get readonly() {
100
- return context.isReadonly();
101
- },
102
- get internal() {
103
- return context.isInternal();
104
- },
105
- get ignore() {
106
- return context.isIgnored();
107
- },
108
- get hidden() {
109
- return context.isHidden();
110
- }
111
- }), (0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Show, {
112
- get when() {
113
- return (0, __alloy_js_core_jsx_runtime.memo)(() => !!Boolean(children))() && (0, __alloy_js_core.childrenArray)(() => children).length > 0;
114
- },
115
- get children() {
116
- return (0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.List, { get children() {
117
- return (0, __alloy_js_core.childrenArray)(() => children);
118
- } });
119
- }
120
- })];
121
- } }));
122
- }
123
-
124
- //#endregion
125
- exports.TSDocReflectionClass = TSDocReflectionClass;
126
- exports.TSDocReflectionProperty = TSDocReflectionProperty;
@@ -1,124 +0,0 @@
1
- import { TSDoc, TSDocAttributesTags } from "./tsdoc.mjs";
2
- import { useReflectionClass, useReflectionProperty } from "../../core/contexts/reflection.mjs";
3
- import { createComponent, memo, mergeProps } from "@alloy-js/core/jsx-runtime";
4
- import { List, Show, childrenArray, code, computed, splitProps } from "@alloy-js/core";
5
- import { isSetString } from "@stryke/type-checks/is-set-string";
6
- import { titleCase } from "@stryke/string-format/title-case";
7
- import { isString } from "@stryke/type-checks/is-string";
8
- import { isUndefined } from "@stryke/type-checks/is-undefined";
9
-
10
- //#region ../plugin-alloy/src/typescript/components/tsdoc-reflection.tsx
11
- /**
12
- * Generates a TypeScript interface property for the given reflection class.
13
- */
14
- function TSDocReflectionClass(props) {
15
- const [{ children }, rest] = splitProps(props, ["children"]);
16
- const reflectionClass = useReflectionClass();
17
- const title = computed(() => reflectionClass.reflection.getTitle() || titleCase(reflectionClass.reflection.getName()));
18
- const alias = computed(() => reflectionClass.reflection.getAlias());
19
- const domain = computed(() => reflectionClass.reflection.getDomain());
20
- const permission = computed(() => reflectionClass.reflection.getPermission());
21
- const readonly = computed(() => reflectionClass.reflection.isReadonly());
22
- const internal = computed(() => reflectionClass.reflection.isInternal());
23
- const ignore = computed(() => reflectionClass.reflection.isIgnored());
24
- const hidden = computed(() => reflectionClass.reflection.isHidden());
25
- if (!reflectionClass.reflection.getName()) return null;
26
- return createComponent(TSDoc, mergeProps(rest, {
27
- get heading() {
28
- return reflectionClass.reflection.getDescription();
29
- },
30
- get children() {
31
- return [createComponent(Show, {
32
- get when() {
33
- return isSetString(title.value) || !isUndefined(alias.value) && alias.value.length > 0 || !isUndefined(permission.value) && permission.value.length > 0 || isSetString(domain.value) || !isUndefined(readonly.value) || !isUndefined(internal.value) || !isUndefined(ignore.value) || !isUndefined(hidden.value);
34
- },
35
- get children() {
36
- return createComponent(TSDocAttributesTags, {
37
- get title() {
38
- return title.value;
39
- },
40
- get alias() {
41
- return alias.value;
42
- },
43
- get domain() {
44
- return domain.value;
45
- },
46
- get permission() {
47
- return permission.value;
48
- },
49
- get readonly() {
50
- return readonly.value;
51
- },
52
- get internal() {
53
- return internal.value;
54
- },
55
- get ignore() {
56
- return ignore.value;
57
- },
58
- get hidden() {
59
- return hidden.value;
60
- }
61
- });
62
- }
63
- }), createComponent(Show, {
64
- get when() {
65
- return memo(() => !!Boolean(children))() && childrenArray(() => children).length > 0;
66
- },
67
- get children() {
68
- return createComponent(List, { get children() {
69
- return childrenArray(() => children);
70
- } });
71
- }
72
- })];
73
- }
74
- }));
75
- }
76
- /**
77
- * Generates a TypeScript interface property for the given reflection class.
78
- */
79
- function TSDocReflectionProperty(props) {
80
- const [{ children }, rest] = splitProps(props, ["children"]);
81
- const context = useReflectionProperty();
82
- return createComponent(TSDoc, mergeProps({ get heading() {
83
- return context.getDescription();
84
- } }, rest, { get children() {
85
- return [createComponent(TSDocAttributesTags, {
86
- get title() {
87
- return context.getTitle();
88
- },
89
- get alias() {
90
- return context.getAlias();
91
- },
92
- get domain() {
93
- return context.getDomain();
94
- },
95
- get permission() {
96
- return context.getPermission();
97
- },
98
- get readonly() {
99
- return context.isReadonly();
100
- },
101
- get internal() {
102
- return context.isInternal();
103
- },
104
- get ignore() {
105
- return context.isIgnored();
106
- },
107
- get hidden() {
108
- return context.isHidden();
109
- }
110
- }), createComponent(Show, {
111
- get when() {
112
- return memo(() => !!Boolean(children))() && childrenArray(() => children).length > 0;
113
- },
114
- get children() {
115
- return createComponent(List, { get children() {
116
- return childrenArray(() => children);
117
- } });
118
- }
119
- })];
120
- } }));
121
- }
122
-
123
- //#endregion
124
- export { TSDocReflectionClass, TSDocReflectionProperty };