@typesafe-html5/typescript 0.2.58

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 (117) hide show
  1. package/README.md +166 -0
  2. package/block/article/article.ts +506 -0
  3. package/block/aside/aside.ts +522 -0
  4. package/block/audio/audio.ts +506 -0
  5. package/block/blockquote/blockquote.ts +522 -0
  6. package/block/body/body.ts +458 -0
  7. package/block/canvas/canvas.ts +538 -0
  8. package/block/caption/caption.ts +506 -0
  9. package/block/colgroup/colgroup.ts +154 -0
  10. package/block/datalist/datalist.ts +506 -0
  11. package/block/dd/dd.ts +506 -0
  12. package/block/del/del.ts +538 -0
  13. package/block/details/details.ts +586 -0
  14. package/block/dialog/dialog.ts +586 -0
  15. package/block/div/div.ts +586 -0
  16. package/block/dl/dl.ts +506 -0
  17. package/block/dt/dt.ts +506 -0
  18. package/block/embed/embed.ts +317 -0
  19. package/block/fieldset/fieldset.ts +570 -0
  20. package/block/figcaption/figcaption.ts +506 -0
  21. package/block/figure/figure.ts +506 -0
  22. package/block/footer/footer.ts +522 -0
  23. package/block/form/form.ts +490 -0
  24. package/block/h1/h1.ts +490 -0
  25. package/block/h2/h2.ts +490 -0
  26. package/block/h3/h3.ts +490 -0
  27. package/block/h4/h4.ts +490 -0
  28. package/block/h5/h5.ts +490 -0
  29. package/block/h6/h6.ts +490 -0
  30. package/block/header/header.ts +298 -0
  31. package/block/hgroup/hgroup.ts +506 -0
  32. package/block/hr/hr.ts +189 -0
  33. package/block/html/html.ts +106 -0
  34. package/block/iframe/iframe.ts +538 -0
  35. package/block/ins/ins.ts +538 -0
  36. package/block/legend/legend.ts +506 -0
  37. package/block/li/li.ts +602 -0
  38. package/block/main/main.ts +538 -0
  39. package/block/map/map.ts +522 -0
  40. package/block/menu/menu.ts +554 -0
  41. package/block/nav/nav.ts +554 -0
  42. package/block/noscript/noscript.ts +282 -0
  43. package/block/object/object.ts +618 -0
  44. package/block/ol/ol.ts +618 -0
  45. package/block/optgroup/optgroup.ts +522 -0
  46. package/block/option/option.ts +618 -0
  47. package/block/p/p.ts +506 -0
  48. package/block/picture/picture.ts +506 -0
  49. package/block/pre/pre.ts +506 -0
  50. package/block/section/section.ts +538 -0
  51. package/block/summary/summary.ts +570 -0
  52. package/block/table/table.ts +570 -0
  53. package/block/tbody/tbody.ts +506 -0
  54. package/block/td/td.ts +666 -0
  55. package/block/template/template.ts +506 -0
  56. package/block/tfoot/tfoot.ts +506 -0
  57. package/block/th/th.ts +682 -0
  58. package/block/thead/thead.ts +506 -0
  59. package/block/tr/tr.ts +682 -0
  60. package/block/ul/ul.ts +570 -0
  61. package/block/video/video.ts +666 -0
  62. package/index.ts +126 -0
  63. package/inline/a/a.ts +682 -0
  64. package/inline/abbr/abbr.ts +490 -0
  65. package/inline/address/address.ts +474 -0
  66. package/inline/b/b.ts +506 -0
  67. package/inline/bdi/bdi.ts +490 -0
  68. package/inline/bdo/bdo.ts +506 -0
  69. package/inline/button/button.ts +826 -0
  70. package/inline/cite/cite.ts +506 -0
  71. package/inline/code/code.ts +506 -0
  72. package/inline/data/data.ts +522 -0
  73. package/inline/dfn/dfn.ts +506 -0
  74. package/inline/em/em.ts +506 -0
  75. package/inline/i/i.ts +506 -0
  76. package/inline/img/img.ts +445 -0
  77. package/inline/input/input.ts +1197 -0
  78. package/inline/kbd/kbd.ts +506 -0
  79. package/inline/label/label.ts +538 -0
  80. package/inline/mark/mark.ts +506 -0
  81. package/inline/meter/meter.ts +554 -0
  82. package/inline/output/output.ts +426 -0
  83. package/inline/progress/progress.ts +490 -0
  84. package/inline/q/q.ts +522 -0
  85. package/inline/rp/rp.ts +506 -0
  86. package/inline/rt/rt.ts +506 -0
  87. package/inline/ruby/ruby.ts +506 -0
  88. package/inline/s/s.ts +506 -0
  89. package/inline/samp/samp.ts +506 -0
  90. package/inline/select/select.ts +810 -0
  91. package/inline/slot/slot.ts +522 -0
  92. package/inline/small/small.ts +506 -0
  93. package/inline/span/span.ts +506 -0
  94. package/inline/strong/strong.ts +506 -0
  95. package/inline/sub/sub.ts +506 -0
  96. package/inline/sup/sup.ts +506 -0
  97. package/inline/svg/svg.ts +618 -0
  98. package/inline/textarea/textarea.ts +874 -0
  99. package/inline/time/time.ts +522 -0
  100. package/inline/u/u.ts +506 -0
  101. package/inline/var/var.ts +506 -0
  102. package/package.json +32 -0
  103. package/tsconfig.json +26 -0
  104. package/void/area/area.ts +397 -0
  105. package/void/base/base.ts +61 -0
  106. package/void/br/br.ts +77 -0
  107. package/void/col/col.ts +77 -0
  108. package/void/head/head.ts +58 -0
  109. package/void/link/link.ts +253 -0
  110. package/void/meta/meta.ts +157 -0
  111. package/void/param/param.ts +93 -0
  112. package/void/script/script.ts +250 -0
  113. package/void/source/source.ts +125 -0
  114. package/void/style/style.ts +154 -0
  115. package/void/title/title.ts +58 -0
  116. package/void/track/track.ts +157 -0
  117. package/void/wbr/wbr.ts +61 -0
