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