@powerlines/plugin-alloy 0.25.34 → 0.25.35

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 (266) hide show
  1. package/dist/core/components/index.d.cts +5 -0
  2. package/dist/core/components/index.d.mts +5 -0
  3. package/dist/core/components/output.d.cts +24 -0
  4. package/dist/core/components/output.d.cts.map +1 -0
  5. package/dist/core/components/output.d.mts +24 -0
  6. package/dist/core/components/output.d.mts.map +1 -0
  7. package/dist/core/components/output.mjs +2 -1
  8. package/dist/core/components/output.mjs.map +1 -0
  9. package/dist/core/components/single-line-comment.d.cts +23 -0
  10. package/dist/core/components/single-line-comment.d.cts.map +1 -0
  11. package/dist/core/components/single-line-comment.d.mts +23 -0
  12. package/dist/core/components/single-line-comment.d.mts.map +1 -0
  13. package/dist/core/components/single-line-comment.mjs +2 -1
  14. package/dist/core/components/single-line-comment.mjs.map +1 -0
  15. package/dist/core/components/source-file.d.cts +33 -0
  16. package/dist/core/components/source-file.d.cts.map +1 -0
  17. package/dist/core/components/source-file.d.mts +33 -0
  18. package/dist/core/components/source-file.d.mts.map +1 -0
  19. package/dist/core/components/source-file.mjs +2 -1
  20. package/dist/core/components/source-file.mjs.map +1 -0
  21. package/dist/core/components/spacing.d.cts +24 -0
  22. package/dist/core/components/spacing.d.cts.map +1 -0
  23. package/dist/core/components/spacing.d.mts +24 -0
  24. package/dist/core/components/spacing.d.mts.map +1 -0
  25. package/dist/core/components/spacing.mjs +2 -1
  26. package/dist/core/components/spacing.mjs.map +1 -0
  27. package/dist/core/contexts/context.d.cts +29 -0
  28. package/dist/core/contexts/context.d.cts.map +1 -0
  29. package/dist/core/contexts/context.d.mts +29 -0
  30. package/dist/core/contexts/context.d.mts.map +1 -0
  31. package/dist/core/contexts/context.mjs +2 -1
  32. package/dist/core/contexts/context.mjs.map +1 -0
  33. package/dist/core/contexts/index.d.cts +4 -0
  34. package/dist/core/contexts/index.d.mts +4 -0
  35. package/dist/core/contexts/meta.d.cts +48 -0
  36. package/dist/core/contexts/meta.d.cts.map +1 -0
  37. package/dist/core/contexts/meta.d.mts +48 -0
  38. package/dist/core/contexts/meta.d.mts.map +1 -0
  39. package/dist/core/contexts/meta.mjs +2 -1
  40. package/dist/core/contexts/meta.mjs.map +1 -0
  41. package/dist/core/contexts/reflection.d.cts +53 -0
  42. package/dist/core/contexts/reflection.d.cts.map +1 -0
  43. package/dist/core/contexts/reflection.d.mts +53 -0
  44. package/dist/core/contexts/reflection.d.mts.map +1 -0
  45. package/dist/core/contexts/reflection.mjs +2 -1
  46. package/dist/core/contexts/reflection.mjs.map +1 -0
  47. package/dist/core/helpers/code.d.cts +29 -0
  48. package/dist/core/helpers/code.d.cts.map +1 -0
  49. package/dist/core/helpers/code.d.mts +29 -0
  50. package/dist/core/helpers/code.d.mts.map +1 -0
  51. package/dist/core/helpers/code.mjs +2 -1
  52. package/dist/core/helpers/code.mjs.map +1 -0
  53. package/dist/core/helpers/index.d.cts +2 -0
  54. package/dist/core/helpers/index.d.mts +2 -0
  55. package/dist/core/index.d.cts +9 -0
  56. package/dist/core/index.d.mts +9 -0
  57. package/dist/helpers/capnp.d.cts +87 -0
  58. package/dist/helpers/capnp.d.cts.map +1 -0
  59. package/dist/helpers/capnp.d.mts +87 -0
  60. package/dist/helpers/capnp.d.mts.map +1 -0
  61. package/dist/helpers/capnp.mjs +2 -1
  62. package/dist/helpers/capnp.mjs.map +1 -0
  63. package/dist/helpers/create-builtin.d.cts +16 -0
  64. package/dist/helpers/create-builtin.d.cts.map +1 -0
  65. package/dist/helpers/create-builtin.d.mts +16 -0
  66. package/dist/helpers/create-builtin.d.mts.map +1 -0
  67. package/dist/helpers/create-builtin.mjs +2 -1
  68. package/dist/helpers/create-builtin.mjs.map +1 -0
  69. package/dist/helpers/index.d.cts +5 -0
  70. package/dist/helpers/index.d.mts +5 -0
  71. package/dist/helpers/refkey.d.cts +13 -0
  72. package/dist/helpers/refkey.d.cts.map +1 -0
  73. package/dist/helpers/refkey.d.mts +13 -0
  74. package/dist/helpers/refkey.d.mts.map +1 -0
  75. package/dist/helpers/refkey.mjs +2 -1
  76. package/dist/helpers/refkey.mjs.map +1 -0
  77. package/dist/helpers/typescript.d.cts +26 -0
  78. package/dist/helpers/typescript.d.cts.map +1 -0
  79. package/dist/helpers/typescript.d.mts +26 -0
  80. package/dist/helpers/typescript.d.mts.map +1 -0
  81. package/dist/helpers/typescript.mjs +2 -1
  82. package/dist/helpers/typescript.mjs.map +1 -0
  83. package/dist/index.cjs +6 -1
  84. package/dist/index.d.cts +19 -0
  85. package/dist/index.d.cts.map +1 -0
  86. package/dist/index.d.mts +19 -0
  87. package/dist/index.d.mts.map +1 -0
  88. package/dist/index.mjs +8 -2
  89. package/dist/index.mjs.map +1 -0
  90. package/dist/markdown/components/front-matter.d.cts +16 -0
  91. package/dist/markdown/components/front-matter.d.cts.map +1 -0
  92. package/dist/markdown/components/front-matter.d.mts +16 -0
  93. package/dist/markdown/components/front-matter.d.mts.map +1 -0
  94. package/dist/markdown/components/front-matter.mjs +2 -1
  95. package/dist/markdown/components/front-matter.mjs.map +1 -0
  96. package/dist/markdown/components/index.d.cts +4 -0
  97. package/dist/markdown/components/index.d.mts +4 -0
  98. package/dist/markdown/components/markdown-file.d.cts +29 -0
  99. package/dist/markdown/components/markdown-file.d.cts.map +1 -0
  100. package/dist/markdown/components/markdown-file.d.mts +29 -0
  101. package/dist/markdown/components/markdown-file.d.mts.map +1 -0
  102. package/dist/markdown/components/markdown-file.mjs +2 -1
  103. package/dist/markdown/components/markdown-file.mjs.map +1 -0
  104. package/dist/markdown/components/markdown-table.d.cts +28 -0
  105. package/dist/markdown/components/markdown-table.d.cts.map +1 -0
  106. package/dist/markdown/components/markdown-table.d.mts +28 -0
  107. package/dist/markdown/components/markdown-table.d.mts.map +1 -0
  108. package/dist/markdown/components/markdown-table.mjs +2 -1
  109. package/dist/markdown/components/markdown-table.mjs.map +1 -0
  110. package/dist/markdown/contexts/index.d.cts +2 -0
  111. package/dist/markdown/contexts/index.d.mts +2 -0
  112. package/dist/markdown/contexts/markdown-table.d.cts +38 -0
  113. package/dist/markdown/contexts/markdown-table.d.cts.map +1 -0
  114. package/dist/markdown/contexts/markdown-table.d.mts +38 -0
  115. package/dist/markdown/contexts/markdown-table.d.mts.map +1 -0
  116. package/dist/markdown/contexts/markdown-table.mjs +2 -1
  117. package/dist/markdown/contexts/markdown-table.mjs.map +1 -0
  118. package/dist/markdown/index.d.cts +5 -0
  119. package/dist/markdown/index.d.mts +5 -0
  120. package/dist/render.cjs +1 -1
  121. package/dist/render.d.cts +38 -0
  122. package/dist/render.d.cts.map +1 -0
  123. package/dist/render.d.mts +38 -0
  124. package/dist/render.d.mts.map +1 -0
  125. package/dist/render.mjs +3 -2
  126. package/dist/render.mjs.map +1 -0
  127. package/dist/types/components.d.cts +142 -0
  128. package/dist/types/components.d.cts.map +1 -0
  129. package/dist/types/components.d.mts +142 -0
  130. package/dist/types/components.d.mts.map +1 -0
  131. package/dist/types/index.d.cts +3 -0
  132. package/dist/types/index.d.mts +3 -0
  133. package/dist/types/plugin.d.cts +39 -0
  134. package/dist/types/plugin.d.cts.map +1 -0
  135. package/dist/types/plugin.d.mts +39 -0
  136. package/dist/types/plugin.d.mts.map +1 -0
  137. package/dist/typescript/components/builtin-file.cjs +1 -1
  138. package/dist/typescript/components/builtin-file.d.cts +35 -0
  139. package/dist/typescript/components/builtin-file.d.cts.map +1 -0
  140. package/dist/typescript/components/builtin-file.d.mts +35 -0
  141. package/dist/typescript/components/builtin-file.d.mts.map +1 -0
  142. package/dist/typescript/components/builtin-file.mjs +3 -2
  143. package/dist/typescript/components/builtin-file.mjs.map +1 -0
  144. package/dist/typescript/components/class-declaration.d.cts +145 -0
  145. package/dist/typescript/components/class-declaration.d.cts.map +1 -0
  146. package/dist/typescript/components/class-declaration.d.mts +145 -0
  147. package/dist/typescript/components/class-declaration.d.mts.map +1 -0
  148. package/dist/typescript/components/class-declaration.mjs +2 -1
  149. package/dist/typescript/components/class-declaration.mjs.map +1 -0
  150. package/dist/typescript/components/dynamic-import-statement.d.cts +33 -0
  151. package/dist/typescript/components/dynamic-import-statement.d.cts.map +1 -0
  152. package/dist/typescript/components/dynamic-import-statement.d.mts +33 -0
  153. package/dist/typescript/components/dynamic-import-statement.d.mts.map +1 -0
  154. package/dist/typescript/components/dynamic-import-statement.mjs +2 -1
  155. package/dist/typescript/components/dynamic-import-statement.mjs.map +1 -0
  156. package/dist/typescript/components/entry-file.cjs +1 -1
  157. package/dist/typescript/components/entry-file.d.cts +28 -0
  158. package/dist/typescript/components/entry-file.d.cts.map +1 -0
  159. package/dist/typescript/components/entry-file.d.mts +28 -0
  160. package/dist/typescript/components/entry-file.d.mts.map +1 -0
  161. package/dist/typescript/components/entry-file.mjs +3 -2
  162. package/dist/typescript/components/entry-file.mjs.map +1 -0
  163. package/dist/typescript/components/index.d.cts +15 -0
  164. package/dist/typescript/components/index.d.mts +15 -0
  165. package/dist/typescript/components/infrastructure-file.cjs +1 -1
  166. package/dist/typescript/components/infrastructure-file.d.cts +21 -0
  167. package/dist/typescript/components/infrastructure-file.d.cts.map +1 -0
  168. package/dist/typescript/components/infrastructure-file.d.mts +21 -0
  169. package/dist/typescript/components/infrastructure-file.d.mts.map +1 -0
  170. package/dist/typescript/components/infrastructure-file.mjs +3 -2
  171. package/dist/typescript/components/infrastructure-file.mjs.map +1 -0
  172. package/dist/typescript/components/interface-declaration.d.cts +86 -0
  173. package/dist/typescript/components/interface-declaration.d.cts.map +1 -0
  174. package/dist/typescript/components/interface-declaration.d.mts +86 -0
  175. package/dist/typescript/components/interface-declaration.d.mts.map +1 -0
  176. package/dist/typescript/components/interface-declaration.mjs +2 -1
  177. package/dist/typescript/components/interface-declaration.mjs.map +1 -0
  178. package/dist/typescript/components/object-declaration.d.cts +30 -0
  179. package/dist/typescript/components/object-declaration.d.cts.map +1 -0
  180. package/dist/typescript/components/object-declaration.d.mts +30 -0
  181. package/dist/typescript/components/object-declaration.d.mts.map +1 -0
  182. package/dist/typescript/components/object-declaration.mjs +2 -1
  183. package/dist/typescript/components/object-declaration.mjs.map +1 -0
  184. package/dist/typescript/components/property-name.d.cts +24 -0
  185. package/dist/typescript/components/property-name.d.cts.map +1 -0
  186. package/dist/typescript/components/property-name.d.mts +24 -0
  187. package/dist/typescript/components/property-name.d.mts.map +1 -0
  188. package/dist/typescript/components/property-name.mjs +2 -1
  189. package/dist/typescript/components/property-name.mjs.map +1 -0
  190. package/dist/typescript/components/record-expression.d.cts +13 -0
  191. package/dist/typescript/components/record-expression.d.cts.map +1 -0
  192. package/dist/typescript/components/record-expression.d.mts +13 -0
  193. package/dist/typescript/components/record-expression.d.mts.map +1 -0
  194. package/dist/typescript/components/record-expression.mjs +2 -1
  195. package/dist/typescript/components/record-expression.mjs.map +1 -0
  196. package/dist/typescript/components/tsdoc-reflection.d.cts +44 -0
  197. package/dist/typescript/components/tsdoc-reflection.d.cts.map +1 -0
  198. package/dist/typescript/components/tsdoc-reflection.d.mts +44 -0
  199. package/dist/typescript/components/tsdoc-reflection.d.mts.map +1 -0
  200. package/dist/typescript/components/tsdoc-reflection.mjs +2 -1
  201. package/dist/typescript/components/tsdoc-reflection.mjs.map +1 -0
  202. package/dist/typescript/components/tsdoc.d.cts +164 -0
  203. package/dist/typescript/components/tsdoc.d.cts.map +1 -0
  204. package/dist/typescript/components/tsdoc.d.mts +164 -0
  205. package/dist/typescript/components/tsdoc.d.mts.map +1 -0
  206. package/dist/typescript/components/tsdoc.mjs +2 -1
  207. package/dist/typescript/components/tsdoc.mjs.map +1 -0
  208. package/dist/typescript/components/type-declaration.d.cts +18 -0
  209. package/dist/typescript/components/type-declaration.d.cts.map +1 -0
  210. package/dist/typescript/components/type-declaration.d.mts +18 -0
  211. package/dist/typescript/components/type-declaration.d.mts.map +1 -0
  212. package/dist/typescript/components/type-declaration.mjs +2 -1
  213. package/dist/typescript/components/type-declaration.mjs.map +1 -0
  214. package/dist/typescript/components/type-parameters.d.cts +24 -0
  215. package/dist/typescript/components/type-parameters.d.cts.map +1 -0
  216. package/dist/typescript/components/type-parameters.d.mts +24 -0
  217. package/dist/typescript/components/type-parameters.d.mts.map +1 -0
  218. package/dist/typescript/components/type-parameters.mjs +2 -1
  219. package/dist/typescript/components/type-parameters.mjs.map +1 -0
  220. package/dist/typescript/components/typescript-file.d.cts +50 -0
  221. package/dist/typescript/components/typescript-file.d.cts.map +1 -0
  222. package/dist/typescript/components/typescript-file.d.mts +50 -0
  223. package/dist/typescript/components/typescript-file.d.mts.map +1 -0
  224. package/dist/typescript/components/typescript-file.mjs +2 -1
  225. package/dist/typescript/components/typescript-file.mjs.map +1 -0
  226. package/dist/typescript/contexts/index.d.cts +2 -0
  227. package/dist/typescript/contexts/index.d.mts +2 -0
  228. package/dist/typescript/contexts/lexical-scope.d.cts +17 -0
  229. package/dist/typescript/contexts/lexical-scope.d.cts.map +1 -0
  230. package/dist/typescript/contexts/lexical-scope.d.mts +17 -0
  231. package/dist/typescript/contexts/lexical-scope.d.mts.map +1 -0
  232. package/dist/typescript/contexts/lexical-scope.mjs +2 -1
  233. package/dist/typescript/contexts/lexical-scope.mjs.map +1 -0
  234. package/dist/typescript/contexts/member-scope.d.cts +20 -0
  235. package/dist/typescript/contexts/member-scope.d.cts.map +1 -0
  236. package/dist/typescript/contexts/member-scope.d.mts +20 -0
  237. package/dist/typescript/contexts/member-scope.d.mts.map +1 -0
  238. package/dist/typescript/contexts/member-scope.mjs +2 -1
  239. package/dist/typescript/contexts/member-scope.mjs.map +1 -0
  240. package/dist/typescript/helpers/get-call-signature-props.d.cts +14 -0
  241. package/dist/typescript/helpers/get-call-signature-props.d.cts.map +1 -0
  242. package/dist/typescript/helpers/get-call-signature-props.d.mts +14 -0
  243. package/dist/typescript/helpers/get-call-signature-props.d.mts.map +1 -0
  244. package/dist/typescript/helpers/get-call-signature-props.mjs +2 -1
  245. package/dist/typescript/helpers/get-call-signature-props.mjs.map +1 -0
  246. package/dist/typescript/helpers/index.d.cts +3 -0
  247. package/dist/typescript/helpers/index.d.mts +3 -0
  248. package/dist/typescript/helpers/utilities.d.cts +11 -0
  249. package/dist/typescript/helpers/utilities.d.cts.map +1 -0
  250. package/dist/typescript/helpers/utilities.d.mts +11 -0
  251. package/dist/typescript/helpers/utilities.d.mts.map +1 -0
  252. package/dist/typescript/helpers/utilities.mjs +2 -1
  253. package/dist/typescript/helpers/utilities.mjs.map +1 -0
  254. package/dist/typescript/index.d.cts +18 -0
  255. package/dist/typescript/index.d.mts +18 -0
  256. package/dist/yaml/components/index.d.cts +2 -0
  257. package/dist/yaml/components/index.d.mts +2 -0
  258. package/dist/yaml/components/yaml-file.d.cts +34 -0
  259. package/dist/yaml/components/yaml-file.d.cts.map +1 -0
  260. package/dist/yaml/components/yaml-file.d.mts +34 -0
  261. package/dist/yaml/components/yaml-file.d.mts.map +1 -0
  262. package/dist/yaml/components/yaml-file.mjs +2 -1
  263. package/dist/yaml/components/yaml-file.mjs.map +1 -0
  264. package/dist/yaml/index.d.cts +2 -0
  265. package/dist/yaml/index.d.mts +2 -0
  266. package/package.json +2 -2
