@powerlines/plugin-alloy 0.26.19 → 0.26.20

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 (95) hide show
  1. package/dist/core/components/infrastructure-file.cjs +9 -14
  2. package/dist/core/components/infrastructure-file.mjs +9 -14
  3. package/dist/core/components/infrastructure-file.mjs.map +1 -1
  4. package/dist/core/components/output.cjs +10 -17
  5. package/dist/core/components/output.mjs +10 -17
  6. package/dist/core/components/output.mjs.map +1 -1
  7. package/dist/core/components/single-line-comment.cjs +4 -6
  8. package/dist/core/components/single-line-comment.mjs +4 -6
  9. package/dist/core/components/single-line-comment.mjs.map +1 -1
  10. package/dist/core/components/source-file.cjs +6 -10
  11. package/dist/core/components/source-file.mjs +6 -10
  12. package/dist/core/components/source-file.mjs.map +1 -1
  13. package/dist/core/components/spacing.cjs +4 -6
  14. package/dist/core/components/spacing.mjs +4 -6
  15. package/dist/core/components/spacing.mjs.map +1 -1
  16. package/dist/hcl/components/block-declaration.cjs +8 -12
  17. package/dist/hcl/components/block-declaration.mjs +8 -12
  18. package/dist/hcl/components/block-declaration.mjs.map +1 -1
  19. package/dist/hcl/components/hcl-file.cjs +21 -35
  20. package/dist/hcl/components/hcl-file.mjs +22 -36
  21. package/dist/hcl/components/hcl-file.mjs.map +1 -1
  22. package/dist/hcl/components/packer-file.cjs +8 -8
  23. package/dist/hcl/components/packer-file.mjs +8 -8
  24. package/dist/hcl/components/packer-file.mjs.map +1 -1
  25. package/dist/hcl/components/terraform-file.cjs +8 -8
  26. package/dist/hcl/components/terraform-file.mjs +8 -8
  27. package/dist/hcl/components/terraform-file.mjs.map +1 -1
  28. package/dist/helpers/capnp.cjs +1 -1
  29. package/dist/helpers/capnp.mjs +1 -1
  30. package/dist/helpers/capnp.mjs.map +1 -1
  31. package/dist/index.cjs +7 -12
  32. package/dist/index.d.cts.map +1 -1
  33. package/dist/index.d.mts.map +1 -1
  34. package/dist/index.mjs +7 -11
  35. package/dist/index.mjs.map +1 -1
  36. package/dist/markdown/components/front-matter.cjs +7 -9
  37. package/dist/markdown/components/front-matter.mjs +7 -9
  38. package/dist/markdown/components/front-matter.mjs.map +1 -1
  39. package/dist/markdown/components/markdown-file.cjs +44 -76
  40. package/dist/markdown/components/markdown-file.mjs +44 -76
  41. package/dist/markdown/components/markdown-file.mjs.map +1 -1
  42. package/dist/markdown/components/markdown-table.cjs +28 -49
  43. package/dist/markdown/components/markdown-table.mjs +28 -49
  44. package/dist/markdown/components/markdown-table.mjs.map +1 -1
  45. package/dist/markdown/contexts/markdown-table.mjs.map +1 -1
  46. package/dist/render.cjs +3 -3
  47. package/dist/render.mjs +4 -4
  48. package/dist/render.mjs.map +1 -1
  49. package/dist/typescript/components/builtin-file.cjs +20 -30
  50. package/dist/typescript/components/builtin-file.mjs +20 -30
  51. package/dist/typescript/components/builtin-file.mjs.map +1 -1
  52. package/dist/typescript/components/class-declaration.cjs +100 -165
  53. package/dist/typescript/components/class-declaration.mjs +100 -165
  54. package/dist/typescript/components/class-declaration.mjs.map +1 -1
  55. package/dist/typescript/components/dynamic-import-statement.cjs +6 -2
  56. package/dist/typescript/components/dynamic-import-statement.mjs +6 -2
  57. package/dist/typescript/components/dynamic-import-statement.mjs.map +1 -1
  58. package/dist/typescript/components/entry-file.cjs +8 -11
  59. package/dist/typescript/components/entry-file.mjs +8 -11
  60. package/dist/typescript/components/entry-file.mjs.map +1 -1
  61. package/dist/typescript/components/interface-declaration.cjs +74 -127
  62. package/dist/typescript/components/interface-declaration.mjs +74 -127
  63. package/dist/typescript/components/interface-declaration.mjs.map +1 -1
  64. package/dist/typescript/components/object-declaration.cjs +50 -84
  65. package/dist/typescript/components/object-declaration.mjs +50 -84
  66. package/dist/typescript/components/object-declaration.mjs.map +1 -1
  67. package/dist/typescript/components/property-name.cjs +3 -3
  68. package/dist/typescript/components/property-name.mjs +3 -3
  69. package/dist/typescript/components/property-name.mjs.map +1 -1
  70. package/dist/typescript/components/record-expression.mjs.map +1 -1
  71. package/dist/typescript/components/tsdoc-reflection.cjs +108 -241
  72. package/dist/typescript/components/tsdoc-reflection.mjs +108 -241
  73. package/dist/typescript/components/tsdoc-reflection.mjs.map +1 -1
  74. package/dist/typescript/components/tsdoc.cjs +168 -265
  75. package/dist/typescript/components/tsdoc.mjs +168 -265
  76. package/dist/typescript/components/tsdoc.mjs.map +1 -1
  77. package/dist/typescript/components/type-declaration.cjs +15 -20
  78. package/dist/typescript/components/type-declaration.mjs +15 -20
  79. package/dist/typescript/components/type-declaration.mjs.map +1 -1
  80. package/dist/typescript/components/type-parameters.cjs +29 -55
  81. package/dist/typescript/components/type-parameters.mjs +29 -55
  82. package/dist/typescript/components/type-parameters.mjs.map +1 -1
  83. package/dist/typescript/components/typescript-file.cjs +74 -135
  84. package/dist/typescript/components/typescript-file.mjs +74 -135
  85. package/dist/typescript/components/typescript-file.mjs.map +1 -1
  86. package/dist/typescript/contexts/lexical-scope.cjs +3 -5
  87. package/dist/typescript/contexts/lexical-scope.mjs +3 -5
  88. package/dist/typescript/contexts/lexical-scope.mjs.map +1 -1
  89. package/dist/typescript/contexts/member-scope.cjs +3 -5
  90. package/dist/typescript/contexts/member-scope.mjs +3 -5
  91. package/dist/typescript/contexts/member-scope.mjs.map +1 -1
  92. package/dist/yaml/components/yaml-file.cjs +47 -92
  93. package/dist/yaml/components/yaml-file.mjs +47 -92
  94. package/dist/yaml/components/yaml-file.mjs.map +1 -1
  95. package/package.json +6 -6
