@polotno/schema 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.
Files changed (48) hide show
  1. package/LICENSE.md +10 -0
  2. package/README.md +81 -0
  3. package/lib/constants.d.ts +6 -0
  4. package/lib/constants.d.ts.map +1 -0
  5. package/lib/constants.js +61 -0
  6. package/lib/constants.js.map +1 -0
  7. package/lib/defaults.d.ts +445 -0
  8. package/lib/defaults.d.ts.map +1 -0
  9. package/lib/defaults.js +254 -0
  10. package/lib/defaults.js.map +1 -0
  11. package/lib/design.schema.json +2771 -0
  12. package/lib/index.d.ts +5 -0
  13. package/lib/index.d.ts.map +1 -0
  14. package/lib/index.js +7 -0
  15. package/lib/index.js.map +1 -0
  16. package/lib/migrate.d.ts +6 -0
  17. package/lib/migrate.d.ts.map +1 -0
  18. package/lib/migrate.js +58 -0
  19. package/lib/migrate.js.map +1 -0
  20. package/lib/normalize.d.ts +2 -0
  21. package/lib/normalize.d.ts.map +1 -0
  22. package/lib/normalize.js +36 -0
  23. package/lib/normalize.js.map +1 -0
  24. package/lib/processors.d.ts +13 -0
  25. package/lib/processors.d.ts.map +1 -0
  26. package/lib/processors.js +170 -0
  27. package/lib/processors.js.map +1 -0
  28. package/lib/schema.d.ts +693 -0
  29. package/lib/schema.d.ts.map +1 -0
  30. package/lib/schema.js +379 -0
  31. package/lib/schema.js.map +1 -0
  32. package/lib/traverse.d.ts +3 -0
  33. package/lib/traverse.d.ts.map +1 -0
  34. package/lib/traverse.js +32 -0
  35. package/lib/traverse.js.map +1 -0
  36. package/lib/types-parity.d.ts +2 -0
  37. package/lib/types-parity.d.ts.map +1 -0
  38. package/lib/types-parity.js +11 -0
  39. package/lib/types-parity.js.map +1 -0
  40. package/lib/types.d.ts +349 -0
  41. package/lib/types.d.ts.map +1 -0
  42. package/lib/types.js +22 -0
  43. package/lib/types.js.map +1 -0
  44. package/lib/validate.d.ts +19 -0
  45. package/lib/validate.d.ts.map +1 -0
  46. package/lib/validate.js +383 -0
  47. package/lib/validate.js.map +1 -0
  48. package/package.json +57 -0