@@ -0,0 +1,5 @@
1
+ import { Output, OutputProps, __ΩOutputProps } from "./output.cjs";
2
+ import { SingleLineComment, SingleLineCommentProps, SingleLineCommentVariant, __ΩSingleLineCommentProps, __ΩSingleLineCommentVariant } from "./single-line-comment.cjs";
3
+ import { SourceFile, SourceFileProps, __ΩSourceFileProps } from "./source-file.cjs";
4
+ import { Spacing, SpacingProps, __ΩSpacingProps } from "./spacing.cjs";
5
+ export { Output, OutputProps, SingleLineComment, SingleLineCommentProps, SingleLineCommentVariant, SourceFile, SourceFileProps, Spacing, SpacingProps, __ΩOutputProps, __ΩSingleLineCommentProps, __ΩSingleLineCommentVariant, __ΩSourceFileProps, __ΩSpacingProps };
@@ -0,0 +1,5 @@
1
+ import { Output, OutputProps, __ΩOutputProps } from "./output.mjs";
2
+ import { SingleLineComment, SingleLineCommentProps, SingleLineCommentVariant, __ΩSingleLineCommentProps, __ΩSingleLineCommentVariant } from "./single-line-comment.mjs";
3
+ import { SourceFile, SourceFileProps, __ΩSourceFileProps } from "./source-file.mjs";
4
+ import { Spacing, SpacingProps, __ΩSpacingProps } from "./spacing.mjs";
5
+ export { Output, OutputProps, SingleLineComment, SingleLineCommentProps, SingleLineCommentVariant, SourceFile, SourceFileProps, Spacing, SpacingProps, __ΩOutputProps, __ΩSingleLineCommentProps, __ΩSingleLineCommentVariant, __ΩSourceFileProps, __ΩSpacingProps };
@@ -0,0 +1,24 @@
1
+ import { MetaItem } from "../contexts/meta.cjs";
2
+ import * as _alloy_js_core0 from "@alloy-js/core";
3
+ import { OutputProps as OutputProps$1 } from "@alloy-js/core";
4
+ import { PluginContext } from "@powerlines/core";
5
+
6
+ //#region src/core/components/output.d.ts
7
+ interface OutputProps<TContext extends PluginContext = PluginContext> extends Omit<OutputProps$1, "basePath"> {
8
+ /**
9
+ * The current Powerlines process context.
10
+ */
11
+ context: TContext;
12
+ /**
13
+ * The file metadata collected during rendering.
14
+ */
15
+ meta?: Record<string, MetaItem>;
16
+ }
17
+ /**
18
+ * Output component for rendering the Powerlines plugin's output files via templates.
19
+ */
20
+ declare function Output<TContext extends PluginContext = PluginContext>(props: OutputProps<TContext>): _alloy_js_core0.Children;
21
+ declare type __ΩOutputProps = any[];
22
+ //#endregion
23
+ export { Output, OutputProps, __ΩOutputProps };
24
+ //# sourceMappingURL=output.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"output.d.cts","names":[],"sources":["../../../src/core/components/output.tsx"],"mappings":";;;;;;UAwBiB,WAAA,kBACE,aAAA,GAAgB,aAAA,UACzB,IAAA,CAAK,aAAA;;;;EAIb,OAAA,EAAS,QAAA;EANiB;;;EAW1B,IAAA,GAAO,MAAA,SAAe,QAAA;AAAA;;;;iBAMR,MAAA,kBAAwB,aAAA,GAAgB,aAAA,CAAA,CACtD,KAAA,EAAO,WAAA,CAAY,QAAA,IAAD,eAAA,CAAU,QAAA;AAAA"}
@@ -0,0 +1,24 @@
1
+ import { MetaItem } from "../contexts/meta.mjs";
2
+ import * as _alloy_js_core0 from "@alloy-js/core";
3
+ import { OutputProps as OutputProps$1 } from "@alloy-js/core";
4
+ import { PluginContext } from "@powerlines/core";
5
+
6
+ //#region src/core/components/output.d.ts
7
+ interface OutputProps<TContext extends PluginContext = PluginContext> extends Omit<OutputProps$1, "basePath"> {
8
+ /**
9
+ * The current Powerlines process context.
10
+ */
11
+ context: TContext;
12
+ /**
13
+ * The file metadata collected during rendering.
14
+ */
15
+ meta?: Record<string, MetaItem>;
16
+ }
17
+ /**
18
+ * Output component for rendering the Powerlines plugin's output files via templates.
19
+ */
20
+ declare function Output<TContext extends PluginContext = PluginContext>(props: OutputProps<TContext>): _alloy_js_core0.Children;
21
+ declare type __ΩOutputProps = any[];
22
+ //#endregion
23
+ export { Output, OutputProps, __ΩOutputProps };
24
+ //# sourceMappingURL=output.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"output.d.mts","names":[],"sources":["../../../src/core/components/output.tsx"],"mappings":";;;;;;UAwBiB,WAAA,kBACE,aAAA,GAAgB,aAAA,UACzB,IAAA,CAAK,aAAA;;;;EAIb,OAAA,EAAS,QAAA;EANiB;;;EAW1B,IAAA,GAAO,MAAA,SAAe,QAAA;AAAA;;;;iBAMR,MAAA,kBAAwB,aAAA,GAAgB,aAAA,CAAA,CACtD,KAAA,EAAO,WAAA,CAAY,QAAA,IAAD,eAAA,CAAU,QAAA;AAAA"}
@@ -36,4 +36,5 @@ function Output(props) {
36
36
  }
