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