@powerlines/plugin-alloy 0.26.51 → 0.26.52

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 (377) hide show
  1. package/dist/_virtual/_rolldown/runtime.cjs +1 -0
  2. package/dist/core/components/index.cjs +1 -0
  3. package/dist/core/components/index.d.cts +6 -0
  4. package/dist/core/components/index.d.mts +6 -0
  5. package/dist/core/components/index.mjs +1 -0
  6. package/dist/core/components/infrastructure-file.cjs +1 -0
  7. package/dist/core/components/infrastructure-file.d.cts +27 -0
  8. package/dist/core/components/infrastructure-file.d.cts.map +1 -0
  9. package/dist/core/components/infrastructure-file.d.mts +27 -0
  10. package/dist/core/components/infrastructure-file.d.mts.map +1 -0
  11. package/dist/core/components/infrastructure-file.mjs +2 -0
  12. package/dist/core/components/infrastructure-file.mjs.map +1 -0
  13. package/dist/core/components/output.cjs +1 -0
  14. package/dist/core/components/output.d.cts +23 -0
  15. package/dist/core/components/output.d.cts.map +1 -0
  16. package/dist/core/components/output.d.mts +23 -0
  17. package/dist/core/components/output.d.mts.map +1 -0
  18. package/dist/core/components/output.mjs +2 -0
  19. package/dist/core/components/output.mjs.map +1 -0
  20. package/dist/core/components/single-line-comment.cjs +1 -0
  21. package/dist/core/components/single-line-comment.d.cts +21 -0
  22. package/dist/core/components/single-line-comment.d.cts.map +1 -0
  23. package/dist/core/components/single-line-comment.d.mts +21 -0
  24. package/dist/core/components/single-line-comment.d.mts.map +1 -0
  25. package/dist/core/components/single-line-comment.mjs +2 -0
  26. package/dist/core/components/single-line-comment.mjs.map +1 -0
  27. package/dist/core/components/source-file.cjs +1 -0
  28. package/dist/core/components/source-file.d.cts +32 -0
  29. package/dist/core/components/source-file.d.cts.map +1 -0
  30. package/dist/core/components/source-file.d.mts +32 -0
  31. package/dist/core/components/source-file.d.mts.map +1 -0
  32. package/dist/core/components/source-file.mjs +2 -0
  33. package/dist/core/components/source-file.mjs.map +1 -0
  34. package/dist/core/components/spacing.cjs +1 -0
  35. package/dist/core/components/spacing.d.cts +23 -0
  36. package/dist/core/components/spacing.d.cts.map +1 -0
  37. package/dist/core/components/spacing.d.mts +23 -0
  38. package/dist/core/components/spacing.d.mts.map +1 -0
  39. package/dist/core/components/spacing.mjs +2 -0
  40. package/dist/core/components/spacing.mjs.map +1 -0
  41. package/dist/core/contexts/context.cjs +1 -0
  42. package/dist/core/contexts/context.d.cts +29 -0
  43. package/dist/core/contexts/context.d.cts.map +1 -0
  44. package/dist/core/contexts/context.d.mts +29 -0
  45. package/dist/core/contexts/context.d.mts.map +1 -0
  46. package/dist/core/contexts/context.mjs +2 -0
  47. package/dist/core/contexts/context.mjs.map +1 -0
  48. package/dist/core/contexts/index.cjs +1 -0
  49. package/dist/core/contexts/index.d.cts +4 -0
  50. package/dist/core/contexts/index.d.mts +4 -0
  51. package/dist/core/contexts/index.mjs +1 -0
  52. package/dist/core/contexts/meta.cjs +1 -0
  53. package/dist/core/contexts/meta.d.cts +47 -0
  54. package/dist/core/contexts/meta.d.cts.map +1 -0
  55. package/dist/core/contexts/meta.d.mts +47 -0
  56. package/dist/core/contexts/meta.d.mts.map +1 -0
  57. package/dist/core/contexts/meta.mjs +2 -0
  58. package/dist/core/contexts/meta.mjs.map +1 -0
  59. package/dist/core/contexts/reflection.cjs +1 -0
  60. package/dist/core/contexts/reflection.d.cts +62 -0
  61. package/dist/core/contexts/reflection.d.cts.map +1 -0
  62. package/dist/core/contexts/reflection.d.mts +62 -0
  63. package/dist/core/contexts/reflection.d.mts.map +1 -0
  64. package/dist/core/contexts/reflection.mjs +2 -0
  65. package/dist/core/contexts/reflection.mjs.map +1 -0
  66. package/dist/core/helpers/code.cjs +1 -0
  67. package/dist/core/helpers/code.d.cts +29 -0
  68. package/dist/core/helpers/code.d.cts.map +1 -0
  69. package/dist/core/helpers/code.d.mts +29 -0
  70. package/dist/core/helpers/code.d.mts.map +1 -0
  71. package/dist/core/helpers/code.mjs +2 -0
  72. package/dist/core/helpers/code.mjs.map +1 -0
  73. package/dist/core/helpers/index.cjs +1 -0
  74. package/dist/core/helpers/index.d.cts +2 -0
  75. package/dist/core/helpers/index.d.mts +2 -0
  76. package/dist/core/helpers/index.mjs +1 -0
  77. package/dist/core/index.cjs +1 -0
  78. package/dist/core/index.d.cts +10 -0
  79. package/dist/core/index.d.mts +10 -0
  80. package/dist/core/index.mjs +1 -0
  81. package/dist/hcl/components/block-declaration.cjs +1 -0
  82. package/dist/hcl/components/block-declaration.d.cts +21 -0
  83. package/dist/hcl/components/block-declaration.d.cts.map +1 -0
  84. package/dist/hcl/components/block-declaration.d.mts +21 -0
  85. package/dist/hcl/components/block-declaration.d.mts.map +1 -0
  86. package/dist/hcl/components/block-declaration.mjs +2 -0
  87. package/dist/hcl/components/block-declaration.mjs.map +1 -0
  88. package/dist/hcl/components/hcl-file.cjs +1 -0
  89. package/dist/hcl/components/hcl-file.d.cts +26 -0
  90. package/dist/hcl/components/hcl-file.d.cts.map +1 -0
  91. package/dist/hcl/components/hcl-file.d.mts +26 -0
  92. package/dist/hcl/components/hcl-file.d.mts.map +1 -0
  93. package/dist/hcl/components/hcl-file.mjs +2 -0
  94. package/dist/hcl/components/hcl-file.mjs.map +1 -0
  95. package/dist/hcl/components/index.cjs +1 -0
  96. package/dist/hcl/components/index.d.cts +5 -0
  97. package/dist/hcl/components/index.d.mts +5 -0
  98. package/dist/hcl/components/index.mjs +1 -0
  99. package/dist/hcl/components/packer-file.cjs +1 -0
  100. package/dist/hcl/components/packer-file.d.cts +18 -0
  101. package/dist/hcl/components/packer-file.d.cts.map +1 -0
  102. package/dist/hcl/components/packer-file.d.mts +18 -0
  103. package/dist/hcl/components/packer-file.d.mts.map +1 -0
  104. package/dist/hcl/components/packer-file.mjs +2 -0
  105. package/dist/hcl/components/packer-file.mjs.map +1 -0
  106. package/dist/hcl/components/terraform-file.cjs +1 -0
  107. package/dist/hcl/components/terraform-file.d.cts +19 -0
  108. package/dist/hcl/components/terraform-file.d.cts.map +1 -0
  109. package/dist/hcl/components/terraform-file.d.mts +19 -0
  110. package/dist/hcl/components/terraform-file.d.mts.map +1 -0
  111. package/dist/hcl/components/terraform-file.mjs +2 -0
  112. package/dist/hcl/components/terraform-file.mjs.map +1 -0
  113. package/dist/hcl/index.cjs +1 -0
  114. package/dist/hcl/index.d.cts +5 -0
  115. package/dist/hcl/index.d.mts +5 -0
  116. package/dist/hcl/index.mjs +1 -0
  117. package/dist/helpers/capnp.cjs +69 -0
  118. package/dist/helpers/capnp.d.cts +83 -0
  119. package/dist/helpers/capnp.d.cts.map +1 -0
  120. package/dist/helpers/capnp.d.mts +83 -0
  121. package/dist/helpers/capnp.d.mts.map +1 -0
  122. package/dist/helpers/capnp.mjs +70 -0
  123. package/dist/helpers/capnp.mjs.map +1 -0
  124. package/dist/helpers/create-builtin.cjs +1 -0
  125. package/dist/helpers/create-builtin.d.cts +15 -0
  126. package/dist/helpers/create-builtin.d.cts.map +1 -0
  127. package/dist/helpers/create-builtin.d.mts +15 -0
  128. package/dist/helpers/create-builtin.d.mts.map +1 -0
  129. package/dist/helpers/create-builtin.mjs +2 -0
  130. package/dist/helpers/create-builtin.mjs.map +1 -0
  131. package/dist/helpers/index.cjs +1 -0
  132. package/dist/helpers/index.d.cts +5 -0
  133. package/dist/helpers/index.d.mts +5 -0
  134. package/dist/helpers/index.mjs +1 -0
  135. package/dist/helpers/refkey.cjs +1 -0
  136. package/dist/helpers/refkey.d.cts +13 -0
  137. package/dist/helpers/refkey.d.cts.map +1 -0
  138. package/dist/helpers/refkey.d.mts +13 -0
  139. package/dist/helpers/refkey.d.mts.map +1 -0
  140. package/dist/helpers/refkey.mjs +2 -0
  141. package/dist/helpers/refkey.mjs.map +1 -0
  142. package/dist/helpers/typescript.cjs +24 -0
  143. package/dist/helpers/typescript.d.cts +24 -0
  144. package/dist/helpers/typescript.d.cts.map +1 -0
  145. package/dist/helpers/typescript.d.mts +24 -0
  146. package/dist/helpers/typescript.d.mts.map +1 -0
  147. package/dist/helpers/typescript.mjs +25 -0
  148. package/dist/helpers/typescript.mjs.map +1 -0
  149. package/dist/index.cjs +1 -0
  150. package/dist/index.d.cts +19 -0
  151. package/dist/index.d.cts.map +1 -0
  152. package/dist/index.d.mts +19 -0
  153. package/dist/index.d.mts.map +1 -0
  154. package/dist/index.mjs +2 -0
  155. package/dist/index.mjs.map +1 -0
  156. package/dist/markdown/components/front-matter.cjs +1 -0
  157. package/dist/markdown/components/front-matter.d.cts +15 -0
  158. package/dist/markdown/components/front-matter.d.cts.map +1 -0
  159. package/dist/markdown/components/front-matter.d.mts +15 -0
  160. package/dist/markdown/components/front-matter.d.mts.map +1 -0
  161. package/dist/markdown/components/front-matter.mjs +2 -0
  162. package/dist/markdown/components/front-matter.mjs.map +1 -0
  163. package/dist/markdown/components/heading.cjs +1 -0
  164. package/dist/markdown/components/heading.d.cts +19 -0
  165. package/dist/markdown/components/heading.d.cts.map +1 -0
  166. package/dist/markdown/components/heading.d.mts +19 -0
  167. package/dist/markdown/components/heading.d.mts.map +1 -0
  168. package/dist/markdown/components/heading.mjs +2 -0
  169. package/dist/markdown/components/heading.mjs.map +1 -0
  170. package/dist/markdown/components/index.cjs +1 -0
  171. package/dist/markdown/components/index.d.cts +5 -0
  172. package/dist/markdown/components/index.d.mts +5 -0
  173. package/dist/markdown/components/index.mjs +1 -0
  174. package/dist/markdown/components/markdown-file.cjs +1 -0
  175. package/dist/markdown/components/markdown-file.d.cts +27 -0
  176. package/dist/markdown/components/markdown-file.d.cts.map +1 -0
  177. package/dist/markdown/components/markdown-file.d.mts +27 -0
  178. package/dist/markdown/components/markdown-file.d.mts.map +1 -0
  179. package/dist/markdown/components/markdown-file.mjs +2 -0
  180. package/dist/markdown/components/markdown-file.mjs.map +1 -0
  181. package/dist/markdown/components/markdown-table.cjs +1 -0
  182. package/dist/markdown/components/markdown-table.d.cts +26 -0
  183. package/dist/markdown/components/markdown-table.d.cts.map +1 -0
  184. package/dist/markdown/components/markdown-table.d.mts +26 -0
  185. package/dist/markdown/components/markdown-table.d.mts.map +1 -0
  186. package/dist/markdown/components/markdown-table.mjs +2 -0
  187. package/dist/markdown/components/markdown-table.mjs.map +1 -0
  188. package/dist/markdown/contexts/index.cjs +1 -0
  189. package/dist/markdown/contexts/index.d.cts +2 -0
  190. package/dist/markdown/contexts/index.d.mts +2 -0
  191. package/dist/markdown/contexts/index.mjs +1 -0
  192. package/dist/markdown/contexts/markdown-table.cjs +1 -0
  193. package/dist/markdown/contexts/markdown-table.d.cts +36 -0
  194. package/dist/markdown/contexts/markdown-table.d.cts.map +1 -0
  195. package/dist/markdown/contexts/markdown-table.d.mts +36 -0
  196. package/dist/markdown/contexts/markdown-table.d.mts.map +1 -0
  197. package/dist/markdown/contexts/markdown-table.mjs +2 -0
  198. package/dist/markdown/contexts/markdown-table.mjs.map +1 -0
  199. package/dist/markdown/index.cjs +1 -0
  200. package/dist/markdown/index.d.cts +6 -0
  201. package/dist/markdown/index.d.mts +6 -0
  202. package/dist/markdown/index.mjs +1 -0
  203. package/dist/render.cjs +1 -0
  204. package/dist/render.d.cts +38 -0
  205. package/dist/render.d.cts.map +1 -0
  206. package/dist/render.d.mts +38 -0
  207. package/dist/render.d.mts.map +1 -0
  208. package/dist/render.mjs +2 -0
  209. package/dist/render.mjs.map +1 -0
  210. package/dist/types/components.cjs +0 -0
  211. package/dist/types/components.d.cts +126 -0
  212. package/dist/types/components.d.cts.map +1 -0
  213. package/dist/types/components.d.mts +126 -0
  214. package/dist/types/components.d.mts.map +1 -0
  215. package/dist/types/components.mjs +2 -0
  216. package/dist/types/components.mjs.map +1 -0
  217. package/dist/types/index.cjs +0 -0
  218. package/dist/types/index.d.cts +3 -0
  219. package/dist/types/index.d.mts +3 -0
  220. package/dist/types/index.mjs +1 -0
  221. package/dist/types/plugin.cjs +0 -0
  222. package/dist/types/plugin.d.cts +35 -0
  223. package/dist/types/plugin.d.cts.map +1 -0
  224. package/dist/types/plugin.d.mts +35 -0
  225. package/dist/types/plugin.d.mts.map +1 -0
  226. package/dist/types/plugin.mjs +1 -0
  227. package/dist/typescript/components/builtin-file.cjs +1 -0
  228. package/dist/typescript/components/builtin-file.d.cts +34 -0
  229. package/dist/typescript/components/builtin-file.d.cts.map +1 -0
  230. package/dist/typescript/components/builtin-file.d.mts +34 -0
  231. package/dist/typescript/components/builtin-file.d.mts.map +1 -0
  232. package/dist/typescript/components/builtin-file.mjs +2 -0
  233. package/dist/typescript/components/builtin-file.mjs.map +1 -0
  234. package/dist/typescript/components/class-declaration.cjs +1 -0
  235. package/dist/typescript/components/class-declaration.d.cts +140 -0
  236. package/dist/typescript/components/class-declaration.d.cts.map +1 -0
  237. package/dist/typescript/components/class-declaration.d.mts +140 -0
  238. package/dist/typescript/components/class-declaration.d.mts.map +1 -0
  239. package/dist/typescript/components/class-declaration.mjs +2 -0
  240. package/dist/typescript/components/class-declaration.mjs.map +1 -0
  241. package/dist/typescript/components/dynamic-import-statement.cjs +1 -0
  242. package/dist/typescript/components/dynamic-import-statement.d.cts +32 -0
  243. package/dist/typescript/components/dynamic-import-statement.d.cts.map +1 -0
  244. package/dist/typescript/components/dynamic-import-statement.d.mts +32 -0
  245. package/dist/typescript/components/dynamic-import-statement.d.mts.map +1 -0
  246. package/dist/typescript/components/dynamic-import-statement.mjs +2 -0
  247. package/dist/typescript/components/dynamic-import-statement.mjs.map +1 -0
  248. package/dist/typescript/components/entry-file.cjs +1 -0
  249. package/dist/typescript/components/entry-file.d.cts +27 -0
  250. package/dist/typescript/components/entry-file.d.cts.map +1 -0
  251. package/dist/typescript/components/entry-file.d.mts +27 -0
  252. package/dist/typescript/components/entry-file.d.mts.map +1 -0
  253. package/dist/typescript/components/entry-file.mjs +2 -0
  254. package/dist/typescript/components/entry-file.mjs.map +1 -0
  255. package/dist/typescript/components/index.cjs +1 -0
  256. package/dist/typescript/components/index.d.cts +14 -0
  257. package/dist/typescript/components/index.d.mts +14 -0
  258. package/dist/typescript/components/index.mjs +1 -0
  259. package/dist/typescript/components/interface-declaration.cjs +1 -0
  260. package/dist/typescript/components/interface-declaration.d.cts +80 -0
  261. package/dist/typescript/components/interface-declaration.d.cts.map +1 -0
  262. package/dist/typescript/components/interface-declaration.d.mts +80 -0
  263. package/dist/typescript/components/interface-declaration.d.mts.map +1 -0
  264. package/dist/typescript/components/interface-declaration.mjs +2 -0
  265. package/dist/typescript/components/interface-declaration.mjs.map +1 -0
  266. package/dist/typescript/components/object-declaration.cjs +1 -0
  267. package/dist/typescript/components/object-declaration.d.cts +28 -0
  268. package/dist/typescript/components/object-declaration.d.cts.map +1 -0
  269. package/dist/typescript/components/object-declaration.d.mts +28 -0
  270. package/dist/typescript/components/object-declaration.d.mts.map +1 -0
  271. package/dist/typescript/components/object-declaration.mjs +2 -0
  272. package/dist/typescript/components/object-declaration.mjs.map +1 -0
  273. package/dist/typescript/components/property-name.cjs +1 -0
  274. package/dist/typescript/components/property-name.d.cts +23 -0
  275. package/dist/typescript/components/property-name.d.cts.map +1 -0
  276. package/dist/typescript/components/property-name.d.mts +23 -0
  277. package/dist/typescript/components/property-name.d.mts.map +1 -0
  278. package/dist/typescript/components/property-name.mjs +2 -0
  279. package/dist/typescript/components/property-name.mjs.map +1 -0
  280. package/dist/typescript/components/record-expression.cjs +3 -0
  281. package/dist/typescript/components/record-expression.d.cts +12 -0
  282. package/dist/typescript/components/record-expression.d.cts.map +1 -0
  283. package/dist/typescript/components/record-expression.d.mts +12 -0
  284. package/dist/typescript/components/record-expression.d.mts.map +1 -0
  285. package/dist/typescript/components/record-expression.mjs +4 -0
  286. package/dist/typescript/components/record-expression.mjs.map +1 -0
  287. package/dist/typescript/components/tsdoc-reflection.cjs +1 -0
  288. package/dist/typescript/components/tsdoc-reflection.d.cts +42 -0
  289. package/dist/typescript/components/tsdoc-reflection.d.cts.map +1 -0
  290. package/dist/typescript/components/tsdoc-reflection.d.mts +42 -0
  291. package/dist/typescript/components/tsdoc-reflection.d.mts.map +1 -0
  292. package/dist/typescript/components/tsdoc-reflection.mjs +2 -0
  293. package/dist/typescript/components/tsdoc-reflection.mjs.map +1 -0
  294. package/dist/typescript/components/tsdoc.cjs +1 -0
  295. package/dist/typescript/components/tsdoc.d.cts +161 -0
  296. package/dist/typescript/components/tsdoc.d.cts.map +1 -0
  297. package/dist/typescript/components/tsdoc.d.mts +161 -0
  298. package/dist/typescript/components/tsdoc.d.mts.map +1 -0
  299. package/dist/typescript/components/tsdoc.mjs +2 -0
  300. package/dist/typescript/components/tsdoc.mjs.map +1 -0
  301. package/dist/typescript/components/type-declaration.cjs +1 -0
  302. package/dist/typescript/components/type-declaration.d.cts +17 -0
  303. package/dist/typescript/components/type-declaration.d.cts.map +1 -0
  304. package/dist/typescript/components/type-declaration.d.mts +17 -0
  305. package/dist/typescript/components/type-declaration.d.mts.map +1 -0
  306. package/dist/typescript/components/type-declaration.mjs +2 -0
  307. package/dist/typescript/components/type-declaration.mjs.map +1 -0
  308. package/dist/typescript/components/type-parameters.cjs +1 -0
  309. package/dist/typescript/components/type-parameters.d.cts +23 -0
  310. package/dist/typescript/components/type-parameters.d.cts.map +1 -0
  311. package/dist/typescript/components/type-parameters.d.mts +23 -0
  312. package/dist/typescript/components/type-parameters.d.mts.map +1 -0
  313. package/dist/typescript/components/type-parameters.mjs +2 -0
  314. package/dist/typescript/components/type-parameters.mjs.map +1 -0
  315. package/dist/typescript/components/typescript-file.cjs +1 -0
  316. package/dist/typescript/components/typescript-file.d.cts +47 -0
  317. package/dist/typescript/components/typescript-file.d.cts.map +1 -0
  318. package/dist/typescript/components/typescript-file.d.mts +47 -0
  319. package/dist/typescript/components/typescript-file.d.mts.map +1 -0
  320. package/dist/typescript/components/typescript-file.mjs +2 -0
  321. package/dist/typescript/components/typescript-file.mjs.map +1 -0
  322. package/dist/typescript/contexts/index.cjs +1 -0
  323. package/dist/typescript/contexts/index.d.cts +2 -0
  324. package/dist/typescript/contexts/index.d.mts +2 -0
  325. package/dist/typescript/contexts/index.mjs +1 -0
  326. package/dist/typescript/contexts/lexical-scope.cjs +1 -0
  327. package/dist/typescript/contexts/lexical-scope.d.cts +14 -0
  328. package/dist/typescript/contexts/lexical-scope.d.cts.map +1 -0
  329. package/dist/typescript/contexts/lexical-scope.d.mts +14 -0
  330. package/dist/typescript/contexts/lexical-scope.d.mts.map +1 -0
  331. package/dist/typescript/contexts/lexical-scope.mjs +2 -0
  332. package/dist/typescript/contexts/lexical-scope.mjs.map +1 -0
  333. package/dist/typescript/contexts/member-scope.cjs +1 -0
  334. package/dist/typescript/contexts/member-scope.d.cts +19 -0
  335. package/dist/typescript/contexts/member-scope.d.cts.map +1 -0
  336. package/dist/typescript/contexts/member-scope.d.mts +19 -0
  337. package/dist/typescript/contexts/member-scope.d.mts.map +1 -0
  338. package/dist/typescript/contexts/member-scope.mjs +2 -0
  339. package/dist/typescript/contexts/member-scope.mjs.map +1 -0
  340. package/dist/typescript/helpers/get-call-signature-props.cjs +1 -0
  341. package/dist/typescript/helpers/get-call-signature-props.d.cts +14 -0
  342. package/dist/typescript/helpers/get-call-signature-props.d.cts.map +1 -0
  343. package/dist/typescript/helpers/get-call-signature-props.d.mts +14 -0
  344. package/dist/typescript/helpers/get-call-signature-props.d.mts.map +1 -0
  345. package/dist/typescript/helpers/get-call-signature-props.mjs +2 -0
  346. package/dist/typescript/helpers/get-call-signature-props.mjs.map +1 -0
  347. package/dist/typescript/helpers/index.cjs +1 -0
  348. package/dist/typescript/helpers/index.d.cts +3 -0
  349. package/dist/typescript/helpers/index.d.mts +3 -0
  350. package/dist/typescript/helpers/index.mjs +1 -0
  351. package/dist/typescript/helpers/utilities.cjs +1 -0
  352. package/dist/typescript/helpers/utilities.d.cts +11 -0
  353. package/dist/typescript/helpers/utilities.d.cts.map +1 -0
  354. package/dist/typescript/helpers/utilities.d.mts +11 -0
  355. package/dist/typescript/helpers/utilities.d.mts.map +1 -0
  356. package/dist/typescript/helpers/utilities.mjs +2 -0
  357. package/dist/typescript/helpers/utilities.mjs.map +1 -0
  358. package/dist/typescript/index.cjs +1 -0
  359. package/dist/typescript/index.d.cts +17 -0
  360. package/dist/typescript/index.d.mts +17 -0
  361. package/dist/typescript/index.mjs +1 -0
  362. package/dist/yaml/components/index.cjs +1 -0
  363. package/dist/yaml/components/index.d.cts +2 -0
  364. package/dist/yaml/components/index.d.mts +2 -0
  365. package/dist/yaml/components/index.mjs +1 -0
  366. package/dist/yaml/components/yaml-file.cjs +1 -0
  367. package/dist/yaml/components/yaml-file.d.cts +32 -0
  368. package/dist/yaml/components/yaml-file.d.cts.map +1 -0
  369. package/dist/yaml/components/yaml-file.d.mts +32 -0
  370. package/dist/yaml/components/yaml-file.d.mts.map +1 -0
  371. package/dist/yaml/components/yaml-file.mjs +2 -0
  372. package/dist/yaml/components/yaml-file.mjs.map +1 -0
  373. package/dist/yaml/index.cjs +1 -0
  374. package/dist/yaml/index.d.cts +2 -0
  375. package/dist/yaml/index.d.mts +2 -0
  376. package/dist/yaml/index.mjs +1 -0
  377. package/package.json +16 -16