37
37
 
38
38
  //#endregion
39
- export { Output };
39
+ export { Output };
40
+ //# sourceMappingURL=output.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"output.mjs","names":[],"sources":["../../../src/core/components/output.tsx"],"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 type { OutputProps as OutputPropsExternal } from \"@alloy-js/core\";\nimport { computed, Output as OutputExternal, splitProps } from \"@alloy-js/core\";\nimport type { PluginContext } from \"@powerlines/core\";\nimport { MetaContext, MetaItem } from \"../contexts\";\nimport { PowerlinesContext } from \"../contexts/context\";\n\nexport interface OutputProps<\n TContext extends PluginContext = PluginContext\n> extends Omit<OutputPropsExternal, \"basePath\"> {\n /**\n * The current Powerlines process context.\n */\n context: TContext;\n\n /**\n * The file metadata collected during rendering.\n */\n meta?: Record<string, MetaItem>;\n}\n\n/**\n * Output component for rendering the Powerlines plugin's output files via templates.\n */\nexport function Output<TContext extends PluginContext = PluginContext>(\n props: OutputProps<TContext>\n) {\n const [{ children, context, meta = {} }, rest] = splitProps(props, [\n \"children\",\n \"context\",\n \"meta\"\n ]);\n\n const contextRef = computed(() => context);\n\n return (\n <MetaContext.Provider value={meta}>\n <PowerlinesContext.Provider value={contextRef.value}>\n <OutputExternal\n {...rest}\n basePath={contextRef.value.workspaceConfig.workspaceRoot}>\n {children}\n </OutputExternal>\n </PowerlinesContext.Provider>\n </MetaContext.Provider>\n );\n}\n"],"mappings":";;;;;;;;;;AAuCA,SAAU,OAA6D,OAAa;CAClF,MAAA,CAAA,EACF,UACE,SACA,OAAA,EAAA,IACA,QAAS,WAAU,OAAS;EAAA;EAAa;EAAQ;EAAW,CAAA;CAC5D,MAAG,aAAS,eAAA,QAAA;AACZ,QAAG,gBAAQ,YAAA,UAAA;EACT,OAAK;EACL,IAAA,WAAA;;IAEI,IAAA,QAAY;;;IAGf,IAAA,WAAY;AACV,YAAA,gBAA2B,UAAiB,WAAO,MAAA;MACjD,IAAA,WAAA;AACK,cAAI,WAAA,MAAA,gBAAA;;MAEC;MACT,CAAA,CAAA;;IAEJ,CAAA;;EAEN,CAAA"}
@@ -0,0 +1,23 @@
1
+ import { ComponentProps } from "../../types/components.cjs";
2
+ import * as _alloy_js_core0 from "@alloy-js/core";
3
+
4
+ //#region src/core/components/single-line-comment.d.ts
5
+ type SingleLineCommentVariant = "double-slash" | "triple-slash" | "slash-star" | "slash-star-star" | "markdown" | "yaml";
6
+ interface SingleLineCommentProps extends ComponentProps {
7
+ /**
8
+ * The variant of the single line comment.
9
+ *
10
+ * @defaultValue "double-slash"
11
+ */
12
+ variant?: SingleLineCommentVariant;
13
+ }
14
+ /**
15
+ * A single line comment block. The children are rendered as a prose element, which means that they
16
+ * are broken into multiple lines
17
+ */
18
+ declare function SingleLineComment(props: SingleLineCommentProps): _alloy_js_core0.Children;
19
+ declare type __ΩSingleLineCommentVariant = any[];
20
+ declare type __ΩSingleLineCommentProps = any[];
21
+ //#endregion
22
+ export { SingleLineComment, SingleLineCommentProps, SingleLineCommentVariant, __ΩSingleLineCommentProps, __ΩSingleLineCommentVariant };
23
+ //# sourceMappingURL=single-line-comment.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"single-line-comment.d.cts","names":[],"sources":["../../../src/core/components/single-line-comment.tsx"],"mappings":";;;;KAqBY,wBAAA;AAAA,UAQK,sBAAA,SAA+B,cAAA;;AARhD;;;;EAcE,OAAA,GAAU,wBAAA;AAAA;;;;;iBAOI,iBAAA,CAAkB,KAAA,EAAO,sBAAA,GAAsB,eAAA,CAAA,QAAA;AAAA"}
@@ -0,0 +1,23 @@
1
+ import { ComponentProps } from "../../types/components.mjs";
2
+ import * as _alloy_js_core0 from "@alloy-js/core";
3
+
4
+ //#region src/core/components/single-line-comment.d.ts
5
+ type SingleLineCommentVariant = "double-slash" | "triple-slash" | "slash-star" | "slash-star-star" | "markdown" | "yaml";
6
+ interface SingleLineCommentProps extends ComponentProps {
7
+ /**
8
+ * The variant of the single line comment.
9
+ *
10
+ * @defaultValue "double-slash"
11
+ */
12
+ variant?: SingleLineCommentVariant;
13
+ }
14
+ /**
15
+ * A single line comment block. The children are rendered as a prose element, which means that they
16
+ * are broken into multiple lines
17
+ */
18
+ declare function SingleLineComment(props: SingleLineCommentProps): _alloy_js_core0.Children;
19
+ declare type __ΩSingleLineCommentVariant = any[];
20
+ declare type __ΩSingleLineCommentProps = any[];
21
+ //#endregion
22
+ export { SingleLineComment, SingleLineCommentProps, SingleLineCommentVariant, __ΩSingleLineCommentProps, __ΩSingleLineCommentVariant };
23
+ //# sourceMappingURL=single-line-comment.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"single-line-comment.d.mts","names":[],"sources":["../../../src/core/components/single-line-comment.tsx"],"mappings":";;;;KAqBY,wBAAA;AAAA,UAQK,sBAAA,SAA+B,cAAA;;AARhD;;;;EAcE,OAAA,GAAU,wBAAA;AAAA;;;;;iBAOI,iBAAA,CAAkB,KAAA,EAAO,sBAAA,GAAsB,eAAA,CAAA,QAAA;AAAA"}
@@ -18,4 +18,5 @@ function SingleLineComment(props) {
18
18
  }
