@wise/dynamic-flow-client 3.22.1 → 3.22.2-experimental-b24c473
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 +406 -300
- package/build/main.min.js +1 -1
- package/build/main.mjs +406 -300
- package/build/types/legacy/common/validators/schemas/one-of-preselection.d.ts +9 -0
- package/package.json +1 -1
package/build/main.mjs
CHANGED
|
@@ -5867,21 +5867,13 @@ var z = /* @__PURE__ */ Object.freeze({
|
|
|
5867
5867
|
quotelessJson,
|
|
5868
5868
|
ZodError
|
|
5869
5869
|
});
|
|
5870
|
-
var
|
|
5871
|
-
|
|
5872
|
-
|
|
5873
|
-
|
|
5874
|
-
|
|
5875
|
-
|
|
5876
|
-
z.literal("GET"),
|
|
5877
|
-
z.literal("POST"),
|
|
5878
|
-
z.literal("PUT"),
|
|
5879
|
-
z.literal("PATCH"),
|
|
5880
|
-
z.literal("DELETE")
|
|
5870
|
+
var sizeSchema = z.union([
|
|
5871
|
+
z.literal("xs"),
|
|
5872
|
+
z.literal("sm"),
|
|
5873
|
+
z.literal("md"),
|
|
5874
|
+
z.literal("lg"),
|
|
5875
|
+
z.literal("xl")
|
|
5881
5876
|
]);
|
|
5882
|
-
var iconNamedSchema = z.object({
|
|
5883
|
-
name: z.string()
|
|
5884
|
-
});
|
|
5885
5877
|
var contextSchema = z.union([
|
|
5886
5878
|
z.literal("positive"),
|
|
5887
5879
|
z.literal("neutral"),
|
|
@@ -5892,18 +5884,107 @@ var contextSchema = z.union([
|
|
|
5892
5884
|
z.literal("info"),
|
|
5893
5885
|
z.literal("primary")
|
|
5894
5886
|
]);
|
|
5895
|
-
var
|
|
5896
|
-
|
|
5897
|
-
|
|
5898
|
-
|
|
5899
|
-
|
|
5900
|
-
|
|
5901
|
-
z.literal("
|
|
5902
|
-
z.literal("
|
|
5903
|
-
z.literal("
|
|
5887
|
+
var columnsLayoutBiasSchema = z.union([
|
|
5888
|
+
z.literal("none"),
|
|
5889
|
+
z.literal("left"),
|
|
5890
|
+
z.literal("right")
|
|
5891
|
+
]);
|
|
5892
|
+
var statusListLayoutStatusSchema = z.union([
|
|
5893
|
+
z.literal("not-done"),
|
|
5894
|
+
z.literal("pending"),
|
|
5895
|
+
z.literal("done")
|
|
5904
5896
|
]);
|
|
5905
5897
|
var alignSchema = z.union([z.literal("left"), z.literal("center"), z.literal("right")]);
|
|
5906
|
-
var
|
|
5898
|
+
var formLayoutSchemaReferenceSchema = z.object({
|
|
5899
|
+
$ref: z.string()
|
|
5900
|
+
});
|
|
5901
|
+
var modalLayoutTriggerSchema = z.object({
|
|
5902
|
+
title: z.string()
|
|
5903
|
+
});
|
|
5904
|
+
var httpMethodSchema = z.union([
|
|
5905
|
+
z.literal("GET"),
|
|
5906
|
+
z.literal("POST"),
|
|
5907
|
+
z.literal("PUT"),
|
|
5908
|
+
z.literal("PATCH"),
|
|
5909
|
+
z.literal("DELETE")
|
|
5910
|
+
]);
|
|
5911
|
+
var dividerLayoutSchema = z.object({
|
|
5912
|
+
type: z.literal("divider"),
|
|
5913
|
+
control: z.string().optional(),
|
|
5914
|
+
margin: sizeSchema.optional()
|
|
5915
|
+
});
|
|
5916
|
+
var listLayoutStatusSchema = z.union([
|
|
5917
|
+
z.literal("warning"),
|
|
5918
|
+
z.literal("neutral"),
|
|
5919
|
+
z.literal("positive")
|
|
5920
|
+
]);
|
|
5921
|
+
var headingLayoutSchema = z.object({
|
|
5922
|
+
type: z.literal("heading"),
|
|
5923
|
+
text: z.string(),
|
|
5924
|
+
size: sizeSchema.optional(),
|
|
5925
|
+
align: alignSchema.optional(),
|
|
5926
|
+
control: z.string().optional(),
|
|
5927
|
+
margin: sizeSchema.optional()
|
|
5928
|
+
});
|
|
5929
|
+
var formLayoutSchema = z.object({
|
|
5930
|
+
type: z.literal("form"),
|
|
5931
|
+
schema: formLayoutSchemaReferenceSchema.optional(),
|
|
5932
|
+
schemaId: z.string(),
|
|
5933
|
+
control: z.string().optional(),
|
|
5934
|
+
margin: sizeSchema.optional()
|
|
5935
|
+
});
|
|
5936
|
+
var imageLayoutSchema = z.object({
|
|
5937
|
+
type: z.literal("image"),
|
|
5938
|
+
text: z.string().optional(),
|
|
5939
|
+
url: z.string(),
|
|
5940
|
+
size: sizeSchema.optional(),
|
|
5941
|
+
accessibilityDescription: z.string().optional(),
|
|
5942
|
+
control: z.string().optional(),
|
|
5943
|
+
margin: sizeSchema.optional()
|
|
5944
|
+
});
|
|
5945
|
+
var infoLayoutSchema = z.object({
|
|
5946
|
+
type: z.literal("info"),
|
|
5947
|
+
markdown: z.string(),
|
|
5948
|
+
align: alignSchema.optional(),
|
|
5949
|
+
control: z.string().optional(),
|
|
5950
|
+
margin: sizeSchema.optional()
|
|
5951
|
+
});
|
|
5952
|
+
var loadingIndicatorLayoutSchema = z.object({
|
|
5953
|
+
type: z.literal("loading-indicator"),
|
|
5954
|
+
size: sizeSchema.optional(),
|
|
5955
|
+
control: z.string().optional(),
|
|
5956
|
+
margin: sizeSchema.optional()
|
|
5957
|
+
});
|
|
5958
|
+
var paragraphLayoutSchema = z.object({
|
|
5959
|
+
type: z.literal("paragraph"),
|
|
5960
|
+
text: z.string(),
|
|
5961
|
+
align: alignSchema.optional(),
|
|
5962
|
+
control: z.string().optional(),
|
|
5963
|
+
margin: sizeSchema.optional()
|
|
5964
|
+
});
|
|
5965
|
+
var instructionsLayoutItemSchema = z.object({
|
|
5966
|
+
text: z.string(),
|
|
5967
|
+
context: contextSchema
|
|
5968
|
+
});
|
|
5969
|
+
var helpSchema = z.object({
|
|
5970
|
+
markdown: z.string()
|
|
5971
|
+
});
|
|
5972
|
+
var imageSchema = z.object({
|
|
5973
|
+
text: z.string().optional(),
|
|
5974
|
+
url: z.string(),
|
|
5975
|
+
accessibilityDescription: z.string().optional()
|
|
5976
|
+
});
|
|
5977
|
+
var summaryProviderSchema = z.object({
|
|
5978
|
+
providesTitle: z.boolean().optional(),
|
|
5979
|
+
providesDescription: z.boolean().optional(),
|
|
5980
|
+
providesIcon: z.boolean().optional(),
|
|
5981
|
+
providesImage: z.boolean().optional()
|
|
5982
|
+
});
|
|
5983
|
+
var validateAsyncSchema = z.object({
|
|
5984
|
+
param: z.string(),
|
|
5985
|
+
method: httpMethodSchema,
|
|
5986
|
+
url: z.string()
|
|
5987
|
+
});
|
|
5907
5988
|
var autocompleteTokenSchema = z.union([
|
|
5908
5989
|
z.literal("on"),
|
|
5909
5990
|
z.literal("name"),
|
|
@@ -5969,106 +6050,14 @@ var autocompleteTokenSchema = z.union([
|
|
|
5969
6050
|
z.literal("fax"),
|
|
5970
6051
|
z.literal("pager")
|
|
5971
6052
|
]);
|
|
5972
|
-
var
|
|
5973
|
-
|
|
5974
|
-
|
|
5975
|
-
|
|
5976
|
-
|
|
5977
|
-
|
|
5978
|
-
|
|
5979
|
-
type: z.literal("paragraph"),
|
|
5980
|
-
text: z.string(),
|
|
5981
|
-
align: alignSchema.optional(),
|
|
5982
|
-
control: z.string().optional(),
|
|
5983
|
-
margin: sizeSchema.optional()
|
|
5984
|
-
});
|
|
5985
|
-
var dividerLayoutSchema = z.object({
|
|
5986
|
-
type: z.literal("divider"),
|
|
5987
|
-
control: z.string().optional(),
|
|
5988
|
-
margin: sizeSchema.optional()
|
|
5989
|
-
});
|
|
5990
|
-
var listLayoutStatusSchema = z.union([
|
|
5991
|
-
z.literal("warning"),
|
|
5992
|
-
z.literal("neutral"),
|
|
5993
|
-
z.literal("positive")
|
|
5994
|
-
]);
|
|
5995
|
-
var formLayoutSchemaReferenceSchema = z.object({
|
|
5996
|
-
$ref: z.string()
|
|
5997
|
-
});
|
|
5998
|
-
var imageLayoutSchema = z.object({
|
|
5999
|
-
type: z.literal("image"),
|
|
6000
|
-
text: z.string().optional(),
|
|
6001
|
-
url: z.string(),
|
|
6002
|
-
size: sizeSchema.optional(),
|
|
6003
|
-
accessibilityDescription: z.string().optional(),
|
|
6004
|
-
control: z.string().optional(),
|
|
6005
|
-
margin: sizeSchema.optional()
|
|
6006
|
-
});
|
|
6007
|
-
var statusListLayoutStatusSchema = z.union([
|
|
6008
|
-
z.literal("not-done"),
|
|
6009
|
-
z.literal("pending"),
|
|
6010
|
-
z.literal("done")
|
|
6011
|
-
]);
|
|
6012
|
-
var instructionsLayoutItemSchema = z.object({
|
|
6013
|
-
text: z.string(),
|
|
6014
|
-
context: contextSchema
|
|
6015
|
-
});
|
|
6016
|
-
var modalLayoutTriggerSchema = z.object({
|
|
6017
|
-
title: z.string()
|
|
6018
|
-
});
|
|
6019
|
-
var searchLayoutSchema = z.object({
|
|
6020
|
-
type: z.literal("search"),
|
|
6021
|
-
title: z.string(),
|
|
6022
|
-
method: httpMethodSchema,
|
|
6023
|
-
url: z.string(),
|
|
6024
|
-
param: z.string(),
|
|
6025
|
-
emptyMessage: z.string().optional(),
|
|
6026
|
-
control: z.string().optional(),
|
|
6027
|
-
margin: sizeSchema.optional()
|
|
6028
|
-
});
|
|
6029
|
-
var infoLayoutSchema = z.object({
|
|
6030
|
-
type: z.literal("info"),
|
|
6031
|
-
markdown: z.string(),
|
|
6032
|
-
align: alignSchema.optional(),
|
|
6033
|
-
control: z.string().optional(),
|
|
6034
|
-
margin: sizeSchema.optional()
|
|
6035
|
-
});
|
|
6036
|
-
var formLayoutSchema = z.object({
|
|
6037
|
-
type: z.literal("form"),
|
|
6038
|
-
schema: formLayoutSchemaReferenceSchema.optional(),
|
|
6039
|
-
schemaId: z.string(),
|
|
6040
|
-
control: z.string().optional(),
|
|
6041
|
-
margin: sizeSchema.optional()
|
|
6042
|
-
});
|
|
6043
|
-
var headingLayoutSchema = z.object({
|
|
6044
|
-
type: z.literal("heading"),
|
|
6045
|
-
text: z.string(),
|
|
6046
|
-
size: sizeSchema.optional(),
|
|
6047
|
-
align: alignSchema.optional(),
|
|
6048
|
-
control: z.string().optional(),
|
|
6049
|
-
margin: sizeSchema.optional()
|
|
6050
|
-
});
|
|
6051
|
-
var markdownLayoutSchema = z.object({
|
|
6052
|
-
type: z.literal("markdown"),
|
|
6053
|
-
content: z.string(),
|
|
6054
|
-
align: alignSchema.optional(),
|
|
6055
|
-
control: z.string().optional(),
|
|
6056
|
-
margin: sizeSchema.optional()
|
|
6057
|
-
});
|
|
6058
|
-
var columnsLayoutBiasSchema = z.union([
|
|
6059
|
-
z.literal("none"),
|
|
6060
|
-
z.literal("left"),
|
|
6061
|
-
z.literal("right")
|
|
6053
|
+
var stringSchemaFormatSchema = z.union([
|
|
6054
|
+
z.literal("date"),
|
|
6055
|
+
z.literal("email"),
|
|
6056
|
+
z.literal("numeric"),
|
|
6057
|
+
z.literal("password"),
|
|
6058
|
+
z.literal("phone-number"),
|
|
6059
|
+
z.literal("base64url")
|
|
6062
6060
|
]);
|
|
6063
|
-
var helpSchema = z.object({
|
|
6064
|
-
markdown: z.string()
|
|
6065
|
-
});
|
|
6066
|
-
var searchSearchRequestSchema = z.object({
|
|
6067
|
-
url: z.string(),
|
|
6068
|
-
method: httpMethodSchema,
|
|
6069
|
-
param: z.string(),
|
|
6070
|
-
query: z.string()
|
|
6071
|
-
});
|
|
6072
6061
|
var jsonElementSchema = z.lazy(
|
|
6073
6062
|
() => z.union([
|
|
6074
6063
|
z.string(),
|
|
@@ -6078,6 +6067,7 @@ var jsonElementSchema = z.lazy(
|
|
|
6078
6067
|
z.array(jsonElementSchema)
|
|
6079
6068
|
]).nullable()
|
|
6080
6069
|
);
|
|
6070
|
+
var uploadSourceSchema = z.union([z.literal("camera"), z.literal("file")]);
|
|
6081
6071
|
var externalSchema = z.object({
|
|
6082
6072
|
url: z.string()
|
|
6083
6073
|
});
|
|
@@ -6085,42 +6075,28 @@ var stepErrorSchema = z.object({
|
|
|
6085
6075
|
error: z.string().optional(),
|
|
6086
6076
|
validation: jsonElementSchema.optional()
|
|
6087
6077
|
});
|
|
6088
|
-
var
|
|
6089
|
-
z.
|
|
6090
|
-
z.
|
|
6091
|
-
z.
|
|
6092
|
-
|
|
6093
|
-
z.
|
|
6094
|
-
z.literal("base64url")
|
|
6095
|
-
]);
|
|
6096
|
-
var summarySummariserSchema = z.object({
|
|
6097
|
-
defaultTitle: z.string().optional(),
|
|
6098
|
-
defaultDescription: z.string().optional(),
|
|
6099
|
-
defaultIcon: iconSchema.optional(),
|
|
6100
|
-
defaultImage: imageLayoutSchema.optional(),
|
|
6101
|
-
providesTitle: z.boolean().optional(),
|
|
6102
|
-
providesDescription: z.boolean().optional(),
|
|
6103
|
-
providesIcon: z.boolean().optional(),
|
|
6104
|
-
providesImage: z.boolean().optional()
|
|
6078
|
+
var errorResponseBodySchema = z.object({
|
|
6079
|
+
refreshFormUrl: z.string().optional(),
|
|
6080
|
+
analytics: z.record(z.string()).optional(),
|
|
6081
|
+
error: z.string().optional(),
|
|
6082
|
+
validation: jsonElementSchema.optional(),
|
|
6083
|
+
refreshUrl: z.string().optional()
|
|
6105
6084
|
});
|
|
6106
|
-
var
|
|
6107
|
-
|
|
6085
|
+
var searchSearchRequestSchema = z.object({
|
|
6086
|
+
url: z.string(),
|
|
6108
6087
|
method: httpMethodSchema,
|
|
6109
|
-
|
|
6110
|
-
|
|
6111
|
-
var summaryProviderSchema = z.object({
|
|
6112
|
-
providesTitle: z.boolean().optional(),
|
|
6113
|
-
providesDescription: z.boolean().optional(),
|
|
6114
|
-
providesIcon: z.boolean().optional(),
|
|
6115
|
-
providesImage: z.boolean().optional()
|
|
6088
|
+
param: z.string(),
|
|
6089
|
+
query: z.string()
|
|
6116
6090
|
});
|
|
6117
|
-
var uploadSourceSchema = z.union([z.literal("camera"), z.literal("file")]);
|
|
6118
6091
|
var navigationStackBehaviorSchema = z.union([
|
|
6119
6092
|
z.literal("default"),
|
|
6120
6093
|
z.literal("remove-previous"),
|
|
6121
6094
|
z.literal("remove-all"),
|
|
6122
6095
|
z.literal("replace-current")
|
|
6123
6096
|
]);
|
|
6097
|
+
var linkSchema = z.object({
|
|
6098
|
+
url: z.string()
|
|
6099
|
+
});
|
|
6124
6100
|
var actionTypeSchema = z.union([
|
|
6125
6101
|
z.literal("primary"),
|
|
6126
6102
|
z.literal("secondary"),
|
|
@@ -6128,9 +6104,11 @@ var actionTypeSchema = z.union([
|
|
|
6128
6104
|
z.literal("positive"),
|
|
6129
6105
|
z.literal("negative")
|
|
6130
6106
|
]);
|
|
6131
|
-
var
|
|
6132
|
-
|
|
6133
|
-
|
|
6107
|
+
var iconNamedSchema = z.object({
|
|
6108
|
+
name: z.string()
|
|
6109
|
+
});
|
|
6110
|
+
var iconTextSchema = z.object({
|
|
6111
|
+
text: z.string()
|
|
6134
6112
|
});
|
|
6135
6113
|
var actionSchema = z.object({
|
|
6136
6114
|
title: z.string().optional(),
|
|
@@ -6147,19 +6125,26 @@ var actionSchema = z.object({
|
|
|
6147
6125
|
timeout: z.number().optional(),
|
|
6148
6126
|
skipValidation: z.boolean().optional()
|
|
6149
6127
|
});
|
|
6150
|
-
var
|
|
6128
|
+
var markdownLayoutSchema = z.object({
|
|
6129
|
+
type: z.literal("markdown"),
|
|
6130
|
+
content: z.string(),
|
|
6131
|
+
align: alignSchema.optional(),
|
|
6132
|
+
control: z.string().optional(),
|
|
6133
|
+
margin: sizeSchema.optional()
|
|
6134
|
+
});
|
|
6135
|
+
var searchLayoutSchema = z.object({
|
|
6136
|
+
type: z.literal("search"),
|
|
6151
6137
|
title: z.string(),
|
|
6152
|
-
|
|
6153
|
-
|
|
6154
|
-
|
|
6138
|
+
method: httpMethodSchema,
|
|
6139
|
+
url: z.string(),
|
|
6140
|
+
param: z.string(),
|
|
6141
|
+
emptyMessage: z.string().optional(),
|
|
6142
|
+
control: z.string().optional(),
|
|
6143
|
+
margin: sizeSchema.optional()
|
|
6155
6144
|
});
|
|
6156
|
-
var
|
|
6157
|
-
action: actionSchema,
|
|
6145
|
+
var reviewLayoutCallToActionSchema = z.object({
|
|
6158
6146
|
title: z.string(),
|
|
6159
|
-
|
|
6160
|
-
disabled: z.boolean().optional(),
|
|
6161
|
-
icon: iconSchema.optional(),
|
|
6162
|
-
image: imageLayoutSchema.optional()
|
|
6147
|
+
action: actionSchema
|
|
6163
6148
|
});
|
|
6164
6149
|
var instructionsLayoutSchema = z.object({
|
|
6165
6150
|
type: z.literal("instructions"),
|
|
@@ -6168,26 +6153,38 @@ var instructionsLayoutSchema = z.object({
|
|
|
6168
6153
|
control: z.string().optional(),
|
|
6169
6154
|
margin: sizeSchema.optional()
|
|
6170
6155
|
});
|
|
6156
|
+
var iconSchema = z.union([iconNamedSchema, iconTextSchema]);
|
|
6171
6157
|
var behaviorSchema = z.object({
|
|
6172
6158
|
action: actionSchema.optional(),
|
|
6173
6159
|
link: linkSchema.optional()
|
|
6174
6160
|
});
|
|
6175
|
-
var buttonLayoutSchema = z.object({
|
|
6176
|
-
type: z.literal("button"),
|
|
6177
|
-
size: sizeSchema.optional(),
|
|
6178
|
-
title: z.string().optional(),
|
|
6179
|
-
action: actionSchema,
|
|
6180
|
-
context: contextSchema.optional(),
|
|
6181
|
-
disabled: z.boolean().optional(),
|
|
6182
|
-
pinOrder: z.number().optional(),
|
|
6183
|
-
control: z.string().optional(),
|
|
6184
|
-
margin: sizeSchema.optional()
|
|
6185
|
-
});
|
|
6186
6161
|
var reviewLayoutFieldSchema = z.object({
|
|
6187
6162
|
label: z.string(),
|
|
6188
6163
|
value: z.string(),
|
|
6189
6164
|
help: helpSchema.optional()
|
|
6190
6165
|
});
|
|
6166
|
+
var alertLayoutCallToActionSchema = z.object({
|
|
6167
|
+
title: z.string(),
|
|
6168
|
+
accessibilityDescription: z.string().optional(),
|
|
6169
|
+
behavior: behaviorSchema
|
|
6170
|
+
});
|
|
6171
|
+
var summarySummariserSchema = z.object({
|
|
6172
|
+
defaultTitle: z.string().optional(),
|
|
6173
|
+
defaultDescription: z.string().optional(),
|
|
6174
|
+
defaultIcon: iconSchema.optional(),
|
|
6175
|
+
defaultImage: imageLayoutSchema.optional(),
|
|
6176
|
+
providesTitle: z.boolean().optional(),
|
|
6177
|
+
providesDescription: z.boolean().optional(),
|
|
6178
|
+
providesIcon: z.boolean().optional(),
|
|
6179
|
+
providesImage: z.boolean().optional()
|
|
6180
|
+
});
|
|
6181
|
+
var linkHandlerSchema = z.object({
|
|
6182
|
+
regexPattern: z.string(),
|
|
6183
|
+
action: actionSchema
|
|
6184
|
+
});
|
|
6185
|
+
var actionResponseBodySchema = z.object({
|
|
6186
|
+
action: actionSchema
|
|
6187
|
+
});
|
|
6191
6188
|
var searchResultSearchSchema = z.object({
|
|
6192
6189
|
type: z.literal("search"),
|
|
6193
6190
|
title: z.string(),
|
|
@@ -6204,20 +6201,6 @@ var searchResultActionSchema = z.object({
|
|
|
6204
6201
|
image: imageLayoutSchema.optional(),
|
|
6205
6202
|
value: actionSchema
|
|
6206
6203
|
});
|
|
6207
|
-
var actionResponseBodySchema = z.object({
|
|
6208
|
-
action: actionSchema
|
|
6209
|
-
});
|
|
6210
|
-
var errorResponseBodySchema = z.object({
|
|
6211
|
-
refreshFormUrl: z.string().optional(),
|
|
6212
|
-
analytics: z.record(z.string()).optional(),
|
|
6213
|
-
error: z.string().optional(),
|
|
6214
|
-
validation: jsonElementSchema.optional(),
|
|
6215
|
-
refreshUrl: z.string().optional()
|
|
6216
|
-
});
|
|
6217
|
-
var linkHandlerSchema = z.object({
|
|
6218
|
-
regexPattern: z.string(),
|
|
6219
|
-
action: actionSchema
|
|
6220
|
-
});
|
|
6221
6204
|
var pollingOnErrorSchema = z.object({
|
|
6222
6205
|
action: actionSchema
|
|
6223
6206
|
});
|
|
@@ -6225,57 +6208,25 @@ var navigationBackBehaviorSchema = z.object({
|
|
|
6225
6208
|
title: z.string().optional(),
|
|
6226
6209
|
action: actionSchema
|
|
6227
6210
|
});
|
|
6228
|
-
var
|
|
6229
|
-
|
|
6230
|
-
|
|
6231
|
-
|
|
6232
|
-
var alertLayoutCallToActionSchema = z.object({
|
|
6233
|
-
title: z.string(),
|
|
6234
|
-
accessibilityDescription: z.string().optional(),
|
|
6235
|
-
behavior: behaviorSchema
|
|
6236
|
-
});
|
|
6237
|
-
var listLayoutSchema = z.object({
|
|
6238
|
-
type: z.literal("list"),
|
|
6239
|
-
items: z.array(listLayoutItemSchema),
|
|
6240
|
-
title: z.string().optional(),
|
|
6241
|
-
control: z.string().optional(),
|
|
6242
|
-
margin: sizeSchema.optional()
|
|
6243
|
-
});
|
|
6244
|
-
var decisionLayoutSchema = z.object({
|
|
6245
|
-
type: z.literal("decision"),
|
|
6246
|
-
title: z.string().optional(),
|
|
6247
|
-
options: z.array(decisionLayoutOptionSchema),
|
|
6248
|
-
control: z.string().optional(),
|
|
6249
|
-
margin: sizeSchema.optional()
|
|
6250
|
-
});
|
|
6251
|
-
var itemCallToActionSchema = z.object({
|
|
6252
|
-
title: z.string(),
|
|
6253
|
-
accessibilityDescription: z.string().optional(),
|
|
6254
|
-
behavior: behaviorSchema
|
|
6255
|
-
});
|
|
6256
|
-
var reviewLayoutSchema = z.object({
|
|
6257
|
-
type: z.literal("review"),
|
|
6258
|
-
orientation: z.string().optional(),
|
|
6259
|
-
action: actionSchema.optional(),
|
|
6260
|
-
fields: z.array(reviewLayoutFieldSchema),
|
|
6211
|
+
var summarySchema = z.union([summaryProviderSchema, summarySummariserSchema]);
|
|
6212
|
+
var buttonLayoutSchema = z.object({
|
|
6213
|
+
type: z.literal("button"),
|
|
6214
|
+
size: sizeSchema.optional(),
|
|
6261
6215
|
title: z.string().optional(),
|
|
6262
|
-
|
|
6216
|
+
action: actionSchema,
|
|
6217
|
+
context: contextSchema.optional(),
|
|
6218
|
+
disabled: z.boolean().optional(),
|
|
6219
|
+
pinOrder: z.number().optional(),
|
|
6263
6220
|
control: z.string().optional(),
|
|
6264
6221
|
margin: sizeSchema.optional()
|
|
6265
6222
|
});
|
|
6266
|
-
var
|
|
6267
|
-
|
|
6268
|
-
|
|
6269
|
-
|
|
6270
|
-
|
|
6271
|
-
|
|
6272
|
-
|
|
6273
|
-
onError: pollingOnErrorSchema
|
|
6274
|
-
});
|
|
6275
|
-
var navigationSchema = z.object({
|
|
6276
|
-
backButton: navigationBackBehaviorSchema.optional(),
|
|
6277
|
-
back: navigationBackBehaviorSchema.optional(),
|
|
6278
|
-
stackBehavior: navigationStackBehaviorSchema.optional()
|
|
6223
|
+
var decisionLayoutOptionSchema = z.object({
|
|
6224
|
+
action: actionSchema,
|
|
6225
|
+
title: z.string(),
|
|
6226
|
+
description: z.string().optional(),
|
|
6227
|
+
disabled: z.boolean().optional(),
|
|
6228
|
+
icon: iconSchema.optional(),
|
|
6229
|
+
image: imageLayoutSchema.optional()
|
|
6279
6230
|
});
|
|
6280
6231
|
var alertLayoutSchema = z.object({
|
|
6281
6232
|
type: z.literal("alert"),
|
|
@@ -6285,6 +6236,27 @@ var alertLayoutSchema = z.object({
|
|
|
6285
6236
|
margin: sizeSchema.optional(),
|
|
6286
6237
|
callToAction: alertLayoutCallToActionSchema.optional()
|
|
6287
6238
|
});
|
|
6239
|
+
var reviewLayoutSchema = z.object({
|
|
6240
|
+
type: z.literal("review"),
|
|
6241
|
+
orientation: z.string().optional(),
|
|
6242
|
+
action: actionSchema.optional(),
|
|
6243
|
+
fields: z.array(reviewLayoutFieldSchema),
|
|
6244
|
+
title: z.string().optional(),
|
|
6245
|
+
callToAction: reviewLayoutCallToActionSchema.optional(),
|
|
6246
|
+
control: z.string().optional(),
|
|
6247
|
+
margin: sizeSchema.optional()
|
|
6248
|
+
});
|
|
6249
|
+
var listLayoutItemSchema = z.object({
|
|
6250
|
+
title: z.string(),
|
|
6251
|
+
description: z.string().optional(),
|
|
6252
|
+
icon: iconSchema,
|
|
6253
|
+
status: listLayoutStatusSchema.optional()
|
|
6254
|
+
});
|
|
6255
|
+
var itemCallToActionSchema = z.object({
|
|
6256
|
+
title: z.string(),
|
|
6257
|
+
accessibilityDescription: z.string().optional(),
|
|
6258
|
+
behavior: behaviorSchema
|
|
6259
|
+
});
|
|
6288
6260
|
var statusListLayoutItemSchema = z.object({
|
|
6289
6261
|
title: z.string(),
|
|
6290
6262
|
description: z.string().optional(),
|
|
@@ -6292,9 +6264,6 @@ var statusListLayoutItemSchema = z.object({
|
|
|
6292
6264
|
status: statusListLayoutStatusSchema.optional(),
|
|
6293
6265
|
callToAction: itemCallToActionSchema.optional()
|
|
6294
6266
|
});
|
|
6295
|
-
var searchResponseBodySchema = z.object({
|
|
6296
|
-
results: z.array(searchResultSchema)
|
|
6297
|
-
});
|
|
6298
6267
|
var blobSchemaSchema = z.object({
|
|
6299
6268
|
type: z.literal("blob"),
|
|
6300
6269
|
promoted: z.boolean().optional(),
|
|
@@ -6333,6 +6302,34 @@ var constSchemaSchema = z.object({
|
|
|
6333
6302
|
analyticsId: z.string().optional(),
|
|
6334
6303
|
disabled: z.boolean().optional()
|
|
6335
6304
|
});
|
|
6305
|
+
var pollingSchema = z.object({
|
|
6306
|
+
url: z.string(),
|
|
6307
|
+
interval: z.number().optional(),
|
|
6308
|
+
delay: z.number().optional(),
|
|
6309
|
+
timeout: z.number().optional(),
|
|
6310
|
+
maxAttempts: z.number(),
|
|
6311
|
+
onError: pollingOnErrorSchema
|
|
6312
|
+
});
|
|
6313
|
+
var navigationSchema = z.object({
|
|
6314
|
+
backButton: navigationBackBehaviorSchema.optional(),
|
|
6315
|
+
back: navigationBackBehaviorSchema.optional(),
|
|
6316
|
+
stackBehavior: navigationStackBehaviorSchema.optional()
|
|
6317
|
+
});
|
|
6318
|
+
var searchResultSchema = z.union([searchResultActionSchema, searchResultSearchSchema]);
|
|
6319
|
+
var decisionLayoutSchema = z.object({
|
|
6320
|
+
type: z.literal("decision"),
|
|
6321
|
+
title: z.string().optional(),
|
|
6322
|
+
options: z.array(decisionLayoutOptionSchema),
|
|
6323
|
+
control: z.string().optional(),
|
|
6324
|
+
margin: sizeSchema.optional()
|
|
6325
|
+
});
|
|
6326
|
+
var listLayoutSchema = z.object({
|
|
6327
|
+
type: z.literal("list"),
|
|
6328
|
+
items: z.array(listLayoutItemSchema),
|
|
6329
|
+
title: z.string().optional(),
|
|
6330
|
+
control: z.string().optional(),
|
|
6331
|
+
margin: sizeSchema.optional()
|
|
6332
|
+
});
|
|
6336
6333
|
var statusListLayoutSchema = z.object({
|
|
6337
6334
|
type: z.literal("status-list"),
|
|
6338
6335
|
items: z.array(statusListLayoutItemSchema),
|
|
@@ -6340,6 +6337,19 @@ var statusListLayoutSchema = z.object({
|
|
|
6340
6337
|
control: z.string().optional(),
|
|
6341
6338
|
margin: sizeSchema.optional()
|
|
6342
6339
|
});
|
|
6340
|
+
var searchResponseBodySchema = z.object({
|
|
6341
|
+
results: z.array(searchResultSchema)
|
|
6342
|
+
});
|
|
6343
|
+
var columnsLayoutSchema = z.lazy(
|
|
6344
|
+
() => z.object({
|
|
6345
|
+
type: z.literal("columns"),
|
|
6346
|
+
left: z.array(layoutSchema),
|
|
6347
|
+
right: z.array(layoutSchema),
|
|
6348
|
+
bias: columnsLayoutBiasSchema.optional(),
|
|
6349
|
+
control: z.string().optional(),
|
|
6350
|
+
margin: sizeSchema.optional()
|
|
6351
|
+
})
|
|
6352
|
+
);
|
|
6343
6353
|
var layoutSchema = z.lazy(
|
|
6344
6354
|
() => z.union([
|
|
6345
6355
|
alertLayoutSchema,
|
|
@@ -6363,26 +6373,6 @@ var layoutSchema = z.lazy(
|
|
|
6363
6373
|
statusListLayoutSchema
|
|
6364
6374
|
])
|
|
6365
6375
|
);
|
|
6366
|
-
var boxLayoutSchema = z.lazy(
|
|
6367
|
-
() => z.object({
|
|
6368
|
-
type: z.literal("box"),
|
|
6369
|
-
components: z.array(layoutSchema),
|
|
6370
|
-
width: sizeSchema.optional(),
|
|
6371
|
-
border: z.boolean().optional(),
|
|
6372
|
-
control: z.string().optional(),
|
|
6373
|
-
margin: sizeSchema.optional()
|
|
6374
|
-
})
|
|
6375
|
-
);
|
|
6376
|
-
var columnsLayoutSchema = z.lazy(
|
|
6377
|
-
() => z.object({
|
|
6378
|
-
type: z.literal("columns"),
|
|
6379
|
-
left: z.array(layoutSchema),
|
|
6380
|
-
right: z.array(layoutSchema),
|
|
6381
|
-
bias: columnsLayoutBiasSchema.optional(),
|
|
6382
|
-
control: z.string().optional(),
|
|
6383
|
-
margin: sizeSchema.optional()
|
|
6384
|
-
})
|
|
6385
|
-
);
|
|
6386
6376
|
var modalLayoutSchema = z.lazy(
|
|
6387
6377
|
() => z.object({
|
|
6388
6378
|
type: z.literal("modal"),
|
|
@@ -6398,25 +6388,14 @@ var modalLayoutContentSchema = z.lazy(
|
|
|
6398
6388
|
components: z.array(layoutSchema)
|
|
6399
6389
|
})
|
|
6400
6390
|
);
|
|
6401
|
-
var
|
|
6391
|
+
var boxLayoutSchema = z.lazy(
|
|
6402
6392
|
() => z.object({
|
|
6403
|
-
|
|
6404
|
-
|
|
6405
|
-
|
|
6406
|
-
|
|
6407
|
-
|
|
6408
|
-
|
|
6409
|
-
schemas: z.array(schemaSchema),
|
|
6410
|
-
layout: z.array(layoutSchema),
|
|
6411
|
-
description: z.string().optional(),
|
|
6412
|
-
model: jsonElementSchema.optional(),
|
|
6413
|
-
external: externalSchema.optional(),
|
|
6414
|
-
polling: pollingSchema.optional(),
|
|
6415
|
-
linkHandlers: z.array(linkHandlerSchema).optional(),
|
|
6416
|
-
analytics: z.record(z.string()).optional(),
|
|
6417
|
-
errors: stepErrorSchema.optional(),
|
|
6418
|
-
navigation: navigationSchema.optional(),
|
|
6419
|
-
refreshUrl: z.string().optional()
|
|
6393
|
+
type: z.literal("box"),
|
|
6394
|
+
components: z.array(layoutSchema),
|
|
6395
|
+
width: sizeSchema.optional(),
|
|
6396
|
+
border: z.boolean().optional(),
|
|
6397
|
+
control: z.string().optional(),
|
|
6398
|
+
margin: sizeSchema.optional()
|
|
6420
6399
|
})
|
|
6421
6400
|
);
|
|
6422
6401
|
var schemaSchema = z.lazy(
|
|
@@ -6642,17 +6621,21 @@ var stringSchemaSchema = z.lazy(
|
|
|
6642
6621
|
help: helpSchema.optional()
|
|
6643
6622
|
})
|
|
6644
6623
|
);
|
|
6645
|
-
var
|
|
6624
|
+
var persistAsyncSchema = z.lazy(
|
|
6625
|
+
() => z.object({
|
|
6626
|
+
param: z.string(),
|
|
6627
|
+
idProperty: z.string(),
|
|
6628
|
+
schema: schemaSchema,
|
|
6629
|
+
url: z.string(),
|
|
6630
|
+
method: httpMethodSchema
|
|
6631
|
+
})
|
|
6632
|
+
);
|
|
6633
|
+
var arraySchemaTupleSchema = z.lazy(
|
|
6646
6634
|
() => z.object({
|
|
6647
6635
|
type: z.literal("array"),
|
|
6648
6636
|
promoted: z.boolean().optional(),
|
|
6649
6637
|
$id: z.string().optional(),
|
|
6650
|
-
items: schemaSchema,
|
|
6651
|
-
addItemTitle: z.string(),
|
|
6652
|
-
editItemTitle: z.string(),
|
|
6653
|
-
minItems: z.number().optional(),
|
|
6654
|
-
maxItems: z.number().optional(),
|
|
6655
|
-
placeholder: z.string().optional(),
|
|
6638
|
+
items: z.array(schemaSchema),
|
|
6656
6639
|
title: z.string().optional(),
|
|
6657
6640
|
description: z.string().optional(),
|
|
6658
6641
|
control: z.string().optional(),
|
|
@@ -6660,30 +6643,24 @@ var arraySchemaListSchema = z.lazy(
|
|
|
6660
6643
|
icon: iconSchema.optional(),
|
|
6661
6644
|
image: imageSchema.optional(),
|
|
6662
6645
|
keywords: z.array(z.string()).optional(),
|
|
6663
|
-
summary:
|
|
6646
|
+
summary: summaryProviderSchema.optional(),
|
|
6664
6647
|
analyticsId: z.string().optional(),
|
|
6665
6648
|
persistAsync: persistAsyncSchema.optional(),
|
|
6666
6649
|
validationAsync: validateAsyncSchema.optional(),
|
|
6667
|
-
alert: alertLayoutSchema.optional()
|
|
6668
|
-
validationMessages: z.record(z.string()).optional(),
|
|
6669
|
-
disabled: z.boolean().optional()
|
|
6670
|
-
})
|
|
6671
|
-
);
|
|
6672
|
-
var persistAsyncSchema = z.lazy(
|
|
6673
|
-
() => z.object({
|
|
6674
|
-
param: z.string(),
|
|
6675
|
-
idProperty: z.string(),
|
|
6676
|
-
schema: schemaSchema,
|
|
6677
|
-
url: z.string(),
|
|
6678
|
-
method: httpMethodSchema
|
|
6650
|
+
alert: alertLayoutSchema.optional()
|
|
6679
6651
|
})
|
|
6680
6652
|
);
|
|
6681
|
-
var
|
|
6653
|
+
var arraySchemaListSchema = z.lazy(
|
|
6682
6654
|
() => z.object({
|
|
6683
6655
|
type: z.literal("array"),
|
|
6684
6656
|
promoted: z.boolean().optional(),
|
|
6685
6657
|
$id: z.string().optional(),
|
|
6686
|
-
items:
|
|
6658
|
+
items: schemaSchema,
|
|
6659
|
+
addItemTitle: z.string(),
|
|
6660
|
+
editItemTitle: z.string(),
|
|
6661
|
+
minItems: z.number().optional(),
|
|
6662
|
+
maxItems: z.number().optional(),
|
|
6663
|
+
placeholder: z.string().optional(),
|
|
6687
6664
|
title: z.string().optional(),
|
|
6688
6665
|
description: z.string().optional(),
|
|
6689
6666
|
control: z.string().optional(),
|
|
@@ -6691,11 +6668,34 @@ var arraySchemaTupleSchema = z.lazy(
|
|
|
6691
6668
|
icon: iconSchema.optional(),
|
|
6692
6669
|
image: imageSchema.optional(),
|
|
6693
6670
|
keywords: z.array(z.string()).optional(),
|
|
6694
|
-
summary:
|
|
6671
|
+
summary: summarySummariserSchema.optional(),
|
|
6695
6672
|
analyticsId: z.string().optional(),
|
|
6696
6673
|
persistAsync: persistAsyncSchema.optional(),
|
|
6697
6674
|
validationAsync: validateAsyncSchema.optional(),
|
|
6698
|
-
alert: alertLayoutSchema.optional()
|
|
6675
|
+
alert: alertLayoutSchema.optional(),
|
|
6676
|
+
validationMessages: z.record(z.string()).optional(),
|
|
6677
|
+
disabled: z.boolean().optional()
|
|
6678
|
+
})
|
|
6679
|
+
);
|
|
6680
|
+
var stepSchema = z.lazy(
|
|
6681
|
+
() => z.object({
|
|
6682
|
+
key: z.string().optional(),
|
|
6683
|
+
type: z.string().optional(),
|
|
6684
|
+
actions: z.array(actionSchema).optional(),
|
|
6685
|
+
refreshFormUrl: z.string().optional(),
|
|
6686
|
+
id: z.string(),
|
|
6687
|
+
title: z.string(),
|
|
6688
|
+
schemas: z.array(schemaSchema),
|
|
6689
|
+
layout: z.array(layoutSchema),
|
|
6690
|
+
description: z.string().optional(),
|
|
6691
|
+
model: jsonElementSchema.optional(),
|
|
6692
|
+
external: externalSchema.optional(),
|
|
6693
|
+
polling: pollingSchema.optional(),
|
|
6694
|
+
linkHandlers: z.array(linkHandlerSchema).optional(),
|
|
6695
|
+
analytics: z.record(z.string()).optional(),
|
|
6696
|
+
errors: stepErrorSchema.optional(),
|
|
6697
|
+
navigation: navigationSchema.optional(),
|
|
6698
|
+
refreshUrl: z.string().optional()
|
|
6699
6699
|
})
|
|
6700
6700
|
);
|
|
6701
6701
|
var validateStep = (step) => validate(step, stepSchema);
|
|
@@ -15860,6 +15860,102 @@ function RepeatableSchemaStep({
|
|
|
15860
15860
|
}
|
|
15861
15861
|
var RepeatableSchemaStep_default = RepeatableSchemaStep;
|
|
15862
15862
|
|
|
15863
|
+
// src/legacy/common/validators/schemas/one-of-preselection.ts
|
|
15864
|
+
function isValidStringSchema2(value, schema) {
|
|
15865
|
+
return !getStringValidationFailures(value, schema).length;
|
|
15866
|
+
}
|
|
15867
|
+
function isValidNumberSchema2(value, schema) {
|
|
15868
|
+
return !getNumberValidationFailures(value, schema).length;
|
|
15869
|
+
}
|
|
15870
|
+
function isValidIntegerSchema2(value, schema) {
|
|
15871
|
+
return !getIntegerValidationFailures(value, schema).length;
|
|
15872
|
+
}
|
|
15873
|
+
function isValidBooleanSchema2(value, schema) {
|
|
15874
|
+
return !getBooleanValidationFailures(value, schema).length;
|
|
15875
|
+
}
|
|
15876
|
+
function isValidConstSchema2(value, schema) {
|
|
15877
|
+
return !getConstValidationFailures(value, schema).length;
|
|
15878
|
+
}
|
|
15879
|
+
function isValidObjectSchema2(value, schema) {
|
|
15880
|
+
if (!isObject2(value) || schema.type !== "object" || !isObject2(schema.properties)) {
|
|
15881
|
+
return false;
|
|
15882
|
+
}
|
|
15883
|
+
const checks = Object.keys(schema.properties).map((propertyName) => {
|
|
15884
|
+
if (value[propertyName] === void 0) {
|
|
15885
|
+
return null;
|
|
15886
|
+
}
|
|
15887
|
+
return isObjectPropertyValid2(
|
|
15888
|
+
value[propertyName],
|
|
15889
|
+
schema.properties[propertyName],
|
|
15890
|
+
schema.required && schema.required.includes(propertyName)
|
|
15891
|
+
);
|
|
15892
|
+
});
|
|
15893
|
+
return !checks.some((check) => check === false) && checks.some((check) => check === true);
|
|
15894
|
+
}
|
|
15895
|
+
function isObjectPropertyValid2(propertyValue, propertySchema, isRequired) {
|
|
15896
|
+
if (propertySchema.hidden) {
|
|
15897
|
+
return true;
|
|
15898
|
+
}
|
|
15899
|
+
if (typeof propertyValue === "undefined") {
|
|
15900
|
+
return !isRequired;
|
|
15901
|
+
}
|
|
15902
|
+
return isValidSchemaForPreselection(propertyValue, propertySchema);
|
|
15903
|
+
}
|
|
15904
|
+
function isValidArraySchema2(value, schema) {
|
|
15905
|
+
if (schema.type !== "array" || !isObject2(schema.items)) {
|
|
15906
|
+
return false;
|
|
15907
|
+
}
|
|
15908
|
+
if (getArrayValidationFailures(value, schema).length > 0) {
|
|
15909
|
+
return false;
|
|
15910
|
+
}
|
|
15911
|
+
return Array.isArray(value) && isListArraySchema(schema) && // TupleArraySchema not yet supported
|
|
15912
|
+
value.map((item) => isValidSchemaForPreselection(item, schema.items)).every((valid) => valid);
|
|
15913
|
+
}
|
|
15914
|
+
function isValidOneOfSchema2(value, schema) {
|
|
15915
|
+
if (!isArray2(schema.oneOf)) {
|
|
15916
|
+
return false;
|
|
15917
|
+
}
|
|
15918
|
+
return schema.oneOf.some((childSchema) => isValidSchemaForPreselection(value, childSchema));
|
|
15919
|
+
}
|
|
15920
|
+
function isValidAllOfSchema2(value, schema) {
|
|
15921
|
+
if (!isArray2(schema.allOf)) {
|
|
15922
|
+
return false;
|
|
15923
|
+
}
|
|
15924
|
+
return schema.allOf.map((childSchema) => isValidSchemaForPreselection(value, childSchema)).every((valid) => valid);
|
|
15925
|
+
}
|
|
15926
|
+
function isValidBlobSchema2(value, schema) {
|
|
15927
|
+
return !getBlobValidationFailures(value, schema).length;
|
|
15928
|
+
}
|
|
15929
|
+
function isValidSchemaForPreselection(value, schema) {
|
|
15930
|
+
if (schema.oneOf) {
|
|
15931
|
+
return isValidOneOfSchema2(value, schema);
|
|
15932
|
+
}
|
|
15933
|
+
if (schema.allOf) {
|
|
15934
|
+
return isValidAllOfSchema2(value, schema);
|
|
15935
|
+
}
|
|
15936
|
+
if (schema.const) {
|
|
15937
|
+
return isValidConstSchema2(value, schema);
|
|
15938
|
+
}
|
|
15939
|
+
switch (schema.type) {
|
|
15940
|
+
case "string":
|
|
15941
|
+
return isValidStringSchema2(value, schema);
|
|
15942
|
+
case "number":
|
|
15943
|
+
return isValidNumberSchema2(value, schema);
|
|
15944
|
+
case "integer":
|
|
15945
|
+
return isValidIntegerSchema2(value, schema);
|
|
15946
|
+
case "boolean":
|
|
15947
|
+
return isValidBooleanSchema2(value, schema);
|
|
15948
|
+
case "array":
|
|
15949
|
+
return isValidArraySchema2(value, schema);
|
|
15950
|
+
case "object":
|
|
15951
|
+
return isValidObjectSchema2(value, schema);
|
|
15952
|
+
case "blob":
|
|
15953
|
+
return isValidBlobSchema2(value, schema);
|
|
15954
|
+
default:
|
|
15955
|
+
return false;
|
|
15956
|
+
}
|
|
15957
|
+
}
|
|
15958
|
+
|
|
15863
15959
|
// src/legacy/jsonSchemaForm/oneOfSchema/utils.ts
|
|
15864
15960
|
var getActiveSchemaIndex = (schema, model) => {
|
|
15865
15961
|
const indexFromModel = getValidIndexFromValue(schema, model);
|
|
@@ -15881,8 +15977,18 @@ var getActiveSchemaIndex = (schema, model) => {
|
|
|
15881
15977
|
if (isOneOfObjectSchema(schema) && !isUndefined3(schema.default) && isObjectModel2(schema.default) && Object.keys(schema.default).length >= 1) {
|
|
15882
15978
|
return getBestMatchingSchemaIndexForValue(schema, schema.default);
|
|
15883
15979
|
}
|
|
15980
|
+
if (schema.oneOf.every((s) => isOneOfObjectSchema(s) || isObjectSchema2(s) || isAllOfSchema2(s)) && isObjectModel2(model) && Object.keys(model).length >= 1) {
|
|
15981
|
+
return getValidIndexFromValueForPreselection(schema, model);
|
|
15982
|
+
}
|
|
15884
15983
|
return null;
|
|
15885
15984
|
};
|
|
15985
|
+
var getValidIndexFromValueForPreselection = (schema, value) => {
|
|
15986
|
+
const predicate = (childSchema) => !isUndefined3(value) && isValidSchemaForPreselection(value, childSchema);
|
|
15987
|
+
if (schema.oneOf.filter(predicate).length === 1) {
|
|
15988
|
+
return schema.oneOf.findIndex(predicate);
|
|
15989
|
+
}
|
|
15990
|
+
return -1;
|
|
15991
|
+
};
|
|
15886
15992
|
var getValidIndexFromValue = (schema, value) => {
|
|
15887
15993
|
const predicate = (childSchema) => !isUndefined3(value) && isValidSchema(value, childSchema);
|
|
15888
15994
|
if (schema.oneOf.filter(predicate).length === 1) {
|