@wise/dynamic-flow-client 4.0.0-experimental-af37aae → 4.0.0-experimental-9cbdd3f
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/main.js +608 -595
- package/build/main.mjs +608 -595
- package/build/types/index.d.ts +1 -1
- package/build/types/revamp/domain/components/AllOfComponent.d.ts +2 -10
- package/build/types/revamp/domain/components/ImageComponent.d.ts +1 -3
- package/build/types/revamp/domain/components/RepeatableComponent.d.ts +14 -3
- package/build/types/revamp/domain/components/SelectInputComponent.d.ts +2 -2
- package/build/types/revamp/domain/features/summary/summary-utils.d.ts +3 -23
- package/build/types/revamp/domain/mappers/layout/buttonLayoutToComponent.d.ts +1 -4
- package/build/types/revamp/domain/mappers/layout/decisionLayoutToComponent.d.ts +1 -4
- package/build/types/revamp/domain/mappers/layout/imageLayoutToComponent.d.ts +1 -10
- package/build/types/revamp/domain/mappers/mapStepToComponent.d.ts +2 -2
- package/build/types/revamp/domain/mappers/schema/utils/mapCommonSchemaProps.d.ts +2 -12
- package/build/types/revamp/domain/mappers/utils/image.d.ts +3 -0
- package/build/types/revamp/domain/types.d.ts +1 -15
- package/build/types/revamp/renderers/mappers/allOfComponentToProps.d.ts +1 -1
- package/build/types/revamp/renderers/mappers/utils/inputComponentToProps.d.ts +1 -5
- package/build/types/revamp/renderers/utils.d.ts +1 -5
- package/package.json +4 -4
package/build/main.mjs
CHANGED
|
@@ -5386,10 +5386,50 @@ var z = /* @__PURE__ */ Object.freeze({
|
|
|
5386
5386
|
quotelessJson,
|
|
5387
5387
|
ZodError
|
|
5388
5388
|
});
|
|
5389
|
-
var
|
|
5390
|
-
|
|
5391
|
-
url: z.string()
|
|
5392
|
-
|
|
5389
|
+
var linkBehaviorSchema = z.object({
|
|
5390
|
+
type: z.literal("link"),
|
|
5391
|
+
url: z.string()
|
|
5392
|
+
});
|
|
5393
|
+
var navigationStackBehaviorSchema = z.union([
|
|
5394
|
+
z.literal("default"),
|
|
5395
|
+
z.literal("remove-previous"),
|
|
5396
|
+
z.literal("remove-all"),
|
|
5397
|
+
z.literal("replace-current")
|
|
5398
|
+
]);
|
|
5399
|
+
var jsonElementSchema = z.lazy(
|
|
5400
|
+
() => z.union([
|
|
5401
|
+
z.string(),
|
|
5402
|
+
z.number(),
|
|
5403
|
+
z.boolean(),
|
|
5404
|
+
z.record(jsonElementSchema),
|
|
5405
|
+
z.array(jsonElementSchema)
|
|
5406
|
+
]).nullable()
|
|
5407
|
+
);
|
|
5408
|
+
var helpSchema = z.object({
|
|
5409
|
+
markdown: z.string()
|
|
5410
|
+
});
|
|
5411
|
+
var actionTypeSchema = z.union([
|
|
5412
|
+
z.literal("primary"),
|
|
5413
|
+
z.literal("secondary"),
|
|
5414
|
+
z.literal("link"),
|
|
5415
|
+
z.literal("positive"),
|
|
5416
|
+
z.literal("negative")
|
|
5417
|
+
]);
|
|
5418
|
+
var linkSchema = z.object({
|
|
5419
|
+
url: z.string()
|
|
5420
|
+
});
|
|
5421
|
+
var httpMethodSchema = z.union([
|
|
5422
|
+
z.literal("GET"),
|
|
5423
|
+
z.literal("POST"),
|
|
5424
|
+
z.literal("PUT"),
|
|
5425
|
+
z.literal("PATCH"),
|
|
5426
|
+
z.literal("DELETE")
|
|
5427
|
+
]);
|
|
5428
|
+
var uploadSourceSchema = z.union([z.literal("camera"), z.literal("file")]);
|
|
5429
|
+
var validateAsyncSchema = z.object({
|
|
5430
|
+
param: z.string(),
|
|
5431
|
+
method: httpMethodSchema,
|
|
5432
|
+
url: z.string()
|
|
5393
5433
|
});
|
|
5394
5434
|
var summaryProviderSchema = z.object({
|
|
5395
5435
|
providesTitle: z.boolean().optional(),
|
|
@@ -5397,6 +5437,139 @@ var summaryProviderSchema = z.object({
|
|
|
5397
5437
|
providesIcon: z.boolean().optional(),
|
|
5398
5438
|
providesImage: z.boolean().optional()
|
|
5399
5439
|
});
|
|
5440
|
+
var imageSchema = z.object({
|
|
5441
|
+
text: z.string().optional(),
|
|
5442
|
+
url: z.string().optional(),
|
|
5443
|
+
uri: z.string().optional(),
|
|
5444
|
+
accessibilityDescription: z.string().optional()
|
|
5445
|
+
});
|
|
5446
|
+
var externalSchema = z.object({
|
|
5447
|
+
url: z.string()
|
|
5448
|
+
});
|
|
5449
|
+
var columnsLayoutBiasSchema = z.union([
|
|
5450
|
+
z.literal("none"),
|
|
5451
|
+
z.literal("left"),
|
|
5452
|
+
z.literal("right")
|
|
5453
|
+
]);
|
|
5454
|
+
var sizeSchema = z.union([
|
|
5455
|
+
z.literal("xs"),
|
|
5456
|
+
z.literal("sm"),
|
|
5457
|
+
z.literal("md"),
|
|
5458
|
+
z.literal("lg"),
|
|
5459
|
+
z.literal("xl")
|
|
5460
|
+
]);
|
|
5461
|
+
var dividerLayoutSchema = z.object({
|
|
5462
|
+
type: z.literal("divider"),
|
|
5463
|
+
control: z.string().optional(),
|
|
5464
|
+
margin: sizeSchema.optional()
|
|
5465
|
+
});
|
|
5466
|
+
var statusListLayoutStatusSchema = z.union([
|
|
5467
|
+
z.literal("not-done"),
|
|
5468
|
+
z.literal("pending"),
|
|
5469
|
+
z.literal("done")
|
|
5470
|
+
]);
|
|
5471
|
+
var loadingIndicatorLayoutSchema = z.object({
|
|
5472
|
+
type: z.literal("loading-indicator"),
|
|
5473
|
+
size: sizeSchema.optional(),
|
|
5474
|
+
control: z.string().optional(),
|
|
5475
|
+
margin: sizeSchema.optional()
|
|
5476
|
+
});
|
|
5477
|
+
var contextSchema = z.union([
|
|
5478
|
+
z.literal("positive"),
|
|
5479
|
+
z.literal("neutral"),
|
|
5480
|
+
z.literal("warning"),
|
|
5481
|
+
z.literal("negative"),
|
|
5482
|
+
z.literal("success"),
|
|
5483
|
+
z.literal("failure"),
|
|
5484
|
+
z.literal("info"),
|
|
5485
|
+
z.literal("primary")
|
|
5486
|
+
]);
|
|
5487
|
+
var instructionsLayoutItemSchema = z.object({
|
|
5488
|
+
text: z.string(),
|
|
5489
|
+
context: contextSchema,
|
|
5490
|
+
tag: z.string().optional()
|
|
5491
|
+
});
|
|
5492
|
+
var formLayoutSchemaReferenceSchema = z.object({
|
|
5493
|
+
$ref: z.string()
|
|
5494
|
+
});
|
|
5495
|
+
var modalLayoutTriggerSchema = z.object({
|
|
5496
|
+
title: z.string()
|
|
5497
|
+
});
|
|
5498
|
+
var instructionsLayoutSchema = z.object({
|
|
5499
|
+
type: z.literal("instructions"),
|
|
5500
|
+
title: z.string().optional(),
|
|
5501
|
+
items: z.array(instructionsLayoutItemSchema),
|
|
5502
|
+
control: z.string().optional(),
|
|
5503
|
+
margin: sizeSchema.optional()
|
|
5504
|
+
});
|
|
5505
|
+
var reviewLayoutFieldSchema = z.object({
|
|
5506
|
+
label: z.string(),
|
|
5507
|
+
value: z.string(),
|
|
5508
|
+
rawValue: z.string().optional(),
|
|
5509
|
+
help: helpSchema.optional(),
|
|
5510
|
+
tag: z.string().optional()
|
|
5511
|
+
});
|
|
5512
|
+
var alignSchema = z.union([z.literal("left"), z.literal("center"), z.literal("right")]);
|
|
5513
|
+
var searchLayoutSchema = z.object({
|
|
5514
|
+
type: z.literal("search"),
|
|
5515
|
+
title: z.string(),
|
|
5516
|
+
method: httpMethodSchema,
|
|
5517
|
+
url: z.string(),
|
|
5518
|
+
param: z.string(),
|
|
5519
|
+
emptyMessage: z.string().optional(),
|
|
5520
|
+
control: z.string().optional(),
|
|
5521
|
+
margin: sizeSchema.optional()
|
|
5522
|
+
});
|
|
5523
|
+
var headingLayoutSchema = z.object({
|
|
5524
|
+
type: z.literal("heading"),
|
|
5525
|
+
text: z.string(),
|
|
5526
|
+
size: sizeSchema.optional(),
|
|
5527
|
+
align: alignSchema.optional(),
|
|
5528
|
+
control: z.string().optional(),
|
|
5529
|
+
margin: sizeSchema.optional()
|
|
5530
|
+
});
|
|
5531
|
+
var imageLayoutSchema = z.object({
|
|
5532
|
+
type: z.literal("image"),
|
|
5533
|
+
text: z.string().optional(),
|
|
5534
|
+
url: z.string().optional(),
|
|
5535
|
+
accessibilityDescription: z.string().optional(),
|
|
5536
|
+
content: imageSchema.optional(),
|
|
5537
|
+
size: sizeSchema.optional(),
|
|
5538
|
+
control: z.string().optional(),
|
|
5539
|
+
margin: sizeSchema.optional()
|
|
5540
|
+
});
|
|
5541
|
+
var markdownLayoutSchema = z.object({
|
|
5542
|
+
type: z.literal("markdown"),
|
|
5543
|
+
content: z.string(),
|
|
5544
|
+
align: alignSchema.optional(),
|
|
5545
|
+
control: z.string().optional(),
|
|
5546
|
+
margin: sizeSchema.optional()
|
|
5547
|
+
});
|
|
5548
|
+
var paragraphLayoutSchema = z.object({
|
|
5549
|
+
type: z.literal("paragraph"),
|
|
5550
|
+
text: z.string(),
|
|
5551
|
+
align: alignSchema.optional(),
|
|
5552
|
+
control: z.string().optional(),
|
|
5553
|
+
margin: sizeSchema.optional()
|
|
5554
|
+
});
|
|
5555
|
+
var listLayoutStatusSchema = z.union([
|
|
5556
|
+
z.literal("warning"),
|
|
5557
|
+
z.literal("neutral"),
|
|
5558
|
+
z.literal("positive")
|
|
5559
|
+
]);
|
|
5560
|
+
var errorResponseBodySchema = z.object({
|
|
5561
|
+
refreshFormUrl: z.string().optional(),
|
|
5562
|
+
analytics: z.record(z.string()).optional(),
|
|
5563
|
+
error: z.string().optional(),
|
|
5564
|
+
validation: jsonElementSchema.optional(),
|
|
5565
|
+
refreshUrl: z.string().optional()
|
|
5566
|
+
});
|
|
5567
|
+
var searchSearchRequestSchema = z.object({
|
|
5568
|
+
url: z.string(),
|
|
5569
|
+
method: httpMethodSchema,
|
|
5570
|
+
param: z.string(),
|
|
5571
|
+
query: z.string()
|
|
5572
|
+
});
|
|
5400
5573
|
var autocompleteTokenSchema = z.union([
|
|
5401
5574
|
z.literal("on"),
|
|
5402
5575
|
z.literal("name"),
|
|
@@ -5462,214 +5635,29 @@ var autocompleteTokenSchema = z.union([
|
|
|
5462
5635
|
z.literal("fax"),
|
|
5463
5636
|
z.literal("pager")
|
|
5464
5637
|
]);
|
|
5465
|
-
var helpSchema = z.object({
|
|
5466
|
-
markdown: z.string()
|
|
5467
|
-
});
|
|
5468
|
-
var jsonElementSchema = z.lazy(
|
|
5469
|
-
() => z.union([
|
|
5470
|
-
z.string(),
|
|
5471
|
-
z.number(),
|
|
5472
|
-
z.boolean(),
|
|
5473
|
-
z.record(jsonElementSchema),
|
|
5474
|
-
z.array(jsonElementSchema)
|
|
5475
|
-
]).nullable()
|
|
5476
|
-
);
|
|
5477
|
-
var stringSchemaFormatSchema = z.union([
|
|
5478
|
-
z.literal("date"),
|
|
5479
|
-
z.literal("email"),
|
|
5480
|
-
z.literal("numeric"),
|
|
5481
|
-
z.literal("password"),
|
|
5482
|
-
z.literal("phone-number"),
|
|
5483
|
-
z.literal("base64url")
|
|
5484
|
-
]);
|
|
5485
5638
|
var autocapitalizationTypeSchema = z.union([
|
|
5486
5639
|
z.literal("none"),
|
|
5487
5640
|
z.literal("characters"),
|
|
5488
5641
|
z.literal("sentences"),
|
|
5489
5642
|
z.literal("words")
|
|
5490
5643
|
]);
|
|
5491
|
-
var uploadSourceSchema = z.union([z.literal("camera"), z.literal("file")]);
|
|
5492
|
-
var externalSchema = z.object({
|
|
5493
|
-
url: z.string()
|
|
5494
|
-
});
|
|
5495
|
-
var stepErrorSchema = z.object({
|
|
5496
|
-
error: z.string().optional(),
|
|
5497
|
-
validation: jsonElementSchema.optional()
|
|
5498
|
-
});
|
|
5499
5644
|
var iconNamedSchema = z.object({
|
|
5500
5645
|
name: z.string()
|
|
5501
5646
|
});
|
|
5502
5647
|
var iconTextSchema = z.object({
|
|
5503
5648
|
text: z.string()
|
|
5504
5649
|
});
|
|
5505
|
-
var
|
|
5506
|
-
|
|
5507
|
-
z.literal("
|
|
5508
|
-
z.literal("
|
|
5509
|
-
z.literal("
|
|
5510
|
-
z.literal("
|
|
5511
|
-
z.literal("
|
|
5512
|
-
]);
|
|
5513
|
-
var sizeSchema = z.union([
|
|
5514
|
-
z.literal("xs"),
|
|
5515
|
-
z.literal("sm"),
|
|
5516
|
-
z.literal("md"),
|
|
5517
|
-
z.literal("lg"),
|
|
5518
|
-
z.literal("xl")
|
|
5519
|
-
]);
|
|
5520
|
-
var contextSchema = z.union([
|
|
5521
|
-
z.literal("positive"),
|
|
5522
|
-
z.literal("neutral"),
|
|
5523
|
-
z.literal("warning"),
|
|
5524
|
-
z.literal("negative"),
|
|
5525
|
-
z.literal("success"),
|
|
5526
|
-
z.literal("failure"),
|
|
5527
|
-
z.literal("info"),
|
|
5528
|
-
z.literal("primary")
|
|
5650
|
+
var stringSchemaFormatSchema = z.union([
|
|
5651
|
+
z.literal("date"),
|
|
5652
|
+
z.literal("email"),
|
|
5653
|
+
z.literal("numeric"),
|
|
5654
|
+
z.literal("password"),
|
|
5655
|
+
z.literal("phone-number"),
|
|
5656
|
+
z.literal("base64url")
|
|
5529
5657
|
]);
|
|
5530
|
-
var
|
|
5531
|
-
type: z.literal("image"),
|
|
5532
|
-
text: z.string().optional(),
|
|
5533
|
-
url: z.string(),
|
|
5534
|
-
size: sizeSchema.optional(),
|
|
5535
|
-
accessibilityDescription: z.string().optional(),
|
|
5536
|
-
control: z.string().optional(),
|
|
5537
|
-
margin: sizeSchema.optional()
|
|
5538
|
-
});
|
|
5539
|
-
var searchSearchRequestSchema = z.object({
|
|
5540
|
-
url: z.string(),
|
|
5541
|
-
method: httpMethodSchema,
|
|
5542
|
-
param: z.string(),
|
|
5543
|
-
query: z.string()
|
|
5544
|
-
});
|
|
5545
|
-
var errorResponseBodySchema = z.object({
|
|
5546
|
-
refreshFormUrl: z.string().optional(),
|
|
5547
|
-
analytics: z.record(z.string()).optional(),
|
|
5658
|
+
var stepErrorSchema = z.object({
|
|
5548
5659
|
error: z.string().optional(),
|
|
5549
|
-
validation: jsonElementSchema.optional()
|
|
5550
|
-
refreshUrl: z.string().optional()
|
|
5551
|
-
});
|
|
5552
|
-
var paragraphLayoutSchema = z.object({
|
|
5553
|
-
type: z.literal("paragraph"),
|
|
5554
|
-
text: z.string(),
|
|
5555
|
-
align: alignSchema.optional(),
|
|
5556
|
-
control: z.string().optional(),
|
|
5557
|
-
margin: sizeSchema.optional()
|
|
5558
|
-
});
|
|
5559
|
-
var instructionsLayoutItemSchema = z.object({
|
|
5560
|
-
text: z.string(),
|
|
5561
|
-
context: contextSchema,
|
|
5562
|
-
tag: z.string().optional()
|
|
5563
|
-
});
|
|
5564
|
-
var columnsLayoutBiasSchema = z.union([
|
|
5565
|
-
z.literal("none"),
|
|
5566
|
-
z.literal("left"),
|
|
5567
|
-
z.literal("right")
|
|
5568
|
-
]);
|
|
5569
|
-
var formLayoutSchemaReferenceSchema = z.object({
|
|
5570
|
-
$ref: z.string()
|
|
5571
|
-
});
|
|
5572
|
-
var headingLayoutSchema = z.object({
|
|
5573
|
-
type: z.literal("heading"),
|
|
5574
|
-
text: z.string(),
|
|
5575
|
-
size: sizeSchema.optional(),
|
|
5576
|
-
align: alignSchema.optional(),
|
|
5577
|
-
control: z.string().optional(),
|
|
5578
|
-
margin: sizeSchema.optional()
|
|
5579
|
-
});
|
|
5580
|
-
var dividerLayoutSchema = z.object({
|
|
5581
|
-
type: z.literal("divider"),
|
|
5582
|
-
control: z.string().optional(),
|
|
5583
|
-
margin: sizeSchema.optional()
|
|
5584
|
-
});
|
|
5585
|
-
var infoLayoutSchema = z.object({
|
|
5586
|
-
type: z.literal("info"),
|
|
5587
|
-
markdown: z.string(),
|
|
5588
|
-
align: alignSchema.optional(),
|
|
5589
|
-
control: z.string().optional(),
|
|
5590
|
-
margin: sizeSchema.optional()
|
|
5591
|
-
});
|
|
5592
|
-
var instructionsLayoutSchema = z.object({
|
|
5593
|
-
type: z.literal("instructions"),
|
|
5594
|
-
title: z.string().optional(),
|
|
5595
|
-
items: z.array(instructionsLayoutItemSchema),
|
|
5596
|
-
control: z.string().optional(),
|
|
5597
|
-
margin: sizeSchema.optional()
|
|
5598
|
-
});
|
|
5599
|
-
var loadingIndicatorLayoutSchema = z.object({
|
|
5600
|
-
type: z.literal("loading-indicator"),
|
|
5601
|
-
size: sizeSchema.optional(),
|
|
5602
|
-
control: z.string().optional(),
|
|
5603
|
-
margin: sizeSchema.optional()
|
|
5604
|
-
});
|
|
5605
|
-
var markdownLayoutSchema = z.object({
|
|
5606
|
-
type: z.literal("markdown"),
|
|
5607
|
-
content: z.string(),
|
|
5608
|
-
align: alignSchema.optional(),
|
|
5609
|
-
control: z.string().optional(),
|
|
5610
|
-
margin: sizeSchema.optional()
|
|
5611
|
-
});
|
|
5612
|
-
var searchLayoutSchema = z.object({
|
|
5613
|
-
type: z.literal("search"),
|
|
5614
|
-
title: z.string(),
|
|
5615
|
-
method: httpMethodSchema,
|
|
5616
|
-
url: z.string(),
|
|
5617
|
-
param: z.string(),
|
|
5618
|
-
emptyMessage: z.string().optional(),
|
|
5619
|
-
control: z.string().optional(),
|
|
5620
|
-
margin: sizeSchema.optional()
|
|
5621
|
-
});
|
|
5622
|
-
var modalLayoutTriggerSchema = z.object({
|
|
5623
|
-
title: z.string()
|
|
5624
|
-
});
|
|
5625
|
-
var listLayoutStatusSchema = z.union([
|
|
5626
|
-
z.literal("warning"),
|
|
5627
|
-
z.literal("neutral"),
|
|
5628
|
-
z.literal("positive")
|
|
5629
|
-
]);
|
|
5630
|
-
var reviewLayoutFieldSchema = z.object({
|
|
5631
|
-
label: z.string(),
|
|
5632
|
-
value: z.string(),
|
|
5633
|
-
rawValue: z.string().optional(),
|
|
5634
|
-
help: helpSchema.optional(),
|
|
5635
|
-
tag: z.string().optional()
|
|
5636
|
-
});
|
|
5637
|
-
var statusListLayoutStatusSchema = z.union([
|
|
5638
|
-
z.literal("not-done"),
|
|
5639
|
-
z.literal("pending"),
|
|
5640
|
-
z.literal("done")
|
|
5641
|
-
]);
|
|
5642
|
-
var linkSchema = z.object({
|
|
5643
|
-
url: z.string()
|
|
5644
|
-
});
|
|
5645
|
-
var actionTypeSchema = z.union([
|
|
5646
|
-
z.literal("primary"),
|
|
5647
|
-
z.literal("secondary"),
|
|
5648
|
-
z.literal("link"),
|
|
5649
|
-
z.literal("positive"),
|
|
5650
|
-
z.literal("negative")
|
|
5651
|
-
]);
|
|
5652
|
-
var navigationStackBehaviorSchema = z.union([
|
|
5653
|
-
z.literal("default"),
|
|
5654
|
-
z.literal("remove-previous"),
|
|
5655
|
-
z.literal("remove-all"),
|
|
5656
|
-
z.literal("replace-current")
|
|
5657
|
-
]);
|
|
5658
|
-
var iconSchema = z.union([iconNamedSchema, iconTextSchema]);
|
|
5659
|
-
var validateAsyncSchema = z.object({
|
|
5660
|
-
param: z.string(),
|
|
5661
|
-
method: httpMethodSchema,
|
|
5662
|
-
url: z.string()
|
|
5663
|
-
});
|
|
5664
|
-
var summarySummariserSchema = z.object({
|
|
5665
|
-
defaultTitle: z.string().optional(),
|
|
5666
|
-
defaultDescription: z.string().optional(),
|
|
5667
|
-
defaultIcon: iconSchema.optional(),
|
|
5668
|
-
defaultImage: imageLayoutSchema.optional(),
|
|
5669
|
-
providesTitle: z.boolean().optional(),
|
|
5670
|
-
providesDescription: z.boolean().optional(),
|
|
5671
|
-
providesIcon: z.boolean().optional(),
|
|
5672
|
-
providesImage: z.boolean().optional()
|
|
5660
|
+
validation: jsonElementSchema.optional()
|
|
5673
5661
|
});
|
|
5674
5662
|
var actionSchema = z.object({
|
|
5675
5663
|
title: z.string().optional(),
|
|
@@ -5686,8 +5674,33 @@ var actionSchema = z.object({
|
|
|
5686
5674
|
timeout: z.number().optional(),
|
|
5687
5675
|
skipValidation: z.boolean().optional()
|
|
5688
5676
|
});
|
|
5689
|
-
var
|
|
5690
|
-
|
|
5677
|
+
var iconSchema = z.union([iconNamedSchema, iconTextSchema]);
|
|
5678
|
+
var formLayoutSchema = z.object({
|
|
5679
|
+
type: z.literal("form"),
|
|
5680
|
+
schema: formLayoutSchemaReferenceSchema.optional(),
|
|
5681
|
+
schemaId: z.string(),
|
|
5682
|
+
control: z.string().optional(),
|
|
5683
|
+
margin: sizeSchema.optional()
|
|
5684
|
+
});
|
|
5685
|
+
var infoLayoutSchema = z.object({
|
|
5686
|
+
type: z.literal("info"),
|
|
5687
|
+
markdown: z.string(),
|
|
5688
|
+
align: alignSchema.optional(),
|
|
5689
|
+
control: z.string().optional(),
|
|
5690
|
+
margin: sizeSchema.optional()
|
|
5691
|
+
});
|
|
5692
|
+
var listLayoutItemSchema = z.object({
|
|
5693
|
+
description: z.string().optional(),
|
|
5694
|
+
status: listLayoutStatusSchema.optional(),
|
|
5695
|
+
icon: iconSchema.optional(),
|
|
5696
|
+
image: imageSchema.optional(),
|
|
5697
|
+
title: z.string().optional(),
|
|
5698
|
+
subtitle: z.string().optional(),
|
|
5699
|
+
value: z.string().optional(),
|
|
5700
|
+
subvalue: z.string().optional(),
|
|
5701
|
+
tag: z.string().optional()
|
|
5702
|
+
});
|
|
5703
|
+
var actionResponseBodySchema = z.object({
|
|
5691
5704
|
action: actionSchema
|
|
5692
5705
|
});
|
|
5693
5706
|
var searchResultActionSchema = z.object({
|
|
@@ -5695,7 +5708,7 @@ var searchResultActionSchema = z.object({
|
|
|
5695
5708
|
title: z.string(),
|
|
5696
5709
|
description: z.string().optional(),
|
|
5697
5710
|
icon: iconSchema.optional(),
|
|
5698
|
-
image:
|
|
5711
|
+
image: imageSchema.optional(),
|
|
5699
5712
|
value: actionSchema
|
|
5700
5713
|
});
|
|
5701
5714
|
var searchResultSearchSchema = z.object({
|
|
@@ -5703,112 +5716,109 @@ var searchResultSearchSchema = z.object({
|
|
|
5703
5716
|
title: z.string(),
|
|
5704
5717
|
description: z.string().optional(),
|
|
5705
5718
|
icon: iconSchema.optional(),
|
|
5706
|
-
image:
|
|
5719
|
+
image: imageSchema.optional(),
|
|
5707
5720
|
value: searchSearchRequestSchema
|
|
5708
5721
|
});
|
|
5709
|
-
var
|
|
5722
|
+
var actionBehaviorSchema = z.object({
|
|
5723
|
+
type: z.literal("action"),
|
|
5710
5724
|
action: actionSchema
|
|
5711
5725
|
});
|
|
5712
|
-
var
|
|
5713
|
-
|
|
5726
|
+
var containerBehaviorSchema = z.object({
|
|
5727
|
+
action: actionSchema.optional(),
|
|
5728
|
+
link: linkSchema.optional()
|
|
5729
|
+
});
|
|
5730
|
+
var navigationBackBehaviorSchema = z.object({
|
|
5731
|
+
title: z.string().optional(),
|
|
5714
5732
|
action: actionSchema
|
|
5715
5733
|
});
|
|
5716
|
-
var
|
|
5717
|
-
|
|
5718
|
-
|
|
5719
|
-
|
|
5720
|
-
|
|
5721
|
-
|
|
5734
|
+
var summarySummariserSchema = z.object({
|
|
5735
|
+
defaultTitle: z.string().optional(),
|
|
5736
|
+
defaultDescription: z.string().optional(),
|
|
5737
|
+
defaultIcon: iconSchema.optional(),
|
|
5738
|
+
defaultImage: imageSchema.optional(),
|
|
5739
|
+
providesTitle: z.boolean().optional(),
|
|
5740
|
+
providesDescription: z.boolean().optional(),
|
|
5741
|
+
providesIcon: z.boolean().optional(),
|
|
5742
|
+
providesImage: z.boolean().optional()
|
|
5743
|
+
});
|
|
5744
|
+
var searchResultSchema = z.union([searchResultActionSchema, searchResultSearchSchema]);
|
|
5745
|
+
var searchResponseBodySchema = z.object({
|
|
5746
|
+
results: z.array(searchResultSchema)
|
|
5747
|
+
});
|
|
5748
|
+
var behaviorSchema = z.union([
|
|
5749
|
+
actionBehaviorSchema,
|
|
5750
|
+
containerBehaviorSchema,
|
|
5751
|
+
linkBehaviorSchema
|
|
5752
|
+
]);
|
|
5753
|
+
var navigationSchema = z.object({
|
|
5754
|
+
backButton: navigationBackBehaviorSchema.optional(),
|
|
5755
|
+
back: navigationBackBehaviorSchema.optional(),
|
|
5756
|
+
stackBehavior: navigationStackBehaviorSchema.optional()
|
|
5722
5757
|
});
|
|
5758
|
+
var linkHandlerSchema = z.object({
|
|
5759
|
+
regexPattern: z.string(),
|
|
5760
|
+
behavior: behaviorSchema.optional()
|
|
5761
|
+
});
|
|
5762
|
+
var pollingOnErrorSchema = z.object({
|
|
5763
|
+
action: actionSchema.optional(),
|
|
5764
|
+
behavior: behaviorSchema.optional()
|
|
5765
|
+
});
|
|
5766
|
+
var pollingSchema = z.object({
|
|
5767
|
+
interval: z.number().optional(),
|
|
5768
|
+
url: z.string(),
|
|
5769
|
+
delay: z.number().optional(),
|
|
5770
|
+
timeout: z.number().optional(),
|
|
5771
|
+
maxAttempts: z.number(),
|
|
5772
|
+
onError: pollingOnErrorSchema
|
|
5773
|
+
});
|
|
5774
|
+
var summarySchema = z.union([summaryProviderSchema, summarySummariserSchema]);
|
|
5723
5775
|
var decisionLayoutOptionSchema = z.object({
|
|
5724
|
-
action: actionSchema,
|
|
5776
|
+
action: actionSchema.optional(),
|
|
5725
5777
|
title: z.string(),
|
|
5726
5778
|
description: z.string().optional(),
|
|
5727
5779
|
disabled: z.boolean().optional(),
|
|
5728
5780
|
icon: iconSchema.optional(),
|
|
5729
|
-
image:
|
|
5781
|
+
image: imageSchema.optional(),
|
|
5782
|
+
behavior: behaviorSchema.optional(),
|
|
5730
5783
|
tag: z.string().optional()
|
|
5731
5784
|
});
|
|
5732
|
-
var behaviorSchema = z.object({
|
|
5733
|
-
action: actionSchema.optional(),
|
|
5734
|
-
link: linkSchema.optional()
|
|
5735
|
-
});
|
|
5736
5785
|
var buttonLayoutSchema = z.object({
|
|
5737
5786
|
type: z.literal("button"),
|
|
5787
|
+
action: actionSchema.optional(),
|
|
5738
5788
|
size: sizeSchema.optional(),
|
|
5739
5789
|
title: z.string().optional(),
|
|
5740
|
-
|
|
5790
|
+
behavior: behaviorSchema.optional(),
|
|
5741
5791
|
context: contextSchema.optional(),
|
|
5742
5792
|
disabled: z.boolean().optional(),
|
|
5743
5793
|
pinOrder: z.number().optional(),
|
|
5744
5794
|
control: z.string().optional(),
|
|
5745
5795
|
margin: sizeSchema.optional()
|
|
5746
5796
|
});
|
|
5747
|
-
var
|
|
5748
|
-
|
|
5749
|
-
|
|
5750
|
-
|
|
5751
|
-
|
|
5752
|
-
title: z.string().optional(),
|
|
5753
|
-
callToAction: reviewLayoutCallToActionSchema.optional(),
|
|
5754
|
-
control: z.string().optional(),
|
|
5755
|
-
margin: sizeSchema.optional()
|
|
5756
|
-
});
|
|
5757
|
-
var itemCallToActionSchema = z.object({
|
|
5758
|
-
title: z.string(),
|
|
5759
|
-
accessibilityDescription: z.string().optional(),
|
|
5760
|
-
behavior: behaviorSchema
|
|
5761
|
-
});
|
|
5762
|
-
var listLayoutCallToActionSchema = z.object({
|
|
5763
|
-
title: z.string(),
|
|
5764
|
-
accessibilityDescription: z.string().optional(),
|
|
5765
|
-
behavior: behaviorSchema
|
|
5766
|
-
});
|
|
5767
|
-
var listLayoutItemSchema = z.object({
|
|
5768
|
-
description: z.string().optional(),
|
|
5769
|
-
status: listLayoutStatusSchema.optional(),
|
|
5770
|
-
icon: iconSchema.optional(),
|
|
5771
|
-
image: imageSchema.optional(),
|
|
5772
|
-
title: z.string().optional(),
|
|
5773
|
-
subtitle: z.string().optional(),
|
|
5774
|
-
value: z.string().optional(),
|
|
5775
|
-
subvalue: z.string().optional(),
|
|
5776
|
-
tag: z.string().optional()
|
|
5777
|
-
});
|
|
5778
|
-
var statusListLayoutItemSchema = z.object({
|
|
5779
|
-
title: z.string(),
|
|
5780
|
-
description: z.string().optional(),
|
|
5781
|
-
icon: iconSchema,
|
|
5782
|
-
status: statusListLayoutStatusSchema.optional(),
|
|
5783
|
-
callToAction: itemCallToActionSchema.optional(),
|
|
5784
|
-
tag: z.string().optional()
|
|
5785
|
-
});
|
|
5786
|
-
var pollingOnErrorSchema = z.object({
|
|
5787
|
-
action: actionSchema
|
|
5788
|
-
});
|
|
5789
|
-
var navigationBackBehaviorSchema = z.object({
|
|
5790
|
-
title: z.string().optional(),
|
|
5791
|
-
action: actionSchema
|
|
5797
|
+
var reviewLayoutCallToActionSchema = z.object({
|
|
5798
|
+
action: actionSchema.optional(),
|
|
5799
|
+
title: z.string(),
|
|
5800
|
+
accessibilityDescription: z.string().optional(),
|
|
5801
|
+
behavior: behaviorSchema.optional()
|
|
5792
5802
|
});
|
|
5793
|
-
var
|
|
5794
|
-
|
|
5795
|
-
|
|
5796
|
-
|
|
5797
|
-
delay: z.number().optional(),
|
|
5798
|
-
timeout: z.number().optional(),
|
|
5799
|
-
maxAttempts: z.number(),
|
|
5800
|
-
onError: pollingOnErrorSchema
|
|
5803
|
+
var alertLayoutCallToActionSchema = z.object({
|
|
5804
|
+
title: z.string(),
|
|
5805
|
+
accessibilityDescription: z.string().optional(),
|
|
5806
|
+
behavior: behaviorSchema
|
|
5801
5807
|
});
|
|
5802
|
-
var
|
|
5803
|
-
|
|
5804
|
-
|
|
5805
|
-
|
|
5808
|
+
var itemCallToActionSchema = z.object({
|
|
5809
|
+
title: z.string(),
|
|
5810
|
+
accessibilityDescription: z.string().optional(),
|
|
5811
|
+
behavior: behaviorSchema
|
|
5806
5812
|
});
|
|
5807
|
-
var
|
|
5808
|
-
|
|
5809
|
-
|
|
5813
|
+
var alertLayoutSchema = z.object({
|
|
5814
|
+
type: z.literal("alert"),
|
|
5815
|
+
markdown: z.string(),
|
|
5816
|
+
context: contextSchema.optional(),
|
|
5817
|
+
control: z.string().optional(),
|
|
5818
|
+
margin: sizeSchema.optional(),
|
|
5819
|
+
callToAction: alertLayoutCallToActionSchema.optional()
|
|
5810
5820
|
});
|
|
5811
|
-
var
|
|
5821
|
+
var listLayoutCallToActionSchema = z.object({
|
|
5812
5822
|
title: z.string(),
|
|
5813
5823
|
accessibilityDescription: z.string().optional(),
|
|
5814
5824
|
behavior: behaviorSchema
|
|
@@ -5828,21 +5838,6 @@ var listLayoutSchema = z.object({
|
|
|
5828
5838
|
control: z.string().optional(),
|
|
5829
5839
|
margin: sizeSchema.optional()
|
|
5830
5840
|
});
|
|
5831
|
-
var statusListLayoutSchema = z.object({
|
|
5832
|
-
type: z.literal("status-list"),
|
|
5833
|
-
items: z.array(statusListLayoutItemSchema),
|
|
5834
|
-
title: z.string().optional(),
|
|
5835
|
-
control: z.string().optional(),
|
|
5836
|
-
margin: sizeSchema.optional()
|
|
5837
|
-
});
|
|
5838
|
-
var alertLayoutSchema = z.object({
|
|
5839
|
-
type: z.literal("alert"),
|
|
5840
|
-
markdown: z.string(),
|
|
5841
|
-
context: contextSchema.optional(),
|
|
5842
|
-
control: z.string().optional(),
|
|
5843
|
-
margin: sizeSchema.optional(),
|
|
5844
|
-
callToAction: alertLayoutCallToActionSchema.optional()
|
|
5845
|
-
});
|
|
5846
5841
|
var constSchemaSchema = z.object({
|
|
5847
5842
|
hidden: z.boolean().optional(),
|
|
5848
5843
|
alert: alertLayoutSchema.optional(),
|
|
@@ -5881,22 +5876,157 @@ var blobSchemaSchema = z.object({
|
|
|
5881
5876
|
source: uploadSourceSchema.optional(),
|
|
5882
5877
|
disabled: z.boolean().optional()
|
|
5883
5878
|
});
|
|
5884
|
-
var
|
|
5879
|
+
var reviewLayoutSchema = z.object({
|
|
5880
|
+
type: z.literal("review"),
|
|
5881
|
+
orientation: z.string().optional(),
|
|
5882
|
+
action: actionSchema.optional(),
|
|
5883
|
+
fields: z.array(reviewLayoutFieldSchema),
|
|
5884
|
+
title: z.string().optional(),
|
|
5885
|
+
callToAction: reviewLayoutCallToActionSchema.optional(),
|
|
5886
|
+
control: z.string().optional(),
|
|
5887
|
+
margin: sizeSchema.optional()
|
|
5888
|
+
});
|
|
5889
|
+
var statusListLayoutItemSchema = z.object({
|
|
5890
|
+
title: z.string(),
|
|
5891
|
+
description: z.string().optional(),
|
|
5892
|
+
icon: iconSchema,
|
|
5893
|
+
status: statusListLayoutStatusSchema.optional(),
|
|
5894
|
+
callToAction: itemCallToActionSchema.optional(),
|
|
5895
|
+
tag: z.string().optional()
|
|
5896
|
+
});
|
|
5897
|
+
var statusListLayoutSchema = z.object({
|
|
5898
|
+
type: z.literal("status-list"),
|
|
5899
|
+
items: z.array(statusListLayoutItemSchema),
|
|
5900
|
+
title: z.string().optional(),
|
|
5901
|
+
control: z.string().optional(),
|
|
5902
|
+
margin: sizeSchema.optional()
|
|
5903
|
+
});
|
|
5904
|
+
var persistAsyncSchema = z.lazy(
|
|
5885
5905
|
() => z.object({
|
|
5886
|
-
|
|
5906
|
+
param: z.string(),
|
|
5907
|
+
idProperty: z.string(),
|
|
5908
|
+
schema: schemaSchema,
|
|
5909
|
+
url: z.string(),
|
|
5910
|
+
method: httpMethodSchema
|
|
5911
|
+
})
|
|
5912
|
+
);
|
|
5913
|
+
var schemaSchema = z.lazy(
|
|
5914
|
+
() => z.union([
|
|
5915
|
+
allOfSchemaSchema,
|
|
5916
|
+
arraySchemaSchema,
|
|
5917
|
+
blobSchemaSchema,
|
|
5918
|
+
booleanSchemaSchema,
|
|
5919
|
+
constSchemaSchema,
|
|
5920
|
+
integerSchemaSchema,
|
|
5921
|
+
numberSchemaSchema,
|
|
5922
|
+
objectSchemaSchema,
|
|
5923
|
+
oneOfSchemaSchema,
|
|
5924
|
+
stringSchemaSchema
|
|
5925
|
+
])
|
|
5926
|
+
);
|
|
5927
|
+
var columnsLayoutSchema = z.lazy(
|
|
5928
|
+
() => z.object({
|
|
5929
|
+
type: z.literal("columns"),
|
|
5930
|
+
left: z.array(layoutSchema),
|
|
5931
|
+
right: z.array(layoutSchema),
|
|
5932
|
+
bias: columnsLayoutBiasSchema.optional(),
|
|
5933
|
+
control: z.string().optional(),
|
|
5934
|
+
margin: sizeSchema.optional()
|
|
5935
|
+
})
|
|
5936
|
+
);
|
|
5937
|
+
var layoutSchema = z.lazy(
|
|
5938
|
+
() => z.union([
|
|
5939
|
+
alertLayoutSchema,
|
|
5940
|
+
boxLayoutSchema,
|
|
5941
|
+
buttonLayoutSchema,
|
|
5942
|
+
columnsLayoutSchema,
|
|
5943
|
+
decisionLayoutSchema,
|
|
5944
|
+
dividerLayoutSchema,
|
|
5945
|
+
formLayoutSchema,
|
|
5946
|
+
headingLayoutSchema,
|
|
5947
|
+
imageLayoutSchema,
|
|
5948
|
+
infoLayoutSchema,
|
|
5949
|
+
instructionsLayoutSchema,
|
|
5950
|
+
listLayoutSchema,
|
|
5951
|
+
loadingIndicatorLayoutSchema,
|
|
5952
|
+
markdownLayoutSchema,
|
|
5953
|
+
modalLayoutSchema,
|
|
5954
|
+
paragraphLayoutSchema,
|
|
5955
|
+
reviewLayoutSchema,
|
|
5956
|
+
searchLayoutSchema,
|
|
5957
|
+
statusListLayoutSchema
|
|
5958
|
+
])
|
|
5959
|
+
);
|
|
5960
|
+
var modalLayoutContentSchema = z.lazy(
|
|
5961
|
+
() => z.object({
|
|
5962
|
+
title: z.string().optional(),
|
|
5963
|
+
components: z.array(layoutSchema)
|
|
5964
|
+
})
|
|
5965
|
+
);
|
|
5966
|
+
var boxLayoutSchema = z.lazy(
|
|
5967
|
+
() => z.object({
|
|
5968
|
+
type: z.literal("box"),
|
|
5969
|
+
components: z.array(layoutSchema),
|
|
5970
|
+
width: sizeSchema.optional(),
|
|
5971
|
+
border: z.boolean().optional(),
|
|
5972
|
+
control: z.string().optional(),
|
|
5973
|
+
margin: sizeSchema.optional()
|
|
5974
|
+
})
|
|
5975
|
+
);
|
|
5976
|
+
var modalLayoutSchema = z.lazy(
|
|
5977
|
+
() => z.object({
|
|
5978
|
+
type: z.literal("modal"),
|
|
5979
|
+
control: z.string().optional(),
|
|
5980
|
+
margin: sizeSchema.optional(),
|
|
5981
|
+
trigger: modalLayoutTriggerSchema,
|
|
5982
|
+
content: modalLayoutContentSchema
|
|
5983
|
+
})
|
|
5984
|
+
);
|
|
5985
|
+
var stepSchema = z.lazy(
|
|
5986
|
+
() => z.object({
|
|
5987
|
+
key: z.string().optional(),
|
|
5988
|
+
type: z.string().optional(),
|
|
5989
|
+
actions: z.array(actionSchema).optional(),
|
|
5990
|
+
refreshFormUrl: z.string().optional(),
|
|
5991
|
+
id: z.string(),
|
|
5992
|
+
title: z.string(),
|
|
5993
|
+
schemas: z.array(schemaSchema),
|
|
5994
|
+
layout: z.array(layoutSchema),
|
|
5995
|
+
description: z.string().optional(),
|
|
5996
|
+
model: jsonElementSchema.optional(),
|
|
5997
|
+
external: externalSchema.optional(),
|
|
5998
|
+
polling: pollingSchema.optional(),
|
|
5999
|
+
linkHandlers: z.array(linkHandlerSchema).optional(),
|
|
6000
|
+
analytics: z.record(z.string()).optional(),
|
|
6001
|
+
errors: stepErrorSchema.optional(),
|
|
6002
|
+
navigation: navigationSchema.optional(),
|
|
6003
|
+
refreshUrl: z.string().optional(),
|
|
6004
|
+
control: z.string().optional()
|
|
6005
|
+
})
|
|
6006
|
+
);
|
|
6007
|
+
var stringSchemaSchema = z.lazy(
|
|
6008
|
+
() => z.object({
|
|
6009
|
+
type: z.literal("string"),
|
|
5887
6010
|
autofillProvider: z.string().optional(),
|
|
5888
6011
|
promoted: z.boolean().optional(),
|
|
5889
6012
|
refreshFormOnChange: z.boolean().optional(),
|
|
5890
6013
|
refreshUrl: z.string().optional(),
|
|
5891
6014
|
refreshFormUrl: z.string().optional(),
|
|
6015
|
+
format: stringSchemaFormatSchema.optional(),
|
|
6016
|
+
displayFormat: z.string().optional(),
|
|
5892
6017
|
placeholder: z.string().optional(),
|
|
5893
|
-
|
|
5894
|
-
|
|
6018
|
+
minLength: z.number().optional(),
|
|
6019
|
+
maxLength: z.number().optional(),
|
|
6020
|
+
minimum: z.string().optional(),
|
|
6021
|
+
maximum: z.string().optional(),
|
|
6022
|
+
pattern: z.string().optional(),
|
|
6023
|
+
autocapitalization: autocapitalizationTypeSchema.optional(),
|
|
6024
|
+
autocorrect: z.boolean().optional(),
|
|
5895
6025
|
$id: z.string().optional(),
|
|
5896
6026
|
title: z.string().optional(),
|
|
5897
6027
|
description: z.string().optional(),
|
|
5898
6028
|
control: z.string().optional(),
|
|
5899
|
-
default: z.
|
|
6029
|
+
default: z.string().optional(),
|
|
5900
6030
|
hidden: z.boolean().optional(),
|
|
5901
6031
|
disabled: z.boolean().optional(),
|
|
5902
6032
|
icon: iconSchema.optional(),
|
|
@@ -5909,67 +6039,61 @@ var numberSchemaSchema = z.lazy(
|
|
|
5909
6039
|
validationAsync: validateAsyncSchema.optional(),
|
|
5910
6040
|
validationMessages: z.record(z.string()).optional(),
|
|
5911
6041
|
alert: alertLayoutSchema.optional(),
|
|
6042
|
+
cameraConfig: jsonElementSchema.optional(),
|
|
6043
|
+
accepts: z.array(z.string()).optional(),
|
|
6044
|
+
maxSize: z.number().optional(),
|
|
6045
|
+
source: uploadSourceSchema.optional(),
|
|
5912
6046
|
autocompleteHint: z.array(autocompleteTokenSchema).optional(),
|
|
5913
6047
|
autofillKey: z.string().optional(),
|
|
5914
6048
|
help: helpSchema.optional()
|
|
5915
6049
|
})
|
|
5916
6050
|
);
|
|
5917
|
-
var
|
|
5918
|
-
() => z.object({
|
|
5919
|
-
param: z.string(),
|
|
5920
|
-
idProperty: z.string(),
|
|
5921
|
-
schema: schemaSchema,
|
|
5922
|
-
url: z.string(),
|
|
5923
|
-
method: httpMethodSchema
|
|
5924
|
-
})
|
|
5925
|
-
);
|
|
5926
|
-
var arraySchemaTupleSchema = z.lazy(
|
|
6051
|
+
var oneOfSchemaSchema = z.lazy(
|
|
5927
6052
|
() => z.object({
|
|
5928
|
-
|
|
6053
|
+
autofillProvider: z.string().optional(),
|
|
5929
6054
|
promoted: z.boolean().optional(),
|
|
6055
|
+
refreshFormOnChange: z.boolean().optional(),
|
|
6056
|
+
refreshUrl: z.string().optional(),
|
|
6057
|
+
refreshFormUrl: z.string().optional(),
|
|
6058
|
+
promotion: jsonElementSchema.optional(),
|
|
6059
|
+
oneOf: z.array(schemaSchema),
|
|
6060
|
+
placeholder: z.string().optional(),
|
|
5930
6061
|
$id: z.string().optional(),
|
|
5931
|
-
items: z.array(schemaSchema),
|
|
5932
6062
|
title: z.string().optional(),
|
|
5933
6063
|
description: z.string().optional(),
|
|
5934
6064
|
control: z.string().optional(),
|
|
6065
|
+
default: jsonElementSchema.optional(),
|
|
5935
6066
|
hidden: z.boolean().optional(),
|
|
5936
6067
|
icon: iconSchema.optional(),
|
|
5937
6068
|
image: imageSchema.optional(),
|
|
5938
6069
|
keywords: z.array(z.string()).optional(),
|
|
5939
6070
|
summary: summaryProviderSchema.optional(),
|
|
5940
6071
|
analyticsId: z.string().optional(),
|
|
5941
|
-
|
|
5942
|
-
|
|
5943
|
-
|
|
6072
|
+
refreshStepOnChange: z.boolean().optional(),
|
|
6073
|
+
alert: alertLayoutSchema.optional(),
|
|
6074
|
+
help: helpSchema.optional(),
|
|
6075
|
+
autocompleteHint: z.array(autocompleteTokenSchema).optional(),
|
|
6076
|
+
autofillKey: z.string().optional(),
|
|
6077
|
+
validationMessages: z.record(z.string()).optional(),
|
|
6078
|
+
disabled: z.boolean().optional()
|
|
5944
6079
|
})
|
|
5945
6080
|
);
|
|
5946
|
-
var
|
|
5947
|
-
() => z.union([
|
|
5948
|
-
allOfSchemaSchema,
|
|
5949
|
-
arraySchemaSchema,
|
|
5950
|
-
blobSchemaSchema,
|
|
5951
|
-
booleanSchemaSchema,
|
|
5952
|
-
constSchemaSchema,
|
|
5953
|
-
integerSchemaSchema,
|
|
5954
|
-
numberSchemaSchema,
|
|
5955
|
-
objectSchemaSchema,
|
|
5956
|
-
oneOfSchemaSchema,
|
|
5957
|
-
stringSchemaSchema
|
|
5958
|
-
])
|
|
5959
|
-
);
|
|
5960
|
-
var booleanSchemaSchema = z.lazy(
|
|
6081
|
+
var numberSchemaSchema = z.lazy(
|
|
5961
6082
|
() => z.object({
|
|
5962
|
-
type: z.literal("
|
|
6083
|
+
type: z.literal("number"),
|
|
5963
6084
|
autofillProvider: z.string().optional(),
|
|
5964
6085
|
promoted: z.boolean().optional(),
|
|
5965
6086
|
refreshFormOnChange: z.boolean().optional(),
|
|
5966
6087
|
refreshUrl: z.string().optional(),
|
|
5967
6088
|
refreshFormUrl: z.string().optional(),
|
|
6089
|
+
placeholder: z.string().optional(),
|
|
6090
|
+
minimum: z.number().optional(),
|
|
6091
|
+
maximum: z.number().optional(),
|
|
5968
6092
|
$id: z.string().optional(),
|
|
5969
6093
|
title: z.string().optional(),
|
|
5970
6094
|
description: z.string().optional(),
|
|
5971
6095
|
control: z.string().optional(),
|
|
5972
|
-
default: z.
|
|
6096
|
+
default: z.number().optional(),
|
|
5973
6097
|
hidden: z.boolean().optional(),
|
|
5974
6098
|
disabled: z.boolean().optional(),
|
|
5975
6099
|
icon: iconSchema.optional(),
|
|
@@ -5980,17 +6104,19 @@ var booleanSchemaSchema = z.lazy(
|
|
|
5980
6104
|
persistAsync: persistAsyncSchema.optional(),
|
|
5981
6105
|
refreshStepOnChange: z.boolean().optional(),
|
|
5982
6106
|
validationAsync: validateAsyncSchema.optional(),
|
|
6107
|
+
validationMessages: z.record(z.string()).optional(),
|
|
5983
6108
|
alert: alertLayoutSchema.optional(),
|
|
6109
|
+
autocompleteHint: z.array(autocompleteTokenSchema).optional(),
|
|
5984
6110
|
autofillKey: z.string().optional(),
|
|
5985
6111
|
help: helpSchema.optional()
|
|
5986
6112
|
})
|
|
5987
6113
|
);
|
|
5988
|
-
var
|
|
6114
|
+
var arraySchemaTupleSchema = z.lazy(
|
|
5989
6115
|
() => z.object({
|
|
5990
|
-
|
|
6116
|
+
type: z.literal("array"),
|
|
5991
6117
|
promoted: z.boolean().optional(),
|
|
5992
|
-
allOf: z.array(schemaSchema),
|
|
5993
6118
|
$id: z.string().optional(),
|
|
6119
|
+
items: z.array(schemaSchema),
|
|
5994
6120
|
title: z.string().optional(),
|
|
5995
6121
|
description: z.string().optional(),
|
|
5996
6122
|
control: z.string().optional(),
|
|
@@ -6000,12 +6126,11 @@ var allOfSchemaSchema = z.lazy(
|
|
|
6000
6126
|
keywords: z.array(z.string()).optional(),
|
|
6001
6127
|
summary: summaryProviderSchema.optional(),
|
|
6002
6128
|
analyticsId: z.string().optional(),
|
|
6129
|
+
persistAsync: persistAsyncSchema.optional(),
|
|
6130
|
+
validationAsync: validateAsyncSchema.optional(),
|
|
6003
6131
|
alert: alertLayoutSchema.optional()
|
|
6004
6132
|
})
|
|
6005
6133
|
);
|
|
6006
|
-
var arraySchemaSchema = z.lazy(
|
|
6007
|
-
() => z.union([arraySchemaListSchema, arraySchemaTupleSchema])
|
|
6008
|
-
);
|
|
6009
6134
|
var integerSchemaSchema = z.lazy(
|
|
6010
6135
|
() => z.object({
|
|
6011
6136
|
type: z.literal("integer"),
|
|
@@ -6039,16 +6164,20 @@ var integerSchemaSchema = z.lazy(
|
|
|
6039
6164
|
help: helpSchema.optional()
|
|
6040
6165
|
})
|
|
6041
6166
|
);
|
|
6042
|
-
var
|
|
6167
|
+
var arraySchemaSchema = z.lazy(
|
|
6168
|
+
() => z.union([arraySchemaListSchema, arraySchemaTupleSchema])
|
|
6169
|
+
);
|
|
6170
|
+
var arraySchemaListSchema = z.lazy(
|
|
6043
6171
|
() => z.object({
|
|
6044
|
-
type: z.literal("
|
|
6045
|
-
disabled: z.boolean().optional(),
|
|
6172
|
+
type: z.literal("array"),
|
|
6046
6173
|
promoted: z.boolean().optional(),
|
|
6047
|
-
help: helpSchema.optional(),
|
|
6048
|
-
properties: z.record(schemaSchema),
|
|
6049
|
-
displayOrder: z.array(z.string()),
|
|
6050
|
-
required: z.array(z.string()).optional(),
|
|
6051
6174
|
$id: z.string().optional(),
|
|
6175
|
+
items: schemaSchema,
|
|
6176
|
+
addItemTitle: z.string(),
|
|
6177
|
+
editItemTitle: z.string(),
|
|
6178
|
+
minItems: z.number().optional(),
|
|
6179
|
+
maxItems: z.number().optional(),
|
|
6180
|
+
placeholder: z.string().optional(),
|
|
6052
6181
|
title: z.string().optional(),
|
|
6053
6182
|
description: z.string().optional(),
|
|
6054
6183
|
control: z.string().optional(),
|
|
@@ -6056,64 +6185,46 @@ var objectSchemaSchema = z.lazy(
|
|
|
6056
6185
|
icon: iconSchema.optional(),
|
|
6057
6186
|
image: imageSchema.optional(),
|
|
6058
6187
|
keywords: z.array(z.string()).optional(),
|
|
6059
|
-
summary:
|
|
6188
|
+
summary: summarySummariserSchema.optional(),
|
|
6060
6189
|
analyticsId: z.string().optional(),
|
|
6061
|
-
|
|
6190
|
+
persistAsync: persistAsyncSchema.optional(),
|
|
6191
|
+
validationAsync: validateAsyncSchema.optional(),
|
|
6192
|
+
alert: alertLayoutSchema.optional(),
|
|
6193
|
+
validationMessages: z.record(z.string()).optional(),
|
|
6194
|
+
disabled: z.boolean().optional()
|
|
6062
6195
|
})
|
|
6063
6196
|
);
|
|
6064
|
-
var
|
|
6197
|
+
var allOfSchemaSchema = z.lazy(
|
|
6065
6198
|
() => z.object({
|
|
6066
|
-
|
|
6199
|
+
disabled: z.boolean().optional(),
|
|
6067
6200
|
promoted: z.boolean().optional(),
|
|
6068
|
-
|
|
6069
|
-
refreshUrl: z.string().optional(),
|
|
6070
|
-
refreshFormUrl: z.string().optional(),
|
|
6071
|
-
promotion: jsonElementSchema.optional(),
|
|
6072
|
-
oneOf: z.array(schemaSchema),
|
|
6073
|
-
placeholder: z.string().optional(),
|
|
6201
|
+
allOf: z.array(schemaSchema),
|
|
6074
6202
|
$id: z.string().optional(),
|
|
6075
6203
|
title: z.string().optional(),
|
|
6076
6204
|
description: z.string().optional(),
|
|
6077
6205
|
control: z.string().optional(),
|
|
6078
|
-
default: jsonElementSchema.optional(),
|
|
6079
6206
|
hidden: z.boolean().optional(),
|
|
6080
6207
|
icon: iconSchema.optional(),
|
|
6081
6208
|
image: imageSchema.optional(),
|
|
6082
6209
|
keywords: z.array(z.string()).optional(),
|
|
6083
6210
|
summary: summaryProviderSchema.optional(),
|
|
6084
6211
|
analyticsId: z.string().optional(),
|
|
6085
|
-
|
|
6086
|
-
alert: alertLayoutSchema.optional(),
|
|
6087
|
-
help: helpSchema.optional(),
|
|
6088
|
-
autocompleteHint: z.array(autocompleteTokenSchema).optional(),
|
|
6089
|
-
autofillKey: z.string().optional(),
|
|
6090
|
-
validationMessages: z.record(z.string()).optional(),
|
|
6091
|
-
disabled: z.boolean().optional()
|
|
6212
|
+
alert: alertLayoutSchema.optional()
|
|
6092
6213
|
})
|
|
6093
6214
|
);
|
|
6094
|
-
var
|
|
6215
|
+
var booleanSchemaSchema = z.lazy(
|
|
6095
6216
|
() => z.object({
|
|
6096
|
-
type: z.literal("
|
|
6217
|
+
type: z.literal("boolean"),
|
|
6097
6218
|
autofillProvider: z.string().optional(),
|
|
6098
6219
|
promoted: z.boolean().optional(),
|
|
6099
6220
|
refreshFormOnChange: z.boolean().optional(),
|
|
6100
6221
|
refreshUrl: z.string().optional(),
|
|
6101
6222
|
refreshFormUrl: z.string().optional(),
|
|
6102
|
-
format: stringSchemaFormatSchema.optional(),
|
|
6103
|
-
displayFormat: z.string().optional(),
|
|
6104
|
-
placeholder: z.string().optional(),
|
|
6105
|
-
minLength: z.number().optional(),
|
|
6106
|
-
maxLength: z.number().optional(),
|
|
6107
|
-
minimum: z.string().optional(),
|
|
6108
|
-
maximum: z.string().optional(),
|
|
6109
|
-
pattern: z.string().optional(),
|
|
6110
|
-
autocapitalization: autocapitalizationTypeSchema.optional(),
|
|
6111
|
-
autocorrect: z.boolean().optional(),
|
|
6112
6223
|
$id: z.string().optional(),
|
|
6113
6224
|
title: z.string().optional(),
|
|
6114
6225
|
description: z.string().optional(),
|
|
6115
6226
|
control: z.string().optional(),
|
|
6116
|
-
default: z.
|
|
6227
|
+
default: z.boolean().optional(),
|
|
6117
6228
|
hidden: z.boolean().optional(),
|
|
6118
6229
|
disabled: z.boolean().optional(),
|
|
6119
6230
|
icon: iconSchema.optional(),
|
|
@@ -6124,28 +6235,21 @@ var stringSchemaSchema = z.lazy(
|
|
|
6124
6235
|
persistAsync: persistAsyncSchema.optional(),
|
|
6125
6236
|
refreshStepOnChange: z.boolean().optional(),
|
|
6126
6237
|
validationAsync: validateAsyncSchema.optional(),
|
|
6127
|
-
validationMessages: z.record(z.string()).optional(),
|
|
6128
6238
|
alert: alertLayoutSchema.optional(),
|
|
6129
|
-
cameraConfig: jsonElementSchema.optional(),
|
|
6130
|
-
accepts: z.array(z.string()).optional(),
|
|
6131
|
-
maxSize: z.number().optional(),
|
|
6132
|
-
source: uploadSourceSchema.optional(),
|
|
6133
|
-
autocompleteHint: z.array(autocompleteTokenSchema).optional(),
|
|
6134
6239
|
autofillKey: z.string().optional(),
|
|
6135
6240
|
help: helpSchema.optional()
|
|
6136
6241
|
})
|
|
6137
6242
|
);
|
|
6138
|
-
var
|
|
6243
|
+
var objectSchemaSchema = z.lazy(
|
|
6139
6244
|
() => z.object({
|
|
6140
|
-
type: z.literal("
|
|
6245
|
+
type: z.literal("object"),
|
|
6246
|
+
disabled: z.boolean().optional(),
|
|
6141
6247
|
promoted: z.boolean().optional(),
|
|
6248
|
+
help: helpSchema.optional(),
|
|
6249
|
+
properties: z.record(schemaSchema),
|
|
6250
|
+
displayOrder: z.array(z.string()),
|
|
6251
|
+
required: z.array(z.string()).optional(),
|
|
6142
6252
|
$id: z.string().optional(),
|
|
6143
|
-
items: schemaSchema,
|
|
6144
|
-
addItemTitle: z.string(),
|
|
6145
|
-
editItemTitle: z.string(),
|
|
6146
|
-
minItems: z.number().optional(),
|
|
6147
|
-
maxItems: z.number().optional(),
|
|
6148
|
-
placeholder: z.string().optional(),
|
|
6149
6253
|
title: z.string().optional(),
|
|
6150
6254
|
description: z.string().optional(),
|
|
6151
6255
|
control: z.string().optional(),
|
|
@@ -6153,93 +6257,9 @@ var arraySchemaListSchema = z.lazy(
|
|
|
6153
6257
|
icon: iconSchema.optional(),
|
|
6154
6258
|
image: imageSchema.optional(),
|
|
6155
6259
|
keywords: z.array(z.string()).optional(),
|
|
6156
|
-
summary:
|
|
6260
|
+
summary: summaryProviderSchema.optional(),
|
|
6157
6261
|
analyticsId: z.string().optional(),
|
|
6158
|
-
|
|
6159
|
-
validationAsync: validateAsyncSchema.optional(),
|
|
6160
|
-
alert: alertLayoutSchema.optional(),
|
|
6161
|
-
validationMessages: z.record(z.string()).optional(),
|
|
6162
|
-
disabled: z.boolean().optional()
|
|
6163
|
-
})
|
|
6164
|
-
);
|
|
6165
|
-
var stepSchema = z.lazy(
|
|
6166
|
-
() => z.object({
|
|
6167
|
-
key: z.string().optional(),
|
|
6168
|
-
type: z.string().optional(),
|
|
6169
|
-
actions: z.array(actionSchema).optional(),
|
|
6170
|
-
refreshFormUrl: z.string().optional(),
|
|
6171
|
-
id: z.string(),
|
|
6172
|
-
title: z.string(),
|
|
6173
|
-
schemas: z.array(schemaSchema),
|
|
6174
|
-
layout: z.array(layoutSchema),
|
|
6175
|
-
description: z.string().optional(),
|
|
6176
|
-
model: jsonElementSchema.optional(),
|
|
6177
|
-
external: externalSchema.optional(),
|
|
6178
|
-
polling: pollingSchema.optional(),
|
|
6179
|
-
linkHandlers: z.array(linkHandlerSchema).optional(),
|
|
6180
|
-
analytics: z.record(z.string()).optional(),
|
|
6181
|
-
errors: stepErrorSchema.optional(),
|
|
6182
|
-
navigation: navigationSchema.optional(),
|
|
6183
|
-
refreshUrl: z.string().optional(),
|
|
6184
|
-
control: z.string().optional()
|
|
6185
|
-
})
|
|
6186
|
-
);
|
|
6187
|
-
var layoutSchema = z.lazy(
|
|
6188
|
-
() => z.union([
|
|
6189
|
-
alertLayoutSchema,
|
|
6190
|
-
boxLayoutSchema,
|
|
6191
|
-
buttonLayoutSchema,
|
|
6192
|
-
columnsLayoutSchema,
|
|
6193
|
-
decisionLayoutSchema,
|
|
6194
|
-
dividerLayoutSchema,
|
|
6195
|
-
formLayoutSchema,
|
|
6196
|
-
headingLayoutSchema,
|
|
6197
|
-
imageLayoutSchema,
|
|
6198
|
-
infoLayoutSchema,
|
|
6199
|
-
instructionsLayoutSchema,
|
|
6200
|
-
listLayoutSchema,
|
|
6201
|
-
loadingIndicatorLayoutSchema,
|
|
6202
|
-
markdownLayoutSchema,
|
|
6203
|
-
modalLayoutSchema,
|
|
6204
|
-
paragraphLayoutSchema,
|
|
6205
|
-
reviewLayoutSchema,
|
|
6206
|
-
searchLayoutSchema,
|
|
6207
|
-
statusListLayoutSchema
|
|
6208
|
-
])
|
|
6209
|
-
);
|
|
6210
|
-
var columnsLayoutSchema = z.lazy(
|
|
6211
|
-
() => z.object({
|
|
6212
|
-
type: z.literal("columns"),
|
|
6213
|
-
left: z.array(layoutSchema),
|
|
6214
|
-
right: z.array(layoutSchema),
|
|
6215
|
-
bias: columnsLayoutBiasSchema.optional(),
|
|
6216
|
-
control: z.string().optional(),
|
|
6217
|
-
margin: sizeSchema.optional()
|
|
6218
|
-
})
|
|
6219
|
-
);
|
|
6220
|
-
var modalLayoutContentSchema = z.lazy(
|
|
6221
|
-
() => z.object({
|
|
6222
|
-
title: z.string().optional(),
|
|
6223
|
-
components: z.array(layoutSchema)
|
|
6224
|
-
})
|
|
6225
|
-
);
|
|
6226
|
-
var boxLayoutSchema = z.lazy(
|
|
6227
|
-
() => z.object({
|
|
6228
|
-
type: z.literal("box"),
|
|
6229
|
-
components: z.array(layoutSchema),
|
|
6230
|
-
width: sizeSchema.optional(),
|
|
6231
|
-
border: z.boolean().optional(),
|
|
6232
|
-
control: z.string().optional(),
|
|
6233
|
-
margin: sizeSchema.optional()
|
|
6234
|
-
})
|
|
6235
|
-
);
|
|
6236
|
-
var modalLayoutSchema = z.lazy(
|
|
6237
|
-
() => z.object({
|
|
6238
|
-
type: z.literal("modal"),
|
|
6239
|
-
control: z.string().optional(),
|
|
6240
|
-
margin: sizeSchema.optional(),
|
|
6241
|
-
trigger: modalLayoutTriggerSchema,
|
|
6242
|
-
content: modalLayoutContentSchema
|
|
6262
|
+
alert: alertLayoutSchema.optional()
|
|
6243
6263
|
})
|
|
6244
6264
|
);
|
|
6245
6265
|
var validateStep = (step) => validate(step, stepSchema);
|
|
@@ -6335,6 +6355,15 @@ var mergeModels = (valueA, valueB) => {
|
|
|
6335
6355
|
return valueB;
|
|
6336
6356
|
};
|
|
6337
6357
|
|
|
6358
|
+
// src/revamp/domain/mappers/utils/image.ts
|
|
6359
|
+
var mapSpecImage = (image) => {
|
|
6360
|
+
var _a, _b, _c;
|
|
6361
|
+
return image ? {
|
|
6362
|
+
uri: (_b = (_a = image.uri) != null ? _a : image.url) != null ? _b : "",
|
|
6363
|
+
accessibilityDescription: (_c = image.accessibilityDescription) != null ? _c : image.text
|
|
6364
|
+
} : void 0;
|
|
6365
|
+
};
|
|
6366
|
+
|
|
6338
6367
|
// src/revamp/domain/features/summary/summary-utils.ts
|
|
6339
6368
|
var getSummariser = (schema) => (value) => {
|
|
6340
6369
|
const { summary, icon, image } = schema;
|
|
@@ -6367,7 +6396,7 @@ var summaryIfProvides = (summary, { value, icon, image }) => {
|
|
|
6367
6396
|
title: summary.providesTitle && value || void 0,
|
|
6368
6397
|
description: summary.providesDescription && value || void 0,
|
|
6369
6398
|
icon: summary.providesIcon && icon || void 0,
|
|
6370
|
-
image: summary.providesImage && image || void 0
|
|
6399
|
+
image: summary.providesImage && mapSpecImage(image != null ? image : void 0) || void 0
|
|
6371
6400
|
};
|
|
6372
6401
|
};
|
|
6373
6402
|
|
|
@@ -6467,7 +6496,7 @@ var getOnErrorAction = (onError) => {
|
|
|
6467
6496
|
return onError.behavior.action;
|
|
6468
6497
|
}
|
|
6469
6498
|
}
|
|
6470
|
-
if ("action" in onError) {
|
|
6499
|
+
if ("action" in onError && onError.action) {
|
|
6471
6500
|
return onError.action;
|
|
6472
6501
|
}
|
|
6473
6502
|
return {};
|
|
@@ -6678,6 +6707,10 @@ var buttonLayoutToComponentWithBehavior = (uid, button, mapperProps) => {
|
|
|
6678
6707
|
const { onAction, onLink, step } = mapperProps;
|
|
6679
6708
|
const { context, control, disabled, margin = "md", pinOrder, size, title, behavior } = button;
|
|
6680
6709
|
const getOnClick2 = () => {
|
|
6710
|
+
if (!behavior) {
|
|
6711
|
+
return () => {
|
|
6712
|
+
};
|
|
6713
|
+
}
|
|
6681
6714
|
if ("type" in behavior) {
|
|
6682
6715
|
switch (behavior.type) {
|
|
6683
6716
|
case "action": {
|
|
@@ -6847,6 +6880,7 @@ var decisionLayoutToComponent = (uid, {
|
|
|
6847
6880
|
return __spreadProps(__spreadValues({}, option), {
|
|
6848
6881
|
disabled: (_a = option.disabled) != null ? _a : false,
|
|
6849
6882
|
href: getHref(option),
|
|
6883
|
+
image: mapSpecImage(option.image),
|
|
6850
6884
|
onClick: getOnClick(option, mapperProps)
|
|
6851
6885
|
});
|
|
6852
6886
|
}),
|
|
@@ -6861,13 +6895,13 @@ var getHref = (option) => {
|
|
|
6861
6895
|
};
|
|
6862
6896
|
var getOnClick = (option, { step, onAction, onLink }) => {
|
|
6863
6897
|
const { behavior } = option;
|
|
6864
|
-
if (!behavior) {
|
|
6898
|
+
if (!behavior && option.action) {
|
|
6865
6899
|
const action = inlineAction(option.action, step == null ? void 0 : step.actions);
|
|
6866
6900
|
return () => {
|
|
6867
6901
|
void onAction(action);
|
|
6868
6902
|
};
|
|
6869
6903
|
}
|
|
6870
|
-
if ("type" in behavior) {
|
|
6904
|
+
if (behavior && "type" in behavior) {
|
|
6871
6905
|
switch (behavior.type) {
|
|
6872
6906
|
case "action": {
|
|
6873
6907
|
const action = inlineAction(behavior.action, step == null ? void 0 : step.actions);
|
|
@@ -6941,6 +6975,9 @@ var isExactLocalValueMatch = (valueA, valueB) => {
|
|
|
6941
6975
|
return valueA === valueB;
|
|
6942
6976
|
};
|
|
6943
6977
|
|
|
6978
|
+
// src/revamp/domain/components/utils/getRandomId.ts
|
|
6979
|
+
var getRandomId = () => Math.random().toString(36).substring(2);
|
|
6980
|
+
|
|
6944
6981
|
// src/revamp/domain/features/persistAsync/getComponentPersistAsync.ts
|
|
6945
6982
|
var getComponentPersistAsync = (update, performPersistAsync) => (
|
|
6946
6983
|
/**
|
|
@@ -7020,7 +7057,7 @@ var getComponentMultiPersistAsync = (update, performPersistAsync) => (
|
|
|
7020
7057
|
draft.persistedState = [
|
|
7021
7058
|
...draft.persistedState.slice(0, index),
|
|
7022
7059
|
{
|
|
7023
|
-
id:
|
|
7060
|
+
id: getRandomId(),
|
|
7024
7061
|
abortController: newAbortController,
|
|
7025
7062
|
lastResponse: null,
|
|
7026
7063
|
lastSubmitted: null,
|
|
@@ -7581,7 +7618,7 @@ var mapCommonSchemaProps = (schemaMapperProps) => {
|
|
|
7581
7618
|
errors: isString(validationErrors) ? [validationErrors] : void 0,
|
|
7582
7619
|
hidden: Boolean(hidden),
|
|
7583
7620
|
icon,
|
|
7584
|
-
image,
|
|
7621
|
+
image: mapSpecImage(image),
|
|
7585
7622
|
keywords,
|
|
7586
7623
|
required: Boolean(required),
|
|
7587
7624
|
title,
|
|
@@ -8188,7 +8225,7 @@ var oneOfSchemaToComponent = (schemaMapperProps, mapperProps) => {
|
|
|
8188
8225
|
return {
|
|
8189
8226
|
title,
|
|
8190
8227
|
description,
|
|
8191
|
-
image,
|
|
8228
|
+
image: mapSpecImage(image),
|
|
8192
8229
|
icon,
|
|
8193
8230
|
keywords,
|
|
8194
8231
|
disabled: "disabled" in childSchema ? Boolean(childSchema.disabled) : false,
|
|
@@ -8909,7 +8946,9 @@ var arraySchemaToRepeatableComponent = (schemaMapperProps, mapperProps) => {
|
|
|
8909
8946
|
editItemTitle,
|
|
8910
8947
|
maxItems,
|
|
8911
8948
|
minItems,
|
|
8912
|
-
summary,
|
|
8949
|
+
summary: __spreadProps(__spreadValues({}, summary), {
|
|
8950
|
+
defaultImage: mapSpecImage(summary == null ? void 0 : summary.defaultImage)
|
|
8951
|
+
}),
|
|
8913
8952
|
createEditableComponent,
|
|
8914
8953
|
onValueChange
|
|
8915
8954
|
}),
|
|
@@ -8932,9 +8971,6 @@ var localValueToJsonElement = (localValue) => {
|
|
|
8932
8971
|
};
|
|
8933
8972
|
var getRandomInt = () => Math.floor(Math.random() * 1e8);
|
|
8934
8973
|
|
|
8935
|
-
// src/revamp/domain/components/utils/getRandomId.ts
|
|
8936
|
-
var getRandomId = () => Math.random().toString(36).substring(2);
|
|
8937
|
-
|
|
8938
8974
|
// src/revamp/domain/components/MultiUploadInputComponent.ts
|
|
8939
8975
|
var createMultiUploadInputComponent = (uploadInputProps, updateComponent) => {
|
|
8940
8976
|
const _a = uploadInputProps, {
|
|
@@ -9237,7 +9273,7 @@ var arraySchemaToMultiSelectComponent = (schemaMapperProps, mapperProps) => {
|
|
|
9237
9273
|
return {
|
|
9238
9274
|
title: title2,
|
|
9239
9275
|
description,
|
|
9240
|
-
image,
|
|
9276
|
+
image: mapSpecImage(image),
|
|
9241
9277
|
icon,
|
|
9242
9278
|
keywords,
|
|
9243
9279
|
disabled: "disabled" in childSchema ? Boolean(childSchema.disabled) : false,
|
|
@@ -9698,13 +9734,27 @@ var createImageComponent = (imageProps) => __spreadProps(__spreadValues({
|
|
|
9698
9734
|
});
|
|
9699
9735
|
|
|
9700
9736
|
// src/revamp/domain/mappers/layout/imageLayoutToComponent.ts
|
|
9701
|
-
var imageLayoutToComponent = (uid, {
|
|
9702
|
-
|
|
9703
|
-
content
|
|
9737
|
+
var imageLayoutToComponent = (uid, {
|
|
9738
|
+
accessibilityDescription,
|
|
9739
|
+
content,
|
|
9704
9740
|
control,
|
|
9705
|
-
margin,
|
|
9706
|
-
size
|
|
9707
|
-
|
|
9741
|
+
margin = "md",
|
|
9742
|
+
size = "md",
|
|
9743
|
+
text,
|
|
9744
|
+
url
|
|
9745
|
+
}) => {
|
|
9746
|
+
var _a, _b, _c;
|
|
9747
|
+
return createImageComponent({
|
|
9748
|
+
uid,
|
|
9749
|
+
content: content ? {
|
|
9750
|
+
uri: (_b = (_a = content.uri) != null ? _a : content.url) != null ? _b : "",
|
|
9751
|
+
accessibilityDescription: (_c = content.accessibilityDescription) != null ? _c : content.text
|
|
9752
|
+
} : { accessibilityDescription: accessibilityDescription != null ? accessibilityDescription : text, uri: url != null ? url : "" },
|
|
9753
|
+
control,
|
|
9754
|
+
margin,
|
|
9755
|
+
size
|
|
9756
|
+
});
|
|
9757
|
+
};
|
|
9708
9758
|
|
|
9709
9759
|
// src/revamp/domain/components/MarkdownComponent.ts
|
|
9710
9760
|
var createMarkdownComponent = (markdownProps) => __spreadProps(__spreadValues({
|
|
@@ -10229,7 +10279,9 @@ var createListComponent = (listProps) => __spreadProps(__spreadValues({
|
|
|
10229
10279
|
var listLayoutToComponent = (uid, { callToAction, control, items, margin = "md", title }, mapperProps) => createListComponent({
|
|
10230
10280
|
uid,
|
|
10231
10281
|
control,
|
|
10232
|
-
items: items.map((item) => __spreadValues({}, item)
|
|
10282
|
+
items: items.map((item) => __spreadProps(__spreadValues({}, item), {
|
|
10283
|
+
image: mapSpecImage(item.image)
|
|
10284
|
+
})),
|
|
10233
10285
|
callToAction: getListCallToAction(callToAction, mapperProps),
|
|
10234
10286
|
margin,
|
|
10235
10287
|
title
|
|
@@ -10353,13 +10405,13 @@ var getUnreferencedSchemas = (step) => {
|
|
|
10353
10405
|
// src/revamp/domain/mappers/mapStepToComponent.ts
|
|
10354
10406
|
var mapStepToComponent = (_a) => {
|
|
10355
10407
|
var _b = _a, {
|
|
10356
|
-
|
|
10408
|
+
count,
|
|
10357
10409
|
loadingState,
|
|
10358
10410
|
displayStepTitle,
|
|
10359
10411
|
trackEvent,
|
|
10360
10412
|
onPoll
|
|
10361
10413
|
} = _b, restProps = __objRest(_b, [
|
|
10362
|
-
"
|
|
10414
|
+
"count",
|
|
10363
10415
|
"loadingState",
|
|
10364
10416
|
"displayStepTitle",
|
|
10365
10417
|
"trackEvent",
|
|
@@ -10367,7 +10419,18 @@ var mapStepToComponent = (_a) => {
|
|
|
10367
10419
|
]);
|
|
10368
10420
|
var _a2, _b2;
|
|
10369
10421
|
const { step, updateComponent } = restProps;
|
|
10370
|
-
const {
|
|
10422
|
+
const {
|
|
10423
|
+
id,
|
|
10424
|
+
control,
|
|
10425
|
+
description,
|
|
10426
|
+
errors,
|
|
10427
|
+
external,
|
|
10428
|
+
key,
|
|
10429
|
+
layout = [],
|
|
10430
|
+
navigation,
|
|
10431
|
+
polling,
|
|
10432
|
+
title
|
|
10433
|
+
} = step;
|
|
10371
10434
|
const backNavigation = (_a2 = navigation == null ? void 0 : navigation.back) != null ? _a2 : navigation == null ? void 0 : navigation.backButton;
|
|
10372
10435
|
const back = backNavigation ? {
|
|
10373
10436
|
title: backNavigation.title,
|
|
@@ -10380,7 +10443,7 @@ var mapStepToComponent = (_a) => {
|
|
|
10380
10443
|
if (stepId === void 0) {
|
|
10381
10444
|
throw new Error("Step must have an id or a key");
|
|
10382
10445
|
}
|
|
10383
|
-
const uid = `${stepId != null ? stepId : "step"}_${
|
|
10446
|
+
const uid = `${stepId != null ? stepId : "step"}_${count % 100}`;
|
|
10384
10447
|
const onAction = async (action) => {
|
|
10385
10448
|
try {
|
|
10386
10449
|
await stepComponent.getSubmittableValue();
|
|
@@ -10407,6 +10470,7 @@ var mapStepToComponent = (_a) => {
|
|
|
10407
10470
|
uid,
|
|
10408
10471
|
back,
|
|
10409
10472
|
components,
|
|
10473
|
+
control,
|
|
10410
10474
|
description,
|
|
10411
10475
|
error: errors == null ? void 0 : errors.error,
|
|
10412
10476
|
external,
|
|
@@ -10871,10 +10935,7 @@ function useDynamicFlowCore(props) {
|
|
|
10871
10935
|
);
|
|
10872
10936
|
const [stepComponent, setStepComponent] = useState(null);
|
|
10873
10937
|
const stepComponentRef = useRef2(null);
|
|
10874
|
-
const
|
|
10875
|
-
const flipStepBit = () => {
|
|
10876
|
-
stepBit.current = stepBit.current === "flip" ? "flop" : "flip";
|
|
10877
|
-
};
|
|
10938
|
+
const stepCount = useRef2(0);
|
|
10878
10939
|
const stepRef = useRef2(initialStep != null ? initialStep : null);
|
|
10879
10940
|
const etagRef = useRef2(null);
|
|
10880
10941
|
const abortControllerRef = useRef2(new AbortController());
|
|
@@ -10889,13 +10950,23 @@ function useDynamicFlowCore(props) {
|
|
|
10889
10950
|
void onAction(__spreadValues({ method: "GET" }, initialAction));
|
|
10890
10951
|
}
|
|
10891
10952
|
if (initialStep && !initialAction) {
|
|
10892
|
-
|
|
10953
|
+
createStep(initialStep, null);
|
|
10893
10954
|
trackCoreEvent("Step Shown", { isFirstStep: true });
|
|
10894
10955
|
}
|
|
10895
10956
|
}, []);
|
|
10957
|
+
const createStep = useCallback2((newStep, etag) => {
|
|
10958
|
+
if (stepComponentRef.current) {
|
|
10959
|
+
stepCount.current += 1;
|
|
10960
|
+
}
|
|
10961
|
+
initialiseWithStep(newStep, etag, null);
|
|
10962
|
+
}, []);
|
|
10963
|
+
const updateStep = useCallback2((newStep, etag) => {
|
|
10964
|
+
var _a2, _b;
|
|
10965
|
+
initialiseWithStep(newStep, etag, (_b = (_a2 = stepComponentRef.current) == null ? void 0 : _a2.getLocalValue()) != null ? _b : null);
|
|
10966
|
+
}, []);
|
|
10896
10967
|
const initialiseWithStep = useCallback2(
|
|
10897
|
-
(newStep, etag) => {
|
|
10898
|
-
var _a2
|
|
10968
|
+
(newStep, etag, localValue) => {
|
|
10969
|
+
var _a2;
|
|
10899
10970
|
(_a2 = stepComponentRef.current) == null ? void 0 : _a2.stop();
|
|
10900
10971
|
stepRef.current = newStep;
|
|
10901
10972
|
etagRef.current = etag;
|
|
@@ -10918,8 +10989,8 @@ function useDynamicFlowCore(props) {
|
|
|
10918
10989
|
};
|
|
10919
10990
|
try {
|
|
10920
10991
|
const newStepComponent = mapStepToComponent({
|
|
10921
|
-
|
|
10922
|
-
stepLocalValue:
|
|
10992
|
+
count: stepCount.current,
|
|
10993
|
+
stepLocalValue: localValue,
|
|
10923
10994
|
step: newStep,
|
|
10924
10995
|
displayStepTitle,
|
|
10925
10996
|
loadingState: "idle",
|
|
@@ -11004,8 +11075,7 @@ function useDynamicFlowCore(props) {
|
|
|
11004
11075
|
}
|
|
11005
11076
|
case "replace-step": {
|
|
11006
11077
|
const isFirstStep = stepRef.current === null;
|
|
11007
|
-
|
|
11008
|
-
initialiseWithStep(command.step, command.etag);
|
|
11078
|
+
createStep(command.step, command.etag);
|
|
11009
11079
|
trackCoreEvent("Step Shown", { isFirstStep });
|
|
11010
11080
|
break;
|
|
11011
11081
|
}
|
|
@@ -11013,7 +11083,7 @@ function useDynamicFlowCore(props) {
|
|
|
11013
11083
|
const genericErrorMessage = getErrorMessageFunctions().genericErrorWithRetry();
|
|
11014
11084
|
const { errors = { error: genericErrorMessage } } = command.body;
|
|
11015
11085
|
if (stepRef.current) {
|
|
11016
|
-
|
|
11086
|
+
updateStep(
|
|
11017
11087
|
__spreadProps(__spreadValues({}, stepRef.current), {
|
|
11018
11088
|
// the existing step
|
|
11019
11089
|
errors,
|
|
@@ -11061,7 +11131,7 @@ function useDynamicFlowCore(props) {
|
|
|
11061
11131
|
case "refresh-step":
|
|
11062
11132
|
{
|
|
11063
11133
|
const errors = errorsOverride != null ? errorsOverride : command.step.errors;
|
|
11064
|
-
|
|
11134
|
+
updateStep(__spreadProps(__spreadValues({}, command.step), { errors }), command.etag);
|
|
11065
11135
|
}
|
|
11066
11136
|
break;
|
|
11067
11137
|
case "error": {
|
|
@@ -11094,8 +11164,7 @@ function useDynamicFlowCore(props) {
|
|
|
11094
11164
|
});
|
|
11095
11165
|
switch (command.type) {
|
|
11096
11166
|
case "replace-step":
|
|
11097
|
-
|
|
11098
|
-
initialiseWithStep(command.step, command.etag);
|
|
11167
|
+
createStep(command.step, command.etag);
|
|
11099
11168
|
return true;
|
|
11100
11169
|
case "action":
|
|
11101
11170
|
void onAction(command.action);
|
|
@@ -11151,7 +11220,7 @@ var mapErrorsToValidationState = (errors) => {
|
|
|
11151
11220
|
|
|
11152
11221
|
// src/revamp/renderers/mappers/utils/inputComponentToProps.ts
|
|
11153
11222
|
var inputComponentToProps = (component, type) => {
|
|
11154
|
-
var _a
|
|
11223
|
+
var _a;
|
|
11155
11224
|
const {
|
|
11156
11225
|
uid,
|
|
11157
11226
|
control,
|
|
@@ -11180,11 +11249,7 @@ var inputComponentToProps = (component, type) => {
|
|
|
11180
11249
|
help,
|
|
11181
11250
|
icon,
|
|
11182
11251
|
id,
|
|
11183
|
-
image
|
|
11184
|
-
accessibilityDescription: (_b = image.accessibilityDescription) != null ? _b : image.text,
|
|
11185
|
-
uri: image.uri,
|
|
11186
|
-
url: (_d = (_c = image.uri) != null ? _c : image.url) != null ? _d : ""
|
|
11187
|
-
} : void 0,
|
|
11252
|
+
image,
|
|
11188
11253
|
placeholder,
|
|
11189
11254
|
required,
|
|
11190
11255
|
title,
|
|
@@ -11239,7 +11304,7 @@ var mapBoxControl = ({
|
|
|
11239
11304
|
|
|
11240
11305
|
// src/revamp/renderers/mappers/buttonComponentToProps.ts
|
|
11241
11306
|
var buttonComponentToProps = (component, rendererMapperProps) => {
|
|
11242
|
-
return __spreadValues(__spreadValues({
|
|
11307
|
+
return __spreadValues(__spreadProps(__spreadValues({
|
|
11243
11308
|
type: "button"
|
|
11244
11309
|
}, pick(
|
|
11245
11310
|
component,
|
|
@@ -11247,12 +11312,13 @@ var buttonComponentToProps = (component, rendererMapperProps) => {
|
|
|
11247
11312
|
"title",
|
|
11248
11313
|
"control",
|
|
11249
11314
|
"context",
|
|
11250
|
-
"disabled",
|
|
11251
11315
|
"margin",
|
|
11252
11316
|
"pinOrder",
|
|
11253
11317
|
"size",
|
|
11254
11318
|
"onClick"
|
|
11255
|
-
)),
|
|
11319
|
+
)), {
|
|
11320
|
+
disabled: component.disabled || rendererMapperProps.stepLoadingState !== "idle"
|
|
11321
|
+
}), rendererMapperProps);
|
|
11256
11322
|
};
|
|
11257
11323
|
|
|
11258
11324
|
// src/revamp/renderers/mappers/columnsComponentToProps.ts
|
|
@@ -11298,14 +11364,9 @@ var dateInputComponentToProps = (component, rendererMapperProps) => __spreadProp
|
|
|
11298
11364
|
// src/revamp/renderers/mappers/decisionComponentToProps.ts
|
|
11299
11365
|
var decisionComponentToProps = (component, rendererMapperProps) => __spreadProps(__spreadValues(__spreadValues({}, pick(component, "uid", "type", "control", "margin", "title")), rendererMapperProps), {
|
|
11300
11366
|
options: component.options.map((_a) => {
|
|
11301
|
-
var _b = _a, {
|
|
11302
|
-
var _a2, _b2, _c;
|
|
11367
|
+
var _b = _a, { disabled } = _b, rest = __objRest(_b, ["disabled"]);
|
|
11303
11368
|
return __spreadProps(__spreadValues({}, rest), {
|
|
11304
|
-
|
|
11305
|
-
accessibilityDescription: (_a2 = image.accessibilityDescription) != null ? _a2 : image.text,
|
|
11306
|
-
uri: image.uri,
|
|
11307
|
-
url: (_c = (_b2 = image.uri) != null ? _b2 : image.url) != null ? _c : ""
|
|
11308
|
-
} : image
|
|
11369
|
+
disabled: disabled || rendererMapperProps.stepLoadingState !== "idle"
|
|
11309
11370
|
});
|
|
11310
11371
|
})
|
|
11311
11372
|
});
|
|
@@ -11337,14 +11398,10 @@ var hiddenComponentToProps = ({ uid }) => ({
|
|
|
11337
11398
|
});
|
|
11338
11399
|
|
|
11339
11400
|
// src/revamp/renderers/mappers/imageComponentToProps.ts
|
|
11340
|
-
var imageComponentToProps = (component, rendererMapperProps) => {
|
|
11341
|
-
|
|
11342
|
-
|
|
11343
|
-
|
|
11344
|
-
url: (_a = component.content.url) != null ? _a : "",
|
|
11345
|
-
uri: component.content.uri
|
|
11346
|
-
});
|
|
11347
|
-
};
|
|
11401
|
+
var imageComponentToProps = (component, rendererMapperProps) => __spreadProps(__spreadValues(__spreadValues({}, pick(component, "uid", "type", "control", "margin", "size")), rendererMapperProps), {
|
|
11402
|
+
uri: component.content.uri,
|
|
11403
|
+
accessibilityDescription: component.content.accessibilityDescription
|
|
11404
|
+
});
|
|
11348
11405
|
|
|
11349
11406
|
// src/revamp/renderers/mappers/instructionsComponentToProps.ts
|
|
11350
11407
|
var instructionsComponentToProps = (component, rendererMapperProps) => __spreadValues(__spreadValues({}, pick(component, "uid", "type", "control", "items", "margin", "title")), rendererMapperProps);
|
|
@@ -11409,15 +11466,10 @@ var numberInputComponentToProps = (component, rendererMapperProps) => __spreadPr
|
|
|
11409
11466
|
|
|
11410
11467
|
// src/revamp/renderers/mappers/objectComponentToProps.ts
|
|
11411
11468
|
var objectComponentToProps = (component, rendererMapperProps) => {
|
|
11412
|
-
var _a, _b;
|
|
11413
11469
|
const childrenProps = component.getChildren().map((c) => componentToRendererProps(c, rendererMapperProps));
|
|
11414
11470
|
return __spreadProps(__spreadValues(__spreadValues({
|
|
11415
11471
|
type: "section"
|
|
11416
|
-
}, pick(component, "uid", "control", "description", "help", "icon", "title")), rendererMapperProps), {
|
|
11417
|
-
// TODO: Remove when viewbindings are updated
|
|
11418
|
-
image: component.image ? __spreadProps(__spreadValues({}, component.image), {
|
|
11419
|
-
url: (_b = (_a = component.image) == null ? void 0 : _a.url) != null ? _b : ""
|
|
11420
|
-
}) : void 0,
|
|
11472
|
+
}, pick(component, "uid", "control", "description", "help", "icon", "image", "title")), rendererMapperProps), {
|
|
11421
11473
|
children: childrenProps.map(rendererMapperProps.render),
|
|
11422
11474
|
childrenProps
|
|
11423
11475
|
});
|
|
@@ -11428,7 +11480,6 @@ var paragraphComponentToProps = (component, rendererMapperProps) => __spreadValu
|
|
|
11428
11480
|
|
|
11429
11481
|
// src/revamp/renderers/mappers/repeatableComponentToProps.ts
|
|
11430
11482
|
var repeatableComponentToProps = (component, rendererMapperProps) => {
|
|
11431
|
-
var _a, _b;
|
|
11432
11483
|
const {
|
|
11433
11484
|
uid,
|
|
11434
11485
|
addItemTitle,
|
|
@@ -11451,26 +11502,13 @@ var repeatableComponentToProps = (component, rendererMapperProps) => {
|
|
|
11451
11502
|
} = component;
|
|
11452
11503
|
const childrenProps = component.getChildren().map((c) => componentToRendererProps(c, rendererMapperProps));
|
|
11453
11504
|
const editableItemProps = editableComponent ? componentToRendererProps(editableComponent, rendererMapperProps) : null;
|
|
11454
|
-
const getSummaryImage = (componentSummary) => {
|
|
11455
|
-
var _a2, _b2;
|
|
11456
|
-
if (componentSummary.image) {
|
|
11457
|
-
return __spreadProps(__spreadValues({}, componentSummary.image), {
|
|
11458
|
-
url: (_a2 = componentSummary.image.url) != null ? _a2 : ""
|
|
11459
|
-
});
|
|
11460
|
-
}
|
|
11461
|
-
if (summaryDefaults.image) {
|
|
11462
|
-
return __spreadProps(__spreadValues({}, summaryDefaults.image), {
|
|
11463
|
-
url: (_b2 = summaryDefaults.image.url) != null ? _b2 : ""
|
|
11464
|
-
});
|
|
11465
|
-
}
|
|
11466
|
-
};
|
|
11467
11505
|
const getSummary = (componentSummary) => {
|
|
11468
|
-
var
|
|
11506
|
+
var _a, _b, _c, _d;
|
|
11469
11507
|
return {
|
|
11470
|
-
title: (
|
|
11471
|
-
description: (
|
|
11508
|
+
title: (_a = componentSummary.title) != null ? _a : summaryDefaults.title,
|
|
11509
|
+
description: (_b = componentSummary.description) != null ? _b : summaryDefaults.description,
|
|
11472
11510
|
icon: (_c = componentSummary.icon) != null ? _c : summaryDefaults.icon,
|
|
11473
|
-
image:
|
|
11511
|
+
image: (_d = componentSummary.image) != null ? _d : summaryDefaults.image
|
|
11474
11512
|
};
|
|
11475
11513
|
};
|
|
11476
11514
|
const itemProps = components.map((childComponent) => __spreadProps(__spreadValues({}, getSummary(childComponent.getSummary())), {
|
|
@@ -11488,11 +11526,7 @@ var repeatableComponentToProps = (component, rendererMapperProps) => {
|
|
|
11488
11526
|
editableItemProps,
|
|
11489
11527
|
editItemTitle,
|
|
11490
11528
|
icon,
|
|
11491
|
-
image
|
|
11492
|
-
accessibilityDescription: (_a = image.accessibilityDescription) != null ? _a : image.text,
|
|
11493
|
-
uri: image.uri,
|
|
11494
|
-
url: (_b = image.url) != null ? _b : ""
|
|
11495
|
-
} : void 0,
|
|
11529
|
+
image,
|
|
11496
11530
|
items: itemProps,
|
|
11497
11531
|
maxItems,
|
|
11498
11532
|
minItems,
|
|
@@ -11557,6 +11591,7 @@ var getSearchState = ({
|
|
|
11557
11591
|
var _a;
|
|
11558
11592
|
return __spreadProps(__spreadValues({}, result), {
|
|
11559
11593
|
id: result.type === "action" ? (_a = result.value.id) != null ? _a : result.value.$id : void 0,
|
|
11594
|
+
image: mapSpecImage(result.image),
|
|
11560
11595
|
onClick: () => onSelect(result)
|
|
11561
11596
|
});
|
|
11562
11597
|
});
|
|
@@ -11620,15 +11655,10 @@ var uploadInputComponentToProps = (component, rendererMapperProps) => {
|
|
|
11620
11655
|
|
|
11621
11656
|
// src/revamp/renderers/mappers/tupleComponentToProps.ts
|
|
11622
11657
|
var tupleComponentToProps = (component, rendererMapperProps) => {
|
|
11623
|
-
var _a, _b;
|
|
11624
11658
|
const childrenProps = component.getChildren().map((c) => componentToRendererProps(c, rendererMapperProps));
|
|
11625
11659
|
return __spreadProps(__spreadValues(__spreadValues({
|
|
11626
11660
|
type: "section"
|
|
11627
|
-
}, pick(component, "uid", "control", "description", "help", "icon", "title")), rendererMapperProps), {
|
|
11628
|
-
// TODO Remove URL default after next types update (add back to `pick`)
|
|
11629
|
-
image: component.image ? __spreadProps(__spreadValues({}, component.image), {
|
|
11630
|
-
url: (_b = (_a = component.image) == null ? void 0 : _a.url) != null ? _b : ""
|
|
11631
|
-
}) : void 0,
|
|
11661
|
+
}, pick(component, "uid", "control", "description", "help", "icon", "image", "title")), rendererMapperProps), {
|
|
11632
11662
|
children: childrenProps.map(rendererMapperProps.render),
|
|
11633
11663
|
childrenProps
|
|
11634
11664
|
});
|
|
@@ -11637,15 +11667,8 @@ var tupleComponentToProps = (component, rendererMapperProps) => {
|
|
|
11637
11667
|
// src/revamp/renderers/mappers/listComponentToProps.ts
|
|
11638
11668
|
var listComponentToProps = (component, rendererMapperProps) => __spreadProps(__spreadValues(__spreadValues({}, pick(component, "uid", "type", "callToAction", "control", "margin", "title")), rendererMapperProps), {
|
|
11639
11669
|
items: component.items.map((_a) => {
|
|
11640
|
-
var
|
|
11641
|
-
|
|
11642
|
-
return __spreadProps(__spreadValues({}, rest), {
|
|
11643
|
-
image: image ? {
|
|
11644
|
-
accessibilityDescription: (_a2 = image == null ? void 0 : image.accessibilityDescription) != null ? _a2 : image == null ? void 0 : image.text,
|
|
11645
|
-
uri: image == null ? void 0 : image.uri,
|
|
11646
|
-
url: (_c = (_b2 = image == null ? void 0 : image.url) != null ? _b2 : image == null ? void 0 : image.url) != null ? _c : ""
|
|
11647
|
-
} : void 0
|
|
11648
|
-
});
|
|
11670
|
+
var item = __objRest(_a, []);
|
|
11671
|
+
return __spreadValues({}, item);
|
|
11649
11672
|
})
|
|
11650
11673
|
});
|
|
11651
11674
|
|
|
@@ -18898,22 +18921,13 @@ var noop8 = () => {
|
|
|
18898
18921
|
};
|
|
18899
18922
|
|
|
18900
18923
|
// src/revamp/renderers/utils.ts
|
|
18901
|
-
function
|
|
18902
|
-
if (isArray(root)) {
|
|
18903
|
-
return root.flatMap((child) => find(child, predicate));
|
|
18904
|
-
}
|
|
18905
|
-
return [
|
|
18906
|
-
...predicate(root) ? [root] : [],
|
|
18907
|
-
...getChildren(root).flatMap((child) => find(child, predicate))
|
|
18908
|
-
];
|
|
18909
|
-
}
|
|
18910
|
-
function findType(root, type, predicate = () => true) {
|
|
18924
|
+
function findRendererPropsByType(root, type, predicate = () => true) {
|
|
18911
18925
|
if (isArray(root)) {
|
|
18912
|
-
return root.flatMap((child) =>
|
|
18926
|
+
return root.flatMap((child) => findRendererPropsByType(child, type, predicate));
|
|
18913
18927
|
}
|
|
18914
18928
|
return [
|
|
18915
18929
|
...isType(root, type) && predicate(root) ? [root] : [],
|
|
18916
|
-
...getChildren(root).flatMap((child) =>
|
|
18930
|
+
...getChildren(root).flatMap((child) => findRendererPropsByType(child, type, predicate))
|
|
18917
18931
|
];
|
|
18918
18932
|
}
|
|
18919
18933
|
var isType = (node, type) => node.type === type;
|
|
@@ -18966,8 +18980,7 @@ export {
|
|
|
18966
18980
|
JsonSchemaForm_default as JsonSchemaForm,
|
|
18967
18981
|
DynamicLayout_default as Layout,
|
|
18968
18982
|
convertStepToLayout,
|
|
18969
|
-
|
|
18970
|
-
findType,
|
|
18983
|
+
findRendererPropsByType,
|
|
18971
18984
|
inlineReferences,
|
|
18972
18985
|
isValidSchema,
|
|
18973
18986
|
makeHttpClient,
|