19
19
 
20
20
  //#endregion
21
- export { SingleLineComment };
21
+ export { SingleLineComment };
22
+ //# sourceMappingURL=single-line-comment.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"single-line-comment.mjs","names":[],"sources":["../../../src/core/components/single-line-comment.tsx"],"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 { Prose } from \"@alloy-js/core\";\nimport { ComponentProps } from \"../../types/components\";\n\nexport type SingleLineCommentVariant =\n | \"double-slash\"\n | \"triple-slash\"\n | \"slash-star\"\n | \"slash-star-star\"\n | \"markdown\"\n | \"yaml\";\n\nexport interface SingleLineCommentProps extends ComponentProps {\n /**\n * The variant of the single line comment.\n *\n * @defaultValue \"double-slash\"\n */\n variant?: SingleLineCommentVariant;\n}\n\n/**\n * A single line comment block. The children are rendered as a prose element, which means that they\n * are broken into multiple lines\n */\nexport function SingleLineComment(props: SingleLineCommentProps) {\n const { variant = \"double-slash\", children } = props;\n\n const commentStart =\n variant === \"slash-star\"\n ? \"/* \"\n : variant === \"slash-star-star\"\n ? \"/** \"\n : variant === \"triple-slash\"\n ? \"/// \"\n : variant === \"markdown\"\n ? \"<!-- \"\n : variant === \"yaml\"\n ? \"# \"\n : \"// \";\n\n return (\n <>\n {commentStart}\n <align string={commentStart}>\n <Prose>{children}</Prose>\n\n {variant === \"slash-star\" || variant === \"slash-star-star\"\n ? \" */ \"\n : variant === \"markdown\"\n ? \" -->\"\n : \"\"}\n </align>\n </>\n );\n}\n"],"mappings":";;;;;;;;AAmCA,SAAY,kBAAA,OAAwB;CACpC,MAAA,4BAEE,aACG;CACH,MAAK,eAAY,YAAS,eAAA,QAAA,YAAA,oBAAA,SAAA,YAAA,iBAAA,SAAA,YAAA,aAAA,UAAA,YAAA,SAAA,OAAA;AAC1B,QAAA,CAAA,cAAA,gBAAA,SAAA;EACF,QAAO;EACL,IAAM,WAAW;oCAEX,UACJ,CAAA,EAAA,YAAkB,gBAAK,YAAA,oBAAA,SAAA,YAAA,aAAA,SAAA,GAAA;;EAExB,CAAC,CAAC"}
@@ -0,0 +1,33 @@
1
+ import { ComponentProps } from "../../types/components.cjs";
2
+ import * as _alloy_js_core0 from "@alloy-js/core";
3
+ import { SourceFileProps as SourceFileProps$1 } from "@alloy-js/core";
4
+ import { StoragePreset } from "powerlines";
5
+
6
+ //#region src/core/components/source-file.d.ts
7
+ type SourceFileProps = SourceFileProps$1 & ComponentProps & {
8
+ /**
9
+ * The storage preset for the output files.
10
+ *
11
+ * @remarks
12
+ * If not specified, the output mode will be determined by the provided `output.mode` value.
13
+ */
14
+ storage?: StoragePreset;
15
+ /**
16
+ * The metadata associated with the source file.
17
+ *
18
+ * @remarks
19
+ * The values stored in the metadata will be available in the rendering context.
20
+ */
21
+ meta?: Record<string, any>;
22
+ };
23
+ /**
24
+ * A base component representing a Powerlines generated source file.
25
+ *
26
+ * @param props - The properties for the source file.
27
+ * @returns The rendered source file component.
28
+ */
29
+ declare function SourceFile(props: SourceFileProps): _alloy_js_core0.Children;
30
+ declare type __ΩSourceFileProps = any[];
31
+ //#endregion
32
+ export { SourceFile, SourceFileProps, __ΩSourceFileProps };
33
+ //# sourceMappingURL=source-file.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"source-file.d.cts","names":[],"sources":["../../../src/core/components/source-file.tsx"],"mappings":";;;;;;KAkCY,eAAA,GAAkB,iBAAA,GAC5B,cAAA;;;AADF;;;;EAQI,OAAA,GAAU,aAAA;EAAA;;;;;;EAQV,IAAA,GAAO,MAAA;AAAA;;;;;AASX;;iBAAgB,UAAA,CAAW,KAAA,EAAO,eAAA,GAAe,eAAA,CAAA,QAAA;AAAA"}
@@ -0,0 +1,33 @@
1
+ import { ComponentProps } from "../../types/components.mjs";
2
+ import * as _alloy_js_core0 from "@alloy-js/core";
3
+ import { SourceFileProps as SourceFileProps$1 } from "@alloy-js/core";
4
+ import { StoragePreset } from "powerlines";
5
+
6
+ //#region src/core/components/source-file.d.ts
7
+ type SourceFileProps = SourceFileProps$1 & ComponentProps & {
8
+ /**
9
+ * The storage preset for the output files.
10
+ *
11
+ * @remarks
12
+ * If not specified, the output mode will be determined by the provided `output.mode` value.
13
+ */
14
+ storage?: StoragePreset;
15
+ /**
16
+ * The metadata associated with the source file.
17
+ *
18
+ * @remarks
19
+ * The values stored in the metadata will be available in the rendering context.
20
+ */
21
+ meta?: Record<string, any>;
22
+ };
23
+ /**
24
+ * A base component representing a Powerlines generated source file.
25
+ *
26
+ * @param props - The properties for the source file.
27
+ * @returns The rendered source file component.
28
+ */
29
+ declare function SourceFile(props: SourceFileProps): _alloy_js_core0.Children;
30
+ declare type __ΩSourceFileProps = any[];
31
+ //#endregion
32
+ export { SourceFile, SourceFileProps, __ΩSourceFileProps };
33
+ //# sourceMappingURL=source-file.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"source-file.d.mts","names":[],"sources":["../../../src/core/components/source-file.tsx"],"mappings":";;;;;;KAkCY,eAAA,GAAkB,iBAAA,GAC5B,cAAA;;;AADF;;;;EAQI,OAAA,GAAU,aAAA;EAAA;;;;;;EAQV,IAAA,GAAO,MAAA;AAAA;;;;;AASX;;iBAAgB,UAAA,CAAW,KAAA,EAAO,eAAA,GAAe,eAAA,CAAA,QAAA;AAAA"}
@@ -58,4 +58,5 @@ function SourceFile(props) {
58
58
  }