@@ -0,0 +1,2771 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "type": "object",
4
+ "properties": {
5
+ "schemaVersion": {
6
+ "default": 4,
7
+ "description": "Schema version for compatibility / migration.",
8
+ "type": "number"
9
+ },
10
+ "width": {
11
+ "default": 1080,
12
+ "description": "Canvas width in pixels.",
13
+ "type": "number"
14
+ },
15
+ "height": {
16
+ "default": 1080,
17
+ "description": "Canvas height in pixels.",
18
+ "type": "number"
19
+ },
20
+ "unit": {
21
+ "default": "px",
22
+ "description": "Unit type for print measurements.",
23
+ "type": "string",
24
+ "enum": [
25
+ "px",
26
+ "pt",
27
+ "mm",
28
+ "cm",
29
+ "in"
30
+ ]
31
+ },
32
+ "dpi": {
33
+ "default": 72,
34
+ "description": "Dots per inch for print calculations.",
35
+ "type": "number"
36
+ },
37
+ "custom": {
38
+ "description": "Custom data attached to the design."
39
+ },
40
+ "fonts": {
41
+ "default": [],
42
+ "description": "Fonts used in the design.",
43
+ "type": "array",
44
+ "items": {
45
+ "type": "object",
46
+ "properties": {
47
+ "fontFamily": {
48
+ "type": "string",
49
+ "description": "Font family name."
50
+ },
51
+ "url": {
52
+ "default": "",
53
+ "description": "URL to load the font from (single-variant fonts).",
54
+ "type": "string"
55
+ },
56
+ "styles": {
57
+ "description": "Per-weight/style variants for multi-variant families.",
58
+ "type": "array",
59
+ "items": {
60
+ "type": "object",
61
+ "properties": {
62
+ "src": {
63
+ "type": "string",
64
+ "description": "Font source, typically in CSS url() form."
65
+ },
66
+ "fontStyle": {
67
+ "type": "string"
68
+ },
69
+ "fontWeight": {
70
+ "type": "string"
71
+ }
72
+ },
73
+ "required": [
74
+ "src"
75
+ ]
76
+ }
77
+ }
78
+ },
79
+ "required": [
80
+ "fontFamily"
81
+ ]
82
+ }
83
+ },
84
+ "pages": {
85
+ "default": [],
86
+ "description": "Pages in the design.",
87
+ "type": "array",
88
+ "items": {
89
+ "type": "object",
90
+ "properties": {
91
+ "id": {
92
+ "type": "string",
93
+ "description": "Unique identifier for the page."
94
+ },
95
+ "width": {
96
+ "default": "auto",
97
+ "description": "Page width in pixels or 'auto'.",
98
+ "anyOf": [
99
+ {
100
+ "type": "number"
101
+ },
102
+ {
103
+ "type": "string",
104
+ "const": "auto"
105
+ }
106
+ ]
107
+ },
108
+ "height": {
109
+ "default": "auto",
110
+ "description": "Page height in pixels or 'auto'.",
111
+ "anyOf": [
112
+ {
113
+ "type": "number"
114
+ },
115
+ {
116
+ "type": "string",
117
+ "const": "auto"
118
+ }
119
+ ]
120
+ },
121
+ "background": {
122
+ "default": "white",
123
+ "description": "Background color or image.",
124
+ "type": "string"
125
+ },
126
+ "bleed": {
127
+ "default": 0,
128
+ "description": "Bleed area in pixels for print.",
129
+ "type": "number"
130
+ },
131
+ "custom": {},
132
+ "duration": {
133
+ "default": 5000,
134
+ "description": "Page duration in milliseconds.",
135
+ "type": "number"
136
+ },
137
+ "children": {
138
+ "default": [],
139
+ "description": "Elements on this page.",
140
+ "type": "array",
141
+ "items": {
142
+ "$ref": "#/$defs/__schema0"
143
+ }
144
+ }
145
+ },
146
+ "required": [
147
+ "id"
148
+ ]
149
+ }
150
+ },
151
+ "audios": {
152
+ "default": [],
153
+ "description": "Audio tracks in the design.",
154
+ "type": "array",
155
+ "items": {
156
+ "type": "object",
157
+ "properties": {
158
+ "id": {
159
+ "type": "string",
160
+ "description": "Unique identifier for the audio track."
161
+ },
162
+ "src": {
163
+ "default": "",
164
+ "description": "URL or data URI of the audio file.",
165
+ "type": "string"
166
+ },
167
+ "duration": {
168
+ "default": 0,
169
+ "description": "Duration in milliseconds.",
170
+ "type": "number"
171
+ },
172
+ "startTime": {
173
+ "default": 0,
174
+ "description": "Start offset (0-1).",
175
+ "type": "number"
176
+ },
177
+ "endTime": {
178
+ "default": 1,
179
+ "description": "End offset (0-1).",
180
+ "type": "number"
181
+ },
182
+ "volume": {
183
+ "default": 1,
184
+ "description": "Volume level (0-1).",
185
+ "type": "number"
186
+ },
187
+ "delay": {
188
+ "default": 0,
189
+ "description": "Delay before playing, in milliseconds.",
190
+ "type": "number"
191
+ },
192
+ "speed": {
193
+ "default": 1,
194
+ "description": "Playback speed multiplier (1 = normal).",
195
+ "type": "number"
196
+ },
197
+ "custom": {}
198
+ },
199
+ "required": [
200
+ "id"
201
+ ]
202
+ }
203
+ }
204
+ },
205
+ "$defs": {
206
+ "__schema0": {
207
+ "oneOf": [
208
+ {
209
+ "type": "object",
210
+ "properties": {
211
+ "id": {
212
+ "type": "string",
213
+ "description": "Unique identifier for the element."
214
+ },
215
+ "type": {
216
+ "type": "string",
217
+ "const": "text"
218
+ },
219
+ "name": {
220
+ "default": "",
221
+ "description": "Display name for the element.",
222
+ "type": "string"
223
+ },
224
+ "custom": {
225
+ "description": "Custom data attached to the element."
226
+ },
227
+ "x": {
228
+ "default": 0,
229
+ "description": "X position in pixels.",
230
+ "type": "number"
231
+ },
232
+ "y": {
233
+ "default": 0,
234
+ "description": "Y position in pixels.",
235
+ "type": "number"
236
+ },
237
+ "width": {
238
+ "default": 100,
239
+ "description": "Width in pixels.",
240
+ "type": "number"
241
+ },
242
+ "height": {
243
+ "default": 0,
244
+ "description": "Height in pixels (0 until measured/rendered).",
245
+ "type": "number"
246
+ },
247
+ "rotation": {
248
+ "default": 0,
249
+ "description": "Rotation angle in degrees.",
250
+ "type": "number"
251
+ },
252
+ "opacity": {
253
+ "default": 1,
254
+ "description": "Opacity level (0-1).",
255
+ "type": "number"
256
+ },
257
+ "animations": {
258
+ "default": [],
259
+ "description": "Animation configurations.",
260
+ "type": "array",
261
+ "items": {
262
+ "type": "object",
263
+ "properties": {
264
+ "delay": {
265
+ "default": 0,
266
+ "description": "Delay before the animation starts, in milliseconds.",
267
+ "type": "number"
268
+ },
269
+ "duration": {
270
+ "default": 500,
271
+ "description": "Animation duration in milliseconds.",
272
+ "type": "number"
273
+ },
274
+ "enabled": {
275
+ "default": true,
276
+ "description": "Whether the animation is enabled.",
277
+ "type": "boolean"
278
+ },
279
+ "type": {
280
+ "type": "string",
281
+ "enum": [
282
+ "enter",
283
+ "exit",
284
+ "loop"
285
+ ],
286
+ "description": "Animation phase."
287
+ },
288
+ "name": {
289
+ "default": "none",
290
+ "description": "Animation name identifier.",
291
+ "type": "string"
292
+ },
293
+ "data": {
294
+ "default": {},
295
+ "description": "Animation-specific data."
296
+ }
297
+ },
298
+ "required": [
299
+ "type"
300
+ ]
301
+ }
302
+ },
303
+ "blurEnabled": {
304
+ "default": false,
305
+ "description": "Whether blur effect is enabled.",
306
+ "type": "boolean"
307
+ },
308
+ "blurRadius": {
309
+ "default": 10,
310
+ "description": "Blur radius in pixels.",
311
+ "type": "number"
312
+ },
313
+ "brightnessEnabled": {
314
+ "default": false,
315
+ "description": "Whether brightness effect is enabled.",
316
+ "type": "boolean"
317
+ },
318
+ "brightness": {
319
+ "default": 0,
320
+ "description": "Brightness level (-1 to 1).",
321
+ "type": "number"
322
+ },
323
+ "sepiaEnabled": {
324
+ "default": false,
325
+ "description": "Whether sepia effect is enabled.",
326
+ "type": "boolean"
327
+ },
328
+ "grayscaleEnabled": {
329
+ "default": false,
330
+ "description": "Whether grayscale effect is enabled.",
331
+ "type": "boolean"
332
+ },
333
+ "filters": {
334
+ "default": {},
335
+ "type": "object",
336
+ "propertyNames": {
337
+ "type": "string"
338
+ },
339
+ "additionalProperties": {
340
+ "type": "object",
341
+ "properties": {
342
+ "intensity": {
343
+ "default": 1,
344
+ "description": "Filter intensity (-1 to 1).",
345
+ "type": "number"
346
+ }
347
+ }
348
+ },
349
+ "description": "Applied image filters keyed by filter name."
350
+ },
351
+ "shadowEnabled": {
352
+ "default": false,
353
+ "description": "Whether shadow is enabled.",
354
+ "type": "boolean"
355
+ },
356
+ "shadowBlur": {
357
+ "default": 5,
358
+ "description": "Shadow blur radius in pixels.",
359
+ "type": "number"
360
+ },
361
+ "shadowOffsetX": {
362
+ "default": 0,
363
+ "description": "Shadow horizontal offset in pixels.",
364
+ "type": "number"
365
+ },
366
+ "shadowOffsetY": {
367
+ "default": 0,
368
+ "description": "Shadow vertical offset in pixels.",
369
+ "type": "number"
370
+ },
371
+ "shadowColor": {
372
+ "default": "black",
373
+ "description": "Shadow color.",
374
+ "type": "string"
375
+ },
376
+ "shadowOpacity": {
377
+ "default": 1,
378
+ "description": "Shadow opacity (0-1).",
379
+ "type": "number"
380
+ },
381
+ "visible": {
382
+ "default": true,
383
+ "description": "Whether the element is visible.",
384
+ "type": "boolean"
385
+ },
386
+ "draggable": {
387
+ "default": true,
388
+ "description": "Whether the element can be dragged.",
389
+ "type": "boolean"
390
+ },
391
+ "resizable": {
392
+ "default": true,
393
+ "description": "Whether the element can be resized.",
394
+ "type": "boolean"
395
+ },
396
+ "selectable": {
397
+ "default": true,
398
+ "description": "Whether the element can be selected.",
399
+ "type": "boolean"
400
+ },
401
+ "removable": {
402
+ "default": true,
403
+ "description": "Whether the element can be removed.",
404
+ "type": "boolean"
405
+ },
406
+ "contentEditable": {
407
+ "default": true,
408
+ "description": "Whether the element content can be edited.",
409
+ "type": "boolean"
410
+ },
411
+ "styleEditable": {
412
+ "default": true,
413
+ "description": "Whether the element style can be edited.",
414
+ "type": "boolean"
415
+ },
416
+ "alwaysOnTop": {
417
+ "default": false,
418
+ "description": "Whether the element stays on top of others.",
419
+ "type": "boolean"
420
+ },
421
+ "showInExport": {
422
+ "default": true,
423
+ "description": "Whether the element appears in exports.",
424
+ "type": "boolean"
425
+ },
426
+ "text": {
427
+ "default": "",
428
+ "description": "Visible text shown on canvas.",
429
+ "type": "string"
430
+ },
431
+ "placeholder": {
432
+ "default": "",
433
+ "description": "Placeholder text shown when empty.",
434
+ "type": "string"
435
+ },
436
+ "fontSize": {
437
+ "default": 14,
438
+ "description": "Font size in pixels.",
439
+ "type": "number"
440
+ },
441
+ "fontFamily": {
442
+ "default": "Roboto",
443
+ "description": "Font family name.",
444
+ "type": "string"
445
+ },
446
+ "fontStyle": {
447
+ "default": "normal",
448
+ "description": "Font style: 'normal' or 'italic'.",
449
+ "type": "string"
450
+ },
451
+ "fontWeight": {
452
+ "default": "normal",
453
+ "description": "Font weight: 'normal', 'bold', or numeric string.",
454
+ "type": "string"
455
+ },
456
+ "textDecoration": {
457
+ "default": "",
458
+ "description": "Text decoration (e.g. underline, line-through).",
459
+ "type": "string"
460
+ },
461
+ "textTransform": {
462
+ "default": "none",
463
+ "description": "Text transform: uppercase, lowercase, capitalize, none.",
464
+ "type": "string"
465
+ },
466
+ "fill": {
467
+ "default": "black",
468
+ "description": "Text color.",
469
+ "type": "string"
470
+ },
471
+ "align": {
472
+ "default": "center",
473
+ "description": "Horizontal alignment (commonly left | center | right | justify).",
474
+ "type": "string"
475
+ },
476
+ "verticalAlign": {
477
+ "default": "top",
478
+ "description": "Vertical alignment: top, middle, bottom.",
479
+ "type": "string"
480
+ },
481
+ "strokeWidth": {
482
+ "default": 0,
483
+ "description": "Stroke width in pixels.",
484
+ "type": "number"
485
+ },
486
+ "stroke": {
487
+ "default": "black",
488
+ "description": "Stroke color.",
489
+ "type": "string"
490
+ },
491
+ "lineHeight": {
492
+ "default": 1.2,
493
+ "description": "Line height multiplier or 'auto'.",
494
+ "anyOf": [
495
+ {
496
+ "type": "number"
497
+ },
498
+ {
499
+ "type": "string"
500
+ }
501
+ ]
502
+ },
503
+ "letterSpacing": {
504
+ "default": 0,
505
+ "description": "Letter spacing as a fraction of font size.",
506
+ "type": "number"
507
+ },
508
+ "backgroundEnabled": {
509
+ "default": false,
510
+ "description": "Whether the text background is enabled.",
511
+ "type": "boolean"
512
+ },
513
+ "backgroundColor": {
514
+ "default": "#7ED321",
515
+ "description": "Text background color.",
516
+ "type": "string"
517
+ },
518
+ "backgroundOpacity": {
519
+ "default": 1,
520
+ "description": "Text background opacity (0-1).",
521
+ "type": "number"
522
+ },
523
+ "backgroundCornerRadius": {
524
+ "default": 0.5,
525
+ "description": "Text background corner radius.",
526
+ "type": "number"
527
+ },
528
+ "backgroundPadding": {
529
+ "default": 0.5,
530
+ "description": "Text background padding.",
531
+ "type": "number"
532
+ },
533
+ "curveEnabled": {
534
+ "default": false,
535
+ "description": "Whether the text curve effect is enabled.",
536
+ "type": "boolean"
537
+ },
538
+ "curvePower": {
539
+ "default": 0.5,
540
+ "description": "Text curve power (-1 to 1, 0 = straight).",
541
+ "type": "number"
542
+ },
543
+ "legacyBackground": {
544
+ "description": "Internal compatibility flag stamped by the v2→v3 migration.",
545
+ "type": "boolean"
546
+ }
547
+ },
548
+ "required": [
549
+ "id",
550
+ "type"
551
+ ]
552
+ },
553
+ {
554
+ "type": "object",
555
+ "properties": {
556
+ "id": {
557
+ "type": "string",
558
+ "description": "Unique identifier for the element."
559
+ },
560
+ "type": {
561
+ "type": "string",
562
+ "const": "image"
563
+ },
564
+ "name": {
565
+ "default": "",
566
+ "description": "Display name for the element.",
567
+ "type": "string"
568
+ },
569
+ "custom": {
570
+ "description": "Custom data attached to the element."
571
+ },
572
+ "x": {
573
+ "default": 0,
574
+ "description": "X position in pixels.",
575
+ "type": "number"
576
+ },
577
+ "y": {
578
+ "default": 0,
579
+ "description": "Y position in pixels.",
580
+ "type": "number"
581
+ },
582
+ "width": {
583
+ "default": 100,
584
+ "description": "Width in pixels.",
585
+ "type": "number"
586
+ },
587
+ "height": {
588
+ "default": 100,
589
+ "description": "Height in pixels.",
590
+ "type": "number"
591
+ },
592
+ "rotation": {
593
+ "default": 0,
594
+ "description": "Rotation angle in degrees.",
595
+ "type": "number"
596
+ },
597
+ "opacity": {
598
+ "default": 1,
599
+ "description": "Opacity level (0-1).",
600
+ "type": "number"
601
+ },
602
+ "animations": {
603
+ "default": [],
604
+ "description": "Animation configurations.",
605
+ "type": "array",
606
+ "items": {
607
+ "type": "object",
608
+ "properties": {
609
+ "delay": {
610
+ "default": 0,
611
+ "description": "Delay before the animation starts, in milliseconds.",
612
+ "type": "number"
613
+ },
614
+ "duration": {
615
+ "default": 500,
616
+ "description": "Animation duration in milliseconds.",
617
+ "type": "number"
618
+ },
619
+ "enabled": {
620
+ "default": true,
621
+ "description": "Whether the animation is enabled.",
622
+ "type": "boolean"
623
+ },
624
+ "type": {
625
+ "type": "string",
626
+ "enum": [
627
+ "enter",
628
+ "exit",
629
+ "loop"
630
+ ],
631
+ "description": "Animation phase."
632
+ },
633
+ "name": {
634
+ "default": "none",
635
+ "description": "Animation name identifier.",
636
+ "type": "string"
637
+ },
638
+ "data": {
639
+ "default": {},
640
+ "description": "Animation-specific data."
641
+ }
642
+ },
643
+ "required": [
644
+ "type"
645
+ ]
646
+ }
647
+ },
648
+ "blurEnabled": {
649
+ "default": false,
650
+ "description": "Whether blur effect is enabled.",
651
+ "type": "boolean"
652
+ },
653
+ "blurRadius": {
654
+ "default": 10,
655
+ "description": "Blur radius in pixels.",
656
+ "type": "number"
657
+ },
658
+ "brightnessEnabled": {
659
+ "default": false,
660
+ "description": "Whether brightness effect is enabled.",
661
+ "type": "boolean"
662
+ },
663
+ "brightness": {
664
+ "default": 0,
665
+ "description": "Brightness level (-1 to 1).",
666
+ "type": "number"
667
+ },
668
+ "sepiaEnabled": {
669
+ "default": false,
670
+ "description": "Whether sepia effect is enabled.",
671
+ "type": "boolean"
672
+ },
673
+ "grayscaleEnabled": {
674
+ "default": false,
675
+ "description": "Whether grayscale effect is enabled.",
676
+ "type": "boolean"
677
+ },
678
+ "filters": {
679
+ "default": {},
680
+ "type": "object",
681
+ "propertyNames": {
682
+ "type": "string"
683
+ },
684
+ "additionalProperties": {
685
+ "type": "object",
686
+ "properties": {
687
+ "intensity": {
688
+ "default": 1,
689
+ "description": "Filter intensity (-1 to 1).",
690
+ "type": "number"
691
+ }
692
+ }
693
+ },
694
+ "description": "Applied image filters keyed by filter name."
695
+ },
696
+ "shadowEnabled": {
697
+ "default": false,
698
+ "description": "Whether shadow is enabled.",
699
+ "type": "boolean"
700
+ },
701
+ "shadowBlur": {
702
+ "default": 5,
703
+ "description": "Shadow blur radius in pixels.",
704
+ "type": "number"
705
+ },
706
+ "shadowOffsetX": {
707
+ "default": 0,
708
+ "description": "Shadow horizontal offset in pixels.",
709
+ "type": "number"
710
+ },
711
+ "shadowOffsetY": {
712
+ "default": 0,
713
+ "description": "Shadow vertical offset in pixels.",
714
+ "type": "number"
715
+ },
716
+ "shadowColor": {
717
+ "default": "black",
718
+ "description": "Shadow color.",
719
+ "type": "string"
720
+ },
721
+ "shadowOpacity": {
722
+ "default": 1,
723
+ "description": "Shadow opacity (0-1).",
724
+ "type": "number"
725
+ },
726
+ "visible": {
727
+ "default": true,
728
+ "description": "Whether the element is visible.",
729
+ "type": "boolean"
730
+ },
731
+ "draggable": {
732
+ "default": true,
733
+ "description": "Whether the element can be dragged.",
734
+ "type": "boolean"
735
+ },
736
+ "resizable": {
737
+ "default": true,
738
+ "description": "Whether the element can be resized.",
739
+ "type": "boolean"
740
+ },
741
+ "selectable": {
742
+ "default": true,
743
+ "description": "Whether the element can be selected.",
744
+ "type": "boolean"
745
+ },
746
+ "removable": {
747
+ "default": true,
748
+ "description": "Whether the element can be removed.",
749
+ "type": "boolean"
750
+ },
751
+ "contentEditable": {
752
+ "default": true,
753
+ "description": "Whether the element content can be edited.",
754
+ "type": "boolean"
755
+ },
756
+ "styleEditable": {
757
+ "default": true,
758
+ "description": "Whether the element style can be edited.",
759
+ "type": "boolean"
760
+ },
761
+ "alwaysOnTop": {
762
+ "default": false,
763
+ "description": "Whether the element stays on top of others.",
764
+ "type": "boolean"
765
+ },
766
+ "showInExport": {
767
+ "default": true,
768
+ "description": "Whether the element appears in exports.",
769
+ "type": "boolean"
770
+ },
771
+ "src": {
772
+ "default": "",
773
+ "description": "URL or data URI of the image file.",
774
+ "type": "string"
775
+ },
776
+ "cropX": {
777
+ "default": 0,
778
+ "description": "Crop X offset as a fraction (0-1).",
779
+ "type": "number"
780
+ },
781
+ "cropY": {
782
+ "default": 0,
783
+ "description": "Crop Y offset as a fraction (0-1).",
784
+ "type": "number"
785
+ },
786
+ "cropWidth": {
787
+ "default": 1,
788
+ "description": "Crop width as a fraction (0-1).",
789
+ "type": "number"
790
+ },
791
+ "cropHeight": {
792
+ "default": 1,
793
+ "description": "Crop height as a fraction (0-1).",
794
+ "type": "number"
795
+ },
796
+ "cornerRadius": {
797
+ "default": 0,
798
+ "description": "Corner radius in pixels.",
799
+ "type": "number"
800
+ },
801
+ "flipX": {
802
+ "default": false,
803
+ "description": "Whether the image is flipped horizontally.",
804
+ "type": "boolean"
805
+ },
806
+ "flipY": {
807
+ "default": false,
808
+ "description": "Whether the image is flipped vertically.",
809
+ "type": "boolean"
810
+ },
811
+ "clipSrc": {
812
+ "default": "",
813
+ "description": "URL or data URI for a clipping mask.",
814
+ "type": "string"
815
+ },
816
+ "borderColor": {
817
+ "default": "black",
818
+ "description": "Border color.",
819
+ "type": "string"
820
+ },
821
+ "borderSize": {
822
+ "default": 0,
823
+ "description": "Border width in pixels.",
824
+ "type": "number"
825
+ },
826
+ "keepRatio": {
827
+ "default": false,
828
+ "description": "Whether to maintain aspect ratio when resizing.",
829
+ "type": "boolean"
830
+ },
831
+ "stretchEnabled": {
832
+ "default": false,
833
+ "description": "Whether stretch mode is enabled.",
834
+ "type": "boolean"
835
+ }
836
+ },
837
+ "required": [
838
+ "id",
839
+ "type"
840
+ ]
841
+ },
842
+ {
843
+ "type": "object",
844
+ "properties": {
845
+ "id": {
846
+ "type": "string",
847
+ "description": "Unique identifier for the element."
848
+ },
849
+ "type": {
850
+ "type": "string",
851
+ "const": "svg"
852
+ },
853
+ "name": {
854
+ "default": "",
855
+ "description": "Display name for the element.",
856
+ "type": "string"
857
+ },
858
+ "custom": {
859
+ "description": "Custom data attached to the element."
860
+ },
861
+ "x": {
862
+ "default": 0,
863
+ "description": "X position in pixels.",
864
+ "type": "number"
865
+ },
866
+ "y": {
867
+ "default": 0,
868
+ "description": "Y position in pixels.",
869
+ "type": "number"
870
+ },
871
+ "width": {
872
+ "default": 100,
873
+ "type": "number"
874
+ },
875
+ "height": {
876
+ "default": 100,
877
+ "type": "number"
878
+ },
879
+ "rotation": {
880
+ "default": 0,
881
+ "description": "Rotation angle in degrees.",
882
+ "type": "number"
883
+ },
884
+ "opacity": {
885
+ "default": 1,
886
+ "description": "Opacity level (0-1).",
887
+ "type": "number"
888
+ },
889
+ "animations": {
890
+ "default": [],
891
+ "description": "Animation configurations.",
892
+ "type": "array",
893
+ "items": {
894
+ "type": "object",
895
+ "properties": {
896
+ "delay": {
897
+ "default": 0,
898
+ "description": "Delay before the animation starts, in milliseconds.",
899
+ "type": "number"
900
+ },
901
+ "duration": {
902
+ "default": 500,
903
+ "description": "Animation duration in milliseconds.",
904
+ "type": "number"
905
+ },
906
+ "enabled": {
907
+ "default": true,
908
+ "description": "Whether the animation is enabled.",
909
+ "type": "boolean"
910
+ },
911
+ "type": {
912
+ "type": "string",
913
+ "enum": [
914
+ "enter",
915
+ "exit",
916
+ "loop"
917
+ ],
918
+ "description": "Animation phase."
919
+ },
920
+ "name": {
921
+ "default": "none",
922
+ "description": "Animation name identifier.",
923
+ "type": "string"
924
+ },
925
+ "data": {
926
+ "default": {},
927
+ "description": "Animation-specific data."
928
+ }
929
+ },
930
+ "required": [
931
+ "type"
932
+ ]
933
+ }
934
+ },
935
+ "blurEnabled": {
936
+ "default": false,
937
+ "description": "Whether blur effect is enabled.",
938
+ "type": "boolean"
939
+ },
940
+ "blurRadius": {
941
+ "default": 10,
942
+ "description": "Blur radius in pixels.",
943
+ "type": "number"
944
+ },
945
+ "brightnessEnabled": {
946
+ "default": false,
947
+ "description": "Whether brightness effect is enabled.",
948
+ "type": "boolean"
949
+ },
950
+ "brightness": {
951
+ "default": 0,
952
+ "description": "Brightness level (-1 to 1).",
953
+ "type": "number"
954
+ },
955
+ "sepiaEnabled": {
956
+ "default": false,
957
+ "description": "Whether sepia effect is enabled.",
958
+ "type": "boolean"
959
+ },
960
+ "grayscaleEnabled": {
961
+ "default": false,
962
+ "description": "Whether grayscale effect is enabled.",
963
+ "type": "boolean"
964
+ },
965
+ "filters": {
966
+ "default": {},
967
+ "type": "object",
968
+ "propertyNames": {
969
+ "type": "string"
970
+ },
971
+ "additionalProperties": {
972
+ "type": "object",
973
+ "properties": {
974
+ "intensity": {
975
+ "default": 1,
976
+ "description": "Filter intensity (-1 to 1).",
977
+ "type": "number"
978
+ }
979
+ }
980
+ },
981
+ "description": "Applied image filters keyed by filter name."
982
+ },
983
+ "shadowEnabled": {
984
+ "default": false,
985
+ "description": "Whether shadow is enabled.",
986
+ "type": "boolean"
987
+ },
988
+ "shadowBlur": {
989
+ "default": 5,
990
+ "description": "Shadow blur radius in pixels.",
991
+ "type": "number"
992
+ },
993
+ "shadowOffsetX": {
994
+ "default": 0,
995
+ "description": "Shadow horizontal offset in pixels.",
996
+ "type": "number"
997
+ },
998
+ "shadowOffsetY": {
999
+ "default": 0,
1000
+ "description": "Shadow vertical offset in pixels.",
1001
+ "type": "number"
1002
+ },
1003
+ "shadowColor": {
1004
+ "default": "black",
1005
+ "description": "Shadow color.",
1006
+ "type": "string"
1007
+ },
1008
+ "shadowOpacity": {
1009
+ "default": 1,
1010
+ "description": "Shadow opacity (0-1).",
1011
+ "type": "number"
1012
+ },
1013
+ "visible": {
1014
+ "default": true,
1015
+ "description": "Whether the element is visible.",
1016
+ "type": "boolean"
1017
+ },
1018
+ "draggable": {
1019
+ "default": true,
1020
+ "description": "Whether the element can be dragged.",
1021
+ "type": "boolean"
1022
+ },
1023
+ "resizable": {
1024
+ "default": true,
1025
+ "description": "Whether the element can be resized.",
1026
+ "type": "boolean"
1027
+ },
1028
+ "selectable": {
1029
+ "default": true,
1030
+ "description": "Whether the element can be selected.",
1031
+ "type": "boolean"
1032
+ },
1033
+ "removable": {
1034
+ "default": true,
1035
+ "description": "Whether the element can be removed.",
1036
+ "type": "boolean"
1037
+ },
1038
+ "contentEditable": {
1039
+ "default": true,
1040
+ "description": "Whether the element content can be edited.",
1041
+ "type": "boolean"
1042
+ },
1043
+ "styleEditable": {
1044
+ "default": true,
1045
+ "description": "Whether the element style can be edited.",
1046
+ "type": "boolean"
1047
+ },
1048
+ "alwaysOnTop": {
1049
+ "default": false,
1050
+ "description": "Whether the element stays on top of others.",
1051
+ "type": "boolean"
1052
+ },
1053
+ "showInExport": {
1054
+ "default": true,
1055
+ "description": "Whether the element appears in exports.",
1056
+ "type": "boolean"
1057
+ },
1058
+ "src": {
1059
+ "default": "",
1060
+ "description": "URL or data URI of the SVG.",
1061
+ "type": "string"
1062
+ },
1063
+ "maskSrc": {
1064
+ "default": "",
1065
+ "description": "URL or data URI for an SVG mask.",
1066
+ "type": "string"
1067
+ },
1068
+ "cropX": {
1069
+ "default": 0,
1070
+ "type": "number"
1071
+ },
1072
+ "cropY": {
1073
+ "default": 0,
1074
+ "type": "number"
1075
+ },
1076
+ "cropWidth": {
1077
+ "default": 1,
1078
+ "type": "number"
1079
+ },
1080
+ "cropHeight": {
1081
+ "default": 1,
1082
+ "type": "number"
1083
+ },
1084
+ "keepRatio": {
1085
+ "default": true,
1086
+ "type": "boolean"
1087
+ },
1088
+ "stretchEnabled": {
1089
+ "default": true,
1090
+ "type": "boolean"
1091
+ },
1092
+ "flipX": {
1093
+ "default": false,
1094
+ "type": "boolean"
1095
+ },
1096
+ "flipY": {
1097
+ "default": false,
1098
+ "type": "boolean"
1099
+ },
1100
+ "borderColor": {
1101
+ "default": "black",
1102
+ "type": "string"
1103
+ },
1104
+ "borderSize": {
1105
+ "default": 0,
1106
+ "type": "number"
1107
+ },
1108
+ "cornerRadius": {
1109
+ "default": 0,
1110
+ "type": "number"
1111
+ },
1112
+ "colorsReplace": {
1113
+ "default": {},
1114
+ "description": "Color replacement mappings (original → replacement).",
1115
+ "type": "object",
1116
+ "propertyNames": {
1117
+ "type": "string"
1118
+ },
1119
+ "additionalProperties": {
1120
+ "type": "string"
1121
+ }
1122
+ }
1123
+ },
1124
+ "required": [
1125
+ "id",
1126
+ "type"
1127
+ ]
1128
+ },
1129
+ {
1130
+ "type": "object",
1131
+ "properties": {
1132
+ "id": {
1133
+ "type": "string",
1134
+ "description": "Unique identifier for the element."
1135
+ },
1136
+ "type": {
1137
+ "type": "string",
1138
+ "const": "line"
1139
+ },
1140
+ "name": {
1141
+ "default": "",
1142
+ "description": "Display name for the element.",
1143
+ "type": "string"
1144
+ },
1145
+ "custom": {
1146
+ "description": "Custom data attached to the element."
1147
+ },
1148
+ "x": {
1149
+ "default": 0,
1150
+ "description": "X position in pixels.",
1151
+ "type": "number"
1152
+ },
1153
+ "y": {
1154
+ "default": 0,
1155
+ "description": "Y position in pixels.",
1156
+ "type": "number"
1157
+ },
1158
+ "width": {
1159
+ "default": 400,
1160
+ "type": "number"
1161
+ },
1162
+ "height": {
1163
+ "default": 10,
1164
+ "type": "number"
1165
+ },
1166
+ "rotation": {
1167
+ "default": 0,
1168
+ "description": "Rotation angle in degrees.",
1169
+ "type": "number"
1170
+ },
1171
+ "opacity": {
1172
+ "default": 1,
1173
+ "description": "Opacity level (0-1).",
1174
+ "type": "number"
1175
+ },
1176
+ "animations": {
1177
+ "default": [],
1178
+ "description": "Animation configurations.",
1179
+ "type": "array",
1180
+ "items": {
1181
+ "type": "object",
1182
+ "properties": {
1183
+ "delay": {
1184
+ "default": 0,
1185
+ "description": "Delay before the animation starts, in milliseconds.",
1186
+ "type": "number"
1187
+ },
1188
+ "duration": {
1189
+ "default": 500,
1190
+ "description": "Animation duration in milliseconds.",
1191
+ "type": "number"
1192
+ },
1193
+ "enabled": {
1194
+ "default": true,
1195
+ "description": "Whether the animation is enabled.",
1196
+ "type": "boolean"
1197
+ },
1198
+ "type": {
1199
+ "type": "string",
1200
+ "enum": [
1201
+ "enter",
1202
+ "exit",
1203
+ "loop"
1204
+ ],
1205
+ "description": "Animation phase."
1206
+ },
1207
+ "name": {
1208
+ "default": "none",
1209
+ "description": "Animation name identifier.",
1210
+ "type": "string"
1211
+ },
1212
+ "data": {
1213
+ "default": {},
1214
+ "description": "Animation-specific data."
1215
+ }
1216
+ },
1217
+ "required": [
1218
+ "type"
1219
+ ]
1220
+ }
1221
+ },
1222
+ "blurEnabled": {
1223
+ "default": false,
1224
+ "description": "Whether blur effect is enabled.",
1225
+ "type": "boolean"
1226
+ },
1227
+ "blurRadius": {
1228
+ "default": 10,
1229
+ "description": "Blur radius in pixels.",
1230
+ "type": "number"
1231
+ },
1232
+ "brightnessEnabled": {
1233
+ "default": false,
1234
+ "description": "Whether brightness effect is enabled.",
1235
+ "type": "boolean"
1236
+ },
1237
+ "brightness": {
1238
+ "default": 0,
1239
+ "description": "Brightness level (-1 to 1).",
1240
+ "type": "number"
1241
+ },
1242
+ "sepiaEnabled": {
1243
+ "default": false,
1244
+ "description": "Whether sepia effect is enabled.",
1245
+ "type": "boolean"
1246
+ },
1247
+ "grayscaleEnabled": {
1248
+ "default": false,
1249
+ "description": "Whether grayscale effect is enabled.",
1250
+ "type": "boolean"
1251
+ },
1252
+ "filters": {
1253
+ "default": {},
1254
+ "type": "object",
1255
+ "propertyNames": {
1256
+ "type": "string"
1257
+ },
1258
+ "additionalProperties": {
1259
+ "type": "object",
1260
+ "properties": {
1261
+ "intensity": {
1262
+ "default": 1,
1263
+ "description": "Filter intensity (-1 to 1).",
1264
+ "type": "number"
1265
+ }
1266
+ }
1267
+ },
1268
+ "description": "Applied image filters keyed by filter name."
1269
+ },
1270
+ "shadowEnabled": {
1271
+ "default": false,
1272
+ "description": "Whether shadow is enabled.",
1273
+ "type": "boolean"
1274
+ },
1275
+ "shadowBlur": {
1276
+ "default": 5,
1277
+ "description": "Shadow blur radius in pixels.",
1278
+ "type": "number"
1279
+ },
1280
+ "shadowOffsetX": {
1281
+ "default": 0,
1282
+ "description": "Shadow horizontal offset in pixels.",
1283
+ "type": "number"
1284
+ },
1285
+ "shadowOffsetY": {
1286
+ "default": 0,
1287
+ "description": "Shadow vertical offset in pixels.",
1288
+ "type": "number"
1289
+ },
1290
+ "shadowColor": {
1291
+ "default": "black",
1292
+ "description": "Shadow color.",
1293
+ "type": "string"
1294
+ },
1295
+ "shadowOpacity": {
1296
+ "default": 1,
1297
+ "description": "Shadow opacity (0-1).",
1298
+ "type": "number"
1299
+ },
1300
+ "visible": {
1301
+ "default": true,
1302
+ "description": "Whether the element is visible.",
1303
+ "type": "boolean"
1304
+ },
1305
+ "draggable": {
1306
+ "default": true,
1307
+ "description": "Whether the element can be dragged.",
1308
+ "type": "boolean"
1309
+ },
1310
+ "resizable": {
1311
+ "default": true,
1312
+ "description": "Whether the element can be resized.",
1313
+ "type": "boolean"
1314
+ },
1315
+ "selectable": {
1316
+ "default": true,
1317
+ "description": "Whether the element can be selected.",
1318
+ "type": "boolean"
1319
+ },
1320
+ "removable": {
1321
+ "default": true,
1322
+ "description": "Whether the element can be removed.",
1323
+ "type": "boolean"
1324
+ },
1325
+ "contentEditable": {
1326
+ "default": true,
1327
+ "description": "Whether the element content can be edited.",
1328
+ "type": "boolean"
1329
+ },
1330
+ "styleEditable": {
1331
+ "default": true,
1332
+ "description": "Whether the element style can be edited.",
1333
+ "type": "boolean"
1334
+ },
1335
+ "alwaysOnTop": {
1336
+ "default": false,
1337
+ "description": "Whether the element stays on top of others.",
1338
+ "type": "boolean"
1339
+ },
1340
+ "showInExport": {
1341
+ "default": true,
1342
+ "description": "Whether the element appears in exports.",
1343
+ "type": "boolean"
1344
+ },
1345
+ "color": {
1346
+ "default": "black",
1347
+ "description": "Line color.",
1348
+ "type": "string"
1349
+ },
1350
+ "dash": {
1351
+ "default": [],
1352
+ "description": "Dash pattern array.",
1353
+ "type": "array",
1354
+ "items": {
1355
+ "type": "number"
1356
+ }
1357
+ },
1358
+ "startHead": {
1359
+ "default": "",
1360
+ "description": "Start arrow head: empty, arrow, circle, square, bar.",
1361
+ "type": "string"
1362
+ },
1363
+ "endHead": {
1364
+ "default": "",
1365
+ "description": "End arrow head: empty, arrow, circle, square, bar.",
1366
+ "type": "string"
1367
+ }
1368
+ },
1369
+ "required": [
1370
+ "id",
1371
+ "type"
1372
+ ]
1373
+ },
1374
+ {
1375
+ "type": "object",
1376
+ "properties": {
1377
+ "id": {
1378
+ "type": "string",
1379
+ "description": "Unique identifier for the element."
1380
+ },
1381
+ "type": {
1382
+ "type": "string",
1383
+ "const": "figure"
1384
+ },
1385
+ "name": {
1386
+ "default": "",
1387
+ "description": "Display name for the element.",
1388
+ "type": "string"
1389
+ },
1390
+ "custom": {
1391
+ "description": "Custom data attached to the element."
1392
+ },
1393
+ "x": {
1394
+ "default": 0,
1395
+ "description": "X position in pixels.",
1396
+ "type": "number"
1397
+ },
1398
+ "y": {
1399
+ "default": 0,
1400
+ "description": "Y position in pixels.",
1401
+ "type": "number"
1402
+ },
1403
+ "width": {
1404
+ "default": 100,
1405
+ "description": "Width in pixels.",
1406
+ "type": "number"
1407
+ },
1408
+ "height": {
1409
+ "default": 100,
1410
+ "description": "Height in pixels.",
1411
+ "type": "number"
1412
+ },
1413
+ "rotation": {
1414
+ "default": 0,
1415
+ "description": "Rotation angle in degrees.",
1416
+ "type": "number"
1417
+ },
1418
+ "opacity": {
1419
+ "default": 1,
1420
+ "description": "Opacity level (0-1).",
1421
+ "type": "number"
1422
+ },
1423
+ "animations": {
1424
+ "default": [],
1425
+ "description": "Animation configurations.",
1426
+ "type": "array",
1427
+ "items": {
1428
+ "type": "object",
1429
+ "properties": {
1430
+ "delay": {
1431
+ "default": 0,
1432
+ "description": "Delay before the animation starts, in milliseconds.",
1433
+ "type": "number"
1434
+ },
1435
+ "duration": {
1436
+ "default": 500,
1437
+ "description": "Animation duration in milliseconds.",
1438
+ "type": "number"
1439
+ },
1440
+ "enabled": {
1441
+ "default": true,
1442
+ "description": "Whether the animation is enabled.",
1443
+ "type": "boolean"
1444
+ },
1445
+ "type": {
1446
+ "type": "string",
1447
+ "enum": [
1448
+ "enter",
1449
+ "exit",
1450
+ "loop"
1451
+ ],
1452
+ "description": "Animation phase."
1453
+ },
1454
+ "name": {
1455
+ "default": "none",
1456
+ "description": "Animation name identifier.",
1457
+ "type": "string"
1458
+ },
1459
+ "data": {
1460
+ "default": {},
1461
+ "description": "Animation-specific data."
1462
+ }
1463
+ },
1464
+ "required": [
1465
+ "type"
1466
+ ]
1467
+ }
1468
+ },
1469
+ "blurEnabled": {
1470
+ "default": false,
1471
+ "description": "Whether blur effect is enabled.",
1472
+ "type": "boolean"
1473
+ },
1474
+ "blurRadius": {
1475
+ "default": 10,
1476
+ "description": "Blur radius in pixels.",
1477
+ "type": "number"
1478
+ },
1479
+ "brightnessEnabled": {
1480
+ "default": false,
1481
+ "description": "Whether brightness effect is enabled.",
1482
+ "type": "boolean"
1483
+ },
1484
+ "brightness": {
1485
+ "default": 0,
1486
+ "description": "Brightness level (-1 to 1).",
1487
+ "type": "number"
1488
+ },
1489
+ "sepiaEnabled": {
1490
+ "default": false,
1491
+ "description": "Whether sepia effect is enabled.",
1492
+ "type": "boolean"
1493
+ },
1494
+ "grayscaleEnabled": {
1495
+ "default": false,
1496
+ "description": "Whether grayscale effect is enabled.",
1497
+ "type": "boolean"
1498
+ },
1499
+ "filters": {
1500
+ "default": {},
1501
+ "type": "object",
1502
+ "propertyNames": {
1503
+ "type": "string"
1504
+ },
1505
+ "additionalProperties": {
1506
+ "type": "object",
1507
+ "properties": {
1508
+ "intensity": {
1509
+ "default": 1,
1510
+ "description": "Filter intensity (-1 to 1).",
1511
+ "type": "number"
1512
+ }
1513
+ }
1514
+ },
1515
+ "description": "Applied image filters keyed by filter name."
1516
+ },
1517
+ "shadowEnabled": {
1518
+ "default": false,
1519
+ "description": "Whether shadow is enabled.",
1520
+ "type": "boolean"
1521
+ },
1522
+ "shadowBlur": {
1523
+ "default": 5,
1524
+ "description": "Shadow blur radius in pixels.",
1525
+ "type": "number"
1526
+ },
1527
+ "shadowOffsetX": {
1528
+ "default": 0,
1529
+ "description": "Shadow horizontal offset in pixels.",
1530
+ "type": "number"
1531
+ },
1532
+ "shadowOffsetY": {
1533
+ "default": 0,
1534
+ "description": "Shadow vertical offset in pixels.",
1535
+ "type": "number"
1536
+ },
1537
+ "shadowColor": {
1538
+ "default": "black",
1539
+ "description": "Shadow color.",
1540
+ "type": "string"
1541
+ },
1542
+ "shadowOpacity": {
1543
+ "default": 1,
1544
+ "description": "Shadow opacity (0-1).",
1545
+ "type": "number"
1546
+ },
1547
+ "visible": {
1548
+ "default": true,
1549
+ "description": "Whether the element is visible.",
1550
+ "type": "boolean"
1551
+ },
1552
+ "draggable": {
1553
+ "default": true,
1554
+ "description": "Whether the element can be dragged.",
1555
+ "type": "boolean"
1556
+ },
1557
+ "resizable": {
1558
+ "default": true,
1559
+ "description": "Whether the element can be resized.",
1560
+ "type": "boolean"
1561
+ },
1562
+ "selectable": {
1563
+ "default": true,
1564
+ "description": "Whether the element can be selected.",
1565
+ "type": "boolean"
1566
+ },
1567
+ "removable": {
1568
+ "default": true,
1569
+ "description": "Whether the element can be removed.",
1570
+ "type": "boolean"
1571
+ },
1572
+ "contentEditable": {
1573
+ "default": true,
1574
+ "description": "Whether the element content can be edited.",
1575
+ "type": "boolean"
1576
+ },
1577
+ "styleEditable": {
1578
+ "default": true,
1579
+ "description": "Whether the element style can be edited.",
1580
+ "type": "boolean"
1581
+ },
1582
+ "alwaysOnTop": {
1583
+ "default": false,
1584
+ "description": "Whether the element stays on top of others.",
1585
+ "type": "boolean"
1586
+ },
1587
+ "showInExport": {
1588
+ "default": true,
1589
+ "description": "Whether the element appears in exports.",
1590
+ "type": "boolean"
1591
+ },
1592
+ "subType": {
1593
+ "default": "rect",
1594
+ "description": "Figure subtype: rect, ellipse, triangle, etc.",
1595
+ "type": "string"
1596
+ },
1597
+ "fill": {
1598
+ "default": "rgb(0, 161, 255)",
1599
+ "description": "Fill color.",
1600
+ "type": "string"
1601
+ },
1602
+ "dash": {
1603
+ "default": [],
1604
+ "description": "Dash pattern array.",
1605
+ "type": "array",
1606
+ "items": {
1607
+ "type": "number"
1608
+ }
1609
+ },
1610
+ "strokeWidth": {
1611
+ "default": 0,
1612
+ "type": "number"
1613
+ },
1614
+ "stroke": {
1615
+ "default": "rgba(98, 197, 255, 1)",
1616
+ "type": "string"
1617
+ },
1618
+ "cornerRadius": {
1619
+ "default": 0,
1620
+ "type": "number"
1621
+ }
1622
+ },
1623
+ "required": [
1624
+ "id",
1625
+ "type"
1626
+ ]
1627
+ },
1628
+ {
1629
+ "type": "object",
1630
+ "properties": {
1631
+ "id": {
1632
+ "type": "string",
1633
+ "description": "Unique identifier for the element."
1634
+ },
1635
+ "type": {
1636
+ "type": "string",
1637
+ "const": "gif"
1638
+ },
1639
+ "name": {
1640
+ "default": "",
1641
+ "description": "Display name for the element.",
1642
+ "type": "string"
1643
+ },
1644
+ "custom": {
1645
+ "description": "Custom data attached to the element."
1646
+ },
1647
+ "x": {
1648
+ "default": 0,
1649
+ "description": "X position in pixels.",
1650
+ "type": "number"
1651
+ },
1652
+ "y": {
1653
+ "default": 0,
1654
+ "description": "Y position in pixels.",
1655
+ "type": "number"
1656
+ },
1657
+ "width": {
1658
+ "default": 100,
1659
+ "description": "Width in pixels.",
1660
+ "type": "number"
1661
+ },
1662
+ "height": {
1663
+ "default": 100,
1664
+ "description": "Height in pixels.",
1665
+ "type": "number"
1666
+ },
1667
+ "rotation": {
1668
+ "default": 0,
1669
+ "description": "Rotation angle in degrees.",
1670
+ "type": "number"
1671
+ },
1672
+ "opacity": {
1673
+ "default": 1,
1674
+ "description": "Opacity level (0-1).",
1675
+ "type": "number"
1676
+ },
1677
+ "animations": {
1678
+ "default": [],
1679
+ "description": "Animation configurations.",
1680
+ "type": "array",
1681
+ "items": {
1682
+ "type": "object",
1683
+ "properties": {
1684
+ "delay": {
1685
+ "default": 0,
1686
+ "description": "Delay before the animation starts, in milliseconds.",
1687
+ "type": "number"
1688
+ },
1689
+ "duration": {
1690
+ "default": 500,
1691
+ "description": "Animation duration in milliseconds.",
1692
+ "type": "number"
1693
+ },
1694
+ "enabled": {
1695
+ "default": true,
1696
+ "description": "Whether the animation is enabled.",
1697
+ "type": "boolean"
1698
+ },
1699
+ "type": {
1700
+ "type": "string",
1701
+ "enum": [
1702
+ "enter",
1703
+ "exit",
1704
+ "loop"
1705
+ ],
1706
+ "description": "Animation phase."
1707
+ },
1708
+ "name": {
1709
+ "default": "none",
1710
+ "description": "Animation name identifier.",
1711
+ "type": "string"
1712
+ },
1713
+ "data": {
1714
+ "default": {},
1715
+ "description": "Animation-specific data."
1716
+ }
1717
+ },
1718
+ "required": [
1719
+ "type"
1720
+ ]
1721
+ }
1722
+ },
1723
+ "blurEnabled": {
1724
+ "default": false,
1725
+ "description": "Whether blur effect is enabled.",
1726
+ "type": "boolean"
1727
+ },
1728
+ "blurRadius": {
1729
+ "default": 10,
1730
+ "description": "Blur radius in pixels.",
1731
+ "type": "number"
1732
+ },
1733
+ "brightnessEnabled": {
1734
+ "default": false,
1735
+ "description": "Whether brightness effect is enabled.",
1736
+ "type": "boolean"
1737
+ },
1738
+ "brightness": {
1739
+ "default": 0,
1740
+ "description": "Brightness level (-1 to 1).",
1741
+ "type": "number"
1742
+ },
1743
+ "sepiaEnabled": {
1744
+ "default": false,
1745
+ "description": "Whether sepia effect is enabled.",
1746
+ "type": "boolean"
1747
+ },
1748
+ "grayscaleEnabled": {
1749
+ "default": false,
1750
+ "description": "Whether grayscale effect is enabled.",
1751
+ "type": "boolean"
1752
+ },
1753
+ "filters": {
1754
+ "default": {},
1755
+ "type": "object",
1756
+ "propertyNames": {
1757
+ "type": "string"
1758
+ },
1759
+ "additionalProperties": {
1760
+ "type": "object",
1761
+ "properties": {
1762
+ "intensity": {
1763
+ "default": 1,
1764
+ "description": "Filter intensity (-1 to 1).",
1765
+ "type": "number"
1766
+ }
1767
+ }
1768
+ },
1769
+ "description": "Applied image filters keyed by filter name."
1770
+ },
1771
+ "shadowEnabled": {
1772
+ "default": false,
1773
+ "description": "Whether shadow is enabled.",
1774
+ "type": "boolean"
1775
+ },
1776
+ "shadowBlur": {
1777
+ "default": 5,
1778
+ "description": "Shadow blur radius in pixels.",
1779
+ "type": "number"
1780
+ },
1781
+ "shadowOffsetX": {
1782
+ "default": 0,
1783
+ "description": "Shadow horizontal offset in pixels.",
1784
+ "type": "number"
1785
+ },
1786
+ "shadowOffsetY": {
1787
+ "default": 0,
1788
+ "description": "Shadow vertical offset in pixels.",
1789
+ "type": "number"
1790
+ },
1791
+ "shadowColor": {
1792
+ "default": "black",
1793
+ "description": "Shadow color.",
1794
+ "type": "string"
1795
+ },
1796
+ "shadowOpacity": {
1797
+ "default": 1,
1798
+ "description": "Shadow opacity (0-1).",
1799
+ "type": "number"
1800
+ },
1801
+ "visible": {
1802
+ "default": true,
1803
+ "description": "Whether the element is visible.",
1804
+ "type": "boolean"
1805
+ },
1806
+ "draggable": {
1807
+ "default": true,
1808
+ "description": "Whether the element can be dragged.",
1809
+ "type": "boolean"
1810
+ },
1811
+ "resizable": {
1812
+ "default": true,
1813
+ "description": "Whether the element can be resized.",
1814
+ "type": "boolean"
1815
+ },
1816
+ "selectable": {
1817
+ "default": true,
1818
+ "description": "Whether the element can be selected.",
1819
+ "type": "boolean"
1820
+ },
1821
+ "removable": {
1822
+ "default": true,
1823
+ "description": "Whether the element can be removed.",
1824
+ "type": "boolean"
1825
+ },
1826
+ "contentEditable": {
1827
+ "default": true,
1828
+ "description": "Whether the element content can be edited.",
1829
+ "type": "boolean"
1830
+ },
1831
+ "styleEditable": {
1832
+ "default": true,
1833
+ "description": "Whether the element style can be edited.",
1834
+ "type": "boolean"
1835
+ },
1836
+ "alwaysOnTop": {
1837
+ "default": false,
1838
+ "description": "Whether the element stays on top of others.",
1839
+ "type": "boolean"
1840
+ },
1841
+ "showInExport": {
1842
+ "default": true,
1843
+ "description": "Whether the element appears in exports.",
1844
+ "type": "boolean"
1845
+ },
1846
+ "src": {
1847
+ "default": "",
1848
+ "description": "URL or data URI of the image file.",
1849
+ "type": "string"
1850
+ },
1851
+ "cropX": {
1852
+ "default": 0,
1853
+ "description": "Crop X offset as a fraction (0-1).",
1854
+ "type": "number"
1855
+ },
1856
+ "cropY": {
1857
+ "default": 0,
1858
+ "description": "Crop Y offset as a fraction (0-1).",
1859
+ "type": "number"
1860
+ },
1861
+ "cropWidth": {
1862
+ "default": 1,
1863
+ "description": "Crop width as a fraction (0-1).",
1864
+ "type": "number"
1865
+ },
1866
+ "cropHeight": {
1867
+ "default": 1,
1868
+ "description": "Crop height as a fraction (0-1).",
1869
+ "type": "number"
1870
+ },
1871
+ "cornerRadius": {
1872
+ "default": 0,
1873
+ "description": "Corner radius in pixels.",
1874
+ "type": "number"
1875
+ },
1876
+ "flipX": {
1877
+ "default": false,
1878
+ "description": "Whether the image is flipped horizontally.",
1879
+ "type": "boolean"
1880
+ },
1881
+ "flipY": {
1882
+ "default": false,
1883
+ "description": "Whether the image is flipped vertically.",
1884
+ "type": "boolean"
1885
+ },
1886
+ "clipSrc": {
1887
+ "default": "",
1888
+ "description": "URL or data URI for a clipping mask.",
1889
+ "type": "string"
1890
+ },
1891
+ "borderColor": {
1892
+ "default": "black",
1893
+ "description": "Border color.",
1894
+ "type": "string"
1895
+ },
1896
+ "borderSize": {
1897
+ "default": 0,
1898
+ "description": "Border width in pixels.",
1899
+ "type": "number"
1900
+ },
1901
+ "keepRatio": {
1902
+ "default": true,
1903
+ "type": "boolean"
1904
+ },
1905
+ "stretchEnabled": {
1906
+ "default": false,
1907
+ "description": "Whether stretch mode is enabled.",
1908
+ "type": "boolean"
1909
+ },
1910
+ "duration": {
1911
+ "default": 0,
1912
+ "description": "GIF duration in milliseconds.",
1913
+ "type": "number"
1914
+ }
1915
+ },
1916
+ "required": [
1917
+ "id",
1918
+ "type"
1919
+ ]
1920
+ },
1921
+ {
1922
+ "type": "object",
1923
+ "properties": {
1924
+ "id": {
1925
+ "type": "string",
1926
+ "description": "Unique identifier for the element."
1927
+ },
1928
+ "type": {
1929
+ "type": "string",
1930
+ "const": "video"
1931
+ },
1932
+ "name": {
1933
+ "default": "",
1934
+ "description": "Display name for the element.",
1935
+ "type": "string"
1936
+ },
1937
+ "custom": {
1938
+ "description": "Custom data attached to the element."
1939
+ },
1940
+ "x": {
1941
+ "default": 0,
1942
+ "description": "X position in pixels.",
1943
+ "type": "number"
1944
+ },
1945
+ "y": {
1946
+ "default": 0,
1947
+ "description": "Y position in pixels.",
1948
+ "type": "number"
1949
+ },
1950
+ "width": {
1951
+ "default": 100,
1952
+ "description": "Width in pixels.",
1953
+ "type": "number"
1954
+ },
1955
+ "height": {
1956
+ "default": 100,
1957
+ "description": "Height in pixels.",
1958
+ "type": "number"
1959
+ },
1960
+ "rotation": {
1961
+ "default": 0,
1962
+ "description": "Rotation angle in degrees.",
1963
+ "type": "number"
1964
+ },
1965
+ "opacity": {
1966
+ "default": 1,
1967
+ "description": "Opacity level (0-1).",
1968
+ "type": "number"
1969
+ },
1970
+ "animations": {
1971
+ "default": [],
1972
+ "description": "Animation configurations.",
1973
+ "type": "array",
1974
+ "items": {
1975
+ "type": "object",
1976
+ "properties": {
1977
+ "delay": {
1978
+ "default": 0,
1979
+ "description": "Delay before the animation starts, in milliseconds.",
1980
+ "type": "number"
1981
+ },
1982
+ "duration": {
1983
+ "default": 500,
1984
+ "description": "Animation duration in milliseconds.",
1985
+ "type": "number"
1986
+ },
1987
+ "enabled": {
1988
+ "default": true,
1989
+ "description": "Whether the animation is enabled.",
1990
+ "type": "boolean"
1991
+ },
1992
+ "type": {
1993
+ "type": "string",
1994
+ "enum": [
1995
+ "enter",
1996
+ "exit",
1997
+ "loop"
1998
+ ],
1999
+ "description": "Animation phase."
2000
+ },
2001
+ "name": {
2002
+ "default": "none",
2003
+ "description": "Animation name identifier.",
2004
+ "type": "string"
2005
+ },
2006
+ "data": {
2007
+ "default": {},
2008
+ "description": "Animation-specific data."
2009
+ }
2010
+ },
2011
+ "required": [
2012
+ "type"
2013
+ ]
2014
+ }
2015
+ },
2016
+ "blurEnabled": {
2017
+ "default": false,
2018
+ "description": "Whether blur effect is enabled.",
2019
+ "type": "boolean"
2020
+ },
2021
+ "blurRadius": {
2022
+ "default": 10,
2023
+ "description": "Blur radius in pixels.",
2024
+ "type": "number"
2025
+ },
2026
+ "brightnessEnabled": {
2027
+ "default": false,
2028
+ "description": "Whether brightness effect is enabled.",
2029
+ "type": "boolean"
2030
+ },
2031
+ "brightness": {
2032
+ "default": 0,
2033
+ "description": "Brightness level (-1 to 1).",
2034
+ "type": "number"
2035
+ },
2036
+ "sepiaEnabled": {
2037
+ "default": false,
2038
+ "description": "Whether sepia effect is enabled.",
2039
+ "type": "boolean"
2040
+ },
2041
+ "grayscaleEnabled": {
2042
+ "default": false,
2043
+ "description": "Whether grayscale effect is enabled.",
2044
+ "type": "boolean"
2045
+ },
2046
+ "filters": {
2047
+ "default": {},
2048
+ "type": "object",
2049
+ "propertyNames": {
2050
+ "type": "string"
2051
+ },
2052
+ "additionalProperties": {
2053
+ "type": "object",
2054
+ "properties": {
2055
+ "intensity": {
2056
+ "default": 1,
2057
+ "description": "Filter intensity (-1 to 1).",
2058
+ "type": "number"
2059
+ }
2060
+ }
2061
+ },
2062
+ "description": "Applied image filters keyed by filter name."
2063
+ },
2064
+ "shadowEnabled": {
2065
+ "default": false,
2066
+ "description": "Whether shadow is enabled.",
2067
+ "type": "boolean"
2068
+ },
2069
+ "shadowBlur": {
2070
+ "default": 5,
2071
+ "description": "Shadow blur radius in pixels.",
2072
+ "type": "number"
2073
+ },
2074
+ "shadowOffsetX": {
2075
+ "default": 0,
2076
+ "description": "Shadow horizontal offset in pixels.",
2077
+ "type": "number"
2078
+ },
2079
+ "shadowOffsetY": {
2080
+ "default": 0,
2081
+ "description": "Shadow vertical offset in pixels.",
2082
+ "type": "number"
2083
+ },
2084
+ "shadowColor": {
2085
+ "default": "black",
2086
+ "description": "Shadow color.",
2087
+ "type": "string"
2088
+ },
2089
+ "shadowOpacity": {
2090
+ "default": 1,
2091
+ "description": "Shadow opacity (0-1).",
2092
+ "type": "number"
2093
+ },
2094
+ "visible": {
2095
+ "default": true,
2096
+ "description": "Whether the element is visible.",
2097
+ "type": "boolean"
2098
+ },
2099
+ "draggable": {
2100
+ "default": true,
2101
+ "description": "Whether the element can be dragged.",
2102
+ "type": "boolean"
2103
+ },
2104
+ "resizable": {
2105
+ "default": true,
2106
+ "description": "Whether the element can be resized.",
2107
+ "type": "boolean"
2108
+ },
2109
+ "selectable": {
2110
+ "default": true,
2111
+ "description": "Whether the element can be selected.",
2112
+ "type": "boolean"
2113
+ },
2114
+ "removable": {
2115
+ "default": true,
2116
+ "description": "Whether the element can be removed.",
2117
+ "type": "boolean"
2118
+ },
2119
+ "contentEditable": {
2120
+ "default": true,
2121
+ "description": "Whether the element content can be edited.",
2122
+ "type": "boolean"
2123
+ },
2124
+ "styleEditable": {
2125
+ "default": true,
2126
+ "description": "Whether the element style can be edited.",
2127
+ "type": "boolean"
2128
+ },
2129
+ "alwaysOnTop": {
2130
+ "default": false,
2131
+ "description": "Whether the element stays on top of others.",
2132
+ "type": "boolean"
2133
+ },
2134
+ "showInExport": {
2135
+ "default": true,
2136
+ "description": "Whether the element appears in exports.",
2137
+ "type": "boolean"
2138
+ },
2139
+ "src": {
2140
+ "default": "",
2141
+ "description": "URL or data URI of the image file.",
2142
+ "type": "string"
2143
+ },
2144
+ "cropX": {
2145
+ "default": 0,
2146
+ "description": "Crop X offset as a fraction (0-1).",
2147
+ "type": "number"
2148
+ },
2149
+ "cropY": {
2150
+ "default": 0,
2151
+ "description": "Crop Y offset as a fraction (0-1).",
2152
+ "type": "number"
2153
+ },
2154
+ "cropWidth": {
2155
+ "default": 1,
2156
+ "description": "Crop width as a fraction (0-1).",
2157
+ "type": "number"
2158
+ },
2159
+ "cropHeight": {
2160
+ "default": 1,
2161
+ "description": "Crop height as a fraction (0-1).",
2162
+ "type": "number"
2163
+ },
2164
+ "cornerRadius": {
2165
+ "default": 0,
2166
+ "description": "Corner radius in pixels.",
2167
+ "type": "number"
2168
+ },
2169
+ "flipX": {
2170
+ "default": false,
2171
+ "description": "Whether the image is flipped horizontally.",
2172
+ "type": "boolean"
2173
+ },
2174
+ "flipY": {
2175
+ "default": false,
2176
+ "description": "Whether the image is flipped vertically.",
2177
+ "type": "boolean"
2178
+ },
2179
+ "clipSrc": {
2180
+ "default": "",
2181
+ "description": "URL or data URI for a clipping mask.",
2182
+ "type": "string"
2183
+ },
2184
+ "borderColor": {
2185
+ "default": "black",
2186
+ "description": "Border color.",
2187
+ "type": "string"
2188
+ },
2189
+ "borderSize": {
2190
+ "default": 0,
2191
+ "description": "Border width in pixels.",
2192
+ "type": "number"
2193
+ },
2194
+ "keepRatio": {
2195
+ "default": false,
2196
+ "description": "Whether to maintain aspect ratio when resizing.",
2197
+ "type": "boolean"
2198
+ },
2199
+ "stretchEnabled": {
2200
+ "default": false,
2201
+ "description": "Whether stretch mode is enabled.",
2202
+ "type": "boolean"
2203
+ },
2204
+ "duration": {
2205
+ "default": 0,
2206
+ "description": "Video duration in milliseconds.",
2207
+ "type": "number"
2208
+ },
2209
+ "startTime": {
2210
+ "default": 0,
2211
+ "description": "Start offset (0-1).",
2212
+ "type": "number"
2213
+ },
2214
+ "endTime": {
2215
+ "default": 1,
2216
+ "description": "End offset (0-1).",
2217
+ "type": "number"
2218
+ },
2219
+ "volume": {
2220
+ "default": 1,
2221
+ "description": "Volume (0-1).",
2222
+ "type": "number"
2223
+ },
2224
+ "speed": {
2225
+ "default": 1,
2226
+ "description": "Playback speed multiplier (1 = normal).",
2227
+ "type": "number"
2228
+ }
2229
+ },
2230
+ "required": [
2231
+ "id",
2232
+ "type"
2233
+ ]
2234
+ },
2235
+ {
2236
+ "type": "object",
2237
+ "properties": {
2238
+ "id": {
2239
+ "type": "string",
2240
+ "description": "Unique identifier for the element."
2241
+ },
2242
+ "type": {
2243
+ "type": "string",
2244
+ "const": "table"
2245
+ },
2246
+ "name": {
2247
+ "default": "",
2248
+ "description": "Display name for the element.",
2249
+ "type": "string"
2250
+ },
2251
+ "custom": {
2252
+ "description": "Custom data attached to the element."
2253
+ },
2254
+ "x": {
2255
+ "default": 0,
2256
+ "description": "X position in pixels.",
2257
+ "type": "number"
2258
+ },
2259
+ "y": {
2260
+ "default": 0,
2261
+ "description": "Y position in pixels.",
2262
+ "type": "number"
2263
+ },
2264
+ "width": {
2265
+ "default": 300,
2266
+ "type": "number"
2267
+ },
2268
+ "height": {
2269
+ "default": 200,
2270
+ "type": "number"
2271
+ },
2272
+ "rotation": {
2273
+ "default": 0,
2274
+ "description": "Rotation angle in degrees.",
2275
+ "type": "number"
2276
+ },
2277
+ "opacity": {
2278
+ "default": 1,
2279
+ "description": "Opacity level (0-1).",
2280
+ "type": "number"
2281
+ },
2282
+ "animations": {
2283
+ "default": [],
2284
+ "description": "Animation configurations.",
2285
+ "type": "array",
2286
+ "items": {
2287
+ "type": "object",
2288
+ "properties": {
2289
+ "delay": {
2290
+ "default": 0,
2291
+ "description": "Delay before the animation starts, in milliseconds.",
2292
+ "type": "number"
2293
+ },
2294
+ "duration": {
2295
+ "default": 500,
2296
+ "description": "Animation duration in milliseconds.",
2297
+ "type": "number"
2298
+ },
2299
+ "enabled": {
2300
+ "default": true,
2301
+ "description": "Whether the animation is enabled.",
2302
+ "type": "boolean"
2303
+ },
2304
+ "type": {
2305
+ "type": "string",
2306
+ "enum": [
2307
+ "enter",
2308
+ "exit",
2309
+ "loop"
2310
+ ],
2311
+ "description": "Animation phase."
2312
+ },
2313
+ "name": {
2314
+ "default": "none",
2315
+ "description": "Animation name identifier.",
2316
+ "type": "string"
2317
+ },
2318
+ "data": {
2319
+ "default": {},
2320
+ "description": "Animation-specific data."
2321
+ }
2322
+ },
2323
+ "required": [
2324
+ "type"
2325
+ ]
2326
+ }
2327
+ },
2328
+ "visible": {
2329
+ "default": true,
2330
+ "description": "Whether the element is visible.",
2331
+ "type": "boolean"
2332
+ },
2333
+ "draggable": {
2334
+ "default": true,
2335
+ "description": "Whether the element can be dragged.",
2336
+ "type": "boolean"
2337
+ },
2338
+ "resizable": {
2339
+ "default": true,
2340
+ "description": "Whether the element can be resized.",
2341
+ "type": "boolean"
2342
+ },
2343
+ "selectable": {
2344
+ "default": true,
2345
+ "description": "Whether the element can be selected.",
2346
+ "type": "boolean"
2347
+ },
2348
+ "removable": {
2349
+ "default": true,
2350
+ "description": "Whether the element can be removed.",
2351
+ "type": "boolean"
2352
+ },
2353
+ "contentEditable": {
2354
+ "default": true,
2355
+ "description": "Whether the element content can be edited.",
2356
+ "type": "boolean"
2357
+ },
2358
+ "styleEditable": {
2359
+ "default": true,
2360
+ "description": "Whether the element style can be edited.",
2361
+ "type": "boolean"
2362
+ },
2363
+ "alwaysOnTop": {
2364
+ "default": false,
2365
+ "description": "Whether the element stays on top of others.",
2366
+ "type": "boolean"
2367
+ },
2368
+ "showInExport": {
2369
+ "default": true,
2370
+ "description": "Whether the element appears in exports.",
2371
+ "type": "boolean"
2372
+ },
2373
+ "rows": {
2374
+ "default": 3,
2375
+ "description": "Number of rows.",
2376
+ "type": "number"
2377
+ },
2378
+ "cols": {
2379
+ "default": 3,
2380
+ "description": "Number of columns.",
2381
+ "type": "number"
2382
+ },
2383
+ "colWidths": {
2384
+ "default": [],
2385
+ "description": "Column width fractions (sum to 1).",
2386
+ "type": "array",
2387
+ "items": {
2388
+ "type": "number"
2389
+ }
2390
+ },
2391
+ "rowHeights": {
2392
+ "default": [],
2393
+ "description": "Row height fractions (sum to 1).",
2394
+ "type": "array",
2395
+ "items": {
2396
+ "type": "number"
2397
+ }
2398
+ },
2399
+ "cells": {
2400
+ "default": [],
2401
+ "description": "Flat cell array in row-major order.",
2402
+ "type": "array",
2403
+ "items": {
2404
+ "type": "object",
2405
+ "properties": {
2406
+ "id": {
2407
+ "type": "string"
2408
+ },
2409
+ "type": {
2410
+ "default": "tablecell",
2411
+ "type": "string",
2412
+ "const": "tablecell"
2413
+ },
2414
+ "text": {
2415
+ "default": "",
2416
+ "type": "string"
2417
+ },
2418
+ "opacity": {
2419
+ "type": "number"
2420
+ },
2421
+ "rowSpan": {
2422
+ "type": "number"
2423
+ },
2424
+ "colSpan": {
2425
+ "type": "number"
2426
+ },
2427
+ "mergedInto": {
2428
+ "type": "string"
2429
+ },
2430
+ "name": {
2431
+ "type": "string"
2432
+ },
2433
+ "custom": {},
2434
+ "borders": {
2435
+ "type": "object",
2436
+ "properties": {
2437
+ "top": {
2438
+ "type": "object",
2439
+ "properties": {
2440
+ "color": {
2441
+ "type": "string"
2442
+ },
2443
+ "width": {
2444
+ "type": "number"
2445
+ },
2446
+ "style": {
2447
+ "type": "string",
2448
+ "enum": [
2449
+ "solid",
2450
+ "dashed",
2451
+ "dotted",
2452
+ "none"
2453
+ ]
2454
+ }
2455
+ }
2456
+ },
2457
+ "right": {
2458
+ "type": "object",
2459
+ "properties": {
2460
+ "color": {
2461
+ "type": "string"
2462
+ },
2463
+ "width": {
2464
+ "type": "number"
2465
+ },
2466
+ "style": {
2467
+ "type": "string",
2468
+ "enum": [
2469
+ "solid",
2470
+ "dashed",
2471
+ "dotted",
2472
+ "none"
2473
+ ]
2474
+ }
2475
+ }
2476
+ },
2477
+ "bottom": {
2478
+ "type": "object",
2479
+ "properties": {
2480
+ "color": {
2481
+ "type": "string"
2482
+ },
2483
+ "width": {
2484
+ "type": "number"
2485
+ },
2486
+ "style": {
2487
+ "type": "string",
2488
+ "enum": [
2489
+ "solid",
2490
+ "dashed",
2491
+ "dotted",
2492
+ "none"
2493
+ ]
2494
+ }
2495
+ }
2496
+ },
2497
+ "left": {
2498
+ "type": "object",
2499
+ "properties": {
2500
+ "color": {
2501
+ "type": "string"
2502
+ },
2503
+ "width": {
2504
+ "type": "number"
2505
+ },
2506
+ "style": {
2507
+ "type": "string",
2508
+ "enum": [
2509
+ "solid",
2510
+ "dashed",
2511
+ "dotted",
2512
+ "none"
2513
+ ]
2514
+ }
2515
+ }
2516
+ }
2517
+ }
2518
+ },
2519
+ "fontSize": {
2520
+ "type": "number"
2521
+ },
2522
+ "fontFamily": {
2523
+ "type": "string"
2524
+ },
2525
+ "fontWeight": {
2526
+ "type": "string"
2527
+ },
2528
+ "fontStyle": {
2529
+ "type": "string"
2530
+ },
2531
+ "textDecoration": {
2532
+ "type": "string"
2533
+ },
2534
+ "textTransform": {
2535
+ "type": "string"
2536
+ },
2537
+ "fill": {
2538
+ "type": "string"
2539
+ },
2540
+ "align": {
2541
+ "type": "string"
2542
+ },
2543
+ "verticalAlign": {
2544
+ "type": "string"
2545
+ },
2546
+ "lineHeight": {
2547
+ "anyOf": [
2548
+ {
2549
+ "type": "number"
2550
+ },
2551
+ {
2552
+ "type": "string"
2553
+ }
2554
+ ]
2555
+ },
2556
+ "letterSpacing": {
2557
+ "type": "number"
2558
+ },
2559
+ "strokeWidth": {
2560
+ "type": "number"
2561
+ },
2562
+ "stroke": {
2563
+ "type": "string"
2564
+ },
2565
+ "cellBackground": {
2566
+ "type": "string"
2567
+ },
2568
+ "cellPadding": {
2569
+ "type": "number"
2570
+ }
2571
+ },
2572
+ "required": [
2573
+ "id"
2574
+ ]
2575
+ }
2576
+ },
2577
+ "borderColor": {
2578
+ "default": "#000000",
2579
+ "type": "string"
2580
+ },
2581
+ "borderWidth": {
2582
+ "default": 1,
2583
+ "type": "number"
2584
+ },
2585
+ "borderStyle": {
2586
+ "default": "solid",
2587
+ "type": "string",
2588
+ "enum": [
2589
+ "solid",
2590
+ "dashed",
2591
+ "dotted",
2592
+ "none"
2593
+ ]
2594
+ },
2595
+ "fontSize": {
2596
+ "default": 30,
2597
+ "type": "number"
2598
+ },
2599
+ "fontFamily": {
2600
+ "default": "Roboto",
2601
+ "type": "string"
2602
+ },
2603
+ "fontWeight": {
2604
+ "default": "normal",
2605
+ "type": "string"
2606
+ },
2607
+ "fontStyle": {
2608
+ "default": "normal",
2609
+ "type": "string"
2610
+ },
2611
+ "textDecoration": {
2612
+ "default": "",
2613
+ "type": "string"
2614
+ },
2615
+ "textTransform": {
2616
+ "default": "none",
2617
+ "type": "string"
2618
+ },
2619
+ "fill": {
2620
+ "default": "black",
2621
+ "type": "string"
2622
+ },
2623
+ "align": {
2624
+ "default": "center",
2625
+ "type": "string"
2626
+ },
2627
+ "verticalAlign": {
2628
+ "default": "middle",
2629
+ "type": "string"
2630
+ },
2631
+ "lineHeight": {
2632
+ "default": 1.2,
2633
+ "anyOf": [
2634
+ {
2635
+ "type": "number"
2636
+ },
2637
+ {
2638
+ "type": "string"
2639
+ }
2640
+ ]
2641
+ },
2642
+ "letterSpacing": {
2643
+ "default": 0,
2644
+ "type": "number"
2645
+ },
2646
+ "strokeWidth": {
2647
+ "default": 0,
2648
+ "type": "number"
2649
+ },
2650
+ "stroke": {
2651
+ "default": "black",
2652
+ "type": "string"
2653
+ },
2654
+ "cellBackground": {
2655
+ "default": "transparent",
2656
+ "type": "string"
2657
+ },
2658
+ "cellPadding": {
2659
+ "default": 4,
2660
+ "type": "number"
2661
+ }
2662
+ },
2663
+ "required": [
2664
+ "id",
2665
+ "type"
2666
+ ]
2667
+ },
2668
+ {
2669
+ "type": "object",
2670
+ "properties": {
2671
+ "id": {
2672
+ "type": "string"
2673
+ },
2674
+ "type": {
2675
+ "type": "string",
2676
+ "const": "group"
2677
+ },
2678
+ "name": {
2679
+ "default": "",
2680
+ "type": "string"
2681
+ },
2682
+ "custom": {},
2683
+ "opacity": {
2684
+ "default": 1,
2685
+ "type": "number"
2686
+ },
2687
+ "visible": {
2688
+ "default": true,
2689
+ "type": "boolean"
2690
+ },
2691
+ "selectable": {
2692
+ "default": true,
2693
+ "type": "boolean"
2694
+ },
2695
+ "removable": {
2696
+ "default": true,
2697
+ "type": "boolean"
2698
+ },
2699
+ "alwaysOnTop": {
2700
+ "default": false,
2701
+ "type": "boolean"
2702
+ },
2703
+ "showInExport": {
2704
+ "default": true,
2705
+ "type": "boolean"
2706
+ },
2707
+ "animations": {
2708
+ "default": [],
2709
+ "type": "array",
2710
+ "items": {
2711
+ "type": "object",
2712
+ "properties": {
2713
+ "delay": {
2714
+ "default": 0,
2715
+ "description": "Delay before the animation starts, in milliseconds.",
2716
+ "type": "number"
2717
+ },
2718
+ "duration": {
2719
+ "default": 500,
2720
+ "description": "Animation duration in milliseconds.",
2721
+ "type": "number"
2722
+ },
2723
+ "enabled": {
2724
+ "default": true,
2725
+ "description": "Whether the animation is enabled.",
2726
+ "type": "boolean"
2727
+ },
2728
+ "type": {
2729
+ "type": "string",
2730
+ "enum": [
2731
+ "enter",
2732
+ "exit",
2733
+ "loop"
2734
+ ],
2735
+ "description": "Animation phase."
2736
+ },
2737
+ "name": {
2738
+ "default": "none",
2739
+ "description": "Animation name identifier.",
2740
+ "type": "string"
2741
+ },
2742
+ "data": {
2743
+ "default": {},
2744
+ "description": "Animation-specific data."
2745
+ }
2746
+ },
2747
+ "required": [
2748
+ "type"
2749
+ ]
2750
+ }
2751
+ },
2752
+ "children": {
2753
+ "default": [],
2754
+ "description": "Child elements in this group.",
2755
+ "type": "array",
2756
+ "items": {
2757
+ "$ref": "#/$defs/__schema0"
2758
+ }
2759
+ }
2760
+ },
2761
+ "required": [
2762
+ "id",
2763
+ "type"
2764
+ ]
2765
+ }
2766
+ ]
2767
+ }
2768
+ },
2769
+ "$id": "https://schema.polotno.com/v1/design.schema.json",
2770
+ "title": "Polotno Design"
2771
+ }