@optimizely-opal/opal-tools-sdk 0.1.5-dev → 0.1.8-dev

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/src/proteus.ts ADDED
@@ -0,0 +1,2129 @@
1
+ /**
2
+ * Generated by json-schema-to-typescript
3
+ * DO NOT MODIFY - This file is auto-generated from proteus-document-spec.json
4
+ * Run 'npm run generate:proteus' to regenerate
5
+ */
6
+
7
+ export type OpalProteusDocumentSpecification =
8
+ | ProteusAction
9
+ | ProteusAtomicCondition
10
+ | ProteusCancelAction
11
+ | ProteusCondition
12
+ | ProteusDocument
13
+ | ProteusElement
14
+ | ProteusEventHandler
15
+ | ProteusField
16
+ | ProteusGroup
17
+ | ProteusHeading
18
+ | ProteusImage
19
+ | ProteusInput
20
+ | ProteusLink
21
+ | ProteusMap
22
+ | ProteusNode
23
+ | ProteusRange
24
+ | ProteusSelect
25
+ | ProteusSelectContent
26
+ | ProteusSelectTrigger
27
+ | ProteusSeparator
28
+ | ProteusShow
29
+ | ProteusText
30
+ | ProteusTextarea
31
+ | ProteusValue;
32
+ export interface ProteusAction {
33
+ $type: "Action";
34
+ alignItems?: SprinklePropAlignItems;
35
+ alignSelf?: SprinklePropAlignSelf;
36
+ animation?: SprinklePropAnimation;
37
+ /**
38
+ * Control the appearance by selecting between the different button types.
39
+ */
40
+ appearance?:
41
+ | "danger"
42
+ | "danger-outline"
43
+ | "default"
44
+ | "default-opal"
45
+ | "inverse"
46
+ | "primary"
47
+ | "primary-opal"
48
+ | "subtle";
49
+ backgroundImage?: SprinklePropBackgroundImage;
50
+ bg?: SprinklePropBg;
51
+ border?: SprinklePropBorder;
52
+ borderB?: SprinklePropBorderB;
53
+ borderColor?: SprinklePropBorderColor;
54
+ borderL?: SprinklePropBorderL;
55
+ borderR?: SprinklePropBorderR;
56
+ borderT?: SprinklePropBorderT;
57
+ children?: ProteusNode;
58
+ color?: SprinklePropColor;
59
+ cursor?: SprinklePropCursor;
60
+ display?: SprinklePropDisplay;
61
+ flex?: SprinklePropFlex;
62
+ flexDirection?: SprinklePropFlexDirection;
63
+ flexWrap?: SprinklePropFlexWrap;
64
+ fontFamily?: SprinklePropFontFamily;
65
+ fontSize?: SprinklePropFontSize;
66
+ fontWeight?: SprinklePropFontWeight;
67
+ gap?: SprinklePropGap;
68
+ gridColumn?: SprinklePropGridColumn;
69
+ gridTemplateColumns?: SprinklePropGridTemplateColumns;
70
+ h?: SprinklePropH;
71
+ justifyContent?: SprinklePropJustifyContent;
72
+ justifyItems?: SprinklePropJustifyItems;
73
+ m?: SprinklePropM;
74
+ maxH?: SprinklePropMaxH;
75
+ maxW?: SprinklePropMaxW;
76
+ mb?: SprinklePropMb;
77
+ ml?: SprinklePropMl;
78
+ mr?: SprinklePropMr;
79
+ mt?: SprinklePropMt;
80
+ mx?: SprinklePropMx;
81
+ my?: SprinklePropMy;
82
+ objectFit?: SprinklePropObjectFit;
83
+ /**
84
+ * Action triggered when button is clicked
85
+ */
86
+ onClick?:
87
+ | {
88
+ /**
89
+ * Message to send to LLM via sendNewMessage()
90
+ */
91
+ message: string;
92
+ }
93
+ | {
94
+ /**
95
+ * Name of registered tool to call
96
+ */
97
+ tool: string;
98
+ };
99
+ overflow?: SprinklePropOverflow;
100
+ overflowX?: SprinklePropOverflowX;
101
+ overflowY?: SprinklePropOverflowY;
102
+ p?: SprinklePropP;
103
+ pb?: SprinklePropPb;
104
+ pl?: SprinklePropPl;
105
+ placeItems?: SprinklePropPlaceItems;
106
+ pointerEvents?: SprinklePropPointerEvents;
107
+ pr?: SprinklePropPr;
108
+ pt?: SprinklePropPt;
109
+ px?: SprinklePropPx;
110
+ py?: SprinklePropPy;
111
+ rounded?: SprinklePropRounded;
112
+ shadow?: SprinklePropShadow;
113
+ textAlign?: SprinklePropTextAlign;
114
+ textTransform?: SprinklePropTextTransform;
115
+ transition?: SprinklePropTransition;
116
+ w?: SprinklePropW;
117
+ whiteSpace?: SprinklePropWhiteSpace;
118
+ z?: SprinklePropZ;
119
+ }
120
+ /**
121
+ * Simple comparison condition - single operator only (used in OR arrays to avoid recursion)
122
+ */
123
+ export type ProteusAtomicCondition =
124
+ | {
125
+ /**
126
+ * Equality comparison
127
+ *
128
+ * @minItems 2
129
+ * @maxItems 2
130
+ */
131
+ "==": [
132
+ boolean | null | number | ProteusValue | string,
133
+ boolean | null | number | ProteusValue | string,
134
+ ];
135
+ }
136
+ | {
137
+ /**
138
+ * Greater than comparison
139
+ *
140
+ * @minItems 2
141
+ * @maxItems 2
142
+ */
143
+ ">": [
144
+ boolean | null | number | ProteusValue | string,
145
+ boolean | null | number | ProteusValue | string,
146
+ ];
147
+ }
148
+ | {
149
+ /**
150
+ * Greater than or equal comparison
151
+ *
152
+ * @minItems 2
153
+ * @maxItems 2
154
+ */
155
+ ">=": [
156
+ boolean | null | number | ProteusValue | string,
157
+ boolean | null | number | ProteusValue | string,
158
+ ];
159
+ }
160
+ | {
161
+ /**
162
+ * Inequality comparison
163
+ *
164
+ * @minItems 2
165
+ * @maxItems 2
166
+ */
167
+ "!=": [
168
+ boolean | null | number | ProteusValue | string,
169
+ boolean | null | number | ProteusValue | string,
170
+ ];
171
+ }
172
+ | {
173
+ /**
174
+ * Less than comparison
175
+ *
176
+ * @minItems 2
177
+ * @maxItems 2
178
+ */
179
+ "<": [
180
+ boolean | null | number | ProteusValue | string,
181
+ boolean | null | number | ProteusValue | string,
182
+ ];
183
+ }
184
+ | {
185
+ /**
186
+ * Less than or equal comparison
187
+ *
188
+ * @minItems 2
189
+ * @maxItems 2
190
+ */
191
+ "<=": [
192
+ boolean | null | number | ProteusValue | string,
193
+ boolean | null | number | ProteusValue | string,
194
+ ];
195
+ }
196
+ | {
197
+ /**
198
+ * Truthy check - returns true if value is truthy (not null, undefined, false, 0, or empty string)
199
+ */
200
+ "!!": boolean | null | number | ProteusValue | string;
201
+ };
202
+ export interface ProteusCancelAction {
203
+ $type: "CancelAction";
204
+ alignItems?: SprinklePropAlignItems;
205
+ alignSelf?: SprinklePropAlignSelf;
206
+ animation?: SprinklePropAnimation;
207
+ backgroundImage?: SprinklePropBackgroundImage;
208
+ bg?: SprinklePropBg;
209
+ border?: SprinklePropBorder;
210
+ borderB?: SprinklePropBorderB;
211
+ borderColor?: SprinklePropBorderColor;
212
+ borderL?: SprinklePropBorderL;
213
+ borderR?: SprinklePropBorderR;
214
+ borderT?: SprinklePropBorderT;
215
+ children?: ProteusNode;
216
+ color?: SprinklePropColor;
217
+ cursor?: SprinklePropCursor;
218
+ display?: SprinklePropDisplay;
219
+ flex?: SprinklePropFlex;
220
+ flexDirection?: SprinklePropFlexDirection;
221
+ flexWrap?: SprinklePropFlexWrap;
222
+ fontFamily?: SprinklePropFontFamily;
223
+ fontSize?: SprinklePropFontSize;
224
+ fontWeight?: SprinklePropFontWeight;
225
+ gap?: SprinklePropGap;
226
+ gridColumn?: SprinklePropGridColumn;
227
+ gridTemplateColumns?: SprinklePropGridTemplateColumns;
228
+ h?: SprinklePropH;
229
+ justifyContent?: SprinklePropJustifyContent;
230
+ justifyItems?: SprinklePropJustifyItems;
231
+ m?: SprinklePropM;
232
+ maxH?: SprinklePropMaxH;
233
+ maxW?: SprinklePropMaxW;
234
+ mb?: SprinklePropMb;
235
+ ml?: SprinklePropMl;
236
+ mr?: SprinklePropMr;
237
+ mt?: SprinklePropMt;
238
+ mx?: SprinklePropMx;
239
+ my?: SprinklePropMy;
240
+ objectFit?: SprinklePropObjectFit;
241
+ overflow?: SprinklePropOverflow;
242
+ overflowX?: SprinklePropOverflowX;
243
+ overflowY?: SprinklePropOverflowY;
244
+ p?: SprinklePropP;
245
+ pb?: SprinklePropPb;
246
+ pl?: SprinklePropPl;
247
+ /**
248
+ * Placeholder text for the text input field
249
+ */
250
+ placeholder?: string;
251
+ placeItems?: SprinklePropPlaceItems;
252
+ pointerEvents?: SprinklePropPointerEvents;
253
+ pr?: SprinklePropPr;
254
+ pt?: SprinklePropPt;
255
+ px?: SprinklePropPx;
256
+ py?: SprinklePropPy;
257
+ rounded?: SprinklePropRounded;
258
+ shadow?: SprinklePropShadow;
259
+ textAlign?: SprinklePropTextAlign;
260
+ textTransform?: SprinklePropTextTransform;
261
+ transition?: SprinklePropTransition;
262
+ w?: SprinklePropW;
263
+ whiteSpace?: SprinklePropWhiteSpace;
264
+ z?: SprinklePropZ;
265
+ }
266
+ /**
267
+ * Condition for Show component. Can be a comparison operator, logical AND, or logical OR. Supports nesting.
268
+ */
269
+ export type ProteusCondition =
270
+ | ProteusAtomicCondition
271
+ | {
272
+ /**
273
+ * Logical OR - returns true if any condition is true
274
+ *
275
+ * @minItems 1
276
+ */
277
+ or: [
278
+ (
279
+ | ProteusAtomicCondition
280
+ | {
281
+ /**
282
+ * Logical AND - returns true if all conditions are true
283
+ *
284
+ * @minItems 1
285
+ */
286
+ and: [ProteusAtomicCondition, ...ProteusAtomicCondition[]];
287
+ }
288
+ ),
289
+ ...(
290
+ | ProteusAtomicCondition
291
+ | {
292
+ /**
293
+ * Logical AND - returns true if all conditions are true
294
+ *
295
+ * @minItems 1
296
+ */
297
+ and: [ProteusAtomicCondition, ...ProteusAtomicCondition[]];
298
+ }
299
+ )[],
300
+ ];
301
+ };
302
+ export interface ProteusDocument {
303
+ $type: "Document";
304
+ /**
305
+ * Actions available for this document
306
+ */
307
+ actions?: ProteusNode;
308
+ /**
309
+ * A visual representation of the application
310
+ */
311
+ appIcon?: string;
312
+ /**
313
+ * The official name of the application
314
+ */
315
+ appName: string;
316
+ /**
317
+ * If true, hides chat prompt and forces user interaction with document. User can press ESC or close to abandon.
318
+ */
319
+ blocking?: boolean;
320
+ body: ProteusNode;
321
+ /**
322
+ * A brief description or tagline that provides additional context about the Proteus document's purpose.
323
+ */
324
+ subtitle?: string;
325
+ /**
326
+ * A concise heading that encapsulates the essence of the Proteus document's content or intended action.
327
+ */
328
+ title: string;
329
+ }
330
+ /**
331
+ * A single Proteus UI component element identified by its $type discriminator
332
+ */
333
+ export type ProteusElement =
334
+ | ProteusAction
335
+ | ProteusCancelAction
336
+ | ProteusField
337
+ | ProteusGroup
338
+ | ProteusHeading
339
+ | ProteusImage
340
+ | ProteusInput
341
+ | ProteusLink
342
+ | ProteusMap
343
+ | ProteusRange
344
+ | ProteusSelect
345
+ | ProteusSelectContent
346
+ | ProteusSelectTrigger
347
+ | ProteusSeparator
348
+ | ProteusShow
349
+ | ProteusText
350
+ | ProteusTextarea
351
+ | ProteusValue;
352
+ /**
353
+ * Handler for user interactions - either a server-side tool call or client-side message
354
+ */
355
+ export type ProteusEventHandler =
356
+ | {
357
+ /**
358
+ * Message to send to LLM via sendNewMessage()
359
+ */
360
+ message: string;
361
+ }
362
+ | {
363
+ /**
364
+ * Name of registered tool to call
365
+ */
366
+ tool: string;
367
+ };
368
+ export interface ProteusField {
369
+ $type: "Field";
370
+ alignItems?: SprinklePropAlignItems;
371
+ alignSelf?: SprinklePropAlignSelf;
372
+ animation?: SprinklePropAnimation;
373
+ backgroundImage?: SprinklePropBackgroundImage;
374
+ bg?: SprinklePropBg;
375
+ border?: SprinklePropBorder;
376
+ borderB?: SprinklePropBorderB;
377
+ borderColor?: SprinklePropBorderColor;
378
+ borderL?: SprinklePropBorderL;
379
+ borderR?: SprinklePropBorderR;
380
+ borderT?: SprinklePropBorderT;
381
+ children?: ProteusNode;
382
+ color?: SprinklePropColor;
383
+ cursor?: SprinklePropCursor;
384
+ /**
385
+ * A Proteus node can be a string, number, boolean, null, a single element, or an array of these types (similar to ReactNode)
386
+ */
387
+ description?:
388
+ | (boolean | null | number | ProteusElement | string)[]
389
+ | boolean
390
+ | null
391
+ | number
392
+ | ProteusElement
393
+ | string;
394
+ display?: SprinklePropDisplay;
395
+ flex?: SprinklePropFlex;
396
+ flexDirection?: SprinklePropFlexDirection;
397
+ flexWrap?: SprinklePropFlexWrap;
398
+ fontFamily?: SprinklePropFontFamily;
399
+ fontSize?: SprinklePropFontSize;
400
+ fontWeight?: SprinklePropFontWeight;
401
+ gap?: SprinklePropGap;
402
+ gridColumn?: SprinklePropGridColumn;
403
+ gridTemplateColumns?: SprinklePropGridTemplateColumns;
404
+ h?: SprinklePropH;
405
+ /**
406
+ * A Proteus node can be a string, number, boolean, null, a single element, or an array of these types (similar to ReactNode)
407
+ */
408
+ info?:
409
+ | (boolean | null | number | ProteusElement | string)[]
410
+ | boolean
411
+ | null
412
+ | number
413
+ | ProteusElement
414
+ | string;
415
+ justifyContent?: SprinklePropJustifyContent;
416
+ justifyItems?: SprinklePropJustifyItems;
417
+ /**
418
+ * A Proteus node can be a string, number, boolean, null, a single element, or an array of these types (similar to ReactNode)
419
+ */
420
+ label?:
421
+ | (boolean | null | number | ProteusElement | string)[]
422
+ | boolean
423
+ | null
424
+ | number
425
+ | ProteusElement
426
+ | string;
427
+ m?: SprinklePropM;
428
+ maxH?: SprinklePropMaxH;
429
+ maxW?: SprinklePropMaxW;
430
+ mb?: SprinklePropMb;
431
+ ml?: SprinklePropMl;
432
+ mr?: SprinklePropMr;
433
+ mt?: SprinklePropMt;
434
+ mx?: SprinklePropMx;
435
+ my?: SprinklePropMy;
436
+ objectFit?: SprinklePropObjectFit;
437
+ overflow?: SprinklePropOverflow;
438
+ overflowX?: SprinklePropOverflowX;
439
+ overflowY?: SprinklePropOverflowY;
440
+ p?: SprinklePropP;
441
+ pb?: SprinklePropPb;
442
+ pl?: SprinklePropPl;
443
+ placeItems?: SprinklePropPlaceItems;
444
+ pointerEvents?: SprinklePropPointerEvents;
445
+ pr?: SprinklePropPr;
446
+ pt?: SprinklePropPt;
447
+ px?: SprinklePropPx;
448
+ py?: SprinklePropPy;
449
+ /**
450
+ * Display an asterisk for required inputs.
451
+ */
452
+ required?: boolean;
453
+ rounded?: SprinklePropRounded;
454
+ shadow?: SprinklePropShadow;
455
+ size?: SprinklePropSize;
456
+ textAlign?: SprinklePropTextAlign;
457
+ textTransform?: SprinklePropTextTransform;
458
+ transition?: SprinklePropTransition;
459
+ w?: SprinklePropW;
460
+ whiteSpace?: SprinklePropWhiteSpace;
461
+ z?: SprinklePropZ;
462
+ }
463
+ export interface ProteusGroup {
464
+ $type: "Group";
465
+ /**
466
+ * Set the element's `align-items` CSS property. Defaults to `center` when
467
+ * `flexDirection='row'`, and `stretch` when `flexDirection='column'`.
468
+ */
469
+ alignItems?: "center" | "end" | "normal" | "start" | "stretch";
470
+ alignSelf?: SprinklePropAlignSelf;
471
+ animation?: SprinklePropAnimation;
472
+ backgroundImage?: SprinklePropBackgroundImage;
473
+ bg?: SprinklePropBg;
474
+ border?: SprinklePropBorder;
475
+ borderB?: SprinklePropBorderB;
476
+ borderColor?: SprinklePropBorderColor;
477
+ borderL?: SprinklePropBorderL;
478
+ borderR?: SprinklePropBorderR;
479
+ borderT?: SprinklePropBorderT;
480
+ children?: ProteusNode;
481
+ color?: SprinklePropColor;
482
+ cursor?: SprinklePropCursor;
483
+ display?: SprinklePropDisplay;
484
+ flex?: SprinklePropFlex;
485
+ /**
486
+ * Set the element's `flex-direction` CSS property.
487
+ *
488
+ * Default: 'row' (CSS standard)
489
+ */
490
+ flexDirection?: "column" | "column-reverse" | "row" | "row-reverse";
491
+ flexWrap?: SprinklePropFlexWrap;
492
+ fontFamily?: SprinklePropFontFamily;
493
+ fontSize?: SprinklePropFontSize;
494
+ fontWeight?: SprinklePropFontWeight;
495
+ gap?: SprinklePropGap;
496
+ gridColumn?: SprinklePropGridColumn;
497
+ gridTemplateColumns?: SprinklePropGridTemplateColumns;
498
+ h?: SprinklePropH;
499
+ justifyContent?: SprinklePropJustifyContent;
500
+ justifyItems?: SprinklePropJustifyItems;
501
+ m?: SprinklePropM;
502
+ maxH?: SprinklePropMaxH;
503
+ maxW?: SprinklePropMaxW;
504
+ mb?: SprinklePropMb;
505
+ ml?: SprinklePropMl;
506
+ mr?: SprinklePropMr;
507
+ mt?: SprinklePropMt;
508
+ mx?: SprinklePropMx;
509
+ my?: SprinklePropMy;
510
+ objectFit?: SprinklePropObjectFit;
511
+ overflow?: SprinklePropOverflow;
512
+ overflowX?: SprinklePropOverflowX;
513
+ overflowY?: SprinklePropOverflowY;
514
+ p?: SprinklePropP;
515
+ pb?: SprinklePropPb;
516
+ pl?: SprinklePropPl;
517
+ placeItems?: SprinklePropPlaceItems;
518
+ pointerEvents?: SprinklePropPointerEvents;
519
+ pr?: SprinklePropPr;
520
+ pt?: SprinklePropPt;
521
+ px?: SprinklePropPx;
522
+ py?: SprinklePropPy;
523
+ rounded?: SprinklePropRounded;
524
+ shadow?: SprinklePropShadow;
525
+ size?: SprinklePropSize;
526
+ textAlign?: SprinklePropTextAlign;
527
+ textTransform?: SprinklePropTextTransform;
528
+ transition?: SprinklePropTransition;
529
+ w?: SprinklePropW;
530
+ whiteSpace?: SprinklePropWhiteSpace;
531
+ z?: SprinklePropZ;
532
+ }
533
+ export interface ProteusHeading {
534
+ $type: "Heading";
535
+ alignItems?: SprinklePropAlignItems;
536
+ alignSelf?: SprinklePropAlignSelf;
537
+ animation?: SprinklePropAnimation;
538
+ backgroundImage?: SprinklePropBackgroundImage;
539
+ bg?: SprinklePropBg;
540
+ border?: SprinklePropBorder;
541
+ borderB?: SprinklePropBorderB;
542
+ borderColor?: SprinklePropBorderColor;
543
+ borderL?: SprinklePropBorderL;
544
+ borderR?: SprinklePropBorderR;
545
+ borderT?: SprinklePropBorderT;
546
+ children?: ProteusNode;
547
+ color?: SprinklePropColor;
548
+ cursor?: SprinklePropCursor;
549
+ display?: SprinklePropDisplay;
550
+ flex?: SprinklePropFlex;
551
+ flexDirection?: SprinklePropFlexDirection;
552
+ flexWrap?: SprinklePropFlexWrap;
553
+ fontFamily?: SprinklePropFontFamily;
554
+ fontSize?: SprinklePropFontSize;
555
+ fontWeight?: SprinklePropFontWeight;
556
+ gap?: SprinklePropGap;
557
+ gridColumn?: SprinklePropGridColumn;
558
+ gridTemplateColumns?: SprinklePropGridTemplateColumns;
559
+ h?: SprinklePropH;
560
+ justifyContent?: SprinklePropJustifyContent;
561
+ justifyItems?: SprinklePropJustifyItems;
562
+ /**
563
+ * Heading level (1-4) that controls both the semantic HTML tag and font size.
564
+ * - `level="1"`: renders `<h1>` with `fontSize="4xl"` (default)
565
+ * - `level="2"`: renders `<h2>` with `fontSize="3xl"`
566
+ * - `level="3"`: renders `<h3>` with `fontSize="2xl"`
567
+ * - `level="4"`: renders `<h4>` with `fontSize="xl"`
568
+ *
569
+ * Use `asChild` to decouple the semantic level from visual appearance.
570
+ */
571
+ level?: "1" | "2" | "3" | "4";
572
+ m?: SprinklePropM;
573
+ maxH?: SprinklePropMaxH;
574
+ maxW?: SprinklePropMaxW;
575
+ mb?: SprinklePropMb;
576
+ ml?: SprinklePropMl;
577
+ mr?: SprinklePropMr;
578
+ mt?: SprinklePropMt;
579
+ mx?: SprinklePropMx;
580
+ my?: SprinklePropMy;
581
+ objectFit?: SprinklePropObjectFit;
582
+ overflow?: SprinklePropOverflow;
583
+ overflowX?: SprinklePropOverflowX;
584
+ overflowY?: SprinklePropOverflowY;
585
+ p?: SprinklePropP;
586
+ pb?: SprinklePropPb;
587
+ pl?: SprinklePropPl;
588
+ placeItems?: SprinklePropPlaceItems;
589
+ pointerEvents?: SprinklePropPointerEvents;
590
+ pr?: SprinklePropPr;
591
+ pt?: SprinklePropPt;
592
+ px?: SprinklePropPx;
593
+ py?: SprinklePropPy;
594
+ rounded?: SprinklePropRounded;
595
+ shadow?: SprinklePropShadow;
596
+ size?: SprinklePropSize;
597
+ textAlign?: SprinklePropTextAlign;
598
+ textTransform?: SprinklePropTextTransform;
599
+ transition?: SprinklePropTransition;
600
+ w?: SprinklePropW;
601
+ whiteSpace?: SprinklePropWhiteSpace;
602
+ z?: SprinklePropZ;
603
+ }
604
+ export interface ProteusImage {
605
+ $type: "Image";
606
+ alignItems?: SprinklePropAlignItems;
607
+ alignSelf?: SprinklePropAlignSelf;
608
+ /**
609
+ * Alternative text for the image
610
+ */
611
+ alt?: string;
612
+ animation?: SprinklePropAnimation;
613
+ backgroundImage?: SprinklePropBackgroundImage;
614
+ bg?: SprinklePropBg;
615
+ border?: SprinklePropBorder;
616
+ borderB?: SprinklePropBorderB;
617
+ borderColor?: SprinklePropBorderColor;
618
+ borderL?: SprinklePropBorderL;
619
+ borderR?: SprinklePropBorderR;
620
+ borderT?: SprinklePropBorderT;
621
+ color?: SprinklePropColor;
622
+ cursor?: SprinklePropCursor;
623
+ display?: SprinklePropDisplay;
624
+ flex?: SprinklePropFlex;
625
+ flexDirection?: SprinklePropFlexDirection;
626
+ flexWrap?: SprinklePropFlexWrap;
627
+ fontFamily?: SprinklePropFontFamily;
628
+ fontSize?: SprinklePropFontSize;
629
+ fontWeight?: SprinklePropFontWeight;
630
+ gap?: SprinklePropGap;
631
+ gridColumn?: SprinklePropGridColumn;
632
+ gridTemplateColumns?: SprinklePropGridTemplateColumns;
633
+ h?: SprinklePropH;
634
+ justifyContent?: SprinklePropJustifyContent;
635
+ justifyItems?: SprinklePropJustifyItems;
636
+ m?: SprinklePropM;
637
+ maxH?: SprinklePropMaxH;
638
+ maxW?: SprinklePropMaxW;
639
+ mb?: SprinklePropMb;
640
+ ml?: SprinklePropMl;
641
+ mr?: SprinklePropMr;
642
+ mt?: SprinklePropMt;
643
+ mx?: SprinklePropMx;
644
+ my?: SprinklePropMy;
645
+ objectFit?: SprinklePropObjectFit;
646
+ overflow?: SprinklePropOverflow;
647
+ overflowX?: SprinklePropOverflowX;
648
+ overflowY?: SprinklePropOverflowY;
649
+ p?: SprinklePropP;
650
+ pb?: SprinklePropPb;
651
+ pl?: SprinklePropPl;
652
+ placeItems?: SprinklePropPlaceItems;
653
+ pointerEvents?: SprinklePropPointerEvents;
654
+ pr?: SprinklePropPr;
655
+ pt?: SprinklePropPt;
656
+ px?: SprinklePropPx;
657
+ py?: SprinklePropPy;
658
+ rounded?: SprinklePropRounded;
659
+ shadow?: SprinklePropShadow;
660
+ size?: SprinklePropSize;
661
+ /**
662
+ * The image source URL
663
+ */
664
+ src?: string;
665
+ textAlign?: SprinklePropTextAlign;
666
+ textTransform?: SprinklePropTextTransform;
667
+ transition?: SprinklePropTransition;
668
+ w?: SprinklePropW;
669
+ whiteSpace?: SprinklePropWhiteSpace;
670
+ z?: SprinklePropZ;
671
+ }
672
+ export interface ProteusInput {
673
+ $type: "Input";
674
+ /**
675
+ * A Proteus node can be a string, number, boolean, null, a single element, or an array of these types (similar to ReactNode)
676
+ */
677
+ addonAfter?:
678
+ | (boolean | null | number | ProteusElement | string)[]
679
+ | boolean
680
+ | null
681
+ | number
682
+ | ProteusElement
683
+ | string;
684
+ /**
685
+ * A Proteus node can be a string, number, boolean, null, a single element, or an array of these types (similar to ReactNode)
686
+ */
687
+ addonBefore?:
688
+ | (boolean | null | number | ProteusElement | string)[]
689
+ | boolean
690
+ | null
691
+ | number
692
+ | ProteusElement
693
+ | string;
694
+ alignItems?: SprinklePropAlignItems;
695
+ alignSelf?: SprinklePropAlignSelf;
696
+ animation?: SprinklePropAnimation;
697
+ /**
698
+ * Control the appearance of the input.
699
+ */
700
+ appearance?: "default" | "number";
701
+ backgroundImage?: SprinklePropBackgroundImage;
702
+ bg?: SprinklePropBg;
703
+ border?: SprinklePropBorder;
704
+ borderB?: SprinklePropBorderB;
705
+ borderColor?: SprinklePropBorderColor;
706
+ borderL?: SprinklePropBorderL;
707
+ borderR?: SprinklePropBorderR;
708
+ borderT?: SprinklePropBorderT;
709
+ color?: SprinklePropColor;
710
+ cursor?: SprinklePropCursor;
711
+ display?: SprinklePropDisplay;
712
+ flex?: SprinklePropFlex;
713
+ flexDirection?: SprinklePropFlexDirection;
714
+ flexWrap?: SprinklePropFlexWrap;
715
+ fontFamily?: SprinklePropFontFamily;
716
+ fontSize?: SprinklePropFontSize;
717
+ fontWeight?: SprinklePropFontWeight;
718
+ gap?: SprinklePropGap;
719
+ gridColumn?: SprinklePropGridColumn;
720
+ gridTemplateColumns?: SprinklePropGridTemplateColumns;
721
+ h?: SprinklePropH;
722
+ justifyContent?: SprinklePropJustifyContent;
723
+ justifyItems?: SprinklePropJustifyItems;
724
+ m?: SprinklePropM;
725
+ maxH?: SprinklePropMaxH;
726
+ maxW?: SprinklePropMaxW;
727
+ mb?: SprinklePropMb;
728
+ ml?: SprinklePropMl;
729
+ mr?: SprinklePropMr;
730
+ mt?: SprinklePropMt;
731
+ mx?: SprinklePropMx;
732
+ my?: SprinklePropMy;
733
+ /**
734
+ * The name of the form control element.
735
+ */
736
+ name?: string;
737
+ objectFit?: SprinklePropObjectFit;
738
+ overflow?: SprinklePropOverflow;
739
+ overflowX?: SprinklePropOverflowX;
740
+ overflowY?: SprinklePropOverflowY;
741
+ p?: SprinklePropP;
742
+ pb?: SprinklePropPb;
743
+ pl?: SprinklePropPl;
744
+ /**
745
+ * The placeholder text to use when control has no value.
746
+ */
747
+ placeholder?: string;
748
+ placeItems?: SprinklePropPlaceItems;
749
+ pointerEvents?: SprinklePropPointerEvents;
750
+ pr?: SprinklePropPr;
751
+ pt?: SprinklePropPt;
752
+ px?: SprinklePropPx;
753
+ py?: SprinklePropPy;
754
+ rounded?: SprinklePropRounded;
755
+ shadow?: SprinklePropShadow;
756
+ textAlign?: SprinklePropTextAlign;
757
+ textTransform?: SprinklePropTextTransform;
758
+ transition?: SprinklePropTransition;
759
+ /**
760
+ * The input type.
761
+ */
762
+ type?:
763
+ | "button"
764
+ | "checkbox"
765
+ | "color"
766
+ | "date"
767
+ | "datetime-local"
768
+ | "email"
769
+ | "file"
770
+ | "hidden"
771
+ | "image"
772
+ | "month"
773
+ | "number"
774
+ | "password"
775
+ | "radio"
776
+ | "range"
777
+ | "reset"
778
+ | "search"
779
+ | "submit"
780
+ | "tel"
781
+ | "text"
782
+ | "time"
783
+ | "url"
784
+ | "week"
785
+ | string;
786
+ w?: SprinklePropW;
787
+ whiteSpace?: SprinklePropWhiteSpace;
788
+ z?: SprinklePropZ;
789
+ }
790
+ export interface ProteusLink {
791
+ $type: "Link";
792
+ alignItems?: SprinklePropAlignItems;
793
+ alignSelf?: SprinklePropAlignSelf;
794
+ animation?: SprinklePropAnimation;
795
+ backgroundImage?: SprinklePropBackgroundImage;
796
+ bg?: SprinklePropBg;
797
+ border?: SprinklePropBorder;
798
+ borderB?: SprinklePropBorderB;
799
+ borderColor?: SprinklePropBorderColor;
800
+ borderL?: SprinklePropBorderL;
801
+ borderR?: SprinklePropBorderR;
802
+ borderT?: SprinklePropBorderT;
803
+ children?: ProteusNode;
804
+ color?: SprinklePropColor;
805
+ cursor?: SprinklePropCursor;
806
+ display?: SprinklePropDisplay;
807
+ flex?: SprinklePropFlex;
808
+ flexDirection?: SprinklePropFlexDirection;
809
+ flexWrap?: SprinklePropFlexWrap;
810
+ fontFamily?: SprinklePropFontFamily;
811
+ fontSize?: SprinklePropFontSize;
812
+ fontWeight?: SprinklePropFontWeight;
813
+ gap?: SprinklePropGap;
814
+ gridColumn?: SprinklePropGridColumn;
815
+ gridTemplateColumns?: SprinklePropGridTemplateColumns;
816
+ h?: SprinklePropH;
817
+ /**
818
+ * The link href.
819
+ */
820
+ href?: string;
821
+ justifyContent?: SprinklePropJustifyContent;
822
+ justifyItems?: SprinklePropJustifyItems;
823
+ m?: SprinklePropM;
824
+ maxH?: SprinklePropMaxH;
825
+ maxW?: SprinklePropMaxW;
826
+ mb?: SprinklePropMb;
827
+ ml?: SprinklePropMl;
828
+ mr?: SprinklePropMr;
829
+ mt?: SprinklePropMt;
830
+ mx?: SprinklePropMx;
831
+ my?: SprinklePropMy;
832
+ objectFit?: SprinklePropObjectFit;
833
+ overflow?: SprinklePropOverflow;
834
+ overflowX?: SprinklePropOverflowX;
835
+ overflowY?: SprinklePropOverflowY;
836
+ p?: SprinklePropP;
837
+ pb?: SprinklePropPb;
838
+ pl?: SprinklePropPl;
839
+ placeItems?: SprinklePropPlaceItems;
840
+ pointerEvents?: SprinklePropPointerEvents;
841
+ pr?: SprinklePropPr;
842
+ pt?: SprinklePropPt;
843
+ px?: SprinklePropPx;
844
+ py?: SprinklePropPy;
845
+ rounded?: SprinklePropRounded;
846
+ shadow?: SprinklePropShadow;
847
+ size?: SprinklePropSize;
848
+ textAlign?: SprinklePropTextAlign;
849
+ textTransform?: SprinklePropTextTransform;
850
+ transition?: SprinklePropTransition;
851
+ w?: SprinklePropW;
852
+ whiteSpace?: SprinklePropWhiteSpace;
853
+ z?: SprinklePropZ;
854
+ }
855
+ export interface ProteusMap {
856
+ $type: "Map";
857
+ /**
858
+ * Template object to render for each item in the array. Value paths are relative to current item.
859
+ */
860
+ children?: {
861
+ [k: string]: undefined | unknown;
862
+ };
863
+ /**
864
+ * JSON pointer path to array (e.g., '/questions')
865
+ */
866
+ path: string;
867
+ }
868
+ /**
869
+ * A Proteus node can be a string, number, boolean, null, a single element, or an array of these types (similar to ReactNode)
870
+ */
871
+ export type ProteusNode =
872
+ | (boolean | null | number | ProteusElement | string)[]
873
+ | boolean
874
+ | null
875
+ | number
876
+ | ProteusElement
877
+ | string;
878
+ export interface ProteusRange {
879
+ $type: "Range";
880
+ alignItems?: SprinklePropAlignItems;
881
+ alignSelf?: SprinklePropAlignSelf;
882
+ animation?: SprinklePropAnimation;
883
+ backgroundImage?: SprinklePropBackgroundImage;
884
+ bg?: SprinklePropBg;
885
+ border?: SprinklePropBorder;
886
+ borderB?: SprinklePropBorderB;
887
+ borderColor?: SprinklePropBorderColor;
888
+ borderL?: SprinklePropBorderL;
889
+ borderR?: SprinklePropBorderR;
890
+ borderT?: SprinklePropBorderT;
891
+ color?: SprinklePropColor;
892
+ cursor?: SprinklePropCursor;
893
+ display?: SprinklePropDisplay;
894
+ flex?: SprinklePropFlex;
895
+ flexDirection?: SprinklePropFlexDirection;
896
+ flexWrap?: SprinklePropFlexWrap;
897
+ fontFamily?: SprinklePropFontFamily;
898
+ fontSize?: SprinklePropFontSize;
899
+ fontWeight?: SprinklePropFontWeight;
900
+ gap?: SprinklePropGap;
901
+ gridColumn?: SprinklePropGridColumn;
902
+ gridTemplateColumns?: SprinklePropGridTemplateColumns;
903
+ h?: SprinklePropH;
904
+ justifyContent?: SprinklePropJustifyContent;
905
+ justifyItems?: SprinklePropJustifyItems;
906
+ m?: SprinklePropM;
907
+ /**
908
+ * The marks to display on the range steps.
909
+ */
910
+ marks?: (
911
+ | number
912
+ | {
913
+ /**
914
+ * The label for the mark
915
+ */
916
+ label: string;
917
+ /**
918
+ * The value for the mark
919
+ */
920
+ value: number;
921
+ }
922
+ )[];
923
+ /**
924
+ * The maximum value for the range.
925
+ */
926
+ max?: number;
927
+ maxH?: SprinklePropMaxH;
928
+ maxW?: SprinklePropMaxW;
929
+ mb?: SprinklePropMb;
930
+ /**
931
+ * The minimum value for the range.
932
+ */
933
+ min?: number;
934
+ ml?: SprinklePropMl;
935
+ mr?: SprinklePropMr;
936
+ mt?: SprinklePropMt;
937
+ mx?: SprinklePropMx;
938
+ my?: SprinklePropMy;
939
+ objectFit?: SprinklePropObjectFit;
940
+ overflow?: SprinklePropOverflow;
941
+ overflowX?: SprinklePropOverflowX;
942
+ overflowY?: SprinklePropOverflowY;
943
+ p?: SprinklePropP;
944
+ pb?: SprinklePropPb;
945
+ pl?: SprinklePropPl;
946
+ placeItems?: SprinklePropPlaceItems;
947
+ pointerEvents?: SprinklePropPointerEvents;
948
+ pr?: SprinklePropPr;
949
+ pt?: SprinklePropPt;
950
+ px?: SprinklePropPx;
951
+ py?: SprinklePropPy;
952
+ rounded?: SprinklePropRounded;
953
+ shadow?: SprinklePropShadow;
954
+ /**
955
+ * The stepping interval for the range.
956
+ */
957
+ step?: number;
958
+ textAlign?: SprinklePropTextAlign;
959
+ textTransform?: SprinklePropTextTransform;
960
+ transition?: SprinklePropTransition;
961
+ w?: SprinklePropW;
962
+ whiteSpace?: SprinklePropWhiteSpace;
963
+ z?: SprinklePropZ;
964
+ }
965
+ export interface ProteusSelect {
966
+ $type: "Select";
967
+ children?: ProteusNode;
968
+ /**
969
+ * The name of the inner select element.
970
+ */
971
+ name?: string;
972
+ /**
973
+ * The select items/options we want to render.
974
+ */
975
+ options: {
976
+ /**
977
+ * String representation of items
978
+ */
979
+ label: string;
980
+ /**
981
+ * Return a unique key for each item
982
+ */
983
+ value: string;
984
+ }[];
985
+ }
986
+ export interface ProteusSelectContent {
987
+ $type: "SelectContent";
988
+ alignItems?: SprinklePropAlignItems;
989
+ alignSelf?: SprinklePropAlignSelf;
990
+ animation?: SprinklePropAnimation;
991
+ backgroundImage?: SprinklePropBackgroundImage;
992
+ bg?: SprinklePropBg;
993
+ border?: SprinklePropBorder;
994
+ borderB?: SprinklePropBorderB;
995
+ borderColor?: SprinklePropBorderColor;
996
+ borderL?: SprinklePropBorderL;
997
+ borderR?: SprinklePropBorderR;
998
+ borderT?: SprinklePropBorderT;
999
+ color?: SprinklePropColor;
1000
+ cursor?: SprinklePropCursor;
1001
+ display?: SprinklePropDisplay;
1002
+ flex?: SprinklePropFlex;
1003
+ flexDirection?: SprinklePropFlexDirection;
1004
+ flexWrap?: SprinklePropFlexWrap;
1005
+ fontFamily?: SprinklePropFontFamily;
1006
+ fontSize?: SprinklePropFontSize;
1007
+ fontWeight?: SprinklePropFontWeight;
1008
+ gap?: SprinklePropGap;
1009
+ gridColumn?: SprinklePropGridColumn;
1010
+ gridTemplateColumns?: SprinklePropGridTemplateColumns;
1011
+ h?: SprinklePropH;
1012
+ justifyContent?: SprinklePropJustifyContent;
1013
+ justifyItems?: SprinklePropJustifyItems;
1014
+ m?: SprinklePropM;
1015
+ maxW?: SprinklePropMaxW;
1016
+ mb?: SprinklePropMb;
1017
+ ml?: SprinklePropMl;
1018
+ mr?: SprinklePropMr;
1019
+ mt?: SprinklePropMt;
1020
+ mx?: SprinklePropMx;
1021
+ my?: SprinklePropMy;
1022
+ objectFit?: SprinklePropObjectFit;
1023
+ overflow?: SprinklePropOverflow;
1024
+ overflowX?: SprinklePropOverflowX;
1025
+ overflowY?: SprinklePropOverflowY;
1026
+ p?: SprinklePropP;
1027
+ pb?: SprinklePropPb;
1028
+ pl?: SprinklePropPl;
1029
+ placeItems?: SprinklePropPlaceItems;
1030
+ pointerEvents?: SprinklePropPointerEvents;
1031
+ pr?: SprinklePropPr;
1032
+ pt?: SprinklePropPt;
1033
+ px?: SprinklePropPx;
1034
+ py?: SprinklePropPy;
1035
+ rounded?: SprinklePropRounded;
1036
+ shadow?: SprinklePropShadow;
1037
+ size?: SprinklePropSize;
1038
+ textAlign?: SprinklePropTextAlign;
1039
+ textTransform?: SprinklePropTextTransform;
1040
+ transition?: SprinklePropTransition;
1041
+ w?: SprinklePropW;
1042
+ whiteSpace?: SprinklePropWhiteSpace;
1043
+ z?: SprinklePropZ;
1044
+ }
1045
+ export interface ProteusSelectTrigger {
1046
+ $type: "SelectTrigger";
1047
+ alignItems?: SprinklePropAlignItems;
1048
+ alignSelf?: SprinklePropAlignSelf;
1049
+ animation?: SprinklePropAnimation;
1050
+ backgroundImage?: SprinklePropBackgroundImage;
1051
+ bg?: SprinklePropBg;
1052
+ border?: SprinklePropBorder;
1053
+ borderB?: SprinklePropBorderB;
1054
+ borderColor?: SprinklePropBorderColor;
1055
+ borderL?: SprinklePropBorderL;
1056
+ borderR?: SprinklePropBorderR;
1057
+ borderT?: SprinklePropBorderT;
1058
+ children?: ProteusNode;
1059
+ color?: SprinklePropColor;
1060
+ cursor?: SprinklePropCursor;
1061
+ display?: SprinklePropDisplay;
1062
+ flex?: SprinklePropFlex;
1063
+ flexDirection?: SprinklePropFlexDirection;
1064
+ flexWrap?: SprinklePropFlexWrap;
1065
+ fontFamily?: SprinklePropFontFamily;
1066
+ fontSize?: SprinklePropFontSize;
1067
+ fontWeight?: SprinklePropFontWeight;
1068
+ gap?: SprinklePropGap;
1069
+ gridColumn?: SprinklePropGridColumn;
1070
+ gridTemplateColumns?: SprinklePropGridTemplateColumns;
1071
+ h?: SprinklePropH;
1072
+ justifyContent?: SprinklePropJustifyContent;
1073
+ justifyItems?: SprinklePropJustifyItems;
1074
+ m?: SprinklePropM;
1075
+ maxH?: SprinklePropMaxH;
1076
+ maxW?: SprinklePropMaxW;
1077
+ mb?: SprinklePropMb;
1078
+ ml?: SprinklePropMl;
1079
+ mr?: SprinklePropMr;
1080
+ mt?: SprinklePropMt;
1081
+ mx?: SprinklePropMx;
1082
+ my?: SprinklePropMy;
1083
+ objectFit?: SprinklePropObjectFit;
1084
+ overflow?: SprinklePropOverflow;
1085
+ overflowX?: SprinklePropOverflowX;
1086
+ overflowY?: SprinklePropOverflowY;
1087
+ p?: SprinklePropP;
1088
+ pb?: SprinklePropPb;
1089
+ pl?: SprinklePropPl;
1090
+ placeItems?: SprinklePropPlaceItems;
1091
+ pointerEvents?: SprinklePropPointerEvents;
1092
+ pr?: SprinklePropPr;
1093
+ pt?: SprinklePropPt;
1094
+ px?: SprinklePropPx;
1095
+ py?: SprinklePropPy;
1096
+ rounded?: SprinklePropRounded;
1097
+ shadow?: SprinklePropShadow;
1098
+ textAlign?: SprinklePropTextAlign;
1099
+ textTransform?: SprinklePropTextTransform;
1100
+ transition?: SprinklePropTransition;
1101
+ w?: SprinklePropW;
1102
+ whiteSpace?: SprinklePropWhiteSpace;
1103
+ z?: SprinklePropZ;
1104
+ }
1105
+ export interface ProteusSeparator {
1106
+ $type: "Separator";
1107
+ alignItems?: SprinklePropAlignItems;
1108
+ alignSelf?: SprinklePropAlignSelf;
1109
+ animation?: SprinklePropAnimation;
1110
+ backgroundImage?: SprinklePropBackgroundImage;
1111
+ bg?: SprinklePropBg;
1112
+ border?: SprinklePropBorder;
1113
+ borderB?: SprinklePropBorderB;
1114
+ borderColor?: SprinklePropBorderColor;
1115
+ borderL?: SprinklePropBorderL;
1116
+ borderR?: SprinklePropBorderR;
1117
+ borderT?: SprinklePropBorderT;
1118
+ color?: SprinklePropColor;
1119
+ cursor?: SprinklePropCursor;
1120
+ display?: SprinklePropDisplay;
1121
+ flex?: SprinklePropFlex;
1122
+ flexDirection?: SprinklePropFlexDirection;
1123
+ flexWrap?: SprinklePropFlexWrap;
1124
+ fontFamily?: SprinklePropFontFamily;
1125
+ fontSize?: SprinklePropFontSize;
1126
+ fontWeight?: SprinklePropFontWeight;
1127
+ gap?: SprinklePropGap;
1128
+ gridColumn?: SprinklePropGridColumn;
1129
+ gridTemplateColumns?: SprinklePropGridTemplateColumns;
1130
+ h?: SprinklePropH;
1131
+ justifyContent?: SprinklePropJustifyContent;
1132
+ justifyItems?: SprinklePropJustifyItems;
1133
+ m?: SprinklePropM;
1134
+ maxH?: SprinklePropMaxH;
1135
+ maxW?: SprinklePropMaxW;
1136
+ mb?: SprinklePropMb;
1137
+ ml?: SprinklePropMl;
1138
+ mr?: SprinklePropMr;
1139
+ mt?: SprinklePropMt;
1140
+ mx?: SprinklePropMx;
1141
+ my?: SprinklePropMy;
1142
+ objectFit?: SprinklePropObjectFit;
1143
+ overflow?: SprinklePropOverflow;
1144
+ overflowX?: SprinklePropOverflowX;
1145
+ overflowY?: SprinklePropOverflowY;
1146
+ p?: SprinklePropP;
1147
+ pb?: SprinklePropPb;
1148
+ pl?: SprinklePropPl;
1149
+ placeItems?: SprinklePropPlaceItems;
1150
+ pointerEvents?: SprinklePropPointerEvents;
1151
+ pr?: SprinklePropPr;
1152
+ pt?: SprinklePropPt;
1153
+ px?: SprinklePropPx;
1154
+ py?: SprinklePropPy;
1155
+ rounded?: SprinklePropRounded;
1156
+ shadow?: SprinklePropShadow;
1157
+ size?: SprinklePropSize;
1158
+ textAlign?: SprinklePropTextAlign;
1159
+ textTransform?: SprinklePropTextTransform;
1160
+ transition?: SprinklePropTransition;
1161
+ w?: SprinklePropW;
1162
+ whiteSpace?: SprinklePropWhiteSpace;
1163
+ z?: SprinklePropZ;
1164
+ }
1165
+ export interface ProteusShow {
1166
+ $type: "Show";
1167
+ /**
1168
+ * A Proteus node can be a string, number, boolean, null, a single element, or an array of these types (similar to ReactNode)
1169
+ */
1170
+ children?:
1171
+ | (boolean | null | number | ProteusElement | string)[]
1172
+ | boolean
1173
+ | null
1174
+ | number
1175
+ | ProteusElement
1176
+ | string;
1177
+ /**
1178
+ * Single condition or array of conditions (AND logic). Each condition is an object with one operator key.
1179
+ */
1180
+ when?: ProteusCondition | ProteusCondition[];
1181
+ }
1182
+ export interface ProteusText {
1183
+ $type: "Text";
1184
+ alignItems?: SprinklePropAlignItems;
1185
+ alignSelf?: SprinklePropAlignSelf;
1186
+ animation?: SprinklePropAnimation;
1187
+ backgroundImage?: SprinklePropBackgroundImage;
1188
+ bg?: SprinklePropBg;
1189
+ border?: SprinklePropBorder;
1190
+ borderB?: SprinklePropBorderB;
1191
+ borderColor?: SprinklePropBorderColor;
1192
+ borderL?: SprinklePropBorderL;
1193
+ borderR?: SprinklePropBorderR;
1194
+ borderT?: SprinklePropBorderT;
1195
+ children?: ProteusNode;
1196
+ color?: SprinklePropColor;
1197
+ cursor?: SprinklePropCursor;
1198
+ display?: SprinklePropDisplay;
1199
+ flex?: SprinklePropFlex;
1200
+ flexDirection?: SprinklePropFlexDirection;
1201
+ flexWrap?: SprinklePropFlexWrap;
1202
+ fontFamily?: SprinklePropFontFamily;
1203
+ fontSize?: SprinklePropFontSize;
1204
+ fontWeight?: SprinklePropFontWeight;
1205
+ gap?: SprinklePropGap;
1206
+ gridColumn?: SprinklePropGridColumn;
1207
+ gridTemplateColumns?: SprinklePropGridTemplateColumns;
1208
+ h?: SprinklePropH;
1209
+ justifyContent?: SprinklePropJustifyContent;
1210
+ justifyItems?: SprinklePropJustifyItems;
1211
+ m?: SprinklePropM;
1212
+ maxH?: SprinklePropMaxH;
1213
+ maxW?: SprinklePropMaxW;
1214
+ mb?: SprinklePropMb;
1215
+ ml?: SprinklePropMl;
1216
+ mr?: SprinklePropMr;
1217
+ mt?: SprinklePropMt;
1218
+ mx?: SprinklePropMx;
1219
+ my?: SprinklePropMy;
1220
+ objectFit?: SprinklePropObjectFit;
1221
+ overflow?: SprinklePropOverflow;
1222
+ overflowX?: SprinklePropOverflowX;
1223
+ overflowY?: SprinklePropOverflowY;
1224
+ p?: SprinklePropP;
1225
+ pb?: SprinklePropPb;
1226
+ pl?: SprinklePropPl;
1227
+ placeItems?: SprinklePropPlaceItems;
1228
+ pointerEvents?: SprinklePropPointerEvents;
1229
+ pr?: SprinklePropPr;
1230
+ pt?: SprinklePropPt;
1231
+ px?: SprinklePropPx;
1232
+ py?: SprinklePropPy;
1233
+ rounded?: SprinklePropRounded;
1234
+ shadow?: SprinklePropShadow;
1235
+ size?: SprinklePropSize;
1236
+ textAlign?: SprinklePropTextAlign;
1237
+ textTransform?: SprinklePropTextTransform;
1238
+ transition?: SprinklePropTransition;
1239
+ w?: SprinklePropW;
1240
+ whiteSpace?: SprinklePropWhiteSpace;
1241
+ z?: SprinklePropZ;
1242
+ }
1243
+ export interface ProteusTextarea {
1244
+ $type: "Textarea";
1245
+ alignItems?: SprinklePropAlignItems;
1246
+ alignSelf?: SprinklePropAlignSelf;
1247
+ animation?: SprinklePropAnimation;
1248
+ backgroundImage?: SprinklePropBackgroundImage;
1249
+ bg?: SprinklePropBg;
1250
+ border?: SprinklePropBorder;
1251
+ borderB?: SprinklePropBorderB;
1252
+ borderColor?: SprinklePropBorderColor;
1253
+ borderL?: SprinklePropBorderL;
1254
+ borderR?: SprinklePropBorderR;
1255
+ borderT?: SprinklePropBorderT;
1256
+ color?: SprinklePropColor;
1257
+ cursor?: SprinklePropCursor;
1258
+ display?: SprinklePropDisplay;
1259
+ flex?: SprinklePropFlex;
1260
+ flexDirection?: SprinklePropFlexDirection;
1261
+ flexWrap?: SprinklePropFlexWrap;
1262
+ fontFamily?: SprinklePropFontFamily;
1263
+ fontSize?: SprinklePropFontSize;
1264
+ fontWeight?: SprinklePropFontWeight;
1265
+ gap?: SprinklePropGap;
1266
+ gridColumn?: SprinklePropGridColumn;
1267
+ gridTemplateColumns?: SprinklePropGridTemplateColumns;
1268
+ h?: SprinklePropH;
1269
+ justifyContent?: SprinklePropJustifyContent;
1270
+ justifyItems?: SprinklePropJustifyItems;
1271
+ m?: SprinklePropM;
1272
+ maxH?: SprinklePropMaxH;
1273
+ /**
1274
+ * Limits the height of the textarea when `resize=auto` is used.
1275
+ */
1276
+ maxRows?: 1 | 2 | 3 | 4 | 5;
1277
+ maxW?: SprinklePropMaxW;
1278
+ mb?: SprinklePropMb;
1279
+ ml?: SprinklePropMl;
1280
+ mr?: SprinklePropMr;
1281
+ mt?: SprinklePropMt;
1282
+ mx?: SprinklePropMx;
1283
+ my?: SprinklePropMy;
1284
+ /**
1285
+ * The name of the form control element.
1286
+ */
1287
+ name?: string;
1288
+ objectFit?: SprinklePropObjectFit;
1289
+ overflow?: SprinklePropOverflow;
1290
+ overflowX?: SprinklePropOverflowX;
1291
+ overflowY?: SprinklePropOverflowY;
1292
+ p?: SprinklePropP;
1293
+ pb?: SprinklePropPb;
1294
+ pl?: SprinklePropPl;
1295
+ /**
1296
+ * The placeholder text to use when control has no value.
1297
+ */
1298
+ placeholder?: string;
1299
+ placeItems?: SprinklePropPlaceItems;
1300
+ pointerEvents?: SprinklePropPointerEvents;
1301
+ pr?: SprinklePropPr;
1302
+ pt?: SprinklePropPt;
1303
+ px?: SprinklePropPx;
1304
+ py?: SprinklePropPy;
1305
+ /**
1306
+ * Control whether resizing mode is manual, automatic, or disabled.
1307
+ */
1308
+ resize?: "auto" | "none" | "vertical";
1309
+ rounded?: SprinklePropRounded;
1310
+ /**
1311
+ * The number of rows to display.
1312
+ */
1313
+ rows?: number;
1314
+ shadow?: SprinklePropShadow;
1315
+ textAlign?: SprinklePropTextAlign;
1316
+ textTransform?: SprinklePropTextTransform;
1317
+ transition?: SprinklePropTransition;
1318
+ w?: SprinklePropW;
1319
+ whiteSpace?: SprinklePropWhiteSpace;
1320
+ z?: SprinklePropZ;
1321
+ }
1322
+ export interface ProteusValue {
1323
+ $type: "Value";
1324
+ /**
1325
+ * JSON pointer path to value (e.g., '/question', '/options/0/label')
1326
+ */
1327
+ path: string;
1328
+ }
1329
+ /**
1330
+ * Set the element's `align-items` CSS property
1331
+ */
1332
+ export type SprinklePropAlignItems =
1333
+ | "center"
1334
+ | "end"
1335
+ | "normal"
1336
+ | "start"
1337
+ | "stretch";
1338
+ /**
1339
+ * Set the element's `align-self` CSS property
1340
+ */
1341
+ export type SprinklePropAlignSelf =
1342
+ | "center"
1343
+ | "end"
1344
+ | "normal"
1345
+ | "start"
1346
+ | "stretch";
1347
+ /**
1348
+ * Animate element with CSS animations
1349
+ */
1350
+ export type SprinklePropAnimation = "ping" | "pulse" | "spin";
1351
+ /**
1352
+ * Set the element's `background-image` CSS property
1353
+ */
1354
+ export type SprinklePropBackgroundImage = "gradient.opal";
1355
+ /**
1356
+ * Set the element's background color. Only accepts predefined color tokens starting with `bg.` (e.g., `bg.default`, `bg.accent`, `bg.error`), or the special values `current` and `transparent`.
1357
+ */
1358
+ export type SprinklePropBg =
1359
+ | "bg.accent"
1360
+ | "bg.accent.hovered"
1361
+ | "bg.accent.light"
1362
+ | "bg.accent.pressed"
1363
+ | "bg.accent.subtle"
1364
+ | "bg.avatar.neutral"
1365
+ | "bg.avatar.purple"
1366
+ | "bg.default"
1367
+ | "bg.default.hovered"
1368
+ | "bg.default.inverse"
1369
+ | "bg.default.inverse.hovered"
1370
+ | "bg.default.inverse.pressed"
1371
+ | "bg.default.pressed"
1372
+ | "bg.error"
1373
+ | "bg.error.hovered"
1374
+ | "bg.error.light"
1375
+ | "bg.error.pressed"
1376
+ | "bg.error.subtle"
1377
+ | "bg.error.subtlest"
1378
+ | "bg.information"
1379
+ | "bg.information.light"
1380
+ | "bg.information.subtle"
1381
+ | "bg.overlay"
1382
+ | "bg.page"
1383
+ | "bg.secondary"
1384
+ | "bg.secondary.hovered"
1385
+ | "bg.spinner.default"
1386
+ | "bg.spinner.inverse"
1387
+ | "bg.success"
1388
+ | "bg.success.hovered"
1389
+ | "bg.success.light"
1390
+ | "bg.success.subtle"
1391
+ | "bg.tertiary"
1392
+ | "bg.tertiary.hovered"
1393
+ | "bg.warning"
1394
+ | "bg.warning.hovered"
1395
+ | "bg.warning.light"
1396
+ | "bg.warning.subtle"
1397
+ | "current"
1398
+ | "transparent";
1399
+ /**
1400
+ * Set the element's `border-width` CSS property
1401
+ */
1402
+ export type SprinklePropBorder = "0" | "1" | "2";
1403
+ /**
1404
+ * Set the element's `border-bottom-width` CSS property
1405
+ */
1406
+ export type SprinklePropBorderB = "0" | "1" | "2";
1407
+ /**
1408
+ * Set the element's border color. Only accepts predefined color tokens starting with `border.` (e.g., `border.default`, `border.accent`, `border.error`), or the special values `current` and `transparent`.
1409
+ */
1410
+ export type SprinklePropBorderColor =
1411
+ | "border.accent"
1412
+ | "border.control"
1413
+ | "border.control.hovered"
1414
+ | "border.default"
1415
+ | "border.disabled"
1416
+ | "border.error"
1417
+ | "border.focus"
1418
+ | "border.focus.error"
1419
+ | "border.secondary"
1420
+ | "border.success"
1421
+ | "border.tertiary"
1422
+ | "border.warning"
1423
+ | "current"
1424
+ | "transparent";
1425
+ /**
1426
+ * Set the element's `border-left-width` CSS property
1427
+ */
1428
+ export type SprinklePropBorderL = "0" | "1" | "2";
1429
+ /**
1430
+ * Set the element's `border-right-width` CSS property
1431
+ */
1432
+ export type SprinklePropBorderR = "0" | "1" | "2";
1433
+ /**
1434
+ * Set the element's `border-top-width` CSS property
1435
+ */
1436
+ export type SprinklePropBorderT = "0" | "1" | "2";
1437
+ /**
1438
+ * Set the element's text color. Only accepts predefined color tokens starting with `fg.` (e.g., `fg.default`, `fg.accent`, `fg.error`), or the special values `current` and `transparent`.
1439
+ */
1440
+ export type SprinklePropColor =
1441
+ | "current"
1442
+ | "fg.accent"
1443
+ | "fg.accent.hovered"
1444
+ | "fg.accent.strong"
1445
+ | "fg.avatar.neutral"
1446
+ | "fg.avatar.purple"
1447
+ | "fg.default"
1448
+ | "fg.default.inverse"
1449
+ | "fg.disabled"
1450
+ | "fg.error"
1451
+ | "fg.error.hovered"
1452
+ | "fg.error.light"
1453
+ | "fg.error.strong"
1454
+ | "fg.information"
1455
+ | "fg.information.light"
1456
+ | "fg.information.strong"
1457
+ | "fg.link.default"
1458
+ | "fg.link.default.hovered"
1459
+ | "fg.link.inverse"
1460
+ | "fg.link.subtle"
1461
+ | "fg.link.visited"
1462
+ | "fg.secondary"
1463
+ | "fg.spinner.default"
1464
+ | "fg.spinner.inverse"
1465
+ | "fg.success"
1466
+ | "fg.success.hovered"
1467
+ | "fg.success.light"
1468
+ | "fg.success.strong"
1469
+ | "fg.tertiary"
1470
+ | "fg.warning"
1471
+ | "fg.warning.hovered"
1472
+ | "fg.warning.inverse"
1473
+ | "fg.warning.light"
1474
+ | "fg.warning.strong"
1475
+ | "fg.white"
1476
+ | "transparent";
1477
+ /**
1478
+ * Set the element's `cursor` CSS property
1479
+ */
1480
+ export type SprinklePropCursor = "default" | "pointer" | "text";
1481
+ /**
1482
+ * Set the element's `display` CSS property
1483
+ */
1484
+ export type SprinklePropDisplay =
1485
+ | "block"
1486
+ | "flex"
1487
+ | "grid"
1488
+ | "inline"
1489
+ | "inline-block"
1490
+ | "inline-flex"
1491
+ | "none"
1492
+ | "table"
1493
+ | "table-cell"
1494
+ | "table-row";
1495
+ /**
1496
+ * Set the element's `flex` CSS property
1497
+ */
1498
+ export type SprinklePropFlex = "1" | "auto" | "initial" | "none";
1499
+ /**
1500
+ * Set the element's `flex-direction` CSS property
1501
+ */
1502
+ export type SprinklePropFlexDirection =
1503
+ | "column"
1504
+ | "column-reverse"
1505
+ | "row"
1506
+ | "row-reverse";
1507
+ /**
1508
+ * Set the element's `flex-wrap` CSS property
1509
+ */
1510
+ export type SprinklePropFlexWrap = "nowrap" | "wrap";
1511
+ /**
1512
+ * Set the element's font family. Only accepts predefined fontFamily tokens.
1513
+ */
1514
+ export type SprinklePropFontFamily = "mono" | "sans";
1515
+ /**
1516
+ * Set the element's font size and line height (both properties are set together). Only accepts predefined fontSize tokens.
1517
+ */
1518
+ export type SprinklePropFontSize =
1519
+ | "2xl"
1520
+ | "3xl"
1521
+ | "4xl"
1522
+ | "inherit"
1523
+ | "lg"
1524
+ | "md"
1525
+ | "sm"
1526
+ | "xl"
1527
+ | "xs";
1528
+ /**
1529
+ * Set the element's `font-weight` CSS property
1530
+ */
1531
+ export type SprinklePropFontWeight = "400" | "500" | "600" | "700" | "inherit";
1532
+ /**
1533
+ * Set the element's `gap` CSS property
1534
+ */
1535
+ export type SprinklePropGap =
1536
+ | "0"
1537
+ | "2"
1538
+ | "4"
1539
+ | "6"
1540
+ | "8"
1541
+ | "10"
1542
+ | "12"
1543
+ | "16"
1544
+ | "20"
1545
+ | "24"
1546
+ | "32"
1547
+ | "40"
1548
+ | "48"
1549
+ | "64"
1550
+ | "80";
1551
+ /**
1552
+ * Set the element's size across grid columns
1553
+ */
1554
+ export type SprinklePropGridColumn = "1" | "2" | "3" | "4";
1555
+ /**
1556
+ * Control number of columns in a grid layout
1557
+ */
1558
+ export type SprinklePropGridTemplateColumns = "1" | "2" | "3" | "4";
1559
+ /**
1560
+ * Set the element's height. Only accepts predefined size tokens.
1561
+ */
1562
+ export type SprinklePropH =
1563
+ | "0"
1564
+ | "1/2"
1565
+ | "1/3"
1566
+ | "1/4"
1567
+ | "2/3"
1568
+ | "2xs"
1569
+ | "3/4"
1570
+ | "3xl"
1571
+ | "10"
1572
+ | "12"
1573
+ | "16"
1574
+ | "20"
1575
+ | "24"
1576
+ | "32"
1577
+ | "40"
1578
+ | "48"
1579
+ | "56"
1580
+ | "64"
1581
+ | "80"
1582
+ | "224"
1583
+ | "384"
1584
+ | "auto"
1585
+ | "fit"
1586
+ | "full"
1587
+ | "lg"
1588
+ | "max"
1589
+ | "md"
1590
+ | "min"
1591
+ | "sm"
1592
+ | "xl"
1593
+ | "xs";
1594
+ /**
1595
+ * Set the element's `justify-content` CSS property
1596
+ */
1597
+ export type SprinklePropJustifyContent =
1598
+ | "center"
1599
+ | "end"
1600
+ | "flex-end"
1601
+ | "flex-start"
1602
+ | "normal"
1603
+ | "space-around"
1604
+ | "space-between"
1605
+ | "space-evenly"
1606
+ | "start"
1607
+ | "stretch";
1608
+ /**
1609
+ * Set the element's `justify-items` CSS property
1610
+ */
1611
+ export type SprinklePropJustifyItems =
1612
+ | "center"
1613
+ | "end"
1614
+ | "normal"
1615
+ | "start"
1616
+ | "stretch";
1617
+ /**
1618
+ * Set the element's margin on all sides. Only accepts predefined spacing tokens.
1619
+ */
1620
+ export type SprinklePropM =
1621
+ | "0"
1622
+ | "2"
1623
+ | "4"
1624
+ | "6"
1625
+ | "8"
1626
+ | "10"
1627
+ | "12"
1628
+ | "16"
1629
+ | "20"
1630
+ | "24"
1631
+ | "32"
1632
+ | "40"
1633
+ | "48"
1634
+ | "64"
1635
+ | "80"
1636
+ | "auto";
1637
+ /**
1638
+ * Set the element's maximum height. Only accepts predefined maxSize tokens.
1639
+ */
1640
+ export type SprinklePropMaxH = "full" | "lg" | "md" | "sm" | "xs";
1641
+ /**
1642
+ * Set the element's maximum width. Only accepts predefined maxSize tokens.
1643
+ */
1644
+ export type SprinklePropMaxW = "full" | "lg" | "md" | "sm" | "xs";
1645
+ /**
1646
+ * Set the element's bottom margin. Only accepts predefined spacing tokens.
1647
+ */
1648
+ export type SprinklePropMb =
1649
+ | "0"
1650
+ | "2"
1651
+ | "4"
1652
+ | "6"
1653
+ | "8"
1654
+ | "10"
1655
+ | "12"
1656
+ | "16"
1657
+ | "20"
1658
+ | "24"
1659
+ | "32"
1660
+ | "40"
1661
+ | "48"
1662
+ | "64"
1663
+ | "80"
1664
+ | "auto";
1665
+ /**
1666
+ * Set the element's left margin. Only accepts predefined spacing tokens.
1667
+ */
1668
+ export type SprinklePropMl =
1669
+ | "0"
1670
+ | "2"
1671
+ | "4"
1672
+ | "6"
1673
+ | "8"
1674
+ | "10"
1675
+ | "12"
1676
+ | "16"
1677
+ | "20"
1678
+ | "24"
1679
+ | "32"
1680
+ | "40"
1681
+ | "48"
1682
+ | "64"
1683
+ | "80"
1684
+ | "auto";
1685
+ /**
1686
+ * Set the element's right margin. Only accepts predefined spacing tokens.
1687
+ */
1688
+ export type SprinklePropMr =
1689
+ | "0"
1690
+ | "2"
1691
+ | "4"
1692
+ | "6"
1693
+ | "8"
1694
+ | "10"
1695
+ | "12"
1696
+ | "16"
1697
+ | "20"
1698
+ | "24"
1699
+ | "32"
1700
+ | "40"
1701
+ | "48"
1702
+ | "64"
1703
+ | "80"
1704
+ | "auto";
1705
+ /**
1706
+ * Set the element's top margin. Only accepts predefined spacing tokens.
1707
+ */
1708
+ export type SprinklePropMt =
1709
+ | "0"
1710
+ | "2"
1711
+ | "4"
1712
+ | "6"
1713
+ | "8"
1714
+ | "10"
1715
+ | "12"
1716
+ | "16"
1717
+ | "20"
1718
+ | "24"
1719
+ | "32"
1720
+ | "40"
1721
+ | "48"
1722
+ | "64"
1723
+ | "80"
1724
+ | "auto";
1725
+ /**
1726
+ * Set the element's left and right margin. Only accepts predefined spacing tokens.
1727
+ */
1728
+ export type SprinklePropMx =
1729
+ | "0"
1730
+ | "2"
1731
+ | "4"
1732
+ | "6"
1733
+ | "8"
1734
+ | "10"
1735
+ | "12"
1736
+ | "16"
1737
+ | "20"
1738
+ | "24"
1739
+ | "32"
1740
+ | "40"
1741
+ | "48"
1742
+ | "64"
1743
+ | "80"
1744
+ | "auto";
1745
+ /**
1746
+ * Set the element's top and bottom margin. Only accepts predefined spacing tokens.
1747
+ */
1748
+ export type SprinklePropMy =
1749
+ | "0"
1750
+ | "2"
1751
+ | "4"
1752
+ | "6"
1753
+ | "8"
1754
+ | "10"
1755
+ | "12"
1756
+ | "16"
1757
+ | "20"
1758
+ | "24"
1759
+ | "32"
1760
+ | "40"
1761
+ | "48"
1762
+ | "64"
1763
+ | "80"
1764
+ | "auto";
1765
+ /**
1766
+ * Set the element's `object-fit` CSS property
1767
+ */
1768
+ export type SprinklePropObjectFit = "contain" | "cover" | "fill" | "none";
1769
+ /**
1770
+ * Set the element's `overflow` CSS property
1771
+ */
1772
+ export type SprinklePropOverflow = "auto" | "hidden" | "visible";
1773
+ /**
1774
+ * Set the element's `overflow-x` CSS property
1775
+ */
1776
+ export type SprinklePropOverflowX = "auto" | "hidden" | "visible";
1777
+
1778
+ /**
1779
+ * Set the element's `overflow-y` CSS property
1780
+ */
1781
+ export type SprinklePropOverflowY = "auto" | "hidden" | "visible";
1782
+ /**
1783
+ * Set the element's padding on all sides. Only accepts predefined spacing tokens.
1784
+ */
1785
+ export type SprinklePropP =
1786
+ | "0"
1787
+ | "2"
1788
+ | "4"
1789
+ | "6"
1790
+ | "8"
1791
+ | "10"
1792
+ | "12"
1793
+ | "16"
1794
+ | "20"
1795
+ | "24"
1796
+ | "32"
1797
+ | "40"
1798
+ | "48"
1799
+ | "64"
1800
+ | "80";
1801
+ /**
1802
+ * Set the element's bottom padding. Only accepts predefined spacing tokens.
1803
+ */
1804
+ export type SprinklePropPb =
1805
+ | "0"
1806
+ | "2"
1807
+ | "4"
1808
+ | "6"
1809
+ | "8"
1810
+ | "10"
1811
+ | "12"
1812
+ | "16"
1813
+ | "20"
1814
+ | "24"
1815
+ | "32"
1816
+ | "40"
1817
+ | "48"
1818
+ | "64"
1819
+ | "80";
1820
+ /**
1821
+ * Set the element's left padding. Only accepts predefined spacing tokens.
1822
+ */
1823
+ export type SprinklePropPl =
1824
+ | "0"
1825
+ | "2"
1826
+ | "4"
1827
+ | "6"
1828
+ | "8"
1829
+ | "10"
1830
+ | "12"
1831
+ | "16"
1832
+ | "20"
1833
+ | "24"
1834
+ | "32"
1835
+ | "40"
1836
+ | "48"
1837
+ | "64"
1838
+ | "80";
1839
+ /**
1840
+ * Set the element's `place-items` CSS property
1841
+ */
1842
+ export type SprinklePropPlaceItems = "center";
1843
+ /**
1844
+ * Set the element's `pointer-events` CSS property
1845
+ */
1846
+ export type SprinklePropPointerEvents = "auto" | "none";
1847
+ /**
1848
+ * Set the element's right padding. Only accepts predefined spacing tokens.
1849
+ */
1850
+ export type SprinklePropPr =
1851
+ | "0"
1852
+ | "2"
1853
+ | "4"
1854
+ | "6"
1855
+ | "8"
1856
+ | "10"
1857
+ | "12"
1858
+ | "16"
1859
+ | "20"
1860
+ | "24"
1861
+ | "32"
1862
+ | "40"
1863
+ | "48"
1864
+ | "64"
1865
+ | "80";
1866
+ /**
1867
+ * Set the element's top padding. Only accepts predefined spacing tokens.
1868
+ */
1869
+ export type SprinklePropPt =
1870
+ | "0"
1871
+ | "2"
1872
+ | "4"
1873
+ | "6"
1874
+ | "8"
1875
+ | "10"
1876
+ | "12"
1877
+ | "16"
1878
+ | "20"
1879
+ | "24"
1880
+ | "32"
1881
+ | "40"
1882
+ | "48"
1883
+ | "64"
1884
+ | "80";
1885
+ /**
1886
+ * Set the element's left and right padding. Only accepts predefined spacing tokens.
1887
+ */
1888
+ export type SprinklePropPx =
1889
+ | "0"
1890
+ | "2"
1891
+ | "4"
1892
+ | "6"
1893
+ | "8"
1894
+ | "10"
1895
+ | "12"
1896
+ | "16"
1897
+ | "20"
1898
+ | "24"
1899
+ | "32"
1900
+ | "40"
1901
+ | "48"
1902
+ | "64"
1903
+ | "80";
1904
+ /**
1905
+ * Set the element's top and bottom padding. Only accepts predefined spacing tokens.
1906
+ */
1907
+ export type SprinklePropPy =
1908
+ | "0"
1909
+ | "2"
1910
+ | "4"
1911
+ | "6"
1912
+ | "8"
1913
+ | "10"
1914
+ | "12"
1915
+ | "16"
1916
+ | "20"
1917
+ | "24"
1918
+ | "32"
1919
+ | "40"
1920
+ | "48"
1921
+ | "64"
1922
+ | "80";
1923
+ /**
1924
+ * Set the element's border radius. Only accepts predefined borderRadius tokens.
1925
+ */
1926
+ export type SprinklePropRounded =
1927
+ | "full"
1928
+ | "inherit"
1929
+ | "lg"
1930
+ | "md"
1931
+ | "none"
1932
+ | "sm"
1933
+ | "xl"
1934
+ | "xs";
1935
+ /**
1936
+ * Set the element's box shadow. Only accepts predefined boxShadow tokens.
1937
+ */
1938
+ export type SprinklePropShadow = "lg" | "md" | "none" | "sm" | "xl";
1939
+ /**
1940
+ * Set the element's width and height. Only accepts predefined size tokens.
1941
+ *
1942
+ * When width and height are the same, use `size` instead of setting both
1943
+ * `w` and `h` separately (e.g., prefer `size="24"` over `w="24" h="24"`).
1944
+ */
1945
+ export type SprinklePropSize =
1946
+ | "0"
1947
+ | "1/2"
1948
+ | "1/3"
1949
+ | "1/4"
1950
+ | "2/3"
1951
+ | "2xs"
1952
+ | "3/4"
1953
+ | "3xl"
1954
+ | "10"
1955
+ | "12"
1956
+ | "16"
1957
+ | "20"
1958
+ | "24"
1959
+ | "32"
1960
+ | "40"
1961
+ | "48"
1962
+ | "56"
1963
+ | "64"
1964
+ | "80"
1965
+ | "224"
1966
+ | "384"
1967
+ | "auto"
1968
+ | "fit"
1969
+ | "full"
1970
+ | "lg"
1971
+ | "max"
1972
+ | "md"
1973
+ | "min"
1974
+ | "sm"
1975
+ | "xl"
1976
+ | "xs";
1977
+ /**
1978
+ * Set the element's `text-align` CSS property
1979
+ */
1980
+ export type SprinklePropTextAlign = "center" | "end" | "justify" | "start";
1981
+ /**
1982
+ * Set the element's `text-transform` CSS property
1983
+ */
1984
+ export type SprinklePropTextTransform = "capitalize" | "none" | "uppercase";
1985
+ /**
1986
+ * Control which CSS properties should transition
1987
+ */
1988
+ export type SprinklePropTransition =
1989
+ | "all"
1990
+ | "colors"
1991
+ | "none"
1992
+ | "opacity"
1993
+ | "transform";
1994
+ /**
1995
+ * Set the element's width. Only accepts predefined size tokens.
1996
+ */
1997
+ export type SprinklePropW =
1998
+ | "0"
1999
+ | "1/2"
2000
+ | "1/3"
2001
+ | "1/4"
2002
+ | "2/3"
2003
+ | "2xs"
2004
+ | "3/4"
2005
+ | "3xl"
2006
+ | "10"
2007
+ | "12"
2008
+ | "16"
2009
+ | "20"
2010
+ | "24"
2011
+ | "32"
2012
+ | "40"
2013
+ | "48"
2014
+ | "56"
2015
+ | "64"
2016
+ | "80"
2017
+ | "224"
2018
+ | "384"
2019
+ | "auto"
2020
+ | "fit"
2021
+ | "full"
2022
+ | "lg"
2023
+ | "max"
2024
+ | "md"
2025
+ | "min"
2026
+ | "sm"
2027
+ | "xl"
2028
+ | "xs";
2029
+ /**
2030
+ * Set the element's `white-space` CSS property
2031
+ */
2032
+ export type SprinklePropWhiteSpace = "nowrap";
2033
+ /**
2034
+ * Set the element's stacking order. Only accepts predefined zIndex tokens (e.g., popover, toast, tooltip) or numeric values (0, 10, 20, 30, auto).
2035
+ */
2036
+ export type SprinklePropZ =
2037
+ | "0"
2038
+ | "10"
2039
+ | "20"
2040
+ | "30"
2041
+ | "auto"
2042
+ | "popover"
2043
+ | "toast"
2044
+ | "tooltip";
2045
+
2046
+ /**
2047
+ * Builder namespace for Adaptive UI Document components.
2048
+ *
2049
+ * Usage:
2050
+ * UI.Document({ children: [...] })
2051
+ * UI.Heading({ children: "Title", level: "2" })
2052
+ * UI.Input({ name: "field_name", placeholder: "Enter..." })
2053
+ */
2054
+ export const UI = {
2055
+ Action: (props: Omit<ProteusAction, "$type">): ProteusAction => ({
2056
+ $type: "Action" as const,
2057
+ ...props,
2058
+ }),
2059
+ CancelAction: (
2060
+ props: Omit<ProteusCancelAction, "$type">,
2061
+ ): ProteusCancelAction => ({ $type: "CancelAction" as const, ...props }),
2062
+ Document: (props: Omit<ProteusDocument, "$type">): ProteusDocument => ({
2063
+ $type: "Document" as const,
2064
+ ...props,
2065
+ }),
2066
+ Field: (props: Omit<ProteusField, "$type">): ProteusField => ({
2067
+ $type: "Field" as const,
2068
+ ...props,
2069
+ }),
2070
+ Group: (props: Omit<ProteusGroup, "$type">): ProteusGroup => ({
2071
+ $type: "Group" as const,
2072
+ ...props,
2073
+ }),
2074
+ Heading: (props: Omit<ProteusHeading, "$type">): ProteusHeading => ({
2075
+ $type: "Heading" as const,
2076
+ ...props,
2077
+ }),
2078
+ Image: (props: Omit<ProteusImage, "$type">): ProteusImage => ({
2079
+ $type: "Image" as const,
2080
+ ...props,
2081
+ }),
2082
+ Input: (props: Omit<ProteusInput, "$type">): ProteusInput => ({
2083
+ $type: "Input" as const,
2084
+ ...props,
2085
+ }),
2086
+ Link: (props: Omit<ProteusLink, "$type">): ProteusLink => ({
2087
+ $type: "Link" as const,
2088
+ ...props,
2089
+ }),
2090
+ Map: (props: Omit<ProteusMap, "$type">): ProteusMap => ({
2091
+ $type: "Map" as const,
2092
+ ...props,
2093
+ }),
2094
+ MIME_TYPE: "application/vnd.opal.proteus+json" as const,
2095
+ Range: (props: Omit<ProteusRange, "$type">): ProteusRange => ({
2096
+ $type: "Range" as const,
2097
+ ...props,
2098
+ }),
2099
+ Select: (props: Omit<ProteusSelect, "$type">): ProteusSelect => ({
2100
+ $type: "Select" as const,
2101
+ ...props,
2102
+ }),
2103
+ SelectContent: (
2104
+ props: Omit<ProteusSelectContent, "$type">,
2105
+ ): ProteusSelectContent => ({ $type: "SelectContent" as const, ...props }),
2106
+ SelectTrigger: (
2107
+ props: Omit<ProteusSelectTrigger, "$type">,
2108
+ ): ProteusSelectTrigger => ({ $type: "SelectTrigger" as const, ...props }),
2109
+ Separator: (props: Omit<ProteusSeparator, "$type">): ProteusSeparator => ({
2110
+ $type: "Separator" as const,
2111
+ ...props,
2112
+ }),
2113
+ Show: (props: Omit<ProteusShow, "$type">): ProteusShow => ({
2114
+ $type: "Show" as const,
2115
+ ...props,
2116
+ }),
2117
+ Text: (props: Omit<ProteusText, "$type">): ProteusText => ({
2118
+ $type: "Text" as const,
2119
+ ...props,
2120
+ }),
2121
+ Textarea: (props: Omit<ProteusTextarea, "$type">): ProteusTextarea => ({
2122
+ $type: "Textarea" as const,
2123
+ ...props,
2124
+ }),
2125
+ Value: (props: Omit<ProteusValue, "$type">): ProteusValue => ({
2126
+ $type: "Value" as const,
2127
+ ...props,
2128
+ }),
2129
+ };