59
59
 
60
60
  //#endregion
61
- export { SourceFile };
61
+ export { SourceFile };
62
+ //# sourceMappingURL=source-file.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"source-file.mjs","names":[],"sources":["../../../src/core/components/source-file.tsx"],"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 {\n getContext,\n Show,\n SourceDirectoryContext,\n SourceFileContext,\n SourceFileProps as SourceFilePropsExternal,\n splitProps,\n useContext,\n useFormatOptions\n} from \"@alloy-js/core\";\nimport { appendPath } from \"@stryke/path/append\";\nimport defu from \"defu\";\nimport type { StoragePreset } from \"powerlines\";\nimport { ComponentProps } from \"../../types/components\";\nimport { useMeta } from \"../contexts/meta\";\n\nexport type SourceFileProps = SourceFilePropsExternal &\n ComponentProps & {\n /**\n * The storage preset for the output files.\n *\n * @remarks\n * If not specified, the output mode will be determined by the provided `output.mode` value.\n */\n storage?: StoragePreset;\n\n /**\n * The metadata associated with the source file.\n *\n * @remarks\n * The values stored in the metadata will be available in the rendering context.\n */\n meta?: Record<string, any>;\n };\n\n/**\n * A base component representing a Powerlines generated source file.\n *\n * @param props - The properties for the source file.\n * @returns The rendered source file component.\n */\nexport function SourceFile(props: SourceFileProps) {\n const [{ children, meta, path, header, storage, filetype, reference }] =\n splitProps(props, [\n \"children\",\n \"meta\",\n \"path\",\n \"header\",\n \"storage\",\n \"filetype\",\n \"reference\"\n ]);\n\n const metadata = useMeta();\n const parentDirectory = useContext(SourceDirectoryContext)!;\n\n const sourceFile: SourceFileContext = {\n path: appendPath(path, parentDirectory.path),\n filetype,\n reference\n };\n parentDirectory?.addContent(sourceFile);\n\n const printOptions = useFormatOptions({\n printWidth: props.printWidth,\n tabWidth: props.tabWidth,\n useTabs: props.useTabs,\n insertFinalNewLine: props.insertFinalNewLine\n });\n\n const nodeContext = getContext()!;\n nodeContext.meta = defu(\n {\n sourceFile,\n printOptions\n },\n meta ?? {}\n );\n\n if (metadata) {\n metadata[sourceFile.path] = {\n storage,\n ...(meta ?? {})\n };\n }\n\n return (\n <SourceFileContext.Provider value={sourceFile}>\n <Show when={header !== undefined}>\n {header}\n <hbr />\n </Show>\n {children}\n </SourceFileContext.Provider>\n );\n}\n"],"mappings":";;;;;;;;;;;;;AAiDA,SAAM,WAAA,OAAA;CACJ,MAAM,CAAC,EACN,gBAED,MACE,QACH,SACG,UACA,eACF,WAAA,OAAA;EAAA;EAAA;EAAA;EAAA;EAAA;EAAA;EAAA;EAAA,CAAA;CACF,MAAO,WAAS,SAAW;CACzB,MAAM,kBAAkB,WAAO,uBAA2B;CAC1D,MAAE,aAAkB;EAClB,MAAG,WAAS,MAAA,gBAAA,KAAA;EACZ;EACA;EACD;AACD,kBAAa,WAAA,WAAA;CACb,MAAK,eAAS,iBAAA;EACZ,YAAY,MAAA;EACZ,UAAE,MAAA;;EAEJ,oBAAiB,MAAS;EAC1B,CAAA;;AAEA,aAAM,OAAY,KAAA;EAChB;EACA;EACD,EAAC,QAAA,EAAA,CAAA;AACF,KAAC,SACD,UAAA,WAAiB,QAAW;;EAE5B,GAAM,QAAA,EAAY;EAChB;AAEF,QAAE,gBAAsB,kBAAA,UAAA;EACtB,OAAA;EACA,IAAA,WAAA;;IAEI,MAAA,WAAc;IACpB,IAAA,WAAmB;AACjB,YAAA,CAAA,QAAA,gBAAA,OAAA,EAAA,CAAA,CAAA;;IAEE,CAAA,EAAA,SAAA;;EAEH,CAAC"}
@@ -0,0 +1,24 @@
1
+ import * as _alloy_js_core0 from "@alloy-js/core";
2
+
3
+ //#region src/core/components/spacing.d.ts
4
+ interface SpacingProps {
5
+ /**
6
+ * A scale factor that determines the amount of vertical space to be added.
7
+ *
8
+ * @remarks
9
+ * The default value is 1, which corresponds to a standard spacing. A value of 2 would double the spacing, while a value of 0.5 would halve it.
10
+ *
11
+ * @defaultValue 1
12
+ */
13
+ scale?: number;
14
+ }
15
+ /**
16
+ * A simple component that renders two horizontal breaks to create vertical spacing between elements.
17
+ */
18
+ declare function Spacing({
19
+ scale
20
+ }: SpacingProps): _alloy_js_core0.Children;
21
+ declare type __ΩSpacingProps = any[];
22
+ //#endregion
23
+ export { Spacing, SpacingProps, __ΩSpacingProps };
24
+ //# sourceMappingURL=spacing.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"spacing.d.cts","names":[],"sources":["../../../src/core/components/spacing.tsx"],"mappings":";;;UAoBiB,YAAA;;;AAAjB;;;;;AAeA;EANE,KAAA;AAAA;;;;iBAMc,OAAA,CAAA;EAAU;AAAA,GAAa,YAAA,GAAY,eAAA,CAAA,QAAA;AAAA"}
@@ -0,0 +1,24 @@
1
+ import * as _alloy_js_core0 from "@alloy-js/core";
2
+
3
+ //#region src/core/components/spacing.d.ts
4
+ interface SpacingProps {
5
+ /**
6
+ * A scale factor that determines the amount of vertical space to be added.
7
+ *
8
+ * @remarks
9
+ * The default value is 1, which corresponds to a standard spacing. A value of 2 would double the spacing, while a value of 0.5 would halve it.
10
+ *
11
+ * @defaultValue 1
12
+ */
13
+ scale?: number;
14
+ }
15
+ /**
16
+ * A simple component that renders two horizontal breaks to create vertical spacing between elements.
17
+ */
18
+ declare function Spacing({
19
+ scale
20
+ }: SpacingProps): _alloy_js_core0.Children;
21
+ declare type __ΩSpacingProps = any[];
22
+ //#endregion
23
+ export { Spacing, SpacingProps, __ΩSpacingProps };
24
+ //# sourceMappingURL=spacing.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"spacing.d.mts","names":[],"sources":["../../../src/core/components/spacing.tsx"],"mappings":";;;UAoBiB,YAAA;;;AAAjB;;;;;AAeA;EANE,KAAA;AAAA;;;;iBAMc,OAAA,CAAA;EAAU;AAAA,GAAa,YAAA,GAAY,eAAA,CAAA,QAAA;AAAA"}
@@ -15,4 +15,5 @@ function Spacing({ scale = 1 }) {
15
15
  }