@@ -0,0 +1 @@
1
+ Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require(`./markdown-table.cjs`);exports.MarkdownTableColumnContext=e.MarkdownTableColumnContext,exports.MarkdownTableContext=e.MarkdownTableContext,exports.useMarkdownTable=e.useMarkdownTable,exports.useMarkdownTableColumn=e.useMarkdownTableColumn;
@@ -0,0 +1,2 @@
1
+ import { MarkdownTableColumnContext, MarkdownTableColumnContextInterface, MarkdownTableContext, MarkdownTableContextInterface, useMarkdownTable, useMarkdownTableColumn } from "./markdown-table.cjs";
2
+ export { MarkdownTableColumnContext, MarkdownTableColumnContextInterface, MarkdownTableContext, MarkdownTableContextInterface, useMarkdownTable, useMarkdownTableColumn };
@@ -0,0 +1,2 @@
1
+ import { MarkdownTableColumnContext, MarkdownTableColumnContextInterface, MarkdownTableContext, MarkdownTableContextInterface, useMarkdownTable, useMarkdownTableColumn } from "./markdown-table.mjs";
2
+ export { MarkdownTableColumnContext, MarkdownTableColumnContextInterface, MarkdownTableContext, MarkdownTableContextInterface, useMarkdownTable, useMarkdownTableColumn };
@@ -0,0 +1 @@
1
+ import{MarkdownTableColumnContext as e,MarkdownTableContext as t,useMarkdownTable as n,useMarkdownTableColumn as r}from"./markdown-table.mjs";export{e as MarkdownTableColumnContext,t as MarkdownTableContext,n as useMarkdownTable,r as useMarkdownTableColumn};
@@ -0,0 +1 @@
1
+ Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`}),require(`../../_virtual/_rolldown/runtime.cjs`);let e=require(`@alloy-js/core`);const t=(0,e.createNamedContext)(`MarkdownTableColumn`,{});function n(){return(0,e.useContext)(t)}const r=(0,e.createContext)({columns:[],data:[]});function i(){return(0,e.useContext)(r)}exports.MarkdownTableColumnContext=t,exports.MarkdownTableContext=r,exports.useMarkdownTable=i,exports.useMarkdownTableColumn=n;
@@ -0,0 +1,36 @@
1
+ import { ComponentContext } from "@alloy-js/core";
2
+
3
+ //#region src/markdown/contexts/markdown-table.d.ts
4
+ interface MarkdownTableColumnContextInterface<T extends Record<string, any> = Record<string, any>> {
5
+ index: number;
6
+ name: keyof T;
7
+ align: "left" | "right" | "center";
8
+ width: number;
9
+ }
10
+ /**
11
+ * The Powerlines context used in template rendering.
12
+ */
13
+ declare const MarkdownTableColumnContext: ComponentContext<MarkdownTableColumnContextInterface>;
14
+ /**
15
+ * Hook to access the Powerlines Context.
16
+ *
17
+ * @returns The Context.
18
+ */
19
+ declare function useMarkdownTableColumn(): MarkdownTableColumnContextInterface<Record<string, any>> | undefined;
20
+ interface MarkdownTableContextInterface<T extends Record<string, any> = Record<string, any>> {
21
+ columns: MarkdownTableColumnContextInterface<T>[];
22
+ data: T[];
23
+ }
24
+ /**
25
+ * The Powerlines context used in template rendering.
26
+ */
27
+ declare const MarkdownTableContext: ComponentContext<MarkdownTableContextInterface>;
28
+ /**
29
+ * Hook to access the Powerlines Context.
30
+ *
31
+ * @returns The Context.
32
+ */
33
+ declare function useMarkdownTable(): MarkdownTableContextInterface<Record<string, any>> | undefined;
34
+ //#endregion
35
+ export { MarkdownTableColumnContext, MarkdownTableColumnContextInterface, MarkdownTableContext, MarkdownTableContextInterface, useMarkdownTable, useMarkdownTableColumn };
36
+ //# sourceMappingURL=markdown-table.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"markdown-table.d.cts","names":[],"sources":["../../../src/markdown/contexts/markdown-table.ts"],"mappings":";;;UAqBiB,mCAAA,WACL,MAAA,gBAAsB,MAAA;EAEhC,KAAA;EACA,IAAA,QAAY,CAAA;EACZ,KAAA;EACA,KAAA;AAAA;;;;cAMW,0BAAA,EAA4B,gBAAA,CAAiB,mCAAA;;;;;;iBAW1C,sBAAA,CAAA,GAAsB,mCAAA,CAAA,MAAA;AAAA,UAMrB,6BAAA,WACL,MAAA,gBAAsB,MAAA;EAEhC,OAAA,EAAS,mCAAA,CAAoC,CAAA;EAC7C,IAAA,EAAM,CAAA;AAAA;AArBR;;;AAAA,cA2Ba,oBAAA,EAAsB,gBAAA,CAAiB,6BAAA;;AAhBpD;;;;iBA2BgB,gBAAA,CAAA,GAAgB,6BAAA,CAAA,MAAA"}
@@ -0,0 +1,36 @@
1
+ import { ComponentContext } from "@alloy-js/core";
2
+
3
+ //#region src/markdown/contexts/markdown-table.d.ts
4
+ interface MarkdownTableColumnContextInterface<T extends Record<string, any> = Record<string, any>> {
5
+ index: number;
6
+ name: keyof T;
7
+ align: "left" | "right" | "center";
8
+ width: number;
9
+ }
10
+ /**
11
+ * The Powerlines context used in template rendering.
12
+ */
13
+ declare const MarkdownTableColumnContext: ComponentContext<MarkdownTableColumnContextInterface>;
14
+ /**
15
+ * Hook to access the Powerlines Context.
16
+ *
17
+ * @returns The Context.
18
+ */
19
+ declare function useMarkdownTableColumn(): MarkdownTableColumnContextInterface<Record<string, any>> | undefined;
20
+ interface MarkdownTableContextInterface<T extends Record<string, any> = Record<string, any>> {
21
+ columns: MarkdownTableColumnContextInterface<T>[];
22
+ data: T[];
23
+ }
24
+ /**
25
+ * The Powerlines context used in template rendering.
26
+ */
27
+ declare const MarkdownTableContext: ComponentContext<MarkdownTableContextInterface>;
28
+ /**
29
+ * Hook to access the Powerlines Context.
30
+ *
31
+ * @returns The Context.
32
+ */
33
+ declare function useMarkdownTable(): MarkdownTableContextInterface<Record<string, any>> | undefined;
34
+ //#endregion
35
+ export { MarkdownTableColumnContext, MarkdownTableColumnContextInterface, MarkdownTableContext, MarkdownTableContextInterface, useMarkdownTable, useMarkdownTableColumn };
36
+ //# sourceMappingURL=markdown-table.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"markdown-table.d.mts","names":[],"sources":["../../../src/markdown/contexts/markdown-table.ts"],"mappings":";;;UAqBiB,mCAAA,WACL,MAAA,gBAAsB,MAAA;EAEhC,KAAA;EACA,IAAA,QAAY,CAAA;EACZ,KAAA;EACA,KAAA;AAAA;;;;cAMW,0BAAA,EAA4B,gBAAA,CAAiB,mCAAA;;;;;;iBAW1C,sBAAA,CAAA,GAAsB,mCAAA,CAAA,MAAA;AAAA,UAMrB,6BAAA,WACL,MAAA,gBAAsB,MAAA;EAEhC,OAAA,EAAS,mCAAA,CAAoC,CAAA;EAC7C,IAAA,EAAM,CAAA;AAAA;AArBR;;;AAAA,cA2Ba,oBAAA,EAAsB,gBAAA,CAAiB,6BAAA;;AAhBpD;;;;iBA2BgB,gBAAA,CAAA,GAAgB,6BAAA,CAAA,MAAA"}
@@ -0,0 +1,2 @@
1
+ import{createContext as e,createNamedContext as t,useContext as n}from"@alloy-js/core";const r=t(`MarkdownTableColumn`,{});function i(){return n(r)}const a=e({columns:[],data:[]});function o(){return n(a)}export{r as MarkdownTableColumnContext,a as MarkdownTableContext,o as useMarkdownTable,i as useMarkdownTableColumn};
2
+ //# sourceMappingURL=markdown-table.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"markdown-table.mjs","names":[],"sources":["../../../src/markdown/contexts/markdown-table.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 type { ComponentContext } from \"@alloy-js/core\";\nimport { createContext, createNamedContext, useContext } from \"@alloy-js/core\";\n\nexport interface MarkdownTableColumnContextInterface<\n T extends Record<string, any> = Record<string, any>\n> {\n index: number;\n name: keyof T;\n align: \"left\" | \"right\" | \"center\";\n width: number;\n}\n\n/**\n * The Powerlines context used in template rendering.\n */\nexport const MarkdownTableColumnContext: ComponentContext<MarkdownTableColumnContextInterface> =\n createNamedContext<MarkdownTableColumnContextInterface>(\n \"MarkdownTableColumn\",\n {} as MarkdownTableColumnContextInterface\n );\n\n/**\n * Hook to access the Powerlines Context.\n *\n * @returns The Context.\n */\nexport function useMarkdownTableColumn() {\n return useContext<MarkdownTableColumnContextInterface>(\n MarkdownTableColumnContext\n );\n}\n\nexport interface MarkdownTableContextInterface<\n T extends Record<string, any> = Record<string, any>\n> {\n columns: MarkdownTableColumnContextInterface<T>[];\n data: T[];\n}\n\n/**\n * The Powerlines context used in template rendering.\n */\nexport const MarkdownTableContext: ComponentContext<MarkdownTableContextInterface> =\n createContext<MarkdownTableContextInterface>({\n columns: [],\n data: []\n });\n\n/**\n * Hook to access the Powerlines Context.\n *\n * @returns The Context.\n */\nexport function useMarkdownTable() {\n return useContext<MarkdownTableContextInterface>(MarkdownTableContext);\n}\n"],"mappings":"uFAsBA,MAAY,EAA6B,EAAW,sBAAA,EAAA,CAAA,cAQlD,OAAA,EAAA,EAAA,CAKF,MAAK,EAAoB,EAAA,CACvB,QAAQ,EAAA,CACR,KAAC,EAAA,GAQH,SAAS,GAAW,CAClB,OAAE,EAAA,EAAA"}
@@ -0,0 +1 @@
1
+ Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require(`./components/front-matter.cjs`),t=require(`./components/heading.cjs`),n=require(`./components/markdown-file.cjs`),r=require(`./contexts/markdown-table.cjs`),i=require(`./components/markdown-table.cjs`);require(`./components/index.cjs`),require(`./contexts/index.cjs`),exports.FrontMatter=e.FrontMatter,exports.Heading=t.Heading,exports.MarkdownFile=n.MarkdownFile,exports.MarkdownFileHeader=n.MarkdownFileHeader,exports.MarkdownTable=i.MarkdownTable,exports.MarkdownTableColumn=i.MarkdownTableColumn,exports.MarkdownTableColumnContext=r.MarkdownTableColumnContext,exports.MarkdownTableColumnHeader=i.MarkdownTableColumnHeader,exports.MarkdownTableContext=r.MarkdownTableContext,exports.useMarkdownTable=r.useMarkdownTable,exports.useMarkdownTableColumn=r.useMarkdownTableColumn;
@@ -0,0 +1,6 @@
1
+ import { FrontMatter, FrontMatterProps } from "./components/front-matter.cjs";
2
+ import { Heading, HeadingProps } from "./components/heading.cjs";
3
+ import { MarkdownFile, MarkdownFileHeader, MarkdownFileHeaderProps, MarkdownFileProps } from "./components/markdown-file.cjs";
4
+ import { MarkdownTableColumnContext, MarkdownTableColumnContextInterface, MarkdownTableContext, MarkdownTableContextInterface, useMarkdownTable, useMarkdownTableColumn } from "./contexts/markdown-table.cjs";
5
+ import { MarkdownTable, MarkdownTableColumn, MarkdownTableColumnHeader, MarkdownTableColumnProps, MarkdownTableProps } from "./components/markdown-table.cjs";
6
+ export { FrontMatter, FrontMatterProps, Heading, HeadingProps, MarkdownFile, MarkdownFileHeader, MarkdownFileHeaderProps, MarkdownFileProps, MarkdownTable, MarkdownTableColumn, MarkdownTableColumnContext, MarkdownTableColumnContextInterface, MarkdownTableColumnHeader, MarkdownTableColumnProps, MarkdownTableContext, MarkdownTableContextInterface, MarkdownTableProps, useMarkdownTable, useMarkdownTableColumn };
@@ -0,0 +1,6 @@
1
+ import { FrontMatter, FrontMatterProps } from "./components/front-matter.mjs";
2
+ import { Heading, HeadingProps } from "./components/heading.mjs";
3
+ import { MarkdownFile, MarkdownFileHeader, MarkdownFileHeaderProps, MarkdownFileProps } from "./components/markdown-file.mjs";
4
+ import { MarkdownTableColumnContext, MarkdownTableColumnContextInterface, MarkdownTableContext, MarkdownTableContextInterface, useMarkdownTable, useMarkdownTableColumn } from "./contexts/markdown-table.mjs";
5
+ import { MarkdownTable, MarkdownTableColumn, MarkdownTableColumnHeader, MarkdownTableColumnProps, MarkdownTableProps } from "./components/markdown-table.mjs";
6
+ export { FrontMatter, FrontMatterProps, Heading, HeadingProps, MarkdownFile, MarkdownFileHeader, MarkdownFileHeaderProps, MarkdownFileProps, MarkdownTable, MarkdownTableColumn, MarkdownTableColumnContext, MarkdownTableColumnContextInterface, MarkdownTableColumnHeader, MarkdownTableColumnProps, MarkdownTableContext, MarkdownTableContextInterface, MarkdownTableProps, useMarkdownTable, useMarkdownTableColumn };
@@ -0,0 +1 @@
1
+ import{FrontMatter as e}from"./components/front-matter.mjs";import{Heading as t}from"./components/heading.mjs";import{MarkdownFile as n,MarkdownFileHeader as r}from"./components/markdown-file.mjs";import{MarkdownTableColumnContext as i,MarkdownTableContext as a,useMarkdownTable as o,useMarkdownTableColumn as s}from"./contexts/markdown-table.mjs";import{MarkdownTable as c,MarkdownTableColumn as l,MarkdownTableColumnHeader as u}from"./components/markdown-table.mjs";import"./components/index.mjs";import"./contexts/index.mjs";export{e as FrontMatter,t as Heading,n as MarkdownFile,r as MarkdownFileHeader,c as MarkdownTable,l as MarkdownTableColumn,i as MarkdownTableColumnContext,u as MarkdownTableColumnHeader,a as MarkdownTableContext,o as useMarkdownTable,s as useMarkdownTableColumn};
@@ -0,0 +1 @@
1
+ Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`}),require(`./_virtual/_rolldown/runtime.cjs`);const e=require(`./core/components/output.cjs`);require(`./core/index.cjs`);let t=require(`@stryke/path/file-path-fns`),n=require(`@alloy-js/core/jsx-runtime`),r=require(`@alloy-js/core`);async function i(i,a){let o={},s=await(0,r.renderAsync)((0,n.createComponent)(e.Output,{context:i,meta:o,children:a}));Object.keys(s).length?(i.debug(`Processing ${Object.keys(s).length} rendered output files from Alloy-js component templates.`),await(0,r.traverseOutput)(s,{visitDirectory:e=>{i.fs.existsSync(e.path)||i.fs.mkdirSync(e.path)},visitFile:e=>{if(`contents`in e){let n=o[e.path]??{};if(n.kind===`builtin`){if(!n.id)throw Error(`Built-in file "${e.path}" is missing its ID in the render metadata.`);i.emitBuiltinSync(e.contents,n.id,{skipFormat:n.skipFormat,storage:n.storage,extension:(0,t.findFileExtension)(e.path)})}else if(n.kind===`entry`)i.emitEntrySync(e.contents,e.path,{skipFormat:n.skipFormat,storage:n.storage,...n.typeDefinition??{}});else if(n.kind===`infrastructure`){if(!n.id)throw Error(`Infrastructure file "${e.path}" is missing its ID in the render metadata.`);i.emitInfrastructureSync(e.contents,n.id,{skipFormat:n.skipFormat,storage:n.storage,extension:(0,t.findFileExtension)(e.path)})}else i.emitSync(e.contents,e.path,n)}else i.fs.copySync(e.sourcePath,e.path)}})):i.debug(`No output files were rendered by Alloy-js component templates.`)}function a(t,i,a){return(0,r.printTree)((0,r.renderTree)((0,n.createComponent)(e.Output,{context:t,children:i})),a)}exports.render=i,exports.renderString=a;
@@ -0,0 +1,38 @@
1
+ import { Children, PrintTreeOptions } from "@alloy-js/core";
2
+ import { PluginContext } from "powerlines";
3
+
4
+ //#region src/render.d.ts
5
+ /**
6
+ * A function to render children components within the [Alloy](https://alloy-framework.github.io) context, and write any saved content to the file system.
7
+ *
8
+ * @example
9
+ * ```tsx
10
+ * import { render } from "@powerlines/plugin-alloy/render";
11
+ *
12
+ * await render(context, <> ... </>);
13
+ * ```
14
+ *
15
+ * @param context - The Powerlines plugin context.
16
+ * @param children - The children components to render.
17
+ * @returns A promise that resolves when rendering is complete.
18
+ */
19
+ declare function render<TContext extends PluginContext>(context: TContext, children: Children): Promise<void>;
20
+ /**
21
+ * A function to render children components within the [Alloy](https://alloy-framework.github.io) context and return the rendered output as a string.
22
+ *
23
+ * @example
24
+ * ```tsx
25
+ * import { renderString } from "@powerlines/plugin-alloy/render";
26
+ *
27
+ * const output = await renderString(context, <> ... </>);
28
+ * ```
29
+ *
30
+ * @param context - The Powerlines plugin context.
31
+ * @param children - The children components to render.
32
+ * @param options - Optional print tree options.
33
+ * @returns The rendered output as a string.
34
+ */
35
+ declare function renderString<TContext extends PluginContext>(context: TContext, children: Children, options?: PrintTreeOptions): string;
36
+ //#endregion
37
+ export { render, renderString };
38
+ //# sourceMappingURL=render.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"render.d.cts","names":[],"sources":["../src/render.tsx"],"mappings":";;;;;;AA4CA;;;;;;;;;;;;iBAAsB,MAAA,kBAAwB,aAAA,CAAA,CAC5C,OAAA,EAAS,QAAA,EACT,QAAA,EAAU,QAAA,GAAQ,OAAA;;;;;;AA2FpB;;;;;;;;;;iBAAgB,YAAA,kBAA8B,aAAA,CAAA,CAC5C,OAAA,EAAS,QAAA,EACT,QAAA,EAAU,QAAA,EACV,OAAA,GAAU,gBAAA"}
@@ -0,0 +1,38 @@
1
+ import { Children, PrintTreeOptions } from "@alloy-js/core";
2
+ import { PluginContext } from "powerlines";
3
+
4
+ //#region src/render.d.ts
5
+ /**
6
+ * A function to render children components within the [Alloy](https://alloy-framework.github.io) context, and write any saved content to the file system.
7
+ *
8
+ * @example
9
+ * ```tsx
10
+ * import { render } from "@powerlines/plugin-alloy/render";
11
+ *
12
+ * await render(context, <> ... </>);
13
+ * ```
14
+ *
15
+ * @param context - The Powerlines plugin context.
16
+ * @param children - The children components to render.
17
+ * @returns A promise that resolves when rendering is complete.
18
+ */
19
+ declare function render<TContext extends PluginContext>(context: TContext, children: Children): Promise<void>;
20
+ /**
21
+ * A function to render children components within the [Alloy](https://alloy-framework.github.io) context and return the rendered output as a string.
22
+ *
23
+ * @example
24
+ * ```tsx
25
+ * import { renderString } from "@powerlines/plugin-alloy/render";
26
+ *
27
+ * const output = await renderString(context, <> ... </>);
28
+ * ```
29
+ *
30
+ * @param context - The Powerlines plugin context.
31
+ * @param children - The children components to render.
32
+ * @param options - Optional print tree options.
33
+ * @returns The rendered output as a string.
34
+ */
35
+ declare function renderString<TContext extends PluginContext>(context: TContext, children: Children, options?: PrintTreeOptions): string;
36
+ //#endregion
37
+ export { render, renderString };
38
+ //# sourceMappingURL=render.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"render.d.mts","names":[],"sources":["../src/render.tsx"],"mappings":";;;;;;AA4CA;;;;;;;;;;;;iBAAsB,MAAA,kBAAwB,aAAA,CAAA,CAC5C,OAAA,EAAS,QAAA,EACT,QAAA,EAAU,QAAA,GAAQ,OAAA;;;;;;AA2FpB;;;;;;;;;;iBAAgB,YAAA,kBAA8B,aAAA,CAAA,CAC5C,OAAA,EAAS,QAAA,EACT,QAAA,EAAU,QAAA,EACV,OAAA,GAAU,gBAAA"}
@@ -0,0 +1,2 @@
1
+ import{Output as e}from"./core/components/output.mjs";import"./core/index.mjs";import{findFileExtension as t}from"@stryke/path/file-path-fns";import{createComponent as n}from"@alloy-js/core/jsx-runtime";import{printTree as r,renderAsync as i,renderTree as a,traverseOutput as o}from"@alloy-js/core";async function s(r,a){let s={},c=await i(n(e,{context:r,meta:s,children:a}));Object.keys(c).length?(r.debug(`Processing ${Object.keys(c).length} rendered output files from Alloy-js component templates.`),await o(c,{visitDirectory:e=>{r.fs.existsSync(e.path)||r.fs.mkdirSync(e.path)},visitFile:e=>{if(`contents`in e){let n=s[e.path]??{};if(n.kind===`builtin`){if(!n.id)throw Error(`Built-in file "${e.path}" is missing its ID in the render metadata.`);r.emitBuiltinSync(e.contents,n.id,{skipFormat:n.skipFormat,storage:n.storage,extension:t(e.path)})}else if(n.kind===`entry`)r.emitEntrySync(e.contents,e.path,{skipFormat:n.skipFormat,storage:n.storage,...n.typeDefinition??{}});else if(n.kind===`infrastructure`){if(!n.id)throw Error(`Infrastructure file "${e.path}" is missing its ID in the render metadata.`);r.emitInfrastructureSync(e.contents,n.id,{skipFormat:n.skipFormat,storage:n.storage,extension:t(e.path)})}else r.emitSync(e.contents,e.path,n)}else r.fs.copySync(e.sourcePath,e.path)}})):r.debug(`No output files were rendered by Alloy-js component templates.`)}function c(t,i,o){return r(a(n(e,{context:t,children:i})),o)}export{s as render,c as renderString};
2
+ //# sourceMappingURL=render.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"render.mjs","names":[],"sources":["../src/render.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 Children,\n printTree,\n PrintTreeOptions,\n renderAsync,\n renderTree,\n traverseOutput\n} from \"@alloy-js/core\";\nimport { findFileExtension } from \"@stryke/path/file-path-fns\";\nimport { PluginContext } from \"powerlines\";\nimport { MetaItem, Output } from \"./core\";\n\n/**\n * A function to render children components within the [Alloy](https://alloy-framework.github.io) context, and write any saved content to the file system.\n *\n * @example\n * ```tsx\n * import { render } from \"@powerlines/plugin-alloy/render\";\n *\n * await render(context, <> ... </>);\n * ```\n *\n * @param context - The Powerlines plugin context.\n * @param children - The children components to render.\n * @returns A promise that resolves when rendering is complete.\n */\nexport async function render<TContext extends PluginContext>(\n context: TContext,\n children: Children\n) {\n const meta = {} as Record<string, MetaItem>;\n const output = await renderAsync(\n <Output<TContext> context={context} meta={meta}>\n {children}\n </Output>\n );\n\n if (!Object.keys(output).length) {\n context.debug(\n \"No output files were rendered by Alloy-js component templates.\"\n );\n } else {\n context.debug(\n `Processing ${\n Object.keys(output).length\n } rendered output files from Alloy-js component templates.`\n );\n\n await traverseOutput(output, {\n visitDirectory: directory => {\n if (context.fs.existsSync(directory.path)) {\n return;\n }\n\n context.fs.mkdirSync(directory.path);\n },\n visitFile: file => {\n if (\"contents\" in file) {\n const metadata = meta[file.path] ?? {};\n if (metadata.kind === \"builtin\") {\n if (!metadata.id) {\n throw new Error(\n `Built-in file \"${\n file.path\n }\" is missing its ID in the render metadata.`\n );\n }\n\n context.emitBuiltinSync(file.contents, metadata.id, {\n skipFormat: metadata.skipFormat,\n storage: metadata.storage,\n extension: findFileExtension(file.path)\n });\n } else if (metadata.kind === \"entry\") {\n context.emitEntrySync(file.contents, file.path, {\n skipFormat: metadata.skipFormat,\n storage: metadata.storage,\n ...(metadata.typeDefinition ?? {})\n });\n } else if (metadata.kind === \"infrastructure\") {\n if (!metadata.id) {\n throw new Error(\n `Infrastructure file \"${\n file.path\n }\" is missing its ID in the render metadata.`\n );\n }\n\n context.emitInfrastructureSync(file.contents, metadata.id, {\n skipFormat: metadata.skipFormat,\n storage: metadata.storage,\n extension: findFileExtension(file.path)\n });\n } else {\n context.emitSync(file.contents, file.path, metadata);\n }\n } else {\n context.fs.copySync(file.sourcePath, file.path);\n }\n }\n });\n }\n}\n\n/**\n * A function to render children components within the [Alloy](https://alloy-framework.github.io) context and return the rendered output as a string.\n *\n * @example\n * ```tsx\n * import { renderString } from \"@powerlines/plugin-alloy/render\";\n *\n * const output = await renderString(context, <> ... </>);\n * ```\n *\n * @param context - The Powerlines plugin context.\n * @param children - The children components to render.\n * @param options - Optional print tree options.\n * @returns The rendered output as a string.\n */\nexport function renderString<TContext extends PluginContext>(\n context: TContext,\n children: Children,\n options?: PrintTreeOptions\n) {\n const tree = renderTree(\n <Output<TContext> context={context}>{children}</Output>\n );\n\n return printTree(tree, options);\n}\n"],"mappings":"2SAsCA,eAAK,EAAA,EAAA,EAAA,CACJ,IAAA,EAAA,EAAA,CACG,EAAa,MAAM,EAAY,EAAc,EAAA,CACvC,UACN,OACF,WACF,CAAA,CAAA,CACE,OAAS,KAAQ,EAAA,CAAA,QAGjB,EAAU,MAAM,cAAU,OAAQ,KAAQ,EAAC,CAAA,OAAA,2DAAA,CAC3C,MAAM,EAAe,EAAA,CAClB,eAAiB,GAAS,CACxB,EAAQ,GAAA,WAAA,EAAA,KAAA,0BAKX,UAAa,GAAA,CACV,GAAG,aAAa,EAAK,CACvB,IAAA,EAAA,EAAA,EAAA,OAAA,EAAA,CACI,GAAA,EAAA,OAAA,UAAA,CACG,GAAA,CAAK,EAAA,GACV,MAAY,MAAA,kBAAA,EAAA,KAAA,6CAAA,CAEX,EAAS,gBAAkB,EAAM,SAAG,EAAU,GAAU,CAC3D,WAAA,EAAA,6BAEK,UAAe,EAAQ,EAAA,KAAA,CAC3B,CAAA,SACc,EAAG,OAAW,QACxB,EAAM,cAAA,EAAA,SAAA,EAAA,KAAA,CACR,WAAA,EAAA,6BAEA,GAAU,EAAC,gBAAyB,EAAA,CACrC,CAAA,SACc,EAAI,OAAA,iBAAA,CACb,GAAC,CAAA,EAAa,GAChB,MAAc,MAAG,wBAAqB,EAAA,KAAA,6CAAA,CAEpC,EAAK,uBAAa,EAAA,SAAA,EAAA,GAAA,CAChB,WAAU,EAAK,WACf,QAAS,EAAS,QAClB,UAAS,EAAA,EAAA,KAAA,CACV,CAAC,MAEF,EAAA,SAAA,EAAA,SAAA,EAAA,KAAA,EAAA,MAGF,EAAI,GAAA,SAAY,EAAS,WAAU,EAAA,KAAA,EAGxC,CAAC,EA5CJ,EAAU,MAAA,iEAAA,CA+DZ,SAAc,EAAW,EAAA,EAAuB,EAAI,CAKlD,OAAO,EAJK,EAAA,EAAA,EAAA,CACF,UACA,WACT,CAAC,CACW,CAAA,EAAA"}
File without changes
@@ -0,0 +1,126 @@
1
+ import { Children, Context } from "@alloy-js/core";
2
+ import { ResolvedEntryTypeDefinition, StoragePreset } from "powerlines";
3
+ import { SourceFileContext } from "@alloy-js/typescript";
4
+
5
+ //#region src/types/components.d.ts
6
+ interface CopyOutputFile {
7
+ kind: "file";
8
+ path: string;
9
+ sourcePath: string;
10
+ /**
11
+ * The format of the output files
12
+ *
13
+ * @remarks
14
+ * If not specified, the output mode will be determined by the provided \`output.mode\` value.
15
+ */
16
+ preset?: StoragePreset;
17
+ }
18
+ interface WriteOutputFile {
19
+ kind: "file" | "entry" | "builtin";
20
+ path: string;
21
+ contents: string;
22
+ filetype: string;
23
+ /**
24
+ * The format of the output files
25
+ *
26
+ * @remarks
27
+ * If not specified, the output mode will be determined by the provided \`output.mode\` value.
28
+ */
29
+ preset?: StoragePreset;
30
+ }
31
+ type OutputFile = (WriteOutputFile & {
32
+ kind: "file";
33
+ }) | (WriteOutputFile & {
34
+ kind: "entry";
35
+ typeDefinition?: ResolvedEntryTypeDefinition;
36
+ }) | (WriteOutputFile & {
37
+ kind: "builtin";
38
+ id: string;
39
+ }) | CopyOutputFile;
40
+ interface OutputDirectory {
41
+ kind: "directory";
42
+ path: string;
43
+ contents: (OutputDirectory | OutputFile)[];
44
+ }
45
+ interface RenderEntryContext {
46
+ typeDefinition: ResolvedEntryTypeDefinition;
47
+ }
48
+ interface RenderBuiltinContext {
49
+ id: string;
50
+ }
51
+ interface RenderOutputContext {
52
+ mode?: StoragePreset;
53
+ }
54
+ interface CopyFileOutputContext {
55
+ path?: string;
56
+ sourcePath?: string;
57
+ }
58
+ interface RenderContext extends Context {
59
+ meta?: {
60
+ copyFile?: CopyFileOutputContext;
61
+ /**
62
+ * The current context for the built-in module.
63
+ */
64
+ builtin?: RenderBuiltinContext;
65
+ /**
66
+ * The current context for the application entrypoint file being rendered.
67
+ */
68
+ entry?: RenderEntryContext;
69
+ /**
70
+ * The current context for output rendering.
71
+ */
72
+ output?: RenderOutputContext;
73
+ } & Record<string, any>;
74
+ }
75
+ /**
76
+ * A type that represents the props of a component that can have children.
77
+ */
78
+ interface ComponentProps {
79
+ children?: Children;
80
+ }
81
+ /**
82
+ * A type that requires the `children` prop in a component.
83
+ */
84
+ type ComponentPropsWithChildren = Omit<ComponentProps, "children"> & Required<Pick<ComponentProps, "children">>;
85
+ interface BuiltinSourceFileContext extends SourceFileContext {
86
+ /**
87
+ * The runtime module identifier.
88
+ */
89
+ id: string;
90
+ }
91
+ interface ReflectionOverrideInterface<T> {
92
+ name?: string | Children;
93
+ type?: string | Children;
94
+ extends?: string | false;
95
+ defaultValue?: Partial<T>;
96
+ }
97
+ interface TypescriptFileImportItem {
98
+ name: string;
99
+ default?: boolean;
100
+ alias?: string;
101
+ type?: boolean;
102
+ }
103
+ type TypescriptFileImports = Record<string, null | string | Array<TypescriptFileImportItem | string>>;
104
+ interface SourceFileHeaderProps extends ComponentProps {
105
+ /**
106
+ * If true, disables the ESLint directive at the top of the file.
107
+ *
108
+ * @defaultValue true
109
+ */
110
+ disableEslint?: boolean;
111
+ /**
112
+ * If true, disables the Biome directive at the top of the file.
113
+ *
114
+ * @defaultValue true
115
+ */
116
+ disableBiome?: boolean;
117
+ /**
118
+ * If true, disables the Prettier directive at the top of the file.
119
+ *
120
+ * @defaultValue false
121
+ */
122
+ disablePrettier?: boolean;
123
+ }
124
+ //#endregion
125
+ export { BuiltinSourceFileContext, ComponentProps, ComponentPropsWithChildren, CopyFileOutputContext, CopyOutputFile, OutputDirectory, OutputFile, ReflectionOverrideInterface, RenderBuiltinContext, RenderContext, RenderEntryContext, RenderOutputContext, SourceFileHeaderProps, TypescriptFileImportItem, TypescriptFileImports, WriteOutputFile };
126
+ //# sourceMappingURL=components.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"components.d.cts","names":[],"sources":["../../src/types/components.ts"],"mappings":";;;;;UAsBiB,cAAA;EACf,IAAA;EACA,IAAA;EACA,UAAA;;;;;;;EAQA,MAAA,GAAS,aAAA;AAAA;AAAA,UAGM,eAAA;EACf,IAAA;EACA,IAAA;EACA,QAAA;EACA,QAAA;EAHA;;;;;;EAWA,MAAA,GAAS,aAAA;AAAA;AAAA,KAGC,UAAA,IACP,eAAA;EAAoB,IAAA;AAAA,MACpB,eAAA;EACC,IAAA;EACA,cAAA,GAAiB,2BAAA;AAAA,MAElB,eAAA;EAAoB,IAAA;EAAiB,EAAA;AAAA,KACtC,cAAA;AAAA,UAEa,eAAA;EACf,IAAA;EACA,IAAA;EACA,QAAA,GAAW,eAAA,GAAkB,UAAA;AAAA;AAAA,UAGd,kBAAA;EACf,cAAA,EAAgB,2BAAA;AAAA;AAAA,UAGD,oBAAA;EACf,EAAA;AAAA;AAAA,UAGe,mBAAA;EACf,IAAA,GAAO,aAAA;AAAA;AAAA,UAGQ,qBAAA;EACf,IAAA;EACA,UAAA;AAAA;AAAA,UAGe,aAAA,SAAsB,OAAA;EACrC,IAAA;IACE,QAAA,GAAW,qBAAA;IAtBgB;;;IA2B3B,OAAA,GAAU,oBAAA;IAxBqB;;;IA6B/B,KAAA,GAAQ,kBAAA;IAzBK;;;IA8Bb,MAAA,GAAS,mBAAA;EAAA,IACP,MAAA;AAAA;;;;UAMW,cAAA;EACf,QAAA,GAAW,QAAA;AAAA;;;;KAMD,0BAAA,GAA6B,IAAA,CAAK,cAAA,gBAC5C,QAAA,CAAS,IAAA,CAAK,cAAA;AAAA,UAEC,wBAAA,SAAiC,iBAAA;;;;EAIhD,EAAA;AAAA;AAAA,UAGe,2BAAA;EACf,IAAA,YAAgB,QAAA;EAChB,IAAA,YAAgB,QAAA;EAChB,OAAA;EACA,YAAA,GAAe,OAAA,CAAQ,CAAA;AAAA;AAAA,UAGR,wBAAA;EACf,IAAA;EACA,OAAA;EACA,KAAA;EACA,IAAA;AAAA;AAAA,KAGU,qBAAA,GAAwB,MAAA,yBAElB,KAAA,CAAM,wBAAA;AAAA,UAGP,qBAAA,SAA8B,cAAA;EA1CzC;;;AAMN;;EA0CE,aAAA;EAzCA;;AAMF;;;EA0CE,YAAA;EA1CuC;;;;;EAiDvC,eAAA;AAAA"}
@@ -0,0 +1,126 @@
1
+ import { Children, Context } from "@alloy-js/core";
2
+ import { SourceFileContext as SourceFileContext$1 } from "@alloy-js/typescript";
3
+ import { ResolvedEntryTypeDefinition, StoragePreset } from "powerlines";
4
+
5
+ //#region src/types/components.d.ts
6
+ interface CopyOutputFile {
7
+ kind: "file";
8
+ path: string;
9
+ sourcePath: string;
10
+ /**
11
+ * The format of the output files
12
+ *
13
+ * @remarks
14
+ * If not specified, the output mode will be determined by the provided \`output.mode\` value.
15
+ */
16
+ preset?: StoragePreset;
17
+ }
18
+ interface WriteOutputFile {
19
+ kind: "file" | "entry" | "builtin";
20
+ path: string;
21
+ contents: string;
22
+ filetype: string;
23
+ /**
24
+ * The format of the output files
25
+ *
26
+ * @remarks
27
+ * If not specified, the output mode will be determined by the provided \`output.mode\` value.
28
+ */
29
+ preset?: StoragePreset;
30
+ }
31
+ type OutputFile = (WriteOutputFile & {
32
+ kind: "file";
33
+ }) | (WriteOutputFile & {
34
+ kind: "entry";
35
+ typeDefinition?: ResolvedEntryTypeDefinition;
36
+ }) | (WriteOutputFile & {
37
+ kind: "builtin";
38
+ id: string;
39
+ }) | CopyOutputFile;
40
+ interface OutputDirectory {
41
+ kind: "directory";
42
+ path: string;
43
+ contents: (OutputDirectory | OutputFile)[];
44
+ }
45
+ interface RenderEntryContext {
46
+ typeDefinition: ResolvedEntryTypeDefinition;
47
+ }
48
+ interface RenderBuiltinContext {
49
+ id: string;
50
+ }
51
+ interface RenderOutputContext {
52
+ mode?: StoragePreset;
53
+ }
54
+ interface CopyFileOutputContext {
55
+ path?: string;
56
+ sourcePath?: string;
57
+ }
58
+ interface RenderContext extends Context {
59
+ meta?: {
60
+ copyFile?: CopyFileOutputContext;
61
+ /**
62
+ * The current context for the built-in module.
63
+ */
64
+ builtin?: RenderBuiltinContext;
65
+ /**
66
+ * The current context for the application entrypoint file being rendered.
67
+ */
68
+ entry?: RenderEntryContext;
69
+ /**
70
+ * The current context for output rendering.
71
+ */
72
+ output?: RenderOutputContext;
73
+ } & Record<string, any>;
74
+ }
75
+ /**
76
+ * A type that represents the props of a component that can have children.
77
+ */
78
+ interface ComponentProps {
79
+ children?: Children;
80
+ }
81
+ /**
82
+ * A type that requires the `children` prop in a component.
83
+ */
84
+ type ComponentPropsWithChildren = Omit<ComponentProps, "children"> & Required<Pick<ComponentProps, "children">>;
85
+ interface BuiltinSourceFileContext extends SourceFileContext$1 {
86
+ /**
87
+ * The runtime module identifier.
88
+ */
89
+ id: string;
90
+ }
91
+ interface ReflectionOverrideInterface<T> {
92
+ name?: string | Children;
93
+ type?: string | Children;
94
+ extends?: string | false;
95
+ defaultValue?: Partial<T>;
96
+ }
97
+ interface TypescriptFileImportItem {
98
+ name: string;
99
+ default?: boolean;
100
+ alias?: string;
101
+ type?: boolean;
102
+ }
103
+ type TypescriptFileImports = Record<string, null | string | Array<TypescriptFileImportItem | string>>;
104
+ interface SourceFileHeaderProps extends ComponentProps {
105
+ /**
106
+ * If true, disables the ESLint directive at the top of the file.
107
+ *
108
+ * @defaultValue true
109
+ */
110
+ disableEslint?: boolean;
111
+ /**
112
+ * If true, disables the Biome directive at the top of the file.
113
+ *
114
+ * @defaultValue true
115
+ */
116
+ disableBiome?: boolean;
117
+ /**
118
+ * If true, disables the Prettier directive at the top of the file.
119
+ *
120
+ * @defaultValue false
121
+ */
122
+ disablePrettier?: boolean;
123
+ }
124
+ //#endregion
125
+ export { BuiltinSourceFileContext, ComponentProps, ComponentPropsWithChildren, CopyFileOutputContext, CopyOutputFile, OutputDirectory, OutputFile, ReflectionOverrideInterface, RenderBuiltinContext, RenderContext, RenderEntryContext, RenderOutputContext, SourceFileHeaderProps, TypescriptFileImportItem, TypescriptFileImports, WriteOutputFile };
126
+ //# sourceMappingURL=components.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"components.d.mts","names":[],"sources":["../../src/types/components.ts"],"mappings":";;;;;UAsBiB,cAAA;EACf,IAAA;EACA,IAAA;EACA,UAAA;;;;;;;EAQA,MAAA,GAAS,aAAA;AAAA;AAAA,UAGM,eAAA;EACf,IAAA;EACA,IAAA;EACA,QAAA;EACA,QAAA;EAHA;;;;;;EAWA,MAAA,GAAS,aAAA;AAAA;AAAA,KAGC,UAAA,IACP,eAAA;EAAoB,IAAA;AAAA,MACpB,eAAA;EACC,IAAA;EACA,cAAA,GAAiB,2BAAA;AAAA,MAElB,eAAA;EAAoB,IAAA;EAAiB,EAAA;AAAA,KACtC,cAAA;AAAA,UAEa,eAAA;EACf,IAAA;EACA,IAAA;EACA,QAAA,GAAW,eAAA,GAAkB,UAAA;AAAA;AAAA,UAGd,kBAAA;EACf,cAAA,EAAgB,2BAAA;AAAA;AAAA,UAGD,oBAAA;EACf,EAAA;AAAA;AAAA,UAGe,mBAAA;EACf,IAAA,GAAO,aAAA;AAAA;AAAA,UAGQ,qBAAA;EACf,IAAA;EACA,UAAA;AAAA;AAAA,UAGe,aAAA,SAAsB,OAAA;EACrC,IAAA;IACE,QAAA,GAAW,qBAAA;IAtBgB;;;IA2B3B,OAAA,GAAU,oBAAA;IAxBqB;;;IA6B/B,KAAA,GAAQ,kBAAA;IAzBK;;;IA8Bb,MAAA,GAAS,mBAAA;EAAA,IACP,MAAA;AAAA;;;;UAMW,cAAA;EACf,QAAA,GAAW,QAAA;AAAA;;;;KAMD,0BAAA,GAA6B,IAAA,CAAK,cAAA,gBAC5C,QAAA,CAAS,IAAA,CAAK,cAAA;AAAA,UAEC,wBAAA,SAAiC,mBAAA;;;;EAIhD,EAAA;AAAA;AAAA,UAGe,2BAAA;EACf,IAAA,YAAgB,QAAA;EAChB,IAAA,YAAgB,QAAA;EAChB,OAAA;EACA,YAAA,GAAe,OAAA,CAAQ,CAAA;AAAA;AAAA,UAGR,wBAAA;EACf,IAAA;EACA,OAAA;EACA,KAAA;EACA,IAAA;AAAA;AAAA,KAGU,qBAAA,GAAwB,MAAA,yBAElB,KAAA,CAAM,wBAAA;AAAA,UAGP,qBAAA,SAA8B,cAAA;EA1CzC;;;AAMN;;EA0CE,aAAA;EAzCA;;AAMF;;;EA0CE,YAAA;EA1CuC;;;;;EAiDvC,eAAA;AAAA"}
@@ -0,0 +1,2 @@
1
+ export{};
2
+ //# sourceMappingURL=components.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"components.mjs","names":[],"sources":["../../src/types/components.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 type { Children, Context } from \"@alloy-js/core\";\nimport type { SourceFileContext } from \"@alloy-js/typescript\";\nimport { ResolvedEntryTypeDefinition, StoragePreset } from \"powerlines\";\n\nexport interface CopyOutputFile {\n kind: \"file\";\n path: string;\n sourcePath: string;\n\n /**\n * The format of the output files\n *\n * @remarks\n * If not specified, the output mode will be determined by the provided \\`output.mode\\` value.\n */\n preset?: StoragePreset;\n}\n\nexport interface WriteOutputFile {\n kind: \"file\" | \"entry\" | \"builtin\";\n path: string;\n contents: string;\n filetype: string;\n\n /**\n * The format of the output files\n *\n * @remarks\n * If not specified, the output mode will be determined by the provided \\`output.mode\\` value.\n */\n preset?: StoragePreset;\n}\n\nexport type OutputFile =\n | (WriteOutputFile & { kind: \"file\" })\n | (WriteOutputFile & {\n kind: \"entry\";\n typeDefinition?: ResolvedEntryTypeDefinition;\n })\n | (WriteOutputFile & { kind: \"builtin\"; id: string })\n | CopyOutputFile;\n\nexport interface OutputDirectory {\n kind: \"directory\";\n path: string;\n contents: (OutputDirectory | OutputFile)[];\n}\n\nexport interface RenderEntryContext {\n typeDefinition: ResolvedEntryTypeDefinition;\n}\n\nexport interface RenderBuiltinContext {\n id: string;\n}\n\nexport interface RenderOutputContext {\n mode?: StoragePreset;\n}\n\nexport interface CopyFileOutputContext {\n path?: string;\n sourcePath?: string;\n}\n\nexport interface RenderContext extends Context {\n meta?: {\n copyFile?: CopyFileOutputContext;\n\n /**\n * The current context for the built-in module.\n */\n builtin?: RenderBuiltinContext;\n\n /**\n * The current context for the application entrypoint file being rendered.\n */\n entry?: RenderEntryContext;\n\n /**\n * The current context for output rendering.\n */\n output?: RenderOutputContext;\n } & Record<string, any>;\n}\n\n/**\n * A type that represents the props of a component that can have children.\n */\nexport interface ComponentProps {\n children?: Children;\n}\n\n/**\n * A type that requires the `children` prop in a component.\n */\nexport type ComponentPropsWithChildren = Omit<ComponentProps, \"children\"> &\n Required<Pick<ComponentProps, \"children\">>;\n\nexport interface BuiltinSourceFileContext extends SourceFileContext {\n /**\n * The runtime module identifier.\n */\n id: string;\n}\n\nexport interface ReflectionOverrideInterface<T> {\n name?: string | Children;\n type?: string | Children;\n extends?: string | false;\n defaultValue?: Partial<T>;\n}\n\nexport interface TypescriptFileImportItem {\n name: string;\n default?: boolean;\n alias?: string;\n type?: boolean;\n}\n\nexport type TypescriptFileImports = Record<\n string,\n null | string | Array<TypescriptFileImportItem | string>\n>;\n\nexport interface SourceFileHeaderProps extends ComponentProps {\n /**\n * If true, disables the ESLint directive at the top of the file.\n *\n * @defaultValue true\n */\n disableEslint?: boolean;\n\n /**\n * If true, disables the Biome directive at the top of the file.\n *\n * @defaultValue true\n */\n disableBiome?: boolean;\n\n /**\n * If true, disables the Prettier directive at the top of the file.\n *\n * @defaultValue false\n */\n disablePrettier?: boolean;\n}\n"],"mappings":""}
File without changes
@@ -0,0 +1,3 @@
1
+ import { BuiltinSourceFileContext, ComponentProps, ComponentPropsWithChildren, CopyFileOutputContext, CopyOutputFile, OutputDirectory, OutputFile, ReflectionOverrideInterface, RenderBuiltinContext, RenderContext, RenderEntryContext, RenderOutputContext, SourceFileHeaderProps, TypescriptFileImportItem, TypescriptFileImports, WriteOutputFile } from "./components.cjs";
2
+ import { AlloyPluginContext, AlloyPluginOptions, AlloyPluginResolvedConfig, AlloyPluginUserConfig } from "./plugin.cjs";
3
+ export { AlloyPluginContext, AlloyPluginOptions, AlloyPluginResolvedConfig, AlloyPluginUserConfig, BuiltinSourceFileContext, ComponentProps, ComponentPropsWithChildren, CopyFileOutputContext, CopyOutputFile, OutputDirectory, OutputFile, ReflectionOverrideInterface, RenderBuiltinContext, RenderContext, RenderEntryContext, RenderOutputContext, SourceFileHeaderProps, TypescriptFileImportItem, TypescriptFileImports, WriteOutputFile };
@@ -0,0 +1,3 @@
1
+ import { BuiltinSourceFileContext, ComponentProps, ComponentPropsWithChildren, CopyFileOutputContext, CopyOutputFile, OutputDirectory, OutputFile, ReflectionOverrideInterface, RenderBuiltinContext, RenderContext, RenderEntryContext, RenderOutputContext, SourceFileHeaderProps, TypescriptFileImportItem, TypescriptFileImports, WriteOutputFile } from "./components.mjs";
2
+ import { AlloyPluginContext, AlloyPluginOptions, AlloyPluginResolvedConfig, AlloyPluginUserConfig } from "./plugin.mjs";
3
+ export { AlloyPluginContext, AlloyPluginOptions, AlloyPluginResolvedConfig, AlloyPluginUserConfig, BuiltinSourceFileContext, ComponentProps, ComponentPropsWithChildren, CopyFileOutputContext, CopyOutputFile, OutputDirectory, OutputFile, ReflectionOverrideInterface, RenderBuiltinContext, RenderContext, RenderEntryContext, RenderOutputContext, SourceFileHeaderProps, TypescriptFileImportItem, TypescriptFileImports, WriteOutputFile };
@@ -0,0 +1 @@
1
+ export{};
File without changes
@@ -0,0 +1,35 @@
1
+ import { PrintTreeOptions } from "@alloy-js/core";
2
+ import { PluginContext } from "powerlines";
3
+ import { BabelPluginResolvedConfig, BabelPluginUserConfig } from "@powerlines/plugin-babel/types/plugin";
4
+
5
+ //#region src/types/plugin.d.ts
6
+ type AlloyPluginOptions = Partial<PrintTreeOptions> & {
7
+ /**
8
+ * If true, the Alloy framework is used to generate Typescript output files.
9
+ *
10
+ * @defaultValue true
11
+ */
12
+ typescript?: boolean;
13
+ /**
14
+ * If true, the Alloy framework is used to generate JSON output files.
15
+ *
16
+ * @defaultValue false
17
+ */
18
+ json?: boolean;
19
+ /**
20
+ * If true, the Alloy framework is used to generate Markdown output files.
21
+ *
22
+ * @defaultValue false
23
+ */
24
+ markdown?: boolean;
25
+ };
26
+ type AlloyPluginUserConfig = BabelPluginUserConfig & {
27
+ alloy?: AlloyPluginOptions;
28
+ };
29
+ type AlloyPluginResolvedConfig = BabelPluginResolvedConfig & {
30
+ alloy: AlloyPluginOptions;
31
+ };
32
+ type AlloyPluginContext<TResolvedConfig extends AlloyPluginResolvedConfig = AlloyPluginResolvedConfig> = PluginContext<TResolvedConfig>;
33
+ //#endregion
34
+ export { AlloyPluginContext, AlloyPluginOptions, AlloyPluginResolvedConfig, AlloyPluginUserConfig };
35
+ //# sourceMappingURL=plugin.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"plugin.d.cts","names":[],"sources":["../../src/types/plugin.ts"],"mappings":";;;;;KAyBY,kBAAA,GAAqB,OAAA,CAAQ,gBAAA;;AAAzC;;;;EAME,UAAA;EANuC;;;;;EAavC,IAAA;EAUU;;;;;EAHV,QAAA;AAAA;AAAA,KAGU,qBAAA,GAAwB,qBAAA;EAClC,KAAA,GAAQ,kBAAA;AAAA;AAAA,KAGE,yBAAA,GAA4B,yBAAA;EACtC,KAAA,EAAO,kBAAA;AAAA;AAAA,KAGG,kBAAA,yBACc,yBAAA,GAA4B,yBAAA,IAClD,aAAA,CAAc,eAAA"}
@@ -0,0 +1,35 @@
1
+ import { PrintTreeOptions } from "@alloy-js/core";
2
+ import { PluginContext } from "powerlines";
3
+ import { BabelPluginResolvedConfig, BabelPluginUserConfig } from "@powerlines/plugin-babel/types/plugin";
4
+
5
+ //#region src/types/plugin.d.ts
6
+ type AlloyPluginOptions = Partial<PrintTreeOptions> & {
7
+ /**
8
+ * If true, the Alloy framework is used to generate Typescript output files.
9
+ *
10
+ * @defaultValue true
11
+ */
12
+ typescript?: boolean;
13
+ /**
14
+ * If true, the Alloy framework is used to generate JSON output files.
15
+ *
16
+ * @defaultValue false
17
+ */
18
+ json?: boolean;
19
+ /**
20
+ * If true, the Alloy framework is used to generate Markdown output files.
21
+ *
22
+ * @defaultValue false
23
+ */
24
+ markdown?: boolean;
25
+ };
26
+ type AlloyPluginUserConfig = BabelPluginUserConfig & {
27
+ alloy?: AlloyPluginOptions;
28
+ };
29
+ type AlloyPluginResolvedConfig = BabelPluginResolvedConfig & {
30
+ alloy: AlloyPluginOptions;
31
+ };
32
+ type AlloyPluginContext<TResolvedConfig extends AlloyPluginResolvedConfig = AlloyPluginResolvedConfig> = PluginContext<TResolvedConfig>;
33
+ //#endregion
34
+ export { AlloyPluginContext, AlloyPluginOptions, AlloyPluginResolvedConfig, AlloyPluginUserConfig };
35
+ //# sourceMappingURL=plugin.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"plugin.d.mts","names":[],"sources":["../../src/types/plugin.ts"],"mappings":";;;;;KAyBY,kBAAA,GAAqB,OAAA,CAAQ,gBAAA;;AAAzC;;;;EAME,UAAA;EANuC;;;;;EAavC,IAAA;EAUU;;;;;EAHV,QAAA;AAAA;AAAA,KAGU,qBAAA,GAAwB,qBAAA;EAClC,KAAA,GAAQ,kBAAA;AAAA;AAAA,KAGE,yBAAA,GAA4B,yBAAA;EACtC,KAAA,EAAO,kBAAA;AAAA;AAAA,KAGG,kBAAA,yBACc,yBAAA,GAA4B,yBAAA,IAClD,aAAA,CAAc,eAAA"}