@@ -3,8 +3,8 @@ const require_runtime = require('../../_virtual/_rolldown/runtime.cjs');
3
3
  const require_core_contexts_reflection = require('../../core/contexts/reflection.cjs');
4
4
  const require_core_components_spacing = require('../../core/components/spacing.cjs');
5
5
  const require_typescript_components_tsdoc = require('./tsdoc.cjs');
6
- let _alloy_js_core_jsx_runtime = require("@alloy-js/core/jsx-runtime");
7
6
  let _alloy_js_core = require("@alloy-js/core");
7
+ let _alloy_js_core_jsx_runtime = require("@alloy-js/core/jsx-runtime");
8
8
  let _stryke_string_format_title_case = require("@stryke/string-format/title-case");
9
9
  let _stryke_type_checks_is_undefined = require("@stryke/type-checks/is-undefined");
10
10
  let _powerlines_deepkit_vendor_type = require("@powerlines/deepkit/vendor/type");
@@ -35,80 +35,42 @@ function TSDocReflectionClass(props) {
35
35
  const hidden = (0, _alloy_js_core.computed)(() => reflection.isHidden());
36
36
  if (!computedHeading.value || (0, _stryke_type_checks_is_set_string.isSetString)(computedHeading.value) && computedHeading.value.trim() === "") return null;
37
37
  const hasAttributes = (0, _alloy_js_core.computed)(() => (0, _stryke_type_checks_is_set_string.isSetString)(title.value) || !(0, _stryke_type_checks_is_undefined.isUndefined)(alias.value) && alias.value.length > 0 || !(0, _stryke_type_checks_is_undefined.isUndefined)(permission.value) && permission.value.length > 0 || (0, _stryke_type_checks_is_set_string.isSetString)(domain.value) || !(0, _stryke_type_checks_is_undefined.isUndefined)(readonly.value) || !(0, _stryke_type_checks_is_undefined.isUndefined)(internal.value) || !(0, _stryke_type_checks_is_undefined.isUndefined)(runtime.value) || !(0, _stryke_type_checks_is_undefined.isUndefined)(ignore.value) || !(0, _stryke_type_checks_is_undefined.isUndefined)(hidden.value));
38
- return (0, _alloy_js_core_jsx_runtime.createComponent)(require_typescript_components_tsdoc.TSDoc, (0, _alloy_js_core_jsx_runtime.mergeProps)(rest, {
39
- get heading() {
40
- return (0, _alloy_js_core_jsx_runtime.memo)(() => !!(0, _stryke_type_checks_is_set_string.isSetString)(computedHeading.value))() ? computedHeading.value.trim() : computedHeading.value;
41
- },
42
- get children() {
43
- return [(0, _alloy_js_core_jsx_runtime.createComponent)(_alloy_js_core.Show, {
44
- get when() {
45
- return hasAttributes.value;
46
- },
47
- get children() {
48
- return (0, _alloy_js_core_jsx_runtime.createComponent)(require_typescript_components_tsdoc.TSDocAttributesTags, {
49
- get title() {
50
- return title.value;
51
- },
52
- get alias() {
53
- return alias.value;
54
- },
55
- get domain() {
56
- return domain.value;
57
- },
58
- get permission() {
59
- return permission.value;
60
- },
61
- get readonly() {
62
- return readonly.value;
63
- },
64
- get internal() {
65
- return internal.value;
66
- },
67
- get runtime() {
68
- return runtime.value;
69
- },
70
- get ignore() {
71
- return ignore.value;
72
- },
73
- get hidden() {
74
- return hidden.value;
75
- }
76
- });
77
- }
78
- }), (0, _alloy_js_core_jsx_runtime.createComponent)(_alloy_js_core.Show, {
79
- get when() {
80
- return (0, _alloy_js_core_jsx_runtime.memo)(() => !!!(0, _stryke_type_checks_is_undefined.isUndefined)(children))() && (0, _alloy_js_core.childrenArray)(() => children).filter(Boolean).length > 0;
81
- },
82
- get children() {
83
- return [(0, _alloy_js_core_jsx_runtime.createComponent)(_alloy_js_core.Show, {
84
- get when() {
85
- return hasAttributes.value;
86
- },
87
- get children() {
88
- return (0, _alloy_js_core_jsx_runtime.createComponent)(require_core_components_spacing.Spacing, {});
89
- }
90
- }), (0, _alloy_js_core_jsx_runtime.createComponent)(_alloy_js_core.List, { get children() {
91
- return (0, _alloy_js_core.childrenArray)(() => children);
92
- } })];
93
- }
94
- })];
95
- }
96
- }));
38
+ return /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsxs)(require_typescript_components_tsdoc.TSDoc, {
39
+ ...rest,
40
+ heading: (0, _stryke_type_checks_is_set_string.isSetString)(computedHeading.value) ? computedHeading.value.trim() : computedHeading.value,
41
+ children: [/* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)(_alloy_js_core.Show, {
42
+ when: hasAttributes.value,
43
+ children: /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)(require_typescript_components_tsdoc.TSDocAttributesTags, {
44
+ title: title.value,
45
+ alias: alias.value,
46
+ domain: domain.value,
47
+ permission: permission.value,
48
+ readonly: readonly.value,
49
+ internal: internal.value,
50
+ runtime: runtime.value,
51
+ ignore: ignore.value,
52
+ hidden: hidden.value
53
+ })
54
+ }), /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsxs)(_alloy_js_core.Show, {
55
+ when: !(0, _stryke_type_checks_is_undefined.isUndefined)(children) && (0, _alloy_js_core.childrenArray)(() => children).filter(Boolean).length > 0,
56
+ children: [/* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)(_alloy_js_core.Show, {
57
+ when: hasAttributes.value,
58
+ children: /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)(require_core_components_spacing.Spacing, {})
59
+ }), /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)(_alloy_js_core.List, { children: (0, _alloy_js_core.childrenArray)(() => children) })]
60
+ })]
61
+ });
97
62
  }
98
63
  /**
99
64
  * Uses the `useReflectionClass` hook to retrieve the reflection class from the context, and then renders a `TSDocReflectionClass` component with the retrieved reflection class. This is a convenience component that allows you to easily render a TSDoc documentation block for the current reflection class without having to manually retrieve the reflection class from the context.
100
65
  */
101
66
  function TSDocContextClass(props) {
102
67
  const reflectionClass = require_core_contexts_reflection.useReflectionClass();
103
- return (0, _alloy_js_core_jsx_runtime.createComponent)(_alloy_js_core.Show, {
104
- get when() {
105
- return (0, _stryke_type_checks.isSetObject)(reflectionClass.reflection);
106
- },
107
- get children() {
108
- return (0, _alloy_js_core_jsx_runtime.createComponent)(TSDocReflectionClass, (0, _alloy_js_core_jsx_runtime.mergeProps)(props, { get reflection() {
109
- return reflectionClass.reflection;
110
- } }));
111
- }
68
+ return /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)(_alloy_js_core.Show, {
69
+ when: (0, _stryke_type_checks.isSetObject)(reflectionClass.reflection),
70
+ children: /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)(TSDocReflectionClass, {
71
+ ...props,
72
+ reflection: reflectionClass.reflection
73
+ })
112
74
  });
113
75
  }
114
76
  /**
@@ -122,86 +84,45 @@ function TSDocReflectionProperty(props) {
122
84
  ]);
123
85
  if (!(0, _stryke_type_checks.isSetObject)(reflection)) return null;
124
86
  const hasAttributes = (0, _alloy_js_core.computed)(() => (0, _stryke_type_checks_is_set_string.isSetString)(reflection.getTitle()) || !(0, _stryke_type_checks_is_undefined.isUndefined)(reflection.getAlias()) && reflection.getAlias().length > 0 || !(0, _stryke_type_checks_is_undefined.isUndefined)(reflection.getPermission()) && reflection.getPermission().length > 0 || (0, _stryke_type_checks_is_set_string.isSetString)(reflection.getDomain()) || !(0, _stryke_type_checks_is_undefined.isUndefined)(reflection.isReadonly()) || !(0, _stryke_type_checks_is_undefined.isUndefined)(reflection.isInternal()) || !(0, _stryke_type_checks_is_undefined.isUndefined)(reflection.isRuntime()) || !(0, _stryke_type_checks_is_undefined.isUndefined)(reflection.isIgnored()) || !(0, _stryke_type_checks_is_undefined.isUndefined)(reflection.isHidden()) || reflection.hasDefault() && !(0, _stryke_type_checks_is_undefined.isUndefined)(reflection.getDefaultValue()));
125
- return (0, _alloy_js_core_jsx_runtime.createComponent)(require_typescript_components_tsdoc.TSDoc, (0, _alloy_js_core_jsx_runtime.mergeProps)({ get heading() {
126
- return reflection.getDescription();
127
- } }, rest, { get children() {
128
- return [(0, _alloy_js_core_jsx_runtime.createComponent)(_alloy_js_core.Show, {
129
- get when() {
130
- return hasAttributes.value;
131
- },
132
- get children() {
133
- return (0, _alloy_js_core_jsx_runtime.createComponent)(require_typescript_components_tsdoc.TSDocAttributesTags, {
134
- type: reflection,
135
- get title() {
136
- return reflection.getTitle();
137
- },
138
- get alias() {
139
- return reflection.getAlias();
140
- },
141
- get domain() {
142
- return reflection.getDomain();
143
- },
144
- get permission() {
145
- return reflection.getPermission();
146
- },
147
- get readonly() {
148
- return reflection.isReadonly();
149
- },
150
- get internal() {
151
- return reflection.isInternal();
152
- },
153
- get runtime() {
154
- return reflection.isRuntime();
155
- },
156
- get ignore() {
157
- return reflection.isIgnored();
158
- },
159
- get hidden() {
160
- return reflection.isHidden();
161
- },
162
- get defaultValue() {
163
- return defaultValue ?? reflection.getDefaultValue();
164
- }
165
- });
166
- }
167
- }), (0, _alloy_js_core_jsx_runtime.createComponent)(_alloy_js_core.Show, {
168
- get when() {
169
- return (0, _alloy_js_core_jsx_runtime.memo)(() => !!!(0, _stryke_type_checks_is_undefined.isUndefined)(children))() && (0, _alloy_js_core.childrenArray)(() => children).filter(Boolean).length > 0;
170
- },
171
- get children() {
172
- return [(0, _alloy_js_core_jsx_runtime.createComponent)(_alloy_js_core.Show, {
173
- get when() {
174
- return hasAttributes.value;
175
- },
176
- get children() {
177
- return (0, _alloy_js_core_jsx_runtime.createComponent)(require_core_components_spacing.Spacing, {});
178
- }
179
- }), (0, _alloy_js_core_jsx_runtime.createComponent)(_alloy_js_core.List, { get children() {
180
- return (0, _alloy_js_core.childrenArray)(() => children);
181
- } })];
182
- }
183
- })];
184
- } }));
87
+ return /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsxs)(require_typescript_components_tsdoc.TSDoc, {
88
+ heading: reflection.getDescription(),
89
+ ...rest,
90
+ children: [/* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)(_alloy_js_core.Show, {
91
+ when: hasAttributes.value,
92
+ children: /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)(require_typescript_components_tsdoc.TSDocAttributesTags, {
93
+ type: reflection,
94
+ title: reflection.getTitle(),
95
+ alias: reflection.getAlias(),
96
+ domain: reflection.getDomain(),
97
+ permission: reflection.getPermission(),
98
+ readonly: reflection.isReadonly(),
99
+ internal: reflection.isInternal(),
100
+ runtime: reflection.isRuntime(),
101
+ ignore: reflection.isIgnored(),
102
+ hidden: reflection.isHidden(),
103
+ defaultValue: defaultValue ?? reflection.getDefaultValue()
104
+ })
105
+ }), /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsxs)(_alloy_js_core.Show, {
106
+ when: !(0, _stryke_type_checks_is_undefined.isUndefined)(children) && (0, _alloy_js_core.childrenArray)(() => children).filter(Boolean).length > 0,
107
+ children: [/* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)(_alloy_js_core.Show, {
108
+ when: hasAttributes.value,
109
+ children: /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)(require_core_components_spacing.Spacing, {})
110
+ }), /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)(_alloy_js_core.List, { children: (0, _alloy_js_core.childrenArray)(() => children) })]
111
+ })]
112
+ });
185
113
  }
186
114
  /**
187
115
  * Uses the `useReflectionProperty` hook to retrieve the reflection property from the context, and then renders a `TSDocReflectionProperty` component with the retrieved reflection property. This is a convenience component that allows you to easily render a TSDoc documentation block for the current reflection property without having to manually retrieve the reflection property from the context.
188
116
  */
189
117
  function TSDocContextProperty(props) {
190
118
  const reflection = require_core_contexts_reflection.useReflectionPropertyContext();
191
- return (0, _alloy_js_core_jsx_runtime.createComponent)(_alloy_js_core.Show, {
192
- get when() {
193
- return (0, _stryke_type_checks.isSetObject)(reflection);
194
- },
195
- get children() {
196
- return (0, _alloy_js_core_jsx_runtime.createComponent)(TSDocReflectionProperty, (0, _alloy_js_core_jsx_runtime.mergeProps)(props, {
197
- get reflection() {
198
- return reflection.property;
199
- },
200
- get defaultValue() {
201
- return reflection.defaultValue;
202
- }
203
- }));
204
- }
119
+ return /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)(_alloy_js_core.Show, {
120
+ when: (0, _stryke_type_checks.isSetObject)(reflection),
121
+ children: /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)(TSDocReflectionProperty, {
122
+ ...props,
123
+ reflection: reflection.property,
124
+ defaultValue: reflection.defaultValue
125
+ })
205
126
  });
206
127
  }
207
128
  /**
@@ -210,115 +131,61 @@ function TSDocContextProperty(props) {
210
131
  function TSDocReflectionMethod(props) {
211
132
  const [{ children, reflection }, rest] = (0, _alloy_js_core.splitProps)(props, ["children", "reflection"]);
212
133
  if (!(0, _stryke_type_checks.isSetObject)(reflection)) return null;
213
- const heading = (0, _alloy_js_core.computed)(() => reflection.getDescription() || ((0, _stryke_type_checks_is_string.isString)(reflection.getName()) ? _alloy_js_core.code`${String(reflection.getName())} method definition` : void 0));
214
- return (0, _alloy_js_core_jsx_runtime.createComponent)(require_typescript_components_tsdoc.TSDoc, (0, _alloy_js_core_jsx_runtime.mergeProps)({ get heading() {
215
- return heading.value;
216
- } }, rest, { get children() {
217
- return [
218
- (0, _alloy_js_core_jsx_runtime.createComponent)(require_typescript_components_tsdoc.TSDocAttributesTags, {
219
- get title() {
220
- return reflection.getTitle();
221
- },
222
- get alias() {
223
- return reflection.getAlias();
224
- },
225
- get domain() {
226
- return reflection.getDomain();
227
- },
228
- get permission() {
229
- return reflection.getPermission();
230
- },
231
- get readonly() {
232
- return reflection.isReadonly();
233
- },
234
- get internal() {
235
- return reflection.isInternal();
236
- },
237
- get runtime() {
238
- return reflection.isRuntime();
239
- },
240
- get ignore() {
241
- return reflection.isIgnored();
242
- },
243
- get hidden() {
244
- return reflection.isHidden();
245
- }
134
+ return /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsxs)(require_typescript_components_tsdoc.TSDoc, {
135
+ heading: (0, _alloy_js_core.computed)(() => reflection.getDescription() || ((0, _stryke_type_checks_is_string.isString)(reflection.getName()) ? _alloy_js_core.code`${String(reflection.getName())} method definition` : void 0)).value,
136
+ ...rest,
137
+ children: [
138
+ /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)(require_typescript_components_tsdoc.TSDocAttributesTags, {
139
+ title: reflection.getTitle(),
140
+ alias: reflection.getAlias(),
141
+ domain: reflection.getDomain(),
142
+ permission: reflection.getPermission(),
143
+ readonly: reflection.isReadonly(),
144
+ internal: reflection.isInternal(),
145
+ runtime: reflection.isRuntime(),
146
+ ignore: reflection.isIgnored(),
147
+ hidden: reflection.isHidden()
246
148
  }),
247
- (0, _alloy_js_core_jsx_runtime.createComponent)(_alloy_js_core.Show, {
248
- get when() {
249
- return (0, _alloy_js_core_jsx_runtime.memo)(() => !!Boolean(children))() && (0, _alloy_js_core.childrenArray)(() => children).length > 0;
250
- },
251
- get children() {
252
- return (0, _alloy_js_core_jsx_runtime.createComponent)(_alloy_js_core.List, { get children() {
253
- return (0, _alloy_js_core.childrenArray)(() => children);
254
- } });
255
- }
149
+ /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)(_alloy_js_core.Show, {
150
+ when: Boolean(children) && (0, _alloy_js_core.childrenArray)(() => children).length > 0,
151
+ children: /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)(_alloy_js_core.List, { children: (0, _alloy_js_core.childrenArray)(() => children) })
256
152
  }),
257
- (0, _alloy_js_core_jsx_runtime.createComponent)(_alloy_js_core.Show, {
258
- get when() {
259
- return reflection.getParameters().length > 0;
260
- },
261
- get children() {
262
- return [(0, _alloy_js_core_jsx_runtime.createComponent)(require_core_components_spacing.Spacing, {}), (0, _alloy_js_core_jsx_runtime.createComponent)(_alloy_js_core.For, {
263
- get each() {
264
- return reflection.getParameters();
265
- },
266
- hardline: true,
267
- get ender() {
268
- return (0, _alloy_js_core_jsx_runtime.createIntrinsic)("hbr", {});
269
- },
270
- children: (param) => (0, _alloy_js_core_jsx_runtime.createComponent)(require_typescript_components_tsdoc.TSDocParam, {
271
- get name() {
272
- return param.getName();
273
- },
274
- get optional() {
275
- return param.isOptional();
276
- },
277
- get defaultValue() {
278
- return (0, _alloy_js_core_jsx_runtime.memo)(() => !!param.hasDefault())() ? param.getDefaultValue() : void 0;
279
- },
280
- get children() {
281
- return (0, _alloy_js_core_jsx_runtime.createComponent)(_alloy_js_core.Show, {
282
- get when() {
283
- return Boolean(param.parameter.description);
284
- },
285
- get fallback() {
286
- return _alloy_js_core.code`A parameter to provide a ${param.getName()} value to the function.`;
287
- },
288
- get children() {
289
- return param.parameter.description;
290
- }
291
- });
292
- }
153
+ /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsxs)(_alloy_js_core.Show, {
154
+ when: reflection.getParameters().length > 0,
155
+ children: [/* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)(require_core_components_spacing.Spacing, {}), /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)(_alloy_js_core.For, {
156
+ each: reflection.getParameters(),
157
+ hardline: true,
158
+ ender: /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)("hbr", {}),
159
+ children: (param) => /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)(require_typescript_components_tsdoc.TSDocParam, {
160
+ name: param.getName(),
161
+ optional: param.isOptional(),
162
+ defaultValue: param.hasDefault() ? param.getDefaultValue() : void 0,
163
+ children: /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)(_alloy_js_core.Show, {
164
+ when: Boolean(param.parameter.description),
165
+ fallback: _alloy_js_core.code`A parameter to provide a ${param.getName()} value to the function.`,
166
+ children: param.parameter.description
293
167
  })
294
- })];
295
- }
168
+ })
169
+ })]
296
170
  }),
297
- (0, _alloy_js_core_jsx_runtime.createComponent)(_alloy_js_core.Show, {
298
- get when() {
299
- return reflection.getReturnType().kind !== _powerlines_deepkit_vendor_type.ReflectionKind.void;
300
- },
301
- get children() {
302
- return [(0, _alloy_js_core_jsx_runtime.createComponent)(require_core_components_spacing.Spacing, {}), (0, _alloy_js_core_jsx_runtime.createComponent)(require_typescript_components_tsdoc.TSDocReturns, { get children() {
303
- return _alloy_js_core.code`The return value of the function, which is of type ${(0, _powerlines_deepkit_vendor_type.stringifyType)(reflection.getReturnType())}.`;
304
- } })];
305
- }
171
+ /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsxs)(_alloy_js_core.Show, {
172
+ when: reflection.getReturnType().kind !== _powerlines_deepkit_vendor_type.ReflectionKind.void,
173
+ children: [/* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)(require_core_components_spacing.Spacing, {}), /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)(require_typescript_components_tsdoc.TSDocReturns, { children: _alloy_js_core.code`The return value of the function, which is of type ${(0, _powerlines_deepkit_vendor_type.stringifyType)(reflection.getReturnType())}.` })]
306
174
  })
307
- ];
308
- } }));
175
+ ]
176
+ });
309
177
  }
310
178
  /**
311
179
  * Uses the `useReflectionMethod` hook to retrieve the reflection method from the context, and then renders a `TSDocReflectionMethod` component with the retrieved reflection method. This is a convenience component that allows you to easily render a TSDoc documentation block for the current reflection method without having to manually retrieve the reflection method from the context.
312
180
  */
313
181
  function TSDocContextMethod(props) {
314
182
  const reflection = require_core_contexts_reflection.useReflectionMethod();
315
- return (0, _alloy_js_core_jsx_runtime.createComponent)(_alloy_js_core.Show, {
316
- get when() {
317
- return (0, _stryke_type_checks.isSetObject)(reflection);
318
- },
319
- get children() {
320
- return (0, _alloy_js_core_jsx_runtime.createComponent)(TSDocReflectionMethod, (0, _alloy_js_core_jsx_runtime.mergeProps)(props, { reflection }));
321
- }
183
+ return /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)(_alloy_js_core.Show, {
184
+ when: (0, _stryke_type_checks.isSetObject)(reflection),
185
+ children: /* @__PURE__ */ (0, _alloy_js_core_jsx_runtime.jsx)(TSDocReflectionMethod, {
186
+ ...props,
187
+ reflection
188
+ })
322
189
  });
323
190
  }
324
191