16
16
 
17
17
  //#endregion
18
- export { Spacing };
18
+ export { Spacing };
19
+ //# sourceMappingURL=spacing.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"spacing.mjs","names":[],"sources":["../../../src/core/components/spacing.tsx"],"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 { For } from \"@alloy-js/core\";\n\nexport interface SpacingProps {\n /**\n * A scale factor that determines the amount of vertical space to be added.\n *\n * @remarks\n * The default value is 1, which corresponds to a standard spacing. A value of 2 would double the spacing, while a value of 0.5 would halve it.\n *\n * @defaultValue 1\n */\n scale?: number;\n}\n\n/**\n * A simple component that renders two horizontal breaks to create vertical spacing between elements.\n */\nexport function Spacing({ scale = 1 }: SpacingProps) {\n return (\n <For each={Array.from({ length: scale })}>\n {_ => (\n <>\n <hbr />\n <hbr />\n </>\n )}\n </For>\n );\n}\n"],"mappings":";;;;;;;AAmCA,SAAgB,QAAQ,EACtB,QAAO,KACM;AACb,QAAO,gBAAG,KAAA;EACR,IAAI,OAAC;AACH,UAAK,MAAK,KAAA,EACR,QAAQ,OACT,CAAC;;EAEJ,WAAK,MAAA,CAAA,gBAAA,OAAA,EAAA,CAAA,EAAA,gBAAA,OAAA,EAAA,CAAA,CAAA;EACN,CAAA"}
@@ -0,0 +1,29 @@
1
+ import { ComponentContext } from "@alloy-js/core";
2
+ import { PluginContext } from "powerlines";
3
+
4
+ //#region src/core/contexts/context.d.ts
5
+ /**
6
+ * The Powerlines context used in template rendering.
7
+ */
8
+ declare const PowerlinesContext: ComponentContext<PluginContext>;
9
+ /**
10
+ * Hook to access the Powerlines Context.
11
+ *
12
+ * @returns The Context.
13
+ */
14
+ declare function usePowerlinesContext<TContext extends PluginContext = PluginContext>(): TContext | undefined;
15
+ /**
16
+ * Hook to safely access the {@link PluginContext | Powerlines context}.
17
+ *
18
+ * @returns The Powerlines context or undefined if not set.
19
+ */
20
+ declare function usePowerlinesSafe<TContext extends PluginContext = PluginContext>(): TContext | undefined;
21
+ /**
22
+ * Hook to access the {@link PluginContext | Powerlines context}.
23
+ *
24
+ * @returns The Powerlines context.
25
+ */
26
+ declare function usePowerlines<TContext extends PluginContext = PluginContext>(): TContext;
27
+ //#endregion
28
+ export { PowerlinesContext, usePowerlines, usePowerlinesContext, usePowerlinesSafe };
29
+ //# sourceMappingURL=context.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"context.d.cts","names":[],"sources":["../../../src/core/contexts/context.ts"],"mappings":";;;;;;AA4BA;cAAa,iBAAA,EAAmB,gBAAA,CAAiB,aAAA;;;;AAQjD;;iBAAgB,oBAAA,kBACG,aAAA,GAAgB,aAAA,CAAA,CAAA,GAC9B,QAAA;;;;;;iBASW,iBAAA,kBACG,aAAA,GAAgB,aAAA,CAAA,CAAA,GAC9B,QAAA;;;;;;iBAWW,aAAA,kBACG,aAAA,GAAgB,aAAA,CAAA,CAAA,GAC9B,QAAA"}
@@ -0,0 +1,29 @@
1
+ import { ComponentContext } from "@alloy-js/core";
2
+ import { PluginContext } from "powerlines";
3
+
4
+ //#region src/core/contexts/context.d.ts
5
+ /**
6
+ * The Powerlines context used in template rendering.
7
+ */
8
+ declare const PowerlinesContext: ComponentContext<PluginContext>;
9
+ /**
10
+ * Hook to access the Powerlines Context.
11
+ *
12
+ * @returns The Context.
13
+ */
14
+ declare function usePowerlinesContext<TContext extends PluginContext = PluginContext>(): TContext | undefined;
15
+ /**
16
+ * Hook to safely access the {@link PluginContext | Powerlines context}.
17
+ *
18
+ * @returns The Powerlines context or undefined if not set.
19
+ */
20
+ declare function usePowerlinesSafe<TContext extends PluginContext = PluginContext>(): TContext | undefined;
21
+ /**
22
+ * Hook to access the {@link PluginContext | Powerlines context}.
23
+ *
24
+ * @returns The Powerlines context.
25
+ */
26
+ declare function usePowerlines<TContext extends PluginContext = PluginContext>(): TContext;
27
+ //#endregion
28
+ export { PowerlinesContext, usePowerlines, usePowerlinesContext, usePowerlinesSafe };
29
+ //# sourceMappingURL=context.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"context.d.mts","names":[],"sources":["../../../src/core/contexts/context.ts"],"mappings":";;;;;;AA4BA;cAAa,iBAAA,EAAmB,gBAAA,CAAiB,aAAA;;;;AAQjD;;iBAAgB,oBAAA,kBACG,aAAA,GAAgB,aAAA,CAAA,CAAA,GAC9B,QAAA;;;;;;iBASW,iBAAA,kBACG,aAAA,GAAgB,aAAA,CAAA,CAAA,GAC9B,QAAA;;;;;;iBAWW,aAAA,kBACG,aAAA,GAAgB,aAAA,CAAA,CAAA,GAC9B,QAAA"}
@@ -33,4 +33,5 @@ function usePowerlines() {
33
33
  }
34
34
 
35
35
  //#endregion
