@wise/dynamic-flow-types 4.1.1 → 4.1.2
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/build/zod/schemas.ts +816 -816
- package/package.json +2 -2
package/build/zod/schemas.ts
CHANGED
|
@@ -2,54 +2,54 @@
|
|
|
2
2
|
import { z } from 'zod';
|
|
3
3
|
import {
|
|
4
4
|
type JsonElement,
|
|
5
|
-
type
|
|
6
|
-
type PollingOnError,
|
|
7
|
-
type ToolbarButton,
|
|
8
|
-
type Behavior,
|
|
9
|
-
type ToolbarItem,
|
|
10
|
-
type Toolbar,
|
|
11
|
-
type ModalBehavior,
|
|
12
|
-
type Layout,
|
|
13
|
-
type PersistAsync,
|
|
5
|
+
type Step,
|
|
14
6
|
type Schema,
|
|
7
|
+
type Layout,
|
|
8
|
+
type Polling,
|
|
15
9
|
type LinkHandler,
|
|
16
|
-
type
|
|
17
|
-
type ArraySchemaList,
|
|
18
|
-
type AlertLayout,
|
|
19
|
-
type BooleanSchema,
|
|
20
|
-
type ArraySchemaTuple,
|
|
21
|
-
type OneOfSchema,
|
|
22
|
-
type BlobSchema,
|
|
23
|
-
type StringSchema,
|
|
24
|
-
type ConstSchema,
|
|
25
|
-
type IntegerSchema,
|
|
26
|
-
type AllOfSchema,
|
|
27
|
-
type ArraySchema,
|
|
28
|
-
type NumberSchema,
|
|
29
|
-
type ObjectSchema,
|
|
30
|
-
type ModalResponseBody,
|
|
10
|
+
type Toolbar,
|
|
31
11
|
type AdditionalInfo,
|
|
32
|
-
type
|
|
33
|
-
type
|
|
34
|
-
type ModalLayout,
|
|
35
|
-
type ModalLayoutContent,
|
|
36
|
-
type TabsLayoutTab,
|
|
37
|
-
type ListLayout,
|
|
38
|
-
type ListLayoutCallToAction,
|
|
12
|
+
type Behavior,
|
|
13
|
+
type SectionLayoutCallToAction,
|
|
39
14
|
type ListLayoutItem,
|
|
40
|
-
type
|
|
15
|
+
type ListLayoutCallToAction,
|
|
41
16
|
type ColumnsLayout,
|
|
17
|
+
type StatusListLayoutItem,
|
|
18
|
+
type ItemCallToAction,
|
|
19
|
+
type StatusListLayout,
|
|
20
|
+
type AlertLayout,
|
|
21
|
+
type BoxLayout,
|
|
22
|
+
type ButtonLayout,
|
|
42
23
|
type DecisionLayout,
|
|
24
|
+
type ListLayout,
|
|
25
|
+
type ModalLayout,
|
|
43
26
|
type ReviewLayout,
|
|
44
27
|
type SectionLayout,
|
|
45
|
-
type StatusListLayout,
|
|
46
28
|
type TabsLayout,
|
|
29
|
+
type TabsLayoutTab,
|
|
30
|
+
type ModalLayoutContent,
|
|
47
31
|
type DecisionLayoutOption,
|
|
48
|
-
type StatusListLayoutItem,
|
|
49
|
-
type ItemCallToAction,
|
|
50
|
-
type ReviewLayoutField,
|
|
51
32
|
type ReviewLayoutCallToAction,
|
|
52
|
-
type
|
|
33
|
+
type ReviewLayoutField,
|
|
34
|
+
type AlertLayoutCallToAction,
|
|
35
|
+
type ModalResponseBody,
|
|
36
|
+
type AllOfSchema,
|
|
37
|
+
type NumberSchema,
|
|
38
|
+
type PersistAsync,
|
|
39
|
+
type StringSchema,
|
|
40
|
+
type IntegerSchema,
|
|
41
|
+
type BooleanSchema,
|
|
42
|
+
type BlobSchema,
|
|
43
|
+
type ConstSchema,
|
|
44
|
+
type OneOfSchema,
|
|
45
|
+
type ObjectSchema,
|
|
46
|
+
type ArraySchema,
|
|
47
|
+
type ArraySchemaList,
|
|
48
|
+
type ArraySchemaTuple,
|
|
49
|
+
type PollingOnError,
|
|
50
|
+
type ModalBehavior,
|
|
51
|
+
type ToolbarButton,
|
|
52
|
+
type ToolbarItem,
|
|
53
53
|
} from '../spec';
|
|
54
54
|
|
|
55
55
|
export const jsonElementSchema: z.ZodSchema<JsonElement> = z.lazy(() =>
|
|
@@ -64,26 +64,14 @@ export const jsonElementSchema: z.ZodSchema<JsonElement> = z.lazy(() =>
|
|
|
64
64
|
.nullable(),
|
|
65
65
|
);
|
|
66
66
|
|
|
67
|
-
export const
|
|
68
|
-
text: z.string().optional(),
|
|
69
|
-
url: z.string().optional(),
|
|
70
|
-
uri: z.string().optional(),
|
|
71
|
-
accessibilityDescription: z.string().optional(),
|
|
72
|
-
});
|
|
73
|
-
|
|
74
|
-
export const linkSchema = z.object({
|
|
67
|
+
export const externalSchema = z.object({
|
|
75
68
|
url: z.string(),
|
|
76
69
|
});
|
|
77
70
|
|
|
78
|
-
export const
|
|
79
|
-
z.
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
z.literal('positive'),
|
|
83
|
-
z.literal('negative'),
|
|
84
|
-
]);
|
|
85
|
-
|
|
86
|
-
export const uploadSourceSchema = z.union([z.literal('camera'), z.literal('file')]);
|
|
71
|
+
export const stepErrorSchema = z.object({
|
|
72
|
+
error: z.string().optional(),
|
|
73
|
+
validation: jsonElementSchema.optional(),
|
|
74
|
+
});
|
|
87
75
|
|
|
88
76
|
export const contextSchema = z.union([
|
|
89
77
|
z.literal('positive'),
|
|
@@ -96,114 +84,6 @@ export const contextSchema = z.union([
|
|
|
96
84
|
z.literal('primary'),
|
|
97
85
|
]);
|
|
98
86
|
|
|
99
|
-
export const httpMethodSchema = z.union([
|
|
100
|
-
z.literal('GET'),
|
|
101
|
-
z.literal('POST'),
|
|
102
|
-
z.literal('PUT'),
|
|
103
|
-
z.literal('PATCH'),
|
|
104
|
-
z.literal('DELETE'),
|
|
105
|
-
]);
|
|
106
|
-
|
|
107
|
-
export const dismissBehaviorSchema = z.object({
|
|
108
|
-
type: z.literal('dismiss'),
|
|
109
|
-
});
|
|
110
|
-
|
|
111
|
-
export const navigationStackBehaviorSchema = z.union([
|
|
112
|
-
z.literal('default'),
|
|
113
|
-
z.literal('remove-previous'),
|
|
114
|
-
z.literal('remove-all'),
|
|
115
|
-
z.literal('replace-current'),
|
|
116
|
-
]);
|
|
117
|
-
|
|
118
|
-
export const copyBehaviorSchema = z.object({
|
|
119
|
-
type: z.literal('copy'),
|
|
120
|
-
content: z.string(),
|
|
121
|
-
});
|
|
122
|
-
|
|
123
|
-
export const externalSchema = z.object({
|
|
124
|
-
url: z.string(),
|
|
125
|
-
});
|
|
126
|
-
|
|
127
|
-
export const summaryProviderSchema = z.object({
|
|
128
|
-
providesTitle: z.boolean().optional(),
|
|
129
|
-
providesDescription: z.boolean().optional(),
|
|
130
|
-
providesIcon: z.boolean().optional(),
|
|
131
|
-
providesImage: z.boolean().optional(),
|
|
132
|
-
providesMedia: z.boolean().optional(),
|
|
133
|
-
});
|
|
134
|
-
|
|
135
|
-
export const refreshBehaviorSchema = z.object({
|
|
136
|
-
type: z.literal('refresh'),
|
|
137
|
-
});
|
|
138
|
-
|
|
139
|
-
export const stepErrorSchema = z.object({
|
|
140
|
-
error: z.string().optional(),
|
|
141
|
-
validation: jsonElementSchema.optional(),
|
|
142
|
-
});
|
|
143
|
-
|
|
144
|
-
export const actionSchema = z.object({
|
|
145
|
-
title: z.string().optional(),
|
|
146
|
-
type: actionTypeSchema.optional(),
|
|
147
|
-
disabled: z.boolean().optional(),
|
|
148
|
-
$id: z.string().optional(),
|
|
149
|
-
$ref: z.string().optional(),
|
|
150
|
-
id: z.string().optional(),
|
|
151
|
-
url: z.string().optional(),
|
|
152
|
-
method: httpMethodSchema.optional(),
|
|
153
|
-
exit: z.boolean().optional(),
|
|
154
|
-
result: jsonElementSchema.optional(),
|
|
155
|
-
data: jsonElementSchema.optional(),
|
|
156
|
-
timeout: z.number().optional(),
|
|
157
|
-
skipValidation: z.boolean().optional(),
|
|
158
|
-
prefetch: z.boolean().optional(),
|
|
159
|
-
});
|
|
160
|
-
|
|
161
|
-
export const linkBehaviorSchema = z.object({
|
|
162
|
-
type: z.literal('link'),
|
|
163
|
-
url: z.string(),
|
|
164
|
-
});
|
|
165
|
-
|
|
166
|
-
export const validateAsyncSchema = z.object({
|
|
167
|
-
param: z.string(),
|
|
168
|
-
method: httpMethodSchema,
|
|
169
|
-
url: z.string(),
|
|
170
|
-
});
|
|
171
|
-
|
|
172
|
-
export const navigationBackBehaviorSchema = z.object({
|
|
173
|
-
title: z.string().optional(),
|
|
174
|
-
action: actionSchema,
|
|
175
|
-
});
|
|
176
|
-
|
|
177
|
-
export const helpSchema = z.object({
|
|
178
|
-
markdown: z.string(),
|
|
179
|
-
});
|
|
180
|
-
|
|
181
|
-
export const actionBehaviorSchema = z.object({
|
|
182
|
-
type: z.literal('action'),
|
|
183
|
-
action: actionSchema,
|
|
184
|
-
});
|
|
185
|
-
|
|
186
|
-
export const containerBehaviorSchema = z.object({
|
|
187
|
-
action: actionSchema.optional(),
|
|
188
|
-
link: linkSchema.optional(),
|
|
189
|
-
});
|
|
190
|
-
|
|
191
|
-
export const navigationSchema = z.object({
|
|
192
|
-
backButton: navigationBackBehaviorSchema.optional(),
|
|
193
|
-
back: navigationBackBehaviorSchema.optional(),
|
|
194
|
-
stackBehavior: navigationStackBehaviorSchema.optional(),
|
|
195
|
-
});
|
|
196
|
-
|
|
197
|
-
export const supportingValuesSchema = z.object({
|
|
198
|
-
value: z.string().optional(),
|
|
199
|
-
subvalue: z.string().optional(),
|
|
200
|
-
});
|
|
201
|
-
|
|
202
|
-
export const inlineAlertSchema = z.object({
|
|
203
|
-
content: z.string(),
|
|
204
|
-
context: contextSchema.optional(),
|
|
205
|
-
});
|
|
206
|
-
|
|
207
87
|
export const autocompleteTokenSchema = z.union([
|
|
208
88
|
z.literal('on'),
|
|
209
89
|
z.literal('name'),
|
|
@@ -270,43 +150,6 @@ export const autocompleteTokenSchema = z.union([
|
|
|
270
150
|
z.literal('pager'),
|
|
271
151
|
]);
|
|
272
152
|
|
|
273
|
-
export const stringSchemaFormatSchema = z.union([
|
|
274
|
-
z.literal('date'),
|
|
275
|
-
z.literal('email'),
|
|
276
|
-
z.literal('numeric'),
|
|
277
|
-
z.literal('password'),
|
|
278
|
-
z.literal('phone-number'),
|
|
279
|
-
z.literal('base64url'),
|
|
280
|
-
]);
|
|
281
|
-
|
|
282
|
-
export const autocapitalizationTypeSchema = z.union([
|
|
283
|
-
z.literal('none'),
|
|
284
|
-
z.literal('characters'),
|
|
285
|
-
z.literal('sentences'),
|
|
286
|
-
z.literal('words'),
|
|
287
|
-
]);
|
|
288
|
-
|
|
289
|
-
export const searchSearchRequestSchema = z.object({
|
|
290
|
-
url: z.string(),
|
|
291
|
-
method: httpMethodSchema,
|
|
292
|
-
param: z.string(),
|
|
293
|
-
query: z.string(),
|
|
294
|
-
});
|
|
295
|
-
|
|
296
|
-
export const actionResponseBodySchema = z.object({
|
|
297
|
-
action: actionSchema,
|
|
298
|
-
});
|
|
299
|
-
|
|
300
|
-
export const errorResponseBodySchema = z.object({
|
|
301
|
-
refreshFormUrl: z.string().optional(),
|
|
302
|
-
analytics: z.record(z.string()).optional(),
|
|
303
|
-
error: z.string().optional(),
|
|
304
|
-
validation: jsonElementSchema.optional(),
|
|
305
|
-
refreshUrl: z.string().optional(),
|
|
306
|
-
});
|
|
307
|
-
|
|
308
|
-
export const alignSchema = z.union([z.literal('left'), z.literal('center'), z.literal('right')]);
|
|
309
|
-
|
|
310
153
|
export const iconNamedSchema = z.object({
|
|
311
154
|
name: z.string(),
|
|
312
155
|
});
|
|
@@ -315,46 +158,95 @@ export const iconTextSchema = z.object({
|
|
|
315
158
|
text: z.string(),
|
|
316
159
|
});
|
|
317
160
|
|
|
318
|
-
export const
|
|
319
|
-
z.
|
|
320
|
-
z.
|
|
321
|
-
z.
|
|
322
|
-
z.literal('lg'),
|
|
323
|
-
z.literal('xl'),
|
|
324
|
-
]);
|
|
325
|
-
|
|
326
|
-
export const mediaImageSchema = z.object({
|
|
327
|
-
type: z.literal('image'),
|
|
328
|
-
uri: z.string(),
|
|
161
|
+
export const imageSchema = z.object({
|
|
162
|
+
text: z.string().optional(),
|
|
163
|
+
url: z.string().optional(),
|
|
164
|
+
uri: z.string().optional(),
|
|
329
165
|
accessibilityDescription: z.string().optional(),
|
|
330
166
|
});
|
|
331
167
|
|
|
168
|
+
export const supportingValuesSchema = z.object({
|
|
169
|
+
value: z.string().optional(),
|
|
170
|
+
subvalue: z.string().optional(),
|
|
171
|
+
});
|
|
172
|
+
|
|
332
173
|
export const avatarUriContentSchema = z.object({
|
|
333
174
|
type: z.literal('uri'),
|
|
334
175
|
uri: z.string(),
|
|
335
176
|
badgeUri: z.string().optional(),
|
|
336
177
|
});
|
|
337
178
|
|
|
179
|
+
export const mediaImageSchema = z.object({
|
|
180
|
+
type: z.literal('image'),
|
|
181
|
+
uri: z.string(),
|
|
182
|
+
accessibilityDescription: z.string().optional(),
|
|
183
|
+
});
|
|
184
|
+
|
|
338
185
|
export const avatarTextContentSchema = z.object({
|
|
339
186
|
type: z.literal('text'),
|
|
340
187
|
text: z.string(),
|
|
341
188
|
badgeUri: z.string().optional(),
|
|
342
189
|
});
|
|
343
190
|
|
|
344
|
-
export const
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
margin: sizeSchema.optional(),
|
|
351
|
-
analyticsId: z.string().optional(),
|
|
191
|
+
export const avatarContentSchema = z.union([avatarTextContentSchema, avatarUriContentSchema]);
|
|
192
|
+
|
|
193
|
+
export const mediaAvatarSchema = z.object({
|
|
194
|
+
type: z.literal('avatar'),
|
|
195
|
+
content: z.array(avatarContentSchema),
|
|
196
|
+
accessibilityDescription: z.string().optional(),
|
|
352
197
|
});
|
|
353
198
|
|
|
354
|
-
export const
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
199
|
+
export const sizeSchema = z.union([
|
|
200
|
+
z.literal('xs'),
|
|
201
|
+
z.literal('sm'),
|
|
202
|
+
z.literal('md'),
|
|
203
|
+
z.literal('lg'),
|
|
204
|
+
z.literal('xl'),
|
|
205
|
+
]);
|
|
206
|
+
|
|
207
|
+
export const httpMethodSchema = z.union([
|
|
208
|
+
z.literal('GET'),
|
|
209
|
+
z.literal('POST'),
|
|
210
|
+
z.literal('PUT'),
|
|
211
|
+
z.literal('PATCH'),
|
|
212
|
+
z.literal('DELETE'),
|
|
213
|
+
]);
|
|
214
|
+
|
|
215
|
+
export const inlineAlertSchema = z.object({
|
|
216
|
+
content: z.string(),
|
|
217
|
+
context: contextSchema.optional(),
|
|
218
|
+
});
|
|
219
|
+
|
|
220
|
+
export const autocapitalizationTypeSchema = z.union([
|
|
221
|
+
z.literal('none'),
|
|
222
|
+
z.literal('characters'),
|
|
223
|
+
z.literal('sentences'),
|
|
224
|
+
z.literal('words'),
|
|
225
|
+
]);
|
|
226
|
+
|
|
227
|
+
export const alignSchema = z.union([z.literal('left'), z.literal('center'), z.literal('right')]);
|
|
228
|
+
|
|
229
|
+
export const listLayoutStatusSchema = z.union([
|
|
230
|
+
z.literal('warning'),
|
|
231
|
+
z.literal('neutral'),
|
|
232
|
+
z.literal('positive'),
|
|
233
|
+
]);
|
|
234
|
+
|
|
235
|
+
export const iconSchema = z.union([iconNamedSchema, iconTextSchema]);
|
|
236
|
+
|
|
237
|
+
export const mediaSchema = z.union([mediaAvatarSchema, mediaImageSchema]);
|
|
238
|
+
|
|
239
|
+
export const columnsLayoutBiasSchema = z.union([
|
|
240
|
+
z.literal('none'),
|
|
241
|
+
z.literal('left'),
|
|
242
|
+
z.literal('right'),
|
|
243
|
+
]);
|
|
244
|
+
|
|
245
|
+
export const loadingIndicatorLayoutSchema = z.object({
|
|
246
|
+
type: z.literal('loading-indicator'),
|
|
247
|
+
size: sizeSchema.optional(),
|
|
248
|
+
control: z.string().optional(),
|
|
249
|
+
margin: sizeSchema.optional(),
|
|
358
250
|
analyticsId: z.string().optional(),
|
|
359
251
|
tags: z.array(z.string()).optional(),
|
|
360
252
|
});
|
|
@@ -365,33 +257,41 @@ export const statusListLayoutStatusSchema = z.union([
|
|
|
365
257
|
z.literal('done'),
|
|
366
258
|
]);
|
|
367
259
|
|
|
368
|
-
export const
|
|
369
|
-
type: z.literal('
|
|
370
|
-
title: z.string()
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
help: helpSchema.optional(),
|
|
260
|
+
export const searchLayoutSchema = z.object({
|
|
261
|
+
type: z.literal('search'),
|
|
262
|
+
title: z.string(),
|
|
263
|
+
method: httpMethodSchema,
|
|
264
|
+
url: z.string(),
|
|
265
|
+
param: z.string(),
|
|
266
|
+
emptyMessage: z.string().optional(),
|
|
376
267
|
control: z.string().optional(),
|
|
377
268
|
margin: sizeSchema.optional(),
|
|
378
269
|
analyticsId: z.string().optional(),
|
|
379
270
|
tags: z.array(z.string()).optional(),
|
|
380
271
|
});
|
|
381
272
|
|
|
382
|
-
export const
|
|
383
|
-
|
|
273
|
+
export const instructionsLayoutItemSchema = z.object({
|
|
274
|
+
text: z.string(),
|
|
275
|
+
context: contextSchema,
|
|
276
|
+
tag: z.string().optional(),
|
|
277
|
+
analyticsId: z.string().optional(),
|
|
278
|
+
tags: z.array(z.string()).optional(),
|
|
279
|
+
});
|
|
280
|
+
|
|
281
|
+
export const imageLayoutSchema = z.object({
|
|
282
|
+
type: z.literal('image'),
|
|
283
|
+
text: z.string().optional(),
|
|
284
|
+
url: z.string().optional(),
|
|
285
|
+
accessibilityDescription: z.string().optional(),
|
|
286
|
+
content: imageSchema.optional(),
|
|
384
287
|
size: sizeSchema.optional(),
|
|
385
288
|
control: z.string().optional(),
|
|
386
289
|
margin: sizeSchema.optional(),
|
|
290
|
+
align: alignSchema.optional(),
|
|
387
291
|
analyticsId: z.string().optional(),
|
|
388
292
|
tags: z.array(z.string()).optional(),
|
|
389
293
|
});
|
|
390
294
|
|
|
391
|
-
export const modalLayoutTriggerSchema = z.object({
|
|
392
|
-
title: z.string(),
|
|
393
|
-
});
|
|
394
|
-
|
|
395
295
|
export const dividerLayoutSchema = z.object({
|
|
396
296
|
type: z.literal('divider'),
|
|
397
297
|
control: z.string().optional(),
|
|
@@ -411,18 +311,14 @@ export const headingLayoutSchema = z.object({
|
|
|
411
311
|
tags: z.array(z.string()).optional(),
|
|
412
312
|
});
|
|
413
313
|
|
|
414
|
-
export const
|
|
415
|
-
type: z.literal('
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
content: imageSchema.optional(),
|
|
420
|
-
size: sizeSchema.optional(),
|
|
314
|
+
export const infoLayoutSchema = z.object({
|
|
315
|
+
type: z.literal('info'),
|
|
316
|
+
tags: z.array(z.string()).optional(),
|
|
317
|
+
markdown: z.string(),
|
|
318
|
+
align: alignSchema.optional(),
|
|
421
319
|
control: z.string().optional(),
|
|
422
320
|
margin: sizeSchema.optional(),
|
|
423
|
-
align: alignSchema.optional(),
|
|
424
321
|
analyticsId: z.string().optional(),
|
|
425
|
-
tags: z.array(z.string()).optional(),
|
|
426
322
|
});
|
|
427
323
|
|
|
428
324
|
export const instructionsLayoutSchema = z.object({
|
|
@@ -457,68 +353,82 @@ export const paragraphLayoutSchema = z.object({
|
|
|
457
353
|
size: sizeSchema.optional(),
|
|
458
354
|
});
|
|
459
355
|
|
|
460
|
-
export const
|
|
461
|
-
type: z.literal('search'),
|
|
356
|
+
export const modalLayoutTriggerSchema = z.object({
|
|
462
357
|
title: z.string(),
|
|
463
|
-
method: httpMethodSchema,
|
|
464
|
-
url: z.string(),
|
|
465
|
-
param: z.string(),
|
|
466
|
-
emptyMessage: z.string().optional(),
|
|
467
|
-
control: z.string().optional(),
|
|
468
|
-
margin: sizeSchema.optional(),
|
|
469
|
-
analyticsId: z.string().optional(),
|
|
470
|
-
tags: z.array(z.string()).optional(),
|
|
471
358
|
});
|
|
472
359
|
|
|
473
360
|
export const formLayoutSchemaReferenceSchema = z.object({
|
|
474
361
|
$ref: z.string(),
|
|
475
362
|
});
|
|
476
363
|
|
|
477
|
-
export const
|
|
478
|
-
|
|
479
|
-
export const listLayoutStatusSchema = z.union([
|
|
480
|
-
z.literal('warning'),
|
|
481
|
-
z.literal('neutral'),
|
|
482
|
-
z.literal('positive'),
|
|
483
|
-
]);
|
|
484
|
-
|
|
485
|
-
export const columnsLayoutBiasSchema = z.union([
|
|
486
|
-
z.literal('none'),
|
|
487
|
-
z.literal('left'),
|
|
488
|
-
z.literal('right'),
|
|
489
|
-
]);
|
|
490
|
-
|
|
491
|
-
export const avatarContentSchema = z.union([avatarTextContentSchema, avatarUriContentSchema]);
|
|
492
|
-
|
|
493
|
-
export const mediaAvatarSchema = z.object({
|
|
494
|
-
type: z.literal('avatar'),
|
|
495
|
-
content: z.array(avatarContentSchema),
|
|
496
|
-
accessibilityDescription: z.string().optional(),
|
|
364
|
+
export const helpSchema = z.object({
|
|
365
|
+
markdown: z.string(),
|
|
497
366
|
});
|
|
498
367
|
|
|
499
|
-
export const
|
|
500
|
-
type: z.literal('
|
|
501
|
-
|
|
502
|
-
|
|
368
|
+
export const progressLayoutSchema = z.object({
|
|
369
|
+
type: z.literal('progress'),
|
|
370
|
+
title: z.string().optional(),
|
|
371
|
+
description: z.string().optional(),
|
|
372
|
+
progress: z.number(),
|
|
373
|
+
progressText: z.string(),
|
|
374
|
+
context: contextSchema.optional(),
|
|
375
|
+
help: helpSchema.optional(),
|
|
503
376
|
control: z.string().optional(),
|
|
504
377
|
margin: sizeSchema.optional(),
|
|
505
378
|
analyticsId: z.string().optional(),
|
|
506
379
|
tags: z.array(z.string()).optional(),
|
|
507
380
|
});
|
|
508
381
|
|
|
509
|
-
export const
|
|
382
|
+
export const errorResponseBodySchema = z.object({
|
|
383
|
+
refreshFormUrl: z.string().optional(),
|
|
384
|
+
analytics: z.record(z.string()).optional(),
|
|
385
|
+
error: z.string().optional(),
|
|
386
|
+
validation: jsonElementSchema.optional(),
|
|
387
|
+
refreshUrl: z.string().optional(),
|
|
388
|
+
});
|
|
510
389
|
|
|
511
|
-
export const
|
|
512
|
-
|
|
513
|
-
|
|
390
|
+
export const searchSearchRequestSchema = z.object({
|
|
391
|
+
url: z.string(),
|
|
392
|
+
method: httpMethodSchema,
|
|
393
|
+
param: z.string(),
|
|
394
|
+
query: z.string(),
|
|
395
|
+
});
|
|
396
|
+
|
|
397
|
+
export const searchResultSearchSchema = z.object({
|
|
398
|
+
type: z.literal('search'),
|
|
399
|
+
title: z.string(),
|
|
400
|
+
description: z.string().optional(),
|
|
514
401
|
icon: iconSchema.optional(),
|
|
515
402
|
image: imageSchema.optional(),
|
|
516
|
-
|
|
403
|
+
value: searchSearchRequestSchema,
|
|
517
404
|
media: mediaSchema.optional(),
|
|
518
|
-
analyticsId: z.string().optional(),
|
|
519
|
-
tags: z.array(z.string()).optional(),
|
|
520
405
|
});
|
|
521
406
|
|
|
407
|
+
export const summaryProviderSchema = z.object({
|
|
408
|
+
providesTitle: z.boolean().optional(),
|
|
409
|
+
providesDescription: z.boolean().optional(),
|
|
410
|
+
providesIcon: z.boolean().optional(),
|
|
411
|
+
providesImage: z.boolean().optional(),
|
|
412
|
+
providesMedia: z.boolean().optional(),
|
|
413
|
+
});
|
|
414
|
+
|
|
415
|
+
export const validateAsyncSchema = z.object({
|
|
416
|
+
param: z.string(),
|
|
417
|
+
method: httpMethodSchema,
|
|
418
|
+
url: z.string(),
|
|
419
|
+
});
|
|
420
|
+
|
|
421
|
+
export const stringSchemaFormatSchema = z.union([
|
|
422
|
+
z.literal('date'),
|
|
423
|
+
z.literal('email'),
|
|
424
|
+
z.literal('numeric'),
|
|
425
|
+
z.literal('password'),
|
|
426
|
+
z.literal('phone-number'),
|
|
427
|
+
z.literal('base64url'),
|
|
428
|
+
]);
|
|
429
|
+
|
|
430
|
+
export const uploadSourceSchema = z.union([z.literal('camera'), z.literal('file')]);
|
|
431
|
+
|
|
522
432
|
export const summarySummariserSchema = z.object({
|
|
523
433
|
defaultTitle: z.string().optional(),
|
|
524
434
|
defaultDescription: z.string().optional(),
|
|
@@ -532,99 +442,167 @@ export const summarySummariserSchema = z.object({
|
|
|
532
442
|
providesMedia: z.boolean().optional(),
|
|
533
443
|
});
|
|
534
444
|
|
|
535
|
-
export const
|
|
536
|
-
|
|
537
|
-
});
|
|
538
|
-
|
|
539
|
-
export const searchResultActionSchema = z.object({
|
|
540
|
-
type: z.literal('action'),
|
|
541
|
-
title: z.string(),
|
|
542
|
-
description: z.string().optional(),
|
|
543
|
-
icon: iconSchema.optional(),
|
|
544
|
-
image: imageSchema.optional(),
|
|
545
|
-
value: actionSchema,
|
|
546
|
-
media: mediaSchema.optional(),
|
|
445
|
+
export const dismissBehaviorSchema = z.object({
|
|
446
|
+
type: z.literal('dismiss'),
|
|
547
447
|
});
|
|
548
448
|
|
|
549
|
-
export const
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
description: z.string().optional(),
|
|
449
|
+
export const suggestionsValueSchema = z.object({
|
|
450
|
+
label: z.string(),
|
|
451
|
+
value: jsonElementSchema,
|
|
553
452
|
icon: iconSchema.optional(),
|
|
554
453
|
image: imageSchema.optional(),
|
|
555
|
-
|
|
454
|
+
tag: z.string().optional(),
|
|
556
455
|
media: mediaSchema.optional(),
|
|
456
|
+
analyticsId: z.string().optional(),
|
|
457
|
+
tags: z.array(z.string()).optional(),
|
|
557
458
|
});
|
|
558
459
|
|
|
559
|
-
export const
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
460
|
+
export const actionTypeSchema = z.union([
|
|
461
|
+
z.literal('primary'),
|
|
462
|
+
z.literal('secondary'),
|
|
463
|
+
z.literal('link'),
|
|
464
|
+
z.literal('positive'),
|
|
465
|
+
z.literal('negative'),
|
|
466
|
+
]);
|
|
467
|
+
|
|
468
|
+
export const navigationStackBehaviorSchema = z.union([
|
|
469
|
+
z.literal('default'),
|
|
470
|
+
z.literal('remove-previous'),
|
|
471
|
+
z.literal('remove-all'),
|
|
472
|
+
z.literal('replace-current'),
|
|
473
|
+
]);
|
|
564
474
|
|
|
565
475
|
export const summarySchema = z.union([summaryProviderSchema, summarySummariserSchema]);
|
|
566
476
|
|
|
567
|
-
export const
|
|
568
|
-
z.
|
|
569
|
-
|
|
570
|
-
url: z.string(),
|
|
571
|
-
delay: z.number().optional(),
|
|
572
|
-
timeout: z.number().optional(),
|
|
573
|
-
maxAttempts: z.number(),
|
|
574
|
-
onError: pollingOnErrorSchema,
|
|
575
|
-
}),
|
|
576
|
-
);
|
|
477
|
+
export const linkSchema = z.object({
|
|
478
|
+
url: z.string(),
|
|
479
|
+
});
|
|
577
480
|
|
|
578
|
-
export const
|
|
579
|
-
z.
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
)
|
|
481
|
+
export const actionSchema = z.object({
|
|
482
|
+
title: z.string().optional(),
|
|
483
|
+
type: actionTypeSchema.optional(),
|
|
484
|
+
disabled: z.boolean().optional(),
|
|
485
|
+
$id: z.string().optional(),
|
|
486
|
+
$ref: z.string().optional(),
|
|
487
|
+
id: z.string().optional(),
|
|
488
|
+
url: z.string().optional(),
|
|
489
|
+
method: httpMethodSchema.optional(),
|
|
490
|
+
exit: z.boolean().optional(),
|
|
491
|
+
result: jsonElementSchema.optional(),
|
|
492
|
+
data: jsonElementSchema.optional(),
|
|
493
|
+
timeout: z.number().optional(),
|
|
494
|
+
skipValidation: z.boolean().optional(),
|
|
495
|
+
prefetch: z.boolean().optional(),
|
|
496
|
+
});
|
|
584
497
|
|
|
585
|
-
export const
|
|
586
|
-
z.
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
behavior: behaviorSchema,
|
|
590
|
-
accessibilityDescription: z.string().optional(),
|
|
591
|
-
media: mediaSchema.optional(),
|
|
592
|
-
control: z.string().optional(),
|
|
593
|
-
context: contextSchema.optional(),
|
|
594
|
-
disabled: z.boolean().optional(),
|
|
595
|
-
analyticsId: z.string().optional(),
|
|
596
|
-
tags: z.array(z.string()).optional(),
|
|
597
|
-
}),
|
|
598
|
-
);
|
|
498
|
+
export const actionBehaviorSchema = z.object({
|
|
499
|
+
type: z.literal('action'),
|
|
500
|
+
action: actionSchema,
|
|
501
|
+
});
|
|
599
502
|
|
|
600
|
-
export const
|
|
601
|
-
z.
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
copyBehaviorSchema,
|
|
605
|
-
dismissBehaviorSchema,
|
|
606
|
-
linkBehaviorSchema,
|
|
607
|
-
modalBehaviorSchema,
|
|
608
|
-
refreshBehaviorSchema,
|
|
609
|
-
]),
|
|
610
|
-
);
|
|
503
|
+
export const copyBehaviorSchema = z.object({
|
|
504
|
+
type: z.literal('copy'),
|
|
505
|
+
content: z.string(),
|
|
506
|
+
});
|
|
611
507
|
|
|
612
|
-
export const
|
|
508
|
+
export const linkBehaviorSchema = z.object({
|
|
509
|
+
type: z.literal('link'),
|
|
510
|
+
url: z.string(),
|
|
511
|
+
});
|
|
613
512
|
|
|
614
|
-
export const
|
|
513
|
+
export const refreshBehaviorSchema = z.object({
|
|
514
|
+
type: z.literal('refresh'),
|
|
515
|
+
});
|
|
516
|
+
|
|
517
|
+
export const containerBehaviorSchema = z.object({
|
|
518
|
+
action: actionSchema.optional(),
|
|
519
|
+
link: linkSchema.optional(),
|
|
520
|
+
});
|
|
521
|
+
|
|
522
|
+
export const navigationBackBehaviorSchema = z.object({
|
|
523
|
+
title: z.string().optional(),
|
|
524
|
+
action: actionSchema,
|
|
525
|
+
});
|
|
526
|
+
|
|
527
|
+
export const navigationSchema = z.object({
|
|
528
|
+
backButton: navigationBackBehaviorSchema.optional(),
|
|
529
|
+
back: navigationBackBehaviorSchema.optional(),
|
|
530
|
+
stackBehavior: navigationStackBehaviorSchema.optional(),
|
|
531
|
+
});
|
|
532
|
+
|
|
533
|
+
export const formLayoutSchema = z.object({
|
|
534
|
+
type: z.literal('form'),
|
|
535
|
+
schema: formLayoutSchemaReferenceSchema.optional(),
|
|
536
|
+
schemaId: z.string(),
|
|
537
|
+
control: z.string().optional(),
|
|
538
|
+
margin: sizeSchema.optional(),
|
|
539
|
+
analyticsId: z.string().optional(),
|
|
540
|
+
tags: z.array(z.string()).optional(),
|
|
541
|
+
});
|
|
542
|
+
|
|
543
|
+
export const actionResponseBodySchema = z.object({
|
|
544
|
+
action: actionSchema,
|
|
545
|
+
});
|
|
546
|
+
|
|
547
|
+
export const searchResultActionSchema = z.object({
|
|
548
|
+
type: z.literal('action'),
|
|
549
|
+
title: z.string(),
|
|
550
|
+
description: z.string().optional(),
|
|
551
|
+
icon: iconSchema.optional(),
|
|
552
|
+
image: imageSchema.optional(),
|
|
553
|
+
value: actionSchema,
|
|
554
|
+
media: mediaSchema.optional(),
|
|
555
|
+
});
|
|
556
|
+
|
|
557
|
+
export const searchResultSchema = z.union([searchResultActionSchema, searchResultSearchSchema]);
|
|
558
|
+
|
|
559
|
+
export const suggestionsSchema = z.object({
|
|
560
|
+
values: z.array(suggestionsValueSchema),
|
|
561
|
+
});
|
|
562
|
+
|
|
563
|
+
export const searchResponseBodySchema = z.object({
|
|
564
|
+
results: z.array(searchResultSchema),
|
|
565
|
+
});
|
|
566
|
+
|
|
567
|
+
export const stepSchema: z.ZodSchema<Step> = z.lazy(() =>
|
|
615
568
|
z.object({
|
|
616
|
-
|
|
569
|
+
key: z.string().optional(),
|
|
570
|
+
type: z.string().optional(),
|
|
571
|
+
actions: z.array(actionSchema).optional(),
|
|
572
|
+
refreshFormUrl: z.string().optional(),
|
|
573
|
+
id: z.string(),
|
|
574
|
+
title: z.string(),
|
|
575
|
+
schemas: z.array(schemaSchema),
|
|
576
|
+
layout: z.array(layoutSchema),
|
|
577
|
+
description: z.string().optional(),
|
|
578
|
+
model: jsonElementSchema.optional(),
|
|
579
|
+
external: externalSchema.optional(),
|
|
580
|
+
polling: pollingSchema.optional(),
|
|
581
|
+
linkHandlers: z.array(linkHandlerSchema).optional(),
|
|
582
|
+
analytics: z.record(z.string()).optional(),
|
|
583
|
+
errors: stepErrorSchema.optional(),
|
|
584
|
+
navigation: navigationSchema.optional(),
|
|
585
|
+
refreshUrl: z.string().optional(),
|
|
617
586
|
control: z.string().optional(),
|
|
587
|
+
refreshAfter: z.string().optional(),
|
|
588
|
+
toolbar: toolbarSchema.optional(),
|
|
618
589
|
tags: z.array(z.string()).optional(),
|
|
619
590
|
}),
|
|
620
591
|
);
|
|
621
592
|
|
|
622
|
-
export const
|
|
623
|
-
z.
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
593
|
+
export const schemaSchema: z.ZodSchema<Schema> = z.lazy(() =>
|
|
594
|
+
z.union([
|
|
595
|
+
allOfSchemaSchema,
|
|
596
|
+
arraySchemaSchema,
|
|
597
|
+
blobSchemaSchema,
|
|
598
|
+
booleanSchemaSchema,
|
|
599
|
+
constSchemaSchema,
|
|
600
|
+
integerSchemaSchema,
|
|
601
|
+
numberSchemaSchema,
|
|
602
|
+
objectSchemaSchema,
|
|
603
|
+
oneOfSchemaSchema,
|
|
604
|
+
stringSchemaSchema,
|
|
605
|
+
]),
|
|
628
606
|
);
|
|
629
607
|
|
|
630
608
|
export const layoutSchema: z.ZodSchema<Layout> = z.lazy(() =>
|
|
@@ -654,31 +632,17 @@ export const layoutSchema: z.ZodSchema<Layout> = z.lazy(() =>
|
|
|
654
632
|
]),
|
|
655
633
|
);
|
|
656
634
|
|
|
657
|
-
export const
|
|
635
|
+
export const pollingSchema: z.ZodSchema<Polling> = z.lazy(() =>
|
|
658
636
|
z.object({
|
|
659
|
-
|
|
660
|
-
idProperty: z.string(),
|
|
661
|
-
schema: schemaSchema,
|
|
637
|
+
interval: z.number().optional(),
|
|
662
638
|
url: z.string(),
|
|
663
|
-
|
|
639
|
+
delay: z.number().optional(),
|
|
640
|
+
timeout: z.number().optional(),
|
|
641
|
+
maxAttempts: z.number(),
|
|
642
|
+
onError: pollingOnErrorSchema,
|
|
664
643
|
}),
|
|
665
644
|
);
|
|
666
645
|
|
|
667
|
-
export const schemaSchema: z.ZodSchema<Schema> = z.lazy(() =>
|
|
668
|
-
z.union([
|
|
669
|
-
allOfSchemaSchema,
|
|
670
|
-
arraySchemaSchema,
|
|
671
|
-
blobSchemaSchema,
|
|
672
|
-
booleanSchemaSchema,
|
|
673
|
-
constSchemaSchema,
|
|
674
|
-
integerSchemaSchema,
|
|
675
|
-
numberSchemaSchema,
|
|
676
|
-
objectSchemaSchema,
|
|
677
|
-
oneOfSchemaSchema,
|
|
678
|
-
stringSchemaSchema,
|
|
679
|
-
]),
|
|
680
|
-
);
|
|
681
|
-
|
|
682
646
|
export const linkHandlerSchema: z.ZodSchema<LinkHandler> = z.lazy(() =>
|
|
683
647
|
z.object({
|
|
684
648
|
regexPattern: z.string(),
|
|
@@ -686,62 +650,114 @@ export const linkHandlerSchema: z.ZodSchema<LinkHandler> = z.lazy(() =>
|
|
|
686
650
|
}),
|
|
687
651
|
);
|
|
688
652
|
|
|
689
|
-
export const
|
|
653
|
+
export const toolbarSchema: z.ZodSchema<Toolbar> = z.lazy(() =>
|
|
690
654
|
z.object({
|
|
691
|
-
|
|
692
|
-
type: z.string().optional(),
|
|
693
|
-
actions: z.array(actionSchema).optional(),
|
|
694
|
-
refreshFormUrl: z.string().optional(),
|
|
695
|
-
id: z.string(),
|
|
696
|
-
title: z.string(),
|
|
697
|
-
schemas: z.array(schemaSchema),
|
|
698
|
-
layout: z.array(layoutSchema),
|
|
699
|
-
description: z.string().optional(),
|
|
700
|
-
model: jsonElementSchema.optional(),
|
|
701
|
-
external: externalSchema.optional(),
|
|
702
|
-
polling: pollingSchema.optional(),
|
|
703
|
-
linkHandlers: z.array(linkHandlerSchema).optional(),
|
|
704
|
-
analytics: z.record(z.string()).optional(),
|
|
705
|
-
errors: stepErrorSchema.optional(),
|
|
706
|
-
navigation: navigationSchema.optional(),
|
|
707
|
-
refreshUrl: z.string().optional(),
|
|
655
|
+
items: z.array(toolbarItemSchema),
|
|
708
656
|
control: z.string().optional(),
|
|
709
|
-
refreshAfter: z.string().optional(),
|
|
710
|
-
toolbar: toolbarSchema.optional(),
|
|
711
657
|
tags: z.array(z.string()).optional(),
|
|
712
658
|
}),
|
|
713
659
|
);
|
|
714
660
|
|
|
715
|
-
export const
|
|
661
|
+
export const additionalInfoSchema: z.ZodSchema<AdditionalInfo> = z.lazy(() =>
|
|
716
662
|
z.object({
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
663
|
+
text: z.string(),
|
|
664
|
+
behavior: behaviorSchema.optional(),
|
|
665
|
+
accessibilityDescription: z.string().optional(),
|
|
666
|
+
}),
|
|
667
|
+
);
|
|
668
|
+
|
|
669
|
+
export const behaviorSchema: z.ZodSchema<Behavior> = z.lazy(() =>
|
|
670
|
+
z.union([
|
|
671
|
+
actionBehaviorSchema,
|
|
672
|
+
containerBehaviorSchema,
|
|
673
|
+
copyBehaviorSchema,
|
|
674
|
+
dismissBehaviorSchema,
|
|
675
|
+
linkBehaviorSchema,
|
|
676
|
+
modalBehaviorSchema,
|
|
677
|
+
refreshBehaviorSchema,
|
|
678
|
+
]),
|
|
679
|
+
);
|
|
680
|
+
|
|
681
|
+
export const sectionLayoutCallToActionSchema: z.ZodSchema<SectionLayoutCallToAction> = z.lazy(() =>
|
|
682
|
+
z.object({
|
|
683
|
+
title: z.string(),
|
|
684
|
+
accessibilityDescription: z.string().optional(),
|
|
685
|
+
behavior: behaviorSchema,
|
|
686
|
+
}),
|
|
687
|
+
);
|
|
688
|
+
|
|
689
|
+
export const listLayoutItemSchema: z.ZodSchema<ListLayoutItem> = z.lazy(() =>
|
|
690
|
+
z.object({
|
|
691
|
+
status: listLayoutStatusSchema.optional(),
|
|
692
|
+
icon: iconSchema.optional(),
|
|
693
|
+
image: imageSchema.optional(),
|
|
694
|
+
title: z.string().optional(),
|
|
695
|
+
subtitle: z.string().optional(),
|
|
696
|
+
value: z.string().optional(),
|
|
697
|
+
subvalue: z.string().optional(),
|
|
698
|
+
tag: z.string().optional(),
|
|
699
|
+
additionalInfo: additionalInfoSchema.optional(),
|
|
743
700
|
supportingValues: supportingValuesSchema.optional(),
|
|
744
701
|
inlineAlert: inlineAlertSchema.optional(),
|
|
702
|
+
description: z.string().optional(),
|
|
703
|
+
media: mediaSchema.optional(),
|
|
704
|
+
analyticsId: z.string().optional(),
|
|
705
|
+
tags: z.array(z.string()).optional(),
|
|
706
|
+
callToAction: listLayoutCallToActionSchema.optional(),
|
|
707
|
+
}),
|
|
708
|
+
);
|
|
709
|
+
|
|
710
|
+
export const listLayoutCallToActionSchema: z.ZodSchema<ListLayoutCallToAction> = z.lazy(() =>
|
|
711
|
+
z.object({
|
|
712
|
+
title: z.string(),
|
|
713
|
+
accessibilityDescription: z.string().optional(),
|
|
714
|
+
behavior: behaviorSchema,
|
|
715
|
+
}),
|
|
716
|
+
);
|
|
717
|
+
|
|
718
|
+
export const columnsLayoutSchema: z.ZodSchema<ColumnsLayout> = z.lazy(() =>
|
|
719
|
+
z.object({
|
|
720
|
+
type: z.literal('columns'),
|
|
721
|
+
left: z.array(layoutSchema),
|
|
722
|
+
right: z.array(layoutSchema),
|
|
723
|
+
bias: columnsLayoutBiasSchema.optional(),
|
|
724
|
+
control: z.string().optional(),
|
|
725
|
+
margin: sizeSchema.optional(),
|
|
726
|
+
analyticsId: z.string().optional(),
|
|
727
|
+
tags: z.array(z.string()).optional(),
|
|
728
|
+
}),
|
|
729
|
+
);
|
|
730
|
+
|
|
731
|
+
export const statusListLayoutItemSchema: z.ZodSchema<StatusListLayoutItem> = z.lazy(() =>
|
|
732
|
+
z.object({
|
|
733
|
+
title: z.string(),
|
|
734
|
+
description: z.string().optional(),
|
|
735
|
+
icon: iconSchema,
|
|
736
|
+
status: statusListLayoutStatusSchema.optional(),
|
|
737
|
+
callToAction: itemCallToActionSchema.optional(),
|
|
738
|
+
tag: z.string().optional(),
|
|
739
|
+
analyticsId: z.string().optional(),
|
|
740
|
+
tags: z.array(z.string()).optional(),
|
|
741
|
+
}),
|
|
742
|
+
);
|
|
743
|
+
|
|
744
|
+
export const itemCallToActionSchema: z.ZodSchema<ItemCallToAction> = z.lazy(() =>
|
|
745
|
+
z.object({
|
|
746
|
+
title: z.string(),
|
|
747
|
+
accessibilityDescription: z.string().optional(),
|
|
748
|
+
behavior: behaviorSchema,
|
|
749
|
+
}),
|
|
750
|
+
);
|
|
751
|
+
|
|
752
|
+
export const statusListLayoutSchema: z.ZodSchema<StatusListLayout> = z.lazy(() =>
|
|
753
|
+
z.object({
|
|
754
|
+
type: z.literal('status-list'),
|
|
755
|
+
items: z.array(statusListLayoutItemSchema),
|
|
756
|
+
title: z.string().optional(),
|
|
757
|
+
control: z.string().optional(),
|
|
758
|
+
margin: sizeSchema.optional(),
|
|
759
|
+
analyticsId: z.string().optional(),
|
|
760
|
+
tags: z.array(z.string()).optional(),
|
|
745
761
|
}),
|
|
746
762
|
);
|
|
747
763
|
|
|
@@ -758,204 +774,208 @@ export const alertLayoutSchema: z.ZodSchema<AlertLayout> = z.lazy(() =>
|
|
|
758
774
|
}),
|
|
759
775
|
);
|
|
760
776
|
|
|
761
|
-
export const
|
|
777
|
+
export const boxLayoutSchema: z.ZodSchema<BoxLayout> = z.lazy(() =>
|
|
762
778
|
z.object({
|
|
763
|
-
type: z.literal('
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
refreshUrl: z.string().optional(),
|
|
768
|
-
refreshFormUrl: z.string().optional(),
|
|
769
|
-
$id: z.string().optional(),
|
|
770
|
-
title: z.string().optional(),
|
|
771
|
-
description: z.string().optional(),
|
|
779
|
+
type: z.literal('box'),
|
|
780
|
+
components: z.array(layoutSchema),
|
|
781
|
+
width: sizeSchema.optional(),
|
|
782
|
+
border: z.boolean().optional(),
|
|
772
783
|
control: z.string().optional(),
|
|
773
|
-
|
|
774
|
-
|
|
784
|
+
margin: sizeSchema.optional(),
|
|
785
|
+
analyticsId: z.string().optional(),
|
|
786
|
+
tags: z.array(z.string()).optional(),
|
|
787
|
+
}),
|
|
788
|
+
);
|
|
789
|
+
|
|
790
|
+
export const buttonLayoutSchema: z.ZodSchema<ButtonLayout> = z.lazy(() =>
|
|
791
|
+
z.object({
|
|
792
|
+
type: z.literal('button'),
|
|
793
|
+
action: actionSchema.optional(),
|
|
794
|
+
size: sizeSchema.optional(),
|
|
795
|
+
title: z.string().optional(),
|
|
796
|
+
behavior: behaviorSchema.optional(),
|
|
797
|
+
context: contextSchema.optional(),
|
|
775
798
|
disabled: z.boolean().optional(),
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
summary: summaryProviderSchema.optional(),
|
|
799
|
+
pinOrder: z.number().optional(),
|
|
800
|
+
control: z.string().optional(),
|
|
801
|
+
margin: sizeSchema.optional(),
|
|
780
802
|
analyticsId: z.string().optional(),
|
|
781
|
-
persistAsync: persistAsyncSchema.optional(),
|
|
782
|
-
refreshStepOnChange: z.boolean().optional(),
|
|
783
|
-
validationAsync: validateAsyncSchema.optional(),
|
|
784
|
-
alert: alertLayoutSchema.optional(),
|
|
785
|
-
autofillKey: z.string().optional(),
|
|
786
|
-
help: helpSchema.optional(),
|
|
787
|
-
onChange: behaviorSchema.optional(),
|
|
788
|
-
media: mediaSchema.optional(),
|
|
789
803
|
tags: z.array(z.string()).optional(),
|
|
790
|
-
additionalText: z.string().optional(),
|
|
791
|
-
supportingValues: supportingValuesSchema.optional(),
|
|
792
|
-
inlineAlert: inlineAlertSchema.optional(),
|
|
793
804
|
}),
|
|
794
805
|
);
|
|
795
806
|
|
|
796
|
-
export const
|
|
807
|
+
export const decisionLayoutSchema: z.ZodSchema<DecisionLayout> = z.lazy(() =>
|
|
797
808
|
z.object({
|
|
798
|
-
type: z.literal('
|
|
799
|
-
promoted: z.boolean().optional(),
|
|
800
|
-
$id: z.string().optional(),
|
|
801
|
-
items: z.array(schemaSchema),
|
|
809
|
+
type: z.literal('decision'),
|
|
802
810
|
title: z.string().optional(),
|
|
803
|
-
|
|
811
|
+
options: z.array(decisionLayoutOptionSchema),
|
|
804
812
|
control: z.string().optional(),
|
|
805
|
-
|
|
806
|
-
icon: iconSchema.optional(),
|
|
807
|
-
image: imageSchema.optional(),
|
|
808
|
-
keywords: z.array(z.string()).optional(),
|
|
809
|
-
summary: summaryProviderSchema.optional(),
|
|
813
|
+
margin: sizeSchema.optional(),
|
|
810
814
|
analyticsId: z.string().optional(),
|
|
811
|
-
persistAsync: persistAsyncSchema.optional(),
|
|
812
|
-
validationAsync: validateAsyncSchema.optional(),
|
|
813
|
-
alert: alertLayoutSchema.optional(),
|
|
814
|
-
media: mediaSchema.optional(),
|
|
815
815
|
tags: z.array(z.string()).optional(),
|
|
816
|
-
additionalText: z.string().optional(),
|
|
817
|
-
supportingValues: supportingValuesSchema.optional(),
|
|
818
|
-
inlineAlert: inlineAlertSchema.optional(),
|
|
819
816
|
}),
|
|
820
817
|
);
|
|
821
818
|
|
|
822
|
-
export const
|
|
819
|
+
export const listLayoutSchema: z.ZodSchema<ListLayout> = z.lazy(() =>
|
|
823
820
|
z.object({
|
|
824
|
-
|
|
825
|
-
promoted: z.boolean().optional(),
|
|
826
|
-
refreshFormOnChange: z.boolean().optional(),
|
|
827
|
-
refreshUrl: z.string().optional(),
|
|
828
|
-
refreshFormUrl: z.string().optional(),
|
|
829
|
-
promotion: jsonElementSchema.optional(),
|
|
830
|
-
oneOf: z.array(schemaSchema),
|
|
831
|
-
placeholder: z.string().optional(),
|
|
832
|
-
$id: z.string().optional(),
|
|
821
|
+
type: z.literal('list'),
|
|
833
822
|
title: z.string().optional(),
|
|
834
|
-
|
|
823
|
+
callToAction: listLayoutCallToActionSchema.optional(),
|
|
824
|
+
items: z.array(listLayoutItemSchema),
|
|
835
825
|
control: z.string().optional(),
|
|
836
|
-
|
|
837
|
-
hidden: z.boolean().optional(),
|
|
838
|
-
icon: iconSchema.optional(),
|
|
839
|
-
image: imageSchema.optional(),
|
|
840
|
-
keywords: z.array(z.string()).optional(),
|
|
841
|
-
summary: summaryProviderSchema.optional(),
|
|
826
|
+
margin: sizeSchema.optional(),
|
|
842
827
|
analyticsId: z.string().optional(),
|
|
843
|
-
refreshStepOnChange: z.boolean().optional(),
|
|
844
|
-
alert: alertLayoutSchema.optional(),
|
|
845
|
-
help: helpSchema.optional(),
|
|
846
|
-
autocompleteHint: z.array(autocompleteTokenSchema).optional(),
|
|
847
|
-
autofillKey: z.string().optional(),
|
|
848
|
-
validationMessages: z.record(z.string()).optional(),
|
|
849
|
-
disabled: z.boolean().optional(),
|
|
850
|
-
onChange: behaviorSchema.optional(),
|
|
851
|
-
media: mediaSchema.optional(),
|
|
852
828
|
tags: z.array(z.string()).optional(),
|
|
853
|
-
additionalText: z.string().optional(),
|
|
854
|
-
supportingValues: supportingValuesSchema.optional(),
|
|
855
|
-
inlineAlert: inlineAlertSchema.optional(),
|
|
856
829
|
}),
|
|
857
830
|
);
|
|
858
831
|
|
|
859
|
-
export const
|
|
832
|
+
export const modalLayoutSchema: z.ZodSchema<ModalLayout> = z.lazy(() =>
|
|
860
833
|
z.object({
|
|
861
|
-
type: z.literal('
|
|
862
|
-
|
|
863
|
-
|
|
834
|
+
type: z.literal('modal'),
|
|
835
|
+
control: z.string().optional(),
|
|
836
|
+
margin: sizeSchema.optional(),
|
|
837
|
+
trigger: modalLayoutTriggerSchema,
|
|
838
|
+
content: modalLayoutContentSchema,
|
|
839
|
+
analyticsId: z.string().optional(),
|
|
840
|
+
tags: z.array(z.string()).optional(),
|
|
841
|
+
}),
|
|
842
|
+
);
|
|
843
|
+
|
|
844
|
+
export const reviewLayoutSchema: z.ZodSchema<ReviewLayout> = z.lazy(() =>
|
|
845
|
+
z.object({
|
|
846
|
+
type: z.literal('review'),
|
|
847
|
+
orientation: z.string().optional(),
|
|
848
|
+
action: actionSchema.optional(),
|
|
849
|
+
fields: z.array(reviewLayoutFieldSchema),
|
|
864
850
|
title: z.string().optional(),
|
|
865
|
-
|
|
851
|
+
callToAction: reviewLayoutCallToActionSchema.optional(),
|
|
866
852
|
control: z.string().optional(),
|
|
867
|
-
|
|
868
|
-
icon: iconSchema.optional(),
|
|
869
|
-
image: imageSchema.optional(),
|
|
870
|
-
keywords: z.array(z.string()).optional(),
|
|
871
|
-
summary: summaryProviderSchema.optional(),
|
|
853
|
+
margin: sizeSchema.optional(),
|
|
872
854
|
analyticsId: z.string().optional(),
|
|
873
|
-
validationAsync: validateAsyncSchema.optional(),
|
|
874
|
-
validationMessages: z.record(z.string()).optional(),
|
|
875
|
-
alert: alertLayoutSchema.optional(),
|
|
876
|
-
cameraConfig: jsonElementSchema.optional(),
|
|
877
|
-
accepts: z.array(z.string()).optional(),
|
|
878
|
-
maxSize: z.number().optional(),
|
|
879
|
-
source: uploadSourceSchema.optional(),
|
|
880
|
-
disabled: z.boolean().optional(),
|
|
881
|
-
media: mediaSchema.optional(),
|
|
882
855
|
tags: z.array(z.string()).optional(),
|
|
883
|
-
additionalText: z.string().optional(),
|
|
884
|
-
supportingValues: supportingValuesSchema.optional(),
|
|
885
|
-
inlineAlert: inlineAlertSchema.optional(),
|
|
886
856
|
}),
|
|
887
857
|
);
|
|
888
858
|
|
|
889
|
-
export const
|
|
859
|
+
export const sectionLayoutSchema: z.ZodSchema<SectionLayout> = z.lazy(() =>
|
|
860
|
+
z.object({
|
|
861
|
+
type: z.literal('section'),
|
|
862
|
+
components: z.array(layoutSchema),
|
|
863
|
+
title: z.string(),
|
|
864
|
+
callToAction: sectionLayoutCallToActionSchema.optional(),
|
|
865
|
+
control: z.string().optional(),
|
|
866
|
+
margin: sizeSchema.optional(),
|
|
867
|
+
analyticsId: z.string().optional(),
|
|
868
|
+
tags: z.array(z.string()).optional(),
|
|
869
|
+
}),
|
|
870
|
+
);
|
|
871
|
+
|
|
872
|
+
export const tabsLayoutSchema: z.ZodSchema<TabsLayout> = z.lazy(() =>
|
|
873
|
+
z.object({
|
|
874
|
+
type: z.literal('tabs'),
|
|
875
|
+
tabs: z.array(tabsLayoutTabSchema),
|
|
876
|
+
control: z.string().optional(),
|
|
877
|
+
margin: sizeSchema.optional(),
|
|
878
|
+
analyticsId: z.string().optional(),
|
|
879
|
+
tags: z.array(z.string()).optional(),
|
|
880
|
+
}),
|
|
881
|
+
);
|
|
882
|
+
|
|
883
|
+
export const tabsLayoutTabSchema: z.ZodSchema<TabsLayoutTab> = z.lazy(() =>
|
|
884
|
+
z.object({
|
|
885
|
+
title: z.string(),
|
|
886
|
+
components: z.array(layoutSchema),
|
|
887
|
+
tag: z.string().optional(),
|
|
888
|
+
analyticsId: z.string().optional(),
|
|
889
|
+
tags: z.array(z.string()).optional(),
|
|
890
|
+
}),
|
|
891
|
+
);
|
|
892
|
+
|
|
893
|
+
export const modalLayoutContentSchema: z.ZodSchema<ModalLayoutContent> = z.lazy(() =>
|
|
890
894
|
z.object({
|
|
891
|
-
type: z.literal('string'),
|
|
892
|
-
autofillProvider: z.string().optional(),
|
|
893
|
-
promoted: z.boolean().optional(),
|
|
894
|
-
refreshFormOnChange: z.boolean().optional(),
|
|
895
|
-
refreshUrl: z.string().optional(),
|
|
896
|
-
refreshFormUrl: z.string().optional(),
|
|
897
|
-
format: stringSchemaFormatSchema.optional(),
|
|
898
|
-
displayFormat: z.string().optional(),
|
|
899
|
-
placeholder: z.string().optional(),
|
|
900
|
-
minLength: z.number().optional(),
|
|
901
|
-
maxLength: z.number().optional(),
|
|
902
|
-
minimum: z.string().optional(),
|
|
903
|
-
maximum: z.string().optional(),
|
|
904
|
-
pattern: z.string().optional(),
|
|
905
|
-
autocapitalization: autocapitalizationTypeSchema.optional(),
|
|
906
|
-
autocorrect: z.boolean().optional(),
|
|
907
|
-
$id: z.string().optional(),
|
|
908
895
|
title: z.string().optional(),
|
|
896
|
+
components: z.array(layoutSchema),
|
|
897
|
+
}),
|
|
898
|
+
);
|
|
899
|
+
|
|
900
|
+
export const decisionLayoutOptionSchema: z.ZodSchema<DecisionLayoutOption> = z.lazy(() =>
|
|
901
|
+
z.object({
|
|
902
|
+
action: actionSchema.optional(),
|
|
903
|
+
title: z.string(),
|
|
909
904
|
description: z.string().optional(),
|
|
910
|
-
control: z.string().optional(),
|
|
911
|
-
default: z.string().optional(),
|
|
912
|
-
hidden: z.boolean().optional(),
|
|
913
905
|
disabled: z.boolean().optional(),
|
|
914
906
|
icon: iconSchema.optional(),
|
|
915
907
|
image: imageSchema.optional(),
|
|
916
|
-
|
|
917
|
-
|
|
908
|
+
behavior: behaviorSchema.optional(),
|
|
909
|
+
tag: z.string().optional(),
|
|
910
|
+
additionalText: z.string().optional(),
|
|
911
|
+
supportingValues: supportingValuesSchema.optional(),
|
|
912
|
+
inlineAlert: inlineAlertSchema.optional(),
|
|
913
|
+
media: mediaSchema.optional(),
|
|
918
914
|
analyticsId: z.string().optional(),
|
|
919
|
-
|
|
920
|
-
|
|
921
|
-
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
915
|
+
keywords: z.array(z.string()).optional(),
|
|
916
|
+
tags: z.array(z.string()).optional(),
|
|
917
|
+
}),
|
|
918
|
+
);
|
|
919
|
+
|
|
920
|
+
export const reviewLayoutCallToActionSchema: z.ZodSchema<ReviewLayoutCallToAction> = z.lazy(() =>
|
|
921
|
+
z.object({
|
|
922
|
+
action: actionSchema.optional(),
|
|
923
|
+
title: z.string(),
|
|
924
|
+
accessibilityDescription: z.string().optional(),
|
|
925
|
+
behavior: behaviorSchema.optional(),
|
|
926
|
+
}),
|
|
927
|
+
);
|
|
928
|
+
|
|
929
|
+
export const reviewLayoutFieldSchema: z.ZodSchema<ReviewLayoutField> = z.lazy(() =>
|
|
930
|
+
z.object({
|
|
931
|
+
label: z.string(),
|
|
932
|
+
value: z.string(),
|
|
933
|
+
rawValue: z.string().optional(),
|
|
930
934
|
help: helpSchema.optional(),
|
|
931
|
-
|
|
932
|
-
|
|
935
|
+
tag: z.string().optional(),
|
|
936
|
+
icon: iconSchema.optional(),
|
|
937
|
+
image: imageSchema.optional(),
|
|
938
|
+
additionalInfo: additionalInfoSchema.optional(),
|
|
939
|
+
inlineAlert: inlineAlertSchema.optional(),
|
|
940
|
+
callToAction: reviewLayoutCallToActionSchema.optional(),
|
|
933
941
|
media: mediaSchema.optional(),
|
|
942
|
+
analyticsId: z.string().optional(),
|
|
934
943
|
tags: z.array(z.string()).optional(),
|
|
935
|
-
additionalText: z.string().optional(),
|
|
936
|
-
supportingValues: supportingValuesSchema.optional(),
|
|
937
|
-
inlineAlert: inlineAlertSchema.optional(),
|
|
938
944
|
}),
|
|
939
945
|
);
|
|
940
946
|
|
|
941
|
-
export const
|
|
947
|
+
export const alertLayoutCallToActionSchema: z.ZodSchema<AlertLayoutCallToAction> = z.lazy(() =>
|
|
942
948
|
z.object({
|
|
943
|
-
|
|
944
|
-
|
|
949
|
+
title: z.string(),
|
|
950
|
+
accessibilityDescription: z.string().optional(),
|
|
951
|
+
behavior: behaviorSchema,
|
|
952
|
+
}),
|
|
953
|
+
);
|
|
954
|
+
|
|
955
|
+
export const modalResponseBodySchema: z.ZodSchema<ModalResponseBody> = z.lazy(() =>
|
|
956
|
+
z.object({
|
|
957
|
+
title: z.string().optional(),
|
|
958
|
+
content: z.array(layoutSchema),
|
|
959
|
+
}),
|
|
960
|
+
);
|
|
961
|
+
|
|
962
|
+
export const allOfSchemaSchema: z.ZodSchema<AllOfSchema> = z.lazy(() =>
|
|
963
|
+
z.object({
|
|
964
|
+
disabled: z.boolean().optional(),
|
|
945
965
|
promoted: z.boolean().optional(),
|
|
966
|
+
allOf: z.array(schemaSchema),
|
|
946
967
|
$id: z.string().optional(),
|
|
947
|
-
const: jsonElementSchema,
|
|
948
968
|
title: z.string().optional(),
|
|
949
969
|
description: z.string().optional(),
|
|
970
|
+
control: z.string().optional(),
|
|
971
|
+
hidden: z.boolean().optional(),
|
|
950
972
|
icon: iconSchema.optional(),
|
|
951
973
|
image: imageSchema.optional(),
|
|
952
974
|
keywords: z.array(z.string()).optional(),
|
|
953
975
|
summary: summaryProviderSchema.optional(),
|
|
954
976
|
analyticsId: z.string().optional(),
|
|
955
|
-
disabled: z.boolean().optional(),
|
|
956
|
-
media: mediaSchema.optional(),
|
|
957
977
|
alert: alertLayoutSchema.optional(),
|
|
958
|
-
|
|
978
|
+
media: mediaSchema.optional(),
|
|
959
979
|
tags: z.array(z.string()).optional(),
|
|
960
980
|
additionalText: z.string().optional(),
|
|
961
981
|
supportingValues: supportingValuesSchema.optional(),
|
|
@@ -963,9 +983,9 @@ export const constSchemaSchema: z.ZodSchema<ConstSchema> = z.lazy(() =>
|
|
|
963
983
|
}),
|
|
964
984
|
);
|
|
965
985
|
|
|
966
|
-
export const
|
|
986
|
+
export const numberSchemaSchema: z.ZodSchema<NumberSchema> = z.lazy(() =>
|
|
967
987
|
z.object({
|
|
968
|
-
type: z.literal('
|
|
988
|
+
type: z.literal('number'),
|
|
969
989
|
autofillProvider: z.string().optional(),
|
|
970
990
|
promoted: z.boolean().optional(),
|
|
971
991
|
refreshFormOnChange: z.boolean().optional(),
|
|
@@ -1003,50 +1023,39 @@ export const integerSchemaSchema: z.ZodSchema<IntegerSchema> = z.lazy(() =>
|
|
|
1003
1023
|
}),
|
|
1004
1024
|
);
|
|
1005
1025
|
|
|
1006
|
-
export const
|
|
1026
|
+
export const persistAsyncSchema: z.ZodSchema<PersistAsync> = z.lazy(() =>
|
|
1007
1027
|
z.object({
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
description: z.string().optional(),
|
|
1014
|
-
control: z.string().optional(),
|
|
1015
|
-
hidden: z.boolean().optional(),
|
|
1016
|
-
icon: iconSchema.optional(),
|
|
1017
|
-
image: imageSchema.optional(),
|
|
1018
|
-
keywords: z.array(z.string()).optional(),
|
|
1019
|
-
summary: summaryProviderSchema.optional(),
|
|
1020
|
-
analyticsId: z.string().optional(),
|
|
1021
|
-
alert: alertLayoutSchema.optional(),
|
|
1022
|
-
media: mediaSchema.optional(),
|
|
1023
|
-
tags: z.array(z.string()).optional(),
|
|
1024
|
-
additionalText: z.string().optional(),
|
|
1025
|
-
supportingValues: supportingValuesSchema.optional(),
|
|
1026
|
-
inlineAlert: inlineAlertSchema.optional(),
|
|
1028
|
+
param: z.string(),
|
|
1029
|
+
idProperty: z.string(),
|
|
1030
|
+
schema: schemaSchema,
|
|
1031
|
+
url: z.string(),
|
|
1032
|
+
method: httpMethodSchema,
|
|
1027
1033
|
}),
|
|
1028
1034
|
);
|
|
1029
1035
|
|
|
1030
|
-
export const
|
|
1031
|
-
z.union([arraySchemaListSchema, arraySchemaTupleSchema]),
|
|
1032
|
-
);
|
|
1033
|
-
|
|
1034
|
-
export const numberSchemaSchema: z.ZodSchema<NumberSchema> = z.lazy(() =>
|
|
1036
|
+
export const stringSchemaSchema: z.ZodSchema<StringSchema> = z.lazy(() =>
|
|
1035
1037
|
z.object({
|
|
1036
|
-
type: z.literal('
|
|
1038
|
+
type: z.literal('string'),
|
|
1037
1039
|
autofillProvider: z.string().optional(),
|
|
1038
1040
|
promoted: z.boolean().optional(),
|
|
1039
1041
|
refreshFormOnChange: z.boolean().optional(),
|
|
1040
1042
|
refreshUrl: z.string().optional(),
|
|
1041
1043
|
refreshFormUrl: z.string().optional(),
|
|
1044
|
+
format: stringSchemaFormatSchema.optional(),
|
|
1045
|
+
displayFormat: z.string().optional(),
|
|
1042
1046
|
placeholder: z.string().optional(),
|
|
1043
|
-
|
|
1044
|
-
|
|
1047
|
+
minLength: z.number().optional(),
|
|
1048
|
+
maxLength: z.number().optional(),
|
|
1049
|
+
minimum: z.string().optional(),
|
|
1050
|
+
maximum: z.string().optional(),
|
|
1051
|
+
pattern: z.string().optional(),
|
|
1052
|
+
autocapitalization: autocapitalizationTypeSchema.optional(),
|
|
1053
|
+
autocorrect: z.boolean().optional(),
|
|
1045
1054
|
$id: z.string().optional(),
|
|
1046
1055
|
title: z.string().optional(),
|
|
1047
1056
|
description: z.string().optional(),
|
|
1048
1057
|
control: z.string().optional(),
|
|
1049
|
-
default: z.
|
|
1058
|
+
default: z.string().optional(),
|
|
1050
1059
|
hidden: z.boolean().optional(),
|
|
1051
1060
|
disabled: z.boolean().optional(),
|
|
1052
1061
|
icon: iconSchema.optional(),
|
|
@@ -1059,9 +1068,14 @@ export const numberSchemaSchema: z.ZodSchema<NumberSchema> = z.lazy(() =>
|
|
|
1059
1068
|
validationAsync: validateAsyncSchema.optional(),
|
|
1060
1069
|
validationMessages: z.record(z.string()).optional(),
|
|
1061
1070
|
alert: alertLayoutSchema.optional(),
|
|
1071
|
+
cameraConfig: jsonElementSchema.optional(),
|
|
1072
|
+
accepts: z.array(z.string()).optional(),
|
|
1073
|
+
maxSize: z.number().optional(),
|
|
1074
|
+
source: uploadSourceSchema.optional(),
|
|
1062
1075
|
autocompleteHint: z.array(autocompleteTokenSchema).optional(),
|
|
1063
1076
|
autofillKey: z.string().optional(),
|
|
1064
1077
|
help: helpSchema.optional(),
|
|
1078
|
+
suggestions: suggestionsSchema.optional(),
|
|
1065
1079
|
onChange: behaviorSchema.optional(),
|
|
1066
1080
|
media: mediaSchema.optional(),
|
|
1067
1081
|
tags: z.array(z.string()).optional(),
|
|
@@ -1071,307 +1085,293 @@ export const numberSchemaSchema: z.ZodSchema<NumberSchema> = z.lazy(() =>
|
|
|
1071
1085
|
}),
|
|
1072
1086
|
);
|
|
1073
1087
|
|
|
1074
|
-
export const
|
|
1088
|
+
export const integerSchemaSchema: z.ZodSchema<IntegerSchema> = z.lazy(() =>
|
|
1075
1089
|
z.object({
|
|
1076
|
-
type: z.literal('
|
|
1077
|
-
|
|
1090
|
+
type: z.literal('integer'),
|
|
1091
|
+
autofillProvider: z.string().optional(),
|
|
1078
1092
|
promoted: z.boolean().optional(),
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1093
|
+
refreshFormOnChange: z.boolean().optional(),
|
|
1094
|
+
refreshUrl: z.string().optional(),
|
|
1095
|
+
refreshFormUrl: z.string().optional(),
|
|
1096
|
+
placeholder: z.string().optional(),
|
|
1097
|
+
minimum: z.number().optional(),
|
|
1098
|
+
maximum: z.number().optional(),
|
|
1083
1099
|
$id: z.string().optional(),
|
|
1084
1100
|
title: z.string().optional(),
|
|
1085
1101
|
description: z.string().optional(),
|
|
1086
1102
|
control: z.string().optional(),
|
|
1103
|
+
default: z.number().optional(),
|
|
1087
1104
|
hidden: z.boolean().optional(),
|
|
1105
|
+
disabled: z.boolean().optional(),
|
|
1088
1106
|
icon: iconSchema.optional(),
|
|
1089
1107
|
image: imageSchema.optional(),
|
|
1090
1108
|
keywords: z.array(z.string()).optional(),
|
|
1091
1109
|
summary: summaryProviderSchema.optional(),
|
|
1092
1110
|
analyticsId: z.string().optional(),
|
|
1111
|
+
persistAsync: persistAsyncSchema.optional(),
|
|
1112
|
+
refreshStepOnChange: z.boolean().optional(),
|
|
1113
|
+
validationAsync: validateAsyncSchema.optional(),
|
|
1114
|
+
validationMessages: z.record(z.string()).optional(),
|
|
1093
1115
|
alert: alertLayoutSchema.optional(),
|
|
1094
|
-
|
|
1095
|
-
|
|
1096
|
-
|
|
1097
|
-
|
|
1098
|
-
|
|
1099
|
-
inlineAlert: inlineAlertSchema.optional(),
|
|
1100
|
-
}),
|
|
1101
|
-
);
|
|
1102
|
-
|
|
1103
|
-
export const modalResponseBodySchema: z.ZodSchema<ModalResponseBody> = z.lazy(() =>
|
|
1104
|
-
z.object({
|
|
1105
|
-
title: z.string().optional(),
|
|
1106
|
-
content: z.array(layoutSchema),
|
|
1107
|
-
}),
|
|
1108
|
-
);
|
|
1109
|
-
|
|
1110
|
-
export const additionalInfoSchema: z.ZodSchema<AdditionalInfo> = z.lazy(() =>
|
|
1111
|
-
z.object({
|
|
1112
|
-
text: z.string(),
|
|
1113
|
-
behavior: behaviorSchema.optional(),
|
|
1114
|
-
accessibilityDescription: z.string().optional(),
|
|
1115
|
-
}),
|
|
1116
|
-
);
|
|
1117
|
-
|
|
1118
|
-
export const alertLayoutCallToActionSchema: z.ZodSchema<AlertLayoutCallToAction> = z.lazy(() =>
|
|
1119
|
-
z.object({
|
|
1120
|
-
title: z.string(),
|
|
1121
|
-
accessibilityDescription: z.string().optional(),
|
|
1122
|
-
behavior: behaviorSchema,
|
|
1123
|
-
}),
|
|
1124
|
-
);
|
|
1125
|
-
|
|
1126
|
-
export const buttonLayoutSchema: z.ZodSchema<ButtonLayout> = z.lazy(() =>
|
|
1127
|
-
z.object({
|
|
1128
|
-
type: z.literal('button'),
|
|
1129
|
-
action: actionSchema.optional(),
|
|
1130
|
-
size: sizeSchema.optional(),
|
|
1131
|
-
title: z.string().optional(),
|
|
1132
|
-
behavior: behaviorSchema.optional(),
|
|
1133
|
-
context: contextSchema.optional(),
|
|
1134
|
-
disabled: z.boolean().optional(),
|
|
1135
|
-
pinOrder: z.number().optional(),
|
|
1136
|
-
control: z.string().optional(),
|
|
1137
|
-
margin: sizeSchema.optional(),
|
|
1138
|
-
analyticsId: z.string().optional(),
|
|
1139
|
-
tags: z.array(z.string()).optional(),
|
|
1140
|
-
}),
|
|
1141
|
-
);
|
|
1142
|
-
|
|
1143
|
-
export const modalLayoutSchema: z.ZodSchema<ModalLayout> = z.lazy(() =>
|
|
1144
|
-
z.object({
|
|
1145
|
-
type: z.literal('modal'),
|
|
1146
|
-
control: z.string().optional(),
|
|
1147
|
-
margin: sizeSchema.optional(),
|
|
1148
|
-
trigger: modalLayoutTriggerSchema,
|
|
1149
|
-
content: modalLayoutContentSchema,
|
|
1150
|
-
analyticsId: z.string().optional(),
|
|
1151
|
-
tags: z.array(z.string()).optional(),
|
|
1152
|
-
}),
|
|
1153
|
-
);
|
|
1154
|
-
|
|
1155
|
-
export const modalLayoutContentSchema: z.ZodSchema<ModalLayoutContent> = z.lazy(() =>
|
|
1156
|
-
z.object({
|
|
1157
|
-
title: z.string().optional(),
|
|
1158
|
-
components: z.array(layoutSchema),
|
|
1159
|
-
}),
|
|
1160
|
-
);
|
|
1161
|
-
|
|
1162
|
-
export const tabsLayoutTabSchema: z.ZodSchema<TabsLayoutTab> = z.lazy(() =>
|
|
1163
|
-
z.object({
|
|
1164
|
-
title: z.string(),
|
|
1165
|
-
components: z.array(layoutSchema),
|
|
1166
|
-
tag: z.string().optional(),
|
|
1167
|
-
analyticsId: z.string().optional(),
|
|
1168
|
-
tags: z.array(z.string()).optional(),
|
|
1169
|
-
}),
|
|
1170
|
-
);
|
|
1171
|
-
|
|
1172
|
-
export const listLayoutSchema: z.ZodSchema<ListLayout> = z.lazy(() =>
|
|
1173
|
-
z.object({
|
|
1174
|
-
type: z.literal('list'),
|
|
1175
|
-
title: z.string().optional(),
|
|
1176
|
-
callToAction: listLayoutCallToActionSchema.optional(),
|
|
1177
|
-
items: z.array(listLayoutItemSchema),
|
|
1178
|
-
control: z.string().optional(),
|
|
1179
|
-
margin: sizeSchema.optional(),
|
|
1180
|
-
analyticsId: z.string().optional(),
|
|
1181
|
-
tags: z.array(z.string()).optional(),
|
|
1182
|
-
}),
|
|
1183
|
-
);
|
|
1184
|
-
|
|
1185
|
-
export const listLayoutCallToActionSchema: z.ZodSchema<ListLayoutCallToAction> = z.lazy(() =>
|
|
1186
|
-
z.object({
|
|
1187
|
-
title: z.string(),
|
|
1188
|
-
accessibilityDescription: z.string().optional(),
|
|
1189
|
-
behavior: behaviorSchema,
|
|
1190
|
-
}),
|
|
1191
|
-
);
|
|
1192
|
-
|
|
1193
|
-
export const listLayoutItemSchema: z.ZodSchema<ListLayoutItem> = z.lazy(() =>
|
|
1194
|
-
z.object({
|
|
1195
|
-
status: listLayoutStatusSchema.optional(),
|
|
1196
|
-
icon: iconSchema.optional(),
|
|
1197
|
-
image: imageSchema.optional(),
|
|
1198
|
-
title: z.string().optional(),
|
|
1199
|
-
subtitle: z.string().optional(),
|
|
1200
|
-
value: z.string().optional(),
|
|
1201
|
-
subvalue: z.string().optional(),
|
|
1202
|
-
tag: z.string().optional(),
|
|
1203
|
-
additionalInfo: additionalInfoSchema.optional(),
|
|
1204
|
-
supportingValues: supportingValuesSchema.optional(),
|
|
1205
|
-
inlineAlert: inlineAlertSchema.optional(),
|
|
1206
|
-
description: z.string().optional(),
|
|
1207
|
-
media: mediaSchema.optional(),
|
|
1208
|
-
analyticsId: z.string().optional(),
|
|
1209
|
-
tags: z.array(z.string()).optional(),
|
|
1210
|
-
callToAction: listLayoutCallToActionSchema.optional(),
|
|
1211
|
-
}),
|
|
1212
|
-
);
|
|
1213
|
-
|
|
1214
|
-
export const boxLayoutSchema: z.ZodSchema<BoxLayout> = z.lazy(() =>
|
|
1215
|
-
z.object({
|
|
1216
|
-
type: z.literal('box'),
|
|
1217
|
-
components: z.array(layoutSchema),
|
|
1218
|
-
width: sizeSchema.optional(),
|
|
1219
|
-
border: z.boolean().optional(),
|
|
1220
|
-
control: z.string().optional(),
|
|
1221
|
-
margin: sizeSchema.optional(),
|
|
1222
|
-
analyticsId: z.string().optional(),
|
|
1223
|
-
tags: z.array(z.string()).optional(),
|
|
1224
|
-
}),
|
|
1225
|
-
);
|
|
1226
|
-
|
|
1227
|
-
export const columnsLayoutSchema: z.ZodSchema<ColumnsLayout> = z.lazy(() =>
|
|
1228
|
-
z.object({
|
|
1229
|
-
type: z.literal('columns'),
|
|
1230
|
-
left: z.array(layoutSchema),
|
|
1231
|
-
right: z.array(layoutSchema),
|
|
1232
|
-
bias: columnsLayoutBiasSchema.optional(),
|
|
1233
|
-
control: z.string().optional(),
|
|
1234
|
-
margin: sizeSchema.optional(),
|
|
1235
|
-
analyticsId: z.string().optional(),
|
|
1116
|
+
autocompleteHint: z.array(autocompleteTokenSchema).optional(),
|
|
1117
|
+
autofillKey: z.string().optional(),
|
|
1118
|
+
help: helpSchema.optional(),
|
|
1119
|
+
onChange: behaviorSchema.optional(),
|
|
1120
|
+
media: mediaSchema.optional(),
|
|
1236
1121
|
tags: z.array(z.string()).optional(),
|
|
1122
|
+
additionalText: z.string().optional(),
|
|
1123
|
+
supportingValues: supportingValuesSchema.optional(),
|
|
1124
|
+
inlineAlert: inlineAlertSchema.optional(),
|
|
1237
1125
|
}),
|
|
1238
1126
|
);
|
|
1239
1127
|
|
|
1240
|
-
export const
|
|
1128
|
+
export const booleanSchemaSchema: z.ZodSchema<BooleanSchema> = z.lazy(() =>
|
|
1241
1129
|
z.object({
|
|
1242
|
-
type: z.literal('
|
|
1130
|
+
type: z.literal('boolean'),
|
|
1131
|
+
autofillProvider: z.string().optional(),
|
|
1132
|
+
promoted: z.boolean().optional(),
|
|
1133
|
+
refreshFormOnChange: z.boolean().optional(),
|
|
1134
|
+
refreshUrl: z.string().optional(),
|
|
1135
|
+
refreshFormUrl: z.string().optional(),
|
|
1136
|
+
$id: z.string().optional(),
|
|
1243
1137
|
title: z.string().optional(),
|
|
1244
|
-
|
|
1138
|
+
description: z.string().optional(),
|
|
1245
1139
|
control: z.string().optional(),
|
|
1246
|
-
|
|
1140
|
+
default: z.boolean().optional(),
|
|
1141
|
+
hidden: z.boolean().optional(),
|
|
1142
|
+
disabled: z.boolean().optional(),
|
|
1143
|
+
icon: iconSchema.optional(),
|
|
1144
|
+
image: imageSchema.optional(),
|
|
1145
|
+
keywords: z.array(z.string()).optional(),
|
|
1146
|
+
summary: summaryProviderSchema.optional(),
|
|
1247
1147
|
analyticsId: z.string().optional(),
|
|
1148
|
+
persistAsync: persistAsyncSchema.optional(),
|
|
1149
|
+
refreshStepOnChange: z.boolean().optional(),
|
|
1150
|
+
validationAsync: validateAsyncSchema.optional(),
|
|
1151
|
+
alert: alertLayoutSchema.optional(),
|
|
1152
|
+
autofillKey: z.string().optional(),
|
|
1153
|
+
help: helpSchema.optional(),
|
|
1154
|
+
onChange: behaviorSchema.optional(),
|
|
1155
|
+
media: mediaSchema.optional(),
|
|
1248
1156
|
tags: z.array(z.string()).optional(),
|
|
1157
|
+
additionalText: z.string().optional(),
|
|
1158
|
+
supportingValues: supportingValuesSchema.optional(),
|
|
1159
|
+
inlineAlert: inlineAlertSchema.optional(),
|
|
1249
1160
|
}),
|
|
1250
1161
|
);
|
|
1251
1162
|
|
|
1252
|
-
export const
|
|
1163
|
+
export const blobSchemaSchema: z.ZodSchema<BlobSchema> = z.lazy(() =>
|
|
1253
1164
|
z.object({
|
|
1254
|
-
type: z.literal('
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
fields: z.array(reviewLayoutFieldSchema),
|
|
1165
|
+
type: z.literal('blob'),
|
|
1166
|
+
promoted: z.boolean().optional(),
|
|
1167
|
+
$id: z.string().optional(),
|
|
1258
1168
|
title: z.string().optional(),
|
|
1259
|
-
|
|
1169
|
+
description: z.string().optional(),
|
|
1260
1170
|
control: z.string().optional(),
|
|
1261
|
-
|
|
1171
|
+
hidden: z.boolean().optional(),
|
|
1172
|
+
icon: iconSchema.optional(),
|
|
1173
|
+
image: imageSchema.optional(),
|
|
1174
|
+
keywords: z.array(z.string()).optional(),
|
|
1175
|
+
summary: summaryProviderSchema.optional(),
|
|
1262
1176
|
analyticsId: z.string().optional(),
|
|
1177
|
+
validationAsync: validateAsyncSchema.optional(),
|
|
1178
|
+
validationMessages: z.record(z.string()).optional(),
|
|
1179
|
+
alert: alertLayoutSchema.optional(),
|
|
1180
|
+
cameraConfig: jsonElementSchema.optional(),
|
|
1181
|
+
accepts: z.array(z.string()).optional(),
|
|
1182
|
+
maxSize: z.number().optional(),
|
|
1183
|
+
source: uploadSourceSchema.optional(),
|
|
1184
|
+
disabled: z.boolean().optional(),
|
|
1185
|
+
media: mediaSchema.optional(),
|
|
1263
1186
|
tags: z.array(z.string()).optional(),
|
|
1187
|
+
additionalText: z.string().optional(),
|
|
1188
|
+
supportingValues: supportingValuesSchema.optional(),
|
|
1189
|
+
inlineAlert: inlineAlertSchema.optional(),
|
|
1264
1190
|
}),
|
|
1265
1191
|
);
|
|
1266
1192
|
|
|
1267
|
-
export const
|
|
1193
|
+
export const constSchemaSchema: z.ZodSchema<ConstSchema> = z.lazy(() =>
|
|
1268
1194
|
z.object({
|
|
1269
|
-
|
|
1270
|
-
components: z.array(layoutSchema),
|
|
1271
|
-
title: z.string(),
|
|
1272
|
-
callToAction: sectionLayoutCallToActionSchema.optional(),
|
|
1195
|
+
hidden: z.boolean().optional(),
|
|
1273
1196
|
control: z.string().optional(),
|
|
1274
|
-
|
|
1197
|
+
promoted: z.boolean().optional(),
|
|
1198
|
+
$id: z.string().optional(),
|
|
1199
|
+
const: jsonElementSchema,
|
|
1200
|
+
title: z.string().optional(),
|
|
1201
|
+
description: z.string().optional(),
|
|
1202
|
+
icon: iconSchema.optional(),
|
|
1203
|
+
image: imageSchema.optional(),
|
|
1204
|
+
keywords: z.array(z.string()).optional(),
|
|
1205
|
+
summary: summaryProviderSchema.optional(),
|
|
1275
1206
|
analyticsId: z.string().optional(),
|
|
1207
|
+
disabled: z.boolean().optional(),
|
|
1208
|
+
media: mediaSchema.optional(),
|
|
1209
|
+
alert: alertLayoutSchema.optional(),
|
|
1210
|
+
layout: z.array(layoutSchema).optional(),
|
|
1276
1211
|
tags: z.array(z.string()).optional(),
|
|
1212
|
+
additionalText: z.string().optional(),
|
|
1213
|
+
supportingValues: supportingValuesSchema.optional(),
|
|
1214
|
+
inlineAlert: inlineAlertSchema.optional(),
|
|
1277
1215
|
}),
|
|
1278
1216
|
);
|
|
1279
1217
|
|
|
1280
|
-
export const
|
|
1218
|
+
export const oneOfSchemaSchema: z.ZodSchema<OneOfSchema> = z.lazy(() =>
|
|
1281
1219
|
z.object({
|
|
1282
|
-
|
|
1283
|
-
|
|
1220
|
+
autofillProvider: z.string().optional(),
|
|
1221
|
+
promoted: z.boolean().optional(),
|
|
1222
|
+
refreshFormOnChange: z.boolean().optional(),
|
|
1223
|
+
refreshUrl: z.string().optional(),
|
|
1224
|
+
refreshFormUrl: z.string().optional(),
|
|
1225
|
+
promotion: jsonElementSchema.optional(),
|
|
1226
|
+
oneOf: z.array(schemaSchema),
|
|
1227
|
+
placeholder: z.string().optional(),
|
|
1228
|
+
$id: z.string().optional(),
|
|
1284
1229
|
title: z.string().optional(),
|
|
1230
|
+
description: z.string().optional(),
|
|
1285
1231
|
control: z.string().optional(),
|
|
1286
|
-
|
|
1232
|
+
default: jsonElementSchema.optional(),
|
|
1233
|
+
hidden: z.boolean().optional(),
|
|
1234
|
+
icon: iconSchema.optional(),
|
|
1235
|
+
image: imageSchema.optional(),
|
|
1236
|
+
keywords: z.array(z.string()).optional(),
|
|
1237
|
+
summary: summaryProviderSchema.optional(),
|
|
1287
1238
|
analyticsId: z.string().optional(),
|
|
1239
|
+
refreshStepOnChange: z.boolean().optional(),
|
|
1240
|
+
alert: alertLayoutSchema.optional(),
|
|
1241
|
+
help: helpSchema.optional(),
|
|
1242
|
+
autocompleteHint: z.array(autocompleteTokenSchema).optional(),
|
|
1243
|
+
autofillKey: z.string().optional(),
|
|
1244
|
+
validationMessages: z.record(z.string()).optional(),
|
|
1245
|
+
disabled: z.boolean().optional(),
|
|
1246
|
+
onChange: behaviorSchema.optional(),
|
|
1247
|
+
media: mediaSchema.optional(),
|
|
1288
1248
|
tags: z.array(z.string()).optional(),
|
|
1249
|
+
additionalText: z.string().optional(),
|
|
1250
|
+
supportingValues: supportingValuesSchema.optional(),
|
|
1251
|
+
inlineAlert: inlineAlertSchema.optional(),
|
|
1289
1252
|
}),
|
|
1290
1253
|
);
|
|
1291
1254
|
|
|
1292
|
-
export const
|
|
1255
|
+
export const objectSchemaSchema: z.ZodSchema<ObjectSchema> = z.lazy(() =>
|
|
1293
1256
|
z.object({
|
|
1294
|
-
type: z.literal('
|
|
1295
|
-
|
|
1257
|
+
type: z.literal('object'),
|
|
1258
|
+
disabled: z.boolean().optional(),
|
|
1259
|
+
promoted: z.boolean().optional(),
|
|
1260
|
+
help: helpSchema.optional(),
|
|
1261
|
+
properties: z.record(schemaSchema),
|
|
1262
|
+
displayOrder: z.array(z.string()),
|
|
1263
|
+
required: z.array(z.string()).optional(),
|
|
1264
|
+
$id: z.string().optional(),
|
|
1265
|
+
title: z.string().optional(),
|
|
1266
|
+
description: z.string().optional(),
|
|
1296
1267
|
control: z.string().optional(),
|
|
1297
|
-
|
|
1268
|
+
hidden: z.boolean().optional(),
|
|
1269
|
+
icon: iconSchema.optional(),
|
|
1270
|
+
image: imageSchema.optional(),
|
|
1271
|
+
keywords: z.array(z.string()).optional(),
|
|
1272
|
+
summary: summaryProviderSchema.optional(),
|
|
1298
1273
|
analyticsId: z.string().optional(),
|
|
1274
|
+
alert: alertLayoutSchema.optional(),
|
|
1275
|
+
media: mediaSchema.optional(),
|
|
1299
1276
|
tags: z.array(z.string()).optional(),
|
|
1277
|
+
format: z.string().optional(),
|
|
1278
|
+
additionalText: z.string().optional(),
|
|
1279
|
+
supportingValues: supportingValuesSchema.optional(),
|
|
1280
|
+
inlineAlert: inlineAlertSchema.optional(),
|
|
1300
1281
|
}),
|
|
1301
1282
|
);
|
|
1302
1283
|
|
|
1303
|
-
export const
|
|
1284
|
+
export const arraySchemaSchema: z.ZodSchema<ArraySchema> = z.lazy(() =>
|
|
1285
|
+
z.union([arraySchemaListSchema, arraySchemaTupleSchema]),
|
|
1286
|
+
);
|
|
1287
|
+
|
|
1288
|
+
export const arraySchemaListSchema: z.ZodSchema<ArraySchemaList> = z.lazy(() =>
|
|
1304
1289
|
z.object({
|
|
1305
|
-
|
|
1306
|
-
|
|
1290
|
+
type: z.literal('array'),
|
|
1291
|
+
promoted: z.boolean().optional(),
|
|
1292
|
+
$id: z.string().optional(),
|
|
1293
|
+
items: schemaSchema,
|
|
1294
|
+
addItemTitle: z.string(),
|
|
1295
|
+
editItemTitle: z.string(),
|
|
1296
|
+
minItems: z.number().optional(),
|
|
1297
|
+
maxItems: z.number().optional(),
|
|
1298
|
+
placeholder: z.string().optional(),
|
|
1299
|
+
title: z.string().optional(),
|
|
1307
1300
|
description: z.string().optional(),
|
|
1308
|
-
|
|
1301
|
+
control: z.string().optional(),
|
|
1302
|
+
hidden: z.boolean().optional(),
|
|
1309
1303
|
icon: iconSchema.optional(),
|
|
1310
1304
|
image: imageSchema.optional(),
|
|
1311
|
-
|
|
1312
|
-
|
|
1305
|
+
keywords: z.array(z.string()).optional(),
|
|
1306
|
+
summary: summarySummariserSchema.optional(),
|
|
1307
|
+
analyticsId: z.string().optional(),
|
|
1308
|
+
persistAsync: persistAsyncSchema.optional(),
|
|
1309
|
+
validationAsync: validateAsyncSchema.optional(),
|
|
1310
|
+
alert: alertLayoutSchema.optional(),
|
|
1311
|
+
validationMessages: z.record(z.string()).optional(),
|
|
1312
|
+
disabled: z.boolean().optional(),
|
|
1313
|
+
media: mediaSchema.optional(),
|
|
1314
|
+
tags: z.array(z.string()).optional(),
|
|
1313
1315
|
additionalText: z.string().optional(),
|
|
1314
1316
|
supportingValues: supportingValuesSchema.optional(),
|
|
1315
1317
|
inlineAlert: inlineAlertSchema.optional(),
|
|
1316
|
-
media: mediaSchema.optional(),
|
|
1317
|
-
analyticsId: z.string().optional(),
|
|
1318
|
-
keywords: z.array(z.string()).optional(),
|
|
1319
|
-
tags: z.array(z.string()).optional(),
|
|
1320
1318
|
}),
|
|
1321
1319
|
);
|
|
1322
1320
|
|
|
1323
|
-
export const
|
|
1321
|
+
export const arraySchemaTupleSchema: z.ZodSchema<ArraySchemaTuple> = z.lazy(() =>
|
|
1324
1322
|
z.object({
|
|
1325
|
-
|
|
1323
|
+
type: z.literal('array'),
|
|
1324
|
+
promoted: z.boolean().optional(),
|
|
1325
|
+
$id: z.string().optional(),
|
|
1326
|
+
items: z.array(schemaSchema),
|
|
1327
|
+
title: z.string().optional(),
|
|
1326
1328
|
description: z.string().optional(),
|
|
1327
|
-
|
|
1328
|
-
|
|
1329
|
-
|
|
1330
|
-
|
|
1329
|
+
control: z.string().optional(),
|
|
1330
|
+
hidden: z.boolean().optional(),
|
|
1331
|
+
icon: iconSchema.optional(),
|
|
1332
|
+
image: imageSchema.optional(),
|
|
1333
|
+
keywords: z.array(z.string()).optional(),
|
|
1334
|
+
summary: summaryProviderSchema.optional(),
|
|
1331
1335
|
analyticsId: z.string().optional(),
|
|
1336
|
+
persistAsync: persistAsyncSchema.optional(),
|
|
1337
|
+
validationAsync: validateAsyncSchema.optional(),
|
|
1338
|
+
alert: alertLayoutSchema.optional(),
|
|
1339
|
+
media: mediaSchema.optional(),
|
|
1332
1340
|
tags: z.array(z.string()).optional(),
|
|
1341
|
+
additionalText: z.string().optional(),
|
|
1342
|
+
supportingValues: supportingValuesSchema.optional(),
|
|
1343
|
+
inlineAlert: inlineAlertSchema.optional(),
|
|
1333
1344
|
}),
|
|
1334
1345
|
);
|
|
1335
1346
|
|
|
1336
|
-
export const
|
|
1347
|
+
export const pollingOnErrorSchema: z.ZodSchema<PollingOnError> = z.lazy(() =>
|
|
1337
1348
|
z.object({
|
|
1338
|
-
|
|
1339
|
-
|
|
1340
|
-
behavior: behaviorSchema,
|
|
1349
|
+
action: actionSchema.optional(),
|
|
1350
|
+
behavior: behaviorSchema.optional(),
|
|
1341
1351
|
}),
|
|
1342
1352
|
);
|
|
1343
1353
|
|
|
1344
|
-
export const
|
|
1354
|
+
export const modalBehaviorSchema: z.ZodSchema<ModalBehavior> = z.lazy(() =>
|
|
1345
1355
|
z.object({
|
|
1346
|
-
|
|
1347
|
-
|
|
1348
|
-
|
|
1349
|
-
help: helpSchema.optional(),
|
|
1350
|
-
tag: z.string().optional(),
|
|
1351
|
-
icon: iconSchema.optional(),
|
|
1352
|
-
image: imageSchema.optional(),
|
|
1353
|
-
additionalInfo: additionalInfoSchema.optional(),
|
|
1354
|
-
inlineAlert: inlineAlertSchema.optional(),
|
|
1355
|
-
callToAction: reviewLayoutCallToActionSchema.optional(),
|
|
1356
|
-
media: mediaSchema.optional(),
|
|
1357
|
-
analyticsId: z.string().optional(),
|
|
1358
|
-
tags: z.array(z.string()).optional(),
|
|
1356
|
+
type: z.literal('modal'),
|
|
1357
|
+
title: z.string().optional(),
|
|
1358
|
+
content: z.array(layoutSchema),
|
|
1359
1359
|
}),
|
|
1360
1360
|
);
|
|
1361
1361
|
|
|
1362
|
-
export const
|
|
1362
|
+
export const toolbarButtonSchema: z.ZodSchema<ToolbarButton> = z.lazy(() =>
|
|
1363
1363
|
z.object({
|
|
1364
|
-
|
|
1364
|
+
type: z.literal('toolbar-button'),
|
|
1365
1365
|
title: z.string(),
|
|
1366
|
+
behavior: behaviorSchema,
|
|
1366
1367
|
accessibilityDescription: z.string().optional(),
|
|
1367
|
-
|
|
1368
|
+
media: mediaSchema.optional(),
|
|
1369
|
+
control: z.string().optional(),
|
|
1370
|
+
context: contextSchema.optional(),
|
|
1371
|
+
disabled: z.boolean().optional(),
|
|
1372
|
+
analyticsId: z.string().optional(),
|
|
1373
|
+
tags: z.array(z.string()).optional(),
|
|
1368
1374
|
}),
|
|
1369
1375
|
);
|
|
1370
1376
|
|
|
1371
|
-
export const
|
|
1372
|
-
z.object({
|
|
1373
|
-
title: z.string(),
|
|
1374
|
-
accessibilityDescription: z.string().optional(),
|
|
1375
|
-
behavior: behaviorSchema,
|
|
1376
|
-
}),
|
|
1377
|
-
);
|
|
1377
|
+
export const toolbarItemSchema: z.ZodSchema<ToolbarItem> = z.lazy(() => toolbarButtonSchema);
|