@asteby/metacore-genui 2.0.0 → 2.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.
@@ -0,0 +1,2741 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://schemas.asteby.dev/metacore/genui-v2.schema.json",
4
+ "title": "genui/v2",
5
+ "description": "Contrato declarativo de UI genui/v2 (ADR 0001 del SDK). Fuente única del contrato: de aquí salen los tipos TS; el kernel Go copia este archivo (packages/genui/conformance/README.md). Las reglas que el esquema no expresa (límites globales, unicidad de id, gramática de $ref, enlaces seguros, destino de open) viven en el validador.",
6
+ "type": "object",
7
+ "additionalProperties": false,
8
+ "required": [
9
+ "version",
10
+ "blocks"
11
+ ],
12
+ "properties": {
13
+ "version": {
14
+ "const": "genui/v2"
15
+ },
16
+ "title": {
17
+ "$ref": "#/$defs/label"
18
+ },
19
+ "i18n": {
20
+ "enum": [
21
+ "keys",
22
+ "literal"
23
+ ],
24
+ "default": "literal"
25
+ },
26
+ "data": {
27
+ "type": "object",
28
+ "maxProperties": 8,
29
+ "propertyNames": {
30
+ "pattern": "^[A-Za-z_][A-Za-z0-9_]{0,63}$"
31
+ },
32
+ "additionalProperties": {
33
+ "$ref": "#/$defs/dataSource"
34
+ }
35
+ },
36
+ "state": {
37
+ "type": "object",
38
+ "maxProperties": 32,
39
+ "propertyNames": {
40
+ "pattern": "^[A-Za-z_][A-Za-z0-9_]{0,63}$"
41
+ },
42
+ "additionalProperties": {
43
+ "$ref": "#/$defs/stateValue"
44
+ },
45
+ "description": "Estado local: escalares, listas de escalares y objetos de escalares o listas de escalares."
46
+ },
47
+ "overlays": {
48
+ "type": "object",
49
+ "maxProperties": 4,
50
+ "propertyNames": {
51
+ "pattern": "^[A-Za-z][A-Za-z0-9_-]{0,63}$"
52
+ },
53
+ "additionalProperties": {
54
+ "$ref": "#/$defs/overlay"
55
+ }
56
+ },
57
+ "blocks": {
58
+ "type": "array",
59
+ "items": {
60
+ "$ref": "#/$defs/block"
61
+ },
62
+ "maxItems": 24,
63
+ "minItems": 1
64
+ }
65
+ },
66
+ "$defs": {
67
+ "tone": {
68
+ "enum": [
69
+ "default",
70
+ "muted",
71
+ "info",
72
+ "success",
73
+ "warning",
74
+ "danger"
75
+ ],
76
+ "description": "Vocabulario de tono compartido (Tone)."
77
+ },
78
+ "statFormat": {
79
+ "enum": [
80
+ "number",
81
+ "currency",
82
+ "percent",
83
+ "compact",
84
+ "date",
85
+ "datetime",
86
+ "relative_date"
87
+ ],
88
+ "description": "StatFormat (superconjunto de WidgetFormat)."
89
+ },
90
+ "fieldKind": {
91
+ "enum": [
92
+ "text",
93
+ "textarea",
94
+ "number",
95
+ "integer",
96
+ "email",
97
+ "url",
98
+ "phone",
99
+ "date",
100
+ "datetime",
101
+ "time",
102
+ "boolean",
103
+ "switch",
104
+ "select",
105
+ "multiselect",
106
+ "search"
107
+ ],
108
+ "description": "Tipos de campo (field.kind)."
109
+ },
110
+ "widgetSize": {
111
+ "enum": [
112
+ "sm",
113
+ "md",
114
+ "lg",
115
+ "full"
116
+ ]
117
+ },
118
+ "scalar": {
119
+ "type": [
120
+ "string",
121
+ "number",
122
+ "boolean",
123
+ "null"
124
+ ],
125
+ "maxLength": 2000,
126
+ "description": "Escalar; las cadenas, de hasta 2 000 puntos de código."
127
+ },
128
+ "id": {
129
+ "type": "string",
130
+ "pattern": "^[A-Za-z][A-Za-z0-9_-]{0,63}$",
131
+ "description": "Identificador único dentro del documento."
132
+ },
133
+ "key": {
134
+ "type": "string",
135
+ "pattern": "^(?!(?:.*\\.)?(?:__proto__|constructor|prototype)(?:\\.|$))[A-Za-z_][A-Za-z0-9_.]{0,63}$",
136
+ "x-no-proto": true,
137
+ "description": "Clave de campo, columna o entrada; ningún segmento separado por punto puede ser __proto__, constructor ni prototype."
138
+ },
139
+ "bindingPath": {
140
+ "type": "string",
141
+ "pattern": "^(?!(?:.*\\.)?(?:__proto__|constructor|prototype)(?:\\.|$))(data|state|record|ctx)(\\.[A-Za-z_][A-Za-z0-9_]{0,63}|\\.[0-9]{1,3}){1,6}$",
142
+ "x-no-proto": true,
143
+ "description": "Ruta de vinculación; raíces cerradas data|state|record|ctx. Ningún segmento puede ser __proto__, constructor ni prototype."
144
+ },
145
+ "ref": {
146
+ "type": "object",
147
+ "additionalProperties": false,
148
+ "required": [
149
+ "$ref"
150
+ ],
151
+ "properties": {
152
+ "$ref": {
153
+ "$ref": "#/$defs/bindingPath"
154
+ }
155
+ },
156
+ "description": "Vinculación {\"$ref\": \"<raíz>.<ruta>\"} en posiciones de valor."
157
+ },
158
+ "tref": {
159
+ "type": "object",
160
+ "additionalProperties": false,
161
+ "required": [
162
+ "$t"
163
+ ],
164
+ "properties": {
165
+ "$t": {
166
+ "type": "string",
167
+ "pattern": "^[A-Za-z0-9_.:-]{1,128}$"
168
+ },
169
+ "args": {
170
+ "type": "object",
171
+ "maxProperties": 8,
172
+ "additionalProperties": {
173
+ "anyOf": [
174
+ {
175
+ "type": [
176
+ "string",
177
+ "number",
178
+ "boolean"
179
+ ],
180
+ "maxLength": 2000
181
+ },
182
+ {
183
+ "$ref": "#/$defs/ref"
184
+ }
185
+ ]
186
+ }
187
+ }
188
+ },
189
+ "description": "Clave i18n con argumentos insertados como texto."
190
+ },
191
+ "text": {
192
+ "anyOf": [
193
+ {
194
+ "type": "string",
195
+ "maxLength": 2000
196
+ },
197
+ {
198
+ "$ref": "#/$defs/tref"
199
+ },
200
+ {
201
+ "$ref": "#/$defs/ref"
202
+ }
203
+ ],
204
+ "description": "Texto visible: literal, clave i18n o vinculación."
205
+ },
206
+ "label": {
207
+ "anyOf": [
208
+ {
209
+ "type": "string",
210
+ "maxLength": 160
211
+ },
212
+ {
213
+ "$ref": "#/$defs/tref"
214
+ },
215
+ {
216
+ "$ref": "#/$defs/ref"
217
+ }
218
+ ]
219
+ },
220
+ "value": {
221
+ "anyOf": [
222
+ {
223
+ "$ref": "#/$defs/scalar"
224
+ },
225
+ {
226
+ "$ref": "#/$defs/ref"
227
+ }
228
+ ],
229
+ "description": "Valor: escalar o vinculación."
230
+ },
231
+ "link": {
232
+ "type": "string",
233
+ "maxLength": 2048,
234
+ "pattern": "^(/(?!/)[^\\\\\\n\\r\\t]*|https?://[^\\s\\\\]+)$",
235
+ "x-error": "genui.unsafe_link",
236
+ "description": "Ruta relativa de la app o http(s) literal; nunca $ref. Los externos solo con allowExternalLinks."
237
+ },
238
+ "appPath": {
239
+ "type": "string",
240
+ "maxLength": 2048,
241
+ "pattern": "^/(?!/)[^\\\\\\n\\r\\t]*$",
242
+ "x-error": "genui.unsafe_link",
243
+ "description": "Ruta de la app (nunca http)."
244
+ },
245
+ "name": {
246
+ "type": "string",
247
+ "pattern": "^[A-Za-z_][A-Za-z0-9_]{0,63}$"
248
+ },
249
+ "predicate": {
250
+ "type": "object",
251
+ "additionalProperties": false,
252
+ "required": [
253
+ "ref"
254
+ ],
255
+ "minProperties": 2,
256
+ "properties": {
257
+ "ref": {
258
+ "$ref": "#/$defs/bindingPath"
259
+ },
260
+ "equals": {
261
+ "$ref": "#/$defs/scalar"
262
+ },
263
+ "in": {
264
+ "type": "array",
265
+ "items": {
266
+ "$ref": "#/$defs/scalar"
267
+ },
268
+ "maxItems": 50
269
+ },
270
+ "not_in": {
271
+ "type": "array",
272
+ "items": {
273
+ "$ref": "#/$defs/scalar"
274
+ },
275
+ "maxItems": 50
276
+ },
277
+ "empty": {
278
+ "type": "boolean"
279
+ }
280
+ },
281
+ "description": "Condición when (forma de VisibleWhen ampliada a cualquier raíz)."
282
+ },
283
+ "badge": {
284
+ "type": "object",
285
+ "additionalProperties": false,
286
+ "required": [
287
+ "label"
288
+ ],
289
+ "properties": {
290
+ "label": {
291
+ "type": "string",
292
+ "maxLength": 60
293
+ },
294
+ "tone": {
295
+ "$ref": "#/$defs/tone"
296
+ }
297
+ }
298
+ },
299
+ "field": {
300
+ "type": "object",
301
+ "additionalProperties": false,
302
+ "required": [
303
+ "label"
304
+ ],
305
+ "properties": {
306
+ "label": {
307
+ "$ref": "#/$defs/label"
308
+ },
309
+ "value": {
310
+ "$ref": "#/$defs/text"
311
+ },
312
+ "copy": {
313
+ "type": "boolean"
314
+ }
315
+ }
316
+ },
317
+ "option": {
318
+ "type": "object",
319
+ "additionalProperties": false,
320
+ "required": [
321
+ "value",
322
+ "label"
323
+ ],
324
+ "properties": {
325
+ "value": {
326
+ "type": "string",
327
+ "maxLength": 160
328
+ },
329
+ "label": {
330
+ "$ref": "#/$defs/label"
331
+ }
332
+ }
333
+ },
334
+ "column": {
335
+ "type": "object",
336
+ "additionalProperties": false,
337
+ "required": [
338
+ "key",
339
+ "label"
340
+ ],
341
+ "properties": {
342
+ "key": {
343
+ "$ref": "#/$defs/key"
344
+ },
345
+ "label": {
346
+ "$ref": "#/$defs/label"
347
+ },
348
+ "format": {
349
+ "$ref": "#/$defs/statFormat"
350
+ }
351
+ }
352
+ },
353
+ "stateList": {
354
+ "type": "array",
355
+ "items": {
356
+ "$ref": "#/$defs/scalar"
357
+ },
358
+ "maxItems": 50
359
+ },
360
+ "stateValue": {
361
+ "anyOf": [
362
+ {
363
+ "$ref": "#/$defs/scalar"
364
+ },
365
+ {
366
+ "$ref": "#/$defs/stateList"
367
+ },
368
+ {
369
+ "type": "object",
370
+ "maxProperties": 16,
371
+ "propertyNames": {
372
+ "pattern": "^[A-Za-z_][A-Za-z0-9_]{0,63}$"
373
+ },
374
+ "additionalProperties": {
375
+ "anyOf": [
376
+ {
377
+ "$ref": "#/$defs/scalar"
378
+ },
379
+ {
380
+ "$ref": "#/$defs/stateList"
381
+ }
382
+ ]
383
+ }
384
+ }
385
+ ]
386
+ },
387
+ "row": {
388
+ "type": "object",
389
+ "maxProperties": 24,
390
+ "propertyNames": {
391
+ "pattern": "^[A-Za-z_][A-Za-z0-9_.]{0,63}$"
392
+ },
393
+ "additionalProperties": {
394
+ "$ref": "#/$defs/value"
395
+ }
396
+ },
397
+ "item": {
398
+ "type": "object",
399
+ "additionalProperties": false,
400
+ "properties": {
401
+ "label": {
402
+ "$ref": "#/$defs/label"
403
+ },
404
+ "value": {
405
+ "$ref": "#/$defs/text"
406
+ },
407
+ "hint": {
408
+ "$ref": "#/$defs/label"
409
+ },
410
+ "trend": {
411
+ "enum": [
412
+ "up",
413
+ "down",
414
+ "flat"
415
+ ]
416
+ },
417
+ "title": {
418
+ "$ref": "#/$defs/label"
419
+ },
420
+ "url": {
421
+ "$ref": "#/$defs/link"
422
+ },
423
+ "source": {
424
+ "$ref": "#/$defs/label"
425
+ },
426
+ "date": {
427
+ "type": "string",
428
+ "maxLength": 160
429
+ },
430
+ "time": {
431
+ "type": "string",
432
+ "maxLength": 160
433
+ },
434
+ "description": {
435
+ "$ref": "#/$defs/text"
436
+ },
437
+ "status": {
438
+ "type": "string",
439
+ "maxLength": 160
440
+ },
441
+ "tone": {
442
+ "$ref": "#/$defs/tone"
443
+ },
444
+ "format": {
445
+ "$ref": "#/$defs/statFormat"
446
+ }
447
+ }
448
+ },
449
+ "route": {
450
+ "type": "object",
451
+ "additionalProperties": false,
452
+ "minProperties": 1,
453
+ "properties": {
454
+ "name": {
455
+ "enum": [
456
+ "record",
457
+ "list",
458
+ "page"
459
+ ]
460
+ },
461
+ "model": {
462
+ "$ref": "#/$defs/key"
463
+ },
464
+ "id": {
465
+ "$ref": "#/$defs/value"
466
+ },
467
+ "filters": {
468
+ "type": "object",
469
+ "maxProperties": 8,
470
+ "additionalProperties": {
471
+ "$ref": "#/$defs/scalar"
472
+ }
473
+ },
474
+ "key": {
475
+ "$ref": "#/$defs/key"
476
+ },
477
+ "path": {
478
+ "$ref": "#/$defs/appPath"
479
+ }
480
+ },
481
+ "description": "path o name; los requeridos por name se validan en código."
482
+ },
483
+ "action": {
484
+ "x-discriminator": "do",
485
+ "description": "Acción declarativa {do, ...}; un esquema por verbo.",
486
+ "oneOf": [
487
+ {
488
+ "$ref": "#/$defs/action_navigate"
489
+ },
490
+ {
491
+ "$ref": "#/$defs/action_invoke"
492
+ },
493
+ {
494
+ "$ref": "#/$defs/action_submit"
495
+ },
496
+ {
497
+ "$ref": "#/$defs/action_open"
498
+ },
499
+ {
500
+ "$ref": "#/$defs/action_close"
501
+ },
502
+ {
503
+ "$ref": "#/$defs/action_set"
504
+ },
505
+ {
506
+ "$ref": "#/$defs/action_refresh"
507
+ },
508
+ {
509
+ "$ref": "#/$defs/action_emit"
510
+ }
511
+ ]
512
+ },
513
+ "action_navigate": {
514
+ "type": "object",
515
+ "additionalProperties": false,
516
+ "required": [
517
+ "do",
518
+ "route"
519
+ ],
520
+ "properties": {
521
+ "do": {
522
+ "const": "navigate"
523
+ },
524
+ "label": {
525
+ "$ref": "#/$defs/label"
526
+ },
527
+ "variant": {
528
+ "enum": [
529
+ "primary",
530
+ "secondary",
531
+ "ghost",
532
+ "danger"
533
+ ]
534
+ },
535
+ "icon": {
536
+ "type": "string",
537
+ "pattern": "^[a-z][a-z0-9-]{0,63}$"
538
+ },
539
+ "confirm": {
540
+ "type": "object",
541
+ "additionalProperties": false,
542
+ "properties": {
543
+ "title": {
544
+ "$ref": "#/$defs/label"
545
+ },
546
+ "body": {
547
+ "$ref": "#/$defs/text"
548
+ },
549
+ "tone": {
550
+ "$ref": "#/$defs/tone"
551
+ },
552
+ "require_text": {
553
+ "type": "string",
554
+ "maxLength": 60
555
+ }
556
+ }
557
+ },
558
+ "when": {
559
+ "$ref": "#/$defs/predicate"
560
+ },
561
+ "route": {
562
+ "$ref": "#/$defs/route"
563
+ }
564
+ }
565
+ },
566
+ "action_invoke": {
567
+ "type": "object",
568
+ "additionalProperties": false,
569
+ "required": [
570
+ "do",
571
+ "action"
572
+ ],
573
+ "properties": {
574
+ "do": {
575
+ "const": "invoke"
576
+ },
577
+ "label": {
578
+ "$ref": "#/$defs/label"
579
+ },
580
+ "variant": {
581
+ "enum": [
582
+ "primary",
583
+ "secondary",
584
+ "ghost",
585
+ "danger"
586
+ ]
587
+ },
588
+ "icon": {
589
+ "type": "string",
590
+ "pattern": "^[a-z][a-z0-9-]{0,63}$"
591
+ },
592
+ "confirm": {
593
+ "type": "object",
594
+ "additionalProperties": false,
595
+ "properties": {
596
+ "title": {
597
+ "$ref": "#/$defs/label"
598
+ },
599
+ "body": {
600
+ "$ref": "#/$defs/text"
601
+ },
602
+ "tone": {
603
+ "$ref": "#/$defs/tone"
604
+ },
605
+ "require_text": {
606
+ "type": "string",
607
+ "maxLength": 60
608
+ }
609
+ }
610
+ },
611
+ "when": {
612
+ "$ref": "#/$defs/predicate"
613
+ },
614
+ "action": {
615
+ "type": "string",
616
+ "pattern": "^[a-z][a-z0-9_]*(\\.[A-Za-z][A-Za-z0-9_]*){1,3}$",
617
+ "description": "Acción del manifest <addon>.<Model>.<key>."
618
+ },
619
+ "record": {
620
+ "$ref": "#/$defs/value"
621
+ },
622
+ "params": {
623
+ "type": "object",
624
+ "maxProperties": 8,
625
+ "additionalProperties": {
626
+ "$ref": "#/$defs/value"
627
+ }
628
+ },
629
+ "values": {
630
+ "type": "object",
631
+ "maxProperties": 40,
632
+ "additionalProperties": {
633
+ "$ref": "#/$defs/value"
634
+ }
635
+ }
636
+ }
637
+ },
638
+ "action_submit": {
639
+ "properties": {
640
+ "do": {
641
+ "const": "submit"
642
+ }
643
+ },
644
+ "x-discriminator": "to",
645
+ "oneOf": [
646
+ {
647
+ "$ref": "#/$defs/action_submit_invoke"
648
+ },
649
+ {
650
+ "$ref": "#/$defs/action_submit_settings"
651
+ },
652
+ {
653
+ "$ref": "#/$defs/action_submit_create"
654
+ },
655
+ {
656
+ "$ref": "#/$defs/action_submit_update"
657
+ }
658
+ ]
659
+ },
660
+ "action_submit_invoke": {
661
+ "type": "object",
662
+ "additionalProperties": false,
663
+ "required": [
664
+ "do",
665
+ "to",
666
+ "form",
667
+ "action"
668
+ ],
669
+ "properties": {
670
+ "do": {
671
+ "const": "submit"
672
+ },
673
+ "label": {
674
+ "$ref": "#/$defs/label"
675
+ },
676
+ "variant": {
677
+ "enum": [
678
+ "primary",
679
+ "secondary",
680
+ "ghost",
681
+ "danger"
682
+ ]
683
+ },
684
+ "icon": {
685
+ "type": "string",
686
+ "pattern": "^[a-z][a-z0-9-]{0,63}$"
687
+ },
688
+ "confirm": {
689
+ "type": "object",
690
+ "additionalProperties": false,
691
+ "properties": {
692
+ "title": {
693
+ "$ref": "#/$defs/label"
694
+ },
695
+ "body": {
696
+ "$ref": "#/$defs/text"
697
+ },
698
+ "tone": {
699
+ "$ref": "#/$defs/tone"
700
+ },
701
+ "require_text": {
702
+ "type": "string",
703
+ "maxLength": 60
704
+ }
705
+ }
706
+ },
707
+ "when": {
708
+ "$ref": "#/$defs/predicate"
709
+ },
710
+ "to": {
711
+ "const": "invoke"
712
+ },
713
+ "form": {
714
+ "$ref": "#/$defs/id"
715
+ },
716
+ "action": {
717
+ "type": "string",
718
+ "pattern": "^[a-z][a-z0-9_]*(\\.[A-Za-z][A-Za-z0-9_]*){1,3}$"
719
+ }
720
+ }
721
+ },
722
+ "action_submit_settings": {
723
+ "type": "object",
724
+ "additionalProperties": false,
725
+ "required": [
726
+ "do",
727
+ "to",
728
+ "form"
729
+ ],
730
+ "properties": {
731
+ "do": {
732
+ "const": "submit"
733
+ },
734
+ "label": {
735
+ "$ref": "#/$defs/label"
736
+ },
737
+ "variant": {
738
+ "enum": [
739
+ "primary",
740
+ "secondary",
741
+ "ghost",
742
+ "danger"
743
+ ]
744
+ },
745
+ "icon": {
746
+ "type": "string",
747
+ "pattern": "^[a-z][a-z0-9-]{0,63}$"
748
+ },
749
+ "confirm": {
750
+ "type": "object",
751
+ "additionalProperties": false,
752
+ "properties": {
753
+ "title": {
754
+ "$ref": "#/$defs/label"
755
+ },
756
+ "body": {
757
+ "$ref": "#/$defs/text"
758
+ },
759
+ "tone": {
760
+ "$ref": "#/$defs/tone"
761
+ },
762
+ "require_text": {
763
+ "type": "string",
764
+ "maxLength": 60
765
+ }
766
+ }
767
+ },
768
+ "when": {
769
+ "$ref": "#/$defs/predicate"
770
+ },
771
+ "to": {
772
+ "const": "settings.write"
773
+ },
774
+ "form": {
775
+ "$ref": "#/$defs/id"
776
+ }
777
+ }
778
+ },
779
+ "action_submit_create": {
780
+ "type": "object",
781
+ "additionalProperties": false,
782
+ "required": [
783
+ "do",
784
+ "to",
785
+ "form",
786
+ "model"
787
+ ],
788
+ "properties": {
789
+ "do": {
790
+ "const": "submit"
791
+ },
792
+ "label": {
793
+ "$ref": "#/$defs/label"
794
+ },
795
+ "variant": {
796
+ "enum": [
797
+ "primary",
798
+ "secondary",
799
+ "ghost",
800
+ "danger"
801
+ ]
802
+ },
803
+ "icon": {
804
+ "type": "string",
805
+ "pattern": "^[a-z][a-z0-9-]{0,63}$"
806
+ },
807
+ "confirm": {
808
+ "type": "object",
809
+ "additionalProperties": false,
810
+ "properties": {
811
+ "title": {
812
+ "$ref": "#/$defs/label"
813
+ },
814
+ "body": {
815
+ "$ref": "#/$defs/text"
816
+ },
817
+ "tone": {
818
+ "$ref": "#/$defs/tone"
819
+ },
820
+ "require_text": {
821
+ "type": "string",
822
+ "maxLength": 60
823
+ }
824
+ }
825
+ },
826
+ "when": {
827
+ "$ref": "#/$defs/predicate"
828
+ },
829
+ "to": {
830
+ "const": "record.create"
831
+ },
832
+ "form": {
833
+ "$ref": "#/$defs/id"
834
+ },
835
+ "model": {
836
+ "$ref": "#/$defs/key"
837
+ }
838
+ }
839
+ },
840
+ "action_submit_update": {
841
+ "type": "object",
842
+ "additionalProperties": false,
843
+ "required": [
844
+ "do",
845
+ "to",
846
+ "form",
847
+ "model",
848
+ "record"
849
+ ],
850
+ "properties": {
851
+ "do": {
852
+ "const": "submit"
853
+ },
854
+ "label": {
855
+ "$ref": "#/$defs/label"
856
+ },
857
+ "variant": {
858
+ "enum": [
859
+ "primary",
860
+ "secondary",
861
+ "ghost",
862
+ "danger"
863
+ ]
864
+ },
865
+ "icon": {
866
+ "type": "string",
867
+ "pattern": "^[a-z][a-z0-9-]{0,63}$"
868
+ },
869
+ "confirm": {
870
+ "type": "object",
871
+ "additionalProperties": false,
872
+ "properties": {
873
+ "title": {
874
+ "$ref": "#/$defs/label"
875
+ },
876
+ "body": {
877
+ "$ref": "#/$defs/text"
878
+ },
879
+ "tone": {
880
+ "$ref": "#/$defs/tone"
881
+ },
882
+ "require_text": {
883
+ "type": "string",
884
+ "maxLength": 60
885
+ }
886
+ }
887
+ },
888
+ "when": {
889
+ "$ref": "#/$defs/predicate"
890
+ },
891
+ "to": {
892
+ "const": "record.update"
893
+ },
894
+ "form": {
895
+ "$ref": "#/$defs/id"
896
+ },
897
+ "model": {
898
+ "$ref": "#/$defs/key"
899
+ },
900
+ "record": {
901
+ "$ref": "#/$defs/value"
902
+ }
903
+ }
904
+ },
905
+ "action_open": {
906
+ "type": "object",
907
+ "additionalProperties": false,
908
+ "required": [
909
+ "do",
910
+ "overlay"
911
+ ],
912
+ "properties": {
913
+ "do": {
914
+ "const": "open"
915
+ },
916
+ "label": {
917
+ "$ref": "#/$defs/label"
918
+ },
919
+ "variant": {
920
+ "enum": [
921
+ "primary",
922
+ "secondary",
923
+ "ghost",
924
+ "danger"
925
+ ]
926
+ },
927
+ "icon": {
928
+ "type": "string",
929
+ "pattern": "^[a-z][a-z0-9-]{0,63}$"
930
+ },
931
+ "confirm": {
932
+ "type": "object",
933
+ "additionalProperties": false,
934
+ "properties": {
935
+ "title": {
936
+ "$ref": "#/$defs/label"
937
+ },
938
+ "body": {
939
+ "$ref": "#/$defs/text"
940
+ },
941
+ "tone": {
942
+ "$ref": "#/$defs/tone"
943
+ },
944
+ "require_text": {
945
+ "type": "string",
946
+ "maxLength": 60
947
+ }
948
+ }
949
+ },
950
+ "when": {
951
+ "$ref": "#/$defs/predicate"
952
+ },
953
+ "overlay": {
954
+ "$ref": "#/$defs/id"
955
+ }
956
+ }
957
+ },
958
+ "action_close": {
959
+ "type": "object",
960
+ "additionalProperties": false,
961
+ "required": [
962
+ "do"
963
+ ],
964
+ "properties": {
965
+ "do": {
966
+ "const": "close"
967
+ },
968
+ "label": {
969
+ "$ref": "#/$defs/label"
970
+ },
971
+ "variant": {
972
+ "enum": [
973
+ "primary",
974
+ "secondary",
975
+ "ghost",
976
+ "danger"
977
+ ]
978
+ },
979
+ "icon": {
980
+ "type": "string",
981
+ "pattern": "^[a-z][a-z0-9-]{0,63}$"
982
+ },
983
+ "confirm": {
984
+ "type": "object",
985
+ "additionalProperties": false,
986
+ "properties": {
987
+ "title": {
988
+ "$ref": "#/$defs/label"
989
+ },
990
+ "body": {
991
+ "$ref": "#/$defs/text"
992
+ },
993
+ "tone": {
994
+ "$ref": "#/$defs/tone"
995
+ },
996
+ "require_text": {
997
+ "type": "string",
998
+ "maxLength": 60
999
+ }
1000
+ }
1001
+ },
1002
+ "when": {
1003
+ "$ref": "#/$defs/predicate"
1004
+ },
1005
+ "overlay": {
1006
+ "$ref": "#/$defs/id"
1007
+ }
1008
+ }
1009
+ },
1010
+ "action_set": {
1011
+ "type": "object",
1012
+ "additionalProperties": false,
1013
+ "required": [
1014
+ "do",
1015
+ "path",
1016
+ "value"
1017
+ ],
1018
+ "properties": {
1019
+ "do": {
1020
+ "const": "set"
1021
+ },
1022
+ "label": {
1023
+ "$ref": "#/$defs/label"
1024
+ },
1025
+ "variant": {
1026
+ "enum": [
1027
+ "primary",
1028
+ "secondary",
1029
+ "ghost",
1030
+ "danger"
1031
+ ]
1032
+ },
1033
+ "icon": {
1034
+ "type": "string",
1035
+ "pattern": "^[a-z][a-z0-9-]{0,63}$"
1036
+ },
1037
+ "confirm": {
1038
+ "type": "object",
1039
+ "additionalProperties": false,
1040
+ "properties": {
1041
+ "title": {
1042
+ "$ref": "#/$defs/label"
1043
+ },
1044
+ "body": {
1045
+ "$ref": "#/$defs/text"
1046
+ },
1047
+ "tone": {
1048
+ "$ref": "#/$defs/tone"
1049
+ },
1050
+ "require_text": {
1051
+ "type": "string",
1052
+ "maxLength": 60
1053
+ }
1054
+ }
1055
+ },
1056
+ "when": {
1057
+ "$ref": "#/$defs/predicate"
1058
+ },
1059
+ "path": {
1060
+ "type": "string",
1061
+ "pattern": "^(?!(?:.*\\.)?(?:__proto__|constructor|prototype)(?:\\.|$))state(\\.[A-Za-z_][A-Za-z0-9_]{0,63}){1,6}$",
1062
+ "x-no-proto": true
1063
+ },
1064
+ "value": {
1065
+ "$ref": "#/$defs/scalar"
1066
+ }
1067
+ }
1068
+ },
1069
+ "action_refresh": {
1070
+ "type": "object",
1071
+ "additionalProperties": false,
1072
+ "required": [
1073
+ "do",
1074
+ "source"
1075
+ ],
1076
+ "properties": {
1077
+ "do": {
1078
+ "const": "refresh"
1079
+ },
1080
+ "label": {
1081
+ "$ref": "#/$defs/label"
1082
+ },
1083
+ "variant": {
1084
+ "enum": [
1085
+ "primary",
1086
+ "secondary",
1087
+ "ghost",
1088
+ "danger"
1089
+ ]
1090
+ },
1091
+ "icon": {
1092
+ "type": "string",
1093
+ "pattern": "^[a-z][a-z0-9-]{0,63}$"
1094
+ },
1095
+ "confirm": {
1096
+ "type": "object",
1097
+ "additionalProperties": false,
1098
+ "properties": {
1099
+ "title": {
1100
+ "$ref": "#/$defs/label"
1101
+ },
1102
+ "body": {
1103
+ "$ref": "#/$defs/text"
1104
+ },
1105
+ "tone": {
1106
+ "$ref": "#/$defs/tone"
1107
+ },
1108
+ "require_text": {
1109
+ "type": "string",
1110
+ "maxLength": 60
1111
+ }
1112
+ }
1113
+ },
1114
+ "when": {
1115
+ "$ref": "#/$defs/predicate"
1116
+ },
1117
+ "source": {
1118
+ "$ref": "#/$defs/name"
1119
+ }
1120
+ }
1121
+ },
1122
+ "action_emit": {
1123
+ "type": "object",
1124
+ "additionalProperties": false,
1125
+ "required": [
1126
+ "do",
1127
+ "id"
1128
+ ],
1129
+ "properties": {
1130
+ "do": {
1131
+ "const": "emit"
1132
+ },
1133
+ "label": {
1134
+ "$ref": "#/$defs/label"
1135
+ },
1136
+ "variant": {
1137
+ "enum": [
1138
+ "primary",
1139
+ "secondary",
1140
+ "ghost",
1141
+ "danger"
1142
+ ]
1143
+ },
1144
+ "icon": {
1145
+ "type": "string",
1146
+ "pattern": "^[a-z][a-z0-9-]{0,63}$"
1147
+ },
1148
+ "confirm": {
1149
+ "type": "object",
1150
+ "additionalProperties": false,
1151
+ "properties": {
1152
+ "title": {
1153
+ "$ref": "#/$defs/label"
1154
+ },
1155
+ "body": {
1156
+ "$ref": "#/$defs/text"
1157
+ },
1158
+ "tone": {
1159
+ "$ref": "#/$defs/tone"
1160
+ },
1161
+ "require_text": {
1162
+ "type": "string",
1163
+ "maxLength": 60
1164
+ }
1165
+ }
1166
+ },
1167
+ "when": {
1168
+ "$ref": "#/$defs/predicate"
1169
+ },
1170
+ "id": {
1171
+ "type": "string",
1172
+ "pattern": "^[a-z][a-z0-9_]*(\\.[a-z][a-z0-9_]*){1,3}$"
1173
+ },
1174
+ "params": {
1175
+ "type": "object",
1176
+ "maxProperties": 8,
1177
+ "additionalProperties": {
1178
+ "$ref": "#/$defs/scalar"
1179
+ }
1180
+ }
1181
+ }
1182
+ },
1183
+ "actions": {
1184
+ "type": "array",
1185
+ "items": {
1186
+ "$ref": "#/$defs/action"
1187
+ },
1188
+ "maxItems": 6
1189
+ },
1190
+ "formField": {
1191
+ "type": "object",
1192
+ "additionalProperties": false,
1193
+ "required": [
1194
+ "key",
1195
+ "label",
1196
+ "kind"
1197
+ ],
1198
+ "properties": {
1199
+ "key": {
1200
+ "$ref": "#/$defs/key"
1201
+ },
1202
+ "label": {
1203
+ "$ref": "#/$defs/label"
1204
+ },
1205
+ "kind": {
1206
+ "$ref": "#/$defs/fieldKind"
1207
+ },
1208
+ "required": {
1209
+ "type": "boolean"
1210
+ },
1211
+ "options": {
1212
+ "type": "array",
1213
+ "items": {
1214
+ "$ref": "#/$defs/option"
1215
+ },
1216
+ "maxItems": 100
1217
+ },
1218
+ "value": {
1219
+ "$ref": "#/$defs/value"
1220
+ },
1221
+ "help": {
1222
+ "type": "string",
1223
+ "maxLength": 160
1224
+ },
1225
+ "placeholder": {
1226
+ "type": "string",
1227
+ "maxLength": 160
1228
+ },
1229
+ "depends_on": {
1230
+ "type": "string",
1231
+ "maxLength": 64
1232
+ },
1233
+ "visible_when": {
1234
+ "type": "object",
1235
+ "additionalProperties": false,
1236
+ "properties": {
1237
+ "field": {
1238
+ "$ref": "#/$defs/key"
1239
+ },
1240
+ "equals": {
1241
+ "$ref": "#/$defs/scalar"
1242
+ },
1243
+ "in": {
1244
+ "type": "array",
1245
+ "items": {
1246
+ "$ref": "#/$defs/scalar"
1247
+ },
1248
+ "maxItems": 50
1249
+ },
1250
+ "not_in": {
1251
+ "type": "array",
1252
+ "items": {
1253
+ "$ref": "#/$defs/scalar"
1254
+ },
1255
+ "maxItems": 50
1256
+ },
1257
+ "empty": {
1258
+ "type": "boolean"
1259
+ }
1260
+ }
1261
+ },
1262
+ "validation": {
1263
+ "type": "object",
1264
+ "additionalProperties": false,
1265
+ "properties": {
1266
+ "min": {
1267
+ "type": "number"
1268
+ },
1269
+ "max": {
1270
+ "type": "number"
1271
+ },
1272
+ "min_length": {
1273
+ "type": "integer",
1274
+ "minimum": 0,
1275
+ "maximum": 2000
1276
+ },
1277
+ "max_length": {
1278
+ "type": "integer",
1279
+ "minimum": 0,
1280
+ "maximum": 2000
1281
+ },
1282
+ "pattern": {
1283
+ "type": "string",
1284
+ "maxLength": 200
1285
+ }
1286
+ }
1287
+ },
1288
+ "widget": {
1289
+ "type": "string",
1290
+ "pattern": "^[a-z][a-z0-9_]{0,31}$"
1291
+ },
1292
+ "section": {
1293
+ "type": "string",
1294
+ "maxLength": 64
1295
+ },
1296
+ "write_only": {
1297
+ "type": "boolean"
1298
+ }
1299
+ }
1300
+ },
1301
+ "dataSource": {
1302
+ "type": "object",
1303
+ "additionalProperties": false,
1304
+ "minProperties": 1,
1305
+ "maxProperties": 2,
1306
+ "properties": {
1307
+ "q": {
1308
+ "type": "string",
1309
+ "pattern": "^(t|m|mm|o|r|i|mi|me|x):[^\\s]{1,500}$",
1310
+ "description": "Token de lectura del query batch."
1311
+ },
1312
+ "plan": {
1313
+ "enum": [
1314
+ "model.list",
1315
+ "model.form",
1316
+ "dashboard.home"
1317
+ ]
1318
+ },
1319
+ "args": {
1320
+ "type": "object",
1321
+ "maxProperties": 8,
1322
+ "additionalProperties": {
1323
+ "$ref": "#/$defs/scalar"
1324
+ }
1325
+ },
1326
+ "widget": {
1327
+ "type": "string",
1328
+ "pattern": "^[a-z][a-z0-9_]*\\.dashboard\\.[a-z][a-z0-9_]*$"
1329
+ },
1330
+ "inline": {
1331
+ "type": "array",
1332
+ "items": {
1333
+ "$ref": "#/$defs/row"
1334
+ },
1335
+ "maxItems": 200
1336
+ }
1337
+ },
1338
+ "description": "Fuente declarada de solo lectura: q | plan(+args) | widget | inline."
1339
+ },
1340
+ "source": {
1341
+ "type": "string",
1342
+ "pattern": "^data\\.[A-Za-z_][A-Za-z0-9_]{0,63}$",
1343
+ "description": "Referencia a data.<nombre>."
1344
+ },
1345
+ "overlay": {
1346
+ "type": "object",
1347
+ "additionalProperties": false,
1348
+ "required": [
1349
+ "kind",
1350
+ "blocks"
1351
+ ],
1352
+ "properties": {
1353
+ "kind": {
1354
+ "enum": [
1355
+ "modal",
1356
+ "drawer"
1357
+ ]
1358
+ },
1359
+ "title": {
1360
+ "$ref": "#/$defs/label"
1361
+ },
1362
+ "blocks": {
1363
+ "type": "array",
1364
+ "items": {
1365
+ "$ref": "#/$defs/block"
1366
+ },
1367
+ "maxItems": 24,
1368
+ "minItems": 1
1369
+ }
1370
+ }
1371
+ },
1372
+ "block": {
1373
+ "x-genui": "block",
1374
+ "description": "Despachado por `type`; ver block_<type>.",
1375
+ "oneOf": [
1376
+ {
1377
+ "$ref": "#/$defs/block_stack"
1378
+ },
1379
+ {
1380
+ "$ref": "#/$defs/block_grid"
1381
+ },
1382
+ {
1383
+ "$ref": "#/$defs/block_tabs"
1384
+ },
1385
+ {
1386
+ "$ref": "#/$defs/block_section"
1387
+ },
1388
+ {
1389
+ "$ref": "#/$defs/block_text"
1390
+ },
1391
+ {
1392
+ "$ref": "#/$defs/block_markdown"
1393
+ },
1394
+ {
1395
+ "$ref": "#/$defs/block_alert"
1396
+ },
1397
+ {
1398
+ "$ref": "#/$defs/block_empty"
1399
+ },
1400
+ {
1401
+ "$ref": "#/$defs/block_card"
1402
+ },
1403
+ {
1404
+ "$ref": "#/$defs/block_list"
1405
+ },
1406
+ {
1407
+ "$ref": "#/$defs/block_kpi"
1408
+ },
1409
+ {
1410
+ "$ref": "#/$defs/block_stats"
1411
+ },
1412
+ {
1413
+ "$ref": "#/$defs/block_links"
1414
+ },
1415
+ {
1416
+ "$ref": "#/$defs/block_timeline"
1417
+ },
1418
+ {
1419
+ "$ref": "#/$defs/block_table"
1420
+ },
1421
+ {
1422
+ "$ref": "#/$defs/block_model_view"
1423
+ },
1424
+ {
1425
+ "$ref": "#/$defs/block_view"
1426
+ },
1427
+ {
1428
+ "$ref": "#/$defs/block_chart"
1429
+ },
1430
+ {
1431
+ "$ref": "#/$defs/block_form"
1432
+ },
1433
+ {
1434
+ "$ref": "#/$defs/block_wizard"
1435
+ },
1436
+ {
1437
+ "$ref": "#/$defs/block_confirm"
1438
+ },
1439
+ {
1440
+ "$ref": "#/$defs/block_settings"
1441
+ },
1442
+ {
1443
+ "$ref": "#/$defs/block_media"
1444
+ },
1445
+ {
1446
+ "$ref": "#/$defs/block_slot"
1447
+ },
1448
+ {
1449
+ "$ref": "#/$defs/block_ext"
1450
+ }
1451
+ ]
1452
+ },
1453
+ "block_stack": {
1454
+ "type": "object",
1455
+ "additionalProperties": false,
1456
+ "required": [
1457
+ "type",
1458
+ "blocks"
1459
+ ],
1460
+ "properties": {
1461
+ "type": {
1462
+ "const": "stack"
1463
+ },
1464
+ "id": {
1465
+ "$ref": "#/$defs/id"
1466
+ },
1467
+ "when": {
1468
+ "$ref": "#/$defs/predicate"
1469
+ },
1470
+ "fallback": {
1471
+ "type": "string",
1472
+ "maxLength": 2000
1473
+ },
1474
+ "direction": {
1475
+ "enum": [
1476
+ "vertical",
1477
+ "horizontal"
1478
+ ]
1479
+ },
1480
+ "title": {
1481
+ "$ref": "#/$defs/label"
1482
+ },
1483
+ "blocks": {
1484
+ "type": "array",
1485
+ "items": {
1486
+ "$ref": "#/$defs/block"
1487
+ },
1488
+ "maxItems": 24,
1489
+ "minItems": 1
1490
+ }
1491
+ }
1492
+ },
1493
+ "block_grid": {
1494
+ "type": "object",
1495
+ "additionalProperties": false,
1496
+ "required": [
1497
+ "type",
1498
+ "blocks"
1499
+ ],
1500
+ "properties": {
1501
+ "type": {
1502
+ "const": "grid"
1503
+ },
1504
+ "id": {
1505
+ "$ref": "#/$defs/id"
1506
+ },
1507
+ "when": {
1508
+ "$ref": "#/$defs/predicate"
1509
+ },
1510
+ "fallback": {
1511
+ "type": "string",
1512
+ "maxLength": 2000
1513
+ },
1514
+ "columns": {
1515
+ "type": "integer",
1516
+ "minimum": 1,
1517
+ "maximum": 4
1518
+ },
1519
+ "title": {
1520
+ "$ref": "#/$defs/label"
1521
+ },
1522
+ "blocks": {
1523
+ "type": "array",
1524
+ "items": {
1525
+ "$ref": "#/$defs/block"
1526
+ },
1527
+ "maxItems": 24,
1528
+ "minItems": 1
1529
+ }
1530
+ }
1531
+ },
1532
+ "block_tabs": {
1533
+ "type": "object",
1534
+ "additionalProperties": false,
1535
+ "required": [
1536
+ "type",
1537
+ "tabs"
1538
+ ],
1539
+ "properties": {
1540
+ "type": {
1541
+ "const": "tabs"
1542
+ },
1543
+ "id": {
1544
+ "$ref": "#/$defs/id"
1545
+ },
1546
+ "when": {
1547
+ "$ref": "#/$defs/predicate"
1548
+ },
1549
+ "fallback": {
1550
+ "type": "string",
1551
+ "maxLength": 2000
1552
+ },
1553
+ "state": {
1554
+ "$ref": "#/$defs/bindingPath"
1555
+ },
1556
+ "tabs": {
1557
+ "type": "array",
1558
+ "items": {
1559
+ "type": "object",
1560
+ "additionalProperties": false,
1561
+ "required": [
1562
+ "key",
1563
+ "label",
1564
+ "blocks"
1565
+ ],
1566
+ "properties": {
1567
+ "key": {
1568
+ "$ref": "#/$defs/key"
1569
+ },
1570
+ "label": {
1571
+ "$ref": "#/$defs/label"
1572
+ },
1573
+ "blocks": {
1574
+ "type": "array",
1575
+ "items": {
1576
+ "$ref": "#/$defs/block"
1577
+ },
1578
+ "maxItems": 24,
1579
+ "minItems": 1
1580
+ }
1581
+ }
1582
+ },
1583
+ "maxItems": 8,
1584
+ "minItems": 1
1585
+ }
1586
+ }
1587
+ },
1588
+ "block_section": {
1589
+ "type": "object",
1590
+ "additionalProperties": false,
1591
+ "required": [
1592
+ "type",
1593
+ "title",
1594
+ "blocks"
1595
+ ],
1596
+ "properties": {
1597
+ "type": {
1598
+ "const": "section"
1599
+ },
1600
+ "id": {
1601
+ "$ref": "#/$defs/id"
1602
+ },
1603
+ "when": {
1604
+ "$ref": "#/$defs/predicate"
1605
+ },
1606
+ "fallback": {
1607
+ "type": "string",
1608
+ "maxLength": 2000
1609
+ },
1610
+ "title": {
1611
+ "$ref": "#/$defs/label"
1612
+ },
1613
+ "collapsible": {
1614
+ "type": "boolean"
1615
+ },
1616
+ "collapsed": {
1617
+ "type": "boolean"
1618
+ },
1619
+ "blocks": {
1620
+ "type": "array",
1621
+ "items": {
1622
+ "$ref": "#/$defs/block"
1623
+ },
1624
+ "maxItems": 24,
1625
+ "minItems": 1
1626
+ }
1627
+ }
1628
+ },
1629
+ "block_text": {
1630
+ "type": "object",
1631
+ "additionalProperties": false,
1632
+ "required": [
1633
+ "type",
1634
+ "text"
1635
+ ],
1636
+ "properties": {
1637
+ "type": {
1638
+ "const": "text"
1639
+ },
1640
+ "id": {
1641
+ "$ref": "#/$defs/id"
1642
+ },
1643
+ "when": {
1644
+ "$ref": "#/$defs/predicate"
1645
+ },
1646
+ "fallback": {
1647
+ "type": "string",
1648
+ "maxLength": 2000
1649
+ },
1650
+ "text": {
1651
+ "$ref": "#/$defs/text"
1652
+ },
1653
+ "tone": {
1654
+ "$ref": "#/$defs/tone"
1655
+ }
1656
+ }
1657
+ },
1658
+ "block_markdown": {
1659
+ "type": "object",
1660
+ "additionalProperties": false,
1661
+ "required": [
1662
+ "type",
1663
+ "markdown"
1664
+ ],
1665
+ "properties": {
1666
+ "type": {
1667
+ "const": "markdown"
1668
+ },
1669
+ "id": {
1670
+ "$ref": "#/$defs/id"
1671
+ },
1672
+ "when": {
1673
+ "$ref": "#/$defs/predicate"
1674
+ },
1675
+ "fallback": {
1676
+ "type": "string",
1677
+ "maxLength": 2000
1678
+ },
1679
+ "markdown": {
1680
+ "type": "string",
1681
+ "maxLength": 8000
1682
+ }
1683
+ }
1684
+ },
1685
+ "block_alert": {
1686
+ "type": "object",
1687
+ "additionalProperties": false,
1688
+ "required": [
1689
+ "type",
1690
+ "text"
1691
+ ],
1692
+ "properties": {
1693
+ "type": {
1694
+ "const": "alert"
1695
+ },
1696
+ "id": {
1697
+ "$ref": "#/$defs/id"
1698
+ },
1699
+ "when": {
1700
+ "$ref": "#/$defs/predicate"
1701
+ },
1702
+ "fallback": {
1703
+ "type": "string",
1704
+ "maxLength": 2000
1705
+ },
1706
+ "title": {
1707
+ "$ref": "#/$defs/label"
1708
+ },
1709
+ "text": {
1710
+ "$ref": "#/$defs/text"
1711
+ },
1712
+ "tone": {
1713
+ "$ref": "#/$defs/tone"
1714
+ }
1715
+ }
1716
+ },
1717
+ "block_empty": {
1718
+ "type": "object",
1719
+ "additionalProperties": false,
1720
+ "required": [
1721
+ "type",
1722
+ "title"
1723
+ ],
1724
+ "properties": {
1725
+ "type": {
1726
+ "const": "empty"
1727
+ },
1728
+ "id": {
1729
+ "$ref": "#/$defs/id"
1730
+ },
1731
+ "when": {
1732
+ "$ref": "#/$defs/predicate"
1733
+ },
1734
+ "fallback": {
1735
+ "type": "string",
1736
+ "maxLength": 2000
1737
+ },
1738
+ "title": {
1739
+ "$ref": "#/$defs/label"
1740
+ },
1741
+ "text": {
1742
+ "$ref": "#/$defs/text"
1743
+ },
1744
+ "icon": {
1745
+ "type": "string",
1746
+ "pattern": "^[a-z][a-z0-9-]{0,63}$"
1747
+ },
1748
+ "actions": {
1749
+ "$ref": "#/$defs/actions"
1750
+ }
1751
+ }
1752
+ },
1753
+ "block_card": {
1754
+ "type": "object",
1755
+ "additionalProperties": false,
1756
+ "required": [
1757
+ "type",
1758
+ "title"
1759
+ ],
1760
+ "properties": {
1761
+ "type": {
1762
+ "const": "card"
1763
+ },
1764
+ "id": {
1765
+ "$ref": "#/$defs/id"
1766
+ },
1767
+ "when": {
1768
+ "$ref": "#/$defs/predicate"
1769
+ },
1770
+ "fallback": {
1771
+ "type": "string",
1772
+ "maxLength": 2000
1773
+ },
1774
+ "title": {
1775
+ "$ref": "#/$defs/label"
1776
+ },
1777
+ "subtitle": {
1778
+ "$ref": "#/$defs/label"
1779
+ },
1780
+ "body": {
1781
+ "$ref": "#/$defs/text"
1782
+ },
1783
+ "badges": {
1784
+ "type": "array",
1785
+ "items": {
1786
+ "$ref": "#/$defs/badge"
1787
+ },
1788
+ "maxItems": 6
1789
+ },
1790
+ "fields": {
1791
+ "type": "array",
1792
+ "items": {
1793
+ "$ref": "#/$defs/field"
1794
+ },
1795
+ "maxItems": 12
1796
+ },
1797
+ "link": {
1798
+ "$ref": "#/$defs/link"
1799
+ },
1800
+ "tone": {
1801
+ "$ref": "#/$defs/tone"
1802
+ },
1803
+ "actions": {
1804
+ "$ref": "#/$defs/actions"
1805
+ }
1806
+ }
1807
+ },
1808
+ "block_list": {
1809
+ "type": "object",
1810
+ "additionalProperties": false,
1811
+ "required": [
1812
+ "type",
1813
+ "items"
1814
+ ],
1815
+ "properties": {
1816
+ "type": {
1817
+ "const": "list"
1818
+ },
1819
+ "id": {
1820
+ "$ref": "#/$defs/id"
1821
+ },
1822
+ "when": {
1823
+ "$ref": "#/$defs/predicate"
1824
+ },
1825
+ "fallback": {
1826
+ "type": "string",
1827
+ "maxLength": 2000
1828
+ },
1829
+ "title": {
1830
+ "$ref": "#/$defs/label"
1831
+ },
1832
+ "items": {
1833
+ "type": "array",
1834
+ "items": {
1835
+ "type": "object",
1836
+ "additionalProperties": false,
1837
+ "required": [
1838
+ "title"
1839
+ ],
1840
+ "properties": {
1841
+ "title": {
1842
+ "$ref": "#/$defs/label"
1843
+ },
1844
+ "description": {
1845
+ "$ref": "#/$defs/text"
1846
+ },
1847
+ "badge": {
1848
+ "$ref": "#/$defs/badge"
1849
+ },
1850
+ "action": {
1851
+ "$ref": "#/$defs/action"
1852
+ }
1853
+ }
1854
+ },
1855
+ "maxItems": 50,
1856
+ "minItems": 1
1857
+ }
1858
+ }
1859
+ },
1860
+ "block_kpi": {
1861
+ "type": "object",
1862
+ "additionalProperties": false,
1863
+ "required": [
1864
+ "type",
1865
+ "items"
1866
+ ],
1867
+ "properties": {
1868
+ "type": {
1869
+ "const": "kpi"
1870
+ },
1871
+ "id": {
1872
+ "$ref": "#/$defs/id"
1873
+ },
1874
+ "when": {
1875
+ "$ref": "#/$defs/predicate"
1876
+ },
1877
+ "fallback": {
1878
+ "type": "string",
1879
+ "maxLength": 2000
1880
+ },
1881
+ "title": {
1882
+ "$ref": "#/$defs/label"
1883
+ },
1884
+ "items": {
1885
+ "type": "array",
1886
+ "items": {
1887
+ "$ref": "#/$defs/item"
1888
+ },
1889
+ "maxItems": 12,
1890
+ "minItems": 1
1891
+ }
1892
+ }
1893
+ },
1894
+ "block_stats": {
1895
+ "type": "object",
1896
+ "additionalProperties": false,
1897
+ "required": [
1898
+ "type"
1899
+ ],
1900
+ "properties": {
1901
+ "type": {
1902
+ "const": "stats"
1903
+ },
1904
+ "id": {
1905
+ "$ref": "#/$defs/id"
1906
+ },
1907
+ "when": {
1908
+ "$ref": "#/$defs/predicate"
1909
+ },
1910
+ "fallback": {
1911
+ "type": "string",
1912
+ "maxLength": 2000
1913
+ },
1914
+ "title": {
1915
+ "$ref": "#/$defs/label"
1916
+ },
1917
+ "source": {
1918
+ "$ref": "#/$defs/source"
1919
+ },
1920
+ "format": {
1921
+ "$ref": "#/$defs/statFormat"
1922
+ },
1923
+ "items": {
1924
+ "type": "array",
1925
+ "items": {
1926
+ "$ref": "#/$defs/item"
1927
+ },
1928
+ "maxItems": 12,
1929
+ "minItems": 1
1930
+ },
1931
+ "trend": {
1932
+ "enum": [
1933
+ "up",
1934
+ "down",
1935
+ "flat"
1936
+ ]
1937
+ },
1938
+ "compare": {
1939
+ "type": "string",
1940
+ "maxLength": 160
1941
+ }
1942
+ }
1943
+ },
1944
+ "block_links": {
1945
+ "type": "object",
1946
+ "additionalProperties": false,
1947
+ "required": [
1948
+ "type",
1949
+ "items"
1950
+ ],
1951
+ "properties": {
1952
+ "type": {
1953
+ "const": "links"
1954
+ },
1955
+ "id": {
1956
+ "$ref": "#/$defs/id"
1957
+ },
1958
+ "when": {
1959
+ "$ref": "#/$defs/predicate"
1960
+ },
1961
+ "fallback": {
1962
+ "type": "string",
1963
+ "maxLength": 2000
1964
+ },
1965
+ "title": {
1966
+ "$ref": "#/$defs/label"
1967
+ },
1968
+ "items": {
1969
+ "type": "array",
1970
+ "items": {
1971
+ "$ref": "#/$defs/item"
1972
+ },
1973
+ "maxItems": 50,
1974
+ "minItems": 1
1975
+ }
1976
+ }
1977
+ },
1978
+ "block_timeline": {
1979
+ "type": "object",
1980
+ "additionalProperties": false,
1981
+ "required": [
1982
+ "type"
1983
+ ],
1984
+ "properties": {
1985
+ "type": {
1986
+ "const": "timeline"
1987
+ },
1988
+ "id": {
1989
+ "$ref": "#/$defs/id"
1990
+ },
1991
+ "when": {
1992
+ "$ref": "#/$defs/predicate"
1993
+ },
1994
+ "fallback": {
1995
+ "type": "string",
1996
+ "maxLength": 2000
1997
+ },
1998
+ "title": {
1999
+ "$ref": "#/$defs/label"
2000
+ },
2001
+ "items": {
2002
+ "type": "array",
2003
+ "items": {
2004
+ "$ref": "#/$defs/item"
2005
+ },
2006
+ "maxItems": 50,
2007
+ "minItems": 1
2008
+ },
2009
+ "source": {
2010
+ "$ref": "#/$defs/source"
2011
+ }
2012
+ }
2013
+ },
2014
+ "block_table": {
2015
+ "type": "object",
2016
+ "additionalProperties": false,
2017
+ "required": [
2018
+ "type",
2019
+ "columns"
2020
+ ],
2021
+ "properties": {
2022
+ "type": {
2023
+ "const": "table"
2024
+ },
2025
+ "id": {
2026
+ "$ref": "#/$defs/id"
2027
+ },
2028
+ "when": {
2029
+ "$ref": "#/$defs/predicate"
2030
+ },
2031
+ "fallback": {
2032
+ "type": "string",
2033
+ "maxLength": 2000
2034
+ },
2035
+ "title": {
2036
+ "$ref": "#/$defs/label"
2037
+ },
2038
+ "caption": {
2039
+ "$ref": "#/$defs/label"
2040
+ },
2041
+ "columns": {
2042
+ "type": "array",
2043
+ "items": {
2044
+ "$ref": "#/$defs/column"
2045
+ },
2046
+ "maxItems": 24,
2047
+ "minItems": 1
2048
+ },
2049
+ "rows": {
2050
+ "type": "array",
2051
+ "items": {
2052
+ "$ref": "#/$defs/row"
2053
+ },
2054
+ "maxItems": 200
2055
+ },
2056
+ "source": {
2057
+ "$ref": "#/$defs/source"
2058
+ },
2059
+ "filters": {
2060
+ "type": "array",
2061
+ "items": {
2062
+ "$ref": "#/$defs/key"
2063
+ },
2064
+ "maxItems": 12
2065
+ },
2066
+ "sort": {
2067
+ "type": "object",
2068
+ "additionalProperties": false,
2069
+ "required": [
2070
+ "key"
2071
+ ],
2072
+ "properties": {
2073
+ "key": {
2074
+ "$ref": "#/$defs/key"
2075
+ },
2076
+ "dir": {
2077
+ "enum": [
2078
+ "asc",
2079
+ "desc"
2080
+ ]
2081
+ }
2082
+ }
2083
+ },
2084
+ "page_size": {
2085
+ "type": "integer",
2086
+ "minimum": 1,
2087
+ "maximum": 100
2088
+ },
2089
+ "row_actions": {
2090
+ "$ref": "#/$defs/actions"
2091
+ },
2092
+ "bulk_actions": {
2093
+ "$ref": "#/$defs/actions"
2094
+ }
2095
+ }
2096
+ },
2097
+ "block_model_view": {
2098
+ "type": "object",
2099
+ "additionalProperties": false,
2100
+ "required": [
2101
+ "type",
2102
+ "model"
2103
+ ],
2104
+ "properties": {
2105
+ "type": {
2106
+ "const": "model_view"
2107
+ },
2108
+ "id": {
2109
+ "$ref": "#/$defs/id"
2110
+ },
2111
+ "when": {
2112
+ "$ref": "#/$defs/predicate"
2113
+ },
2114
+ "fallback": {
2115
+ "type": "string",
2116
+ "maxLength": 2000
2117
+ },
2118
+ "title": {
2119
+ "$ref": "#/$defs/label"
2120
+ },
2121
+ "model": {
2122
+ "$ref": "#/$defs/key"
2123
+ },
2124
+ "view": {
2125
+ "enum": [
2126
+ "table",
2127
+ "kanban",
2128
+ "calendar",
2129
+ "map",
2130
+ "timeline",
2131
+ "chart"
2132
+ ]
2133
+ },
2134
+ "filters": {
2135
+ "type": "object",
2136
+ "maxProperties": 8,
2137
+ "additionalProperties": {
2138
+ "$ref": "#/$defs/scalar"
2139
+ }
2140
+ },
2141
+ "allowed_actions": {
2142
+ "type": "array",
2143
+ "items": {
2144
+ "$ref": "#/$defs/key"
2145
+ },
2146
+ "maxItems": 12
2147
+ }
2148
+ }
2149
+ },
2150
+ "block_view": {
2151
+ "type": "object",
2152
+ "additionalProperties": false,
2153
+ "required": [
2154
+ "type",
2155
+ "model"
2156
+ ],
2157
+ "properties": {
2158
+ "type": {
2159
+ "const": "view"
2160
+ },
2161
+ "id": {
2162
+ "$ref": "#/$defs/id"
2163
+ },
2164
+ "when": {
2165
+ "$ref": "#/$defs/predicate"
2166
+ },
2167
+ "fallback": {
2168
+ "type": "string",
2169
+ "maxLength": 2000
2170
+ },
2171
+ "title": {
2172
+ "$ref": "#/$defs/label"
2173
+ },
2174
+ "model": {
2175
+ "$ref": "#/$defs/key"
2176
+ },
2177
+ "record": {
2178
+ "$ref": "#/$defs/value"
2179
+ },
2180
+ "fields": {
2181
+ "type": "array",
2182
+ "items": {
2183
+ "$ref": "#/$defs/key"
2184
+ },
2185
+ "maxItems": 40
2186
+ },
2187
+ "panels": {
2188
+ "type": "array",
2189
+ "items": {
2190
+ "$ref": "#/$defs/key"
2191
+ },
2192
+ "maxItems": 12
2193
+ }
2194
+ }
2195
+ },
2196
+ "block_chart": {
2197
+ "type": "object",
2198
+ "additionalProperties": false,
2199
+ "required": [
2200
+ "type",
2201
+ "kind",
2202
+ "x",
2203
+ "series",
2204
+ "summary"
2205
+ ],
2206
+ "properties": {
2207
+ "type": {
2208
+ "const": "chart"
2209
+ },
2210
+ "id": {
2211
+ "$ref": "#/$defs/id"
2212
+ },
2213
+ "when": {
2214
+ "$ref": "#/$defs/predicate"
2215
+ },
2216
+ "fallback": {
2217
+ "type": "string",
2218
+ "maxLength": 2000
2219
+ },
2220
+ "title": {
2221
+ "$ref": "#/$defs/label"
2222
+ },
2223
+ "kind": {
2224
+ "enum": [
2225
+ "bar",
2226
+ "line",
2227
+ "area",
2228
+ "pie",
2229
+ "donut",
2230
+ "sparkline"
2231
+ ]
2232
+ },
2233
+ "x": {
2234
+ "$ref": "#/$defs/key"
2235
+ },
2236
+ "series": {
2237
+ "type": "array",
2238
+ "items": {
2239
+ "$ref": "#/$defs/column"
2240
+ },
2241
+ "maxItems": 6,
2242
+ "minItems": 1
2243
+ },
2244
+ "rows": {
2245
+ "type": "array",
2246
+ "items": {
2247
+ "$ref": "#/$defs/row"
2248
+ },
2249
+ "maxItems": 500
2250
+ },
2251
+ "source": {
2252
+ "$ref": "#/$defs/source"
2253
+ },
2254
+ "format": {
2255
+ "$ref": "#/$defs/statFormat"
2256
+ },
2257
+ "accent": {
2258
+ "$ref": "#/$defs/tone"
2259
+ },
2260
+ "summary": {
2261
+ "type": "string",
2262
+ "maxLength": 2000
2263
+ },
2264
+ "caption": {
2265
+ "$ref": "#/$defs/label"
2266
+ }
2267
+ }
2268
+ },
2269
+ "block_form": {
2270
+ "type": "object",
2271
+ "additionalProperties": false,
2272
+ "required": [
2273
+ "type",
2274
+ "fields"
2275
+ ],
2276
+ "properties": {
2277
+ "type": {
2278
+ "const": "form"
2279
+ },
2280
+ "id": {
2281
+ "$ref": "#/$defs/id"
2282
+ },
2283
+ "when": {
2284
+ "$ref": "#/$defs/predicate"
2285
+ },
2286
+ "fallback": {
2287
+ "type": "string",
2288
+ "maxLength": 2000
2289
+ },
2290
+ "title": {
2291
+ "$ref": "#/$defs/label"
2292
+ },
2293
+ "description": {
2294
+ "$ref": "#/$defs/text"
2295
+ },
2296
+ "fields": {
2297
+ "type": "array",
2298
+ "items": {
2299
+ "$ref": "#/$defs/formField"
2300
+ },
2301
+ "maxItems": 40,
2302
+ "minItems": 1
2303
+ },
2304
+ "layout": {
2305
+ "type": "object",
2306
+ "additionalProperties": false,
2307
+ "properties": {
2308
+ "mode": {
2309
+ "enum": [
2310
+ "sections",
2311
+ "steps"
2312
+ ]
2313
+ },
2314
+ "steps": {
2315
+ "type": "array",
2316
+ "items": {
2317
+ "type": "object",
2318
+ "additionalProperties": false,
2319
+ "required": [
2320
+ "title",
2321
+ "fields"
2322
+ ],
2323
+ "properties": {
2324
+ "title": {
2325
+ "$ref": "#/$defs/label"
2326
+ },
2327
+ "description": {
2328
+ "$ref": "#/$defs/text"
2329
+ },
2330
+ "fields": {
2331
+ "type": "array",
2332
+ "items": {
2333
+ "$ref": "#/$defs/key"
2334
+ },
2335
+ "maxItems": 40,
2336
+ "minItems": 1
2337
+ }
2338
+ }
2339
+ },
2340
+ "maxItems": 8
2341
+ }
2342
+ }
2343
+ },
2344
+ "submit": {
2345
+ "$ref": "#/$defs/action"
2346
+ },
2347
+ "actions": {
2348
+ "$ref": "#/$defs/actions"
2349
+ }
2350
+ }
2351
+ },
2352
+ "block_wizard": {
2353
+ "type": "object",
2354
+ "additionalProperties": false,
2355
+ "required": [
2356
+ "type"
2357
+ ],
2358
+ "properties": {
2359
+ "type": {
2360
+ "const": "wizard"
2361
+ },
2362
+ "id": {
2363
+ "$ref": "#/$defs/id"
2364
+ },
2365
+ "when": {
2366
+ "$ref": "#/$defs/predicate"
2367
+ },
2368
+ "fallback": {
2369
+ "type": "string",
2370
+ "maxLength": 2000
2371
+ },
2372
+ "title": {
2373
+ "$ref": "#/$defs/label"
2374
+ },
2375
+ "description": {
2376
+ "$ref": "#/$defs/text"
2377
+ },
2378
+ "fields": {
2379
+ "type": "array",
2380
+ "items": {
2381
+ "$ref": "#/$defs/formField"
2382
+ },
2383
+ "maxItems": 40,
2384
+ "minItems": 1
2385
+ },
2386
+ "steps": {
2387
+ "type": "array",
2388
+ "items": {
2389
+ "type": "object",
2390
+ "additionalProperties": false,
2391
+ "required": [
2392
+ "title",
2393
+ "fields"
2394
+ ],
2395
+ "properties": {
2396
+ "title": {
2397
+ "$ref": "#/$defs/label"
2398
+ },
2399
+ "description": {
2400
+ "$ref": "#/$defs/text"
2401
+ },
2402
+ "fields": {
2403
+ "type": "array",
2404
+ "items": {
2405
+ "$ref": "#/$defs/key"
2406
+ },
2407
+ "maxItems": 40,
2408
+ "minItems": 1
2409
+ }
2410
+ }
2411
+ },
2412
+ "maxItems": 8,
2413
+ "minItems": 1
2414
+ },
2415
+ "submit": {
2416
+ "$ref": "#/$defs/action"
2417
+ },
2418
+ "ref": {
2419
+ "type": "object",
2420
+ "additionalProperties": false,
2421
+ "required": [
2422
+ "action"
2423
+ ],
2424
+ "properties": {
2425
+ "action": {
2426
+ "type": "string",
2427
+ "maxLength": 160
2428
+ }
2429
+ }
2430
+ }
2431
+ }
2432
+ },
2433
+ "block_confirm": {
2434
+ "type": "object",
2435
+ "additionalProperties": false,
2436
+ "required": [
2437
+ "type",
2438
+ "title",
2439
+ "actions"
2440
+ ],
2441
+ "properties": {
2442
+ "type": {
2443
+ "const": "confirm"
2444
+ },
2445
+ "id": {
2446
+ "$ref": "#/$defs/id"
2447
+ },
2448
+ "when": {
2449
+ "$ref": "#/$defs/predicate"
2450
+ },
2451
+ "fallback": {
2452
+ "type": "string",
2453
+ "maxLength": 2000
2454
+ },
2455
+ "title": {
2456
+ "$ref": "#/$defs/label"
2457
+ },
2458
+ "description": {
2459
+ "$ref": "#/$defs/text"
2460
+ },
2461
+ "fields": {
2462
+ "type": "array",
2463
+ "items": {
2464
+ "$ref": "#/$defs/field"
2465
+ },
2466
+ "maxItems": 12
2467
+ },
2468
+ "inputs": {
2469
+ "type": "array",
2470
+ "items": {
2471
+ "type": "object",
2472
+ "additionalProperties": false,
2473
+ "required": [
2474
+ "name",
2475
+ "label",
2476
+ "kind"
2477
+ ],
2478
+ "properties": {
2479
+ "name": {
2480
+ "$ref": "#/$defs/key"
2481
+ },
2482
+ "label": {
2483
+ "$ref": "#/$defs/label"
2484
+ },
2485
+ "kind": {
2486
+ "enum": [
2487
+ "text",
2488
+ "textarea",
2489
+ "number",
2490
+ "switch",
2491
+ "select",
2492
+ "time",
2493
+ "date"
2494
+ ]
2495
+ },
2496
+ "value": {
2497
+ "$ref": "#/$defs/scalar"
2498
+ },
2499
+ "required": {
2500
+ "type": "boolean"
2501
+ },
2502
+ "options": {
2503
+ "type": "array",
2504
+ "items": {
2505
+ "$ref": "#/$defs/option"
2506
+ },
2507
+ "maxItems": 30
2508
+ },
2509
+ "help": {
2510
+ "type": "string",
2511
+ "maxLength": 160
2512
+ }
2513
+ }
2514
+ },
2515
+ "maxItems": 12
2516
+ },
2517
+ "actions": {
2518
+ "type": "array",
2519
+ "items": {
2520
+ "type": "object",
2521
+ "additionalProperties": false,
2522
+ "required": [
2523
+ "id",
2524
+ "label"
2525
+ ],
2526
+ "properties": {
2527
+ "id": {
2528
+ "type": "string",
2529
+ "pattern": "^[a-z][a-z0-9_]*(\\.[a-z][a-z0-9_]*){1,3}$"
2530
+ },
2531
+ "label": {
2532
+ "type": "string",
2533
+ "maxLength": 60
2534
+ },
2535
+ "variant": {
2536
+ "enum": [
2537
+ "primary",
2538
+ "secondary",
2539
+ "ghost",
2540
+ "danger"
2541
+ ]
2542
+ },
2543
+ "params": {
2544
+ "type": "object",
2545
+ "maxProperties": 8,
2546
+ "additionalProperties": {
2547
+ "$ref": "#/$defs/scalar"
2548
+ }
2549
+ }
2550
+ }
2551
+ },
2552
+ "maxItems": 6,
2553
+ "minItems": 1
2554
+ },
2555
+ "badges": {
2556
+ "type": "array",
2557
+ "items": {
2558
+ "$ref": "#/$defs/badge"
2559
+ },
2560
+ "maxItems": 6
2561
+ },
2562
+ "tone": {
2563
+ "$ref": "#/$defs/tone"
2564
+ }
2565
+ }
2566
+ },
2567
+ "block_settings": {
2568
+ "description": "Solo por referencia; nunca en línea.",
2569
+ "type": "object",
2570
+ "additionalProperties": false,
2571
+ "required": [
2572
+ "type",
2573
+ "addon",
2574
+ "scope"
2575
+ ],
2576
+ "properties": {
2577
+ "type": {
2578
+ "const": "settings"
2579
+ },
2580
+ "id": {
2581
+ "$ref": "#/$defs/id"
2582
+ },
2583
+ "when": {
2584
+ "$ref": "#/$defs/predicate"
2585
+ },
2586
+ "fallback": {
2587
+ "type": "string",
2588
+ "maxLength": 2000
2589
+ },
2590
+ "addon": {
2591
+ "type": "string",
2592
+ "pattern": "^[a-z][a-z0-9_]{0,63}$"
2593
+ },
2594
+ "keys": {
2595
+ "type": "array",
2596
+ "items": {
2597
+ "$ref": "#/$defs/key"
2598
+ },
2599
+ "maxItems": 40
2600
+ },
2601
+ "scope": {
2602
+ "enum": [
2603
+ "org",
2604
+ "branch"
2605
+ ]
2606
+ },
2607
+ "section": {
2608
+ "type": "string",
2609
+ "maxLength": 64
2610
+ }
2611
+ }
2612
+ },
2613
+ "block_media": {
2614
+ "type": "object",
2615
+ "additionalProperties": false,
2616
+ "required": [
2617
+ "type",
2618
+ "src",
2619
+ "alt",
2620
+ "width",
2621
+ "height"
2622
+ ],
2623
+ "properties": {
2624
+ "type": {
2625
+ "const": "media"
2626
+ },
2627
+ "id": {
2628
+ "$ref": "#/$defs/id"
2629
+ },
2630
+ "when": {
2631
+ "$ref": "#/$defs/predicate"
2632
+ },
2633
+ "fallback": {
2634
+ "type": "string",
2635
+ "maxLength": 2000
2636
+ },
2637
+ "src": {
2638
+ "type": "string",
2639
+ "maxLength": 2048,
2640
+ "pattern": "^(asset:[A-Za-z0-9_-]{1,64}|/[^/\\\\\\s][^\\\\\\s]*)$"
2641
+ },
2642
+ "alt": {
2643
+ "type": "string",
2644
+ "maxLength": 300
2645
+ },
2646
+ "width": {
2647
+ "type": "integer",
2648
+ "minimum": 1,
2649
+ "maximum": 4096
2650
+ },
2651
+ "height": {
2652
+ "type": "integer",
2653
+ "minimum": 1,
2654
+ "maximum": 4096
2655
+ },
2656
+ "caption": {
2657
+ "$ref": "#/$defs/label"
2658
+ }
2659
+ }
2660
+ },
2661
+ "block_slot": {
2662
+ "type": "object",
2663
+ "additionalProperties": false,
2664
+ "required": [
2665
+ "type",
2666
+ "name"
2667
+ ],
2668
+ "properties": {
2669
+ "type": {
2670
+ "const": "slot"
2671
+ },
2672
+ "id": {
2673
+ "$ref": "#/$defs/id"
2674
+ },
2675
+ "when": {
2676
+ "$ref": "#/$defs/predicate"
2677
+ },
2678
+ "fallback": {
2679
+ "type": "string",
2680
+ "maxLength": 2000
2681
+ },
2682
+ "name": {
2683
+ "type": "string",
2684
+ "pattern": "^[a-z][a-z0-9_]*(\\.[a-z][a-z0-9_]*){1,3}$"
2685
+ },
2686
+ "record": {
2687
+ "$ref": "#/$defs/value"
2688
+ }
2689
+ }
2690
+ },
2691
+ "block_ext": {
2692
+ "type": "object",
2693
+ "additionalProperties": false,
2694
+ "required": [
2695
+ "type",
2696
+ "ext"
2697
+ ],
2698
+ "properties": {
2699
+ "type": {
2700
+ "const": "ext"
2701
+ },
2702
+ "id": {
2703
+ "$ref": "#/$defs/id"
2704
+ },
2705
+ "when": {
2706
+ "$ref": "#/$defs/predicate"
2707
+ },
2708
+ "fallback": {
2709
+ "type": "string",
2710
+ "maxLength": 2000
2711
+ },
2712
+ "ext": {
2713
+ "type": "string",
2714
+ "pattern": "^[a-z][a-z0-9_]{0,63}\\.[a-z][a-z0-9_]{0,63}@[0-9]{1,3}$"
2715
+ },
2716
+ "props": {
2717
+ "type": "object",
2718
+ "maxProperties": 16,
2719
+ "additionalProperties": {
2720
+ "anyOf": [
2721
+ {
2722
+ "$ref": "#/$defs/scalar"
2723
+ },
2724
+ {
2725
+ "type": "array",
2726
+ "items": {
2727
+ "type": [
2728
+ "string",
2729
+ "number",
2730
+ "boolean"
2731
+ ]
2732
+ },
2733
+ "maxItems": 50
2734
+ }
2735
+ ]
2736
+ }
2737
+ }
2738
+ }
2739
+ }
2740
+ }
2741
+ }