36
- export { PowerlinesContext, usePowerlines, usePowerlinesContext, usePowerlinesSafe };
36
+ export { PowerlinesContext, usePowerlines, usePowerlinesContext, usePowerlinesSafe };
37
+ //# sourceMappingURL=context.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"context.mjs","names":[],"sources":["../../../src/core/contexts/context.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 {\n ComponentContext,\n createNamedContext,\n useContext\n} from \"@alloy-js/core\";\nimport type { PluginContext } from \"powerlines\";\n\n/**\n * The Powerlines context used in template rendering.\n */\nexport const PowerlinesContext: ComponentContext<PluginContext> =\n createNamedContext<PluginContext>(\"Powerlines\");\n\n/**\n * Hook to access the Powerlines Context.\n *\n * @returns The Context.\n */\nexport function usePowerlinesContext<\n TContext extends PluginContext = PluginContext\n>(): TContext | undefined {\n return useContext(PowerlinesContext) as TContext | undefined;\n}\n\n/**\n * Hook to safely access the {@link PluginContext | Powerlines context}.\n *\n * @returns The Powerlines context or undefined if not set.\n */\nexport function usePowerlinesSafe<\n TContext extends PluginContext = PluginContext\n>(): TContext | undefined {\n const powerlines = usePowerlinesContext<TContext>();\n\n return powerlines ?? undefined;\n}\n\n/**\n * Hook to access the {@link PluginContext | Powerlines context}.\n *\n * @returns The Powerlines context.\n */\nexport function usePowerlines<\n TContext extends PluginContext = PluginContext\n>(): TContext {\n const powerlines = usePowerlinesSafe<TContext>();\n if (!powerlines) {\n throw new Error(\n \"Powerlines - Context is not set. Please make sure the Alloy components are being provided to an invocation of the `render` function added to plugins by `@powerlines/plugin-alloy`.\"\n );\n }\n\n return powerlines;\n}\n"],"mappings":";;;;;;AA4BA,MAAa,oBACX,mBAAkC,aAAa;;;;;;AAOjD,SAAgB,uBAEU;AACxB,QAAO,WAAW,kBAAkB;;;;;;;AAQtC,SAAgB,oBAEU;AAGxB,QAFmB,sBAAgC,IAE9B;;;;;;;AAQvB,SAAgB,gBAEF;CACZ,MAAM,aAAa,mBAA6B;AAChD,KAAI,CAAC,WACH,OAAM,IAAI,MACR,sLACD;AAGH,QAAO"}
@@ -0,0 +1,4 @@
1
+ import { PowerlinesContext, usePowerlines, usePowerlinesContext, usePowerlinesSafe } from "./context.cjs";
2
+ import { MetaContext, MetaItem, __ΩMetaItem, useMeta, useMetaContext, useMetaSafe } from "./meta.cjs";
3
+ import { ReflectionClassContext, ReflectionClassContextInterface, ReflectionMethodContext, ReflectionParameterContext, ReflectionPropertyContext, __ΩReflectionClassContextInterface, useReflectionClass, useReflectionMethod, useReflectionParameter, useReflectionProperty } from "./reflection.cjs";
4
+ export { MetaContext, MetaItem, PowerlinesContext, ReflectionClassContext, ReflectionClassContextInterface, ReflectionMethodContext, ReflectionParameterContext, ReflectionPropertyContext, __ΩMetaItem, __ΩReflectionClassContextInterface, useMeta, useMetaContext, useMetaSafe, usePowerlines, usePowerlinesContext, usePowerlinesSafe, useReflectionClass, useReflectionMethod, useReflectionParameter, useReflectionProperty };
@@ -0,0 +1,4 @@
1
+ import { PowerlinesContext, usePowerlines, usePowerlinesContext, usePowerlinesSafe } from "./context.mjs";
2
+ import { MetaContext, MetaItem, __ΩMetaItem, useMeta, useMetaContext, useMetaSafe } from "./meta.mjs";
3
+ import { ReflectionClassContext, ReflectionClassContextInterface, ReflectionMethodContext, ReflectionParameterContext, ReflectionPropertyContext, __ΩReflectionClassContextInterface, useReflectionClass, useReflectionMethod, useReflectionParameter, useReflectionProperty } from "./reflection.mjs";
4
+ export { MetaContext, MetaItem, PowerlinesContext, ReflectionClassContext, ReflectionClassContextInterface, ReflectionMethodContext, ReflectionParameterContext, ReflectionPropertyContext, __ΩMetaItem, __ΩReflectionClassContextInterface, useMeta, useMetaContext, useMetaSafe, usePowerlines, usePowerlinesContext, usePowerlinesSafe, useReflectionClass, useReflectionMethod, useReflectionParameter, useReflectionProperty };
@@ -0,0 +1,48 @@
1
+ import { ComponentContext } from "@alloy-js/core";
2
+ import { StoragePreset } from "powerlines";
3
+
4
+ //#region src/core/contexts/meta.d.ts
5
+ interface MetaItem {
6
+ /**
7
+ * The kind of metadata item.
8
+ */
9
+ kind?: "builtin" | "entry" | string;
10
+ /**
11
+ * Whether to skip formatting for this output.
12
+ */
13
+ skipFormat?: boolean;
14
+ /**
15
+ * The storage preset or adapter name for the output files.
16
+ *
17
+ * @remarks
18
+ * If not specified, the output mode will be determined by the provided `output.mode` value.
19
+ */
20
+ storage?: StoragePreset | string;
21
+ [key: string]: any;
22
+ }
23
+ /**
24
+ * The Powerlines meta context used to determine metadata of files generated during rendering.
25
+ */
26
+ declare const MetaContext: ComponentContext<Record<string, MetaItem>>;
27
+ /**
28
+ * Hook to access the Powerlines Context.
29
+ *
30
+ * @returns The Context.
31
+ */
32
+ declare function useMetaContext(): Record<string, MetaItem> | undefined;
33
+ /**
34
+ * Hook to safely access the render context's metadata.
35
+ *
36
+ * @returns The Powerlines context or undefined if not set.
37
+ */
38
+ declare function useMetaSafe(): Record<string, MetaItem> | undefined;
39
+ /**
40
+ * Hook to access the render context's metadata.
41
+ *
42
+ * @returns The Powerlines context.
43
+ */
44
+ declare function useMeta(): Record<string, MetaItem>;
45
+ declare type __ΩMetaItem = any[];
46
+ //#endregion
47
+ export { MetaContext, MetaItem, __ΩMetaItem, useMeta, useMetaContext, useMetaSafe };
48
+ //# sourceMappingURL=meta.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"meta.d.cts","names":[],"sources":["../../../src/core/contexts/meta.ts"],"mappings":";;;;UAyBiB,QAAA;;AAAjB;;EAIE,IAAA;EAauB;;;EARvB,UAAA;EAQU;;;;AAQZ;;EARE,OAAA,GAAU,aAAA;EAAA,CAET,GAAA;AAAA;;;;cAMU,WAAA,EAAa,gBAAA,CAAiB,MAAA,SAAe,QAAA;;;;;AAQ1D;iBAAgB,cAAA,CAAA,GAAkB,MAAA,SAAe,QAAA;;;;AASjD;;iBAAgB,WAAA,CAAA,GAAe,MAAA,SAAe,QAAA;;;AAW9C;;;iBAAgB,OAAA,CAAA,GAAW,MAAA,SAAe,QAAA;AAAA"}
@@ -0,0 +1,48 @@
1
+ import { ComponentContext } from "@alloy-js/core";
2
+ import { StoragePreset } from "powerlines";
3
+
4
+ //#region src/core/contexts/meta.d.ts
5
+ interface MetaItem {
6
+ /**
7
+ * The kind of metadata item.
8
+ */
9
+ kind?: "builtin" | "entry" | string;
10
+ /**
11
+ * Whether to skip formatting for this output.
12
+ */
13
+ skipFormat?: boolean;
14
+ /**
15
+ * The storage preset or adapter name for the output files.
16
+ *
17
+ * @remarks
18
+ * If not specified, the output mode will be determined by the provided `output.mode` value.
19
+ */
20
+ storage?: StoragePreset | string;
21
+ [key: string]: any;
22
+ }
23
+ /**
24
+ * The Powerlines meta context used to determine metadata of files generated during rendering.
25
+ */
26
+ declare const MetaContext: ComponentContext<Record<string, MetaItem>>;
27
+ /**
28
+ * Hook to access the Powerlines Context.
29
+ *
30
+ * @returns The Context.
31
+ */
32
+ declare function useMetaContext(): Record<string, MetaItem> | undefined;
33
+ /**
34
+ * Hook to safely access the render context's metadata.
35
+ *
36
+ * @returns The Powerlines context or undefined if not set.
37
+ */
38
+ declare function useMetaSafe(): Record<string, MetaItem> | undefined;
39
+ /**
40
+ * Hook to access the render context's metadata.
41
+ *
42
+ * @returns The Powerlines context.
43
+ */
44
+ declare function useMeta(): Record<string, MetaItem>;
45
+ declare type __ΩMetaItem = any[];
46
+ //#endregion
47
+ export { MetaContext, MetaItem, __ΩMetaItem, useMeta, useMetaContext, useMetaSafe };
48
+ //# sourceMappingURL=meta.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"meta.d.mts","names":[],"sources":["../../../src/core/contexts/meta.ts"],"mappings":";;;;UAyBiB,QAAA;;AAAjB;;EAIE,IAAA;EAauB;;;EARvB,UAAA;EAQU;;;;AAQZ;;EARE,OAAA,GAAU,aAAA;EAAA,CAET,GAAA;AAAA;;;;cAMU,WAAA,EAAa,gBAAA,CAAiB,MAAA,SAAe,QAAA;;;;;AAQ1D;iBAAgB,cAAA,CAAA,GAAkB,MAAA,SAAe,QAAA;;;;AASjD;;iBAAgB,WAAA,CAAA,GAAe,MAAA,SAAe,QAAA;;;AAW9C;;;iBAAgB,OAAA,CAAA,GAAW,MAAA,SAAe,QAAA;AAAA"}
@@ -33,4 +33,5 @@ function useMeta() {
33
33
  }
