@cntrl-site/components 1.0.6 → 1.0.7-alpha.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.
@@ -1,5 +1,4 @@
1
- import { Form } from './Form';
2
- import { ComponentSchemaV1 } from '../../types/SchemaV1';
1
+ import { Form, FormFieldItem } from './Form';
3
2
  export declare const FormComponent: {
4
3
  element: typeof Form;
5
4
  id: string;
@@ -13,6 +12,709 @@ export declare const FormComponent: {
13
12
  width: number;
14
13
  height: number;
15
14
  };
16
- schema: ComponentSchemaV1;
15
+ schema: {
16
+ type: "object";
17
+ version: 1;
18
+ settings: {
19
+ sizing: string;
20
+ properties: {
21
+ fieldsToShow: {
22
+ type: "number";
23
+ scope: "common";
24
+ title: string;
25
+ display: {
26
+ type: string;
27
+ };
28
+ min: number;
29
+ max: number;
30
+ };
31
+ fields: {
32
+ type: "array";
33
+ scope: "common";
34
+ display: {
35
+ type: string;
36
+ };
37
+ items: {
38
+ type: "object";
39
+ properties: {
40
+ name: {
41
+ type: "string";
42
+ };
43
+ type: {
44
+ type: "string";
45
+ enum: string[];
46
+ };
47
+ placeholder: {
48
+ type: "string";
49
+ };
50
+ label: {
51
+ type: "string";
52
+ };
53
+ isRequired: {
54
+ type: "boolean";
55
+ };
56
+ error: {
57
+ type: "string";
58
+ };
59
+ };
60
+ };
61
+ };
62
+ buttonLabel: {
63
+ type: "string";
64
+ scope: "common";
65
+ title: string;
66
+ display: {
67
+ type: string;
68
+ };
69
+ };
70
+ successMessage: {
71
+ type: "string";
72
+ scope: "common";
73
+ title: string;
74
+ display: {
75
+ type: string;
76
+ };
77
+ };
78
+ errorMessage: {
79
+ type: "string";
80
+ scope: "common";
81
+ title: string;
82
+ display: {
83
+ type: string;
84
+ };
85
+ };
86
+ type: {
87
+ type: "string";
88
+ scope: "common";
89
+ title: string;
90
+ display: {
91
+ type: string;
92
+ };
93
+ enum: string[];
94
+ };
95
+ gap: {
96
+ type: "number";
97
+ scope: "layout";
98
+ title: string;
99
+ display: {
100
+ type: string;
101
+ };
102
+ min: number;
103
+ max: number;
104
+ };
105
+ fieldsGap: {
106
+ type: "number";
107
+ scope: "layout";
108
+ title: string;
109
+ display: {
110
+ type: string;
111
+ enabled: boolean;
112
+ };
113
+ min: number;
114
+ max: number;
115
+ };
116
+ buttonPadding: {
117
+ type: "object";
118
+ scope: "layout";
119
+ title: string;
120
+ display: {
121
+ type: string;
122
+ };
123
+ };
124
+ inputPadding: {
125
+ type: "object";
126
+ scope: "layout";
127
+ title: string;
128
+ display: {
129
+ type: string;
130
+ };
131
+ };
132
+ buttonStroke: {
133
+ type: "number";
134
+ scope: "layout";
135
+ title: string;
136
+ display: {
137
+ type: string;
138
+ };
139
+ min: number;
140
+ max: number;
141
+ };
142
+ buttonCorners: {
143
+ type: "number";
144
+ scope: "layout";
145
+ title: string;
146
+ display: {
147
+ type: string;
148
+ enabled: boolean;
149
+ };
150
+ min: number;
151
+ max: number;
152
+ };
153
+ inputStroke: {
154
+ type: "number";
155
+ scope: "layout";
156
+ title: string;
157
+ display: {
158
+ type: string;
159
+ };
160
+ min: number;
161
+ max: number;
162
+ };
163
+ inputCorners: {
164
+ type: "number";
165
+ scope: "layout";
166
+ title: string;
167
+ display: {
168
+ type: string;
169
+ enabled: boolean;
170
+ };
171
+ min: number;
172
+ max: number;
173
+ };
174
+ inputColor: {
175
+ type: "string";
176
+ scope: "common";
177
+ title: string;
178
+ display: {
179
+ type: string;
180
+ };
181
+ };
182
+ inputTextColor: {
183
+ type: "string";
184
+ scope: "common";
185
+ title: string;
186
+ display: {
187
+ type: string;
188
+ };
189
+ };
190
+ inputBorderColor: {
191
+ type: "string";
192
+ scope: "common";
193
+ title: string;
194
+ display: {
195
+ type: string;
196
+ };
197
+ };
198
+ placeholderColor: {
199
+ type: "string";
200
+ scope: "common";
201
+ title: string;
202
+ display: {
203
+ type: string;
204
+ };
205
+ };
206
+ buttonColor: {
207
+ type: "string";
208
+ scope: "common";
209
+ title: string;
210
+ display: {
211
+ type: string;
212
+ };
213
+ };
214
+ buttonTextColor: {
215
+ type: "string";
216
+ scope: "common";
217
+ title: string;
218
+ display: {
219
+ type: string;
220
+ };
221
+ };
222
+ isButtonFullWidth: {
223
+ type: "boolean";
224
+ scope: "common";
225
+ title: string;
226
+ display: {
227
+ type: string;
228
+ enum: string[];
229
+ };
230
+ };
231
+ buttonBorderColor: {
232
+ type: "string";
233
+ scope: "common";
234
+ title: string;
235
+ display: {
236
+ type: string;
237
+ };
238
+ };
239
+ labelTextColor: {
240
+ type: "string";
241
+ scope: "common";
242
+ title: string;
243
+ display: {
244
+ type: string;
245
+ visible: boolean;
246
+ };
247
+ };
248
+ successColor: {
249
+ type: "string";
250
+ scope: "common";
251
+ title: string;
252
+ display: {
253
+ type: string;
254
+ };
255
+ };
256
+ errorColor: {
257
+ type: "string";
258
+ scope: "common";
259
+ title: string;
260
+ display: {
261
+ type: string;
262
+ };
263
+ };
264
+ stateOverrides: {
265
+ type: "object";
266
+ scope: "common";
267
+ };
268
+ fontFamily: {
269
+ type: "string";
270
+ scope: "common";
271
+ title: string;
272
+ display: {
273
+ type: string;
274
+ };
275
+ };
276
+ inputFontSettings: {
277
+ scope: "common";
278
+ title: string;
279
+ display: {
280
+ type: string;
281
+ };
282
+ type: "object";
283
+ properties: {
284
+ fontWeight: {
285
+ type: "number";
286
+ };
287
+ fontStyle: {
288
+ type: "string";
289
+ };
290
+ };
291
+ };
292
+ inputFontSize: {
293
+ type: "number";
294
+ scope: "layout";
295
+ title: string;
296
+ display: {
297
+ type: string;
298
+ };
299
+ };
300
+ inputLineHeight: {
301
+ type: "number";
302
+ scope: "layout";
303
+ title: string;
304
+ display: {
305
+ type: string;
306
+ };
307
+ };
308
+ inputLetterSpacing: {
309
+ type: "number";
310
+ scope: "layout";
311
+ title: string;
312
+ display: {
313
+ type: string;
314
+ };
315
+ };
316
+ inputWordSpacing: {
317
+ type: "number";
318
+ scope: "layout";
319
+ title: string;
320
+ display: {
321
+ type: string;
322
+ };
323
+ };
324
+ inputTextAppearance: {
325
+ type: "object";
326
+ scope: "layout";
327
+ title: string;
328
+ display: {
329
+ type: string;
330
+ };
331
+ };
332
+ buttonFontSettings: {
333
+ scope: "common";
334
+ title: string;
335
+ display: {
336
+ type: string;
337
+ };
338
+ type: "object";
339
+ properties: {
340
+ fontWeight: {
341
+ type: "number";
342
+ };
343
+ fontStyle: {
344
+ type: "string";
345
+ };
346
+ };
347
+ };
348
+ buttonFontSize: {
349
+ type: "number";
350
+ scope: "layout";
351
+ title: string;
352
+ display: {
353
+ type: string;
354
+ };
355
+ };
356
+ buttonLineHeight: {
357
+ type: "number";
358
+ scope: "layout";
359
+ title: string;
360
+ display: {
361
+ type: string;
362
+ };
363
+ };
364
+ buttonLetterSpacing: {
365
+ type: "number";
366
+ scope: "layout";
367
+ title: string;
368
+ display: {
369
+ type: string;
370
+ };
371
+ };
372
+ buttonWordSpacing: {
373
+ type: "number";
374
+ scope: "layout";
375
+ title: string;
376
+ display: {
377
+ type: string;
378
+ };
379
+ };
380
+ buttonTextAppearance: {
381
+ type: "object";
382
+ scope: "layout";
383
+ title: string;
384
+ display: {
385
+ type: string;
386
+ };
387
+ };
388
+ labelFontSettings: {
389
+ scope: "common";
390
+ title: string;
391
+ display: {
392
+ type: string;
393
+ visible: boolean;
394
+ };
395
+ type: "object";
396
+ properties: {
397
+ fontWeight: {
398
+ type: "number";
399
+ };
400
+ fontStyle: {
401
+ type: "string";
402
+ };
403
+ };
404
+ };
405
+ labelFontSize: {
406
+ type: "number";
407
+ scope: "layout";
408
+ title: string;
409
+ display: {
410
+ type: string;
411
+ visible: boolean;
412
+ };
413
+ };
414
+ labelLineHeight: {
415
+ type: "number";
416
+ scope: "layout";
417
+ title: string;
418
+ display: {
419
+ type: string;
420
+ visible: boolean;
421
+ };
422
+ };
423
+ labelLetterSpacing: {
424
+ type: "number";
425
+ scope: "layout";
426
+ title: string;
427
+ display: {
428
+ type: string;
429
+ visible: boolean;
430
+ };
431
+ };
432
+ labelWordSpacing: {
433
+ type: "number";
434
+ scope: "layout";
435
+ title: string;
436
+ display: {
437
+ type: string;
438
+ visible: boolean;
439
+ };
440
+ };
441
+ labelTextAppearance: {
442
+ type: "object";
443
+ scope: "layout";
444
+ title: string;
445
+ display: {
446
+ type: string;
447
+ visible: boolean;
448
+ };
449
+ };
450
+ statusFontSettings: {
451
+ scope: "common";
452
+ title: string;
453
+ type: "object";
454
+ display: {
455
+ type: string;
456
+ };
457
+ properties: {
458
+ fontWeight: {
459
+ type: "number";
460
+ };
461
+ fontStyle: {
462
+ type: "string";
463
+ };
464
+ };
465
+ };
466
+ statusFontSize: {
467
+ type: "number";
468
+ scope: "layout";
469
+ title: string;
470
+ display: {
471
+ type: string;
472
+ };
473
+ };
474
+ statusLineHeight: {
475
+ type: "number";
476
+ scope: "layout";
477
+ title: string;
478
+ display: {
479
+ type: string;
480
+ };
481
+ };
482
+ statusLetterSpacing: {
483
+ type: "number";
484
+ scope: "layout";
485
+ title: string;
486
+ display: {
487
+ type: string;
488
+ };
489
+ };
490
+ statusWordSpacing: {
491
+ type: "number";
492
+ scope: "layout";
493
+ title: string;
494
+ display: {
495
+ type: string;
496
+ };
497
+ };
498
+ statusTextAppearance: {
499
+ type: "object";
500
+ scope: "layout";
501
+ title: string;
502
+ display: {
503
+ type: string;
504
+ };
505
+ };
506
+ };
507
+ defaults: {
508
+ fieldsToShow: number;
509
+ fields: FormFieldItem[];
510
+ type: string;
511
+ inputColor: string;
512
+ inputTextColor: string;
513
+ inputBorderColor: string;
514
+ placeholderColor: string;
515
+ buttonColor: string;
516
+ buttonTextColor: string;
517
+ buttonBorderColor: string;
518
+ labelTextColor: string;
519
+ successColor: string;
520
+ errorColor: string;
521
+ stateOverrides: {
522
+ hover: {
523
+ buttonColor: string;
524
+ };
525
+ };
526
+ fontFamily: string;
527
+ inputFontSettings: {
528
+ fontWeight: number;
529
+ fontStyle: string;
530
+ };
531
+ inputLetterSpacing: number;
532
+ inputWordSpacing: number;
533
+ inputTextAppearance: {
534
+ textTransform: string;
535
+ textDecoration: string;
536
+ fontVariant: string;
537
+ };
538
+ buttonFontSettings: {
539
+ fontWeight: number;
540
+ fontStyle: string;
541
+ };
542
+ buttonLetterSpacing: number;
543
+ buttonWordSpacing: number;
544
+ buttonTextAppearance: {
545
+ textTransform: string;
546
+ textDecoration: string;
547
+ fontVariant: string;
548
+ };
549
+ labelFontSettings: {
550
+ fontWeight: number;
551
+ fontStyle: string;
552
+ };
553
+ labelLetterSpacing: number;
554
+ labelWordSpacing: number;
555
+ labelTextAppearance: {
556
+ textTransform: string;
557
+ textDecoration: string;
558
+ fontVariant: string;
559
+ };
560
+ statusFontSettings: {
561
+ fontWeight: number;
562
+ fontStyle: string;
563
+ };
564
+ statusLetterSpacing: number;
565
+ statusWordSpacing: number;
566
+ statusTextAppearance: {
567
+ textTransform: string;
568
+ textDecoration: string;
569
+ fontVariant: string;
570
+ };
571
+ isButtonFullWidth: boolean;
572
+ buttonLabel: string;
573
+ successMessage: string;
574
+ errorMessage: string;
575
+ };
576
+ layoutDefaults: {
577
+ m: {
578
+ gap: number;
579
+ fieldsGap: number;
580
+ buttonStroke: number;
581
+ buttonCorners: number;
582
+ inputStroke: number;
583
+ inputCorners: number;
584
+ buttonPadding: {
585
+ top: number;
586
+ right: number;
587
+ bottom: number;
588
+ left: number;
589
+ };
590
+ inputPadding: {
591
+ top: number;
592
+ right: number;
593
+ bottom: number;
594
+ left: number;
595
+ };
596
+ inputFontSize: number;
597
+ inputLineHeight: number;
598
+ buttonFontSize: number;
599
+ buttonLineHeight: number;
600
+ labelFontSize: number;
601
+ labelLineHeight: number;
602
+ statusFontSize: number;
603
+ statusLineHeight: number;
604
+ };
605
+ d: {
606
+ gap: number;
607
+ fieldsGap: number;
608
+ buttonStroke: number;
609
+ buttonCorners: number;
610
+ inputStroke: number;
611
+ inputCorners: number;
612
+ buttonPadding: {
613
+ top: number;
614
+ right: number;
615
+ bottom: number;
616
+ left: number;
617
+ };
618
+ inputPadding: {
619
+ top: number;
620
+ right: number;
621
+ bottom: number;
622
+ left: number;
623
+ };
624
+ inputFontSize: number;
625
+ inputLineHeight: number;
626
+ buttonFontSize: number;
627
+ buttonLineHeight: number;
628
+ labelFontSize: number;
629
+ labelLineHeight: number;
630
+ statusFontSize: number;
631
+ statusLineHeight: number;
632
+ };
633
+ };
634
+ displayRules: ({
635
+ if: {
636
+ name: string;
637
+ value: string;
638
+ };
639
+ then: {
640
+ name: string;
641
+ value: boolean;
642
+ };
643
+ } | {
644
+ if: {
645
+ name: string;
646
+ value: number;
647
+ };
648
+ then: {
649
+ name: string;
650
+ value: boolean;
651
+ };
652
+ })[];
653
+ };
654
+ panels: ({
655
+ id: string;
656
+ icon: string;
657
+ title: string;
658
+ tooltip: string;
659
+ layout: (string | {
660
+ type: "row";
661
+ items: string[];
662
+ title?: undefined;
663
+ } | {
664
+ type: "group";
665
+ title: string;
666
+ items: ({
667
+ type: "row";
668
+ title: string;
669
+ items: {
670
+ type: "group";
671
+ title: string;
672
+ items: string[];
673
+ }[];
674
+ } | {
675
+ type: "group";
676
+ title: string;
677
+ items: ({
678
+ type: "row";
679
+ items: string[];
680
+ } | {
681
+ type: "row";
682
+ items: {
683
+ type: "group";
684
+ title: string;
685
+ items: string[];
686
+ }[];
687
+ })[];
688
+ })[];
689
+ })[];
690
+ } | {
691
+ id: string;
692
+ icon: string;
693
+ title: string;
694
+ tooltip: string;
695
+ layout: (string | {
696
+ type: "group";
697
+ title: string;
698
+ items: (string | {
699
+ type: "row";
700
+ items: string[];
701
+ })[];
702
+ })[];
703
+ })[];
704
+ paletteBookmark: {
705
+ items: ("inputColor" | "inputTextColor" | "inputBorderColor" | "placeholderColor" | "buttonColor" | "buttonTextColor" | "buttonBorderColor" | "labelTextColor" | "successColor" | "errorColor")[];
706
+ panelIds: string[];
707
+ stateItems: {
708
+ default: string[];
709
+ hover: string[];
710
+ focus: string[];
711
+ filled: string[];
712
+ success: string[];
713
+ error: string[];
714
+ };
715
+ };
716
+ allowedPlugins: string[];
717
+ states: string[];
718
+ };
17
719
  sourceCode: string;
18
720
  };