@@ -0,0 +1,397 @@
1
+ /**
2
+ * THIS FILE IS AUTOGENERATED. DO NOT EDIT IT.
3
+ *
4
+ * @generated December 28, 2025 12:26:31
5
+ * @component Area
6
+ * @description
7
+ */
8
+
9
+ export interface AreaProps {
10
+ /**
11
+ * specifies a shortcut key (or keys) to activate or focus an element
12
+ */
13
+ accesskey?: string | null | undefined;
14
+ /**
15
+ * Specifies alternative text to be displayed when the image cannot be rendered.
16
+ */
17
+ alt?: string | null | undefined;
18
+ /**
19
+ * Represents the autocapitalize behavior of the element
20
+ */
21
+ autocapitalize?: 'none' | 'sentences' | 'words' | 'characters' | null | undefined;
22
+ /**
23
+ * Indicates whether the element is hidden
24
+ */
25
+ autofocus?: boolean | null | undefined;
26
+ /**
27
+ * Indicates whether the element can be edited in place
28
+ */
29
+ contenteditable?: 'true' | 'false' | 'inherit' | boolean | null | undefined;
30
+ /**
31
+ * Specifies the coordinates of the shape in a rectangular area or a polygonal area on an image map.
32
+ */
33
+ coords?: string | null | undefined;
34
+ /**
35
+ * Represents the text direction of the element
36
+ */
37
+ dir?: 'ltr' | 'rtl' | 'auto' | null | undefined;
38
+ /**
39
+ * Indicates that the linked content should be downloaded rather than displayed.
40
+ */
41
+ download?: string | null | undefined;
42
+ /**
43
+ * Indicates whether the element is draggable
44
+ */
45
+ draggable?: boolean | null | undefined;
46
+ /**
47
+ * Indicates whether the element is hidden
48
+ */
49
+ hidden?: boolean | null | undefined;
50
+ /**
51
+ * Specifies the URL of the linked resource. Special protocols such as mailto: or tel: can be used.
52
+ */
53
+ href?: string | null | undefined;
54
+ /**
55
+ * Specifies the language of the linked resource.
56
+ */
57
+ hreflang?: string | null | undefined;
58
+ /**
59
+ * used to specify the data entry mode for an input. It helps guide on-screen keyboards (especially on mobile devices) to show the appropriate layout for the expected input type
60
+ */
61
+ inputmode?: 'none' | 'text' | 'decimal' | 'numeric' | 'email' | 'tel' | 'url' | 'search' | null | undefined;
62
+ /**
63
+ * Specifies the primary language for the element's content
64
+ */
65
+ lang?: string | null | undefined;
66
+ /**
67
+ * Specifies the relationship between the current document and the linked document.
68
+ */
69
+ rel?: 'alternate' | 'author' | 'bookmark' | 'canonical' | 'help' | 'icon' | 'license' | 'next' | 'nofollow' | 'noreferrer' | 'prefetch' | 'prev' | 'search' | 'stylesheet' | 'tag' | null | undefined;
70
+ /**
71
+ *
72
+ */
73
+ shape?: 'circle' | 'default' | 'poly' | 'rect' | null | undefined;
74
+ /**
75
+ * Represents the spellchecking behavior of the element
76
+ */
77
+ spellcheck?: 'true' | 'false' | boolean | null | undefined;
78
+ /**
79
+ * Represents the CSS inline style of the element
80
+ */
81
+ style?: string | null | undefined;
82
+ /**
83
+ * Represents a tab order of the element
84
+ */
85
+ tabindex?: number | null | undefined;
86
+ /**
87
+ * Specifies where to open the linked document.
88
+ */
89
+ target?: '_blank' | '_parent' | '_self' | '_top' | null | undefined;
90
+ /**
91
+ * Represents a title or tooltip for the element
92
+ */
93
+ title?: string | null | undefined;
94
+ /**
95
+ * used to tell user agents whether the content should be translated.
96
+ */
97
+ translate?: 'yes' | 'no' | null | undefined;
98
+ /**
99
+ * Specifies the media type of the linked resource.
100
+ */
101
+ type?: string | null | undefined;
102
+ }
103
+
104
+ /**
105
+ * Area -
106
+ */
107
+ export class Area {
108
+ private element: HTMLElement;
109
+
110
+ constructor(props: AreaProps = {}) {
111
+ this.element = document.createElement('area');
112
+ this.applyProps(props);
113
+ }
114
+
115
+ private applyProps(props: AreaProps): void {
116
+ if (props.accesskey !== undefined) {
117
+ this.element.setAttribute('accesskey', String(props.accesskey));
118
+ }
119
+ if (props.alt !== undefined) {
120
+ this.element.setAttribute('alt', String(props.alt));
121
+ }
122
+ if (props.autocapitalize !== undefined) {
123
+ this.setAutocapitalize(props.autocapitalize);
124
+ }
125
+ if (props.autofocus !== undefined) {
126
+ this.element.setAttribute('autofocus', String(props.autofocus));
127
+ }
128
+ if (props.contenteditable !== undefined) {
129
+ this.setContenteditable(props.contenteditable);
130
+ }
131
+ if (props.coords !== undefined) {
132
+ this.element.setAttribute('coords', String(props.coords));
133
+ }
134
+ if (props.dir !== undefined) {
135
+ this.setDir(props.dir);
136
+ }
137
+ if (props.download !== undefined) {
138
+ this.element.setAttribute('download', String(props.download));
139
+ }
140
+ if (props.draggable !== undefined) {
141
+ this.element.setAttribute('draggable', String(props.draggable));
142
+ }
143
+ if (props.hidden !== undefined) {
144
+ this.element.setAttribute('hidden', String(props.hidden));
145
+ }
146
+ if (props.href !== undefined) {
147
+ this.element.setAttribute('href', String(props.href));
148
+ }
149
+ if (props.hreflang !== undefined) {
150
+ this.element.setAttribute('hreflang', String(props.hreflang));
151
+ }
152
+ if (props.inputmode !== undefined) {
153
+ this.setInputmode(props.inputmode);
154
+ }
155
+ if (props.lang !== undefined) {
156
+ this.element.setAttribute('lang', String(props.lang));
157
+ }
158
+ if (props.rel !== undefined) {
159
+ this.setRel(props.rel);
160
+ }
161
+ if (props.shape !== undefined) {
162
+ this.setShape(props.shape);
163
+ }
164
+ if (props.spellcheck !== undefined) {
165
+ this.setSpellcheck(props.spellcheck);
166
+ }
167
+ if (props.style !== undefined) {
168
+ this.element.setAttribute('style', String(props.style));
169
+ }
170
+ if (props.tabindex !== undefined) {
171
+ this.element.setAttribute('tabindex', String(props.tabindex));
172
+ }
173
+ if (props.target !== undefined) {
174
+ this.setTarget(props.target);
175
+ }
176
+ if (props.title !== undefined) {
177
+ this.element.setAttribute('title', String(props.title));
178
+ }
179
+ if (props.translate !== undefined) {
180
+ this.setTranslate(props.translate);
181
+ }
182
+ if (props.type !== undefined) {
183
+ this.element.setAttribute('type', String(props.type));
184
+ }
185
+ }
186
+
187
+ setAccesskey(value: string | null | undefined): this {
188
+ if (value === null || value === undefined) {
189
+ this.element.removeAttribute('accesskey');
190
+ } else {
191
+ this.element.setAttribute('accesskey', String(value));
192
+ }
193
+ return this;
194
+ }
195
+
196
+ setAlt(value: string | null | undefined): this {
197
+ if (value === null || value === undefined) {
198
+ this.element.removeAttribute('alt');
199
+ } else {
200
+ this.element.setAttribute('alt', String(value));
201
+ }
202
+ return this;
203
+ }
204
+
205
+ setAutocapitalize(value: 'none' | 'sentences' | 'words' | 'characters' | null | undefined): this {
206
+ if (value === null || value === undefined) {
207
+ this.element.removeAttribute('autocapitalize');
208
+ } else {
209
+ this.element.setAttribute('autocapitalize', String(value));
210
+ }
211
+ return this;
212
+ }
213
+
214
+ setAutofocus(value: boolean | null | undefined): this {
215
+ if (value === true) {
216
+ this.element.setAttribute('autofocus', '');
217
+ } else {
218
+ this.element.removeAttribute('autofocus');
219
+ }
220
+ return this;
221
+ }
222
+
223
+ setContenteditable(value: 'true' | 'false' | 'inherit' | boolean | null | undefined): this {
224
+ if (value === null || value === undefined) {
225
+ this.element.removeAttribute('contenteditable');
226
+ } else {
227
+ this.element.setAttribute('contenteditable', String(value));
228
+ }
229
+ return this;
230
+ }
231
+
232
+ setCoords(value: string | null | undefined): this {
233
+ if (value === null || value === undefined) {
234
+ this.element.removeAttribute('coords');
235
+ } else {
236
+ this.element.setAttribute('coords', String(value));
237
+ }
238
+ return this;
239
+ }
240
+
241
+ setDir(value: 'ltr' | 'rtl' | 'auto' | null | undefined): this {
242
+ if (value === null || value === undefined) {
243
+ this.element.removeAttribute('dir');
244
+ } else {
245
+ this.element.setAttribute('dir', String(value));
246
+ }
247
+ return this;
248
+ }
249
+
250
+ setDownload(value: string | null | undefined): this {
251
+ if (value === null || value === undefined) {
252
+ this.element.removeAttribute('download');
253
+ } else {
254
+ this.element.setAttribute('download', String(value));
255
+ }
256
+ return this;
257
+ }
258
+
259
+ setDraggable(value: boolean | null | undefined): this {
260
+ if (value === true) {
261
+ this.element.setAttribute('draggable', '');
262
+ } else {
263
+ this.element.removeAttribute('draggable');
264
+ }
265
+ return this;
266
+ }
267
+
268
+ setHidden(value: boolean | null | undefined): this {
269
+ if (value === true) {
270
+ this.element.setAttribute('hidden', '');
271
+ } else {
272
+ this.element.removeAttribute('hidden');
273
+ }
274
+ return this;
275
+ }
276
+
277
+ setHref(value: string | null | undefined): this {
278
+ if (value === null || value === undefined) {
279
+ this.element.removeAttribute('href');
280
+ } else {
281
+ this.element.setAttribute('href', String(value));
282
+ }
283
+ return this;
284
+ }
285
+
286
+ setHreflang(value: string | null | undefined): this {
287
+ if (value === null || value === undefined) {
288
+ this.element.removeAttribute('hreflang');
289
+ } else {
290
+ this.element.setAttribute('hreflang', String(value));
291
+ }
292
+ return this;
293
+ }
294
+
295
+ setInputmode(value: 'none' | 'text' | 'decimal' | 'numeric' | 'email' | 'tel' | 'url' | 'search' | null | undefined): this {
296
+ if (value === null || value === undefined) {
297
+ this.element.removeAttribute('inputmode');
298
+ } else {
299
+ this.element.setAttribute('inputmode', String(value));
300
+ }
301
+ return this;
302
+ }
303
+
304
+ setLang(value: string | null | undefined): this {
305
+ if (value === null || value === undefined) {
306
+ this.element.removeAttribute('lang');
307
+ } else {
308
+ this.element.setAttribute('lang', String(value));
309
+ }
310
+ return this;
311
+ }
312
+
313
+ setRel(value: 'alternate' | 'author' | 'bookmark' | 'canonical' | 'help' | 'icon' | 'license' | 'next' | 'nofollow' | 'noreferrer' | 'prefetch' | 'prev' | 'search' | 'stylesheet' | 'tag' | null | undefined): this {
314
+ if (value === null || value === undefined) {
315
+ this.element.removeAttribute('rel');
316
+ } else {
317
+ this.element.setAttribute('rel', String(value));
318
+ }
319
+ return this;
320
+ }
321
+
322
+ setShape(value: 'circle' | 'default' | 'poly' | 'rect' | null | undefined): this {
323
+ if (value === null || value === undefined) {
324
+ this.element.removeAttribute('shape');
325
+ } else {
326
+ this.element.setAttribute('shape', String(value));
327
+ }
328
+ return this;
329
+ }
330
+
331
+ setSpellcheck(value: 'true' | 'false' | boolean | null | undefined): this {
332
+ if (value === null || value === undefined) {
333
+ this.element.removeAttribute('spellcheck');
334
+ } else {
335
+ this.element.setAttribute('spellcheck', String(value));
336
+ }
337
+ return this;
338
+ }
339
+
340
+ setStyle(value: string | null | undefined): this {
341
+ if (value === null || value === undefined) {
342
+ this.element.removeAttribute('style');
343
+ } else {
344
+ this.element.setAttribute('style', String(value));
345
+ }
346
+ return this;
347
+ }
348
+
349
+ setTabindex(value: number | null | undefined): this {
350
+ if (value === null || value === undefined) {
351
+ this.element.removeAttribute('tabindex');
352
+ } else {
353
+ this.element.setAttribute('tabindex', String(value));
354
+ }
355
+ return this;
356
+ }
357
+
358
+ setTarget(value: '_blank' | '_parent' | '_self' | '_top' | null | undefined): this {
359
+ if (value === null || value === undefined) {
360
+ this.element.removeAttribute('target');
361
+ } else {
362
+ this.element.setAttribute('target', String(value));
363
+ }
364
+ return this;
365
+ }
366
+
367
+ setTitle(value: string | null | undefined): this {
368
+ if (value === null || value === undefined) {
369
+ this.element.removeAttribute('title');
370
+ } else {
371
+ this.element.setAttribute('title', String(value));
372
+ }
373
+ return this;
374
+ }
375
+
376
+ setTranslate(value: 'yes' | 'no' | null | undefined): this {
377
+ if (value === null || value === undefined) {
378
+ this.element.removeAttribute('translate');
379
+ } else {
380
+ this.element.setAttribute('translate', String(value));
381
+ }
382
+ return this;
383
+ }
384
+
385
+ setType(value: string | null | undefined): this {
386
+ if (value === null || value === undefined) {
387
+ this.element.removeAttribute('type');
388
+ } else {
389
+ this.element.setAttribute('type', String(value));
390
+ }
391
+ return this;
392
+ }
393
+
394
+ getElement(): HTMLElement {
395
+ return this.element;
396
+ }
397
+ }
@@ -0,0 +1,61 @@
1
+ /**
2
+ * THIS FILE IS AUTOGENERATED. DO NOT EDIT IT.
3
+ *
4
+ * @generated December 28, 2025 12:26:31
5
+ * @component Base
6
+ * @description
7
+ */
8
+
9
+ export interface BaseProps {
10
+ /**
11
+ * Specifies the URL of the linked resource. Special protocols such as mailto: or tel: can be used.
12
+ */
13
+ href?: string | null | undefined;
14
+ /**
15
+ * Specifies where to open the linked document.
16
+ */
17
+ target?: '_blank' | '_parent' | '_self' | '_top' | null | undefined;
18
+ }
19
+
20
+ /**
21
+ * Base -
22
+ */
23
+ export class Base {
24
+ private element: HTMLElement;
25
+
26
+ constructor(props: BaseProps = {}) {
27
+ this.element = document.createElement('base');
28
+ this.applyProps(props);
29
+ }
30
+
31
+ private applyProps(props: BaseProps): void {
32
+ if (props.href !== undefined) {
33
+ this.element.setAttribute('href', String(props.href));
34
+ }
35
+ if (props.target !== undefined) {
36
+ this.setTarget(props.target);
37
+ }
38
+ }
39
+
40
+ setHref(value: string | null | undefined): this {
41
+ if (value === null || value === undefined) {
42
+ this.element.removeAttribute('href');
43
+ } else {
44
+ this.element.setAttribute('href', String(value));
45
+ }
46
+ return this;
47
+ }
48
+
49
+ setTarget(value: '_blank' | '_parent' | '_self' | '_top' | null | undefined): this {
50
+ if (value === null || value === undefined) {
51
+ this.element.removeAttribute('target');
52
+ } else {
53
+ this.element.setAttribute('target', String(value));
54
+ }
55
+ return this;
56
+ }
57
+
58
+ getElement(): HTMLElement {
59
+ return this.element;
60
+ }
61
+ }
package/void/br/br.ts ADDED
@@ -0,0 +1,77 @@
1
+ /**
2
+ * THIS FILE IS AUTOGENERATED. DO NOT EDIT IT.
3
+ *
4
+ * @generated December 28, 2025 12:26:31
5
+ * @component Br
6
+ * @description
7
+ */
8
+
9
+ export interface BrProps {
10
+ /**
11
+ * Represents the text direction of the element
12
+ */
13
+ dir?: 'ltr' | 'rtl' | 'auto' | null | undefined;
14
+ /**
15
+ * Indicates whether the element is hidden
16
+ */
17
+ hidden?: boolean | null | undefined;
18
+ /**
19
+ * Represents the CSS inline style of the element
20
+ */
21
+ style?: string | null | undefined;
22
+ }
23
+
24
+ /**
25
+ * Br -
26
+ */
27
+ export class Br {
28
+ private element: HTMLElement;
29
+
30
+ constructor(props: BrProps = {}) {
31
+ this.element = document.createElement('br');
32
+ this.applyProps(props);
33
+ }
34
+
35
+ private applyProps(props: BrProps): void {
36
+ if (props.dir !== undefined) {
37
+ this.setDir(props.dir);
38
+ }
39
+ if (props.hidden !== undefined) {
40
+ this.element.setAttribute('hidden', String(props.hidden));
41
+ }
42
+ if (props.style !== undefined) {
43
+ this.element.setAttribute('style', String(props.style));
44
+ }
45
+ }
46
+
47
+ setDir(value: 'ltr' | 'rtl' | 'auto' | null | undefined): this {
48
+ if (value === null || value === undefined) {
49
+ this.element.removeAttribute('dir');
50
+ } else {
51
+ this.element.setAttribute('dir', String(value));
52
+ }
53
+ return this;
54
+ }
55
+
56
+ setHidden(value: boolean | null | undefined): this {
57
+ if (value === true) {
58
+ this.element.setAttribute('hidden', '');
59
+ } else {
60
+ this.element.removeAttribute('hidden');
61
+ }
62
+ return this;
63
+ }
64
+
65
+ setStyle(value: string | null | undefined): this {
66
+ if (value === null || value === undefined) {
67
+ this.element.removeAttribute('style');
68
+ } else {
69
+ this.element.setAttribute('style', String(value));
70
+ }
71
+ return this;
72
+ }
73
+
74
+ getElement(): HTMLElement {
75
+ return this.element;
76
+ }
77
+ }
@@ -0,0 +1,77 @@
1
+ /**
2
+ * THIS FILE IS AUTOGENERATED. DO NOT EDIT IT.
3
+ *
4
+ * @generated December 28, 2025 12:26:31
5
+ * @component Col
6
+ * @description
7
+ */
8
+
9
+ export interface ColProps {
10
+ /**
11
+ * Specifies the number of columns the <col> element should span in a table.
12
+ */
13
+ span?: number | null | undefined;
14
+ /**
15
+ * Represents the CSS inline style of the element
16
+ */
17
+ style?: string | null | undefined;
18
+ /**
19
+ * Specifies the width of the element. The meaning may vary depending on the element type. Accepts integers, pixels (px), and percentages (%).
20
+ */
21
+ width?: string | null | undefined;
22
+ }
23
+
24
+ /**
25
+ * Col -
26
+ */
27
+ export class Col {
28
+ private element: HTMLElement;
29
+
30
+ constructor(props: ColProps = {}) {
31
+ this.element = document.createElement('col');
32
+ this.applyProps(props);
33
+ }
34
+
35
+ private applyProps(props: ColProps): void {
36
+ if (props.span !== undefined) {
37
+ this.element.setAttribute('span', String(props.span));
38
+ }
39
+ if (props.style !== undefined) {
40
+ this.element.setAttribute('style', String(props.style));
41
+ }
42
+ if (props.width !== undefined) {
43
+ this.element.setAttribute('width', String(props.width));
44
+ }
45
+ }
46
+
47
+ setSpan(value: number | null | undefined): this {
48
+ if (value === null || value === undefined) {
49
+ this.element.removeAttribute('span');
50
+ } else {
51
+ this.element.setAttribute('span', String(value));
52
+ }
53
+ return this;
54
+ }
55
+
56
+ setStyle(value: string | null | undefined): this {
57
+ if (value === null || value === undefined) {
58
+ this.element.removeAttribute('style');
59
+ } else {
60
+ this.element.setAttribute('style', String(value));
61
+ }
62
+ return this;
63
+ }
64
+
65
+ setWidth(value: string | null | undefined): this {
66
+ if (value === null || value === undefined) {
67
+ this.element.removeAttribute('width');
68
+ } else {
69
+ this.element.setAttribute('width', String(value));
70
+ }
71
+ return this;
72
+ }
73
+
74
+ getElement(): HTMLElement {
75
+ return this.element;
76
+ }
77
+ }
@@ -0,0 +1,58 @@
1
+ /**
2
+ * THIS FILE IS AUTOGENERATED. DO NOT EDIT IT.
3
+ *
4
+ * @generated December 28, 2025 12:26:31
5
+ * @component Head
6
+ * @description
7
+ */
8
+
9
+ export interface HeadProps {
10
+ /**
11
+ * Child content or elements
12
+ */
13
+ children?: string | HTMLElement | (string | HTMLElement)[];
14
+ }
15
+
16
+ /**
17
+ * Head -
18
+ */
19
+ export class Head {
20
+ private element: HTMLElement;
21
+
22
+ constructor(props: HeadProps = {}) {
23
+ this.element = document.createElement('head');
24
+ this.applyProps(props);
25
+ }
26
+
27
+ private applyProps(props: HeadProps): void {
28
+ if (props.children !== undefined) {
29
+ this.setChildren(props.children);
30
+ }
31
+ }
32
+
33
+ setChildren(children: string | HTMLElement | (string | HTMLElement)[]): this {
34
+ // Clear existing children
35
+ while (this.element.firstChild) {
36
+ this.element.removeChild(this.element.firstChild);
37
+ }
38
+
39
+ if (typeof children === 'string') {
40
+ this.element.textContent = children;
41
+ } else if (Array.isArray(children)) {
42
+ children.forEach(child => {
43
+ if (typeof child === 'string') {
44
+ this.element.appendChild(document.createTextNode(child));
45
+ } else {
46
+ this.element.appendChild(child);
47
+ }
48
+ });
49
+ } else {
50
+ this.element.appendChild(children);
51
+ }
52
+ return this;
53
+ }
54
+
55
+ getElement(): HTMLElement {
56
+ return this.element;
57
+ }
58
+ }