@json-to-office/shared-docx 0.1.0
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.
- package/LICENSE +18 -0
- package/README.md +9 -0
- package/dist/chunk-5533WPL6.js +1895 -0
- package/dist/chunk-5533WPL6.js.map +1 -0
- package/dist/chunk-AA4HIXRG.js +34 -0
- package/dist/chunk-AA4HIXRG.js.map +1 -0
- package/dist/chunk-BEPLK76M.js +454 -0
- package/dist/chunk-BEPLK76M.js.map +1 -0
- package/dist/chunk-BOUURUYX.js +364 -0
- package/dist/chunk-BOUURUYX.js.map +1 -0
- package/dist/chunk-EKWM2CWA.js +97 -0
- package/dist/chunk-EKWM2CWA.js.map +1 -0
- package/dist/chunk-ET6YMNMF.js +35 -0
- package/dist/chunk-ET6YMNMF.js.map +1 -0
- package/dist/chunk-F5LVWDTY.js +57 -0
- package/dist/chunk-F5LVWDTY.js.map +1 -0
- package/dist/chunk-HHMK2RWF.js +274 -0
- package/dist/chunk-HHMK2RWF.js.map +1 -0
- package/dist/chunk-LOE6BZQG.js +750 -0
- package/dist/chunk-LOE6BZQG.js.map +1 -0
- package/dist/chunk-LWR4TFZ5.js +121 -0
- package/dist/chunk-LWR4TFZ5.js.map +1 -0
- package/dist/chunk-VP3X6DBP.js +44 -0
- package/dist/chunk-VP3X6DBP.js.map +1 -0
- package/dist/document-validator-CiaGiy1v.d.ts +119 -0
- package/dist/index.d.ts +938 -0
- package/dist/index.js +1129 -0
- package/dist/index.js.map +1 -0
- package/dist/schemas/api.d.ts +46 -0
- package/dist/schemas/api.js +16 -0
- package/dist/schemas/api.js.map +1 -0
- package/dist/schemas/component-registry.d.ts +90 -0
- package/dist/schemas/component-registry.js +24 -0
- package/dist/schemas/component-registry.js.map +1 -0
- package/dist/schemas/components.d.ts +755 -0
- package/dist/schemas/components.js +94 -0
- package/dist/schemas/components.js.map +1 -0
- package/dist/schemas/custom-components.d.ts +59 -0
- package/dist/schemas/custom-components.js +11 -0
- package/dist/schemas/custom-components.js.map +1 -0
- package/dist/schemas/document.d.ts +43 -0
- package/dist/schemas/document.js +19 -0
- package/dist/schemas/document.js.map +1 -0
- package/dist/schemas/export.d.ts +67 -0
- package/dist/schemas/export.js +19 -0
- package/dist/schemas/export.js.map +1 -0
- package/dist/schemas/font.d.ts +57 -0
- package/dist/schemas/font.js +11 -0
- package/dist/schemas/font.js.map +1 -0
- package/dist/schemas/generator.d.ts +80 -0
- package/dist/schemas/generator.js +9 -0
- package/dist/schemas/generator.js.map +1 -0
- package/dist/schemas/theme.d.ts +3354 -0
- package/dist/schemas/theme.js +42 -0
- package/dist/schemas/theme.js.map +1 -0
- package/dist/validation/unified/index.d.ts +720 -0
- package/dist/validation/unified/index.js +154 -0
- package/dist/validation/unified/index.js.map +1 -0
- package/package.json +80 -0
|
@@ -0,0 +1,1895 @@
|
|
|
1
|
+
import {
|
|
2
|
+
FontDefinitionSchema,
|
|
3
|
+
HexColorSchema
|
|
4
|
+
} from "./chunk-F5LVWDTY.js";
|
|
5
|
+
|
|
6
|
+
// src/schemas/component-registry.ts
|
|
7
|
+
import { Type as Type16 } from "@sinclair/typebox";
|
|
8
|
+
|
|
9
|
+
// src/schemas/components/report.ts
|
|
10
|
+
import { Type } from "@sinclair/typebox";
|
|
11
|
+
var createReportPropsSchema = (_moduleRef) => Type.Object(
|
|
12
|
+
{
|
|
13
|
+
theme: Type.Optional(
|
|
14
|
+
Type.String({
|
|
15
|
+
description: 'Theme name to apply (default: "minimal")',
|
|
16
|
+
examples: ["corporate", "professional", "minimal"],
|
|
17
|
+
default: "minimal"
|
|
18
|
+
})
|
|
19
|
+
),
|
|
20
|
+
metadata: Type.Optional(
|
|
21
|
+
Type.Object(
|
|
22
|
+
{
|
|
23
|
+
title: Type.Optional(
|
|
24
|
+
Type.String({
|
|
25
|
+
description: "Document title",
|
|
26
|
+
examples: ["Annual Report 2024", "Technical Documentation"]
|
|
27
|
+
})
|
|
28
|
+
),
|
|
29
|
+
subtitle: Type.Optional(
|
|
30
|
+
Type.String({
|
|
31
|
+
description: "Document subtitle"
|
|
32
|
+
})
|
|
33
|
+
),
|
|
34
|
+
description: Type.Optional(Type.String()),
|
|
35
|
+
author: Type.Optional(Type.String()),
|
|
36
|
+
company: Type.Optional(Type.String()),
|
|
37
|
+
date: Type.Optional(Type.String()),
|
|
38
|
+
created: Type.Optional(Type.String({ format: "date-time" })),
|
|
39
|
+
modified: Type.Optional(Type.String({ format: "date-time" })),
|
|
40
|
+
version: Type.Optional(Type.String()),
|
|
41
|
+
tags: Type.Optional(Type.Array(Type.String()))
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
description: "Document metadata (title, author, company, dates, etc.)",
|
|
45
|
+
additionalProperties: false
|
|
46
|
+
}
|
|
47
|
+
)
|
|
48
|
+
)
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
description: "Report component props",
|
|
52
|
+
additionalProperties: false
|
|
53
|
+
}
|
|
54
|
+
);
|
|
55
|
+
var ReportPropsSchema = createReportPropsSchema();
|
|
56
|
+
|
|
57
|
+
// src/schemas/components/section.ts
|
|
58
|
+
import { Type as Type3 } from "@sinclair/typebox";
|
|
59
|
+
|
|
60
|
+
// src/schemas/components/common.ts
|
|
61
|
+
import { Type as Type2 } from "@sinclair/typebox";
|
|
62
|
+
var AlignmentSchema = Type2.Union(
|
|
63
|
+
[Type2.Literal("left"), Type2.Literal("center"), Type2.Literal("right")],
|
|
64
|
+
{ description: "Text alignment options" }
|
|
65
|
+
);
|
|
66
|
+
var JustifiedAlignmentSchema = Type2.Union(
|
|
67
|
+
[
|
|
68
|
+
Type2.Literal("left"),
|
|
69
|
+
Type2.Literal("center"),
|
|
70
|
+
Type2.Literal("right"),
|
|
71
|
+
Type2.Literal("justify")
|
|
72
|
+
],
|
|
73
|
+
{ description: "Text alignment options including justify" }
|
|
74
|
+
);
|
|
75
|
+
var HeadingLevelSchema = Type2.Union(
|
|
76
|
+
[
|
|
77
|
+
Type2.Literal(1),
|
|
78
|
+
Type2.Literal(2),
|
|
79
|
+
Type2.Literal(3),
|
|
80
|
+
Type2.Literal(4),
|
|
81
|
+
Type2.Literal(5),
|
|
82
|
+
Type2.Literal(6)
|
|
83
|
+
],
|
|
84
|
+
{ description: "Heading level (1-6)" }
|
|
85
|
+
);
|
|
86
|
+
var SpacingSchema = Type2.Object(
|
|
87
|
+
{
|
|
88
|
+
before: Type2.Optional(
|
|
89
|
+
Type2.Number({
|
|
90
|
+
minimum: 0,
|
|
91
|
+
description: "Spacing before element in points"
|
|
92
|
+
})
|
|
93
|
+
),
|
|
94
|
+
after: Type2.Optional(
|
|
95
|
+
Type2.Number({
|
|
96
|
+
minimum: 0,
|
|
97
|
+
description: "Spacing after element in points"
|
|
98
|
+
})
|
|
99
|
+
)
|
|
100
|
+
},
|
|
101
|
+
{
|
|
102
|
+
description: "Spacing configuration",
|
|
103
|
+
additionalProperties: false
|
|
104
|
+
}
|
|
105
|
+
);
|
|
106
|
+
var ListSpacingSchema = Type2.Object(
|
|
107
|
+
{
|
|
108
|
+
before: Type2.Optional(
|
|
109
|
+
Type2.Number({
|
|
110
|
+
minimum: 0,
|
|
111
|
+
description: "Spacing before list in points"
|
|
112
|
+
})
|
|
113
|
+
),
|
|
114
|
+
after: Type2.Optional(
|
|
115
|
+
Type2.Number({
|
|
116
|
+
minimum: 0,
|
|
117
|
+
description: "Spacing after list in points"
|
|
118
|
+
})
|
|
119
|
+
),
|
|
120
|
+
item: Type2.Optional(
|
|
121
|
+
Type2.Number({
|
|
122
|
+
minimum: 0,
|
|
123
|
+
description: "Spacing between list items in points"
|
|
124
|
+
})
|
|
125
|
+
)
|
|
126
|
+
},
|
|
127
|
+
{
|
|
128
|
+
description: "List spacing configuration with item spacing",
|
|
129
|
+
additionalProperties: false
|
|
130
|
+
}
|
|
131
|
+
);
|
|
132
|
+
var MarginsSchema = Type2.Object(
|
|
133
|
+
{
|
|
134
|
+
top: Type2.Optional(Type2.Number({ minimum: 0 })),
|
|
135
|
+
bottom: Type2.Optional(Type2.Number({ minimum: 0 })),
|
|
136
|
+
left: Type2.Optional(Type2.Number({ minimum: 0 })),
|
|
137
|
+
right: Type2.Optional(Type2.Number({ minimum: 0 }))
|
|
138
|
+
},
|
|
139
|
+
{ description: "Margin configuration" }
|
|
140
|
+
);
|
|
141
|
+
var BorderSchema = Type2.Object(
|
|
142
|
+
{
|
|
143
|
+
style: Type2.Optional(
|
|
144
|
+
Type2.Union([
|
|
145
|
+
Type2.Literal("solid"),
|
|
146
|
+
Type2.Literal("dashed"),
|
|
147
|
+
Type2.Literal("dotted"),
|
|
148
|
+
Type2.Literal("double"),
|
|
149
|
+
Type2.Literal("none")
|
|
150
|
+
])
|
|
151
|
+
),
|
|
152
|
+
width: Type2.Optional(Type2.Number({ minimum: 0 })),
|
|
153
|
+
color: Type2.Optional(HexColorSchema)
|
|
154
|
+
},
|
|
155
|
+
{ description: "Border configuration" }
|
|
156
|
+
);
|
|
157
|
+
var LineSpacingSchema = Type2.Object(
|
|
158
|
+
{
|
|
159
|
+
type: Type2.Union([
|
|
160
|
+
Type2.Literal("single"),
|
|
161
|
+
Type2.Literal("atLeast"),
|
|
162
|
+
Type2.Literal("exactly"),
|
|
163
|
+
Type2.Literal("double"),
|
|
164
|
+
Type2.Literal("multiple")
|
|
165
|
+
]),
|
|
166
|
+
value: Type2.Optional(Type2.Number({ minimum: 0 }))
|
|
167
|
+
},
|
|
168
|
+
{ description: "Line spacing configuration" }
|
|
169
|
+
);
|
|
170
|
+
var IndentSchema = Type2.Object(
|
|
171
|
+
{
|
|
172
|
+
left: Type2.Optional(Type2.Number({ minimum: 0 })),
|
|
173
|
+
hanging: Type2.Optional(Type2.Number({ minimum: 0 }))
|
|
174
|
+
},
|
|
175
|
+
{ description: "Indentation configuration" }
|
|
176
|
+
);
|
|
177
|
+
var HorizontalPositionRelativeFromSchema = Type2.Union(
|
|
178
|
+
[
|
|
179
|
+
Type2.Literal("character"),
|
|
180
|
+
Type2.Literal("column"),
|
|
181
|
+
Type2.Literal("margin"),
|
|
182
|
+
Type2.Literal("page"),
|
|
183
|
+
Type2.Literal("text")
|
|
184
|
+
// VML compatibility for text-box
|
|
185
|
+
],
|
|
186
|
+
{
|
|
187
|
+
description: "Horizontal position relative to"
|
|
188
|
+
}
|
|
189
|
+
);
|
|
190
|
+
var VerticalPositionRelativeFromSchema = Type2.Union(
|
|
191
|
+
[
|
|
192
|
+
Type2.Literal("margin"),
|
|
193
|
+
Type2.Literal("page"),
|
|
194
|
+
Type2.Literal("paragraph"),
|
|
195
|
+
Type2.Literal("line"),
|
|
196
|
+
Type2.Literal("text")
|
|
197
|
+
// VML compatibility for text-box
|
|
198
|
+
],
|
|
199
|
+
{
|
|
200
|
+
description: "Vertical position relative to"
|
|
201
|
+
}
|
|
202
|
+
);
|
|
203
|
+
var HorizontalPositionAlignSchema = Type2.Union(
|
|
204
|
+
[
|
|
205
|
+
Type2.Literal("left"),
|
|
206
|
+
Type2.Literal("center"),
|
|
207
|
+
Type2.Literal("right"),
|
|
208
|
+
Type2.Literal("inside"),
|
|
209
|
+
Type2.Literal("outside")
|
|
210
|
+
],
|
|
211
|
+
{
|
|
212
|
+
description: "Horizontal alignment"
|
|
213
|
+
}
|
|
214
|
+
);
|
|
215
|
+
var VerticalPositionAlignSchema = Type2.Union(
|
|
216
|
+
[
|
|
217
|
+
Type2.Literal("top"),
|
|
218
|
+
Type2.Literal("center"),
|
|
219
|
+
Type2.Literal("bottom"),
|
|
220
|
+
Type2.Literal("inside"),
|
|
221
|
+
Type2.Literal("outside")
|
|
222
|
+
],
|
|
223
|
+
{
|
|
224
|
+
description: "Vertical alignment"
|
|
225
|
+
}
|
|
226
|
+
);
|
|
227
|
+
var TextWrappingTypeSchema = Type2.Union(
|
|
228
|
+
[
|
|
229
|
+
Type2.Literal("none"),
|
|
230
|
+
Type2.Literal("square"),
|
|
231
|
+
Type2.Literal("topAndBottom"),
|
|
232
|
+
Type2.Literal("around"),
|
|
233
|
+
// VML compatibility for text-box
|
|
234
|
+
Type2.Literal("tight"),
|
|
235
|
+
// VML compatibility for text-box
|
|
236
|
+
Type2.Literal("through")
|
|
237
|
+
// VML compatibility for text-box
|
|
238
|
+
],
|
|
239
|
+
{
|
|
240
|
+
description: "Text wrapping type"
|
|
241
|
+
}
|
|
242
|
+
);
|
|
243
|
+
var TextWrappingSideSchema = Type2.Union(
|
|
244
|
+
[
|
|
245
|
+
Type2.Literal("bothSides"),
|
|
246
|
+
Type2.Literal("left"),
|
|
247
|
+
Type2.Literal("right"),
|
|
248
|
+
Type2.Literal("largest")
|
|
249
|
+
],
|
|
250
|
+
{
|
|
251
|
+
description: "Text wrapping side"
|
|
252
|
+
}
|
|
253
|
+
);
|
|
254
|
+
var FloatingPropertiesSchema = Type2.Object(
|
|
255
|
+
{
|
|
256
|
+
horizontalPosition: Type2.Optional(
|
|
257
|
+
Type2.Object(
|
|
258
|
+
{
|
|
259
|
+
relative: Type2.Optional(HorizontalPositionRelativeFromSchema),
|
|
260
|
+
align: Type2.Optional(HorizontalPositionAlignSchema),
|
|
261
|
+
offset: Type2.Optional(
|
|
262
|
+
Type2.Number({
|
|
263
|
+
description: "Horizontal offset in twips (1/20 of a point)"
|
|
264
|
+
})
|
|
265
|
+
)
|
|
266
|
+
},
|
|
267
|
+
{
|
|
268
|
+
description: "Horizontal positioning (use either align or offset, not both)"
|
|
269
|
+
}
|
|
270
|
+
)
|
|
271
|
+
),
|
|
272
|
+
verticalPosition: Type2.Optional(
|
|
273
|
+
Type2.Object(
|
|
274
|
+
{
|
|
275
|
+
relative: Type2.Optional(VerticalPositionRelativeFromSchema),
|
|
276
|
+
align: Type2.Optional(VerticalPositionAlignSchema),
|
|
277
|
+
offset: Type2.Optional(
|
|
278
|
+
Type2.Number({
|
|
279
|
+
description: "Vertical offset in twips (1/20 of a point)"
|
|
280
|
+
})
|
|
281
|
+
)
|
|
282
|
+
},
|
|
283
|
+
{
|
|
284
|
+
description: "Vertical positioning (use either align or offset, not both)"
|
|
285
|
+
}
|
|
286
|
+
)
|
|
287
|
+
),
|
|
288
|
+
wrap: Type2.Optional(
|
|
289
|
+
Type2.Object(
|
|
290
|
+
{
|
|
291
|
+
type: TextWrappingTypeSchema,
|
|
292
|
+
side: Type2.Optional(TextWrappingSideSchema),
|
|
293
|
+
margins: Type2.Optional(
|
|
294
|
+
Type2.Object(
|
|
295
|
+
{
|
|
296
|
+
top: Type2.Optional(
|
|
297
|
+
Type2.Number({ description: "Top margin in twips" })
|
|
298
|
+
),
|
|
299
|
+
bottom: Type2.Optional(
|
|
300
|
+
Type2.Number({ description: "Bottom margin in twips" })
|
|
301
|
+
),
|
|
302
|
+
left: Type2.Optional(
|
|
303
|
+
Type2.Number({ description: "Left margin in twips" })
|
|
304
|
+
),
|
|
305
|
+
right: Type2.Optional(
|
|
306
|
+
Type2.Number({ description: "Right margin in twips" })
|
|
307
|
+
)
|
|
308
|
+
},
|
|
309
|
+
{
|
|
310
|
+
description: "Distance from text margins"
|
|
311
|
+
}
|
|
312
|
+
)
|
|
313
|
+
)
|
|
314
|
+
},
|
|
315
|
+
{
|
|
316
|
+
description: "Text wrapping configuration"
|
|
317
|
+
}
|
|
318
|
+
)
|
|
319
|
+
),
|
|
320
|
+
allowOverlap: Type2.Optional(
|
|
321
|
+
Type2.Boolean({
|
|
322
|
+
description: "Allow element to overlap with other elements"
|
|
323
|
+
})
|
|
324
|
+
),
|
|
325
|
+
behindDocument: Type2.Optional(
|
|
326
|
+
Type2.Boolean({
|
|
327
|
+
description: "Place element behind document text"
|
|
328
|
+
})
|
|
329
|
+
),
|
|
330
|
+
lockAnchor: Type2.Optional(
|
|
331
|
+
Type2.Boolean({
|
|
332
|
+
description: "Lock the anchor position"
|
|
333
|
+
})
|
|
334
|
+
),
|
|
335
|
+
layoutInCell: Type2.Optional(
|
|
336
|
+
Type2.Boolean({
|
|
337
|
+
description: "Layout element within table cell"
|
|
338
|
+
})
|
|
339
|
+
),
|
|
340
|
+
zIndex: Type2.Optional(
|
|
341
|
+
Type2.Number({
|
|
342
|
+
minimum: 0,
|
|
343
|
+
description: "Z-order for overlapping elements (must be non-negative)"
|
|
344
|
+
})
|
|
345
|
+
),
|
|
346
|
+
rotation: Type2.Optional(
|
|
347
|
+
Type2.Number({
|
|
348
|
+
description: "Rotation angle in degrees"
|
|
349
|
+
})
|
|
350
|
+
),
|
|
351
|
+
visibility: Type2.Optional(
|
|
352
|
+
Type2.Union([Type2.Literal("hidden"), Type2.Literal("inherit")], {
|
|
353
|
+
description: "Visibility of the floating element"
|
|
354
|
+
})
|
|
355
|
+
)
|
|
356
|
+
},
|
|
357
|
+
{
|
|
358
|
+
description: "Floating element properties"
|
|
359
|
+
}
|
|
360
|
+
);
|
|
361
|
+
var NumberingSchema = Type2.Object(
|
|
362
|
+
{
|
|
363
|
+
start: Type2.Optional(Type2.Number({ minimum: 1 })),
|
|
364
|
+
style: Type2.Optional(
|
|
365
|
+
Type2.Union([
|
|
366
|
+
Type2.Literal("decimal"),
|
|
367
|
+
Type2.Literal("lowerLetter"),
|
|
368
|
+
Type2.Literal("upperLetter"),
|
|
369
|
+
Type2.Literal("lowerRoman"),
|
|
370
|
+
Type2.Literal("upperRoman")
|
|
371
|
+
])
|
|
372
|
+
),
|
|
373
|
+
separator: Type2.Optional(Type2.String())
|
|
374
|
+
},
|
|
375
|
+
{ description: "Numbering configuration for lists" }
|
|
376
|
+
);
|
|
377
|
+
var BaseComponentFields = {};
|
|
378
|
+
var BaseComponentPropsSchema = Type2.Object(BaseComponentFields, {
|
|
379
|
+
description: "Base component props",
|
|
380
|
+
additionalProperties: true
|
|
381
|
+
});
|
|
382
|
+
|
|
383
|
+
// src/schemas/components/section.ts
|
|
384
|
+
var createSectionPropsSchema = (moduleRef) => Type3.Object(
|
|
385
|
+
{
|
|
386
|
+
title: Type3.Optional(
|
|
387
|
+
Type3.String({
|
|
388
|
+
description: "Section title (optional)"
|
|
389
|
+
})
|
|
390
|
+
),
|
|
391
|
+
level: Type3.Optional(
|
|
392
|
+
Type3.Number({
|
|
393
|
+
minimum: 1,
|
|
394
|
+
maximum: 9,
|
|
395
|
+
description: "Heading level for section title (1-9)",
|
|
396
|
+
default: 1
|
|
397
|
+
})
|
|
398
|
+
),
|
|
399
|
+
header: Type3.Optional(
|
|
400
|
+
Type3.Union([
|
|
401
|
+
Type3.Array(moduleRef || Type3.Any(), {
|
|
402
|
+
description: "Section header modules"
|
|
403
|
+
}),
|
|
404
|
+
Type3.Literal("linkToPrevious", {
|
|
405
|
+
description: "Link header to previous section"
|
|
406
|
+
})
|
|
407
|
+
])
|
|
408
|
+
),
|
|
409
|
+
footer: Type3.Optional(
|
|
410
|
+
Type3.Union([
|
|
411
|
+
Type3.Array(moduleRef || Type3.Any(), {
|
|
412
|
+
description: "Section footer modules"
|
|
413
|
+
}),
|
|
414
|
+
Type3.Literal("linkToPrevious", {
|
|
415
|
+
description: "Link footer to previous section"
|
|
416
|
+
})
|
|
417
|
+
])
|
|
418
|
+
),
|
|
419
|
+
pageBreak: Type3.Optional(
|
|
420
|
+
Type3.Boolean({
|
|
421
|
+
description: "Insert page break before section",
|
|
422
|
+
default: true
|
|
423
|
+
})
|
|
424
|
+
),
|
|
425
|
+
spacing: Type3.Optional(SpacingSchema),
|
|
426
|
+
page: Type3.Optional(
|
|
427
|
+
Type3.Object(
|
|
428
|
+
{
|
|
429
|
+
size: Type3.Optional(
|
|
430
|
+
Type3.Union([
|
|
431
|
+
Type3.Literal("A4"),
|
|
432
|
+
Type3.Literal("A3"),
|
|
433
|
+
Type3.Literal("LETTER"),
|
|
434
|
+
Type3.Literal("LEGAL"),
|
|
435
|
+
Type3.Object({
|
|
436
|
+
width: Type3.Number({ minimum: 0 }),
|
|
437
|
+
height: Type3.Number({ minimum: 0 })
|
|
438
|
+
})
|
|
439
|
+
])
|
|
440
|
+
),
|
|
441
|
+
margins: Type3.Optional(
|
|
442
|
+
Type3.Object(
|
|
443
|
+
{
|
|
444
|
+
top: Type3.Optional(Type3.Number({ minimum: 0 })),
|
|
445
|
+
bottom: Type3.Optional(Type3.Number({ minimum: 0 })),
|
|
446
|
+
left: Type3.Optional(Type3.Number({ minimum: 0 })),
|
|
447
|
+
right: Type3.Optional(Type3.Number({ minimum: 0 })),
|
|
448
|
+
header: Type3.Optional(Type3.Number({ minimum: 0 })),
|
|
449
|
+
footer: Type3.Optional(Type3.Number({ minimum: 0 })),
|
|
450
|
+
gutter: Type3.Optional(Type3.Number({ minimum: 0 }))
|
|
451
|
+
},
|
|
452
|
+
{
|
|
453
|
+
additionalProperties: false
|
|
454
|
+
}
|
|
455
|
+
)
|
|
456
|
+
)
|
|
457
|
+
},
|
|
458
|
+
{
|
|
459
|
+
description: "Page configuration override for this section (overrides theme page settings)",
|
|
460
|
+
additionalProperties: false
|
|
461
|
+
}
|
|
462
|
+
)
|
|
463
|
+
)
|
|
464
|
+
},
|
|
465
|
+
{
|
|
466
|
+
description: "Section component props",
|
|
467
|
+
additionalProperties: false
|
|
468
|
+
}
|
|
469
|
+
);
|
|
470
|
+
var SectionPropsSchema = createSectionPropsSchema();
|
|
471
|
+
|
|
472
|
+
// src/schemas/components/columns.ts
|
|
473
|
+
import { Type as Type4 } from "@sinclair/typebox";
|
|
474
|
+
var ColumnDescriptorSchema = Type4.Object(
|
|
475
|
+
{
|
|
476
|
+
width: Type4.Optional(
|
|
477
|
+
Type4.Union([
|
|
478
|
+
Type4.Number({
|
|
479
|
+
minimum: 1,
|
|
480
|
+
description: "Column width in points"
|
|
481
|
+
}),
|
|
482
|
+
Type4.String({
|
|
483
|
+
pattern: "^\\d+(\\.\\d+)?%$",
|
|
484
|
+
description: 'Column width as percentage of available width (e.g., "30%")'
|
|
485
|
+
}),
|
|
486
|
+
Type4.Literal("auto", {
|
|
487
|
+
description: "Auto width: consume remaining space after fixed widths and gaps"
|
|
488
|
+
})
|
|
489
|
+
])
|
|
490
|
+
),
|
|
491
|
+
gap: Type4.Optional(
|
|
492
|
+
Type4.Union([
|
|
493
|
+
Type4.Number({
|
|
494
|
+
minimum: 0,
|
|
495
|
+
description: "Gap after this column in points"
|
|
496
|
+
}),
|
|
497
|
+
Type4.String({
|
|
498
|
+
pattern: "^\\d+(\\.\\d+)?%$",
|
|
499
|
+
description: 'Gap after this column as percentage of available width (e.g., "5%")'
|
|
500
|
+
})
|
|
501
|
+
])
|
|
502
|
+
)
|
|
503
|
+
},
|
|
504
|
+
{ additionalProperties: false }
|
|
505
|
+
);
|
|
506
|
+
var ColumnsPropsSchema = Type4.Object(
|
|
507
|
+
{
|
|
508
|
+
columns: Type4.Union([
|
|
509
|
+
Type4.Number({
|
|
510
|
+
minimum: 1,
|
|
511
|
+
description: "Number of equal-width columns (converter will normalize to array)"
|
|
512
|
+
}),
|
|
513
|
+
Type4.Array(ColumnDescriptorSchema, {
|
|
514
|
+
minItems: 1,
|
|
515
|
+
description: "List of columns in order; width and gap can be points, percentages, or auto width"
|
|
516
|
+
})
|
|
517
|
+
]),
|
|
518
|
+
gap: Type4.Optional(
|
|
519
|
+
Type4.Union([
|
|
520
|
+
Type4.Number({
|
|
521
|
+
minimum: 0,
|
|
522
|
+
description: "Default gap applied after each column except the last (points)"
|
|
523
|
+
}),
|
|
524
|
+
Type4.String({
|
|
525
|
+
pattern: "^\\d+(\\.\\d+)?%$",
|
|
526
|
+
description: 'Default gap applied after each column except the last as percentage of available width (e.g., "5%")'
|
|
527
|
+
})
|
|
528
|
+
])
|
|
529
|
+
)
|
|
530
|
+
},
|
|
531
|
+
{
|
|
532
|
+
description: "Columns component props",
|
|
533
|
+
additionalProperties: false
|
|
534
|
+
}
|
|
535
|
+
);
|
|
536
|
+
|
|
537
|
+
// src/schemas/components/heading.ts
|
|
538
|
+
import { Type as Type5 } from "@sinclair/typebox";
|
|
539
|
+
var HeadingPropsSchema = Type5.Object(
|
|
540
|
+
{
|
|
541
|
+
text: Type5.String({
|
|
542
|
+
description: "Heading text (required)"
|
|
543
|
+
}),
|
|
544
|
+
level: Type5.Optional(HeadingLevelSchema),
|
|
545
|
+
// Local font override: allows customizing family/size/color/bold/italic/underline
|
|
546
|
+
// without modifying theme styles. Supports partial overrides.
|
|
547
|
+
font: Type5.Optional(Type5.Partial(FontDefinitionSchema)),
|
|
548
|
+
alignment: Type5.Optional(JustifiedAlignmentSchema),
|
|
549
|
+
spacing: Type5.Optional(SpacingSchema),
|
|
550
|
+
lineSpacing: Type5.Optional(
|
|
551
|
+
Type5.Union([Type5.Number({ minimum: 0 }), LineSpacingSchema])
|
|
552
|
+
),
|
|
553
|
+
pageBreak: Type5.Optional(
|
|
554
|
+
Type5.Boolean({
|
|
555
|
+
description: "Insert page break before heading"
|
|
556
|
+
})
|
|
557
|
+
),
|
|
558
|
+
columnBreak: Type5.Optional(
|
|
559
|
+
Type5.Boolean({
|
|
560
|
+
description: "Insert column break before heading"
|
|
561
|
+
})
|
|
562
|
+
),
|
|
563
|
+
numbering: Type5.Optional(
|
|
564
|
+
Type5.Boolean({
|
|
565
|
+
description: "Include in numbering"
|
|
566
|
+
})
|
|
567
|
+
),
|
|
568
|
+
keepNext: Type5.Optional(
|
|
569
|
+
Type5.Boolean({
|
|
570
|
+
description: "Keep heading with next paragraph on same page"
|
|
571
|
+
})
|
|
572
|
+
),
|
|
573
|
+
keepLines: Type5.Optional(
|
|
574
|
+
Type5.Boolean({
|
|
575
|
+
description: "Keep all lines of heading together on same page"
|
|
576
|
+
})
|
|
577
|
+
)
|
|
578
|
+
},
|
|
579
|
+
{
|
|
580
|
+
description: "Heading component props",
|
|
581
|
+
additionalProperties: false
|
|
582
|
+
}
|
|
583
|
+
);
|
|
584
|
+
|
|
585
|
+
// src/schemas/components/paragraph.ts
|
|
586
|
+
import { Type as Type6 } from "@sinclair/typebox";
|
|
587
|
+
var FrameWrapTypeSchema = Type6.Union(
|
|
588
|
+
[
|
|
589
|
+
Type6.Literal("around"),
|
|
590
|
+
Type6.Literal("none"),
|
|
591
|
+
Type6.Literal("notBeside"),
|
|
592
|
+
Type6.Literal("through"),
|
|
593
|
+
Type6.Literal("tight"),
|
|
594
|
+
Type6.Literal("auto")
|
|
595
|
+
],
|
|
596
|
+
{
|
|
597
|
+
description: "Frame text wrapping type"
|
|
598
|
+
}
|
|
599
|
+
);
|
|
600
|
+
var FrameAnchorTypeSchema = Type6.Union(
|
|
601
|
+
[Type6.Literal("margin"), Type6.Literal("page"), Type6.Literal("text")],
|
|
602
|
+
{
|
|
603
|
+
description: "Frame anchor type"
|
|
604
|
+
}
|
|
605
|
+
);
|
|
606
|
+
var FrameHorizontalAlignSchema = Type6.Union(
|
|
607
|
+
[
|
|
608
|
+
Type6.Literal("left"),
|
|
609
|
+
Type6.Literal("center"),
|
|
610
|
+
Type6.Literal("right"),
|
|
611
|
+
Type6.Literal("inside"),
|
|
612
|
+
Type6.Literal("outside")
|
|
613
|
+
],
|
|
614
|
+
{
|
|
615
|
+
description: "Frame horizontal alignment"
|
|
616
|
+
}
|
|
617
|
+
);
|
|
618
|
+
var FrameVerticalAlignSchema = Type6.Union(
|
|
619
|
+
[
|
|
620
|
+
Type6.Literal("top"),
|
|
621
|
+
Type6.Literal("center"),
|
|
622
|
+
Type6.Literal("bottom"),
|
|
623
|
+
Type6.Literal("inside"),
|
|
624
|
+
Type6.Literal("outside")
|
|
625
|
+
],
|
|
626
|
+
{
|
|
627
|
+
description: "Frame vertical alignment"
|
|
628
|
+
}
|
|
629
|
+
);
|
|
630
|
+
var FloatingFramePropertiesSchema = Type6.Object(
|
|
631
|
+
{
|
|
632
|
+
horizontalPosition: Type6.Optional(
|
|
633
|
+
Type6.Object(
|
|
634
|
+
{
|
|
635
|
+
relative: Type6.Optional(FrameAnchorTypeSchema),
|
|
636
|
+
align: Type6.Optional(FrameHorizontalAlignSchema),
|
|
637
|
+
offset: Type6.Optional(
|
|
638
|
+
Type6.Number({
|
|
639
|
+
description: "Horizontal offset in twips (1/20 of a point)"
|
|
640
|
+
})
|
|
641
|
+
)
|
|
642
|
+
},
|
|
643
|
+
{
|
|
644
|
+
description: "Horizontal positioning (use either align or offset, not both)"
|
|
645
|
+
}
|
|
646
|
+
)
|
|
647
|
+
),
|
|
648
|
+
verticalPosition: Type6.Optional(
|
|
649
|
+
Type6.Object(
|
|
650
|
+
{
|
|
651
|
+
relative: Type6.Optional(FrameAnchorTypeSchema),
|
|
652
|
+
align: Type6.Optional(FrameVerticalAlignSchema),
|
|
653
|
+
offset: Type6.Optional(
|
|
654
|
+
Type6.Number({
|
|
655
|
+
description: "Vertical offset in twips (1/20 of a point)"
|
|
656
|
+
})
|
|
657
|
+
)
|
|
658
|
+
},
|
|
659
|
+
{
|
|
660
|
+
description: "Vertical positioning (use either align or offset, not both)"
|
|
661
|
+
}
|
|
662
|
+
)
|
|
663
|
+
),
|
|
664
|
+
wrap: Type6.Optional(
|
|
665
|
+
Type6.Object(
|
|
666
|
+
{
|
|
667
|
+
type: FrameWrapTypeSchema
|
|
668
|
+
},
|
|
669
|
+
{
|
|
670
|
+
description: "Text wrapping configuration"
|
|
671
|
+
}
|
|
672
|
+
)
|
|
673
|
+
),
|
|
674
|
+
lockAnchor: Type6.Optional(
|
|
675
|
+
Type6.Boolean({
|
|
676
|
+
description: "Lock the anchor position"
|
|
677
|
+
})
|
|
678
|
+
),
|
|
679
|
+
width: Type6.Optional(
|
|
680
|
+
Type6.Number({
|
|
681
|
+
minimum: 1,
|
|
682
|
+
description: "Frame width in twips (DXA units)"
|
|
683
|
+
})
|
|
684
|
+
),
|
|
685
|
+
height: Type6.Optional(
|
|
686
|
+
Type6.Number({
|
|
687
|
+
minimum: 1,
|
|
688
|
+
description: "Frame height in twips (DXA units)"
|
|
689
|
+
})
|
|
690
|
+
)
|
|
691
|
+
},
|
|
692
|
+
{
|
|
693
|
+
description: "Floating text frame properties"
|
|
694
|
+
}
|
|
695
|
+
);
|
|
696
|
+
var AlignmentSchema2 = Type6.Union(
|
|
697
|
+
[
|
|
698
|
+
Type6.Literal("left"),
|
|
699
|
+
Type6.Literal("center"),
|
|
700
|
+
Type6.Literal("right"),
|
|
701
|
+
Type6.Literal("justify")
|
|
702
|
+
],
|
|
703
|
+
{
|
|
704
|
+
description: "Paragraph text alignment"
|
|
705
|
+
}
|
|
706
|
+
);
|
|
707
|
+
var ParagraphPropsSchema = Type6.Object(
|
|
708
|
+
{
|
|
709
|
+
text: Type6.String({
|
|
710
|
+
description: "Text content (required)"
|
|
711
|
+
}),
|
|
712
|
+
// New nested font object, aligned with theme's FontDefinitionSchema
|
|
713
|
+
// Allow partial overrides (family not required when overriding a subset)
|
|
714
|
+
font: Type6.Optional(Type6.Partial(FontDefinitionSchema)),
|
|
715
|
+
// Optional reference to a named style from theme.styles (e.g., 'heading1', 'normal')
|
|
716
|
+
themeStyle: Type6.Optional(Type6.String()),
|
|
717
|
+
// Rich-text decoration color for bold segments (kept as top-level behavior option)
|
|
718
|
+
boldColor: Type6.Optional(Type6.String()),
|
|
719
|
+
// Paragraph spacing (in points) — limited paragraph-level option allowed
|
|
720
|
+
spacing: Type6.Optional(SpacingSchema),
|
|
721
|
+
// Paragraph alignment (moved from font to config level)
|
|
722
|
+
alignment: Type6.Optional(AlignmentSchema2),
|
|
723
|
+
pageBreak: Type6.Optional(
|
|
724
|
+
Type6.Boolean({
|
|
725
|
+
description: "Insert page break before paragraph"
|
|
726
|
+
})
|
|
727
|
+
),
|
|
728
|
+
columnBreak: Type6.Optional(
|
|
729
|
+
Type6.Boolean({
|
|
730
|
+
description: "Insert column break before paragraph"
|
|
731
|
+
})
|
|
732
|
+
),
|
|
733
|
+
floating: Type6.Optional(FloatingFramePropertiesSchema),
|
|
734
|
+
keepNext: Type6.Optional(
|
|
735
|
+
Type6.Boolean({
|
|
736
|
+
description: "Keep paragraph with next paragraph on same page"
|
|
737
|
+
})
|
|
738
|
+
),
|
|
739
|
+
keepLines: Type6.Optional(
|
|
740
|
+
Type6.Boolean({
|
|
741
|
+
description: "Keep all lines of paragraph together on same page"
|
|
742
|
+
})
|
|
743
|
+
),
|
|
744
|
+
id: Type6.Optional(
|
|
745
|
+
Type6.String({
|
|
746
|
+
description: "Unique identifier for internal linking (bookmark anchor)"
|
|
747
|
+
})
|
|
748
|
+
)
|
|
749
|
+
},
|
|
750
|
+
{
|
|
751
|
+
description: "Paragraph component props (font nested for theme consistency; no flat font properties)",
|
|
752
|
+
additionalProperties: false
|
|
753
|
+
}
|
|
754
|
+
);
|
|
755
|
+
|
|
756
|
+
// src/schemas/components/text-box.ts
|
|
757
|
+
import { Type as Type7 } from "@sinclair/typebox";
|
|
758
|
+
var TextBoxPropsSchema = Type7.Object(
|
|
759
|
+
{
|
|
760
|
+
width: Type7.Optional(
|
|
761
|
+
Type7.Union(
|
|
762
|
+
[
|
|
763
|
+
Type7.Number({
|
|
764
|
+
minimum: 1,
|
|
765
|
+
description: "Text box width in pixels"
|
|
766
|
+
}),
|
|
767
|
+
Type7.String({
|
|
768
|
+
pattern: "^\\d+(\\.\\d+)?%$",
|
|
769
|
+
description: 'Text box width as percentage (e.g., "50%") relative to content width'
|
|
770
|
+
})
|
|
771
|
+
],
|
|
772
|
+
{
|
|
773
|
+
description: 'Text box width in pixels (number) or as percentage string (e.g., "50%")'
|
|
774
|
+
}
|
|
775
|
+
)
|
|
776
|
+
),
|
|
777
|
+
height: Type7.Optional(
|
|
778
|
+
Type7.Union(
|
|
779
|
+
[
|
|
780
|
+
Type7.Number({
|
|
781
|
+
minimum: 1,
|
|
782
|
+
description: "Text box height in pixels"
|
|
783
|
+
}),
|
|
784
|
+
Type7.String({
|
|
785
|
+
pattern: "^\\d+(\\.\\d+)?%$",
|
|
786
|
+
description: 'Text box height as percentage (e.g., "50%") relative to content height'
|
|
787
|
+
})
|
|
788
|
+
],
|
|
789
|
+
{
|
|
790
|
+
description: 'Text box height in pixels (number) or as percentage string (e.g., "50%")'
|
|
791
|
+
}
|
|
792
|
+
)
|
|
793
|
+
),
|
|
794
|
+
floating: Type7.Optional(FloatingPropertiesSchema),
|
|
795
|
+
style: Type7.Optional(
|
|
796
|
+
Type7.Object(
|
|
797
|
+
{
|
|
798
|
+
padding: Type7.Optional(
|
|
799
|
+
Type7.Object(
|
|
800
|
+
{
|
|
801
|
+
top: Type7.Optional(Type7.Number({ minimum: 0 })),
|
|
802
|
+
right: Type7.Optional(Type7.Number({ minimum: 0 })),
|
|
803
|
+
bottom: Type7.Optional(Type7.Number({ minimum: 0 })),
|
|
804
|
+
left: Type7.Optional(Type7.Number({ minimum: 0 }))
|
|
805
|
+
},
|
|
806
|
+
{ additionalProperties: false }
|
|
807
|
+
)
|
|
808
|
+
),
|
|
809
|
+
border: Type7.Optional(
|
|
810
|
+
Type7.Object(
|
|
811
|
+
{
|
|
812
|
+
top: Type7.Optional(
|
|
813
|
+
// Reuse border schema semantics: style/width/color
|
|
814
|
+
Type7.Object({
|
|
815
|
+
style: Type7.Optional(
|
|
816
|
+
Type7.Union([
|
|
817
|
+
Type7.Literal("solid"),
|
|
818
|
+
Type7.Literal("dashed"),
|
|
819
|
+
Type7.Literal("dotted"),
|
|
820
|
+
Type7.Literal("double"),
|
|
821
|
+
Type7.Literal("none")
|
|
822
|
+
])
|
|
823
|
+
),
|
|
824
|
+
width: Type7.Optional(Type7.Number({ minimum: 0 })),
|
|
825
|
+
color: Type7.Optional(HexColorSchema)
|
|
826
|
+
})
|
|
827
|
+
),
|
|
828
|
+
right: Type7.Optional(
|
|
829
|
+
Type7.Object({
|
|
830
|
+
style: Type7.Optional(
|
|
831
|
+
Type7.Union([
|
|
832
|
+
Type7.Literal("solid"),
|
|
833
|
+
Type7.Literal("dashed"),
|
|
834
|
+
Type7.Literal("dotted"),
|
|
835
|
+
Type7.Literal("double"),
|
|
836
|
+
Type7.Literal("none")
|
|
837
|
+
])
|
|
838
|
+
),
|
|
839
|
+
width: Type7.Optional(Type7.Number({ minimum: 0 })),
|
|
840
|
+
color: Type7.Optional(HexColorSchema)
|
|
841
|
+
})
|
|
842
|
+
),
|
|
843
|
+
bottom: Type7.Optional(
|
|
844
|
+
Type7.Object({
|
|
845
|
+
style: Type7.Optional(
|
|
846
|
+
Type7.Union([
|
|
847
|
+
Type7.Literal("solid"),
|
|
848
|
+
Type7.Literal("dashed"),
|
|
849
|
+
Type7.Literal("dotted"),
|
|
850
|
+
Type7.Literal("double"),
|
|
851
|
+
Type7.Literal("none")
|
|
852
|
+
])
|
|
853
|
+
),
|
|
854
|
+
width: Type7.Optional(Type7.Number({ minimum: 0 })),
|
|
855
|
+
color: Type7.Optional(HexColorSchema)
|
|
856
|
+
})
|
|
857
|
+
),
|
|
858
|
+
left: Type7.Optional(
|
|
859
|
+
Type7.Object({
|
|
860
|
+
style: Type7.Optional(
|
|
861
|
+
Type7.Union([
|
|
862
|
+
Type7.Literal("solid"),
|
|
863
|
+
Type7.Literal("dashed"),
|
|
864
|
+
Type7.Literal("dotted"),
|
|
865
|
+
Type7.Literal("double"),
|
|
866
|
+
Type7.Literal("none")
|
|
867
|
+
])
|
|
868
|
+
),
|
|
869
|
+
width: Type7.Optional(Type7.Number({ minimum: 0 })),
|
|
870
|
+
color: Type7.Optional(HexColorSchema)
|
|
871
|
+
})
|
|
872
|
+
)
|
|
873
|
+
},
|
|
874
|
+
{ additionalProperties: false }
|
|
875
|
+
)
|
|
876
|
+
),
|
|
877
|
+
shading: Type7.Optional(
|
|
878
|
+
Type7.Object(
|
|
879
|
+
{
|
|
880
|
+
fill: Type7.Optional(Type7.String())
|
|
881
|
+
},
|
|
882
|
+
{ additionalProperties: false }
|
|
883
|
+
)
|
|
884
|
+
)
|
|
885
|
+
},
|
|
886
|
+
{ additionalProperties: false }
|
|
887
|
+
)
|
|
888
|
+
)
|
|
889
|
+
},
|
|
890
|
+
{ additionalProperties: false }
|
|
891
|
+
);
|
|
892
|
+
|
|
893
|
+
// src/schemas/components/image.ts
|
|
894
|
+
import { Type as Type8 } from "@sinclair/typebox";
|
|
895
|
+
var ImagePropsSchema = Type8.Object(
|
|
896
|
+
{
|
|
897
|
+
path: Type8.Optional(
|
|
898
|
+
Type8.String({
|
|
899
|
+
description: "Image source URL or file path (mutually exclusive with base64)"
|
|
900
|
+
})
|
|
901
|
+
),
|
|
902
|
+
base64: Type8.Optional(
|
|
903
|
+
Type8.String({
|
|
904
|
+
description: 'Base64-encoded image data in data URI format (e.g., "data:image/png;base64,iVBORw0KGgo...") (mutually exclusive with path)'
|
|
905
|
+
})
|
|
906
|
+
),
|
|
907
|
+
alt: Type8.Optional(
|
|
908
|
+
Type8.String({
|
|
909
|
+
description: "Alternative text for accessibility"
|
|
910
|
+
})
|
|
911
|
+
),
|
|
912
|
+
width: Type8.Optional(
|
|
913
|
+
Type8.Union(
|
|
914
|
+
[
|
|
915
|
+
Type8.Number({
|
|
916
|
+
minimum: 1,
|
|
917
|
+
description: "Image width in pixels"
|
|
918
|
+
}),
|
|
919
|
+
Type8.String({
|
|
920
|
+
pattern: "^\\d+(\\.\\d+)?%$",
|
|
921
|
+
description: 'Image width as percentage (e.g., "90%") relative to widthRelativeTo (defaults to content width)'
|
|
922
|
+
})
|
|
923
|
+
],
|
|
924
|
+
{
|
|
925
|
+
description: 'Image width in pixels (number) or as percentage string (e.g., "90%")',
|
|
926
|
+
default: "100%"
|
|
927
|
+
}
|
|
928
|
+
)
|
|
929
|
+
),
|
|
930
|
+
height: Type8.Optional(
|
|
931
|
+
Type8.Union(
|
|
932
|
+
[
|
|
933
|
+
Type8.Number({
|
|
934
|
+
minimum: 1,
|
|
935
|
+
description: "Image height in pixels"
|
|
936
|
+
}),
|
|
937
|
+
Type8.String({
|
|
938
|
+
pattern: "^\\d+(\\.\\d+)?%$",
|
|
939
|
+
description: 'Image height as percentage (e.g., "90%") relative to heightRelativeTo (defaults to content height)'
|
|
940
|
+
})
|
|
941
|
+
],
|
|
942
|
+
{
|
|
943
|
+
description: 'Image height in pixels (number) or as percentage string (e.g., "90%")'
|
|
944
|
+
}
|
|
945
|
+
)
|
|
946
|
+
),
|
|
947
|
+
widthRelativeTo: Type8.Optional(
|
|
948
|
+
Type8.Union([Type8.Literal("content"), Type8.Literal("page")], {
|
|
949
|
+
description: "Reference for width percentages: content (page width minus margins) or page (full page width)",
|
|
950
|
+
default: "content"
|
|
951
|
+
})
|
|
952
|
+
),
|
|
953
|
+
heightRelativeTo: Type8.Optional(
|
|
954
|
+
Type8.Union([Type8.Literal("content"), Type8.Literal("page")], {
|
|
955
|
+
description: "Reference for height percentages: content (page height minus margins) or page (full page height)",
|
|
956
|
+
default: "content"
|
|
957
|
+
})
|
|
958
|
+
),
|
|
959
|
+
alignment: Type8.Optional(AlignmentSchema),
|
|
960
|
+
caption: Type8.Optional(
|
|
961
|
+
Type8.String({
|
|
962
|
+
description: "Image caption (supports rich text with **bold**, *italic*, ***both***)"
|
|
963
|
+
})
|
|
964
|
+
),
|
|
965
|
+
spacing: Type8.Optional(SpacingSchema),
|
|
966
|
+
floating: Type8.Optional(FloatingPropertiesSchema),
|
|
967
|
+
keepNext: Type8.Optional(
|
|
968
|
+
Type8.Boolean({
|
|
969
|
+
description: "Keep paragraph with next paragraph on same page"
|
|
970
|
+
})
|
|
971
|
+
),
|
|
972
|
+
keepLines: Type8.Optional(
|
|
973
|
+
Type8.Boolean({
|
|
974
|
+
description: "Keep all lines of paragraph together on same page"
|
|
975
|
+
})
|
|
976
|
+
)
|
|
977
|
+
},
|
|
978
|
+
{
|
|
979
|
+
description: "Image component props",
|
|
980
|
+
additionalProperties: false
|
|
981
|
+
}
|
|
982
|
+
);
|
|
983
|
+
|
|
984
|
+
// src/schemas/components/statistic.ts
|
|
985
|
+
import { Type as Type9 } from "@sinclair/typebox";
|
|
986
|
+
var StatisticPropsSchema = Type9.Object(
|
|
987
|
+
{
|
|
988
|
+
number: Type9.String({
|
|
989
|
+
description: "Statistic number/value (required)"
|
|
990
|
+
}),
|
|
991
|
+
description: Type9.String({
|
|
992
|
+
description: "Statistic description (required)"
|
|
993
|
+
}),
|
|
994
|
+
unit: Type9.Optional(
|
|
995
|
+
Type9.String({
|
|
996
|
+
description: "Unit of measurement"
|
|
997
|
+
})
|
|
998
|
+
),
|
|
999
|
+
format: Type9.Optional(
|
|
1000
|
+
Type9.String({
|
|
1001
|
+
description: "Number format pattern"
|
|
1002
|
+
})
|
|
1003
|
+
),
|
|
1004
|
+
trend: Type9.Optional(
|
|
1005
|
+
Type9.Union([
|
|
1006
|
+
Type9.Literal("up"),
|
|
1007
|
+
Type9.Literal("down"),
|
|
1008
|
+
Type9.Literal("neutral")
|
|
1009
|
+
])
|
|
1010
|
+
),
|
|
1011
|
+
trendValue: Type9.Optional(Type9.Union([Type9.String(), Type9.Number()])),
|
|
1012
|
+
alignment: Type9.Optional(AlignmentSchema),
|
|
1013
|
+
spacing: Type9.Optional(SpacingSchema),
|
|
1014
|
+
size: Type9.Optional(
|
|
1015
|
+
Type9.Union([
|
|
1016
|
+
Type9.Literal("small"),
|
|
1017
|
+
Type9.Literal("medium"),
|
|
1018
|
+
Type9.Literal("large")
|
|
1019
|
+
])
|
|
1020
|
+
)
|
|
1021
|
+
},
|
|
1022
|
+
{
|
|
1023
|
+
description: "Statistic component props",
|
|
1024
|
+
additionalProperties: false
|
|
1025
|
+
}
|
|
1026
|
+
);
|
|
1027
|
+
|
|
1028
|
+
// src/schemas/components/table.ts
|
|
1029
|
+
import { Type as Type10 } from "@sinclair/typebox";
|
|
1030
|
+
var CellContentSchema = Type10.Recursive(
|
|
1031
|
+
(This) => Type10.Union([
|
|
1032
|
+
Type10.String(),
|
|
1033
|
+
Type10.Object(
|
|
1034
|
+
{
|
|
1035
|
+
name: Type10.String(),
|
|
1036
|
+
props: Type10.Object({}, { additionalProperties: true }),
|
|
1037
|
+
children: Type10.Optional(Type10.Array(This))
|
|
1038
|
+
},
|
|
1039
|
+
{ additionalProperties: false }
|
|
1040
|
+
)
|
|
1041
|
+
])
|
|
1042
|
+
);
|
|
1043
|
+
var HorizontalAlignmentSchema = Type10.Union(
|
|
1044
|
+
[
|
|
1045
|
+
Type10.Literal("left"),
|
|
1046
|
+
Type10.Literal("center"),
|
|
1047
|
+
Type10.Literal("right"),
|
|
1048
|
+
Type10.Literal("justify")
|
|
1049
|
+
],
|
|
1050
|
+
{ description: "Horizontal text alignment" }
|
|
1051
|
+
);
|
|
1052
|
+
var VerticalAlignmentSchema = Type10.Union(
|
|
1053
|
+
[Type10.Literal("top"), Type10.Literal("middle"), Type10.Literal("bottom")],
|
|
1054
|
+
{ description: "Vertical cell alignment" }
|
|
1055
|
+
);
|
|
1056
|
+
var FontConfigSchema = Type10.Object({
|
|
1057
|
+
family: Type10.Optional(Type10.String({ description: "Font family name" })),
|
|
1058
|
+
size: Type10.Optional(
|
|
1059
|
+
Type10.Number({ minimum: 0, description: "Font size in points" })
|
|
1060
|
+
),
|
|
1061
|
+
bold: Type10.Optional(Type10.Boolean({ description: "Bold text" })),
|
|
1062
|
+
italic: Type10.Optional(Type10.Boolean({ description: "Italic text" })),
|
|
1063
|
+
underline: Type10.Optional(Type10.Boolean({ description: "Underlined text" }))
|
|
1064
|
+
});
|
|
1065
|
+
var BorderColorSchema = Type10.Union([
|
|
1066
|
+
Type10.String({ description: "Border color for all sides (hex without #)" }),
|
|
1067
|
+
Type10.Object({
|
|
1068
|
+
bottom: Type10.Optional(
|
|
1069
|
+
Type10.String({ description: "Bottom border color (hex without #)" })
|
|
1070
|
+
),
|
|
1071
|
+
top: Type10.Optional(
|
|
1072
|
+
Type10.String({ description: "Top border color (hex without #)" })
|
|
1073
|
+
),
|
|
1074
|
+
right: Type10.Optional(
|
|
1075
|
+
Type10.String({ description: "Right border color (hex without #)" })
|
|
1076
|
+
),
|
|
1077
|
+
left: Type10.Optional(
|
|
1078
|
+
Type10.String({ description: "Left border color (hex without #)" })
|
|
1079
|
+
)
|
|
1080
|
+
})
|
|
1081
|
+
]);
|
|
1082
|
+
var BorderSizeSchema = Type10.Union([
|
|
1083
|
+
Type10.Number({
|
|
1084
|
+
minimum: 0,
|
|
1085
|
+
description: "Border size for all sides in points"
|
|
1086
|
+
}),
|
|
1087
|
+
Type10.Object({
|
|
1088
|
+
bottom: Type10.Optional(
|
|
1089
|
+
Type10.Number({ minimum: 0, description: "Bottom border size in points" })
|
|
1090
|
+
),
|
|
1091
|
+
top: Type10.Optional(
|
|
1092
|
+
Type10.Number({ minimum: 0, description: "Top border size in points" })
|
|
1093
|
+
),
|
|
1094
|
+
right: Type10.Optional(
|
|
1095
|
+
Type10.Number({ minimum: 0, description: "Right border size in points" })
|
|
1096
|
+
),
|
|
1097
|
+
left: Type10.Optional(
|
|
1098
|
+
Type10.Number({ minimum: 0, description: "Left border size in points" })
|
|
1099
|
+
)
|
|
1100
|
+
})
|
|
1101
|
+
]);
|
|
1102
|
+
var HideBordersSchema = Type10.Union([
|
|
1103
|
+
Type10.Boolean({
|
|
1104
|
+
description: "Hide all borders when true"
|
|
1105
|
+
}),
|
|
1106
|
+
Type10.Object(
|
|
1107
|
+
{
|
|
1108
|
+
bottom: Type10.Optional(
|
|
1109
|
+
Type10.Boolean({ description: "Hide bottom border" })
|
|
1110
|
+
),
|
|
1111
|
+
top: Type10.Optional(Type10.Boolean({ description: "Hide top border" })),
|
|
1112
|
+
right: Type10.Optional(Type10.Boolean({ description: "Hide right border" })),
|
|
1113
|
+
left: Type10.Optional(Type10.Boolean({ description: "Hide left border" })),
|
|
1114
|
+
insideHorizontal: Type10.Optional(
|
|
1115
|
+
Type10.Boolean({ description: "Hide horizontal borders between rows" })
|
|
1116
|
+
),
|
|
1117
|
+
insideVertical: Type10.Optional(
|
|
1118
|
+
Type10.Boolean({ description: "Hide vertical borders between columns" })
|
|
1119
|
+
)
|
|
1120
|
+
},
|
|
1121
|
+
{ description: "Selectively hide specific borders" }
|
|
1122
|
+
)
|
|
1123
|
+
]);
|
|
1124
|
+
var PaddingSchema = Type10.Union([
|
|
1125
|
+
Type10.Number({ minimum: 0, description: "Padding for all sides in points" }),
|
|
1126
|
+
Type10.Object({
|
|
1127
|
+
bottom: Type10.Optional(
|
|
1128
|
+
Type10.Number({ minimum: 0, description: "Bottom padding in points" })
|
|
1129
|
+
),
|
|
1130
|
+
top: Type10.Optional(
|
|
1131
|
+
Type10.Number({ minimum: 0, description: "Top padding in points" })
|
|
1132
|
+
),
|
|
1133
|
+
right: Type10.Optional(
|
|
1134
|
+
Type10.Number({ minimum: 0, description: "Right padding in points" })
|
|
1135
|
+
),
|
|
1136
|
+
left: Type10.Optional(
|
|
1137
|
+
Type10.Number({ minimum: 0, description: "Left padding in points" })
|
|
1138
|
+
)
|
|
1139
|
+
})
|
|
1140
|
+
]);
|
|
1141
|
+
var CellDefaultsSchema = Type10.Object({
|
|
1142
|
+
color: Type10.Optional(HexColorSchema),
|
|
1143
|
+
backgroundColor: Type10.Optional(HexColorSchema),
|
|
1144
|
+
horizontalAlignment: Type10.Optional(HorizontalAlignmentSchema),
|
|
1145
|
+
verticalAlignment: Type10.Optional(VerticalAlignmentSchema),
|
|
1146
|
+
font: Type10.Optional(FontConfigSchema),
|
|
1147
|
+
borderColor: Type10.Optional(BorderColorSchema),
|
|
1148
|
+
borderSize: Type10.Optional(BorderSizeSchema),
|
|
1149
|
+
padding: Type10.Optional(PaddingSchema),
|
|
1150
|
+
height: Type10.Optional(
|
|
1151
|
+
Type10.Number({ minimum: 0, description: "Cell height in points" })
|
|
1152
|
+
)
|
|
1153
|
+
});
|
|
1154
|
+
var HeaderSchema = Type10.Object({
|
|
1155
|
+
color: Type10.Optional(HexColorSchema),
|
|
1156
|
+
backgroundColor: Type10.Optional(HexColorSchema),
|
|
1157
|
+
horizontalAlignment: Type10.Optional(HorizontalAlignmentSchema),
|
|
1158
|
+
verticalAlignment: Type10.Optional(VerticalAlignmentSchema),
|
|
1159
|
+
font: Type10.Optional(FontConfigSchema),
|
|
1160
|
+
borderColor: Type10.Optional(BorderColorSchema),
|
|
1161
|
+
borderSize: Type10.Optional(BorderSizeSchema),
|
|
1162
|
+
padding: Type10.Optional(PaddingSchema),
|
|
1163
|
+
height: Type10.Optional(
|
|
1164
|
+
Type10.Number({ minimum: 0, description: "Cell height in points" })
|
|
1165
|
+
),
|
|
1166
|
+
content: Type10.Optional(CellContentSchema)
|
|
1167
|
+
});
|
|
1168
|
+
var CellSchema = Type10.Object({
|
|
1169
|
+
color: Type10.Optional(HexColorSchema),
|
|
1170
|
+
backgroundColor: Type10.Optional(HexColorSchema),
|
|
1171
|
+
horizontalAlignment: Type10.Optional(HorizontalAlignmentSchema),
|
|
1172
|
+
verticalAlignment: Type10.Optional(VerticalAlignmentSchema),
|
|
1173
|
+
font: Type10.Optional(FontConfigSchema),
|
|
1174
|
+
borderColor: Type10.Optional(BorderColorSchema),
|
|
1175
|
+
borderSize: Type10.Optional(BorderSizeSchema),
|
|
1176
|
+
padding: Type10.Optional(PaddingSchema),
|
|
1177
|
+
height: Type10.Optional(
|
|
1178
|
+
Type10.Number({ minimum: 0, description: "Cell height in points" })
|
|
1179
|
+
),
|
|
1180
|
+
content: Type10.Optional(CellContentSchema)
|
|
1181
|
+
});
|
|
1182
|
+
var ColumnSchema = Type10.Object({
|
|
1183
|
+
width: Type10.Optional(
|
|
1184
|
+
Type10.Number({
|
|
1185
|
+
minimum: 0,
|
|
1186
|
+
description: "Column width in points. When set on some columns, remaining columns will automatically share the leftover table space equally. Leave undefined to distribute space evenly among unspecified columns."
|
|
1187
|
+
})
|
|
1188
|
+
),
|
|
1189
|
+
cellDefaults: Type10.Optional(CellDefaultsSchema),
|
|
1190
|
+
header: Type10.Optional(HeaderSchema),
|
|
1191
|
+
cells: Type10.Optional(Type10.Array(CellSchema))
|
|
1192
|
+
});
|
|
1193
|
+
var TablePropsSchema = Type10.Object(
|
|
1194
|
+
{
|
|
1195
|
+
borderColor: Type10.Optional(BorderColorSchema),
|
|
1196
|
+
borderSize: Type10.Optional(BorderSizeSchema),
|
|
1197
|
+
hideBorders: Type10.Optional(HideBordersSchema),
|
|
1198
|
+
cellDefaults: Type10.Optional(CellDefaultsSchema),
|
|
1199
|
+
headerCellDefaults: Type10.Optional(CellDefaultsSchema),
|
|
1200
|
+
width: Type10.Optional(
|
|
1201
|
+
Type10.Number({
|
|
1202
|
+
minimum: 0,
|
|
1203
|
+
maximum: 100,
|
|
1204
|
+
description: "Table width in percentage (0-100)"
|
|
1205
|
+
})
|
|
1206
|
+
),
|
|
1207
|
+
columns: Type10.Array(ColumnSchema, {
|
|
1208
|
+
description: "Table columns with headers and cells",
|
|
1209
|
+
minItems: 1
|
|
1210
|
+
}),
|
|
1211
|
+
keepInOnePage: Type10.Optional(
|
|
1212
|
+
Type10.Boolean({
|
|
1213
|
+
description: "Keep table rows together on the same page by setting keepNext on all paragraphs"
|
|
1214
|
+
})
|
|
1215
|
+
),
|
|
1216
|
+
keepNext: Type10.Optional(
|
|
1217
|
+
Type10.Boolean({
|
|
1218
|
+
description: "Set keepNext on the last row to keep it connected to the next element. Works independently of keepInOnePage. Defaults to false."
|
|
1219
|
+
})
|
|
1220
|
+
),
|
|
1221
|
+
repeatHeaderOnPageBreak: Type10.Optional(
|
|
1222
|
+
Type10.Boolean({
|
|
1223
|
+
description: "Repeat the header row on each page when the table spans multiple pages. Defaults to false.",
|
|
1224
|
+
default: true
|
|
1225
|
+
})
|
|
1226
|
+
)
|
|
1227
|
+
},
|
|
1228
|
+
{
|
|
1229
|
+
description: "Table component props with column-based structure"
|
|
1230
|
+
}
|
|
1231
|
+
);
|
|
1232
|
+
|
|
1233
|
+
// src/schemas/components/header.ts
|
|
1234
|
+
import { Type as Type11 } from "@sinclair/typebox";
|
|
1235
|
+
var HeaderPropsSchema = Type11.Object(
|
|
1236
|
+
{
|
|
1237
|
+
text: Type11.Optional(
|
|
1238
|
+
Type11.String({
|
|
1239
|
+
description: "Header text"
|
|
1240
|
+
})
|
|
1241
|
+
),
|
|
1242
|
+
logo: Type11.Optional(
|
|
1243
|
+
Type11.String({
|
|
1244
|
+
description: "Logo image URL or path"
|
|
1245
|
+
})
|
|
1246
|
+
),
|
|
1247
|
+
alignment: Type11.Optional(AlignmentSchema),
|
|
1248
|
+
position: Type11.Optional(
|
|
1249
|
+
Type11.Union([Type11.Literal("top"), Type11.Literal("bottom")])
|
|
1250
|
+
),
|
|
1251
|
+
firstPage: Type11.Optional(
|
|
1252
|
+
Type11.Boolean({
|
|
1253
|
+
description: "Show header on first page"
|
|
1254
|
+
})
|
|
1255
|
+
),
|
|
1256
|
+
oddPages: Type11.Optional(
|
|
1257
|
+
Type11.Boolean({
|
|
1258
|
+
description: "Show header on odd pages"
|
|
1259
|
+
})
|
|
1260
|
+
),
|
|
1261
|
+
evenPages: Type11.Optional(
|
|
1262
|
+
Type11.Boolean({
|
|
1263
|
+
description: "Show header on even pages"
|
|
1264
|
+
})
|
|
1265
|
+
),
|
|
1266
|
+
showPageNumbers: Type11.Optional(Type11.Boolean()),
|
|
1267
|
+
showDate: Type11.Optional(Type11.Boolean()),
|
|
1268
|
+
height: Type11.Optional(Type11.Number({ minimum: 0 }))
|
|
1269
|
+
},
|
|
1270
|
+
{
|
|
1271
|
+
description: "Document header configuration",
|
|
1272
|
+
additionalProperties: false
|
|
1273
|
+
}
|
|
1274
|
+
);
|
|
1275
|
+
|
|
1276
|
+
// src/schemas/components/footer.ts
|
|
1277
|
+
import { Type as Type12 } from "@sinclair/typebox";
|
|
1278
|
+
var FooterPropsSchema = Type12.Object(
|
|
1279
|
+
{
|
|
1280
|
+
text: Type12.Optional(
|
|
1281
|
+
Type12.String({
|
|
1282
|
+
description: "Footer text"
|
|
1283
|
+
})
|
|
1284
|
+
),
|
|
1285
|
+
alignment: Type12.Optional(AlignmentSchema),
|
|
1286
|
+
position: Type12.Optional(
|
|
1287
|
+
Type12.Union([Type12.Literal("top"), Type12.Literal("bottom")])
|
|
1288
|
+
),
|
|
1289
|
+
firstPage: Type12.Optional(
|
|
1290
|
+
Type12.Boolean({
|
|
1291
|
+
description: "Show footer on first page"
|
|
1292
|
+
})
|
|
1293
|
+
),
|
|
1294
|
+
oddPages: Type12.Optional(
|
|
1295
|
+
Type12.Boolean({
|
|
1296
|
+
description: "Show footer on odd pages"
|
|
1297
|
+
})
|
|
1298
|
+
),
|
|
1299
|
+
evenPages: Type12.Optional(
|
|
1300
|
+
Type12.Boolean({
|
|
1301
|
+
description: "Show footer on even pages"
|
|
1302
|
+
})
|
|
1303
|
+
),
|
|
1304
|
+
showPageNumbers: Type12.Optional(Type12.Boolean()),
|
|
1305
|
+
showDate: Type12.Optional(Type12.Boolean()),
|
|
1306
|
+
height: Type12.Optional(Type12.Number({ minimum: 0 }))
|
|
1307
|
+
},
|
|
1308
|
+
{
|
|
1309
|
+
description: "Document footer configuration",
|
|
1310
|
+
additionalProperties: false
|
|
1311
|
+
}
|
|
1312
|
+
);
|
|
1313
|
+
|
|
1314
|
+
// src/schemas/components/list.ts
|
|
1315
|
+
import { Type as Type13 } from "@sinclair/typebox";
|
|
1316
|
+
var LevelFormatSchema = Type13.Union(
|
|
1317
|
+
[
|
|
1318
|
+
Type13.Literal("decimal"),
|
|
1319
|
+
Type13.Literal("upperRoman"),
|
|
1320
|
+
Type13.Literal("lowerRoman"),
|
|
1321
|
+
Type13.Literal("upperLetter"),
|
|
1322
|
+
Type13.Literal("lowerLetter"),
|
|
1323
|
+
Type13.Literal("bullet"),
|
|
1324
|
+
Type13.Literal("ordinal"),
|
|
1325
|
+
Type13.Literal("cardinalText"),
|
|
1326
|
+
Type13.Literal("ordinalText"),
|
|
1327
|
+
Type13.Literal("hex"),
|
|
1328
|
+
Type13.Literal("chicago"),
|
|
1329
|
+
Type13.Literal("ideographDigital"),
|
|
1330
|
+
Type13.Literal("japaneseCounting"),
|
|
1331
|
+
Type13.Literal("aiueo"),
|
|
1332
|
+
Type13.Literal("iroha"),
|
|
1333
|
+
Type13.Literal("decimalFullWidth"),
|
|
1334
|
+
Type13.Literal("decimalHalfWidth"),
|
|
1335
|
+
Type13.Literal("japaneseLegal"),
|
|
1336
|
+
Type13.Literal("japaneseDigitalTenThousand"),
|
|
1337
|
+
Type13.Literal("decimalEnclosedCircle"),
|
|
1338
|
+
Type13.Literal("decimalFullWidth2"),
|
|
1339
|
+
Type13.Literal("aiueoFullWidth"),
|
|
1340
|
+
Type13.Literal("irohaFullWidth"),
|
|
1341
|
+
Type13.Literal("decimalZero"),
|
|
1342
|
+
Type13.Literal("ganada"),
|
|
1343
|
+
Type13.Literal("chosung"),
|
|
1344
|
+
Type13.Literal("decimalEnclosedFullstop"),
|
|
1345
|
+
Type13.Literal("decimalEnclosedParen"),
|
|
1346
|
+
Type13.Literal("decimalEnclosedCircleChinese"),
|
|
1347
|
+
Type13.Literal("ideographEnclosedCircle"),
|
|
1348
|
+
Type13.Literal("ideographTraditional"),
|
|
1349
|
+
Type13.Literal("ideographZodiac"),
|
|
1350
|
+
Type13.Literal("ideographZodiacTraditional"),
|
|
1351
|
+
Type13.Literal("taiwaneseCounting"),
|
|
1352
|
+
Type13.Literal("ideographLegalTraditional"),
|
|
1353
|
+
Type13.Literal("taiwaneseCountingThousand"),
|
|
1354
|
+
Type13.Literal("taiwaneseDigital"),
|
|
1355
|
+
Type13.Literal("chineseCounting"),
|
|
1356
|
+
Type13.Literal("chineseLegalSimplified"),
|
|
1357
|
+
Type13.Literal("chineseCountingThousand"),
|
|
1358
|
+
Type13.Literal("koreanDigital"),
|
|
1359
|
+
Type13.Literal("koreanCounting"),
|
|
1360
|
+
Type13.Literal("koreanLegal"),
|
|
1361
|
+
Type13.Literal("koreanDigital2"),
|
|
1362
|
+
Type13.Literal("vietnameseCounting"),
|
|
1363
|
+
Type13.Literal("russianLower"),
|
|
1364
|
+
Type13.Literal("russianUpper"),
|
|
1365
|
+
Type13.Literal("none"),
|
|
1366
|
+
Type13.Literal("numberInDash"),
|
|
1367
|
+
Type13.Literal("hebrew1"),
|
|
1368
|
+
Type13.Literal("hebrew2"),
|
|
1369
|
+
Type13.Literal("arabicAlpha"),
|
|
1370
|
+
Type13.Literal("arabicAbjad"),
|
|
1371
|
+
Type13.Literal("hindiVowels"),
|
|
1372
|
+
Type13.Literal("hindiConsonants"),
|
|
1373
|
+
Type13.Literal("hindiNumbers"),
|
|
1374
|
+
Type13.Literal("hindiCounting"),
|
|
1375
|
+
Type13.Literal("thaiLetters"),
|
|
1376
|
+
Type13.Literal("thaiNumbers"),
|
|
1377
|
+
Type13.Literal("thaiCounting")
|
|
1378
|
+
],
|
|
1379
|
+
{
|
|
1380
|
+
description: "Number or bullet format for list levels"
|
|
1381
|
+
}
|
|
1382
|
+
);
|
|
1383
|
+
var ListLevelPropsSchema = Type13.Object(
|
|
1384
|
+
{
|
|
1385
|
+
level: Type13.Number({
|
|
1386
|
+
minimum: 0,
|
|
1387
|
+
maximum: 8,
|
|
1388
|
+
description: "Nesting level (0 = root, 1 = first sublevel, etc.)"
|
|
1389
|
+
}),
|
|
1390
|
+
format: Type13.Optional(LevelFormatSchema),
|
|
1391
|
+
text: Type13.Optional(
|
|
1392
|
+
Type13.String({
|
|
1393
|
+
description: 'Number format string (e.g., "%1." for "1.", "%1)" for "1)", custom bullet character for bullet format)'
|
|
1394
|
+
})
|
|
1395
|
+
),
|
|
1396
|
+
alignment: Type13.Optional(
|
|
1397
|
+
Type13.Union(
|
|
1398
|
+
[
|
|
1399
|
+
Type13.Literal("start"),
|
|
1400
|
+
Type13.Literal("end"),
|
|
1401
|
+
Type13.Literal("left"),
|
|
1402
|
+
Type13.Literal("right"),
|
|
1403
|
+
Type13.Literal("center")
|
|
1404
|
+
],
|
|
1405
|
+
{
|
|
1406
|
+
description: "Alignment of the numbering/bullet"
|
|
1407
|
+
}
|
|
1408
|
+
)
|
|
1409
|
+
),
|
|
1410
|
+
indent: Type13.Optional(IndentSchema),
|
|
1411
|
+
start: Type13.Optional(
|
|
1412
|
+
Type13.Number({
|
|
1413
|
+
minimum: 1,
|
|
1414
|
+
description: "Starting number for this level (default: 1)"
|
|
1415
|
+
})
|
|
1416
|
+
)
|
|
1417
|
+
},
|
|
1418
|
+
{
|
|
1419
|
+
description: "Configuration for a single list level"
|
|
1420
|
+
}
|
|
1421
|
+
);
|
|
1422
|
+
var ListPropsSchema = Type13.Object(
|
|
1423
|
+
{
|
|
1424
|
+
items: Type13.Array(
|
|
1425
|
+
Type13.Union([
|
|
1426
|
+
Type13.String(),
|
|
1427
|
+
Type13.Object({
|
|
1428
|
+
text: Type13.String(),
|
|
1429
|
+
level: Type13.Optional(
|
|
1430
|
+
Type13.Number({
|
|
1431
|
+
minimum: 0,
|
|
1432
|
+
maximum: 8,
|
|
1433
|
+
description: "Nesting level for this item"
|
|
1434
|
+
})
|
|
1435
|
+
)
|
|
1436
|
+
})
|
|
1437
|
+
]),
|
|
1438
|
+
{
|
|
1439
|
+
description: "List items (required)",
|
|
1440
|
+
minItems: 1
|
|
1441
|
+
}
|
|
1442
|
+
),
|
|
1443
|
+
reference: Type13.Optional(
|
|
1444
|
+
Type13.String({
|
|
1445
|
+
description: "Unique reference ID for this numbering configuration (auto-generated if not provided)"
|
|
1446
|
+
})
|
|
1447
|
+
),
|
|
1448
|
+
levels: Type13.Optional(
|
|
1449
|
+
Type13.Array(ListLevelPropsSchema, {
|
|
1450
|
+
description: "Configuration for each nesting level",
|
|
1451
|
+
minItems: 1,
|
|
1452
|
+
maxItems: 9
|
|
1453
|
+
})
|
|
1454
|
+
),
|
|
1455
|
+
// Simplified options for common use cases (when levels not specified)
|
|
1456
|
+
format: Type13.Optional(
|
|
1457
|
+
Type13.Union(
|
|
1458
|
+
[LevelFormatSchema, Type13.Literal("numbered"), Type13.Literal("none")],
|
|
1459
|
+
{
|
|
1460
|
+
description: "Format for level 0 (simplified option when levels not specified)"
|
|
1461
|
+
}
|
|
1462
|
+
)
|
|
1463
|
+
),
|
|
1464
|
+
bullet: Type13.Optional(
|
|
1465
|
+
Type13.String({
|
|
1466
|
+
description: "Custom bullet character (simplified option when levels not specified)"
|
|
1467
|
+
})
|
|
1468
|
+
),
|
|
1469
|
+
start: Type13.Optional(
|
|
1470
|
+
Type13.Number({
|
|
1471
|
+
minimum: 1,
|
|
1472
|
+
description: "Starting number for level 0 (simplified option when levels not specified)"
|
|
1473
|
+
})
|
|
1474
|
+
),
|
|
1475
|
+
spacing: Type13.Optional(ListSpacingSchema),
|
|
1476
|
+
alignment: Type13.Optional(JustifiedAlignmentSchema),
|
|
1477
|
+
indent: Type13.Optional(
|
|
1478
|
+
Type13.Union([Type13.Number({ minimum: 0 }), IndentSchema])
|
|
1479
|
+
)
|
|
1480
|
+
},
|
|
1481
|
+
{
|
|
1482
|
+
description: "List component props",
|
|
1483
|
+
additionalProperties: false
|
|
1484
|
+
}
|
|
1485
|
+
);
|
|
1486
|
+
|
|
1487
|
+
// src/schemas/components/toc.ts
|
|
1488
|
+
import { Type as Type14 } from "@sinclair/typebox";
|
|
1489
|
+
var TocStyleSchema = Type14.Union(
|
|
1490
|
+
[Type14.Literal("numeric"), Type14.Literal("bullet"), Type14.Literal("none")],
|
|
1491
|
+
{ description: "TOC numbering style" }
|
|
1492
|
+
);
|
|
1493
|
+
var TocScopeSchema = Type14.Union(
|
|
1494
|
+
[Type14.Literal("document"), Type14.Literal("section")],
|
|
1495
|
+
{ description: "TOC scope: document-wide or section-only" }
|
|
1496
|
+
);
|
|
1497
|
+
var TocStyleMappingSchema = Type14.Object(
|
|
1498
|
+
{
|
|
1499
|
+
styleId: Type14.String({
|
|
1500
|
+
description: "Custom style ID matching a key in theme.styles"
|
|
1501
|
+
}),
|
|
1502
|
+
level: Type14.Number({
|
|
1503
|
+
minimum: 1,
|
|
1504
|
+
maximum: 6,
|
|
1505
|
+
description: "TOC level (1-6) to assign to this style"
|
|
1506
|
+
})
|
|
1507
|
+
},
|
|
1508
|
+
{
|
|
1509
|
+
description: "Mapping of custom style to TOC level",
|
|
1510
|
+
additionalProperties: false
|
|
1511
|
+
}
|
|
1512
|
+
);
|
|
1513
|
+
var TocDepthRangeSchema = Type14.Object(
|
|
1514
|
+
{
|
|
1515
|
+
from: Type14.Optional(
|
|
1516
|
+
Type14.Number({
|
|
1517
|
+
minimum: 1,
|
|
1518
|
+
maximum: 6,
|
|
1519
|
+
default: 1,
|
|
1520
|
+
description: "Starting heading level (1-6). Defaults to 1 if not specified."
|
|
1521
|
+
})
|
|
1522
|
+
),
|
|
1523
|
+
to: Type14.Optional(
|
|
1524
|
+
Type14.Number({
|
|
1525
|
+
minimum: 1,
|
|
1526
|
+
maximum: 6,
|
|
1527
|
+
default: 3,
|
|
1528
|
+
description: "Ending heading level (1-6). Defaults to 3 if not specified."
|
|
1529
|
+
})
|
|
1530
|
+
)
|
|
1531
|
+
},
|
|
1532
|
+
{
|
|
1533
|
+
description: 'Range of heading levels to include in TOC. Specify at least one of "from" or "to".',
|
|
1534
|
+
additionalProperties: false
|
|
1535
|
+
}
|
|
1536
|
+
);
|
|
1537
|
+
var TocPropsSchema = Type14.Object(
|
|
1538
|
+
{
|
|
1539
|
+
pageBreak: Type14.Optional(
|
|
1540
|
+
Type14.Boolean({
|
|
1541
|
+
description: "Insert page break before TOC block"
|
|
1542
|
+
})
|
|
1543
|
+
),
|
|
1544
|
+
depth: Type14.Optional(
|
|
1545
|
+
Type14.Object(
|
|
1546
|
+
{
|
|
1547
|
+
from: Type14.Optional(
|
|
1548
|
+
Type14.Number({
|
|
1549
|
+
minimum: 1,
|
|
1550
|
+
maximum: 6,
|
|
1551
|
+
default: 1,
|
|
1552
|
+
description: "Starting heading level (1-6). Defaults to 1 if not specified."
|
|
1553
|
+
})
|
|
1554
|
+
),
|
|
1555
|
+
to: Type14.Optional(
|
|
1556
|
+
Type14.Number({
|
|
1557
|
+
minimum: 1,
|
|
1558
|
+
maximum: 6,
|
|
1559
|
+
default: 3,
|
|
1560
|
+
description: "Ending heading level (1-6). Defaults to 3 if not specified."
|
|
1561
|
+
})
|
|
1562
|
+
)
|
|
1563
|
+
},
|
|
1564
|
+
{
|
|
1565
|
+
description: 'Range of heading levels to include in TOC. Specify "from", "to", or both. Defaults: from=1, to=3',
|
|
1566
|
+
additionalProperties: false,
|
|
1567
|
+
default: { to: 3 }
|
|
1568
|
+
}
|
|
1569
|
+
)
|
|
1570
|
+
),
|
|
1571
|
+
pageNumbersDepth: Type14.Optional(
|
|
1572
|
+
Type14.Object(
|
|
1573
|
+
{
|
|
1574
|
+
from: Type14.Optional(
|
|
1575
|
+
Type14.Number({
|
|
1576
|
+
minimum: 1,
|
|
1577
|
+
maximum: 6,
|
|
1578
|
+
default: 1,
|
|
1579
|
+
description: "Starting heading level (1-6). Defaults to 1 if not specified."
|
|
1580
|
+
})
|
|
1581
|
+
),
|
|
1582
|
+
to: Type14.Optional(
|
|
1583
|
+
Type14.Number({
|
|
1584
|
+
minimum: 1,
|
|
1585
|
+
maximum: 6,
|
|
1586
|
+
default: 3,
|
|
1587
|
+
description: "Ending heading level (1-6). Defaults to 3 if not specified."
|
|
1588
|
+
})
|
|
1589
|
+
)
|
|
1590
|
+
},
|
|
1591
|
+
{
|
|
1592
|
+
description: 'Range of heading levels to show page numbers. Specify "from", "to", or both. When specified, page numbers are hidden for entries outside this range.',
|
|
1593
|
+
additionalProperties: false
|
|
1594
|
+
}
|
|
1595
|
+
)
|
|
1596
|
+
),
|
|
1597
|
+
numberingStyle: Type14.Optional(TocStyleSchema),
|
|
1598
|
+
title: Type14.Optional(
|
|
1599
|
+
Type14.String({
|
|
1600
|
+
description: "TOC heading title"
|
|
1601
|
+
})
|
|
1602
|
+
),
|
|
1603
|
+
includePageNumbers: Type14.Optional(
|
|
1604
|
+
Type14.Boolean({
|
|
1605
|
+
default: true,
|
|
1606
|
+
description: "Show page numbers next to entries"
|
|
1607
|
+
})
|
|
1608
|
+
),
|
|
1609
|
+
numberSeparator: Type14.Optional(
|
|
1610
|
+
Type14.Boolean({
|
|
1611
|
+
default: true,
|
|
1612
|
+
description: 'Use tab separator between entry and page number. True applies "\\t" (default), false applies " "'
|
|
1613
|
+
})
|
|
1614
|
+
),
|
|
1615
|
+
scope: Type14.Optional(
|
|
1616
|
+
Type14.Union([TocScopeSchema, Type14.Literal("auto")], {
|
|
1617
|
+
default: "auto",
|
|
1618
|
+
description: 'TOC scope: "document" for entire document, "section" for parent section only, "auto" for automatic detection (section if inside section, otherwise document)'
|
|
1619
|
+
})
|
|
1620
|
+
),
|
|
1621
|
+
styles: Type14.Optional(
|
|
1622
|
+
Type14.Array(TocStyleMappingSchema, {
|
|
1623
|
+
description: "Custom style mappings for TOC entries. Maps custom theme styles to TOC levels."
|
|
1624
|
+
})
|
|
1625
|
+
)
|
|
1626
|
+
},
|
|
1627
|
+
{
|
|
1628
|
+
description: "Table of Contents component props",
|
|
1629
|
+
additionalProperties: false
|
|
1630
|
+
}
|
|
1631
|
+
);
|
|
1632
|
+
|
|
1633
|
+
// src/schemas/components/highcharts.ts
|
|
1634
|
+
import { Type as Type15 } from "@sinclair/typebox";
|
|
1635
|
+
var HighchartsPropsSchema = Type15.Object({
|
|
1636
|
+
// Highcharts chart options - can be anything but must at least have chart.width and chart.height
|
|
1637
|
+
options: Type15.Intersect([
|
|
1638
|
+
Type15.Record(Type15.String(), Type15.Unknown()),
|
|
1639
|
+
Type15.Object({
|
|
1640
|
+
chart: Type15.Object({
|
|
1641
|
+
width: Type15.Number(),
|
|
1642
|
+
height: Type15.Number()
|
|
1643
|
+
})
|
|
1644
|
+
})
|
|
1645
|
+
]),
|
|
1646
|
+
// Optional scale factor for export
|
|
1647
|
+
scale: Type15.Optional(Type15.Number()),
|
|
1648
|
+
// Optional Highcharts Export Server URL override
|
|
1649
|
+
serverUrl: Type15.Optional(Type15.String({ description: "Highcharts Export Server URL (default: http://localhost:7801)" })),
|
|
1650
|
+
// Optional width for rendering (overrides chart width)
|
|
1651
|
+
width: Type15.Optional(
|
|
1652
|
+
Type15.Union(
|
|
1653
|
+
[
|
|
1654
|
+
Type15.Number({
|
|
1655
|
+
minimum: 1,
|
|
1656
|
+
description: "Image width in pixels"
|
|
1657
|
+
}),
|
|
1658
|
+
Type15.String({
|
|
1659
|
+
pattern: "^\\d+(\\.\\d+)?%$",
|
|
1660
|
+
description: 'Image width as percentage (e.g., "90%") relative to content width'
|
|
1661
|
+
})
|
|
1662
|
+
],
|
|
1663
|
+
{
|
|
1664
|
+
description: 'Rendered image width in pixels (number) or as percentage string (e.g., "90%")'
|
|
1665
|
+
}
|
|
1666
|
+
)
|
|
1667
|
+
),
|
|
1668
|
+
// Optional height for rendering (overrides chart height)
|
|
1669
|
+
height: Type15.Optional(
|
|
1670
|
+
Type15.Union(
|
|
1671
|
+
[
|
|
1672
|
+
Type15.Number({
|
|
1673
|
+
minimum: 1,
|
|
1674
|
+
description: "Image height in pixels"
|
|
1675
|
+
}),
|
|
1676
|
+
Type15.String({
|
|
1677
|
+
pattern: "^\\d+(\\.\\d+)?%$",
|
|
1678
|
+
description: 'Image height as percentage (e.g., "90%") relative to content height'
|
|
1679
|
+
})
|
|
1680
|
+
],
|
|
1681
|
+
{
|
|
1682
|
+
description: 'Rendered image height in pixels (number) or as percentage string (e.g., "90%")'
|
|
1683
|
+
}
|
|
1684
|
+
)
|
|
1685
|
+
)
|
|
1686
|
+
});
|
|
1687
|
+
|
|
1688
|
+
// src/schemas/component-registry.ts
|
|
1689
|
+
var STANDARD_COMPONENTS_REGISTRY = [
|
|
1690
|
+
// ========================================================================
|
|
1691
|
+
// Container Components (can contain children)
|
|
1692
|
+
// ========================================================================
|
|
1693
|
+
{
|
|
1694
|
+
name: "docx",
|
|
1695
|
+
propsSchema: ReportPropsSchema,
|
|
1696
|
+
hasChildren: true,
|
|
1697
|
+
category: "container",
|
|
1698
|
+
description: "Main document container - defines the overall document structure. Required as the root component.",
|
|
1699
|
+
special: {
|
|
1700
|
+
hasSchemaField: true
|
|
1701
|
+
// Only docx root has $schema field
|
|
1702
|
+
}
|
|
1703
|
+
},
|
|
1704
|
+
{
|
|
1705
|
+
name: "section",
|
|
1706
|
+
propsSchema: SectionPropsSchema,
|
|
1707
|
+
hasChildren: true,
|
|
1708
|
+
category: "container",
|
|
1709
|
+
description: "Section container - groups related content with optional title. Use for organizing document structure."
|
|
1710
|
+
},
|
|
1711
|
+
{
|
|
1712
|
+
name: "columns",
|
|
1713
|
+
propsSchema: ColumnsPropsSchema,
|
|
1714
|
+
hasChildren: true,
|
|
1715
|
+
category: "layout",
|
|
1716
|
+
description: "Multi-column layout - arranges content in 2-4 columns. Great for side-by-side content."
|
|
1717
|
+
},
|
|
1718
|
+
{
|
|
1719
|
+
name: "text-box",
|
|
1720
|
+
propsSchema: TextBoxPropsSchema,
|
|
1721
|
+
hasChildren: true,
|
|
1722
|
+
category: "layout",
|
|
1723
|
+
description: "Floating text container - allows positioning text anywhere on the page with absolute or relative positioning."
|
|
1724
|
+
},
|
|
1725
|
+
// ========================================================================
|
|
1726
|
+
// Content Components (leaf nodes, no children)
|
|
1727
|
+
// ========================================================================
|
|
1728
|
+
{
|
|
1729
|
+
name: "heading",
|
|
1730
|
+
propsSchema: HeadingPropsSchema,
|
|
1731
|
+
hasChildren: false,
|
|
1732
|
+
category: "content",
|
|
1733
|
+
description: "Heading text - supports levels 1-6 for document hierarchy. Level 1 is largest."
|
|
1734
|
+
},
|
|
1735
|
+
{
|
|
1736
|
+
name: "paragraph",
|
|
1737
|
+
propsSchema: ParagraphPropsSchema,
|
|
1738
|
+
hasChildren: false,
|
|
1739
|
+
category: "content",
|
|
1740
|
+
description: "Paragraph text - supports formatting like bold, italic, and color. Main content element."
|
|
1741
|
+
},
|
|
1742
|
+
{
|
|
1743
|
+
name: "image",
|
|
1744
|
+
propsSchema: ImagePropsSchema,
|
|
1745
|
+
hasChildren: false,
|
|
1746
|
+
category: "content",
|
|
1747
|
+
description: "Image element - displays images with optional caption. Supports various formats."
|
|
1748
|
+
},
|
|
1749
|
+
{
|
|
1750
|
+
name: "statistic",
|
|
1751
|
+
propsSchema: StatisticPropsSchema,
|
|
1752
|
+
hasChildren: false,
|
|
1753
|
+
category: "content",
|
|
1754
|
+
description: "Statistic display - shows a number with description. Perfect for KPIs and metrics."
|
|
1755
|
+
},
|
|
1756
|
+
{
|
|
1757
|
+
name: "table",
|
|
1758
|
+
propsSchema: TablePropsSchema,
|
|
1759
|
+
hasChildren: false,
|
|
1760
|
+
category: "content",
|
|
1761
|
+
description: "Data table - displays tabular data with headers. Supports formatting and alignment."
|
|
1762
|
+
},
|
|
1763
|
+
{
|
|
1764
|
+
name: "header",
|
|
1765
|
+
propsSchema: HeaderPropsSchema,
|
|
1766
|
+
hasChildren: false,
|
|
1767
|
+
category: "content",
|
|
1768
|
+
description: "Page header - appears at the top of pages. Can include text and page numbers."
|
|
1769
|
+
},
|
|
1770
|
+
{
|
|
1771
|
+
name: "footer",
|
|
1772
|
+
propsSchema: FooterPropsSchema,
|
|
1773
|
+
hasChildren: false,
|
|
1774
|
+
category: "content",
|
|
1775
|
+
description: "Page footer - appears at the bottom of pages. Can include text and page numbers."
|
|
1776
|
+
},
|
|
1777
|
+
{
|
|
1778
|
+
name: "list",
|
|
1779
|
+
propsSchema: ListPropsSchema,
|
|
1780
|
+
hasChildren: false,
|
|
1781
|
+
category: "content",
|
|
1782
|
+
description: "List element - bulleted or numbered list items. Supports nested lists."
|
|
1783
|
+
},
|
|
1784
|
+
{
|
|
1785
|
+
name: "toc",
|
|
1786
|
+
propsSchema: TocPropsSchema,
|
|
1787
|
+
hasChildren: false,
|
|
1788
|
+
category: "content",
|
|
1789
|
+
description: "Table of contents - automatically generates TOC from document headings. Supports depth ranges and custom styles."
|
|
1790
|
+
},
|
|
1791
|
+
{
|
|
1792
|
+
name: "highcharts",
|
|
1793
|
+
propsSchema: HighchartsPropsSchema,
|
|
1794
|
+
hasChildren: false,
|
|
1795
|
+
category: "content",
|
|
1796
|
+
description: "Chart component powered by Highcharts - render line, bar, pie, heatmap, and more with rich options."
|
|
1797
|
+
}
|
|
1798
|
+
];
|
|
1799
|
+
function getStandardComponent(name) {
|
|
1800
|
+
return STANDARD_COMPONENTS_REGISTRY.find((c) => c.name === name);
|
|
1801
|
+
}
|
|
1802
|
+
function getAllStandardComponentNames() {
|
|
1803
|
+
return STANDARD_COMPONENTS_REGISTRY.map((c) => c.name);
|
|
1804
|
+
}
|
|
1805
|
+
function getComponentsByCategory(category) {
|
|
1806
|
+
return STANDARD_COMPONENTS_REGISTRY.filter((c) => c.category === category);
|
|
1807
|
+
}
|
|
1808
|
+
function getContainerComponents() {
|
|
1809
|
+
return STANDARD_COMPONENTS_REGISTRY.filter((c) => c.hasChildren);
|
|
1810
|
+
}
|
|
1811
|
+
function getContentComponents() {
|
|
1812
|
+
return STANDARD_COMPONENTS_REGISTRY.filter((c) => !c.hasChildren);
|
|
1813
|
+
}
|
|
1814
|
+
function isStandardComponent(name) {
|
|
1815
|
+
return STANDARD_COMPONENTS_REGISTRY.some((c) => c.name === name);
|
|
1816
|
+
}
|
|
1817
|
+
function createComponentSchemaObject(component, recursiveRef) {
|
|
1818
|
+
const schema = {
|
|
1819
|
+
name: Type16.Literal(component.name),
|
|
1820
|
+
id: Type16.Optional(Type16.String()),
|
|
1821
|
+
enabled: Type16.Optional(
|
|
1822
|
+
Type16.Boolean({
|
|
1823
|
+
default: true,
|
|
1824
|
+
description: "When false, this component is filtered out and not rendered. Defaults to true. Useful for conditional component inclusion."
|
|
1825
|
+
})
|
|
1826
|
+
)
|
|
1827
|
+
};
|
|
1828
|
+
if (component.special?.hasSchemaField) {
|
|
1829
|
+
schema.$schema = Type16.Optional(Type16.String({ format: "uri" }));
|
|
1830
|
+
}
|
|
1831
|
+
schema.props = component.propsSchema;
|
|
1832
|
+
if (component.hasChildren && recursiveRef) {
|
|
1833
|
+
schema.children = Type16.Optional(Type16.Array(recursiveRef));
|
|
1834
|
+
}
|
|
1835
|
+
return Type16.Object(schema, { additionalProperties: false });
|
|
1836
|
+
}
|
|
1837
|
+
function createAllComponentSchemas(recursiveRef) {
|
|
1838
|
+
return STANDARD_COMPONENTS_REGISTRY.map(
|
|
1839
|
+
(component) => createComponentSchemaObject(component, recursiveRef)
|
|
1840
|
+
);
|
|
1841
|
+
}
|
|
1842
|
+
|
|
1843
|
+
export {
|
|
1844
|
+
createReportPropsSchema,
|
|
1845
|
+
ReportPropsSchema,
|
|
1846
|
+
AlignmentSchema,
|
|
1847
|
+
JustifiedAlignmentSchema,
|
|
1848
|
+
HeadingLevelSchema,
|
|
1849
|
+
SpacingSchema,
|
|
1850
|
+
ListSpacingSchema,
|
|
1851
|
+
MarginsSchema,
|
|
1852
|
+
BorderSchema,
|
|
1853
|
+
LineSpacingSchema,
|
|
1854
|
+
IndentSchema,
|
|
1855
|
+
HorizontalPositionRelativeFromSchema,
|
|
1856
|
+
VerticalPositionRelativeFromSchema,
|
|
1857
|
+
HorizontalPositionAlignSchema,
|
|
1858
|
+
VerticalPositionAlignSchema,
|
|
1859
|
+
TextWrappingTypeSchema,
|
|
1860
|
+
TextWrappingSideSchema,
|
|
1861
|
+
FloatingPropertiesSchema,
|
|
1862
|
+
NumberingSchema,
|
|
1863
|
+
BaseComponentFields,
|
|
1864
|
+
BaseComponentPropsSchema,
|
|
1865
|
+
createSectionPropsSchema,
|
|
1866
|
+
SectionPropsSchema,
|
|
1867
|
+
ColumnsPropsSchema,
|
|
1868
|
+
HeadingPropsSchema,
|
|
1869
|
+
ParagraphPropsSchema,
|
|
1870
|
+
TextBoxPropsSchema,
|
|
1871
|
+
ImagePropsSchema,
|
|
1872
|
+
StatisticPropsSchema,
|
|
1873
|
+
TablePropsSchema,
|
|
1874
|
+
HeaderPropsSchema,
|
|
1875
|
+
FooterPropsSchema,
|
|
1876
|
+
LevelFormatSchema,
|
|
1877
|
+
ListLevelPropsSchema,
|
|
1878
|
+
ListPropsSchema,
|
|
1879
|
+
TocStyleSchema,
|
|
1880
|
+
TocScopeSchema,
|
|
1881
|
+
TocStyleMappingSchema,
|
|
1882
|
+
TocDepthRangeSchema,
|
|
1883
|
+
TocPropsSchema,
|
|
1884
|
+
HighchartsPropsSchema,
|
|
1885
|
+
STANDARD_COMPONENTS_REGISTRY,
|
|
1886
|
+
getStandardComponent,
|
|
1887
|
+
getAllStandardComponentNames,
|
|
1888
|
+
getComponentsByCategory,
|
|
1889
|
+
getContainerComponents,
|
|
1890
|
+
getContentComponents,
|
|
1891
|
+
isStandardComponent,
|
|
1892
|
+
createComponentSchemaObject,
|
|
1893
|
+
createAllComponentSchemas
|
|
1894
|
+
};
|
|
1895
|
+
//# sourceMappingURL=chunk-5533WPL6.js.map
|