34
34
 
35
35
  //#endregion
36
- export { MetaContext, useMeta, useMetaContext, useMetaSafe };
36
+ export { MetaContext, useMeta, useMetaContext, useMetaSafe };
37
+ //# sourceMappingURL=meta.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"meta.mjs","names":[],"sources":["../../../src/core/contexts/meta.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 {\n ComponentContext,\n createNamedContext,\n useContext\n} from \"@alloy-js/core\";\nimport type { StoragePreset } from \"powerlines\";\n\nexport interface MetaItem {\n /**\n * The kind of metadata item.\n */\n kind?: \"builtin\" | \"entry\" | string;\n\n /**\n * Whether to skip formatting for this output.\n */\n skipFormat?: boolean;\n\n /**\n * The storage preset or adapter name for the output files.\n *\n * @remarks\n * If not specified, the output mode will be determined by the provided `output.mode` value.\n */\n storage?: StoragePreset | string;\n\n [key: string]: any;\n}\n\n/**\n * The Powerlines meta context used to determine metadata of files generated during rendering.\n */\nexport const MetaContext: ComponentContext<Record<string, MetaItem>> =\n createNamedContext<Record<string, MetaItem>>(\"Meta\");\n\n/**\n * Hook to access the Powerlines Context.\n *\n * @returns The Context.\n */\nexport function useMetaContext(): Record<string, MetaItem> | undefined {\n return useContext(MetaContext);\n}\n\n/**\n * Hook to safely access the render context's metadata.\n *\n * @returns The Powerlines context or undefined if not set.\n */\nexport function useMetaSafe(): Record<string, MetaItem> | undefined {\n const meta = useMetaContext();\n\n return meta ?? undefined;\n}\n\n/**\n * Hook to access the render context's metadata.\n *\n * @returns The Powerlines context.\n */\nexport function useMeta(): Record<string, MetaItem> {\n const meta = useMetaSafe();\n if (!meta) {\n throw new Error(\n \"Powerlines metadata is not available in the rendering context. Please make sure the Alloy components are being provided to an invocation of the `render` function added to plugins by `@powerlines/plugin-alloy`.\"\n );\n }\n\n return meta;\n}\n"],"mappings":";;;;;;AAkDA,MAAa,cACX,mBAA6C,OAAO;;;;;;AAOtD,SAAgB,iBAAuD;AACrE,QAAO,WAAW,YAAY;;;;;;;AAQhC,SAAgB,cAAoD;AAGlE,QAFa,gBAAgB,IAEd;;;;;;;AAQjB,SAAgB,UAAoC;CAClD,MAAM,OAAO,aAAa;AAC1B,KAAI,CAAC,KACH,OAAM,IAAI,MACR,oNACD;AAGH,QAAO"}
@@ -0,0 +1,53 @@
1
+ import { ReflectionOverrideInterface } from "../../types/components.cjs";
2
+ import { ComponentContext } from "@alloy-js/core";
3
+ import { ReflectionClass, ReflectionMethod, ReflectionParameter, ReflectionProperty } from "@powerlines/deepkit/vendor/type";
4
+
5
+ //#region src/core/contexts/reflection.d.ts
6
+ interface ReflectionClassContextInterface<T extends Record<string, any> = Record<string, any>> {
7
+ reflection: ReflectionClass<T>;
8
+ override?: ReflectionOverrideInterface<T>;
9
+ }
10
+ /**
11
+ * The reflection class context used in template rendering.
12
+ */
13
+ declare const ReflectionClassContext: ComponentContext<ReflectionClassContextInterface<any>>;
14
+ /**
15
+ * Hook to access the Reflection context.
16
+ *
17
+ * @returns A reactive version of the current reflection.
18
+ */
19
+ declare function useReflectionClass<T extends Record<string, any> = Record<string, any>>(): ReflectionClassContextInterface<T>;
20
+ /**
21
+ * The reflection property context used in template rendering.
22
+ */
23
+ declare const ReflectionPropertyContext: ComponentContext<ReflectionProperty>;
24
+ /**
25
+ * Hook to access the Reflection Property context.
26
+ *
27
+ * @returns A reactive version of the current reflection.
28
+ */
29
+ declare function useReflectionProperty(): ReflectionProperty;
30
+ /**
31
+ * The reflection method context used in template rendering.
32
+ */
33
+ declare const ReflectionMethodContext: ComponentContext<ReflectionMethod>;
34
+ /**
35
+ * Hook to access the Reflection Method context.
36
+ *
37
+ * @returns A reactive version of the current reflection.
38
+ */
39
+ declare function useReflectionMethod(): ReflectionMethod;
40
+ /**
41
+ * The reflection parameter context used in template rendering.
42
+ */
43
+ declare const ReflectionParameterContext: ComponentContext<ReflectionParameter>;
44
+ /**
45
+ * Hook to access the Reflection Parameter context.
46
+ *
47
+ * @returns A reactive version of the current reflection.
48
+ */
49
+ declare function useReflectionParameter(): ReflectionParameter;
50
+ declare type __ΩReflectionClassContextInterface = any[];
51
+ //#endregion
52
+ export { ReflectionClassContext, ReflectionClassContextInterface, ReflectionMethodContext, ReflectionParameterContext, ReflectionPropertyContext, __ΩReflectionClassContextInterface, useReflectionClass, useReflectionMethod, useReflectionParameter, useReflectionProperty };
53
+ //# sourceMappingURL=reflection.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"reflection.d.cts","names":[],"sources":["../../../src/core/contexts/reflection.ts"],"mappings":";;;;;UA4BiB,+BAAA,WACL,MAAA,gBAAsB,MAAA;EAEhC,UAAA,EAAY,eAAA,CAAgB,CAAA;EAC5B,QAAA,GAAW,2BAAA,CAA4B,CAAA;AAAA;;;;cAM5B,sBAAA,EAAwB,gBAAA,CACnC,+BAAA;;;;;;iBAQc,kBAAA,WACJ,MAAA,gBAAsB,MAAA,cAAA,CAAA,GAAmB,+BAAA,CAAA,CAAA;;;;cAkBxC,yBAAA,EAA2B,gBAAA,CAAiB,kBAAA;;;;;;iBAQzC,qBAAA,CAAA,GAAqB,kBAAA;AApCrC;;;AAAA,cAmDa,uBAAA,EAAyB,gBAAA,CAAiB,gBAAA;;AA1CvD;;;;iBAkDgB,mBAAA,CAAA,GAAmB,gBAAA;;;;cAetB,0BAAA,EAA4B,gBAAA,CAAiB,mBAAA;;;;;;iBAQ1C,sBAAA,CAAA,GAAsB,mBAAA;AAAA"}