@wise/dynamic-flow-client 4.0.1 → 4.1.0-experimental-6bb6f02
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/i18n/cs.json +46 -3
- package/build/i18n/uk.json +46 -3
- package/build/main.js +478 -436
- package/build/main.mjs +478 -436
- package/build/types/revamp/domain/components/StepDomainComponent.d.ts +4 -2
- package/build/types/revamp/utils/time-utils.d.ts +6 -0
- package/package.json +28 -28
package/build/main.js
CHANGED
|
@@ -5190,16 +5190,32 @@ ZodReadonly.create = (type, params) => {
|
|
|
5190
5190
|
typeName: ZodFirstPartyTypeKind.ZodReadonly
|
|
5191
5191
|
}, processCreateParams(params)));
|
|
5192
5192
|
};
|
|
5193
|
-
function
|
|
5193
|
+
function cleanParams(params, data) {
|
|
5194
|
+
const p = typeof params === "function" ? params(data) : typeof params === "string" ? { message: params } : params;
|
|
5195
|
+
const p2 = typeof p === "string" ? { message: p } : p;
|
|
5196
|
+
return p2;
|
|
5197
|
+
}
|
|
5198
|
+
function custom(check, _params = {}, fatal) {
|
|
5194
5199
|
if (check)
|
|
5195
5200
|
return ZodAny.create().superRefine((data, ctx) => {
|
|
5196
5201
|
var _a, _b;
|
|
5197
|
-
|
|
5198
|
-
|
|
5199
|
-
|
|
5200
|
-
|
|
5201
|
-
|
|
5202
|
+
const r2 = check(data);
|
|
5203
|
+
if (r2 instanceof Promise) {
|
|
5204
|
+
return r2.then((r22) => {
|
|
5205
|
+
var _a2, _b2;
|
|
5206
|
+
if (!r22) {
|
|
5207
|
+
const params = cleanParams(_params, data);
|
|
5208
|
+
const _fatal = (_b2 = (_a2 = params.fatal) !== null && _a2 !== void 0 ? _a2 : fatal) !== null && _b2 !== void 0 ? _b2 : true;
|
|
5209
|
+
ctx.addIssue(__spreadProps2(__spreadValues2({ code: "custom" }, params), { fatal: _fatal }));
|
|
5210
|
+
}
|
|
5211
|
+
});
|
|
5212
|
+
}
|
|
5213
|
+
if (!r2) {
|
|
5214
|
+
const params = cleanParams(_params, data);
|
|
5215
|
+
const _fatal = (_b = (_a = params.fatal) !== null && _a !== void 0 ? _a : fatal) !== null && _b !== void 0 ? _b : true;
|
|
5216
|
+
ctx.addIssue(__spreadProps2(__spreadValues2({ code: "custom" }, params), { fatal: _fatal }));
|
|
5202
5217
|
}
|
|
5218
|
+
return;
|
|
5203
5219
|
});
|
|
5204
5220
|
return ZodAny.create();
|
|
5205
5221
|
}
|
|
@@ -5411,11 +5427,37 @@ var z = /* @__PURE__ */ Object.freeze({
|
|
|
5411
5427
|
quotelessJson,
|
|
5412
5428
|
ZodError
|
|
5413
5429
|
});
|
|
5414
|
-
var
|
|
5415
|
-
|
|
5416
|
-
url: z.string()
|
|
5417
|
-
|
|
5418
|
-
|
|
5430
|
+
var linkBehaviorSchema = z.object({
|
|
5431
|
+
type: z.literal("link"),
|
|
5432
|
+
url: z.string()
|
|
5433
|
+
});
|
|
5434
|
+
var navigationStackBehaviorSchema = z.union([
|
|
5435
|
+
z.literal("default"),
|
|
5436
|
+
z.literal("remove-previous"),
|
|
5437
|
+
z.literal("remove-all"),
|
|
5438
|
+
z.literal("replace-current")
|
|
5439
|
+
]);
|
|
5440
|
+
var jsonElementSchema = z.lazy(
|
|
5441
|
+
() => z.union([
|
|
5442
|
+
z.string(),
|
|
5443
|
+
z.number(),
|
|
5444
|
+
z.boolean(),
|
|
5445
|
+
z.record(jsonElementSchema),
|
|
5446
|
+
z.array(jsonElementSchema)
|
|
5447
|
+
]).nullable()
|
|
5448
|
+
);
|
|
5449
|
+
var helpSchema = z.object({
|
|
5450
|
+
markdown: z.string()
|
|
5451
|
+
});
|
|
5452
|
+
var actionTypeSchema = z.union([
|
|
5453
|
+
z.literal("primary"),
|
|
5454
|
+
z.literal("secondary"),
|
|
5455
|
+
z.literal("link"),
|
|
5456
|
+
z.literal("positive"),
|
|
5457
|
+
z.literal("negative")
|
|
5458
|
+
]);
|
|
5459
|
+
var linkSchema = z.object({
|
|
5460
|
+
url: z.string()
|
|
5419
5461
|
});
|
|
5420
5462
|
var httpMethodSchema = z.union([
|
|
5421
5463
|
z.literal("GET"),
|
|
@@ -5424,8 +5466,54 @@ var httpMethodSchema = z.union([
|
|
|
5424
5466
|
z.literal("PATCH"),
|
|
5425
5467
|
z.literal("DELETE")
|
|
5426
5468
|
]);
|
|
5427
|
-
var
|
|
5428
|
-
|
|
5469
|
+
var uploadSourceSchema = z.union([z.literal("camera"), z.literal("file")]);
|
|
5470
|
+
var validateAsyncSchema = z.object({
|
|
5471
|
+
param: z.string(),
|
|
5472
|
+
method: httpMethodSchema,
|
|
5473
|
+
url: z.string()
|
|
5474
|
+
});
|
|
5475
|
+
var summaryProviderSchema = z.object({
|
|
5476
|
+
providesTitle: z.boolean().optional(),
|
|
5477
|
+
providesDescription: z.boolean().optional(),
|
|
5478
|
+
providesIcon: z.boolean().optional(),
|
|
5479
|
+
providesImage: z.boolean().optional()
|
|
5480
|
+
});
|
|
5481
|
+
var imageSchema = z.object({
|
|
5482
|
+
text: z.string().optional(),
|
|
5483
|
+
url: z.string().optional(),
|
|
5484
|
+
uri: z.string().optional(),
|
|
5485
|
+
accessibilityDescription: z.string().optional()
|
|
5486
|
+
});
|
|
5487
|
+
var externalSchema = z.object({
|
|
5488
|
+
url: z.string()
|
|
5489
|
+
});
|
|
5490
|
+
var columnsLayoutBiasSchema = z.union([
|
|
5491
|
+
z.literal("none"),
|
|
5492
|
+
z.literal("left"),
|
|
5493
|
+
z.literal("right")
|
|
5494
|
+
]);
|
|
5495
|
+
var sizeSchema = z.union([
|
|
5496
|
+
z.literal("xs"),
|
|
5497
|
+
z.literal("sm"),
|
|
5498
|
+
z.literal("md"),
|
|
5499
|
+
z.literal("lg"),
|
|
5500
|
+
z.literal("xl")
|
|
5501
|
+
]);
|
|
5502
|
+
var dividerLayoutSchema = z.object({
|
|
5503
|
+
type: z.literal("divider"),
|
|
5504
|
+
control: z.string().optional(),
|
|
5505
|
+
margin: sizeSchema.optional()
|
|
5506
|
+
});
|
|
5507
|
+
var statusListLayoutStatusSchema = z.union([
|
|
5508
|
+
z.literal("not-done"),
|
|
5509
|
+
z.literal("pending"),
|
|
5510
|
+
z.literal("done")
|
|
5511
|
+
]);
|
|
5512
|
+
var loadingIndicatorLayoutSchema = z.object({
|
|
5513
|
+
type: z.literal("loading-indicator"),
|
|
5514
|
+
size: sizeSchema.optional(),
|
|
5515
|
+
control: z.string().optional(),
|
|
5516
|
+
margin: sizeSchema.optional()
|
|
5429
5517
|
});
|
|
5430
5518
|
var contextSchema = z.union([
|
|
5431
5519
|
z.literal("positive"),
|
|
@@ -5437,24 +5525,92 @@ var contextSchema = z.union([
|
|
|
5437
5525
|
z.literal("info"),
|
|
5438
5526
|
z.literal("primary")
|
|
5439
5527
|
]);
|
|
5440
|
-
var
|
|
5441
|
-
text: z.string()
|
|
5528
|
+
var instructionsLayoutItemSchema = z.object({
|
|
5529
|
+
text: z.string(),
|
|
5530
|
+
context: contextSchema,
|
|
5531
|
+
tag: z.string().optional()
|
|
5532
|
+
});
|
|
5533
|
+
var formLayoutSchemaReferenceSchema = z.object({
|
|
5534
|
+
$ref: z.string()
|
|
5535
|
+
});
|
|
5536
|
+
var modalLayoutTriggerSchema = z.object({
|
|
5537
|
+
title: z.string()
|
|
5538
|
+
});
|
|
5539
|
+
var instructionsLayoutSchema = z.object({
|
|
5540
|
+
type: z.literal("instructions"),
|
|
5541
|
+
title: z.string().optional(),
|
|
5542
|
+
items: z.array(instructionsLayoutItemSchema),
|
|
5543
|
+
control: z.string().optional(),
|
|
5544
|
+
margin: sizeSchema.optional()
|
|
5545
|
+
});
|
|
5546
|
+
var reviewLayoutFieldSchema = z.object({
|
|
5547
|
+
label: z.string(),
|
|
5548
|
+
value: z.string(),
|
|
5549
|
+
rawValue: z.string().optional(),
|
|
5550
|
+
help: helpSchema.optional(),
|
|
5551
|
+
tag: z.string().optional()
|
|
5442
5552
|
});
|
|
5443
|
-
var sizeSchema = z.union([
|
|
5444
|
-
z.literal("xs"),
|
|
5445
|
-
z.literal("sm"),
|
|
5446
|
-
z.literal("md"),
|
|
5447
|
-
z.literal("lg"),
|
|
5448
|
-
z.literal("xl")
|
|
5449
|
-
]);
|
|
5450
|
-
var autocapitalizationTypeSchema = z.union([
|
|
5451
|
-
z.literal("none"),
|
|
5452
|
-
z.literal("characters"),
|
|
5453
|
-
z.literal("sentences"),
|
|
5454
|
-
z.literal("words")
|
|
5455
|
-
]);
|
|
5456
5553
|
var alignSchema = z.union([z.literal("left"), z.literal("center"), z.literal("right")]);
|
|
5457
|
-
var
|
|
5554
|
+
var searchLayoutSchema = z.object({
|
|
5555
|
+
type: z.literal("search"),
|
|
5556
|
+
title: z.string(),
|
|
5557
|
+
method: httpMethodSchema,
|
|
5558
|
+
url: z.string(),
|
|
5559
|
+
param: z.string(),
|
|
5560
|
+
emptyMessage: z.string().optional(),
|
|
5561
|
+
control: z.string().optional(),
|
|
5562
|
+
margin: sizeSchema.optional()
|
|
5563
|
+
});
|
|
5564
|
+
var headingLayoutSchema = z.object({
|
|
5565
|
+
type: z.literal("heading"),
|
|
5566
|
+
text: z.string(),
|
|
5567
|
+
size: sizeSchema.optional(),
|
|
5568
|
+
align: alignSchema.optional(),
|
|
5569
|
+
control: z.string().optional(),
|
|
5570
|
+
margin: sizeSchema.optional()
|
|
5571
|
+
});
|
|
5572
|
+
var imageLayoutSchema = z.object({
|
|
5573
|
+
type: z.literal("image"),
|
|
5574
|
+
text: z.string().optional(),
|
|
5575
|
+
url: z.string().optional(),
|
|
5576
|
+
accessibilityDescription: z.string().optional(),
|
|
5577
|
+
content: imageSchema.optional(),
|
|
5578
|
+
size: sizeSchema.optional(),
|
|
5579
|
+
control: z.string().optional(),
|
|
5580
|
+
margin: sizeSchema.optional()
|
|
5581
|
+
});
|
|
5582
|
+
var markdownLayoutSchema = z.object({
|
|
5583
|
+
type: z.literal("markdown"),
|
|
5584
|
+
content: z.string(),
|
|
5585
|
+
align: alignSchema.optional(),
|
|
5586
|
+
control: z.string().optional(),
|
|
5587
|
+
margin: sizeSchema.optional()
|
|
5588
|
+
});
|
|
5589
|
+
var paragraphLayoutSchema = z.object({
|
|
5590
|
+
type: z.literal("paragraph"),
|
|
5591
|
+
text: z.string(),
|
|
5592
|
+
align: alignSchema.optional(),
|
|
5593
|
+
control: z.string().optional(),
|
|
5594
|
+
margin: sizeSchema.optional()
|
|
5595
|
+
});
|
|
5596
|
+
var listLayoutStatusSchema = z.union([
|
|
5597
|
+
z.literal("warning"),
|
|
5598
|
+
z.literal("neutral"),
|
|
5599
|
+
z.literal("positive")
|
|
5600
|
+
]);
|
|
5601
|
+
var errorResponseBodySchema = z.object({
|
|
5602
|
+
refreshFormUrl: z.string().optional(),
|
|
5603
|
+
analytics: z.record(z.string()).optional(),
|
|
5604
|
+
error: z.string().optional(),
|
|
5605
|
+
validation: jsonElementSchema.optional(),
|
|
5606
|
+
refreshUrl: z.string().optional()
|
|
5607
|
+
});
|
|
5608
|
+
var searchSearchRequestSchema = z.object({
|
|
5609
|
+
url: z.string(),
|
|
5610
|
+
method: httpMethodSchema,
|
|
5611
|
+
param: z.string(),
|
|
5612
|
+
query: z.string()
|
|
5613
|
+
});
|
|
5458
5614
|
var autocompleteTokenSchema = z.union([
|
|
5459
5615
|
z.literal("on"),
|
|
5460
5616
|
z.literal("name"),
|
|
@@ -5520,190 +5676,60 @@ var autocompleteTokenSchema = z.union([
|
|
|
5520
5676
|
z.literal("fax"),
|
|
5521
5677
|
z.literal("pager")
|
|
5522
5678
|
]);
|
|
5523
|
-
var
|
|
5524
|
-
|
|
5525
|
-
|
|
5526
|
-
|
|
5527
|
-
|
|
5679
|
+
var autocapitalizationTypeSchema = z.union([
|
|
5680
|
+
z.literal("none"),
|
|
5681
|
+
z.literal("characters"),
|
|
5682
|
+
z.literal("sentences"),
|
|
5683
|
+
z.literal("words")
|
|
5684
|
+
]);
|
|
5685
|
+
var iconNamedSchema = z.object({
|
|
5686
|
+
name: z.string()
|
|
5528
5687
|
});
|
|
5529
|
-
var
|
|
5530
|
-
|
|
5531
|
-
|
|
5532
|
-
|
|
5688
|
+
var iconTextSchema = z.object({
|
|
5689
|
+
text: z.string()
|
|
5690
|
+
});
|
|
5691
|
+
var stringSchemaFormatSchema = z.union([
|
|
5692
|
+
z.literal("date"),
|
|
5693
|
+
z.literal("email"),
|
|
5694
|
+
z.literal("numeric"),
|
|
5695
|
+
z.literal("password"),
|
|
5696
|
+
z.literal("phone-number"),
|
|
5697
|
+
z.literal("base64url")
|
|
5698
|
+
]);
|
|
5699
|
+
var stepErrorSchema = z.object({
|
|
5700
|
+
error: z.string().optional(),
|
|
5701
|
+
validation: jsonElementSchema.optional()
|
|
5702
|
+
});
|
|
5703
|
+
var actionSchema = z.object({
|
|
5704
|
+
title: z.string().optional(),
|
|
5705
|
+
type: actionTypeSchema.optional(),
|
|
5706
|
+
disabled: z.boolean().optional(),
|
|
5707
|
+
$id: z.string().optional(),
|
|
5708
|
+
$ref: z.string().optional(),
|
|
5709
|
+
id: z.string().optional(),
|
|
5710
|
+
url: z.string().optional(),
|
|
5711
|
+
method: httpMethodSchema.optional(),
|
|
5712
|
+
exit: z.boolean().optional(),
|
|
5713
|
+
result: jsonElementSchema.optional(),
|
|
5714
|
+
data: jsonElementSchema.optional(),
|
|
5715
|
+
timeout: z.number().optional(),
|
|
5716
|
+
skipValidation: z.boolean().optional()
|
|
5717
|
+
});
|
|
5718
|
+
var iconSchema = z.union([iconNamedSchema, iconTextSchema]);
|
|
5719
|
+
var formLayoutSchema = z.object({
|
|
5720
|
+
type: z.literal("form"),
|
|
5721
|
+
schema: formLayoutSchemaReferenceSchema.optional(),
|
|
5722
|
+
schemaId: z.string(),
|
|
5533
5723
|
control: z.string().optional(),
|
|
5534
5724
|
margin: sizeSchema.optional()
|
|
5535
5725
|
});
|
|
5536
|
-
var
|
|
5537
|
-
type: z.literal("
|
|
5726
|
+
var infoLayoutSchema = z.object({
|
|
5727
|
+
type: z.literal("info"),
|
|
5728
|
+
markdown: z.string(),
|
|
5729
|
+
align: alignSchema.optional(),
|
|
5538
5730
|
control: z.string().optional(),
|
|
5539
5731
|
margin: sizeSchema.optional()
|
|
5540
5732
|
});
|
|
5541
|
-
var listLayoutStatusSchema = z.union([
|
|
5542
|
-
z.literal("warning"),
|
|
5543
|
-
z.literal("neutral"),
|
|
5544
|
-
z.literal("positive")
|
|
5545
|
-
]);
|
|
5546
|
-
var formLayoutSchemaReferenceSchema = z.object({
|
|
5547
|
-
$ref: z.string()
|
|
5548
|
-
});
|
|
5549
|
-
var imageLayoutSchema = z.object({
|
|
5550
|
-
type: z.literal("image"),
|
|
5551
|
-
text: z.string().optional(),
|
|
5552
|
-
url: z.string().optional(),
|
|
5553
|
-
accessibilityDescription: z.string().optional(),
|
|
5554
|
-
content: imageSchema.optional(),
|
|
5555
|
-
size: sizeSchema.optional(),
|
|
5556
|
-
control: z.string().optional(),
|
|
5557
|
-
margin: sizeSchema.optional()
|
|
5558
|
-
});
|
|
5559
|
-
var statusListLayoutStatusSchema = z.union([
|
|
5560
|
-
z.literal("not-done"),
|
|
5561
|
-
z.literal("pending"),
|
|
5562
|
-
z.literal("done")
|
|
5563
|
-
]);
|
|
5564
|
-
var instructionsLayoutItemSchema = z.object({
|
|
5565
|
-
text: z.string(),
|
|
5566
|
-
context: contextSchema,
|
|
5567
|
-
tag: z.string().optional()
|
|
5568
|
-
});
|
|
5569
|
-
var modalLayoutTriggerSchema = z.object({
|
|
5570
|
-
title: z.string()
|
|
5571
|
-
});
|
|
5572
|
-
var searchLayoutSchema = z.object({
|
|
5573
|
-
type: z.literal("search"),
|
|
5574
|
-
title: z.string(),
|
|
5575
|
-
method: httpMethodSchema,
|
|
5576
|
-
url: z.string(),
|
|
5577
|
-
param: z.string(),
|
|
5578
|
-
emptyMessage: z.string().optional(),
|
|
5579
|
-
control: z.string().optional(),
|
|
5580
|
-
margin: sizeSchema.optional()
|
|
5581
|
-
});
|
|
5582
|
-
var infoLayoutSchema = z.object({
|
|
5583
|
-
type: z.literal("info"),
|
|
5584
|
-
markdown: z.string(),
|
|
5585
|
-
align: alignSchema.optional(),
|
|
5586
|
-
control: z.string().optional(),
|
|
5587
|
-
margin: sizeSchema.optional()
|
|
5588
|
-
});
|
|
5589
|
-
var formLayoutSchema = z.object({
|
|
5590
|
-
type: z.literal("form"),
|
|
5591
|
-
schema: formLayoutSchemaReferenceSchema.optional(),
|
|
5592
|
-
schemaId: z.string(),
|
|
5593
|
-
control: z.string().optional(),
|
|
5594
|
-
margin: sizeSchema.optional()
|
|
5595
|
-
});
|
|
5596
|
-
var headingLayoutSchema = z.object({
|
|
5597
|
-
type: z.literal("heading"),
|
|
5598
|
-
text: z.string(),
|
|
5599
|
-
size: sizeSchema.optional(),
|
|
5600
|
-
align: alignSchema.optional(),
|
|
5601
|
-
control: z.string().optional(),
|
|
5602
|
-
margin: sizeSchema.optional()
|
|
5603
|
-
});
|
|
5604
|
-
var markdownLayoutSchema = z.object({
|
|
5605
|
-
type: z.literal("markdown"),
|
|
5606
|
-
content: z.string(),
|
|
5607
|
-
align: alignSchema.optional(),
|
|
5608
|
-
control: z.string().optional(),
|
|
5609
|
-
margin: sizeSchema.optional()
|
|
5610
|
-
});
|
|
5611
|
-
var columnsLayoutBiasSchema = z.union([
|
|
5612
|
-
z.literal("none"),
|
|
5613
|
-
z.literal("left"),
|
|
5614
|
-
z.literal("right")
|
|
5615
|
-
]);
|
|
5616
|
-
var helpSchema = z.object({
|
|
5617
|
-
markdown: z.string()
|
|
5618
|
-
});
|
|
5619
|
-
var searchSearchRequestSchema = z.object({
|
|
5620
|
-
url: z.string(),
|
|
5621
|
-
method: httpMethodSchema,
|
|
5622
|
-
param: z.string(),
|
|
5623
|
-
query: z.string()
|
|
5624
|
-
});
|
|
5625
|
-
var jsonElementSchema = z.lazy(
|
|
5626
|
-
() => z.union([
|
|
5627
|
-
z.string(),
|
|
5628
|
-
z.number(),
|
|
5629
|
-
z.boolean(),
|
|
5630
|
-
z.record(jsonElementSchema),
|
|
5631
|
-
z.array(jsonElementSchema)
|
|
5632
|
-
]).nullable()
|
|
5633
|
-
);
|
|
5634
|
-
var externalSchema = z.object({
|
|
5635
|
-
url: z.string()
|
|
5636
|
-
});
|
|
5637
|
-
var stepErrorSchema = z.object({
|
|
5638
|
-
error: z.string().optional(),
|
|
5639
|
-
validation: jsonElementSchema.optional()
|
|
5640
|
-
});
|
|
5641
|
-
var stringSchemaFormatSchema = z.union([
|
|
5642
|
-
z.literal("date"),
|
|
5643
|
-
z.literal("email"),
|
|
5644
|
-
z.literal("numeric"),
|
|
5645
|
-
z.literal("password"),
|
|
5646
|
-
z.literal("phone-number"),
|
|
5647
|
-
z.literal("base64url")
|
|
5648
|
-
]);
|
|
5649
|
-
var summarySummariserSchema = z.object({
|
|
5650
|
-
defaultTitle: z.string().optional(),
|
|
5651
|
-
defaultDescription: z.string().optional(),
|
|
5652
|
-
defaultIcon: iconSchema.optional(),
|
|
5653
|
-
defaultImage: imageSchema.optional(),
|
|
5654
|
-
providesTitle: z.boolean().optional(),
|
|
5655
|
-
providesDescription: z.boolean().optional(),
|
|
5656
|
-
providesIcon: z.boolean().optional(),
|
|
5657
|
-
providesImage: z.boolean().optional()
|
|
5658
|
-
});
|
|
5659
|
-
var validateAsyncSchema = z.object({
|
|
5660
|
-
param: z.string(),
|
|
5661
|
-
method: httpMethodSchema,
|
|
5662
|
-
url: z.string()
|
|
5663
|
-
});
|
|
5664
|
-
var summaryProviderSchema = z.object({
|
|
5665
|
-
providesTitle: z.boolean().optional(),
|
|
5666
|
-
providesDescription: z.boolean().optional(),
|
|
5667
|
-
providesIcon: z.boolean().optional(),
|
|
5668
|
-
providesImage: z.boolean().optional()
|
|
5669
|
-
});
|
|
5670
|
-
var uploadSourceSchema = z.union([z.literal("camera"), z.literal("file")]);
|
|
5671
|
-
var navigationStackBehaviorSchema = z.union([
|
|
5672
|
-
z.literal("default"),
|
|
5673
|
-
z.literal("remove-previous"),
|
|
5674
|
-
z.literal("remove-all"),
|
|
5675
|
-
z.literal("replace-current")
|
|
5676
|
-
]);
|
|
5677
|
-
var actionTypeSchema = z.union([
|
|
5678
|
-
z.literal("primary"),
|
|
5679
|
-
z.literal("secondary"),
|
|
5680
|
-
z.literal("link"),
|
|
5681
|
-
z.literal("positive"),
|
|
5682
|
-
z.literal("negative")
|
|
5683
|
-
]);
|
|
5684
|
-
var summarySchema = z.union([summaryProviderSchema, summarySummariserSchema]);
|
|
5685
|
-
var linkBehaviorSchema = z.object({
|
|
5686
|
-
type: z.literal("link"),
|
|
5687
|
-
url: z.string()
|
|
5688
|
-
});
|
|
5689
|
-
var linkSchema = z.object({
|
|
5690
|
-
url: z.string()
|
|
5691
|
-
});
|
|
5692
|
-
var actionSchema = z.object({
|
|
5693
|
-
title: z.string().optional(),
|
|
5694
|
-
type: actionTypeSchema.optional(),
|
|
5695
|
-
disabled: z.boolean().optional(),
|
|
5696
|
-
$id: z.string().optional(),
|
|
5697
|
-
$ref: z.string().optional(),
|
|
5698
|
-
id: z.string().optional(),
|
|
5699
|
-
url: z.string().optional(),
|
|
5700
|
-
method: httpMethodSchema.optional(),
|
|
5701
|
-
exit: z.boolean().optional(),
|
|
5702
|
-
result: jsonElementSchema.optional(),
|
|
5703
|
-
data: jsonElementSchema.optional(),
|
|
5704
|
-
timeout: z.number().optional(),
|
|
5705
|
-
skipValidation: z.boolean().optional()
|
|
5706
|
-
});
|
|
5707
5733
|
var listLayoutItemSchema = z.object({
|
|
5708
5734
|
description: z.string().optional(),
|
|
5709
5735
|
status: listLayoutStatusSchema.optional(),
|
|
@@ -5715,73 +5741,78 @@ var listLayoutItemSchema = z.object({
|
|
|
5715
5741
|
subvalue: z.string().optional(),
|
|
5716
5742
|
tag: z.string().optional()
|
|
5717
5743
|
});
|
|
5718
|
-
var
|
|
5719
|
-
|
|
5720
|
-
title: z.string().optional(),
|
|
5721
|
-
items: z.array(instructionsLayoutItemSchema),
|
|
5722
|
-
control: z.string().optional(),
|
|
5723
|
-
margin: sizeSchema.optional()
|
|
5724
|
-
});
|
|
5725
|
-
var reviewLayoutFieldSchema = z.object({
|
|
5726
|
-
label: z.string(),
|
|
5727
|
-
value: z.string(),
|
|
5728
|
-
rawValue: z.string().optional(),
|
|
5729
|
-
help: helpSchema.optional(),
|
|
5730
|
-
tag: z.string().optional()
|
|
5744
|
+
var actionResponseBodySchema = z.object({
|
|
5745
|
+
action: actionSchema
|
|
5731
5746
|
});
|
|
5732
|
-
var
|
|
5733
|
-
type: z.literal("
|
|
5747
|
+
var searchResultActionSchema = z.object({
|
|
5748
|
+
type: z.literal("action"),
|
|
5734
5749
|
title: z.string(),
|
|
5735
5750
|
description: z.string().optional(),
|
|
5736
5751
|
icon: iconSchema.optional(),
|
|
5737
5752
|
image: imageSchema.optional(),
|
|
5738
|
-
value:
|
|
5753
|
+
value: actionSchema
|
|
5739
5754
|
});
|
|
5740
|
-
var
|
|
5741
|
-
type: z.literal("
|
|
5755
|
+
var searchResultSearchSchema = z.object({
|
|
5756
|
+
type: z.literal("search"),
|
|
5742
5757
|
title: z.string(),
|
|
5743
5758
|
description: z.string().optional(),
|
|
5744
5759
|
icon: iconSchema.optional(),
|
|
5745
5760
|
image: imageSchema.optional(),
|
|
5746
|
-
value:
|
|
5761
|
+
value: searchSearchRequestSchema
|
|
5747
5762
|
});
|
|
5748
|
-
var
|
|
5763
|
+
var actionBehaviorSchema = z.object({
|
|
5764
|
+
type: z.literal("action"),
|
|
5749
5765
|
action: actionSchema
|
|
5750
5766
|
});
|
|
5751
|
-
var
|
|
5752
|
-
|
|
5753
|
-
|
|
5754
|
-
error: z.string().optional(),
|
|
5755
|
-
validation: jsonElementSchema.optional(),
|
|
5756
|
-
refreshUrl: z.string().optional()
|
|
5767
|
+
var containerBehaviorSchema = z.object({
|
|
5768
|
+
action: actionSchema.optional(),
|
|
5769
|
+
link: linkSchema.optional()
|
|
5757
5770
|
});
|
|
5758
5771
|
var navigationBackBehaviorSchema = z.object({
|
|
5759
5772
|
title: z.string().optional(),
|
|
5760
5773
|
action: actionSchema
|
|
5761
5774
|
});
|
|
5762
|
-
var
|
|
5763
|
-
|
|
5764
|
-
|
|
5775
|
+
var summarySummariserSchema = z.object({
|
|
5776
|
+
defaultTitle: z.string().optional(),
|
|
5777
|
+
defaultDescription: z.string().optional(),
|
|
5778
|
+
defaultIcon: iconSchema.optional(),
|
|
5779
|
+
defaultImage: imageSchema.optional(),
|
|
5780
|
+
providesTitle: z.boolean().optional(),
|
|
5781
|
+
providesDescription: z.boolean().optional(),
|
|
5782
|
+
providesIcon: z.boolean().optional(),
|
|
5783
|
+
providesImage: z.boolean().optional()
|
|
5765
5784
|
});
|
|
5766
|
-
var
|
|
5767
|
-
|
|
5768
|
-
|
|
5785
|
+
var searchResultSchema = z.union([searchResultActionSchema, searchResultSearchSchema]);
|
|
5786
|
+
var searchResponseBodySchema = z.object({
|
|
5787
|
+
results: z.array(searchResultSchema)
|
|
5769
5788
|
});
|
|
5770
5789
|
var behaviorSchema = z.union([
|
|
5771
5790
|
actionBehaviorSchema,
|
|
5772
5791
|
containerBehaviorSchema,
|
|
5773
5792
|
linkBehaviorSchema
|
|
5774
5793
|
]);
|
|
5775
|
-
var
|
|
5776
|
-
|
|
5777
|
-
|
|
5778
|
-
|
|
5794
|
+
var navigationSchema = z.object({
|
|
5795
|
+
backButton: navigationBackBehaviorSchema.optional(),
|
|
5796
|
+
back: navigationBackBehaviorSchema.optional(),
|
|
5797
|
+
stackBehavior: navigationStackBehaviorSchema.optional()
|
|
5779
5798
|
});
|
|
5780
|
-
var
|
|
5781
|
-
|
|
5782
|
-
|
|
5783
|
-
|
|
5799
|
+
var linkHandlerSchema = z.object({
|
|
5800
|
+
regexPattern: z.string(),
|
|
5801
|
+
behavior: behaviorSchema.optional()
|
|
5802
|
+
});
|
|
5803
|
+
var pollingOnErrorSchema = z.object({
|
|
5804
|
+
action: actionSchema.optional(),
|
|
5805
|
+
behavior: behaviorSchema.optional()
|
|
5784
5806
|
});
|
|
5807
|
+
var pollingSchema = z.object({
|
|
5808
|
+
interval: z.number().optional(),
|
|
5809
|
+
url: z.string(),
|
|
5810
|
+
delay: z.number().optional(),
|
|
5811
|
+
timeout: z.number().optional(),
|
|
5812
|
+
maxAttempts: z.number(),
|
|
5813
|
+
onError: pollingOnErrorSchema
|
|
5814
|
+
});
|
|
5815
|
+
var summarySchema = z.union([summaryProviderSchema, summarySummariserSchema]);
|
|
5785
5816
|
var decisionLayoutOptionSchema = z.object({
|
|
5786
5817
|
action: actionSchema.optional(),
|
|
5787
5818
|
title: z.string(),
|
|
@@ -5792,11 +5823,6 @@ var decisionLayoutOptionSchema = z.object({
|
|
|
5792
5823
|
behavior: behaviorSchema.optional(),
|
|
5793
5824
|
tag: z.string().optional()
|
|
5794
5825
|
});
|
|
5795
|
-
var itemCallToActionSchema = z.object({
|
|
5796
|
-
title: z.string(),
|
|
5797
|
-
accessibilityDescription: z.string().optional(),
|
|
5798
|
-
behavior: behaviorSchema
|
|
5799
|
-
});
|
|
5800
5826
|
var buttonLayoutSchema = z.object({
|
|
5801
5827
|
type: z.literal("button"),
|
|
5802
5828
|
action: actionSchema.optional(),
|
|
@@ -5809,26 +5835,22 @@ var buttonLayoutSchema = z.object({
|
|
|
5809
5835
|
control: z.string().optional(),
|
|
5810
5836
|
margin: sizeSchema.optional()
|
|
5811
5837
|
});
|
|
5812
|
-
var searchResultSchema = z.union([searchResultActionSchema, searchResultSearchSchema]);
|
|
5813
|
-
var linkHandlerSchema = z.object({
|
|
5814
|
-
regexPattern: z.string(),
|
|
5815
|
-
behavior: behaviorSchema.optional()
|
|
5816
|
-
});
|
|
5817
|
-
var navigationSchema = z.object({
|
|
5818
|
-
backButton: navigationBackBehaviorSchema.optional(),
|
|
5819
|
-
back: navigationBackBehaviorSchema.optional(),
|
|
5820
|
-
stackBehavior: navigationStackBehaviorSchema.optional()
|
|
5821
|
-
});
|
|
5822
|
-
var pollingOnErrorSchema = z.object({
|
|
5823
|
-
action: actionSchema.optional(),
|
|
5824
|
-
behavior: behaviorSchema.optional()
|
|
5825
|
-
});
|
|
5826
5838
|
var reviewLayoutCallToActionSchema = z.object({
|
|
5827
5839
|
action: actionSchema.optional(),
|
|
5828
5840
|
title: z.string(),
|
|
5829
5841
|
accessibilityDescription: z.string().optional(),
|
|
5830
5842
|
behavior: behaviorSchema.optional()
|
|
5831
5843
|
});
|
|
5844
|
+
var alertLayoutCallToActionSchema = z.object({
|
|
5845
|
+
title: z.string(),
|
|
5846
|
+
accessibilityDescription: z.string().optional(),
|
|
5847
|
+
behavior: behaviorSchema
|
|
5848
|
+
});
|
|
5849
|
+
var itemCallToActionSchema = z.object({
|
|
5850
|
+
title: z.string(),
|
|
5851
|
+
accessibilityDescription: z.string().optional(),
|
|
5852
|
+
behavior: behaviorSchema
|
|
5853
|
+
});
|
|
5832
5854
|
var alertLayoutSchema = z.object({
|
|
5833
5855
|
type: z.literal("alert"),
|
|
5834
5856
|
markdown: z.string(),
|
|
@@ -5837,13 +5859,10 @@ var alertLayoutSchema = z.object({
|
|
|
5837
5859
|
margin: sizeSchema.optional(),
|
|
5838
5860
|
callToAction: alertLayoutCallToActionSchema.optional()
|
|
5839
5861
|
});
|
|
5840
|
-
var
|
|
5841
|
-
|
|
5842
|
-
|
|
5843
|
-
|
|
5844
|
-
items: z.array(listLayoutItemSchema),
|
|
5845
|
-
control: z.string().optional(),
|
|
5846
|
-
margin: sizeSchema.optional()
|
|
5862
|
+
var listLayoutCallToActionSchema = z.object({
|
|
5863
|
+
title: z.string(),
|
|
5864
|
+
accessibilityDescription: z.string().optional(),
|
|
5865
|
+
behavior: behaviorSchema
|
|
5847
5866
|
});
|
|
5848
5867
|
var decisionLayoutSchema = z.object({
|
|
5849
5868
|
type: z.literal("decision"),
|
|
@@ -5852,34 +5871,29 @@ var decisionLayoutSchema = z.object({
|
|
|
5852
5871
|
control: z.string().optional(),
|
|
5853
5872
|
margin: sizeSchema.optional()
|
|
5854
5873
|
});
|
|
5855
|
-
var
|
|
5856
|
-
|
|
5857
|
-
description: z.string().optional(),
|
|
5858
|
-
icon: iconSchema,
|
|
5859
|
-
status: statusListLayoutStatusSchema.optional(),
|
|
5860
|
-
callToAction: itemCallToActionSchema.optional(),
|
|
5861
|
-
tag: z.string().optional()
|
|
5862
|
-
});
|
|
5863
|
-
var reviewLayoutSchema = z.object({
|
|
5864
|
-
type: z.literal("review"),
|
|
5865
|
-
orientation: z.string().optional(),
|
|
5866
|
-
action: actionSchema.optional(),
|
|
5867
|
-
fields: z.array(reviewLayoutFieldSchema),
|
|
5874
|
+
var listLayoutSchema = z.object({
|
|
5875
|
+
type: z.literal("list"),
|
|
5868
5876
|
title: z.string().optional(),
|
|
5869
|
-
callToAction:
|
|
5877
|
+
callToAction: listLayoutCallToActionSchema.optional(),
|
|
5878
|
+
items: z.array(listLayoutItemSchema),
|
|
5870
5879
|
control: z.string().optional(),
|
|
5871
5880
|
margin: sizeSchema.optional()
|
|
5872
5881
|
});
|
|
5873
|
-
var
|
|
5874
|
-
|
|
5875
|
-
|
|
5876
|
-
|
|
5877
|
-
|
|
5878
|
-
|
|
5879
|
-
|
|
5880
|
-
|
|
5881
|
-
|
|
5882
|
-
|
|
5882
|
+
var constSchemaSchema = z.object({
|
|
5883
|
+
hidden: z.boolean().optional(),
|
|
5884
|
+
alert: alertLayoutSchema.optional(),
|
|
5885
|
+
control: z.string().optional(),
|
|
5886
|
+
promoted: z.boolean().optional(),
|
|
5887
|
+
$id: z.string().optional(),
|
|
5888
|
+
const: jsonElementSchema,
|
|
5889
|
+
title: z.string().optional(),
|
|
5890
|
+
description: z.string().optional(),
|
|
5891
|
+
icon: iconSchema.optional(),
|
|
5892
|
+
image: imageSchema.optional(),
|
|
5893
|
+
keywords: z.array(z.string()).optional(),
|
|
5894
|
+
summary: summaryProviderSchema.optional(),
|
|
5895
|
+
analyticsId: z.string().optional(),
|
|
5896
|
+
disabled: z.boolean().optional()
|
|
5883
5897
|
});
|
|
5884
5898
|
var blobSchemaSchema = z.object({
|
|
5885
5899
|
type: z.literal("blob"),
|
|
@@ -5903,21 +5917,23 @@ var blobSchemaSchema = z.object({
|
|
|
5903
5917
|
source: uploadSourceSchema.optional(),
|
|
5904
5918
|
disabled: z.boolean().optional()
|
|
5905
5919
|
});
|
|
5906
|
-
var
|
|
5907
|
-
|
|
5908
|
-
|
|
5909
|
-
|
|
5910
|
-
|
|
5911
|
-
$id: z.string().optional(),
|
|
5912
|
-
const: jsonElementSchema,
|
|
5920
|
+
var reviewLayoutSchema = z.object({
|
|
5921
|
+
type: z.literal("review"),
|
|
5922
|
+
orientation: z.string().optional(),
|
|
5923
|
+
action: actionSchema.optional(),
|
|
5924
|
+
fields: z.array(reviewLayoutFieldSchema),
|
|
5913
5925
|
title: z.string().optional(),
|
|
5926
|
+
callToAction: reviewLayoutCallToActionSchema.optional(),
|
|
5927
|
+
control: z.string().optional(),
|
|
5928
|
+
margin: sizeSchema.optional()
|
|
5929
|
+
});
|
|
5930
|
+
var statusListLayoutItemSchema = z.object({
|
|
5931
|
+
title: z.string(),
|
|
5914
5932
|
description: z.string().optional(),
|
|
5915
|
-
icon: iconSchema
|
|
5916
|
-
|
|
5917
|
-
|
|
5918
|
-
|
|
5919
|
-
analyticsId: z.string().optional(),
|
|
5920
|
-
disabled: z.boolean().optional()
|
|
5933
|
+
icon: iconSchema,
|
|
5934
|
+
status: statusListLayoutStatusSchema.optional(),
|
|
5935
|
+
callToAction: itemCallToActionSchema.optional(),
|
|
5936
|
+
tag: z.string().optional()
|
|
5921
5937
|
});
|
|
5922
5938
|
var statusListLayoutSchema = z.object({
|
|
5923
5939
|
type: z.literal("status-list"),
|
|
@@ -5926,6 +5942,39 @@ var statusListLayoutSchema = z.object({
|
|
|
5926
5942
|
control: z.string().optional(),
|
|
5927
5943
|
margin: sizeSchema.optional()
|
|
5928
5944
|
});
|
|
5945
|
+
var persistAsyncSchema = z.lazy(
|
|
5946
|
+
() => z.object({
|
|
5947
|
+
param: z.string(),
|
|
5948
|
+
idProperty: z.string(),
|
|
5949
|
+
schema: schemaSchema,
|
|
5950
|
+
url: z.string(),
|
|
5951
|
+
method: httpMethodSchema
|
|
5952
|
+
})
|
|
5953
|
+
);
|
|
5954
|
+
var schemaSchema = z.lazy(
|
|
5955
|
+
() => z.union([
|
|
5956
|
+
allOfSchemaSchema,
|
|
5957
|
+
arraySchemaSchema,
|
|
5958
|
+
blobSchemaSchema,
|
|
5959
|
+
booleanSchemaSchema,
|
|
5960
|
+
constSchemaSchema,
|
|
5961
|
+
integerSchemaSchema,
|
|
5962
|
+
numberSchemaSchema,
|
|
5963
|
+
objectSchemaSchema,
|
|
5964
|
+
oneOfSchemaSchema,
|
|
5965
|
+
stringSchemaSchema
|
|
5966
|
+
])
|
|
5967
|
+
);
|
|
5968
|
+
var columnsLayoutSchema = z.lazy(
|
|
5969
|
+
() => z.object({
|
|
5970
|
+
type: z.literal("columns"),
|
|
5971
|
+
left: z.array(layoutSchema),
|
|
5972
|
+
right: z.array(layoutSchema),
|
|
5973
|
+
bias: columnsLayoutBiasSchema.optional(),
|
|
5974
|
+
control: z.string().optional(),
|
|
5975
|
+
margin: sizeSchema.optional()
|
|
5976
|
+
})
|
|
5977
|
+
);
|
|
5929
5978
|
var layoutSchema = z.lazy(
|
|
5930
5979
|
() => z.union([
|
|
5931
5980
|
alertLayoutSchema,
|
|
@@ -5949,6 +5998,12 @@ var layoutSchema = z.lazy(
|
|
|
5949
5998
|
statusListLayoutSchema
|
|
5950
5999
|
])
|
|
5951
6000
|
);
|
|
6001
|
+
var modalLayoutContentSchema = z.lazy(
|
|
6002
|
+
() => z.object({
|
|
6003
|
+
title: z.string().optional(),
|
|
6004
|
+
components: z.array(layoutSchema)
|
|
6005
|
+
})
|
|
6006
|
+
);
|
|
5952
6007
|
var boxLayoutSchema = z.lazy(
|
|
5953
6008
|
() => z.object({
|
|
5954
6009
|
type: z.literal("box"),
|
|
@@ -5959,16 +6014,6 @@ var boxLayoutSchema = z.lazy(
|
|
|
5959
6014
|
margin: sizeSchema.optional()
|
|
5960
6015
|
})
|
|
5961
6016
|
);
|
|
5962
|
-
var columnsLayoutSchema = z.lazy(
|
|
5963
|
-
() => z.object({
|
|
5964
|
-
type: z.literal("columns"),
|
|
5965
|
-
left: z.array(layoutSchema),
|
|
5966
|
-
right: z.array(layoutSchema),
|
|
5967
|
-
bias: columnsLayoutBiasSchema.optional(),
|
|
5968
|
-
control: z.string().optional(),
|
|
5969
|
-
margin: sizeSchema.optional()
|
|
5970
|
-
})
|
|
5971
|
-
);
|
|
5972
6017
|
var modalLayoutSchema = z.lazy(
|
|
5973
6018
|
() => z.object({
|
|
5974
6019
|
type: z.literal("modal"),
|
|
@@ -5978,12 +6023,6 @@ var modalLayoutSchema = z.lazy(
|
|
|
5978
6023
|
content: modalLayoutContentSchema
|
|
5979
6024
|
})
|
|
5980
6025
|
);
|
|
5981
|
-
var modalLayoutContentSchema = z.lazy(
|
|
5982
|
-
() => z.object({
|
|
5983
|
-
title: z.string().optional(),
|
|
5984
|
-
components: z.array(layoutSchema)
|
|
5985
|
-
})
|
|
5986
|
-
);
|
|
5987
6026
|
var stepSchema = z.lazy(
|
|
5988
6027
|
() => z.object({
|
|
5989
6028
|
key: z.string().optional(),
|
|
@@ -6003,57 +6042,33 @@ var stepSchema = z.lazy(
|
|
|
6003
6042
|
errors: stepErrorSchema.optional(),
|
|
6004
6043
|
navigation: navigationSchema.optional(),
|
|
6005
6044
|
refreshUrl: z.string().optional(),
|
|
6045
|
+
refreshAfter: z.string().optional(),
|
|
6006
6046
|
control: z.string().optional()
|
|
6007
6047
|
})
|
|
6008
6048
|
);
|
|
6009
|
-
var
|
|
6010
|
-
() => z.union([
|
|
6011
|
-
allOfSchemaSchema,
|
|
6012
|
-
arraySchemaSchema,
|
|
6013
|
-
blobSchemaSchema,
|
|
6014
|
-
booleanSchemaSchema,
|
|
6015
|
-
constSchemaSchema,
|
|
6016
|
-
integerSchemaSchema,
|
|
6017
|
-
numberSchemaSchema,
|
|
6018
|
-
objectSchemaSchema,
|
|
6019
|
-
oneOfSchemaSchema,
|
|
6020
|
-
stringSchemaSchema
|
|
6021
|
-
])
|
|
6022
|
-
);
|
|
6023
|
-
var allOfSchemaSchema = z.lazy(
|
|
6024
|
-
() => z.object({
|
|
6025
|
-
disabled: z.boolean().optional(),
|
|
6026
|
-
promoted: z.boolean().optional(),
|
|
6027
|
-
allOf: z.array(schemaSchema),
|
|
6028
|
-
$id: z.string().optional(),
|
|
6029
|
-
title: z.string().optional(),
|
|
6030
|
-
description: z.string().optional(),
|
|
6031
|
-
control: z.string().optional(),
|
|
6032
|
-
hidden: z.boolean().optional(),
|
|
6033
|
-
icon: iconSchema.optional(),
|
|
6034
|
-
image: imageSchema.optional(),
|
|
6035
|
-
keywords: z.array(z.string()).optional(),
|
|
6036
|
-
summary: summaryProviderSchema.optional(),
|
|
6037
|
-
analyticsId: z.string().optional(),
|
|
6038
|
-
alert: alertLayoutSchema.optional()
|
|
6039
|
-
})
|
|
6040
|
-
);
|
|
6041
|
-
var arraySchemaSchema = z.lazy(
|
|
6042
|
-
() => z.union([arraySchemaListSchema, arraySchemaTupleSchema])
|
|
6043
|
-
);
|
|
6044
|
-
var booleanSchemaSchema = z.lazy(
|
|
6049
|
+
var stringSchemaSchema = z.lazy(
|
|
6045
6050
|
() => z.object({
|
|
6046
|
-
type: z.literal("
|
|
6051
|
+
type: z.literal("string"),
|
|
6047
6052
|
autofillProvider: z.string().optional(),
|
|
6048
6053
|
promoted: z.boolean().optional(),
|
|
6049
6054
|
refreshFormOnChange: z.boolean().optional(),
|
|
6050
6055
|
refreshUrl: z.string().optional(),
|
|
6051
6056
|
refreshFormUrl: z.string().optional(),
|
|
6057
|
+
format: stringSchemaFormatSchema.optional(),
|
|
6058
|
+
displayFormat: z.string().optional(),
|
|
6059
|
+
placeholder: z.string().optional(),
|
|
6060
|
+
minLength: z.number().optional(),
|
|
6061
|
+
maxLength: z.number().optional(),
|
|
6062
|
+
minimum: z.string().optional(),
|
|
6063
|
+
maximum: z.string().optional(),
|
|
6064
|
+
pattern: z.string().optional(),
|
|
6065
|
+
autocapitalization: autocapitalizationTypeSchema.optional(),
|
|
6066
|
+
autocorrect: z.boolean().optional(),
|
|
6052
6067
|
$id: z.string().optional(),
|
|
6053
6068
|
title: z.string().optional(),
|
|
6054
6069
|
description: z.string().optional(),
|
|
6055
6070
|
control: z.string().optional(),
|
|
6056
|
-
default: z.
|
|
6071
|
+
default: z.string().optional(),
|
|
6057
6072
|
hidden: z.boolean().optional(),
|
|
6058
6073
|
disabled: z.boolean().optional(),
|
|
6059
6074
|
icon: iconSchema.optional(),
|
|
@@ -6064,42 +6079,45 @@ var booleanSchemaSchema = z.lazy(
|
|
|
6064
6079
|
persistAsync: persistAsyncSchema.optional(),
|
|
6065
6080
|
refreshStepOnChange: z.boolean().optional(),
|
|
6066
6081
|
validationAsync: validateAsyncSchema.optional(),
|
|
6082
|
+
validationMessages: z.record(z.string()).optional(),
|
|
6067
6083
|
alert: alertLayoutSchema.optional(),
|
|
6084
|
+
cameraConfig: jsonElementSchema.optional(),
|
|
6085
|
+
accepts: z.array(z.string()).optional(),
|
|
6086
|
+
maxSize: z.number().optional(),
|
|
6087
|
+
source: uploadSourceSchema.optional(),
|
|
6088
|
+
autocompleteHint: z.array(autocompleteTokenSchema).optional(),
|
|
6068
6089
|
autofillKey: z.string().optional(),
|
|
6069
6090
|
help: helpSchema.optional()
|
|
6070
6091
|
})
|
|
6071
6092
|
);
|
|
6072
|
-
var
|
|
6093
|
+
var oneOfSchemaSchema = z.lazy(
|
|
6073
6094
|
() => z.object({
|
|
6074
|
-
type: z.literal("integer"),
|
|
6075
6095
|
autofillProvider: z.string().optional(),
|
|
6076
6096
|
promoted: z.boolean().optional(),
|
|
6077
6097
|
refreshFormOnChange: z.boolean().optional(),
|
|
6078
6098
|
refreshUrl: z.string().optional(),
|
|
6079
6099
|
refreshFormUrl: z.string().optional(),
|
|
6100
|
+
promotion: jsonElementSchema.optional(),
|
|
6101
|
+
oneOf: z.array(schemaSchema),
|
|
6080
6102
|
placeholder: z.string().optional(),
|
|
6081
|
-
minimum: z.number().optional(),
|
|
6082
|
-
maximum: z.number().optional(),
|
|
6083
6103
|
$id: z.string().optional(),
|
|
6084
6104
|
title: z.string().optional(),
|
|
6085
6105
|
description: z.string().optional(),
|
|
6086
6106
|
control: z.string().optional(),
|
|
6087
|
-
default:
|
|
6107
|
+
default: jsonElementSchema.optional(),
|
|
6088
6108
|
hidden: z.boolean().optional(),
|
|
6089
|
-
disabled: z.boolean().optional(),
|
|
6090
6109
|
icon: iconSchema.optional(),
|
|
6091
6110
|
image: imageSchema.optional(),
|
|
6092
6111
|
keywords: z.array(z.string()).optional(),
|
|
6093
6112
|
summary: summaryProviderSchema.optional(),
|
|
6094
6113
|
analyticsId: z.string().optional(),
|
|
6095
|
-
persistAsync: persistAsyncSchema.optional(),
|
|
6096
6114
|
refreshStepOnChange: z.boolean().optional(),
|
|
6097
|
-
validationAsync: validateAsyncSchema.optional(),
|
|
6098
|
-
validationMessages: z.record(z.string()).optional(),
|
|
6099
6115
|
alert: alertLayoutSchema.optional(),
|
|
6116
|
+
help: helpSchema.optional(),
|
|
6100
6117
|
autocompleteHint: z.array(autocompleteTokenSchema).optional(),
|
|
6101
6118
|
autofillKey: z.string().optional(),
|
|
6102
|
-
|
|
6119
|
+
validationMessages: z.record(z.string()).optional(),
|
|
6120
|
+
disabled: z.boolean().optional()
|
|
6103
6121
|
})
|
|
6104
6122
|
);
|
|
6105
6123
|
var numberSchemaSchema = z.lazy(
|
|
@@ -6135,16 +6153,12 @@ var numberSchemaSchema = z.lazy(
|
|
|
6135
6153
|
help: helpSchema.optional()
|
|
6136
6154
|
})
|
|
6137
6155
|
);
|
|
6138
|
-
var
|
|
6156
|
+
var arraySchemaTupleSchema = z.lazy(
|
|
6139
6157
|
() => z.object({
|
|
6140
|
-
type: z.literal("
|
|
6141
|
-
disabled: z.boolean().optional(),
|
|
6158
|
+
type: z.literal("array"),
|
|
6142
6159
|
promoted: z.boolean().optional(),
|
|
6143
|
-
help: helpSchema.optional(),
|
|
6144
|
-
properties: z.record(schemaSchema),
|
|
6145
|
-
displayOrder: z.array(z.string()),
|
|
6146
|
-
required: z.array(z.string()).optional(),
|
|
6147
6160
|
$id: z.string().optional(),
|
|
6161
|
+
items: z.array(schemaSchema),
|
|
6148
6162
|
title: z.string().optional(),
|
|
6149
6163
|
description: z.string().optional(),
|
|
6150
6164
|
control: z.string().optional(),
|
|
@@ -6154,62 +6168,27 @@ var objectSchemaSchema = z.lazy(
|
|
|
6154
6168
|
keywords: z.array(z.string()).optional(),
|
|
6155
6169
|
summary: summaryProviderSchema.optional(),
|
|
6156
6170
|
analyticsId: z.string().optional(),
|
|
6171
|
+
persistAsync: persistAsyncSchema.optional(),
|
|
6172
|
+
validationAsync: validateAsyncSchema.optional(),
|
|
6157
6173
|
alert: alertLayoutSchema.optional()
|
|
6158
6174
|
})
|
|
6159
6175
|
);
|
|
6160
|
-
var
|
|
6161
|
-
() => z.object({
|
|
6162
|
-
autofillProvider: z.string().optional(),
|
|
6163
|
-
promoted: z.boolean().optional(),
|
|
6164
|
-
refreshFormOnChange: z.boolean().optional(),
|
|
6165
|
-
refreshUrl: z.string().optional(),
|
|
6166
|
-
refreshFormUrl: z.string().optional(),
|
|
6167
|
-
promotion: jsonElementSchema.optional(),
|
|
6168
|
-
oneOf: z.array(schemaSchema),
|
|
6169
|
-
placeholder: z.string().optional(),
|
|
6170
|
-
$id: z.string().optional(),
|
|
6171
|
-
title: z.string().optional(),
|
|
6172
|
-
description: z.string().optional(),
|
|
6173
|
-
control: z.string().optional(),
|
|
6174
|
-
default: jsonElementSchema.optional(),
|
|
6175
|
-
hidden: z.boolean().optional(),
|
|
6176
|
-
icon: iconSchema.optional(),
|
|
6177
|
-
image: imageSchema.optional(),
|
|
6178
|
-
keywords: z.array(z.string()).optional(),
|
|
6179
|
-
summary: summaryProviderSchema.optional(),
|
|
6180
|
-
analyticsId: z.string().optional(),
|
|
6181
|
-
refreshStepOnChange: z.boolean().optional(),
|
|
6182
|
-
alert: alertLayoutSchema.optional(),
|
|
6183
|
-
help: helpSchema.optional(),
|
|
6184
|
-
autocompleteHint: z.array(autocompleteTokenSchema).optional(),
|
|
6185
|
-
autofillKey: z.string().optional(),
|
|
6186
|
-
validationMessages: z.record(z.string()).optional(),
|
|
6187
|
-
disabled: z.boolean().optional()
|
|
6188
|
-
})
|
|
6189
|
-
);
|
|
6190
|
-
var stringSchemaSchema = z.lazy(
|
|
6176
|
+
var integerSchemaSchema = z.lazy(
|
|
6191
6177
|
() => z.object({
|
|
6192
|
-
type: z.literal("
|
|
6178
|
+
type: z.literal("integer"),
|
|
6193
6179
|
autofillProvider: z.string().optional(),
|
|
6194
6180
|
promoted: z.boolean().optional(),
|
|
6195
6181
|
refreshFormOnChange: z.boolean().optional(),
|
|
6196
6182
|
refreshUrl: z.string().optional(),
|
|
6197
6183
|
refreshFormUrl: z.string().optional(),
|
|
6198
|
-
format: stringSchemaFormatSchema.optional(),
|
|
6199
|
-
displayFormat: z.string().optional(),
|
|
6200
6184
|
placeholder: z.string().optional(),
|
|
6201
|
-
|
|
6202
|
-
|
|
6203
|
-
minimum: z.string().optional(),
|
|
6204
|
-
maximum: z.string().optional(),
|
|
6205
|
-
pattern: z.string().optional(),
|
|
6206
|
-
autocapitalization: autocapitalizationTypeSchema.optional(),
|
|
6207
|
-
autocorrect: z.boolean().optional(),
|
|
6185
|
+
minimum: z.number().optional(),
|
|
6186
|
+
maximum: z.number().optional(),
|
|
6208
6187
|
$id: z.string().optional(),
|
|
6209
6188
|
title: z.string().optional(),
|
|
6210
6189
|
description: z.string().optional(),
|
|
6211
6190
|
control: z.string().optional(),
|
|
6212
|
-
default: z.
|
|
6191
|
+
default: z.number().optional(),
|
|
6213
6192
|
hidden: z.boolean().optional(),
|
|
6214
6193
|
disabled: z.boolean().optional(),
|
|
6215
6194
|
icon: iconSchema.optional(),
|
|
@@ -6222,15 +6201,14 @@ var stringSchemaSchema = z.lazy(
|
|
|
6222
6201
|
validationAsync: validateAsyncSchema.optional(),
|
|
6223
6202
|
validationMessages: z.record(z.string()).optional(),
|
|
6224
6203
|
alert: alertLayoutSchema.optional(),
|
|
6225
|
-
cameraConfig: jsonElementSchema.optional(),
|
|
6226
|
-
accepts: z.array(z.string()).optional(),
|
|
6227
|
-
maxSize: z.number().optional(),
|
|
6228
|
-
source: uploadSourceSchema.optional(),
|
|
6229
6204
|
autocompleteHint: z.array(autocompleteTokenSchema).optional(),
|
|
6230
6205
|
autofillKey: z.string().optional(),
|
|
6231
6206
|
help: helpSchema.optional()
|
|
6232
6207
|
})
|
|
6233
6208
|
);
|
|
6209
|
+
var arraySchemaSchema = z.lazy(
|
|
6210
|
+
() => z.union([arraySchemaListSchema, arraySchemaTupleSchema])
|
|
6211
|
+
);
|
|
6234
6212
|
var arraySchemaListSchema = z.lazy(
|
|
6235
6213
|
() => z.object({
|
|
6236
6214
|
type: z.literal("array"),
|
|
@@ -6258,32 +6236,71 @@ var arraySchemaListSchema = z.lazy(
|
|
|
6258
6236
|
disabled: z.boolean().optional()
|
|
6259
6237
|
})
|
|
6260
6238
|
);
|
|
6261
|
-
var
|
|
6239
|
+
var allOfSchemaSchema = z.lazy(
|
|
6262
6240
|
() => z.object({
|
|
6263
|
-
|
|
6264
|
-
|
|
6265
|
-
|
|
6266
|
-
|
|
6267
|
-
|
|
6241
|
+
disabled: z.boolean().optional(),
|
|
6242
|
+
promoted: z.boolean().optional(),
|
|
6243
|
+
allOf: z.array(schemaSchema),
|
|
6244
|
+
$id: z.string().optional(),
|
|
6245
|
+
title: z.string().optional(),
|
|
6246
|
+
description: z.string().optional(),
|
|
6247
|
+
control: z.string().optional(),
|
|
6248
|
+
hidden: z.boolean().optional(),
|
|
6249
|
+
icon: iconSchema.optional(),
|
|
6250
|
+
image: imageSchema.optional(),
|
|
6251
|
+
keywords: z.array(z.string()).optional(),
|
|
6252
|
+
summary: summaryProviderSchema.optional(),
|
|
6253
|
+
analyticsId: z.string().optional(),
|
|
6254
|
+
alert: alertLayoutSchema.optional()
|
|
6268
6255
|
})
|
|
6269
6256
|
);
|
|
6270
|
-
var
|
|
6257
|
+
var booleanSchemaSchema = z.lazy(
|
|
6271
6258
|
() => z.object({
|
|
6272
|
-
type: z.literal("
|
|
6259
|
+
type: z.literal("boolean"),
|
|
6260
|
+
autofillProvider: z.string().optional(),
|
|
6273
6261
|
promoted: z.boolean().optional(),
|
|
6262
|
+
refreshFormOnChange: z.boolean().optional(),
|
|
6263
|
+
refreshUrl: z.string().optional(),
|
|
6264
|
+
refreshFormUrl: z.string().optional(),
|
|
6274
6265
|
$id: z.string().optional(),
|
|
6275
|
-
items: z.array(schemaSchema),
|
|
6276
6266
|
title: z.string().optional(),
|
|
6277
6267
|
description: z.string().optional(),
|
|
6278
6268
|
control: z.string().optional(),
|
|
6269
|
+
default: z.boolean().optional(),
|
|
6279
6270
|
hidden: z.boolean().optional(),
|
|
6271
|
+
disabled: z.boolean().optional(),
|
|
6280
6272
|
icon: iconSchema.optional(),
|
|
6281
6273
|
image: imageSchema.optional(),
|
|
6282
6274
|
keywords: z.array(z.string()).optional(),
|
|
6283
6275
|
summary: summaryProviderSchema.optional(),
|
|
6284
6276
|
analyticsId: z.string().optional(),
|
|
6285
6277
|
persistAsync: persistAsyncSchema.optional(),
|
|
6278
|
+
refreshStepOnChange: z.boolean().optional(),
|
|
6286
6279
|
validationAsync: validateAsyncSchema.optional(),
|
|
6280
|
+
alert: alertLayoutSchema.optional(),
|
|
6281
|
+
autofillKey: z.string().optional(),
|
|
6282
|
+
help: helpSchema.optional()
|
|
6283
|
+
})
|
|
6284
|
+
);
|
|
6285
|
+
var objectSchemaSchema = z.lazy(
|
|
6286
|
+
() => z.object({
|
|
6287
|
+
type: z.literal("object"),
|
|
6288
|
+
disabled: z.boolean().optional(),
|
|
6289
|
+
promoted: z.boolean().optional(),
|
|
6290
|
+
help: helpSchema.optional(),
|
|
6291
|
+
properties: z.record(schemaSchema),
|
|
6292
|
+
displayOrder: z.array(z.string()),
|
|
6293
|
+
required: z.array(z.string()).optional(),
|
|
6294
|
+
$id: z.string().optional(),
|
|
6295
|
+
title: z.string().optional(),
|
|
6296
|
+
description: z.string().optional(),
|
|
6297
|
+
control: z.string().optional(),
|
|
6298
|
+
hidden: z.boolean().optional(),
|
|
6299
|
+
icon: iconSchema.optional(),
|
|
6300
|
+
image: imageSchema.optional(),
|
|
6301
|
+
keywords: z.array(z.string()).optional(),
|
|
6302
|
+
summary: summaryProviderSchema.optional(),
|
|
6303
|
+
analyticsId: z.string().optional(),
|
|
6287
6304
|
alert: alertLayoutSchema.optional()
|
|
6288
6305
|
})
|
|
6289
6306
|
);
|
|
@@ -6470,6 +6487,9 @@ var createStepComponent = (stepProps) => {
|
|
|
6470
6487
|
},
|
|
6471
6488
|
stop() {
|
|
6472
6489
|
stepPolling == null ? void 0 : stepPolling.stop();
|
|
6490
|
+
},
|
|
6491
|
+
getRefreshAfter() {
|
|
6492
|
+
return this.step.refreshAfter;
|
|
6473
6493
|
}
|
|
6474
6494
|
});
|
|
6475
6495
|
};
|
|
@@ -10505,7 +10525,8 @@ var mapStepToComponent = (_a) => {
|
|
|
10505
10525
|
step,
|
|
10506
10526
|
updateComponent,
|
|
10507
10527
|
trackEvent,
|
|
10508
|
-
onAction
|
|
10528
|
+
onAction,
|
|
10529
|
+
onRefresh
|
|
10509
10530
|
});
|
|
10510
10531
|
return stepComponent;
|
|
10511
10532
|
};
|
|
@@ -10943,6 +10964,13 @@ function useStableCallback(handler) {
|
|
|
10943
10964
|
return (0, import_react2.useCallback)((...args) => ref.current ? ref.current(...args) : null, []);
|
|
10944
10965
|
}
|
|
10945
10966
|
|
|
10967
|
+
// src/revamp/utils/time-utils.ts
|
|
10968
|
+
var getTimeDiffInMs = (timestamp) => {
|
|
10969
|
+
const targetTime = new Date(timestamp).getTime();
|
|
10970
|
+
const currentTime = Date.now();
|
|
10971
|
+
return targetTime - currentTime;
|
|
10972
|
+
};
|
|
10973
|
+
|
|
10946
10974
|
// src/revamp/useDynamicFlowCore.tsx
|
|
10947
10975
|
function useDynamicFlowCore(props) {
|
|
10948
10976
|
const _a = props, { flowId, initialAction, initialStep, displayStepTitle = true } = _a, rest = __objRest(_a, ["flowId", "initialAction", "initialStep", "displayStepTitle"]);
|
|
@@ -10979,6 +11007,20 @@ function useDynamicFlowCore(props) {
|
|
|
10979
11007
|
trackCoreEvent("Step Shown", { isFirstStep: true });
|
|
10980
11008
|
}
|
|
10981
11009
|
}, []);
|
|
11010
|
+
const refreshAfter = stepComponent == null ? void 0 : stepComponent.getRefreshAfter();
|
|
11011
|
+
console.log({ refreshAfter });
|
|
11012
|
+
(0, import_react3.useEffect)(() => {
|
|
11013
|
+
if (!refreshAfter) return;
|
|
11014
|
+
const timeLeft = getTimeDiffInMs(refreshAfter);
|
|
11015
|
+
if (timeLeft <= 0) {
|
|
11016
|
+
void (stepComponent == null ? void 0 : stepComponent.onRefresh(void 0));
|
|
11017
|
+
return;
|
|
11018
|
+
}
|
|
11019
|
+
const timeout = setTimeout(() => {
|
|
11020
|
+
void (stepComponent == null ? void 0 : stepComponent.onRefresh(void 0));
|
|
11021
|
+
}, timeLeft);
|
|
11022
|
+
return () => clearTimeout(timeout);
|
|
11023
|
+
}, [refreshAfter]);
|
|
10982
11024
|
const createStep = (0, import_react3.useCallback)((newStep, etag) => {
|
|
10983
11025
|
if (stepComponentRef.current) {
|
|
10984
11026
|
stepCount.current += 1;
|