@wise/dynamic-flow-client 3.32.0 → 3.34.0

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
@@ -70,7 +70,7 @@ var require_classnames = __commonJS({
70
70
  (function() {
71
71
  "use strict";
72
72
  var hasOwn = {}.hasOwnProperty;
73
- function classNames16() {
73
+ function classNames17() {
74
74
  var classes = "";
75
75
  for (var i = 0; i < arguments.length; i++) {
76
76
  var arg = arguments[i];
@@ -88,7 +88,7 @@ var require_classnames = __commonJS({
88
88
  return "";
89
89
  }
90
90
  if (Array.isArray(arg)) {
91
- return classNames16.apply(null, arg);
91
+ return classNames17.apply(null, arg);
92
92
  }
93
93
  if (arg.toString !== Object.prototype.toString && !arg.toString.toString().includes("[native code]")) {
94
94
  return arg.toString();
@@ -111,14 +111,14 @@ var require_classnames = __commonJS({
111
111
  return value + newClass;
112
112
  }
113
113
  if (typeof module2 !== "undefined" && module2.exports) {
114
- classNames16.default = classNames16;
115
- module2.exports = classNames16;
114
+ classNames17.default = classNames17;
115
+ module2.exports = classNames17;
116
116
  } else if (typeof define === "function" && typeof define.amd === "object" && define.amd) {
117
117
  define("classnames", [], function() {
118
- return classNames16;
118
+ return classNames17;
119
119
  });
120
120
  } else {
121
- window.classNames = classNames16;
121
+ window.classNames = classNames17;
122
122
  }
123
123
  })();
124
124
  }
@@ -1519,7 +1519,7 @@ var mapErrorsToValidationState = (errors) => {
1519
1519
 
1520
1520
  // src/revamp/renderers/mappers/utils/inputComponentToProps.ts
1521
1521
  var inputComponentToProps = (component, type) => {
1522
- var _a;
1522
+ var _a, _b, _c, _d;
1523
1523
  const {
1524
1524
  autoComplete,
1525
1525
  control,
@@ -1548,7 +1548,11 @@ var inputComponentToProps = (component, type) => {
1548
1548
  help,
1549
1549
  icon,
1550
1550
  id,
1551
- image,
1551
+ image: image ? {
1552
+ accessibilityDescription: (_b = image.accessibilityDescription) != null ? _b : image.text,
1553
+ uri: image.uri,
1554
+ url: (_d = (_c = image.uri) != null ? _c : image.url) != null ? _d : ""
1555
+ } : void 0,
1552
1556
  label: title,
1553
1557
  placeholder,
1554
1558
  required,
@@ -1618,7 +1622,19 @@ var dateInputComponentToProps = (component) => __spreadProps(__spreadValues({},
1618
1622
  });
1619
1623
 
1620
1624
  // src/revamp/renderers/mappers/decisionComponentToProps.ts
1621
- var decisionComponentToProps = (component) => pick(component, "type", "control", "options", "margin", "title");
1625
+ var decisionComponentToProps = (component) => __spreadProps(__spreadValues({}, pick(component, "type", "control", "margin", "title")), {
1626
+ options: component.options.map((_a) => {
1627
+ var _b = _a, { image } = _b, rest = __objRest(_b, ["image"]);
1628
+ var _a2, _b2, _c;
1629
+ return __spreadProps(__spreadValues({}, rest), {
1630
+ image: image ? {
1631
+ accessibilityDescription: (_a2 = image.accessibilityDescription) != null ? _a2 : image.text,
1632
+ uri: image.uri,
1633
+ url: (_c = (_b2 = image.uri) != null ? _b2 : image.url) != null ? _c : ""
1634
+ } : image
1635
+ });
1636
+ })
1637
+ });
1622
1638
 
1623
1639
  // src/revamp/renderers/mappers/dividerComponentToProps.ts
1624
1640
  var dividerComponentToProps = (component) => pick(component, "type", "control", "margin");
@@ -1699,17 +1715,25 @@ var numberInputComponentToProps = (component) => __spreadProps(__spreadValues({}
1699
1715
  });
1700
1716
 
1701
1717
  // src/revamp/renderers/mappers/objectComponentToProps.ts
1702
- var objectComponentToProps = (component, children) => __spreadProps(__spreadValues({
1703
- type: "form-section"
1704
- }, pick(component, "control", "description", "help", "icon", "image", "title")), {
1705
- children
1706
- });
1718
+ var objectComponentToProps = (component, children) => {
1719
+ var _a, _b;
1720
+ return __spreadProps(__spreadValues({
1721
+ type: "form-section"
1722
+ }, pick(component, "control", "description", "help", "icon", "title")), {
1723
+ // TODO: Remove when viewbindings are updated
1724
+ image: component.image ? __spreadProps(__spreadValues({}, component.image), {
1725
+ url: (_b = (_a = component.image) == null ? void 0 : _a.url) != null ? _b : ""
1726
+ }) : void 0,
1727
+ children
1728
+ });
1729
+ };
1707
1730
 
1708
1731
  // src/revamp/renderers/mappers/paragraphComponentToProps.ts
1709
1732
  var paragraphComponentToProps = (component) => pick(component, "type", "align", "control", "margin", "text");
1710
1733
 
1711
1734
  // src/revamp/renderers/mappers/repeatableComponentToProps.ts
1712
1735
  var repeatableComponentToProps = (component, children, editableItemChildren) => {
1736
+ var _a, _b;
1713
1737
  const {
1714
1738
  addItemTitle,
1715
1739
  control,
@@ -1728,13 +1752,26 @@ var repeatableComponentToProps = (component, children, editableItemChildren) =>
1728
1752
  onSave,
1729
1753
  onRemove
1730
1754
  } = component;
1755
+ const getSummaryImage = (componentSummary) => {
1756
+ var _a2, _b2;
1757
+ if (componentSummary.image) {
1758
+ return __spreadProps(__spreadValues({}, componentSummary.image), {
1759
+ url: (_a2 = componentSummary.image.url) != null ? _a2 : ""
1760
+ });
1761
+ }
1762
+ if (summaryDefaults.image) {
1763
+ return __spreadProps(__spreadValues({}, summaryDefaults.image), {
1764
+ url: (_b2 = summaryDefaults.image.url) != null ? _b2 : ""
1765
+ });
1766
+ }
1767
+ };
1731
1768
  const getSummary = (componentSummary) => {
1732
- var _a, _b, _c, _d;
1769
+ var _a2, _b2, _c;
1733
1770
  return {
1734
- title: (_a = componentSummary.title) != null ? _a : summaryDefaults.title,
1735
- description: (_b = componentSummary.description) != null ? _b : summaryDefaults.description,
1771
+ title: (_a2 = componentSummary.title) != null ? _a2 : summaryDefaults.title,
1772
+ description: (_b2 = componentSummary.description) != null ? _b2 : summaryDefaults.description,
1736
1773
  icon: (_c = componentSummary.icon) != null ? _c : summaryDefaults.icon,
1737
- image: (_d = componentSummary.image) != null ? _d : summaryDefaults.image
1774
+ image: getSummaryImage(componentSummary)
1738
1775
  };
1739
1776
  };
1740
1777
  const itemProps = components.map((childComponent) => __spreadProps(__spreadValues({}, getSummary(childComponent.getSummary())), {
@@ -1750,7 +1787,11 @@ var repeatableComponentToProps = (component, children, editableItemChildren) =>
1750
1787
  editItemTitle,
1751
1788
  error: errors == null ? void 0 : errors[0],
1752
1789
  icon,
1753
- image,
1790
+ image: image ? {
1791
+ accessibilityDescription: (_a = image.accessibilityDescription) != null ? _a : image.text,
1792
+ uri: image.uri,
1793
+ url: (_b = image.url) != null ? _b : ""
1794
+ } : void 0,
1754
1795
  items: itemProps,
1755
1796
  maxItems,
1756
1797
  minItems,
@@ -1868,10 +1909,32 @@ var uploadInputComponentToProps = (component) => {
1868
1909
  };
1869
1910
 
1870
1911
  // src/revamp/renderers/mappers/tupleComponentToProps.ts
1871
- var tupleComponentToProps = (component, children) => __spreadProps(__spreadValues({
1872
- type: "form-section"
1873
- }, pick(component, "control", "description", "help", "icon", "image", "title")), {
1874
- children
1912
+ var tupleComponentToProps = (component, children) => {
1913
+ var _a, _b;
1914
+ return __spreadProps(__spreadValues({
1915
+ type: "form-section"
1916
+ }, pick(component, "control", "description", "help", "icon", "title")), {
1917
+ // TODO Remove URL default after next types update (add back to `pick`)
1918
+ image: component.image ? __spreadProps(__spreadValues({}, component.image), {
1919
+ url: (_b = (_a = component.image) == null ? void 0 : _a.url) != null ? _b : ""
1920
+ }) : void 0,
1921
+ children
1922
+ });
1923
+ };
1924
+
1925
+ // src/revamp/renderers/mappers/listComponentToProps.ts
1926
+ var listComponentToProps = (component) => __spreadProps(__spreadValues({}, pick(component, "type", "callToAction", "control", "margin", "title")), {
1927
+ items: component.items.map((_a) => {
1928
+ var _b = _a, { image } = _b, rest = __objRest(_b, ["image"]);
1929
+ var _a2, _b2, _c;
1930
+ return __spreadProps(__spreadValues({}, rest), {
1931
+ image: image ? {
1932
+ accessibilityDescription: (_a2 = image == null ? void 0 : image.accessibilityDescription) != null ? _a2 : image == null ? void 0 : image.text,
1933
+ uri: image == null ? void 0 : image.uri,
1934
+ url: (_c = (_b2 = image == null ? void 0 : image.url) != null ? _b2 : image == null ? void 0 : image.url) != null ? _c : ""
1935
+ } : void 0
1936
+ });
1937
+ })
1875
1938
  });
1876
1939
 
1877
1940
  // src/revamp/renderers/mappers/componentToRendererProps.ts
@@ -1915,6 +1978,8 @@ var componentToRendererProps = (component, nestedContent) => {
1915
1978
  return instructionsComponentToProps(component);
1916
1979
  case "integer":
1917
1980
  return integerInputComponentToProps(component);
1981
+ case "list":
1982
+ return listComponentToProps(component);
1918
1983
  case "loading-indicator":
1919
1984
  return loadingIndicatorComponentToProps(component);
1920
1985
  case "markdown":
@@ -6237,10 +6302,14 @@ var actionSchema = z.object({
6237
6302
  skipValidation: z.boolean().optional()
6238
6303
  });
6239
6304
  var listLayoutItemSchema = z.object({
6240
- title: z.string(),
6241
6305
  description: z.string().optional(),
6242
- icon: iconSchema,
6243
- status: listLayoutStatusSchema.optional()
6306
+ status: listLayoutStatusSchema.optional(),
6307
+ icon: iconSchema.optional(),
6308
+ image: imageSchema.optional(),
6309
+ title: z.string(),
6310
+ subtitle: z.string().optional(),
6311
+ value: z.string().optional(),
6312
+ subvalue: z.string().optional()
6244
6313
  });
6245
6314
  var decisionLayoutOptionSchema = z.object({
6246
6315
  action: actionSchema,
@@ -6261,6 +6330,11 @@ var behaviorSchema = z.object({
6261
6330
  action: actionSchema.optional(),
6262
6331
  link: linkSchema.optional()
6263
6332
  });
6333
+ var itemCallToActionSchema = z.object({
6334
+ title: z.string(),
6335
+ accessibilityDescription: z.string().optional(),
6336
+ behavior: behaviorSchema
6337
+ });
6264
6338
  var buttonLayoutSchema = z.object({
6265
6339
  type: z.literal("button"),
6266
6340
  size: sizeSchema.optional(),
@@ -6324,12 +6398,10 @@ var alertLayoutCallToActionSchema = z.object({
6324
6398
  accessibilityDescription: z.string().optional(),
6325
6399
  behavior: behaviorSchema
6326
6400
  });
6327
- var listLayoutSchema = z.object({
6328
- type: z.literal("list"),
6329
- items: z.array(listLayoutItemSchema),
6330
- title: z.string().optional(),
6331
- control: z.string().optional(),
6332
- margin: sizeSchema.optional()
6401
+ var listLayoutCallToActionSchema = z.object({
6402
+ title: z.string(),
6403
+ accessibilityDescription: z.string().optional(),
6404
+ behavior: behaviorSchema
6333
6405
  });
6334
6406
  var decisionLayoutSchema = z.object({
6335
6407
  type: z.literal("decision"),
@@ -6338,10 +6410,12 @@ var decisionLayoutSchema = z.object({
6338
6410
  control: z.string().optional(),
6339
6411
  margin: sizeSchema.optional()
6340
6412
  });
6341
- var itemCallToActionSchema = z.object({
6413
+ var statusListLayoutItemSchema = z.object({
6342
6414
  title: z.string(),
6343
- accessibilityDescription: z.string().optional(),
6344
- behavior: behaviorSchema
6415
+ description: z.string().optional(),
6416
+ icon: iconSchema,
6417
+ status: statusListLayoutStatusSchema.optional(),
6418
+ callToAction: itemCallToActionSchema.optional()
6345
6419
  });
6346
6420
  var reviewLayoutSchema = z.object({
6347
6421
  type: z.literal("review"),
@@ -6375,12 +6449,20 @@ var alertLayoutSchema = z.object({
6375
6449
  margin: sizeSchema.optional(),
6376
6450
  callToAction: alertLayoutCallToActionSchema.optional()
6377
6451
  });
6378
- var statusListLayoutItemSchema = z.object({
6379
- title: z.string(),
6380
- description: z.string().optional(),
6381
- icon: iconSchema,
6382
- status: statusListLayoutStatusSchema.optional(),
6383
- callToAction: itemCallToActionSchema.optional()
6452
+ var listLayoutSchema = z.object({
6453
+ type: z.literal("list"),
6454
+ title: z.string().optional(),
6455
+ callToAction: listLayoutCallToActionSchema.optional(),
6456
+ items: z.array(listLayoutItemSchema),
6457
+ control: z.string().optional(),
6458
+ margin: sizeSchema.optional()
6459
+ });
6460
+ var statusListLayoutSchema = z.object({
6461
+ type: z.literal("status-list"),
6462
+ items: z.array(statusListLayoutItemSchema),
6463
+ title: z.string().optional(),
6464
+ control: z.string().optional(),
6465
+ margin: sizeSchema.optional()
6384
6466
  });
6385
6467
  var searchResponseBodySchema = z.object({
6386
6468
  results: z.array(searchResultSchema)
@@ -6423,13 +6505,6 @@ var constSchemaSchema = z.object({
6423
6505
  analyticsId: z.string().optional(),
6424
6506
  disabled: z.boolean().optional()
6425
6507
  });
6426
- var statusListLayoutSchema = z.object({
6427
- type: z.literal("status-list"),
6428
- items: z.array(statusListLayoutItemSchema),
6429
- title: z.string().optional(),
6430
- control: z.string().optional(),
6431
- margin: sizeSchema.optional()
6432
- });
6433
6508
  var layoutSchema = z.lazy(
6434
6509
  () => z.union([
6435
6510
  alertLayoutSchema,
@@ -6944,19 +7019,20 @@ var getStepPolling = ({
6944
7019
  if (delay == null) {
6945
7020
  throw new Error("Polling configuration must include delay or interval");
6946
7021
  }
7022
+ const onErrorAction = getOnErrorAction(onError);
6947
7023
  let attempts = 0;
6948
7024
  const poll = () => {
6949
7025
  attempts += 1;
6950
7026
  abortController.abort();
6951
7027
  abortController = new AbortController();
6952
7028
  const { signal } = abortController;
6953
- onPoll(url, onError.action, signal).then((result) => {
7029
+ onPoll(url, onErrorAction, signal).then((result) => {
6954
7030
  if (result) {
6955
7031
  stop();
6956
7032
  return;
6957
7033
  }
6958
7034
  if (attempts >= maxAttempts && !signal.aborted) {
6959
- void onAction(onError.action);
7035
+ void onAction(onErrorAction);
6960
7036
  stop();
6961
7037
  }
6962
7038
  }).catch(() => {
@@ -6970,6 +7046,20 @@ var getStepPolling = ({
6970
7046
  poll();
6971
7047
  return { stop };
6972
7048
  };
7049
+ var getOnErrorAction = (onError) => {
7050
+ if ("behavior" in onError) {
7051
+ if (onError.behavior && "type" in onError.behavior && onError.behavior.type === "action") {
7052
+ return onError.behavior.action;
7053
+ }
7054
+ if (onError.behavior && "action" in onError.behavior && onError.behavior.action) {
7055
+ return onError.behavior.action;
7056
+ }
7057
+ }
7058
+ if ("action" in onError) {
7059
+ return onError.action;
7060
+ }
7061
+ return {};
7062
+ };
6973
7063
 
6974
7064
  // src/revamp/domain/components/AlertComponent.ts
6975
7065
  var createAlertComponent = (alertProps) => __spreadProps(__spreadValues({
@@ -7175,7 +7265,7 @@ var buttonLayoutToComponent = (uid, button, mapperProps) => {
7175
7265
  var buttonLayoutToComponentWithBehavior = (uid, button, mapperProps) => {
7176
7266
  const { onAction, onLink, step } = mapperProps;
7177
7267
  const { context, control, disabled, margin = "md", pinOrder, size: size2, title, behavior } = button;
7178
- const getOnClick = () => {
7268
+ const getOnClick2 = () => {
7179
7269
  if ("type" in behavior) {
7180
7270
  switch (behavior.type) {
7181
7271
  case "action": {
@@ -7219,7 +7309,7 @@ var buttonLayoutToComponentWithBehavior = (uid, button, mapperProps) => {
7219
7309
  pinOrder,
7220
7310
  size: size2,
7221
7311
  title: title != null ? title : "",
7222
- onClick: getOnClick()
7312
+ onClick: getOnClick2()
7223
7313
  });
7224
7314
  };
7225
7315
  var buttonLayoutToComponentWithAction = (uid, button, mapperProps) => {
@@ -7331,21 +7421,51 @@ var createDecisionComponent = (decisionProps) => __spreadProps(__spreadValues({
7331
7421
  });
7332
7422
 
7333
7423
  // src/revamp/domain/mappers/layout/decisionLayoutToComponent.ts
7334
- var decisionLayoutToComponent = (uid, { control, margin = "md", options, title }, { onAction, step }) => createDecisionComponent({
7424
+ var decisionLayoutToComponent = (uid, { control, margin = "md", options, title }, mapperProps) => createDecisionComponent({
7335
7425
  uid,
7336
7426
  control,
7337
7427
  margin,
7338
- options: options.map((_a) => {
7339
- var _b = _a, { action: optionAction } = _b, rest = __objRest(_b, ["action"]);
7340
- const action = inlineAction(optionAction, step == null ? void 0 : step.actions);
7341
- return __spreadProps(__spreadValues({}, rest), {
7342
- onClick: () => {
7343
- void onAction(action);
7344
- }
7428
+ options: options.map((option) => {
7429
+ return __spreadProps(__spreadValues({}, option), {
7430
+ href: getHref(option),
7431
+ onClick: getOnClick(option, mapperProps)
7345
7432
  });
7346
7433
  }),
7347
7434
  title
7348
7435
  });
7436
+ var getHref = (option) => {
7437
+ const { behavior } = option;
7438
+ if (behavior && "type" in behavior && behavior.type === "link") {
7439
+ return behavior.url;
7440
+ }
7441
+ return void 0;
7442
+ };
7443
+ var getOnClick = (option, { step, onAction, onLink }) => {
7444
+ const { behavior } = option;
7445
+ if (!behavior) {
7446
+ const action = inlineAction(option.action, step == null ? void 0 : step.actions);
7447
+ return () => {
7448
+ void onAction(action);
7449
+ };
7450
+ }
7451
+ if ("type" in behavior) {
7452
+ switch (behavior.type) {
7453
+ case "action": {
7454
+ const action = inlineAction(behavior.action, step == null ? void 0 : step.actions);
7455
+ return () => {
7456
+ void onAction(action);
7457
+ };
7458
+ }
7459
+ case "link": {
7460
+ return () => {
7461
+ void onLink(behavior.url);
7462
+ };
7463
+ }
7464
+ }
7465
+ }
7466
+ return () => {
7467
+ };
7468
+ };
7349
7469
 
7350
7470
  // src/revamp/domain/components/DividerComponent.ts
7351
7471
  var createDividerComponent = (props) => __spreadProps(__spreadValues({
@@ -10623,14 +10743,14 @@ var getItemCallToAction = (callToAction, onAction, onLink) => {
10623
10743
  };
10624
10744
  };
10625
10745
 
10626
- // src/revamp/domain/mappers/layout/listLayoutToComponent.ts
10627
- var listLayoutToComponent = (uid, { control, items, margin = "md", title }) => createStatusListComponent({
10746
+ // src/revamp/domain/mappers/layout/deprecatedListLayoutToComponent.ts
10747
+ var deprecatedListLayoutToComponent = (uid, { control, items, margin = "md", title }) => createStatusListComponent({
10628
10748
  uid,
10629
10749
  control,
10630
10750
  items: items.map(({ description, icon, status, title: itemTitle }) => ({
10631
10751
  description,
10632
- icon,
10633
- title: itemTitle,
10752
+ icon: icon != null ? icon : { text: "" },
10753
+ title: itemTitle != null ? itemTitle : "",
10634
10754
  status: status ? mapLegacyStatus(status) : void 0
10635
10755
  })),
10636
10756
  margin,
@@ -10648,6 +10768,68 @@ var mapLegacyStatus = (status) => {
10648
10768
  }
10649
10769
  };
10650
10770
 
10771
+ // src/revamp/domain/components/ListComponent.ts
10772
+ var createListComponent = (listProps) => __spreadProps(__spreadValues({
10773
+ type: "list"
10774
+ }, listProps), {
10775
+ getLocalValue: () => null,
10776
+ getSubmittableValue: async () => null,
10777
+ getSubmittableValueSync: () => null,
10778
+ getSummary: () => ({}),
10779
+ // noop
10780
+ validate: () => true
10781
+ });
10782
+
10783
+ // src/revamp/domain/mappers/layout/listLayoutToComponent.ts
10784
+ var listLayoutToComponent = (uid, { callToAction, control, items, margin = "md", title }, mapperProps) => createListComponent({
10785
+ uid,
10786
+ control,
10787
+ items: items.map(({ value, subvalue, title: itemTitle, subtitle, icon, image }) => ({
10788
+ title: itemTitle,
10789
+ subtitle,
10790
+ value,
10791
+ subvalue,
10792
+ icon,
10793
+ image
10794
+ })),
10795
+ callToAction: getListCallToAction(callToAction, mapperProps),
10796
+ margin,
10797
+ title
10798
+ });
10799
+ var getListCallToAction = (callToAction, { onAction, onLink }) => {
10800
+ if (!callToAction) {
10801
+ return void 0;
10802
+ }
10803
+ const { accessibilityDescription, behavior, title } = callToAction;
10804
+ if ("type" in behavior) {
10805
+ switch (behavior.type) {
10806
+ case "action": {
10807
+ const { action } = behavior;
10808
+ return {
10809
+ type: "action",
10810
+ accessibilityDescription,
10811
+ title,
10812
+ onClick: () => {
10813
+ void onAction(action);
10814
+ }
10815
+ };
10816
+ }
10817
+ case "link": {
10818
+ return {
10819
+ type: "link",
10820
+ accessibilityDescription,
10821
+ href: behavior.url,
10822
+ title,
10823
+ onClick: () => {
10824
+ void onLink(behavior.url);
10825
+ }
10826
+ };
10827
+ }
10828
+ }
10829
+ }
10830
+ return void 0;
10831
+ };
10832
+
10651
10833
  // src/revamp/domain/mappers/mapLayoutToComponent.ts
10652
10834
  var mapLayoutToComponent = (uid, layout, mapperProps) => {
10653
10835
  switch (layout.type) {
@@ -10674,7 +10856,10 @@ var mapLayoutToComponent = (uid, layout, mapperProps) => {
10674
10856
  case "instructions":
10675
10857
  return instructionsLayoutToComponent(uid, layout);
10676
10858
  case "list":
10677
- return listLayoutToComponent(uid, layout);
10859
+ if (layout.items.some((item) => item.status || item.description)) {
10860
+ return deprecatedListLayoutToComponent(uid, layout);
10861
+ }
10862
+ return listLayoutToComponent(uid, layout, mapperProps);
10678
10863
  case "loading-indicator":
10679
10864
  return loadingIndicatorLayoutToComponent(uid, layout);
10680
10865
  case "markdown":
@@ -12007,9 +12192,14 @@ function NavigationOptionMedia({ icon, image }) {
12007
12192
  return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(import_components8.Avatar, { type: import_components8.AvatarType.INITIALS, children: icon.text });
12008
12193
  }
12009
12194
  }
12010
- if (image == null ? void 0 : image.url) {
12011
- const { url, accessibilityDescription } = image;
12012
- return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("img", { src: url, alt: accessibilityDescription });
12195
+ if (image) {
12196
+ const { accessibilityDescription, uri, url } = image;
12197
+ if (uri && !uri.startsWith("urn:")) {
12198
+ return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("img", { src: uri, alt: accessibilityDescription });
12199
+ }
12200
+ if (url) {
12201
+ return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("img", { src: url, alt: accessibilityDescription });
12202
+ }
12013
12203
  }
12014
12204
  return null;
12015
12205
  }
@@ -12025,10 +12215,10 @@ function DecisionRendererComponent({ margin, options, title }) {
12025
12215
  const { isLoading } = useLoadingContext();
12026
12216
  return /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)("div", { className: getMargin(margin), children: [
12027
12217
  title && /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(import_components9.Header, { as: "h2", title }),
12028
- /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(import_components9.NavigationOptionsList, { children: options.map(({ description, disabled, icon, image, title: title2, onClick }) => /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
12218
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(import_components9.NavigationOptionsList, { children: options.map(({ description, disabled, icon, image, title: itemTitle, onClick }) => /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
12029
12219
  import_components9.NavigationOption,
12030
12220
  {
12031
- title: title2,
12221
+ title: itemTitle,
12032
12222
  content: description,
12033
12223
  disabled: isLoading || disabled,
12034
12224
  media: /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(NavigationOptionMedia, { icon, image }),
@@ -12036,7 +12226,7 @@ function DecisionRendererComponent({ margin, options, title }) {
12036
12226
  showMediaAtAllSizes: true,
12037
12227
  onClick
12038
12228
  },
12039
- JSON.stringify(title2)
12229
+ JSON.stringify(itemTitle)
12040
12230
  )) })
12041
12231
  ] });
12042
12232
  }
@@ -12144,8 +12334,8 @@ function ImageRendererComponent({
12144
12334
  accessibilityDescription,
12145
12335
  margin,
12146
12336
  size: size2,
12147
- url,
12148
- uri
12337
+ uri,
12338
+ url
12149
12339
  }) {
12150
12340
  const [imageSource, setImageSource] = (0, import_react9.useState)("");
12151
12341
  const httpClient = useRendererHttpClient();
@@ -12158,7 +12348,7 @@ function ImageRendererComponent({
12158
12348
  void getImageSource(httpClient, uri).then(setImageSource);
12159
12349
  return;
12160
12350
  }
12161
- }, [url, httpClient]);
12351
+ }, [uri, url, httpClient]);
12162
12352
  return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("div", { className: `df-image ${size2 || "md"}`, children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
12163
12353
  import_components12.Image,
12164
12354
  {
@@ -13855,6 +14045,72 @@ function StepRendererComponent(props) {
13855
14045
  ] });
13856
14046
  }
13857
14047
 
14048
+ // ../renderers/src/ListRenderer.tsx
14049
+ var import_components42 = require("@transferwise/components");
14050
+ var import_classnames6 = __toESM(require_classnames());
14051
+ var import_jsx_runtime59 = require("react/jsx-runtime");
14052
+ var ListRenderer = {
14053
+ canRenderType: "list",
14054
+ render: ({ callToAction, margin, items, title }) => /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("div", { className: getMargin(margin), children: [
14055
+ title && /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(import_components42.Header, { as: "h2", title, action: getListAction(callToAction) }),
14056
+ items.map((props) => /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(DesignSystemListItem, __spreadValues({}, props), props.title))
14057
+ ] })
14058
+ };
14059
+ var DesignSystemListItem = ({ title, subtitle, value, subvalue, icon, image }) => /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
14060
+ "label",
14061
+ {
14062
+ className: (0, import_classnames6.default)("np-option p-a-2", {
14063
+ "np-option__sm-media": true,
14064
+ "np-option__container-aligned": true
14065
+ }),
14066
+ children: /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("div", { className: "media", children: [
14067
+ icon || image ? /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("div", { className: "media-left", children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(ListItemMedia, { image, icon }) }) : null,
14068
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("div", { className: "media-body", children: [
14069
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("div", { className: "d-flex justify-content-between", children: [
14070
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("h4", { className: "np-text-body-large-bold text-primary np-option__title", children: title }),
14071
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("h4", { className: "np-text-body-large-bold text-primary np-option__title", children: value })
14072
+ ] }),
14073
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("div", { className: "d-flex justify-content-between", children: [
14074
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(import_components42.Body, { className: "d-block np-option__body", children: subtitle }),
14075
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(import_components42.Body, { className: "d-block np-option__body", children: subvalue })
14076
+ ] })
14077
+ ] })
14078
+ ] })
14079
+ },
14080
+ title
14081
+ );
14082
+ var ListItemMedia = ({ icon, image }) => {
14083
+ if (icon) {
14084
+ return /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("div", { className: "circle circle-sm text-primary", children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(NavigationOptionMedia, { icon, image }) });
14085
+ }
14086
+ if (image) {
14087
+ return /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("div", { className: "np-option__no-media-circle", children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(NavigationOptionMedia, { icon, image }) });
14088
+ }
14089
+ };
14090
+ var getListAction = (callToAction) => {
14091
+ if (!callToAction) {
14092
+ return void 0;
14093
+ }
14094
+ const { accessibilityDescription, title, onClick } = callToAction;
14095
+ if (callToAction.type === "action") {
14096
+ return {
14097
+ "aria-label": accessibilityDescription,
14098
+ text: title,
14099
+ onClick: (event) => {
14100
+ event.preventDefault();
14101
+ onClick();
14102
+ }
14103
+ };
14104
+ }
14105
+ return {
14106
+ "aria-label": accessibilityDescription,
14107
+ href: callToAction.href,
14108
+ target: "_blank",
14109
+ text: title
14110
+ };
14111
+ };
14112
+ var ListRenderer_default = ListRenderer;
14113
+
13858
14114
  // ../renderers/src/getWiseRenderers.ts
13859
14115
  var getWiseRenderers = () => [
13860
14116
  AlertRenderer_default,
@@ -13872,6 +14128,7 @@ var getWiseRenderers = () => [
13872
14128
  InstructionsRenderer_default,
13873
14129
  IntegerInputRenderer_default,
13874
14130
  LargeUploadRenderer,
14131
+ ListRenderer_default,
13875
14132
  LoadingIndicatorRenderer_default,
13876
14133
  MarkdownRenderer_default,
13877
14134
  ModalRenderer_default,
@@ -13901,12 +14158,12 @@ var openLinkInNewTab = (url) => {
13901
14158
  };
13902
14159
 
13903
14160
  // src/revamp/DynamicFlowWise.tsx
13904
- var import_jsx_runtime59 = require("react/jsx-runtime");
14161
+ var import_jsx_runtime60 = require("react/jsx-runtime");
13905
14162
  var wiseRenderers = getWiseRenderers();
13906
14163
  function DynamicFlowWise(props) {
13907
14164
  const { httpClient, renderers, onLink = openLinkInNewTab } = props;
13908
14165
  const mergedRenderers = (0, import_react20.useMemo)(() => [...renderers != null ? renderers : [], ...wiseRenderers], [renderers]);
13909
- return /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(RendererHttpClientProvider, { httpClient, children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(DynamicFlowCore, __spreadProps(__spreadValues({}, props), { renderers: mergedRenderers, onLink })) });
14166
+ return /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(RendererHttpClientProvider, { httpClient, children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(DynamicFlowCore, __spreadProps(__spreadValues({}, props), { renderers: mergedRenderers, onLink })) });
13910
14167
  }
13911
14168
  var DynamicFlowWise_default = DynamicFlowWise;
13912
14169
 
@@ -13915,14 +14172,14 @@ var import_react22 = require("react");
13915
14172
 
13916
14173
  // src/common/httpClientContext/HttpClientContext.tsx
13917
14174
  var import_react21 = require("react");
13918
- var import_jsx_runtime60 = require("react/jsx-runtime");
14175
+ var import_jsx_runtime61 = require("react/jsx-runtime");
13919
14176
  var HttpClientContext2 = (0, import_react21.createContext)(void 0);
13920
14177
  function HttpClientProvider({ httpClient, children }) {
13921
- return /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(HttpClientContext2.Provider, { value: httpClient, children });
14178
+ return /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(HttpClientContext2.Provider, { value: httpClient, children });
13922
14179
  }
13923
14180
  function HttpClientProviderFromBaseUrl({ baseUrl, children }) {
13924
14181
  const httpClient = (0, import_react21.useMemo)(() => makeHttpClient(baseUrl), [baseUrl]);
13925
- return /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(HttpClientContext2.Provider, { value: httpClient, children });
14182
+ return /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(HttpClientContext2.Provider, { value: httpClient, children });
13926
14183
  }
13927
14184
  var useHttpClient = () => {
13928
14185
  const contextFetch = (0, import_react21.useContext)(HttpClientContext2);
@@ -13934,7 +14191,7 @@ var useHasHttpClientProvider = () => {
13934
14191
  };
13935
14192
 
13936
14193
  // src/revamp/DynamicFragmentWise.tsx
13937
- var import_jsx_runtime61 = require("react/jsx-runtime");
14194
+ var import_jsx_runtime62 = require("react/jsx-runtime");
13938
14195
  var wiseRenderers2 = getWiseRenderers();
13939
14196
  var DynamicFragmentWise = (0, import_react22.forwardRef)(function DynamicFragmentWise2(props, ref) {
13940
14197
  const {
@@ -13967,14 +14224,14 @@ var DynamicFragmentWise = (0, import_react22.forwardRef)(function DynamicFragmen
13967
14224
  () => getRenderFunction([CoreContainerRenderer, ...mergedRenderers, StepRenderer]),
13968
14225
  [mergedRenderers]
13969
14226
  );
13970
- return /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
14227
+ return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
13971
14228
  ErrorBoundary_default,
13972
14229
  {
13973
14230
  onError: (error) => {
13974
14231
  onEvent == null ? void 0 : onEvent("Dynamic Flow - Failed");
13975
14232
  onError(error);
13976
14233
  },
13977
- children: /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(HttpClientProvider, { httpClient, children: stepComponentRef.current ? render(stepComponentRef.current) : null })
14234
+ children: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(HttpClientProvider, { httpClient, children: stepComponentRef.current ? render(stepComponentRef.current) : null })
13978
14235
  }
13979
14236
  );
13980
14237
  });
@@ -13982,7 +14239,7 @@ var DynamicFragmentWise_default = DynamicFragmentWise;
13982
14239
 
13983
14240
  // src/revamp/DynamicFragmentCore.tsx
13984
14241
  var import_react23 = require("react");
13985
- var import_jsx_runtime62 = require("react/jsx-runtime");
14242
+ var import_jsx_runtime63 = require("react/jsx-runtime");
13986
14243
  var DynamicFragmentCore = (0, import_react23.forwardRef)(function DynamicFragmentCore2(props, ref) {
13987
14244
  const { onCompletion = () => {
13988
14245
  }, onEvent, onError, onLink = openLinkInNewTab, renderers } = props;
@@ -14006,7 +14263,7 @@ var DynamicFragmentCore = (0, import_react23.forwardRef)(function DynamicFragmen
14006
14263
  () => getRenderFunction([CoreContainerRenderer, ...renderers]),
14007
14264
  [renderers]
14008
14265
  );
14009
- return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
14266
+ return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
14010
14267
  ErrorBoundary_default,
14011
14268
  {
14012
14269
  onError: (error) => {
@@ -14347,7 +14604,7 @@ var noop2 = () => {
14347
14604
  };
14348
14605
 
14349
14606
  // src/legacy/common/contexts/dynamicFlowContexts/DynamicFlowContexts.tsx
14350
- var import_jsx_runtime63 = require("react/jsx-runtime");
14607
+ var import_jsx_runtime64 = require("react/jsx-runtime");
14351
14608
  var defaultContextValue = {
14352
14609
  loading: false,
14353
14610
  registerPersistAsyncPromise: (promise) => {
@@ -14362,7 +14619,7 @@ var DynamicFlowProvider = ({ loading, children }) => {
14362
14619
  registerPersistAsyncPromise: addPendingPromise
14363
14620
  };
14364
14621
  }, [loading, pendingPromises, addPendingPromise]);
14365
- return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(DFContext.Provider, { value: providerValue, children });
14622
+ return /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(DFContext.Provider, { value: providerValue, children });
14366
14623
  };
14367
14624
  var useDynamicFlow = () => {
14368
14625
  const context = (0, import_react25.useContext)(DFContext);
@@ -14371,7 +14628,7 @@ var useDynamicFlow = () => {
14371
14628
 
14372
14629
  // src/legacy/common/contexts/eventsContext/EventsContext.tsx
14373
14630
  var import_react26 = require("react");
14374
- var import_jsx_runtime64 = require("react/jsx-runtime");
14631
+ var import_jsx_runtime65 = require("react/jsx-runtime");
14375
14632
  var EventsContext = (0, import_react26.createContext)({
14376
14633
  triggerEvent: () => {
14377
14634
  }
@@ -14381,7 +14638,7 @@ function EventsContextProvider({ metadata, children, onEvent }) {
14381
14638
  () => ({ triggerEvent: getEventDispatcher(onEvent, metadata) }),
14382
14639
  [onEvent, metadata]
14383
14640
  );
14384
- return /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(EventsContext.Provider, { value, children });
14641
+ return /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(EventsContext.Provider, { value, children });
14385
14642
  }
14386
14643
  function useEventDispatcher() {
14387
14644
  const { triggerEvent } = (0, import_react26.useContext)(EventsContext);
@@ -14396,7 +14653,7 @@ var getEventDispatcher = (onEvent, metadata) => (eventName, properties = {}) =>
14396
14653
 
14397
14654
  // src/legacy/common/contexts/logContext/LogContext.tsx
14398
14655
  var import_react27 = require("react");
14399
- var import_jsx_runtime65 = require("react/jsx-runtime");
14656
+ var import_jsx_runtime66 = require("react/jsx-runtime");
14400
14657
  var getLogger = (level, onLog, flowId = "UNKNOWN-FLOW-ID", stepId = "UNKNOWN-FLOW-ID") => (title, description, extra) => {
14401
14658
  try {
14402
14659
  onLog(level, `Dynamic Flow ${level} - ${title} - ${description}`, __spreadValues({
@@ -14418,7 +14675,7 @@ function LogProvider({ flowId, stepId, children, onLog }) {
14418
14675
  }),
14419
14676
  [onLog, flowId, stepId]
14420
14677
  );
14421
- return /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(LogContext.Provider, { value, children });
14678
+ return /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(LogContext.Provider, { value, children });
14422
14679
  }
14423
14680
  var useLogger = () => {
14424
14681
  const logging = (0, import_react27.useContext)(LogContext);
@@ -14432,10 +14689,10 @@ var useLogger = () => {
14432
14689
 
14433
14690
  // src/legacy/common/contexts/featureContext/FeatureContext.tsx
14434
14691
  var import_react28 = require("react");
14435
- var import_jsx_runtime66 = require("react/jsx-runtime");
14692
+ var import_jsx_runtime67 = require("react/jsx-runtime");
14436
14693
  var FeatureContext = (0, import_react28.createContext)([]);
14437
14694
  function FeatureContextProvider({ features, children }) {
14438
- return /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(FeatureContext.Provider, { value: features, children });
14695
+ return /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(FeatureContext.Provider, { value: features, children });
14439
14696
  }
14440
14697
 
14441
14698
  // src/common/cameraCapture/utils/mobile-utils.ts
@@ -15294,29 +15551,29 @@ var Size = {
15294
15551
  };
15295
15552
 
15296
15553
  // src/legacy/jsonSchemaForm/basicTypeSchema/BasicTypeSchema.tsx
15297
- var import_classnames15 = __toESM(require_classnames());
15554
+ var import_classnames16 = __toESM(require_classnames());
15298
15555
  var import_react53 = require("react");
15299
15556
 
15300
15557
  // src/legacy/layout/alert/DynamicAlert.tsx
15301
- var import_components43 = require("@transferwise/components");
15558
+ var import_components44 = require("@transferwise/components");
15302
15559
 
15303
15560
  // src/legacy/layout/utils/getNavigationOptionMedia.tsx
15304
- var import_components42 = require("@transferwise/components");
15561
+ var import_components43 = require("@transferwise/components");
15305
15562
 
15306
15563
  // src/legacy/layout/icon/FlagIcon.tsx
15307
- var import_jsx_runtime67 = require("react/jsx-runtime");
15564
+ var import_jsx_runtime68 = require("react/jsx-runtime");
15308
15565
  var isFlagIcon3 = (name) => name.startsWith("flag-");
15309
15566
  function FlagIcon2({ name }) {
15310
15567
  if (!isFlagIcon3(name)) {
15311
15568
  return null;
15312
15569
  }
15313
15570
  const code = name.substring(5);
15314
- return /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(Flag, { intrinsicSize: 24, code });
15571
+ return /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(Flag, { intrinsicSize: 24, code });
15315
15572
  }
15316
15573
 
15317
15574
  // src/legacy/layout/icon/NamedIcon.tsx
15318
15575
  var icons2 = __toESM(require("@transferwise/icons"));
15319
- var import_jsx_runtime68 = require("react/jsx-runtime");
15576
+ var import_jsx_runtime69 = require("react/jsx-runtime");
15320
15577
  var isNamedIcon3 = (name) => {
15321
15578
  const iconName = toCapitalisedCamelCase2(name);
15322
15579
  return Object.keys(icons2).includes(iconName);
@@ -15327,19 +15584,19 @@ function NamedIcon2({ name }) {
15327
15584
  }
15328
15585
  const iconName = toCapitalisedCamelCase2(name);
15329
15586
  const Icon = icons2[iconName];
15330
- return /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(Icon, { size: 24 });
15587
+ return /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(Icon, { size: 24 });
15331
15588
  }
15332
15589
  var toCapitalisedCamelCase2 = (value) => value.split("-").map(capitaliseFirstChar2).join("");
15333
15590
  var capitaliseFirstChar2 = (value) => `${value[0].toUpperCase()}${value.slice(1)}`;
15334
15591
 
15335
15592
  // src/legacy/layout/icon/DynamicIcon.tsx
15336
- var import_jsx_runtime69 = require("react/jsx-runtime");
15593
+ var import_jsx_runtime70 = require("react/jsx-runtime");
15337
15594
  function DynamicIcon2({ type }) {
15338
15595
  if (isFlagIcon3(type)) {
15339
- return /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(FlagIcon2, { name: type });
15596
+ return /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(FlagIcon2, { name: type });
15340
15597
  }
15341
15598
  if (isNamedIcon3(type)) {
15342
- return /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(NamedIcon2, { name: type });
15599
+ return /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(NamedIcon2, { name: type });
15343
15600
  }
15344
15601
  return null;
15345
15602
  }
@@ -15349,17 +15606,17 @@ function isValidIconName(name) {
15349
15606
  var DynamicIcon_default2 = DynamicIcon2;
15350
15607
 
15351
15608
  // src/legacy/layout/utils/getNavigationOptionMedia.tsx
15352
- var import_jsx_runtime70 = require("react/jsx-runtime");
15609
+ var import_jsx_runtime71 = require("react/jsx-runtime");
15353
15610
  var getNavigationOptionMedia = ({ icon, image }) => {
15354
15611
  if (icon == null ? void 0 : icon.name) {
15355
- return /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_components42.Avatar, { type: import_components42.AvatarType.ICON, children: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(DynamicIcon_default2, { type: icon.name }) });
15612
+ return /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(import_components43.Avatar, { type: import_components43.AvatarType.ICON, children: /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(DynamicIcon_default2, { type: icon.name }) });
15356
15613
  }
15357
15614
  if (icon == null ? void 0 : icon.text) {
15358
- return /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_components42.Avatar, { type: import_components42.AvatarType.INITIALS, children: icon.text });
15615
+ return /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(import_components43.Avatar, { type: import_components43.AvatarType.INITIALS, children: icon.text });
15359
15616
  }
15360
15617
  if (image == null ? void 0 : image.url) {
15361
15618
  const { url, text } = image;
15362
- return /* @__PURE__ */ (0, import_jsx_runtime70.jsx)("img", { src: url, alt: text });
15619
+ return /* @__PURE__ */ (0, import_jsx_runtime71.jsx)("img", { src: url, alt: text });
15363
15620
  }
15364
15621
  return null;
15365
15622
  };
@@ -15395,11 +15652,11 @@ var getTextAlignment2 = (align) => {
15395
15652
  var getTextAlignmentAndMargin2 = (component) => `${getTextAlignment2(component.align)} ${getMargin2(component.margin)}`;
15396
15653
 
15397
15654
  // src/legacy/layout/alert/DynamicAlert.tsx
15398
- var import_jsx_runtime71 = require("react/jsx-runtime");
15655
+ var import_jsx_runtime72 = require("react/jsx-runtime");
15399
15656
  var DynamicAlert = ({ component: alert, onAction }) => {
15400
15657
  const { context, markdown, margin } = alert;
15401
- return /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(
15402
- import_components43.Alert,
15658
+ return /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(
15659
+ import_components44.Alert,
15403
15660
  {
15404
15661
  type: mapContextToAlertType(legacy_mapContext(context)),
15405
15662
  className: getMargin2(margin),
@@ -15482,12 +15739,12 @@ var mapContextToAlertType = (context) => {
15482
15739
  var DynamicAlert_default = DynamicAlert;
15483
15740
 
15484
15741
  // src/legacy/layout/box/DynamicBox.tsx
15485
- var import_jsx_runtime72 = require("react/jsx-runtime");
15742
+ var import_jsx_runtime73 = require("react/jsx-runtime");
15486
15743
  var DynamicBox = (props) => {
15487
15744
  const box = props.component;
15488
15745
  const margin = getMargin2(box.margin || box.border ? "lg" : "xs");
15489
15746
  if (!box.width || box.width === "xl") {
15490
- return /* @__PURE__ */ (0, import_jsx_runtime72.jsx)("div", { className: margin + getBorderClass(box.border), children: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(
15747
+ return /* @__PURE__ */ (0, import_jsx_runtime73.jsx)("div", { className: margin + getBorderClass(box.border), children: /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(
15491
15748
  DynamicLayout_default,
15492
15749
  {
15493
15750
  components: box.components,
@@ -15500,7 +15757,7 @@ var DynamicBox = (props) => {
15500
15757
  }
15501
15758
  ) });
15502
15759
  }
15503
- return /* @__PURE__ */ (0, import_jsx_runtime72.jsx)("div", { className: "row", children: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)("div", { className: margin + getBoxWidthClasses(box), children: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)("div", { className: getBorderClass(box.border), children: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(
15760
+ return /* @__PURE__ */ (0, import_jsx_runtime73.jsx)("div", { className: "row", children: /* @__PURE__ */ (0, import_jsx_runtime73.jsx)("div", { className: margin + getBoxWidthClasses(box), children: /* @__PURE__ */ (0, import_jsx_runtime73.jsx)("div", { className: getBorderClass(box.border), children: /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(
15504
15761
  DynamicLayout_default,
15505
15762
  {
15506
15763
  components: box.components,
@@ -15534,7 +15791,7 @@ var getBoxWidthClasses = (component) => {
15534
15791
  var DynamicBox_default = DynamicBox;
15535
15792
 
15536
15793
  // src/legacy/layout/button/DynamicButton.tsx
15537
- var import_components44 = require("@transferwise/components");
15794
+ var import_components45 = require("@transferwise/components");
15538
15795
 
15539
15796
  // src/legacy/layout/button/utils.ts
15540
15797
  var priorities = {
@@ -15586,9 +15843,9 @@ var getButtonSize = (size2) => {
15586
15843
  };
15587
15844
 
15588
15845
  // src/legacy/layout/button/DynamicButton.tsx
15589
- var import_jsx_runtime73 = require("react/jsx-runtime");
15846
+ var import_jsx_runtime74 = require("react/jsx-runtime");
15590
15847
  function DynamicButton(props) {
15591
- return props.component.behavior ? /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(DynamicButtonWithBehavior, __spreadValues({}, props)) : /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(DynamicButtonWithoutBehavior, __spreadValues({}, props));
15848
+ return props.component.behavior ? /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(DynamicButtonWithBehavior, __spreadValues({}, props)) : /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(DynamicButtonWithoutBehavior, __spreadValues({}, props));
15592
15849
  }
15593
15850
  function DynamicButtonWithoutBehavior(props) {
15594
15851
  var _a, _b;
@@ -15605,8 +15862,8 @@ function DynamicButtonWithoutBehavior(props) {
15605
15862
  onAction(componentAction);
15606
15863
  }
15607
15864
  };
15608
- return /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(
15609
- import_components44.Button,
15865
+ return /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(
15866
+ import_components45.Button,
15610
15867
  {
15611
15868
  size: getButtonSize(component.size),
15612
15869
  type: priority === "tertiary" ? void 0 : type,
@@ -15657,8 +15914,8 @@ function DynamicButtonWithBehavior(props) {
15657
15914
  }
15658
15915
  }
15659
15916
  };
15660
- return /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(
15661
- import_components44.Button,
15917
+ return /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(
15918
+ import_components45.Button,
15662
15919
  {
15663
15920
  size: getButtonSize(component.size),
15664
15921
  type: priority === "tertiary" ? void 0 : type,
@@ -15674,12 +15931,12 @@ function DynamicButtonWithBehavior(props) {
15674
15931
  var DynamicButton_default = DynamicButton;
15675
15932
 
15676
15933
  // src/legacy/layout/columns/DynamicColumns.tsx
15677
- var import_jsx_runtime74 = require("react/jsx-runtime");
15934
+ var import_jsx_runtime75 = require("react/jsx-runtime");
15678
15935
  var DynamicColumns = (props) => {
15679
15936
  const columns = props.component;
15680
15937
  const { leftWidth, rightWidth } = getWidth(columns.bias);
15681
- return /* @__PURE__ */ (0, import_jsx_runtime74.jsxs)("div", { className: `${getMargin2(columns.margin || "xs")} row`, children: [
15682
- /* @__PURE__ */ (0, import_jsx_runtime74.jsx)("div", { className: `${leftWidth} m-b-0`, children: /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(
15938
+ return /* @__PURE__ */ (0, import_jsx_runtime75.jsxs)("div", { className: `${getMargin2(columns.margin || "xs")} row`, children: [
15939
+ /* @__PURE__ */ (0, import_jsx_runtime75.jsx)("div", { className: `${leftWidth} m-b-0`, children: /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(
15683
15940
  DynamicLayout_default,
15684
15941
  {
15685
15942
  components: columns.left,
@@ -15691,7 +15948,7 @@ var DynamicColumns = (props) => {
15691
15948
  onPersistAsync: props.onPersistAsync
15692
15949
  }
15693
15950
  ) }),
15694
- /* @__PURE__ */ (0, import_jsx_runtime74.jsx)("div", { className: `${rightWidth} m-b-0`, children: /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(
15951
+ /* @__PURE__ */ (0, import_jsx_runtime75.jsx)("div", { className: `${rightWidth} m-b-0`, children: /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(
15695
15952
  DynamicLayout_default,
15696
15953
  {
15697
15954
  components: columns.right,
@@ -15726,15 +15983,15 @@ var getWidth = (bias) => {
15726
15983
  var DynamicColumns_default = DynamicColumns;
15727
15984
 
15728
15985
  // src/legacy/layout/decision/DynamicDecision.tsx
15729
- var import_components45 = require("@transferwise/components");
15730
- var import_jsx_runtime75 = require("react/jsx-runtime");
15986
+ var import_components46 = require("@transferwise/components");
15987
+ var import_jsx_runtime76 = require("react/jsx-runtime");
15731
15988
  function DynamicDecision({ component, onAction }) {
15732
15989
  const { loading } = useDynamicFlow();
15733
15990
  const { margin, options, title } = component;
15734
- return /* @__PURE__ */ (0, import_jsx_runtime75.jsxs)("div", { className: getMargin2(margin), children: [
15735
- title && /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(import_components45.Header, { as: "h2", title }),
15736
- /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(import_components45.NavigationOptionsList, { children: options.map((option) => /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(
15737
- import_components45.NavigationOption,
15991
+ return /* @__PURE__ */ (0, import_jsx_runtime76.jsxs)("div", { className: getMargin2(margin), children: [
15992
+ title && /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(import_components46.Header, { as: "h2", title }),
15993
+ /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(import_components46.NavigationOptionsList, { children: options.map((option) => /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(
15994
+ import_components46.NavigationOption,
15738
15995
  {
15739
15996
  title: option.title,
15740
15997
  content: option.description,
@@ -15751,16 +16008,16 @@ function DynamicDecision({ component, onAction }) {
15751
16008
  var DynamicDecision_default = DynamicDecision;
15752
16009
 
15753
16010
  // src/legacy/layout/divider/DynamicDivider.tsx
15754
- var import_jsx_runtime76 = require("react/jsx-runtime");
16011
+ var import_jsx_runtime77 = require("react/jsx-runtime");
15755
16012
  var DynamicDivider = ({ component }) => {
15756
16013
  const margin = getMargin2(component.margin);
15757
16014
  const className = `m-t-0 ${margin}`;
15758
- return /* @__PURE__ */ (0, import_jsx_runtime76.jsx)("hr", { className });
16015
+ return /* @__PURE__ */ (0, import_jsx_runtime77.jsx)("hr", { className });
15759
16016
  };
15760
16017
  var DynamicDivider_default = DynamicDivider;
15761
16018
 
15762
16019
  // src/legacy/layout/external/DynamicExternal.tsx
15763
- var import_components46 = require("@transferwise/components");
16020
+ var import_components47 = require("@transferwise/components");
15764
16021
  var import_react32 = require("react");
15765
16022
  var import_react_intl24 = require("react-intl");
15766
16023
 
@@ -15775,7 +16032,7 @@ var DynamicExternal_messages_default = (0, import_react_intl23.defineMessages)({
15775
16032
  });
15776
16033
 
15777
16034
  // src/legacy/layout/external/DynamicExternal.tsx
15778
- var import_jsx_runtime77 = require("react/jsx-runtime");
16035
+ var import_jsx_runtime78 = require("react/jsx-runtime");
15779
16036
  var DynamicExternal = ({ component, onAction }) => {
15780
16037
  const { requestUrl, responseHandlers, polling, retryTitle } = component;
15781
16038
  const intl = (0, import_react_intl24.useIntl)();
@@ -15792,10 +16049,10 @@ var DynamicExternal = ({ component, onAction }) => {
15792
16049
  }) : void 0;
15793
16050
  }, [polling, responseHandlers]);
15794
16051
  useExternalStepPolling(pollingConfiguration, onAction);
15795
- return /* @__PURE__ */ (0, import_jsx_runtime77.jsxs)(import_jsx_runtime77.Fragment, { children: [
15796
- /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(import_components46.Loader, { size: import_components46.Size.LARGE, classNames: { "tw-loader": "tw-loader m-x-auto" } }),
15797
- /* @__PURE__ */ (0, import_jsx_runtime77.jsx)("br", {}),
15798
- /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(import_components46.Button, { priority: "tertiary", block: true, onClick: openExternalUrl, children: retryTitle || intl.formatMessage(DynamicExternal_messages_default.retryTitle) })
16052
+ return /* @__PURE__ */ (0, import_jsx_runtime78.jsxs)(import_jsx_runtime78.Fragment, { children: [
16053
+ /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(import_components47.Loader, { size: import_components47.Size.LARGE, classNames: { "tw-loader": "tw-loader m-x-auto" } }),
16054
+ /* @__PURE__ */ (0, import_jsx_runtime78.jsx)("br", {}),
16055
+ /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(import_components47.Button, { priority: "tertiary", block: true, onClick: openExternalUrl, children: retryTitle || intl.formatMessage(DynamicExternal_messages_default.retryTitle) })
15799
16056
  ] });
15800
16057
  };
15801
16058
  var DynamicExternal_default = DynamicExternal;
@@ -15804,10 +16061,10 @@ var DynamicExternal_default = DynamicExternal;
15804
16061
  var import_react46 = require("react");
15805
16062
 
15806
16063
  // src/legacy/jsonSchemaForm/allOfSchema/AllOfSchema.tsx
15807
- var import_components47 = require("@transferwise/components");
15808
- var import_classnames6 = __toESM(require_classnames());
16064
+ var import_components48 = require("@transferwise/components");
16065
+ var import_classnames7 = __toESM(require_classnames());
15809
16066
  var import_react33 = require("react");
15810
- var import_jsx_runtime78 = require("react/jsx-runtime");
16067
+ var import_jsx_runtime79 = require("react/jsx-runtime");
15811
16068
  var splitModel = (model, schemas) => schemas.map((schema) => getValidObjectModelParts(model, schema) || {});
15812
16069
  var combineModels = (models) => models.reduce((current, combined) => __spreadValues(__spreadValues({}, combined), current), {});
15813
16070
  var getSchemaColumnClasses = (width) => ({
@@ -15824,12 +16081,12 @@ function AllOfSchema(props) {
15824
16081
  props.onChange(__spreadProps(__spreadValues({}, onChangeProps), { model: combineModels(models) }));
15825
16082
  };
15826
16083
  const [models, setModels] = (0, import_react33.useState)(splitModel(props.model, props.schema.allOf));
15827
- return /* @__PURE__ */ (0, import_jsx_runtime78.jsxs)(import_jsx_runtime78.Fragment, { children: [
15828
- props.schema.title && !hideTitle && /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(import_components47.Header, { title: props.schema.title }),
15829
- props.schema.description && /* @__PURE__ */ (0, import_jsx_runtime78.jsx)("p", { children: props.schema.description }),
15830
- /* @__PURE__ */ (0, import_jsx_runtime78.jsx)("div", { className: "row", children: props.schema.allOf.map((schema, index) => (
16084
+ return /* @__PURE__ */ (0, import_jsx_runtime79.jsxs)(import_jsx_runtime79.Fragment, { children: [
16085
+ props.schema.title && !hideTitle && /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(import_components48.Header, { title: props.schema.title }),
16086
+ props.schema.description && /* @__PURE__ */ (0, import_jsx_runtime79.jsx)("p", { children: props.schema.description }),
16087
+ /* @__PURE__ */ (0, import_jsx_runtime79.jsx)("div", { className: "row", children: props.schema.allOf.map((schema, index) => (
15831
16088
  // eslint-disable-next-line react/no-array-index-key
15832
- /* @__PURE__ */ (0, import_jsx_runtime78.jsx)("div", { className: (0, import_classnames6.default)(getSchemaColumnClasses(schema.width)), children: /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(
16089
+ /* @__PURE__ */ (0, import_jsx_runtime79.jsx)("div", { className: (0, import_classnames7.default)(getSchemaColumnClasses(schema.width)), children: /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(
15833
16090
  GenericSchema_default,
15834
16091
  {
15835
16092
  schema,
@@ -15850,15 +16107,15 @@ function AllOfSchema(props) {
15850
16107
  var AllOfSchema_default = AllOfSchema;
15851
16108
 
15852
16109
  // src/legacy/jsonSchemaForm/arrayTypeSchema/arrayListSchema/multipleFileUploadSchema/MultipleFileUploadSchema.tsx
15853
- var import_components49 = require("@transferwise/components");
15854
- var import_classnames7 = __toESM(require_classnames());
16110
+ var import_components50 = require("@transferwise/components");
16111
+ var import_classnames8 = __toESM(require_classnames());
15855
16112
  var import_react34 = require("react");
15856
16113
 
15857
16114
  // src/legacy/jsonSchemaForm/controlFeedback/ControlFeedback.tsx
15858
- var import_components48 = require("@transferwise/components");
16115
+ var import_components49 = require("@transferwise/components");
15859
16116
  var import_formatting2 = require("@transferwise/formatting");
15860
16117
  var import_react_intl25 = require("react-intl");
15861
- var import_jsx_runtime79 = require("react/jsx-runtime");
16118
+ var import_jsx_runtime80 = require("react/jsx-runtime");
15862
16119
  function ControlFeedback(props) {
15863
16120
  const { errors = "", validations = [], validationMessages = {} } = props;
15864
16121
  const defaultValidationMessages = useDefaultValidationMessages(props.schema);
@@ -15867,12 +16124,12 @@ function ControlFeedback(props) {
15867
16124
  const isValidationVisible = !isErrorVisible && (props.submitted || props.changed && props.blurred) && Boolean(validations == null ? void 0 : validations.length);
15868
16125
  const isDescriptionVisible = props.schema.type !== "boolean" && props.schema.description && !isErrorVisible && !isValidationVisible;
15869
16126
  const hasInfoMessage = Boolean(props.infoMessage);
15870
- return /* @__PURE__ */ (0, import_jsx_runtime79.jsxs)("div", { id: props.id, children: [
15871
- isErrorVisible ? /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(import_components48.InlineAlert, { type: "error", children: errors }) : null,
15872
- isValidationVisible ? /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(import_components48.InlineAlert, { type: "error", children: validations.map((validation) => /* @__PURE__ */ (0, import_jsx_runtime79.jsx)("div", { children: mergedValidationMessages[validation] }, validation)) }) : null,
15873
- (isDescriptionVisible || hasInfoMessage) && /* @__PURE__ */ (0, import_jsx_runtime79.jsxs)(import_components48.InlineAlert, { type: "info", children: [
15874
- isDescriptionVisible && /* @__PURE__ */ (0, import_jsx_runtime79.jsx)("div", { children: props.schema.description }),
15875
- hasInfoMessage && /* @__PURE__ */ (0, import_jsx_runtime79.jsx)("div", { children: props.infoMessage })
16127
+ return /* @__PURE__ */ (0, import_jsx_runtime80.jsxs)("div", { id: props.id, children: [
16128
+ isErrorVisible ? /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(import_components49.InlineAlert, { type: "error", children: errors }) : null,
16129
+ isValidationVisible ? /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(import_components49.InlineAlert, { type: "error", children: validations.map((validation) => /* @__PURE__ */ (0, import_jsx_runtime80.jsx)("div", { children: mergedValidationMessages[validation] }, validation)) }) : null,
16130
+ (isDescriptionVisible || hasInfoMessage) && /* @__PURE__ */ (0, import_jsx_runtime80.jsxs)(import_components49.InlineAlert, { type: "info", children: [
16131
+ isDescriptionVisible && /* @__PURE__ */ (0, import_jsx_runtime80.jsx)("div", { children: props.schema.description }),
16132
+ hasInfoMessage && /* @__PURE__ */ (0, import_jsx_runtime80.jsx)("div", { children: props.infoMessage })
15876
16133
  ] })
15877
16134
  ] });
15878
16135
  }
@@ -15992,7 +16249,7 @@ function useFormattedDefaultErrorMessages({
15992
16249
  }
15993
16250
 
15994
16251
  // src/legacy/jsonSchemaForm/arrayTypeSchema/arrayListSchema/multipleFileUploadSchema/MultipleFileUploadSchema.tsx
15995
- var import_jsx_runtime80 = require("react/jsx-runtime");
16252
+ var import_jsx_runtime81 = require("react/jsx-runtime");
15996
16253
  function MultipleFileUploadSchema(props) {
15997
16254
  var _a, _b;
15998
16255
  const { onChange, errors = null, schema, required = false } = props;
@@ -16053,10 +16310,10 @@ function MultipleFileUploadSchema(props) {
16053
16310
  onDeleteFile: () => Promise.resolve()
16054
16311
  });
16055
16312
  const feedbackId = `${uid}-feedback`;
16056
- return /* @__PURE__ */ (0, import_jsx_runtime80.jsxs)("div", { className: (0, import_classnames7.default)("form-group", { "has-error": showError }), children: [
16057
- /* @__PURE__ */ (0, import_jsx_runtime80.jsx)("label", { className: "d-block control-label", htmlFor: uid, children: props.schema.title }),
16058
- /* @__PURE__ */ (0, import_jsx_runtime80.jsx)("div", { "aria-describedby": feedbackId, children: /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(import_components49.UploadInput, __spreadValues({}, uploadInputProps)) }),
16059
- /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(
16313
+ return /* @__PURE__ */ (0, import_jsx_runtime81.jsxs)("div", { className: (0, import_classnames8.default)("form-group", { "has-error": showError }), children: [
16314
+ /* @__PURE__ */ (0, import_jsx_runtime81.jsx)("label", { className: "d-block control-label", htmlFor: uid, children: props.schema.title }),
16315
+ /* @__PURE__ */ (0, import_jsx_runtime81.jsx)("div", { "aria-describedby": feedbackId, children: /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(import_components50.UploadInput, __spreadValues({}, uploadInputProps)) }),
16316
+ /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(
16060
16317
  ControlFeedback_default,
16061
16318
  {
16062
16319
  id: feedbackId,
@@ -16078,7 +16335,7 @@ function getSuccessfullyProcessedFiles(allFiles) {
16078
16335
  return allFiles.filter((file) => !file.error && file.status === "succeeded");
16079
16336
  }
16080
16337
  function convertFileIdsToComponentFileObjects(fileIds) {
16081
- return fileIds.map((id) => isValidId(id) ? { id, status: import_components49.Status.SUCCEEDED } : null).filter((item) => item !== null);
16338
+ return fileIds.map((id) => isValidId(id) ? { id, status: import_components50.Status.SUCCEEDED } : null).filter((item) => item !== null);
16082
16339
  }
16083
16340
  function isValidId(id) {
16084
16341
  return isNumber3(id) || isString2(id);
@@ -16089,14 +16346,14 @@ function getValidationMessages(schema, required, defaultErrorMessages) {
16089
16346
  }
16090
16347
 
16091
16348
  // src/legacy/jsonSchemaForm/arrayTypeSchema/arrayListSchema/multiSelectSchema/MultiSelectSchema.tsx
16092
- var import_components51 = require("@transferwise/components");
16093
- var import_classnames8 = __toESM(require_classnames());
16349
+ var import_components52 = require("@transferwise/components");
16350
+ var import_classnames9 = __toESM(require_classnames());
16094
16351
  var import_react35 = require("react");
16095
16352
  var import_react_intl29 = require("react-intl");
16096
16353
 
16097
16354
  // src/legacy/jsonSchemaForm/schemaFormControl/utils/mapping-utils.tsx
16098
- var import_components50 = require("@transferwise/components");
16099
- var import_jsx_runtime81 = require("react/jsx-runtime");
16355
+ var import_components51 = require("@transferwise/components");
16356
+ var import_jsx_runtime82 = require("react/jsx-runtime");
16100
16357
  var mapConstSchemaToOption = (schema, controlType) => {
16101
16358
  switch (controlType) {
16102
16359
  case "select":
@@ -16120,7 +16377,7 @@ var mapKeywordsToSearchStrings = (searchStrings) => isArray2(searchStrings) ? {
16120
16377
  var mapImage = (image) => {
16121
16378
  if (image == null ? void 0 : image.url) {
16122
16379
  return {
16123
- icon: /* @__PURE__ */ (0, import_jsx_runtime81.jsx)("div", { className: "media", children: /* @__PURE__ */ (0, import_jsx_runtime81.jsx)("div", { className: "np-option__no-media-circle", children: /* @__PURE__ */ (0, import_jsx_runtime81.jsx)("img", { src: image.url, alt: image.name || "" }) }) }),
16380
+ icon: /* @__PURE__ */ (0, import_jsx_runtime82.jsx)("div", { className: "media", children: /* @__PURE__ */ (0, import_jsx_runtime82.jsx)("div", { className: "np-option__no-media-circle", children: /* @__PURE__ */ (0, import_jsx_runtime82.jsx)("img", { src: image.url, alt: image.name || "" }) }) }),
16124
16381
  hideIconInTrigger: true
16125
16382
  };
16126
16383
  }
@@ -16129,17 +16386,17 @@ var mapImage = (image) => {
16129
16386
  var getIconPropertyForSelectOption = (icon) => {
16130
16387
  if ((icon == null ? void 0 : icon.name) && isFlagIcon3(icon.name)) {
16131
16388
  return {
16132
- icon: /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(Flag, { code: icon.name.substring(5), intrinsicSize: 24 })
16389
+ icon: /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(Flag, { code: icon.name.substring(5), intrinsicSize: 24 })
16133
16390
  };
16134
16391
  }
16135
16392
  if ((icon == null ? void 0 : icon.name) && isValidIconName(icon.name)) {
16136
16393
  return {
16137
- icon: /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(DynamicIcon_default2, { type: icon.name })
16394
+ icon: /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(DynamicIcon_default2, { type: icon.name })
16138
16395
  };
16139
16396
  }
16140
16397
  if (icon == null ? void 0 : icon.text) {
16141
16398
  return {
16142
- icon: /* @__PURE__ */ (0, import_jsx_runtime81.jsx)("span", { children: icon.text })
16399
+ icon: /* @__PURE__ */ (0, import_jsx_runtime82.jsx)("span", { children: icon.text })
16143
16400
  };
16144
16401
  }
16145
16402
  return null;
@@ -16147,17 +16404,17 @@ var getIconPropertyForSelectOption = (icon) => {
16147
16404
  var getAvatarPropertyForRadioOption = ({ image, icon }) => {
16148
16405
  if (image == null ? void 0 : image.url) {
16149
16406
  return {
16150
- avatar: /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(import_components50.Avatar, { type: import_components50.AvatarType.THUMBNAIL, children: /* @__PURE__ */ (0, import_jsx_runtime81.jsx)("img", { src: image.url, alt: "" }) })
16407
+ avatar: /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(import_components51.Avatar, { type: import_components51.AvatarType.THUMBNAIL, children: /* @__PURE__ */ (0, import_jsx_runtime82.jsx)("img", { src: image.url, alt: "" }) })
16151
16408
  };
16152
16409
  }
16153
16410
  if ((icon == null ? void 0 : icon.name) && isValidIconName(icon.name)) {
16154
16411
  return {
16155
- avatar: /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(import_components50.Avatar, { type: import_components50.AvatarType.ICON, children: /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(DynamicIcon_default2, { type: icon.name }) })
16412
+ avatar: /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(import_components51.Avatar, { type: import_components51.AvatarType.ICON, children: /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(DynamicIcon_default2, { type: icon.name }) })
16156
16413
  };
16157
16414
  }
16158
16415
  if (icon == null ? void 0 : icon.text) {
16159
16416
  return {
16160
- avatar: /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(import_components50.Avatar, { type: import_components50.AvatarType.INITIALS, children: icon.text })
16417
+ avatar: /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(import_components51.Avatar, { type: import_components51.AvatarType.INITIALS, children: icon.text })
16161
16418
  };
16162
16419
  }
16163
16420
  return null;
@@ -16196,7 +16453,7 @@ var multi_select_messages_default2 = (0, import_react_intl28.defineMessages)({
16196
16453
  });
16197
16454
 
16198
16455
  // src/legacy/jsonSchemaForm/arrayTypeSchema/arrayListSchema/multiSelectSchema/MultiSelectSchema.tsx
16199
- var import_jsx_runtime82 = require("react/jsx-runtime");
16456
+ var import_jsx_runtime83 = require("react/jsx-runtime");
16200
16457
  function MultiSelectSchema({
16201
16458
  schema,
16202
16459
  model,
@@ -16250,10 +16507,10 @@ function MultiSelectSchema({
16250
16507
  "has-error": shouldShowInitialError || shouldShowValidationError,
16251
16508
  "has-info": !!schema.description
16252
16509
  };
16253
- return /* @__PURE__ */ (0, import_jsx_runtime82.jsxs)("div", { className: (0, import_classnames8.default)("d-flex flex-column", formGroupClasses), children: [
16254
- schema.title ? /* @__PURE__ */ (0, import_jsx_runtime82.jsx)("label", { className: "control-label d-inline m-b-1", htmlFor: id, children: schema.title }) : void 0,
16255
- /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(
16256
- import_components51.SelectInput,
16510
+ return /* @__PURE__ */ (0, import_jsx_runtime83.jsxs)("div", { className: (0, import_classnames9.default)("d-flex flex-column", formGroupClasses), children: [
16511
+ schema.title ? /* @__PURE__ */ (0, import_jsx_runtime83.jsx)("label", { className: "control-label d-inline m-b-1", htmlFor: id, children: schema.title }) : void 0,
16512
+ /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(
16513
+ import_components52.SelectInput,
16257
16514
  {
16258
16515
  id,
16259
16516
  multiple: true,
@@ -16278,12 +16535,12 @@ function MultiSelectSchema({
16278
16535
  if (withinTrigger) {
16279
16536
  return selected && index === selected[0] ? getFormattedMessage() : void 0;
16280
16537
  }
16281
- return /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(import_components51.SelectInputOptionContent, { title: label, note: note != null ? note : secondary, icon });
16538
+ return /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(import_components52.SelectInputOptionContent, { title: label, note: note != null ? note : secondary, icon });
16282
16539
  },
16283
16540
  onChange: broadcastModelChange
16284
16541
  }
16285
16542
  ),
16286
- /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(
16543
+ /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(
16287
16544
  ControlFeedback_default,
16288
16545
  {
16289
16546
  id: `${id}-feedback`,
@@ -16308,17 +16565,17 @@ var getInitialModelIndices2 = (model, options) => {
16308
16565
  };
16309
16566
 
16310
16567
  // src/legacy/jsonSchemaForm/arrayTypeSchema/arrayListSchema/repeatableSchema/RepeatableSchema.tsx
16311
- var import_components53 = require("@transferwise/components");
16568
+ var import_components54 = require("@transferwise/components");
16312
16569
  var import_icons4 = require("@transferwise/icons");
16313
16570
  var import_react37 = require("react");
16314
16571
  var import_react_intl32 = require("react-intl");
16315
16572
 
16316
16573
  // src/legacy/jsonSchemaForm/arrayTypeSchema/arrayListSchema/repeatableSchema/ItemSummary.tsx
16317
- var import_components52 = require("@transferwise/components");
16318
- var import_jsx_runtime83 = require("react/jsx-runtime");
16574
+ var import_components53 = require("@transferwise/components");
16575
+ var import_jsx_runtime84 = require("react/jsx-runtime");
16319
16576
  function ItemSummaryOption2({ item, onClick }) {
16320
- return /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(
16321
- import_components52.NavigationOption,
16577
+ return /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(
16578
+ import_components53.NavigationOption,
16322
16579
  {
16323
16580
  media: getNavigationOptionMedia(item),
16324
16581
  title: item.title,
@@ -16357,7 +16614,7 @@ var repeatable_messages_default2 = (0, import_react_intl30.defineMessages)({
16357
16614
  // src/legacy/jsonSchemaForm/arrayTypeSchema/arrayListSchema/repeatableSchema/RepeatableSchemaStep.tsx
16358
16615
  var import_react36 = require("react");
16359
16616
  var import_react_intl31 = require("react-intl");
16360
- var import_jsx_runtime84 = require("react/jsx-runtime");
16617
+ var import_jsx_runtime85 = require("react/jsx-runtime");
16361
16618
  function RepeatableSchemaStep({
16362
16619
  type,
16363
16620
  schema,
@@ -16405,7 +16662,7 @@ function RepeatableSchemaStep({
16405
16662
  }
16406
16663
  onModelChange(__spreadProps(__spreadValues({}, modelChangeProps), { model: model2 }));
16407
16664
  };
16408
- return /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(
16665
+ return /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(
16409
16666
  DynamicFlowStep,
16410
16667
  {
16411
16668
  step,
@@ -16610,8 +16867,8 @@ var schemaSummaryProvides = (summary, providesProp) => (
16610
16867
  );
16611
16868
 
16612
16869
  // src/legacy/jsonSchemaForm/arrayTypeSchema/arrayListSchema/repeatableSchema/RepeatableSchema.tsx
16613
- var import_classnames9 = __toESM(require_classnames());
16614
- var import_jsx_runtime85 = require("react/jsx-runtime");
16870
+ var import_classnames10 = __toESM(require_classnames());
16871
+ var import_jsx_runtime86 = require("react/jsx-runtime");
16615
16872
  function RepeatableSchema({
16616
16873
  schema,
16617
16874
  model,
@@ -16688,9 +16945,9 @@ function RepeatableSchema({
16688
16945
  const formGroupClasses = {
16689
16946
  "has-error": (_a = errors && !isEmpty(errors)) != null ? _a : submitted && validations.length
16690
16947
  };
16691
- return /* @__PURE__ */ (0, import_jsx_runtime85.jsxs)("div", { id, className: (0, import_classnames9.default)(formGroupClasses), children: [
16692
- schema.title && /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(import_components53.Header, { title: schema.title }),
16693
- itemSummaries == null ? void 0 : itemSummaries.map((itemSummary) => /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(
16948
+ return /* @__PURE__ */ (0, import_jsx_runtime86.jsxs)("div", { id, className: (0, import_classnames10.default)(formGroupClasses), children: [
16949
+ schema.title && /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(import_components54.Header, { title: schema.title }),
16950
+ itemSummaries == null ? void 0 : itemSummaries.map((itemSummary) => /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(
16694
16951
  ItemSummaryOption2,
16695
16952
  {
16696
16953
  item: itemSummary,
@@ -16698,21 +16955,21 @@ function RepeatableSchema({
16698
16955
  },
16699
16956
  JSON.stringify(itemSummary)
16700
16957
  )),
16701
- /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(
16702
- import_components53.NavigationOption,
16958
+ /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(
16959
+ import_components54.NavigationOption,
16703
16960
  {
16704
- media: /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(import_icons4.Plus, {}),
16961
+ media: /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(import_icons4.Plus, {}),
16705
16962
  title: schema.addItemTitle || formatMessage(repeatable_messages_default2.addItemTitle),
16706
16963
  showMediaAtAllSizes: true,
16707
16964
  onClick: onAddItem
16708
16965
  }
16709
16966
  ),
16710
- /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(
16711
- import_components53.Modal,
16967
+ /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(
16968
+ import_components54.Modal,
16712
16969
  {
16713
16970
  open: openModalType !== null,
16714
16971
  title: (openModalType === "add" ? schema.addItemTitle : schema.editItemTitle) || formatMessage(repeatable_messages_default2.addItemTitle),
16715
- body: /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(
16972
+ body: /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(
16716
16973
  RepeatableSchemaStep_default,
16717
16974
  {
16718
16975
  type: openModalType != null ? openModalType : "add",
@@ -16727,7 +16984,7 @@ function RepeatableSchema({
16727
16984
  onClose: onCancelEdit
16728
16985
  }
16729
16986
  ),
16730
- /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(
16987
+ /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(
16731
16988
  ControlFeedback_default,
16732
16989
  {
16733
16990
  id: `${id}-feedback`,
@@ -16769,38 +17026,38 @@ var getUpdatedItemSummaries = (action, {
16769
17026
  var RepeatableSchema_default = RepeatableSchema;
16770
17027
 
16771
17028
  // src/legacy/jsonSchemaForm/arrayTypeSchema/arrayListSchema/ArrayListSchema.tsx
16772
- var import_jsx_runtime86 = require("react/jsx-runtime");
17029
+ var import_jsx_runtime87 = require("react/jsx-runtime");
16773
17030
  function ArrayListSchema(props) {
16774
17031
  const { errors = null, schema } = props;
16775
17032
  if (isMultipleFileUploadSchema(schema)) {
16776
- return /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(MultipleFileUploadSchema_default, __spreadProps(__spreadValues({}, props), { errors, schema }));
17033
+ return /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(MultipleFileUploadSchema_default, __spreadProps(__spreadValues({}, props), { errors, schema }));
16777
17034
  }
16778
17035
  if (isMultiSelectConstSchema(schema)) {
16779
- return /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(MultiSelectSchema, __spreadProps(__spreadValues({}, props), { errors, schema }));
17036
+ return /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(MultiSelectSchema, __spreadProps(__spreadValues({}, props), { errors, schema }));
16780
17037
  }
16781
17038
  if (isListArraySchema(schema)) {
16782
- return /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(RepeatableSchema_default, __spreadProps(__spreadValues({}, props), { errors, schema }));
17039
+ return /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(RepeatableSchema_default, __spreadProps(__spreadValues({}, props), { errors, schema }));
16783
17040
  }
16784
17041
  throw new Error("Invalid array list schema");
16785
17042
  }
16786
17043
  var ArrayListSchema_default = ArrayListSchema;
16787
17044
 
16788
17045
  // src/legacy/jsonSchemaForm/arrayTypeSchema/ArraySchema.tsx
16789
- var import_jsx_runtime87 = require("react/jsx-runtime");
17046
+ var import_jsx_runtime88 = require("react/jsx-runtime");
16790
17047
  var ArraySchema = (props) => {
16791
17048
  const { schema } = props;
16792
17049
  if (isListArraySchema(schema)) {
16793
- return /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(ArrayListSchema_default, __spreadValues({}, props));
17050
+ return /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(ArrayListSchema_default, __spreadValues({}, props));
16794
17051
  }
16795
17052
  throw new Error("Not implemented");
16796
17053
  };
16797
17054
  var ArraySchema_default = ArraySchema;
16798
17055
 
16799
17056
  // src/legacy/jsonSchemaForm/objectSchema/ObjectSchema.tsx
16800
- var import_components54 = require("@transferwise/components");
16801
- var import_classnames10 = __toESM(require_classnames());
17057
+ var import_components55 = require("@transferwise/components");
17058
+ var import_classnames11 = __toESM(require_classnames());
16802
17059
  var import_react38 = require("react");
16803
- var import_jsx_runtime88 = require("react/jsx-runtime");
17060
+ var import_jsx_runtime89 = require("react/jsx-runtime");
16804
17061
  var getSchemaColumnClasses2 = (width) => ({
16805
17062
  "col-xs-12": true,
16806
17063
  "col-sm-6": width === "md",
@@ -16837,22 +17094,22 @@ function ObjectSchema(props) {
16837
17094
  const isPropertyDefined = (propertyName) => typeof props.schema.properties[propertyName] !== "undefined";
16838
17095
  const orderedPropertyNames = Array.from(allorderedPropertiesSet).filter(isPropertyDefined);
16839
17096
  const propsErrors = props.errors;
16840
- return /* @__PURE__ */ (0, import_jsx_runtime88.jsxs)(import_jsx_runtime88.Fragment, { children: [
16841
- props.schema.alert && /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(DynamicAlert_default, { component: props.schema.alert }),
16842
- /* @__PURE__ */ (0, import_jsx_runtime88.jsxs)("fieldset", { children: [
16843
- props.schema.title && !hideTitle && /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(import_components54.Header, { title: props.schema.title, as: "legend" }),
16844
- props.schema.description && !hideTitle && /* @__PURE__ */ (0, import_jsx_runtime88.jsxs)("p", { children: [
17097
+ return /* @__PURE__ */ (0, import_jsx_runtime89.jsxs)(import_jsx_runtime89.Fragment, { children: [
17098
+ props.schema.alert && /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(DynamicAlert_default, { component: props.schema.alert }),
17099
+ /* @__PURE__ */ (0, import_jsx_runtime89.jsxs)("fieldset", { children: [
17100
+ props.schema.title && !hideTitle && /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(import_components55.Header, { title: props.schema.title, as: "legend" }),
17101
+ props.schema.description && !hideTitle && /* @__PURE__ */ (0, import_jsx_runtime89.jsxs)("p", { children: [
16845
17102
  " ",
16846
17103
  props.schema.description,
16847
17104
  " "
16848
17105
  ] }),
16849
- /* @__PURE__ */ (0, import_jsx_runtime88.jsx)("div", { className: "row", children: orderedPropertyNames.map((propertyName) => /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(
17106
+ /* @__PURE__ */ (0, import_jsx_runtime89.jsx)("div", { className: "row", children: orderedPropertyNames.map((propertyName) => /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(
16850
17107
  "div",
16851
17108
  {
16852
- className: (0, import_classnames10.default)(
17109
+ className: (0, import_classnames11.default)(
16853
17110
  getSchemaColumnClasses2(props.schema.properties[propertyName].width)
16854
17111
  ),
16855
- children: /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(
17112
+ children: /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(
16856
17113
  GenericSchema_default,
16857
17114
  {
16858
17115
  schema: props.schema.properties[propertyName],
@@ -16874,12 +17131,12 @@ function ObjectSchema(props) {
16874
17131
  var ObjectSchema_default = ObjectSchema;
16875
17132
 
16876
17133
  // src/legacy/jsonSchemaForm/oneOfSchema/OneOfSchema.tsx
16877
- var import_components57 = require("@transferwise/components");
16878
- var import_classnames11 = __toESM(require_classnames());
17134
+ var import_components58 = require("@transferwise/components");
17135
+ var import_classnames12 = __toESM(require_classnames());
16879
17136
  var import_react41 = require("react");
16880
17137
 
16881
17138
  // src/legacy/jsonSchemaForm/help/Help.tsx
16882
- var import_components55 = require("@transferwise/components");
17139
+ var import_components56 = require("@transferwise/components");
16883
17140
  var import_react_intl34 = require("react-intl");
16884
17141
 
16885
17142
  // src/common/messages/help.messages.ts
@@ -16893,14 +17150,14 @@ var help_messages_default2 = (0, import_react_intl33.defineMessages)({
16893
17150
  });
16894
17151
 
16895
17152
  // src/legacy/jsonSchemaForm/help/Help.tsx
16896
- var import_jsx_runtime89 = require("react/jsx-runtime");
17153
+ var import_jsx_runtime90 = require("react/jsx-runtime");
16897
17154
  function Help2(props) {
16898
17155
  const intl = (0, import_react_intl34.useIntl)();
16899
- return /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(
16900
- import_components55.Info,
17156
+ return /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(
17157
+ import_components56.Info,
16901
17158
  {
16902
17159
  className: "m-l-1",
16903
- content: /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(import_components55.Markdown, { config: { link: { target: "_blank" } }, children: props.help.markdown }),
17160
+ content: /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(import_components56.Markdown, { config: { link: { target: "_blank" } }, children: props.help.markdown }),
16904
17161
  presentation: "POPOVER",
16905
17162
  size: "sm",
16906
17163
  "aria-label": intl.formatMessage(help_messages_default2.helpAria)
@@ -16914,7 +17171,7 @@ var import_react40 = require("react");
16914
17171
  var import_react_intl35 = require("react-intl");
16915
17172
 
16916
17173
  // src/legacy/formControl/FormControl.tsx
16917
- var import_components56 = require("@transferwise/components");
17174
+ var import_components57 = require("@transferwise/components");
16918
17175
  var import_react39 = require("react");
16919
17176
 
16920
17177
  // src/legacy/formControl/utils/value-utils.ts
@@ -17101,7 +17358,7 @@ var autocompleteTokenMap2 = {
17101
17358
  };
17102
17359
 
17103
17360
  // src/legacy/formControl/FormControl.tsx
17104
- var import_jsx_runtime90 = require("react/jsx-runtime");
17361
+ var import_jsx_runtime91 = require("react/jsx-runtime");
17105
17362
  var _FormControl = class _FormControl extends import_react39.PureComponent {
17106
17363
  constructor(props) {
17107
17364
  super(props);
@@ -17191,8 +17448,8 @@ var _FormControl = class _FormControl extends import_react39.PureComponent {
17191
17448
  } = this.props;
17192
17449
  switch (type) {
17193
17450
  case FormControlType.RADIO:
17194
- return /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(
17195
- import_components56.RadioGroup,
17451
+ return /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
17452
+ import_components57.RadioGroup,
17196
17453
  {
17197
17454
  radios: options.map(this.mapOption),
17198
17455
  name,
@@ -17207,8 +17464,8 @@ var _FormControl = class _FormControl extends import_react39.PureComponent {
17207
17464
  }
17208
17465
  );
17209
17466
  case FormControlType.CHECKBOX:
17210
- return /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(
17211
- import_components56.Checkbox,
17467
+ return /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
17468
+ import_components57.Checkbox,
17212
17469
  {
17213
17470
  checked: getSafeBooleanValue(value, { coerceValue: true }),
17214
17471
  disabled,
@@ -17225,8 +17482,8 @@ var _FormControl = class _FormControl extends import_react39.PureComponent {
17225
17482
  const search = options.length >= 8;
17226
17483
  const items = options;
17227
17484
  const selected = this.getSelectedOption(options);
17228
- return /* @__PURE__ */ (0, import_jsx_runtime90.jsx)("div", { className: "d-flex flex-column", children: /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(
17229
- import_components56.SelectInput,
17485
+ return /* @__PURE__ */ (0, import_jsx_runtime91.jsx)("div", { className: "d-flex flex-column", children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
17486
+ import_components57.SelectInput,
17230
17487
  {
17231
17488
  id,
17232
17489
  UNSAFE_triggerButtonProps: {
@@ -17241,8 +17498,8 @@ var _FormControl = class _FormControl extends import_react39.PureComponent {
17241
17498
  disabled: value2.disabled
17242
17499
  })),
17243
17500
  value: selected != null ? selected : null,
17244
- renderValue: ({ hideIconInTrigger, icon, label: label2, note, secondary }, withinTrigger) => /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(
17245
- import_components56.SelectInputOptionContent,
17501
+ renderValue: ({ hideIconInTrigger, icon, label: label2, note, secondary }, withinTrigger) => /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
17502
+ import_components57.SelectInputOptionContent,
17246
17503
  {
17247
17504
  title: label2,
17248
17505
  note: withinTrigger ? note != null ? note : secondary : note,
@@ -17270,13 +17527,13 @@ var _FormControl = class _FormControl extends import_react39.PureComponent {
17270
17527
  ) });
17271
17528
  }
17272
17529
  case FormControlType.TAB:
17273
- return /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(
17274
- import_components56.Tabs,
17530
+ return /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
17531
+ import_components57.Tabs,
17275
17532
  {
17276
17533
  selected: ((_a = this.getSelectedOption(options)) == null ? void 0 : _a.value) || 0,
17277
17534
  tabs: options.map((option) => ({
17278
17535
  title: option.label,
17279
- content: /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(import_jsx_runtime90.Fragment, {}),
17536
+ content: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(import_jsx_runtime91.Fragment, {}),
17280
17537
  disabled: option.disabled || false
17281
17538
  })),
17282
17539
  name: id,
@@ -17291,7 +17548,7 @@ var _FormControl = class _FormControl extends import_react39.PureComponent {
17291
17548
  );
17292
17549
  case FormControlType.NUMERIC:
17293
17550
  case FormControlType.NUMBER: {
17294
- return /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(
17551
+ return /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
17295
17552
  "input",
17296
17553
  {
17297
17554
  autoComplete: this.getAutocompleteValue(),
@@ -17325,7 +17582,7 @@ var _FormControl = class _FormControl extends import_react39.PureComponent {
17325
17582
  );
17326
17583
  }
17327
17584
  case FormControlType.HIDDEN:
17328
- return /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(
17585
+ return /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
17329
17586
  "input",
17330
17587
  {
17331
17588
  type: "hidden",
@@ -17335,7 +17592,7 @@ var _FormControl = class _FormControl extends import_react39.PureComponent {
17335
17592
  }
17336
17593
  );
17337
17594
  case FormControlType.PASSWORD:
17338
- return /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(
17595
+ return /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
17339
17596
  "input",
17340
17597
  {
17341
17598
  autoComplete: this.getAutocompleteValue(),
@@ -17355,8 +17612,8 @@ var _FormControl = class _FormControl extends import_react39.PureComponent {
17355
17612
  );
17356
17613
  case FormControlType.DATE:
17357
17614
  case FormControlType.DATETIME:
17358
- return /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(
17359
- import_components56.DateInput,
17615
+ return /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
17616
+ import_components57.DateInput,
17360
17617
  {
17361
17618
  "aria-labelledby": labelledBy,
17362
17619
  dayAutoComplete: this.getAutocompleteValue({ suffix: "-day" }),
@@ -17372,8 +17629,8 @@ var _FormControl = class _FormControl extends import_react39.PureComponent {
17372
17629
  }
17373
17630
  );
17374
17631
  case FormControlType.DATELOOKUP: {
17375
- return /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(
17376
- import_components56.DateLookup,
17632
+ return /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
17633
+ import_components57.DateLookup,
17377
17634
  {
17378
17635
  value: getSafeDateStringValue(value),
17379
17636
  min: minDate,
@@ -17390,8 +17647,8 @@ var _FormControl = class _FormControl extends import_react39.PureComponent {
17390
17647
  );
17391
17648
  }
17392
17649
  case FormControlType.TEL:
17393
- return /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(
17394
- import_components56.PhoneNumberInput,
17650
+ return /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
17651
+ import_components57.PhoneNumberInput,
17395
17652
  {
17396
17653
  disabled,
17397
17654
  countryCode,
@@ -17422,8 +17679,8 @@ var _FormControl = class _FormControl extends import_react39.PureComponent {
17422
17679
  autoComplete: this.getAutocompleteValue()
17423
17680
  };
17424
17681
  if (this.props.displayPattern) {
17425
- return /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(
17426
- import_components56.TextareaWithDisplayFormat,
17682
+ return /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
17683
+ import_components57.TextareaWithDisplayFormat,
17427
17684
  __spreadProps(__spreadValues({
17428
17685
  displayPattern: this.props.displayPattern
17429
17686
  }, textareaProps), {
@@ -17431,7 +17688,7 @@ var _FormControl = class _FormControl extends import_react39.PureComponent {
17431
17688
  })
17432
17689
  );
17433
17690
  }
17434
- return /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(
17691
+ return /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
17435
17692
  "textarea",
17436
17693
  __spreadProps(__spreadValues({}, textareaProps), {
17437
17694
  "aria-describedby": describedBy,
@@ -17441,8 +17698,8 @@ var _FormControl = class _FormControl extends import_react39.PureComponent {
17441
17698
  }
17442
17699
  case FormControlType.FILE:
17443
17700
  case FormControlType.UPLOAD: {
17444
- return /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(
17445
- import_components56.Upload,
17701
+ return /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
17702
+ import_components57.Upload,
17446
17703
  __spreadProps(__spreadValues({}, uploadProps), {
17447
17704
  usAccept: uploadProps.usAccept || "*",
17448
17705
  usDisabled: uploadProps.usDisabled || disabled,
@@ -17478,8 +17735,8 @@ var _FormControl = class _FormControl extends import_react39.PureComponent {
17478
17735
  autoComplete: this.getAutocompleteValue()
17479
17736
  };
17480
17737
  if (this.props.displayPattern) {
17481
- return /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(
17482
- import_components56.InputWithDisplayFormat,
17738
+ return /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
17739
+ import_components57.InputWithDisplayFormat,
17483
17740
  __spreadProps(__spreadValues({
17484
17741
  displayPattern: this.props.displayPattern
17485
17742
  }, inputProps), {
@@ -17487,7 +17744,7 @@ var _FormControl = class _FormControl extends import_react39.PureComponent {
17487
17744
  })
17488
17745
  );
17489
17746
  }
17490
- return /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(
17747
+ return /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
17491
17748
  "input",
17492
17749
  __spreadProps(__spreadValues({}, inputProps), {
17493
17750
  "aria-describedby": describedBy,
@@ -17537,7 +17794,7 @@ _FormControl.defaultProps = {
17537
17794
  var FormControl = _FormControl;
17538
17795
 
17539
17796
  // src/legacy/jsonSchemaForm/schemaFormControl/SchemaFormControl.tsx
17540
- var import_jsx_runtime91 = require("react/jsx-runtime");
17797
+ var import_jsx_runtime92 = require("react/jsx-runtime");
17541
17798
  var isNativeInput = (propsSchemaType) => propsSchemaType === "string" || propsSchemaType === "number";
17542
17799
  var getControlType = (schema) => {
17543
17800
  if (isOneOfSchema2(schema)) {
@@ -17654,7 +17911,7 @@ function SchemaFormControl(props) {
17654
17911
  labelledBy,
17655
17912
  required
17656
17913
  };
17657
- return /* @__PURE__ */ (0, import_jsx_runtime91.jsx)("div", { "aria-describedby": describedBy, children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(FormControl, __spreadValues(__spreadValues({ type: controlType, value: safeValue }, events), controlProps)) });
17914
+ return /* @__PURE__ */ (0, import_jsx_runtime92.jsx)("div", { "aria-describedby": describedBy, children: /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(FormControl, __spreadValues(__spreadValues({ type: controlType, value: safeValue }, events), controlProps)) });
17658
17915
  }
17659
17916
  var warnIfInvalidSchema = (schema, log, controlType) => {
17660
17917
  if (isOneOfSchema2(schema) && schema.oneOf.length === 2 && !schema.control) {
@@ -17676,7 +17933,7 @@ var warnIfInvalidSchema = (schema, log, controlType) => {
17676
17933
  var SchemaFormControl_default = SchemaFormControl;
17677
17934
 
17678
17935
  // src/legacy/jsonSchemaForm/oneOfSchema/OneOfSchema.tsx
17679
- var import_jsx_runtime92 = require("react/jsx-runtime");
17936
+ var import_jsx_runtime93 = require("react/jsx-runtime");
17680
17937
  function OneOfSchema(props) {
17681
17938
  const onEvent = useEventDispatcher();
17682
17939
  const [changed, setChanged] = (0, import_react41.useState)(false);
@@ -17755,12 +18012,12 @@ function OneOfSchema(props) {
17755
18012
  const isHidden = props.schema.hidden;
17756
18013
  const feedbackId = `${id}-feedback`;
17757
18014
  const labelId = `${id}-label`;
17758
- return !isHidden ? /* @__PURE__ */ (0, import_jsx_runtime92.jsxs)(import_jsx_runtime92.Fragment, { children: [
17759
- (props.schema.oneOf.length > 1 || isConstSchema2(props.schema.oneOf[0])) && /* @__PURE__ */ (0, import_jsx_runtime92.jsxs)(import_jsx_runtime92.Fragment, { children: [
17760
- props.schema.alert && /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(DynamicAlert_default, { component: props.schema.alert }),
17761
- /* @__PURE__ */ (0, import_jsx_runtime92.jsxs)("div", { className: (0, import_classnames11.default)(formGroupClasses), children: [
18015
+ return !isHidden ? /* @__PURE__ */ (0, import_jsx_runtime93.jsxs)(import_jsx_runtime93.Fragment, { children: [
18016
+ (props.schema.oneOf.length > 1 || isConstSchema2(props.schema.oneOf[0])) && /* @__PURE__ */ (0, import_jsx_runtime93.jsxs)(import_jsx_runtime93.Fragment, { children: [
18017
+ props.schema.alert && /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(DynamicAlert_default, { component: props.schema.alert }),
18018
+ /* @__PURE__ */ (0, import_jsx_runtime93.jsxs)("div", { className: (0, import_classnames12.default)(formGroupClasses), children: [
17762
18019
  getTitleAndHelp(props.schema, id, labelId),
17763
- /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(
18020
+ /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(
17764
18021
  SchemaFormControl_default,
17765
18022
  {
17766
18023
  id,
@@ -17777,7 +18034,7 @@ function OneOfSchema(props) {
17777
18034
  onSearchChange
17778
18035
  }
17779
18036
  ),
17780
- /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(
18037
+ /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(
17781
18038
  ControlFeedback_default,
17782
18039
  {
17783
18040
  id: feedbackId,
@@ -17793,7 +18050,7 @@ function OneOfSchema(props) {
17793
18050
  )
17794
18051
  ] })
17795
18052
  ] }),
17796
- isNoNConstSchema(props.schema.oneOf[schemaIndex]) && /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(
18053
+ isNoNConstSchema(props.schema.oneOf[schemaIndex]) && /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(
17797
18054
  GenericSchema_default,
17798
18055
  {
17799
18056
  schema: props.schema.oneOf[schemaIndex],
@@ -17810,16 +18067,16 @@ function OneOfSchema(props) {
17810
18067
  }
17811
18068
  function getTitleAndHelp(schema, forId, labelId) {
17812
18069
  var _a;
17813
- const helpElement = schema.help ? /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(Help_default2, { help: schema.help }) : null;
17814
- const titleElement = isConstSchema2(schema.oneOf[0]) ? /* @__PURE__ */ (0, import_jsx_runtime92.jsx)("div", { className: "m-b-1", children: /* @__PURE__ */ (0, import_jsx_runtime92.jsxs)("label", { className: "control-label d-inline", id: labelId, htmlFor: forId, children: [
18070
+ const helpElement = schema.help ? /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(Help_default2, { help: schema.help }) : null;
18071
+ const titleElement = isConstSchema2(schema.oneOf[0]) ? /* @__PURE__ */ (0, import_jsx_runtime93.jsx)("div", { className: "m-b-1", children: /* @__PURE__ */ (0, import_jsx_runtime93.jsxs)("label", { className: "control-label d-inline", id: labelId, htmlFor: forId, children: [
17815
18072
  schema.title,
17816
18073
  " ",
17817
18074
  helpElement
17818
- ] }) }) : /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(import_jsx_runtime92.Fragment, { children: helpElement ? /* @__PURE__ */ (0, import_jsx_runtime92.jsxs)("h4", { className: "m-b-2", children: [
18075
+ ] }) }) : /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(import_jsx_runtime93.Fragment, { children: helpElement ? /* @__PURE__ */ (0, import_jsx_runtime93.jsxs)("h4", { className: "m-b-2", children: [
17819
18076
  schema.title,
17820
18077
  " ",
17821
18078
  helpElement
17822
- ] }) : /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(import_components57.Header, { title: (_a = schema.title) != null ? _a : "" }) });
18079
+ ] }) : /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(import_components58.Header, { title: (_a = schema.title) != null ? _a : "" }) });
17823
18080
  return schema.title ? titleElement : helpElement;
17824
18081
  }
17825
18082
  function getValidations(props, schemaIndex) {
@@ -17852,14 +18109,14 @@ function mapOneOfToConst(schema, index) {
17852
18109
  var OneOfSchema_default = OneOfSchema;
17853
18110
 
17854
18111
  // src/legacy/jsonSchemaForm/persistAsyncSchema/persistAsyncBlobSchema/PersistAsyncBlobSchema.tsx
17855
- var import_classnames12 = __toESM(require_classnames());
18112
+ var import_classnames13 = __toESM(require_classnames());
17856
18113
  var import_react43 = require("react");
17857
18114
  var import_react_intl36 = require("react-intl");
17858
18115
 
17859
18116
  // src/legacy/jsonSchemaForm/persistAsyncSchema/persistAsyncBlobSchema/UploadInputAdapter.tsx
17860
- var import_components58 = require("@transferwise/components");
18117
+ var import_components59 = require("@transferwise/components");
17861
18118
  var import_react42 = require("react");
17862
- var import_jsx_runtime93 = require("react/jsx-runtime");
18119
+ var import_jsx_runtime94 = require("react/jsx-runtime");
17863
18120
  function UploadInputAdapter(props) {
17864
18121
  const {
17865
18122
  id,
@@ -17875,7 +18132,7 @@ function UploadInputAdapter(props) {
17875
18132
  onCancel
17876
18133
  } = props;
17877
18134
  const onEvent = useEventDispatcher();
17878
- const files = (0, import_react42.useMemo)(() => fileId ? [{ id: fileId, status: import_components58.Status.SUCCEEDED }] : [], [fileId]);
18135
+ const files = (0, import_react42.useMemo)(() => fileId ? [{ id: fileId, status: import_components59.Status.SUCCEEDED }] : [], [fileId]);
17879
18136
  const uploadFile = (formData) => {
17880
18137
  onEvent("Dynamic Flow - PersistAsync", { status: "pending", schemaId: id });
17881
18138
  return httpClient(String(httpOptions.url), {
@@ -17894,8 +18151,8 @@ function UploadInputAdapter(props) {
17894
18151
  return Promise.reject();
17895
18152
  });
17896
18153
  };
17897
- return /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(
17898
- import_components58.UploadInput,
18154
+ return /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(
18155
+ import_components59.UploadInput,
17899
18156
  {
17900
18157
  id,
17901
18158
  fileInputName: httpOptions.fileInputName,
@@ -17914,7 +18171,7 @@ function UploadInputAdapter(props) {
17914
18171
  }
17915
18172
 
17916
18173
  // src/legacy/jsonSchemaForm/persistAsyncSchema/persistAsyncBlobSchema/PersistAsyncBlobSchema.tsx
17917
- var import_jsx_runtime94 = require("react/jsx-runtime");
18174
+ var import_jsx_runtime95 = require("react/jsx-runtime");
17918
18175
  function PersistAsyncBlobSchema(props) {
17919
18176
  const { model, schema, submitted, required = false, errors, onChange } = props;
17920
18177
  const [persistAsyncValidationMessages, setPersistAsyncValidationMessages] = (0, import_react43.useState)({});
@@ -17962,8 +18219,8 @@ function PersistAsyncBlobSchema(props) {
17962
18219
  };
17963
18220
  const id = schema.$id || schema.persistAsync.schema.$id || schema.persistAsync.idProperty;
17964
18221
  const feedbackId = `${id}-feedback`;
17965
- return /* @__PURE__ */ (0, import_jsx_runtime94.jsxs)("div", { className: (0, import_classnames12.default)(formGroupClasses), children: [
17966
- /* @__PURE__ */ (0, import_jsx_runtime94.jsx)("div", { "aria-describedby": feedbackId, children: /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(
18222
+ return /* @__PURE__ */ (0, import_jsx_runtime95.jsxs)("div", { className: (0, import_classnames13.default)(formGroupClasses), children: [
18223
+ /* @__PURE__ */ (0, import_jsx_runtime95.jsx)("div", { "aria-describedby": feedbackId, children: /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(
17967
18224
  UploadInputAdapter,
17968
18225
  __spreadValues({
17969
18226
  id,
@@ -17981,7 +18238,7 @@ function PersistAsyncBlobSchema(props) {
17981
18238
  onCancel
17982
18239
  }, mapSchemaToUploadOptions(schema.persistAsync.schema))
17983
18240
  ) }),
17984
- /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(
18241
+ /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(
17985
18242
  ControlFeedback_default,
17986
18243
  {
17987
18244
  id: feedbackId,
@@ -18007,17 +18264,17 @@ var getResponseJsonObject = async (response) => {
18007
18264
  var PersistAsyncBlobSchema_default = PersistAsyncBlobSchema;
18008
18265
 
18009
18266
  // src/legacy/jsonSchemaForm/persistAsyncSchema/PersistAsyncSchema.tsx
18010
- var import_jsx_runtime95 = require("react/jsx-runtime");
18267
+ var import_jsx_runtime96 = require("react/jsx-runtime");
18011
18268
  function PersistAsyncSchema(props) {
18012
18269
  const { schema } = props;
18013
18270
  const persistAsyncSchemaType = schema.persistAsync.schema.type;
18014
18271
  if (persistAsyncSchemaType === "blob") {
18015
- return /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(
18272
+ return /* @__PURE__ */ (0, import_jsx_runtime96.jsx)(
18016
18273
  PersistAsyncBlobSchema_default,
18017
18274
  __spreadValues({}, props)
18018
18275
  );
18019
18276
  }
18020
- return /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(PersistAsyncBasicSchema_default, __spreadValues({}, props));
18277
+ return /* @__PURE__ */ (0, import_jsx_runtime96.jsx)(PersistAsyncBasicSchema_default, __spreadValues({}, props));
18021
18278
  }
18022
18279
  var PersistAsyncSchema_default = PersistAsyncSchema;
18023
18280
 
@@ -18034,8 +18291,8 @@ var getSelectionFromModel = (schema, model) => {
18034
18291
  };
18035
18292
 
18036
18293
  // src/legacy/jsonSchemaForm/promotedOneOfSchema/promotedOneOfControl/PromotedOneOfCheckboxControl.tsx
18037
- var import_components59 = require("@transferwise/components");
18038
- var import_jsx_runtime96 = require("react/jsx-runtime");
18294
+ var import_components60 = require("@transferwise/components");
18295
+ var import_jsx_runtime97 = require("react/jsx-runtime");
18039
18296
  var PromotedOneOfCheckboxControl = (props) => {
18040
18297
  const { id, selection, setSelection } = props;
18041
18298
  const { promoted, other, checkedMeans } = props.promotion;
@@ -18046,13 +18303,13 @@ var PromotedOneOfCheckboxControl = (props) => {
18046
18303
  const toggleSelection = () => {
18047
18304
  setSelection(checked ? selectionWhenUnchecked : selectionWhenChecked);
18048
18305
  };
18049
- return /* @__PURE__ */ (0, import_jsx_runtime96.jsx)("div", { className: "form-group", children: /* @__PURE__ */ (0, import_jsx_runtime96.jsx)(import_components59.Checkbox, { id, label: title, checked, onChange: toggleSelection }) });
18306
+ return /* @__PURE__ */ (0, import_jsx_runtime97.jsx)("div", { className: "form-group", children: /* @__PURE__ */ (0, import_jsx_runtime97.jsx)(import_components60.Checkbox, { id, label: title, checked, onChange: toggleSelection }) });
18050
18307
  };
18051
18308
  var PromotedOneOfCheckboxControl_default = PromotedOneOfCheckboxControl;
18052
18309
 
18053
18310
  // src/legacy/jsonSchemaForm/promotedOneOfSchema/promotedOneOfControl/PromotedOneOfRadioControl.tsx
18054
- var import_components60 = require("@transferwise/components");
18055
- var import_jsx_runtime97 = require("react/jsx-runtime");
18311
+ var import_components61 = require("@transferwise/components");
18312
+ var import_jsx_runtime98 = require("react/jsx-runtime");
18056
18313
  function PromotedOneOfRadioControl(props) {
18057
18314
  var _a, _b;
18058
18315
  const { id, selection, setSelection, promotion, promotedOneOf, title } = props;
@@ -18069,10 +18326,10 @@ function PromotedOneOfRadioControl(props) {
18069
18326
  secondary: promotion.other.description
18070
18327
  }, getAvatarPropertyForRadioOption(promotion.other))
18071
18328
  ];
18072
- return /* @__PURE__ */ (0, import_jsx_runtime97.jsxs)("div", { className: "form-group", children: [
18073
- title && /* @__PURE__ */ (0, import_jsx_runtime97.jsx)("label", { className: "control-label", htmlFor: id, children: title }),
18074
- /* @__PURE__ */ (0, import_jsx_runtime97.jsx)(
18075
- import_components60.RadioGroup,
18329
+ return /* @__PURE__ */ (0, import_jsx_runtime98.jsxs)("div", { className: "form-group", children: [
18330
+ title && /* @__PURE__ */ (0, import_jsx_runtime98.jsx)("label", { className: "control-label", htmlFor: id, children: title }),
18331
+ /* @__PURE__ */ (0, import_jsx_runtime98.jsx)(
18332
+ import_components61.RadioGroup,
18076
18333
  {
18077
18334
  name: "promoted-selection",
18078
18335
  selectedValue: selection,
@@ -18089,16 +18346,16 @@ PromotedOneOfRadioControl.defaultProps = {
18089
18346
  var PromotedOneOfRadioControl_default = PromotedOneOfRadioControl;
18090
18347
 
18091
18348
  // src/legacy/jsonSchemaForm/promotedOneOfSchema/promotedOneOfControl/PromotedOneOfControl.tsx
18092
- var import_jsx_runtime98 = require("react/jsx-runtime");
18349
+ var import_jsx_runtime99 = require("react/jsx-runtime");
18093
18350
  function PromotedOneOfControl(props) {
18094
18351
  const controlType = props.promotion.control || "radio";
18095
18352
  switch (controlType) {
18096
18353
  case "radio":
18097
- return /* @__PURE__ */ (0, import_jsx_runtime98.jsx)(PromotedOneOfRadioControl_default, __spreadValues({}, props));
18354
+ return /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(PromotedOneOfRadioControl_default, __spreadValues({}, props));
18098
18355
  case "checkbox":
18099
- return /* @__PURE__ */ (0, import_jsx_runtime98.jsx)(PromotedOneOfCheckboxControl_default, __spreadValues({}, props));
18356
+ return /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(PromotedOneOfCheckboxControl_default, __spreadValues({}, props));
18100
18357
  default:
18101
- return /* @__PURE__ */ (0, import_jsx_runtime98.jsx)(import_jsx_runtime98.Fragment, {});
18358
+ return /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(import_jsx_runtime99.Fragment, {});
18102
18359
  }
18103
18360
  }
18104
18361
  PromotedOneOfControl.defaultProps = {
@@ -18108,7 +18365,7 @@ PromotedOneOfControl.defaultProps = {
18108
18365
  var PromotedOneOfControl_default = PromotedOneOfControl;
18109
18366
 
18110
18367
  // src/legacy/jsonSchemaForm/promotedOneOfSchema/PromotedOneOfSchema.tsx
18111
- var import_jsx_runtime99 = require("react/jsx-runtime");
18368
+ var import_jsx_runtime100 = require("react/jsx-runtime");
18112
18369
  var isPromoted = (schema) => schema.promoted === true;
18113
18370
  var PromotedOneOfSchema = (props) => {
18114
18371
  var _a;
@@ -18119,9 +18376,9 @@ var PromotedOneOfSchema = (props) => {
18119
18376
  const promotedOneOf = props.schema.oneOf.find(isPromoted);
18120
18377
  const promotedObjectSchema = getPromotedObjectSchema(promotedOneOf);
18121
18378
  const otherOneOf = getOtherOneOf(props.schema);
18122
- return /* @__PURE__ */ (0, import_jsx_runtime99.jsxs)(import_jsx_runtime99.Fragment, { children: [
18123
- promotedAlert && /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(DynamicAlert_default, { component: promotedAlert }),
18124
- /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(
18379
+ return /* @__PURE__ */ (0, import_jsx_runtime100.jsxs)(import_jsx_runtime100.Fragment, { children: [
18380
+ promotedAlert && /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(DynamicAlert_default, { component: promotedAlert }),
18381
+ /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(
18125
18382
  PromotedOneOfControl_default,
18126
18383
  {
18127
18384
  id: props.schema.$id,
@@ -18132,8 +18389,8 @@ var PromotedOneOfSchema = (props) => {
18132
18389
  setSelection
18133
18390
  }
18134
18391
  ),
18135
- selection === "promoted" && /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(ObjectSchema_default, __spreadProps(__spreadValues({}, props), { schema: promotedObjectSchema })),
18136
- selection === "other" && /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(GenericSchema_default, __spreadProps(__spreadValues({}, props), { schema: otherOneOf }))
18392
+ selection === "promoted" && /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(ObjectSchema_default, __spreadProps(__spreadValues({}, props), { schema: promotedObjectSchema })),
18393
+ selection === "other" && /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(GenericSchema_default, __spreadProps(__spreadValues({}, props), { schema: otherOneOf }))
18137
18394
  ] });
18138
18395
  };
18139
18396
  function getPromotedObjectSchema(promotedSchema) {
@@ -18163,7 +18420,7 @@ function getOtherOneOf(schema) {
18163
18420
  var PromotedOneOfSchema_default = PromotedOneOfSchema;
18164
18421
 
18165
18422
  // src/legacy/jsonSchemaForm/readOnlySchema/ReadOnlySchema.tsx
18166
- var import_components61 = require("@transferwise/components");
18423
+ var import_components62 = require("@transferwise/components");
18167
18424
  var import_react_intl38 = require("react-intl");
18168
18425
 
18169
18426
  // src/legacy/jsonSchemaForm/readOnlySchema/ReadOnlySchema.messages.ts
@@ -18182,12 +18439,12 @@ var ReadOnlySchema_messages_default = (0, import_react_intl37.defineMessages)({
18182
18439
  });
18183
18440
 
18184
18441
  // src/legacy/jsonSchemaForm/readOnlySchema/ReadOnlySchema.tsx
18185
- var import_jsx_runtime100 = require("react/jsx-runtime");
18442
+ var import_jsx_runtime101 = require("react/jsx-runtime");
18186
18443
  function ReadOnlySchema({ schema, model }) {
18187
18444
  const { title = "" } = schema;
18188
18445
  const { formatMessage } = (0, import_react_intl38.useIntl)();
18189
18446
  const value = getValueForSchema({ schema, model, formatMessage });
18190
- return /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(import_components61.DefinitionList, { layout: import_components61.Layout.VERTICAL_ONE_COLUMN, definitions: [{ title, value, key: "" }] });
18447
+ return /* @__PURE__ */ (0, import_jsx_runtime101.jsx)(import_components62.DefinitionList, { layout: import_components62.Layout.VERTICAL_ONE_COLUMN, definitions: [{ title, value, key: "" }] });
18191
18448
  }
18192
18449
  var ReadOnlySchema_default = ReadOnlySchema;
18193
18450
  function getValueForSchema({
@@ -18220,7 +18477,7 @@ function getSelectedOneOf(schema, model) {
18220
18477
  function getValueFromOption(option) {
18221
18478
  const text = option.title && option.description ? `${option.title} - ${option.description}` : option.title || "";
18222
18479
  const icon = getAvatarPropertyForRadioOption({ icon: option.icon });
18223
- return (icon == null ? void 0 : icon.avatar) ? /* @__PURE__ */ (0, import_jsx_runtime100.jsxs)(import_jsx_runtime100.Fragment, { children: [
18480
+ return (icon == null ? void 0 : icon.avatar) ? /* @__PURE__ */ (0, import_jsx_runtime101.jsxs)(import_jsx_runtime101.Fragment, { children: [
18224
18481
  icon.avatar,
18225
18482
  " ",
18226
18483
  text
@@ -18229,7 +18486,7 @@ function getValueFromOption(option) {
18229
18486
 
18230
18487
  // src/legacy/jsonSchemaForm/validationAsyncSchema/ValidationAsyncSchema.tsx
18231
18488
  var import_react45 = require("react");
18232
- var import_jsx_runtime101 = require("react/jsx-runtime");
18489
+ var import_jsx_runtime102 = require("react/jsx-runtime");
18233
18490
  function ValidationAsyncSchema(props) {
18234
18491
  const { schema, model, required = false, submitted, errors, onChange } = props;
18235
18492
  const [validationAsyncModel, setValidationAsyncModel] = (0, import_react45.useState)(model);
@@ -18313,12 +18570,12 @@ function ValidationAsyncSchema(props) {
18313
18570
  required,
18314
18571
  schema
18315
18572
  };
18316
- return /* @__PURE__ */ (0, import_jsx_runtime101.jsx)(BasicTypeSchema_default, __spreadValues({}, basicTypeSchemaProps));
18573
+ return /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(BasicTypeSchema_default, __spreadValues({}, basicTypeSchemaProps));
18317
18574
  }
18318
18575
  var ValidationAsyncSchema_default = ValidationAsyncSchema;
18319
18576
 
18320
18577
  // src/legacy/jsonSchemaForm/genericSchema/GenericSchema.tsx
18321
- var import_jsx_runtime102 = require("react/jsx-runtime");
18578
+ var import_jsx_runtime103 = require("react/jsx-runtime");
18322
18579
  var import_react47 = require("react");
18323
18580
  function GenericSchemaForm(props) {
18324
18581
  const { schema, model = null, errors = null, hideTitle = false, disabled = false } = props;
@@ -18335,29 +18592,29 @@ function GenericSchemaForm(props) {
18335
18592
  }, [JSON.stringify(schema), JSON.stringify(model), JSON.stringify(errors), type, log]);
18336
18593
  switch (type) {
18337
18594
  case "readOnly":
18338
- return /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(ReadOnlySchema_default, __spreadValues({}, schemaProps));
18595
+ return /* @__PURE__ */ (0, import_jsx_runtime103.jsx)(ReadOnlySchema_default, __spreadValues({}, schemaProps));
18339
18596
  case "persistAsync":
18340
- return /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(PersistAsyncSchema_default, __spreadValues({}, schemaProps));
18597
+ return /* @__PURE__ */ (0, import_jsx_runtime103.jsx)(PersistAsyncSchema_default, __spreadValues({}, schemaProps));
18341
18598
  case "validationAsync":
18342
- return /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(ValidationAsyncSchema_default, __spreadValues({}, schemaProps));
18599
+ return /* @__PURE__ */ (0, import_jsx_runtime103.jsx)(ValidationAsyncSchema_default, __spreadValues({}, schemaProps));
18343
18600
  case "basic": {
18344
18601
  const basicTypeProps = __spreadValues({
18345
18602
  infoMessage: null
18346
18603
  }, schemaProps);
18347
- return /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(BasicTypeSchema_default, __spreadValues({}, basicTypeProps));
18604
+ return /* @__PURE__ */ (0, import_jsx_runtime103.jsx)(BasicTypeSchema_default, __spreadValues({}, basicTypeProps));
18348
18605
  }
18349
18606
  case "object":
18350
18607
  return /* @__PURE__ */ (0, import_react47.createElement)(ObjectSchema_default, __spreadProps(__spreadValues({}, schemaProps), { key: JSON.stringify(schema) }));
18351
18608
  case "array":
18352
- return /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(ArraySchema_default, __spreadValues({}, schemaProps));
18609
+ return /* @__PURE__ */ (0, import_jsx_runtime103.jsx)(ArraySchema_default, __spreadValues({}, schemaProps));
18353
18610
  case "promotedOneOf":
18354
- return /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(PromotedOneOfSchema_default, __spreadValues({}, schemaProps));
18611
+ return /* @__PURE__ */ (0, import_jsx_runtime103.jsx)(PromotedOneOfSchema_default, __spreadValues({}, schemaProps));
18355
18612
  case "oneOf":
18356
- return /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(OneOfSchema_default, __spreadValues({}, schemaProps));
18613
+ return /* @__PURE__ */ (0, import_jsx_runtime103.jsx)(OneOfSchema_default, __spreadValues({}, schemaProps));
18357
18614
  case "allOf":
18358
- return /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(AllOfSchema_default, __spreadValues({}, schemaProps));
18615
+ return /* @__PURE__ */ (0, import_jsx_runtime103.jsx)(AllOfSchema_default, __spreadValues({}, schemaProps));
18359
18616
  }
18360
- return /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(import_jsx_runtime102.Fragment, {});
18617
+ return /* @__PURE__ */ (0, import_jsx_runtime103.jsx)(import_jsx_runtime103.Fragment, {});
18361
18618
  }
18362
18619
  var GenericSchema_default = GenericSchemaForm;
18363
18620
  var isValidGenericSchema = (schema, model, errors) => {
@@ -18384,7 +18641,7 @@ var isValidGenericSchema = (schema, model, errors) => {
18384
18641
  };
18385
18642
 
18386
18643
  // src/legacy/layout/form/DynamicForm.tsx
18387
- var import_jsx_runtime103 = require("react/jsx-runtime");
18644
+ var import_jsx_runtime104 = require("react/jsx-runtime");
18388
18645
  function DynamicForm({
18389
18646
  component,
18390
18647
  model = null,
@@ -18394,7 +18651,7 @@ function DynamicForm({
18394
18651
  onPersistAsync
18395
18652
  }) {
18396
18653
  const formSchema = component.schema;
18397
- return /* @__PURE__ */ (0, import_jsx_runtime103.jsx)("div", { className: getMargin2(component.margin || "md"), children: /* @__PURE__ */ (0, import_jsx_runtime103.jsx)(
18654
+ return /* @__PURE__ */ (0, import_jsx_runtime104.jsx)("div", { className: getMargin2(component.margin || "md"), children: /* @__PURE__ */ (0, import_jsx_runtime104.jsx)(
18398
18655
  GenericSchema_default,
18399
18656
  {
18400
18657
  schema: formSchema,
@@ -18411,68 +18668,82 @@ function DynamicForm({
18411
18668
  var DynamicForm_default = DynamicForm;
18412
18669
 
18413
18670
  // src/legacy/layout/heading/DynamicHeading.tsx
18414
- var import_components62 = require("@transferwise/components");
18415
- var import_classnames13 = __toESM(require_classnames());
18416
- var import_jsx_runtime104 = require("react/jsx-runtime");
18671
+ var import_components63 = require("@transferwise/components");
18672
+ var import_classnames14 = __toESM(require_classnames());
18673
+ var import_jsx_runtime105 = require("react/jsx-runtime");
18417
18674
  var DynamicHeading = (props) => {
18418
18675
  const { text, size: size2 = "md", align = "left", margin = "md", control } = props.component;
18419
- const classes = (0, import_classnames13.default)(getTextAlignmentAndMargin2({ align, margin }));
18420
- return control === "display" ? /* @__PURE__ */ (0, import_jsx_runtime104.jsx)(DisplayHeading2, { size: size2, text, classes }) : /* @__PURE__ */ (0, import_jsx_runtime104.jsx)(StandardHeading2, { size: size2, text, classes });
18676
+ const classes = (0, import_classnames14.default)(getTextAlignmentAndMargin2({ align, margin }));
18677
+ return control === "display" ? /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(DisplayHeading2, { size: size2, text, classes }) : /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(StandardHeading2, { size: size2, text, classes });
18421
18678
  };
18422
18679
  var StandardHeading2 = ({ size: size2, text, classes }) => {
18423
18680
  switch (size2) {
18424
18681
  case "xs":
18425
- return /* @__PURE__ */ (0, import_jsx_runtime104.jsx)("h5", { className: classes, children: text });
18682
+ return /* @__PURE__ */ (0, import_jsx_runtime105.jsx)("h5", { className: classes, children: text });
18426
18683
  case "sm":
18427
- return /* @__PURE__ */ (0, import_jsx_runtime104.jsx)("h4", { className: classes, children: text });
18684
+ return /* @__PURE__ */ (0, import_jsx_runtime105.jsx)("h4", { className: classes, children: text });
18428
18685
  case "lg":
18429
- return /* @__PURE__ */ (0, import_jsx_runtime104.jsx)("h2", { className: classes, children: text });
18686
+ return /* @__PURE__ */ (0, import_jsx_runtime105.jsx)("h2", { className: classes, children: text });
18430
18687
  case "xl":
18431
- return /* @__PURE__ */ (0, import_jsx_runtime104.jsx)("h1", { className: classes, children: text });
18688
+ return /* @__PURE__ */ (0, import_jsx_runtime105.jsx)("h1", { className: classes, children: text });
18432
18689
  case "md":
18433
18690
  default:
18434
- return /* @__PURE__ */ (0, import_jsx_runtime104.jsx)("h3", { className: classes, children: text });
18691
+ return /* @__PURE__ */ (0, import_jsx_runtime105.jsx)("h3", { className: classes, children: text });
18435
18692
  }
18436
18693
  };
18437
18694
  var DisplayHeading2 = ({ size: size2, text, classes }) => {
18438
18695
  switch (size2) {
18439
18696
  case "xs":
18440
18697
  case "sm":
18441
- return /* @__PURE__ */ (0, import_jsx_runtime104.jsx)(import_components62.Display, { type: "display-small", className: classes, children: text });
18698
+ return /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(import_components63.Display, { type: "display-small", className: classes, children: text });
18442
18699
  case "xl":
18443
18700
  case "lg":
18444
- return /* @__PURE__ */ (0, import_jsx_runtime104.jsx)(import_components62.Display, { type: "display-large", className: classes, children: text });
18701
+ return /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(import_components63.Display, { type: "display-large", className: classes, children: text });
18445
18702
  case "md":
18446
18703
  default:
18447
- return /* @__PURE__ */ (0, import_jsx_runtime104.jsx)(import_components62.Display, { type: "display-medium", className: classes, children: text });
18704
+ return /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(import_components63.Display, { type: "display-medium", className: classes, children: text });
18448
18705
  }
18449
18706
  };
18450
18707
  var DynamicHeading_default = DynamicHeading;
18451
18708
 
18452
18709
  // src/legacy/layout/markdown/DynamicMarkdown.tsx
18453
- var import_components63 = require("@transferwise/components");
18454
- var import_jsx_runtime105 = require("react/jsx-runtime");
18710
+ var import_components64 = require("@transferwise/components");
18711
+ var import_jsx_runtime106 = require("react/jsx-runtime");
18455
18712
  var DynamicMarkdown = ({ component }) => {
18456
18713
  const { content, align, margin } = component;
18457
- return /* @__PURE__ */ (0, import_jsx_runtime105.jsx)("div", { className: getTextAlignmentAndMargin2({ align, margin }), children: /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(import_components63.Markdown, { config: { link: { target: "_blank" } }, children: content }) });
18714
+ return /* @__PURE__ */ (0, import_jsx_runtime106.jsx)("div", { className: getTextAlignmentAndMargin2({ align, margin }), children: /* @__PURE__ */ (0, import_jsx_runtime106.jsx)(import_components64.Markdown, { config: { link: { target: "_blank" } }, children: content }) });
18458
18715
  };
18459
18716
  var DynamicInfo = ({ component }) => {
18460
- return /* @__PURE__ */ (0, import_jsx_runtime105.jsx)("div", { className: getTextAlignmentAndMargin2(component), children: /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(import_components63.Markdown, { config: { link: { target: "_blank" } }, children: component.markdown }) });
18717
+ return /* @__PURE__ */ (0, import_jsx_runtime106.jsx)("div", { className: getTextAlignmentAndMargin2(component), children: /* @__PURE__ */ (0, import_jsx_runtime106.jsx)(import_components64.Markdown, { config: { link: { target: "_blank" } }, children: component.markdown }) });
18461
18718
  };
18462
18719
 
18463
18720
  // src/legacy/layout/image/DynamicImage.tsx
18464
- var import_components64 = require("@transferwise/components");
18721
+ var import_components65 = require("@transferwise/components");
18465
18722
  var import_react48 = require("react");
18466
- var import_jsx_runtime106 = require("react/jsx-runtime");
18723
+ var import_jsx_runtime107 = require("react/jsx-runtime");
18467
18724
  function DynamicImage({ component: image }) {
18468
- const { url, size: size2, text, margin, accessibilityDescription } = image;
18725
+ var _a, _b, _c;
18726
+ const { content, url, size: size2, text, margin, accessibilityDescription } = image;
18469
18727
  const httpClient = useHttpClient();
18470
18728
  const [imageSource, setImageSource] = (0, import_react48.useState)("");
18471
18729
  (0, import_react48.useEffect)(() => {
18472
- void getImageSource2(httpClient, url).then(setImageSource);
18473
- }, [url, httpClient]);
18730
+ if (content) {
18731
+ const { uri, url: contentUrl } = content;
18732
+ if (uri && !uri.startsWith("urn:")) {
18733
+ void getImageSource2(httpClient, uri).then(setImageSource);
18734
+ return;
18735
+ }
18736
+ if (contentUrl) {
18737
+ void getImageSource2(httpClient, contentUrl).then(setImageSource);
18738
+ return;
18739
+ }
18740
+ }
18741
+ if (url) {
18742
+ void getImageSource2(httpClient, url).then(setImageSource);
18743
+ }
18744
+ }, [content, url, httpClient]);
18474
18745
  const imageProps = {
18475
- alt: accessibilityDescription || text || "",
18746
+ alt: (_c = (_b = (_a = content == null ? void 0 : content.accessibilityDescription) != null ? _a : accessibilityDescription) != null ? _b : text) != null ? _c : "",
18476
18747
  src: imageSource,
18477
18748
  stretch: true,
18478
18749
  shrink: true
@@ -18480,7 +18751,7 @@ function DynamicImage({ component: image }) {
18480
18751
  if (!imageSource) {
18481
18752
  return null;
18482
18753
  }
18483
- return /* @__PURE__ */ (0, import_jsx_runtime106.jsx)("div", { className: `df-image ${size2 || "md"}`, children: /* @__PURE__ */ (0, import_jsx_runtime106.jsx)(import_components64.Image, __spreadValues({ className: `img-responsive ${getMargin2(margin || "md")}` }, imageProps)) });
18754
+ return /* @__PURE__ */ (0, import_jsx_runtime107.jsx)("div", { className: `df-image ${size2 || "md"}`, children: /* @__PURE__ */ (0, import_jsx_runtime107.jsx)(import_components65.Image, __spreadValues({ className: `img-responsive ${getMargin2(margin || "md")}` }, imageProps)) });
18484
18755
  }
18485
18756
  var readImageBlobAsDataURL2 = (imageBlob) => (
18486
18757
  // we can safely assume the type of reader.result is string
@@ -18516,48 +18787,48 @@ var getImageSource2 = async (httpClient, imageUrl) => {
18516
18787
  var DynamicImage_default = DynamicImage;
18517
18788
 
18518
18789
  // src/legacy/layout/instructions/DynamicInstructions.tsx
18519
- var import_components65 = require("@transferwise/components");
18520
- var import_jsx_runtime107 = require("react/jsx-runtime");
18790
+ var import_components66 = require("@transferwise/components");
18791
+ var import_jsx_runtime108 = require("react/jsx-runtime");
18521
18792
  var doContext2 = ["positive", "neutral"];
18522
18793
  var dontContext2 = ["warning", "negative"];
18523
18794
  var DynamicInstructions = ({ component }) => {
18524
18795
  const { items } = component;
18525
18796
  const dos = items.filter((item) => doContext2.includes(item.context)).map(({ text }) => text);
18526
18797
  const donts = items.filter((item) => dontContext2.includes(item.context)).map(({ text }) => text);
18527
- return /* @__PURE__ */ (0, import_jsx_runtime107.jsxs)("div", { className: getMargin2(component.margin || "md"), children: [
18528
- component.title ? /* @__PURE__ */ (0, import_jsx_runtime107.jsx)(import_components65.Header, { title: component.title }) : null,
18529
- /* @__PURE__ */ (0, import_jsx_runtime107.jsx)(import_components65.InstructionsList, { dos, donts })
18798
+ return /* @__PURE__ */ (0, import_jsx_runtime108.jsxs)("div", { className: getMargin2(component.margin || "md"), children: [
18799
+ component.title ? /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(import_components66.Header, { title: component.title }) : null,
18800
+ /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(import_components66.InstructionsList, { dos, donts })
18530
18801
  ] });
18531
18802
  };
18532
18803
  var DynamicInstructions_default = DynamicInstructions;
18533
18804
 
18534
18805
  // src/legacy/layout/DynamicLayout.tsx
18535
- var import_jsx_runtime108 = require("react/jsx-runtime");
18806
+ var import_jsx_runtime109 = require("react/jsx-runtime");
18536
18807
  var getKey = (component) => JSON.stringify(component);
18537
18808
  function DynamicLayout(props) {
18538
18809
  const { components, model, submitted, errors, onModelChange, onAction, onPersistAsync, baseUrl } = props;
18539
18810
  const renderComponent = (component) => {
18540
18811
  switch (component.type) {
18541
18812
  case "heading":
18542
- return /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(DynamicHeading_default, { component }, getKey(component));
18813
+ return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(DynamicHeading_default, { component }, getKey(component));
18543
18814
  case "paragraph":
18544
- return /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(DynamicParagraph_default, { component }, getKey(component));
18815
+ return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(DynamicParagraph_default, { component }, getKey(component));
18545
18816
  case "image":
18546
- return /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(DynamicImage_default, { component }, getKey(component));
18817
+ return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(DynamicImage_default, { component }, getKey(component));
18547
18818
  case "alert":
18548
- return /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(DynamicAlert_default, { component, onAction }, getKey(component));
18819
+ return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(DynamicAlert_default, { component, onAction }, getKey(component));
18549
18820
  case "review":
18550
- return /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(DynamicReview_default, { component, onAction }, getKey(component));
18821
+ return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(DynamicReview_default, { component, onAction }, getKey(component));
18551
18822
  case "divider":
18552
- return /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(DynamicDivider_default, { component }, getKey(component));
18823
+ return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(DynamicDivider_default, { component }, getKey(component));
18553
18824
  case "info":
18554
- return /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(DynamicInfo, { component }, getKey(component));
18825
+ return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(DynamicInfo, { component }, getKey(component));
18555
18826
  case "instructions":
18556
- return /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(DynamicInstructions_default, { component }, getKey(component));
18827
+ return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(DynamicInstructions_default, { component }, getKey(component));
18557
18828
  case "markdown":
18558
- return /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(DynamicMarkdown, { component }, getKey(component));
18829
+ return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(DynamicMarkdown, { component }, getKey(component));
18559
18830
  case "columns":
18560
- return /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(
18831
+ return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(
18561
18832
  DynamicColumns_default,
18562
18833
  {
18563
18834
  component,
@@ -18571,7 +18842,7 @@ function DynamicLayout(props) {
18571
18842
  getKey(component)
18572
18843
  );
18573
18844
  case "form":
18574
- return /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(
18845
+ return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(
18575
18846
  DynamicForm_default,
18576
18847
  {
18577
18848
  component,
@@ -18584,9 +18855,9 @@ function DynamicLayout(props) {
18584
18855
  getKey(__spreadProps(__spreadValues({}, component), { errors: errors != null ? errors : null }))
18585
18856
  );
18586
18857
  case "button":
18587
- return /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(DynamicButton_default, { component, onAction }, getKey(component));
18858
+ return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(DynamicButton_default, { component, onAction }, getKey(component));
18588
18859
  case "box":
18589
- return /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(
18860
+ return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(
18590
18861
  DynamicBox_default,
18591
18862
  {
18592
18863
  component,
@@ -18600,18 +18871,18 @@ function DynamicLayout(props) {
18600
18871
  getKey(component)
18601
18872
  );
18602
18873
  case "decision":
18603
- return /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(DynamicDecision_default, { component, onAction }, getKey(component));
18874
+ return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(DynamicDecision_default, { component, onAction }, getKey(component));
18604
18875
  case "external":
18605
- return /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(DynamicExternal_default, { component, onAction }, getKey(component));
18876
+ return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(DynamicExternal_default, { component, onAction }, getKey(component));
18606
18877
  case "list":
18607
18878
  case "status-list":
18608
- return /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(DynamicStatusList_default, { component, onAction }, getKey(component));
18879
+ return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(DynamicStatusList_default, { component, onAction }, getKey(component));
18609
18880
  case "loading-indicator":
18610
- return /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(DynamicLoadingIndicator_default, { component }, getKey(component));
18881
+ return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(DynamicLoadingIndicator_default, { component }, getKey(component));
18611
18882
  case "search":
18612
- return /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(DynamicSearch_default, { component, onAction }, getKey(component));
18883
+ return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(DynamicSearch_default, { component, onAction }, getKey(component));
18613
18884
  case "modal":
18614
- return /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(
18885
+ return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(
18615
18886
  DynamicModal_default,
18616
18887
  {
18617
18888
  component,
@@ -18625,22 +18896,22 @@ function DynamicLayout(props) {
18625
18896
  getKey(component)
18626
18897
  );
18627
18898
  default:
18628
- return /* @__PURE__ */ (0, import_jsx_runtime108.jsx)("div", {}, getKey(component));
18899
+ return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)("div", {}, getKey(component));
18629
18900
  }
18630
18901
  };
18631
18902
  if (useHasHttpClientProvider() || baseUrl == null) {
18632
- return /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(import_jsx_runtime108.Fragment, { children: components.map(renderComponent) });
18903
+ return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(import_jsx_runtime109.Fragment, { children: components.map(renderComponent) });
18633
18904
  }
18634
- return /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(HttpClientProviderFromBaseUrl, { baseUrl, children: components.map(renderComponent) });
18905
+ return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(HttpClientProviderFromBaseUrl, { baseUrl, children: components.map(renderComponent) });
18635
18906
  }
18636
18907
  var DynamicLayout_default = DynamicLayout;
18637
18908
 
18638
18909
  // src/legacy/layout/list/DynamicStatusList.tsx
18639
- var import_components66 = require("@transferwise/components");
18640
- var import_jsx_runtime109 = require("react/jsx-runtime");
18910
+ var import_components67 = require("@transferwise/components");
18911
+ var import_jsx_runtime110 = require("react/jsx-runtime");
18641
18912
  var DynamicStatusList = ({ component, onAction }) => {
18642
- return /* @__PURE__ */ (0, import_jsx_runtime109.jsxs)("div", { className: getMargin2(component.margin || "md"), children: [
18643
- component.title ? /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(import_components66.Header, { title: component.title, className: "m-b-2" }) : null,
18913
+ return /* @__PURE__ */ (0, import_jsx_runtime110.jsxs)("div", { className: getMargin2(component.margin || "md"), children: [
18914
+ component.title ? /* @__PURE__ */ (0, import_jsx_runtime110.jsx)(import_components67.Header, { title: component.title, className: "m-b-2" }) : null,
18644
18915
  component.items.map((item) => mapListItemToSummary(item, onAction))
18645
18916
  ] });
18646
18917
  };
@@ -18650,8 +18921,8 @@ var mapListItemToSummary = (props, onAction) => {
18650
18921
  title,
18651
18922
  description,
18652
18923
  action: "callToAction" in props ? callToActionToSummaryAction(props == null ? void 0 : props.callToAction, onAction) : void 0
18653
- }, (icon == null ? void 0 : icon.name) ? { icon: /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(DynamicIcon_default2, { type: icon.name }) } : {}), status ? { status: statusMap[status] } : {});
18654
- return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(import_components66.Summary, __spreadValues({}, summaryProps), `${title}/${description || ""}`);
18924
+ }, (icon == null ? void 0 : icon.name) ? { icon: /* @__PURE__ */ (0, import_jsx_runtime110.jsx)(DynamicIcon_default2, { type: icon.name }) } : {}), status ? { status: statusMap[status] } : {});
18925
+ return /* @__PURE__ */ (0, import_jsx_runtime110.jsx)(import_components67.Summary, __spreadValues({}, summaryProps), `${title}/${description || ""}`);
18655
18926
  };
18656
18927
  var callToActionToSummaryAction = (callToAction, onAction) => {
18657
18928
  if (!callToAction) {
@@ -18720,12 +18991,12 @@ var statusMap = __spreadValues(__spreadValues({}, statusListMap), legacyStatusMa
18720
18991
  var DynamicStatusList_default = DynamicStatusList;
18721
18992
 
18722
18993
  // src/legacy/layout/loadingIndicator/DynamicLoadingIndicator.tsx
18723
- var import_components67 = require("@transferwise/components");
18724
- var import_jsx_runtime110 = require("react/jsx-runtime");
18994
+ var import_components68 = require("@transferwise/components");
18995
+ var import_jsx_runtime111 = require("react/jsx-runtime");
18725
18996
  var DynamicLoadingIndicator = ({ component }) => {
18726
18997
  const { margin = "md", size: size2 = "md" } = component;
18727
- return /* @__PURE__ */ (0, import_jsx_runtime110.jsx)(
18728
- import_components67.Loader,
18998
+ return /* @__PURE__ */ (0, import_jsx_runtime111.jsx)(
18999
+ import_components68.Loader,
18729
19000
  {
18730
19001
  size: size2,
18731
19002
  classNames: {
@@ -18738,7 +19009,7 @@ var DynamicLoadingIndicator = ({ component }) => {
18738
19009
  var DynamicLoadingIndicator_default = DynamicLoadingIndicator;
18739
19010
 
18740
19011
  // src/legacy/layout/paragraph/DynamicParagraph.tsx
18741
- var import_components69 = require("@transferwise/components");
19012
+ var import_components70 = require("@transferwise/components");
18742
19013
  var import_react_intl40 = require("react-intl");
18743
19014
 
18744
19015
  // src/common/messages/paragraph.messages.ts
@@ -18757,22 +19028,22 @@ var paragraph_messages_default2 = (0, import_react_intl39.defineMessages)({
18757
19028
  });
18758
19029
 
18759
19030
  // src/legacy/layout/paragraph/useSnackBarIfAvailable.ts
18760
- var import_components68 = require("@transferwise/components");
19031
+ var import_components69 = require("@transferwise/components");
18761
19032
  var import_react49 = require("react");
18762
19033
  function useSnackBarIfAvailable2() {
18763
- const context = (0, import_react49.useContext)(import_components68.SnackbarContext);
19034
+ const context = (0, import_react49.useContext)(import_components69.SnackbarContext);
18764
19035
  return context ? context.createSnackbar : noop3;
18765
19036
  }
18766
19037
  function noop3() {
18767
19038
  }
18768
19039
 
18769
19040
  // src/legacy/layout/paragraph/DynamicParagraph.tsx
18770
- var import_jsx_runtime111 = require("react/jsx-runtime");
19041
+ var import_jsx_runtime112 = require("react/jsx-runtime");
18771
19042
  function DynamicParagraph({ component }) {
18772
- return component.control === "copyable" ? /* @__PURE__ */ (0, import_jsx_runtime111.jsx)(CopyableDynamicParagraph, { component }) : /* @__PURE__ */ (0, import_jsx_runtime111.jsx)(BasicDynamicParagraph, { component });
19043
+ return component.control === "copyable" ? /* @__PURE__ */ (0, import_jsx_runtime112.jsx)(CopyableDynamicParagraph, { component }) : /* @__PURE__ */ (0, import_jsx_runtime112.jsx)(BasicDynamicParagraph, { component });
18773
19044
  }
18774
19045
  function BasicDynamicParagraph({ component }) {
18775
- return /* @__PURE__ */ (0, import_jsx_runtime111.jsx)("p", { className: `np-text-body-large ${getTextAlignmentAndMargin2(component)}`, children: component.text });
19046
+ return /* @__PURE__ */ (0, import_jsx_runtime112.jsx)("p", { className: `np-text-body-large ${getTextAlignmentAndMargin2(component)}`, children: component.text });
18776
19047
  }
18777
19048
  function CopyableDynamicParagraph({ component }) {
18778
19049
  const { formatMessage } = (0, import_react_intl40.useIntl)();
@@ -18782,22 +19053,22 @@ function CopyableDynamicParagraph({ component }) {
18782
19053
  var _a;
18783
19054
  (_a = navigator.clipboard) == null ? void 0 : _a.writeText(text).then(() => createSnackbar({ text: formatMessage(paragraph_messages_default2.copied) })).catch(noop4);
18784
19055
  };
18785
- const classNames16 = `${getTextAlignmentAndMargin2({
19056
+ const classNames17 = `${getTextAlignmentAndMargin2({
18786
19057
  align: component.align,
18787
19058
  margin: "sm"
18788
19059
  })} form-control`;
18789
- return /* @__PURE__ */ (0, import_jsx_runtime111.jsxs)("div", { className: getTextAlignmentAndMargin2(component), children: [
18790
- /* @__PURE__ */ (0, import_jsx_runtime111.jsx)(
19060
+ return /* @__PURE__ */ (0, import_jsx_runtime112.jsxs)("div", { className: getTextAlignmentAndMargin2(component), children: [
19061
+ /* @__PURE__ */ (0, import_jsx_runtime112.jsx)(
18791
19062
  "input",
18792
19063
  {
18793
19064
  type: "text",
18794
- className: classNames16,
19065
+ className: classNames17,
18795
19066
  value: text,
18796
19067
  readOnly: true,
18797
19068
  style: { textOverflow: "ellipsis" }
18798
19069
  }
18799
19070
  ),
18800
- /* @__PURE__ */ (0, import_jsx_runtime111.jsx)(import_components69.Button, { block: true, onClick: copy, children: formatMessage(paragraph_messages_default2.copy) })
19071
+ /* @__PURE__ */ (0, import_jsx_runtime112.jsx)(import_components70.Button, { block: true, onClick: copy, children: formatMessage(paragraph_messages_default2.copy) })
18801
19072
  ] });
18802
19073
  }
18803
19074
  function noop4() {
@@ -18805,8 +19076,8 @@ function noop4() {
18805
19076
  var DynamicParagraph_default = DynamicParagraph;
18806
19077
 
18807
19078
  // src/legacy/layout/review/DynamicReview.tsx
18808
- var import_components70 = require("@transferwise/components");
18809
- var import_jsx_runtime112 = require("react/jsx-runtime");
19079
+ var import_components71 = require("@transferwise/components");
19080
+ var import_jsx_runtime113 = require("react/jsx-runtime");
18810
19081
  var getDefinitions = (orientation, review) => review.fields.map(({ label, value, help }, index) => ({
18811
19082
  key: String(index),
18812
19083
  title: label,
@@ -18814,14 +19085,14 @@ var getDefinitions = (orientation, review) => review.fields.map(({ label, value,
18814
19085
  }));
18815
19086
  var getFieldValue2 = (value, help, orientation) => {
18816
19087
  if (help) {
18817
- return orientation === "HORIZONTAL_RIGHT_ALIGNED" ? /* @__PURE__ */ (0, import_jsx_runtime112.jsxs)(import_jsx_runtime112.Fragment, { children: [
18818
- /* @__PURE__ */ (0, import_jsx_runtime112.jsx)(Help_default2, { help }),
19088
+ return orientation === "HORIZONTAL_RIGHT_ALIGNED" ? /* @__PURE__ */ (0, import_jsx_runtime113.jsxs)(import_jsx_runtime113.Fragment, { children: [
19089
+ /* @__PURE__ */ (0, import_jsx_runtime113.jsx)(Help_default2, { help }),
18819
19090
  " ",
18820
19091
  value
18821
- ] }) : /* @__PURE__ */ (0, import_jsx_runtime112.jsxs)(import_jsx_runtime112.Fragment, { children: [
19092
+ ] }) : /* @__PURE__ */ (0, import_jsx_runtime113.jsxs)(import_jsx_runtime113.Fragment, { children: [
18822
19093
  value,
18823
19094
  " ",
18824
- /* @__PURE__ */ (0, import_jsx_runtime112.jsx)(Help_default2, { help })
19095
+ /* @__PURE__ */ (0, import_jsx_runtime113.jsx)(Help_default2, { help })
18825
19096
  ] });
18826
19097
  }
18827
19098
  return value;
@@ -18854,7 +19125,7 @@ function DynamicReview({ component: review, onAction }) {
18854
19125
  const { action: behaviorAction2 } = behavior;
18855
19126
  return {
18856
19127
  text: title != null ? title : "",
18857
- onClick: behaviorAction2 ? getOnClick(behaviorAction2) : void 0
19128
+ onClick: behaviorAction2 ? getOnClick2(behaviorAction2) : void 0
18858
19129
  };
18859
19130
  }
18860
19131
  case "link": {
@@ -18869,7 +19140,7 @@ function DynamicReview({ component: review, onAction }) {
18869
19140
  if (behaviorAction) {
18870
19141
  return {
18871
19142
  text: title != null ? title : "",
18872
- onClick: behaviorAction ? getOnClick(behaviorAction) : void 0
19143
+ onClick: behaviorAction ? getOnClick2(behaviorAction) : void 0
18873
19144
  };
18874
19145
  }
18875
19146
  if (link) {
@@ -18881,10 +19152,10 @@ function DynamicReview({ component: review, onAction }) {
18881
19152
  }
18882
19153
  return {
18883
19154
  text: title != null ? title : "",
18884
- onClick: action ? getOnClick(action) : void 0
19155
+ onClick: action ? getOnClick2(action) : void 0
18885
19156
  };
18886
19157
  };
18887
- const getOnClick = (action) => {
19158
+ const getOnClick2 = (action) => {
18888
19159
  return (event) => {
18889
19160
  event.preventDefault();
18890
19161
  if (action) {
@@ -18894,10 +19165,10 @@ function DynamicReview({ component: review, onAction }) {
18894
19165
  };
18895
19166
  const orientation = getDefinitionListLayout(review);
18896
19167
  const callToAction = review.callToAction ? getReviewAction3(review.callToAction) : null;
18897
- const legacyCallToAction = !callToAction && review.action ? { text: (_a = review.action.title) != null ? _a : "", onClick: getOnClick(review.action) } : null;
18898
- return /* @__PURE__ */ (0, import_jsx_runtime112.jsxs)("div", { className: margin, children: [
18899
- review.title && /* @__PURE__ */ (0, import_jsx_runtime112.jsx)(import_components70.Header, { title: review.title, action: (_b = callToAction != null ? callToAction : legacyCallToAction) != null ? _b : void 0 }),
18900
- /* @__PURE__ */ (0, import_jsx_runtime112.jsx)("div", { className: margin, children: /* @__PURE__ */ (0, import_jsx_runtime112.jsx)(import_components70.DefinitionList, { layout: orientation, definitions: getDefinitions(orientation, review) }) })
19168
+ const legacyCallToAction = !callToAction && review.action ? { text: (_a = review.action.title) != null ? _a : "", onClick: getOnClick2(review.action) } : null;
19169
+ return /* @__PURE__ */ (0, import_jsx_runtime113.jsxs)("div", { className: margin, children: [
19170
+ review.title && /* @__PURE__ */ (0, import_jsx_runtime113.jsx)(import_components71.Header, { title: review.title, action: (_b = callToAction != null ? callToAction : legacyCallToAction) != null ? _b : void 0 }),
19171
+ /* @__PURE__ */ (0, import_jsx_runtime113.jsx)("div", { className: margin, children: /* @__PURE__ */ (0, import_jsx_runtime113.jsx)(import_components71.DefinitionList, { layout: orientation, definitions: getDefinitions(orientation, review) }) })
18901
19172
  ] });
18902
19173
  }
18903
19174
  var DynamicReview_default = DynamicReview;
@@ -18907,13 +19178,13 @@ var import_react51 = require("react");
18907
19178
  var import_icons5 = require("@transferwise/icons");
18908
19179
 
18909
19180
  // src/legacy/layout/search/SearchInput.tsx
18910
- var import_components71 = require("@transferwise/components");
18911
- var import_jsx_runtime113 = require("react/jsx-runtime");
19181
+ var import_components72 = require("@transferwise/components");
19182
+ var import_jsx_runtime114 = require("react/jsx-runtime");
18912
19183
  var SearchInput = ({ title, value, onFocus, onChange }) => {
18913
- return /* @__PURE__ */ (0, import_jsx_runtime113.jsxs)("label", { className: "control-label d-inline", children: [
19184
+ return /* @__PURE__ */ (0, import_jsx_runtime114.jsxs)("label", { className: "control-label d-inline", children: [
18914
19185
  title,
18915
- /* @__PURE__ */ (0, import_jsx_runtime113.jsx)(
18916
- import_components71.Input,
19186
+ /* @__PURE__ */ (0, import_jsx_runtime114.jsx)(
19187
+ import_components72.Input,
18917
19188
  {
18918
19189
  type: "text",
18919
19190
  value,
@@ -18926,15 +19197,15 @@ var SearchInput = ({ title, value, onFocus, onChange }) => {
18926
19197
  };
18927
19198
 
18928
19199
  // src/legacy/layout/search/SearchResults.tsx
18929
- var import_components72 = require("@transferwise/components");
19200
+ var import_components73 = require("@transferwise/components");
18930
19201
  var import_react_intl41 = require("react-intl");
18931
- var import_jsx_runtime114 = require("react/jsx-runtime");
19202
+ var import_jsx_runtime115 = require("react/jsx-runtime");
18932
19203
  function SearchResults2({ results, emptyMessage, onSelect }) {
18933
19204
  if (results.length === 0) {
18934
- return /* @__PURE__ */ (0, import_jsx_runtime114.jsx)("p", { className: "m-t-2", children: emptyMessage });
19205
+ return /* @__PURE__ */ (0, import_jsx_runtime115.jsx)("p", { className: "m-t-2", children: emptyMessage });
18935
19206
  }
18936
- return /* @__PURE__ */ (0, import_jsx_runtime114.jsx)(import_components72.NavigationOptionsList, { children: results.map((result) => /* @__PURE__ */ (0, import_jsx_runtime114.jsx)(
18937
- import_components72.NavigationOption,
19207
+ return /* @__PURE__ */ (0, import_jsx_runtime115.jsx)(import_components73.NavigationOptionsList, { children: results.map((result) => /* @__PURE__ */ (0, import_jsx_runtime115.jsx)(
19208
+ import_components73.NavigationOption,
18938
19209
  {
18939
19210
  title: result.title,
18940
19211
  content: result.description,
@@ -18948,10 +19219,10 @@ function SearchResults2({ results, emptyMessage, onSelect }) {
18948
19219
  }
18949
19220
  function ErrorResult2({ onRetrySearch }) {
18950
19221
  const intl = (0, import_react_intl41.useIntl)();
18951
- return /* @__PURE__ */ (0, import_jsx_runtime114.jsxs)("p", { className: "m-t-2", children: [
19222
+ return /* @__PURE__ */ (0, import_jsx_runtime115.jsxs)("p", { className: "m-t-2", children: [
18952
19223
  intl.formatMessage(generic_error_messages_default.genericError),
18953
19224
  "\xA0",
18954
- /* @__PURE__ */ (0, import_jsx_runtime114.jsx)(
19225
+ /* @__PURE__ */ (0, import_jsx_runtime115.jsx)(
18955
19226
  "a",
18956
19227
  {
18957
19228
  href: "/",
@@ -19035,8 +19306,8 @@ var addQueryParameter2 = (url, key, value) => {
19035
19306
  };
19036
19307
 
19037
19308
  // src/legacy/layout/search/DynamicSearch.tsx
19038
- var import_components73 = require("@transferwise/components");
19039
- var import_classnames14 = __toESM(require_classnames());
19309
+ var import_components74 = require("@transferwise/components");
19310
+ var import_classnames15 = __toESM(require_classnames());
19040
19311
  var import_react_intl43 = require("react-intl");
19041
19312
 
19042
19313
  // src/common/messages/search.messages.ts
@@ -19050,7 +19321,7 @@ var search_messages_default2 = (0, import_react_intl42.defineMessages)({
19050
19321
  });
19051
19322
 
19052
19323
  // src/legacy/layout/search/DynamicSearch.tsx
19053
- var import_jsx_runtime115 = require("react/jsx-runtime");
19324
+ var import_jsx_runtime116 = require("react/jsx-runtime");
19054
19325
  var DEBOUNCE_TIME2 = 400;
19055
19326
  function DynamicSearch({ component, onAction }) {
19056
19327
  const [query, setQuery] = (0, import_react51.useState)("");
@@ -19088,17 +19359,17 @@ function DynamicSearch({ component, onAction }) {
19088
19359
  };
19089
19360
  const loadingMessage = intl.formatMessage(search_messages_default2.loading);
19090
19361
  if (control === "inline") {
19091
- return /* @__PURE__ */ (0, import_jsx_runtime115.jsx)("div", { className: (0, import_classnames14.default)(getMargin2(margin != null ? margin : "md"), "df-search-typeahead"), children: /* @__PURE__ */ (0, import_jsx_runtime115.jsxs)("label", { className: "control-label d-inline", children: [
19362
+ return /* @__PURE__ */ (0, import_jsx_runtime116.jsx)("div", { className: (0, import_classnames15.default)(getMargin2(margin != null ? margin : "md"), "df-search-typeahead"), children: /* @__PURE__ */ (0, import_jsx_runtime116.jsxs)("label", { className: "control-label d-inline", children: [
19092
19363
  title,
19093
- /* @__PURE__ */ (0, import_jsx_runtime115.jsx)("div", { className: "m-t-1", children: /* @__PURE__ */ (0, import_jsx_runtime115.jsx)(
19094
- import_components73.Typeahead,
19364
+ /* @__PURE__ */ (0, import_jsx_runtime116.jsx)("div", { className: "m-t-1", children: /* @__PURE__ */ (0, import_jsx_runtime116.jsx)(
19365
+ import_components74.Typeahead,
19095
19366
  {
19096
19367
  id: "typeahead-input-id",
19097
19368
  intl,
19098
19369
  name: "typeahead-input-name",
19099
19370
  size: "md",
19100
19371
  maxHeight: 100,
19101
- footer: /* @__PURE__ */ (0, import_jsx_runtime115.jsx)(
19372
+ footer: /* @__PURE__ */ (0, import_jsx_runtime116.jsx)(
19102
19373
  TypeaheadFooter2,
19103
19374
  {
19104
19375
  state: status,
@@ -19110,7 +19381,7 @@ function DynamicSearch({ component, onAction }) {
19110
19381
  ),
19111
19382
  multiple: false,
19112
19383
  clearable: false,
19113
- addon: /* @__PURE__ */ (0, import_jsx_runtime115.jsx)(import_icons5.Search, { size: 24 }),
19384
+ addon: /* @__PURE__ */ (0, import_jsx_runtime116.jsx)(import_icons5.Search, { size: 24 }),
19114
19385
  options: results.map(mapResultToTypeaheadOption2),
19115
19386
  onChange: (values) => {
19116
19387
  if (values.length > 0) {
@@ -19125,11 +19396,11 @@ function DynamicSearch({ component, onAction }) {
19125
19396
  ) })
19126
19397
  ] }) });
19127
19398
  }
19128
- return /* @__PURE__ */ (0, import_jsx_runtime115.jsxs)("div", { className: getMargin2(margin != null ? margin : "md"), children: [
19129
- /* @__PURE__ */ (0, import_jsx_runtime115.jsx)(SearchInput, { title, value: query, onChange, onFocus: onSearchStart }),
19130
- status === "loading" && /* @__PURE__ */ (0, import_jsx_runtime115.jsx)(DynamicLoadingIndicator_default, { component: { type: "loading-indicator", size: "sm" } }),
19131
- status === "error" && /* @__PURE__ */ (0, import_jsx_runtime115.jsx)(ErrorResult2, { onRetrySearch }),
19132
- status === "success" && /* @__PURE__ */ (0, import_jsx_runtime115.jsx)(SearchResults2, { results, emptyMessage, onSelect: onResultSelected })
19399
+ return /* @__PURE__ */ (0, import_jsx_runtime116.jsxs)("div", { className: getMargin2(margin != null ? margin : "md"), children: [
19400
+ /* @__PURE__ */ (0, import_jsx_runtime116.jsx)(SearchInput, { title, value: query, onChange, onFocus: onSearchStart }),
19401
+ status === "loading" && /* @__PURE__ */ (0, import_jsx_runtime116.jsx)(DynamicLoadingIndicator_default, { component: { type: "loading-indicator", size: "sm" } }),
19402
+ status === "error" && /* @__PURE__ */ (0, import_jsx_runtime116.jsx)(ErrorResult2, { onRetrySearch }),
19403
+ status === "success" && /* @__PURE__ */ (0, import_jsx_runtime116.jsx)(SearchResults2, { results, emptyMessage, onSelect: onResultSelected })
19133
19404
  ] });
19134
19405
  }
19135
19406
  function mapResultToTypeaheadOption2(result) {
@@ -19149,36 +19420,36 @@ function TypeaheadFooter2({
19149
19420
  onRetrySearch
19150
19421
  }) {
19151
19422
  if (state === "success" && results.length === 0) {
19152
- return /* @__PURE__ */ (0, import_jsx_runtime115.jsx)(import_components73.Markdown, { className: "m-t-2 m-x-2", config: { link: { target: "_blank" } }, children: emptyMessage });
19423
+ return /* @__PURE__ */ (0, import_jsx_runtime116.jsx)(import_components74.Markdown, { className: "m-t-2 m-x-2", config: { link: { target: "_blank" } }, children: emptyMessage });
19153
19424
  }
19154
19425
  if (state === "error" && results.length === 0) {
19155
- return /* @__PURE__ */ (0, import_jsx_runtime115.jsx)("div", { className: "m-t-2 m-x-2", children: /* @__PURE__ */ (0, import_jsx_runtime115.jsx)(ErrorResult2, { onRetrySearch }) });
19426
+ return /* @__PURE__ */ (0, import_jsx_runtime116.jsx)("div", { className: "m-t-2 m-x-2", children: /* @__PURE__ */ (0, import_jsx_runtime116.jsx)(ErrorResult2, { onRetrySearch }) });
19156
19427
  }
19157
19428
  if (state === "loading" || results.length === 0) {
19158
- return /* @__PURE__ */ (0, import_jsx_runtime115.jsx)("p", { className: "m-t-2 m-x-2", children: loadingMessage });
19429
+ return /* @__PURE__ */ (0, import_jsx_runtime116.jsx)("p", { className: "m-t-2 m-x-2", children: loadingMessage });
19159
19430
  }
19160
19431
  return null;
19161
19432
  }
19162
19433
  var DynamicSearch_default = DynamicSearch;
19163
19434
 
19164
19435
  // src/legacy/layout/modal/DynamicModal.tsx
19165
- var import_components74 = require("@transferwise/components");
19436
+ var import_components75 = require("@transferwise/components");
19166
19437
  var import_react52 = require("react");
19167
- var import_jsx_runtime116 = require("react/jsx-runtime");
19438
+ var import_jsx_runtime117 = require("react/jsx-runtime");
19168
19439
  function DynamicModal(props) {
19169
19440
  const [visible, isVisible] = (0, import_react52.useState)(false);
19170
19441
  const { component, onAction } = props;
19171
19442
  const { margin = "md" } = component;
19172
- return /* @__PURE__ */ (0, import_jsx_runtime116.jsxs)("div", { className: getTextAlignmentAndMargin2({ margin }), children: [
19173
- /* @__PURE__ */ (0, import_jsx_runtime116.jsx)(import_components74.Button, { priority: "tertiary", block: true, onClick: () => isVisible(true), children: component.trigger.title }),
19174
- /* @__PURE__ */ (0, import_jsx_runtime116.jsx)(
19175
- import_components74.Modal,
19443
+ return /* @__PURE__ */ (0, import_jsx_runtime117.jsxs)("div", { className: getTextAlignmentAndMargin2({ margin }), children: [
19444
+ /* @__PURE__ */ (0, import_jsx_runtime117.jsx)(import_components75.Button, { priority: "tertiary", block: true, onClick: () => isVisible(true), children: component.trigger.title }),
19445
+ /* @__PURE__ */ (0, import_jsx_runtime117.jsx)(
19446
+ import_components75.Modal,
19176
19447
  {
19177
19448
  scroll: "content",
19178
19449
  open: visible,
19179
19450
  size: "lg",
19180
19451
  title: component.content.title,
19181
- body: /* @__PURE__ */ (0, import_jsx_runtime116.jsx)(
19452
+ body: /* @__PURE__ */ (0, import_jsx_runtime117.jsx)(
19182
19453
  DynamicLayout_default,
19183
19454
  __spreadProps(__spreadValues({}, props), {
19184
19455
  components: component.content.components,
@@ -19196,7 +19467,7 @@ function DynamicModal(props) {
19196
19467
  var DynamicModal_default = DynamicModal;
19197
19468
 
19198
19469
  // src/legacy/jsonSchemaForm/basicTypeSchema/BasicTypeSchema.tsx
19199
- var import_jsx_runtime117 = require("react/jsx-runtime");
19470
+ var import_jsx_runtime118 = require("react/jsx-runtime");
19200
19471
  var isNullish3 = (value) => isNull3(value) || isUndefined3(value);
19201
19472
  var getDefaultValue = (schema) => {
19202
19473
  return schema.type === "boolean" && isNullish3(schema.default) ? false : schema.default;
@@ -19274,15 +19545,15 @@ var BasicTypeSchema = (props) => {
19274
19545
  const schemaHelp = props.schema.help;
19275
19546
  const feedbackId = `${id}-feedback`;
19276
19547
  const labelId = `${id}-label`;
19277
- return !isHidden ? /* @__PURE__ */ (0, import_jsx_runtime117.jsxs)(import_jsx_runtime117.Fragment, { children: [
19278
- props.schema.alert && /* @__PURE__ */ (0, import_jsx_runtime117.jsx)(DynamicAlert_default, { component: props.schema.alert }),
19279
- /* @__PURE__ */ (0, import_jsx_runtime117.jsxs)("div", { className: (0, import_classnames15.default)(formGroupClasses), children: [
19280
- showLabel && /* @__PURE__ */ (0, import_jsx_runtime117.jsxs)("div", { className: "d-inline-block m-b-1", children: [
19281
- /* @__PURE__ */ (0, import_jsx_runtime117.jsx)("label", { className: "control-label d-inline", htmlFor: id, id: labelId, children: props.schema.title }),
19282
- !!schemaHelp && /* @__PURE__ */ (0, import_jsx_runtime117.jsx)(Help_default2, { help: schemaHelp })
19548
+ return !isHidden ? /* @__PURE__ */ (0, import_jsx_runtime118.jsxs)(import_jsx_runtime118.Fragment, { children: [
19549
+ props.schema.alert && /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(DynamicAlert_default, { component: props.schema.alert }),
19550
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsxs)("div", { className: (0, import_classnames16.default)(formGroupClasses), children: [
19551
+ showLabel && /* @__PURE__ */ (0, import_jsx_runtime118.jsxs)("div", { className: "d-inline-block m-b-1", children: [
19552
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)("label", { className: "control-label d-inline", htmlFor: id, id: labelId, children: props.schema.title }),
19553
+ !!schemaHelp && /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(Help_default2, { help: schemaHelp })
19283
19554
  ] }),
19284
- !showLabel && !!schemaHelp && /* @__PURE__ */ (0, import_jsx_runtime117.jsx)(Help_default2, { help: schemaHelp }),
19285
- /* @__PURE__ */ (0, import_jsx_runtime117.jsx)(
19555
+ !showLabel && !!schemaHelp && /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(Help_default2, { help: schemaHelp }),
19556
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(
19286
19557
  SchemaFormControl_default,
19287
19558
  {
19288
19559
  id,
@@ -19296,7 +19567,7 @@ var BasicTypeSchema = (props) => {
19296
19567
  labelledBy: labelId
19297
19568
  }
19298
19569
  ),
19299
- /* @__PURE__ */ (0, import_jsx_runtime117.jsx)(
19570
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(
19300
19571
  ControlFeedback_default,
19301
19572
  {
19302
19573
  id: feedbackId,
@@ -19316,7 +19587,7 @@ var BasicTypeSchema = (props) => {
19316
19587
  var BasicTypeSchema_default = BasicTypeSchema;
19317
19588
 
19318
19589
  // src/legacy/jsonSchemaForm/persistAsyncSchema/persistAsyncBasicSchema/PersistAsyncBasicSchema.tsx
19319
- var import_jsx_runtime118 = require("react/jsx-runtime");
19590
+ var import_jsx_runtime119 = require("react/jsx-runtime");
19320
19591
  var getIdFromResponse = (idProperty, response) => response[idProperty];
19321
19592
  var getErrorFromResponse = (errorProperty, response) => {
19322
19593
  var _a;
@@ -19406,7 +19677,7 @@ function PersistAsyncBasicSchema(props) {
19406
19677
  setPersistAsyncModel(newPersistAsyncModel);
19407
19678
  }
19408
19679
  };
19409
- return /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(
19680
+ return /* @__PURE__ */ (0, import_jsx_runtime119.jsx)(
19410
19681
  BasicTypeSchema_default,
19411
19682
  {
19412
19683
  required,
@@ -19620,7 +19891,7 @@ function useStepPolling(polling, onAction) {
19620
19891
  }
19621
19892
 
19622
19893
  // src/legacy/step/layoutStep/LayoutStep.tsx
19623
- var import_jsx_runtime119 = require("react/jsx-runtime");
19894
+ var import_jsx_runtime120 = require("react/jsx-runtime");
19624
19895
  var getComponents = (step, options) => {
19625
19896
  var _a;
19626
19897
  if (isEmpty(step)) {
@@ -19643,7 +19914,7 @@ var LayoutStep = (props) => {
19643
19914
  onEvent("Dynamic Flow - onAction supressed", { reason: "LayoutStep - loading state" });
19644
19915
  };
19645
19916
  useStepPolling(stepSpecification.polling, onAction);
19646
- return /* @__PURE__ */ (0, import_jsx_runtime119.jsx)(
19917
+ return /* @__PURE__ */ (0, import_jsx_runtime120.jsx)(
19647
19918
  DynamicLayout_default,
19648
19919
  {
19649
19920
  components,
@@ -19727,49 +19998,49 @@ var CameraCapture_messages_default = (0, import_react_intl46.defineMessages)({
19727
19998
  });
19728
19999
 
19729
20000
  // src/common/cameraCapture/components/bottomBar/BottomBar.tsx
19730
- var import_components75 = require("@transferwise/components");
20001
+ var import_components76 = require("@transferwise/components");
19731
20002
  var import_react_intl47 = require("react-intl");
19732
- var import_jsx_runtime120 = require("react/jsx-runtime");
19733
- var CaptureBottomBar = ({ onCapture }) => /* @__PURE__ */ (0, import_jsx_runtime120.jsx)("div", { className: "bottom-bar", children: /* @__PURE__ */ (0, import_jsx_runtime120.jsx)(CaptureButton, { onClick: onCapture }) });
20003
+ var import_jsx_runtime121 = require("react/jsx-runtime");
20004
+ var CaptureBottomBar = ({ onCapture }) => /* @__PURE__ */ (0, import_jsx_runtime121.jsx)("div", { className: "bottom-bar", children: /* @__PURE__ */ (0, import_jsx_runtime121.jsx)(CaptureButton, { onClick: onCapture }) });
19734
20005
  var ReviewBottomBar = ({
19735
20006
  onSubmit,
19736
20007
  onRetry
19737
20008
  }) => {
19738
20009
  const intl = (0, import_react_intl47.useIntl)();
19739
- return /* @__PURE__ */ (0, import_jsx_runtime120.jsx)("div", { className: "bottom-bar p-x-2", children: /* @__PURE__ */ (0, import_jsx_runtime120.jsx)("div", { className: "row", children: /* @__PURE__ */ (0, import_jsx_runtime120.jsxs)("div", { className: "col-xs-12 col-md-6 col-md-offset-3", children: [
19740
- /* @__PURE__ */ (0, import_jsx_runtime120.jsx)(
19741
- import_components75.Button,
20010
+ return /* @__PURE__ */ (0, import_jsx_runtime121.jsx)("div", { className: "bottom-bar p-x-2", children: /* @__PURE__ */ (0, import_jsx_runtime121.jsx)("div", { className: "row", children: /* @__PURE__ */ (0, import_jsx_runtime121.jsxs)("div", { className: "col-xs-12 col-md-6 col-md-offset-3", children: [
20011
+ /* @__PURE__ */ (0, import_jsx_runtime121.jsx)(
20012
+ import_components76.Button,
19742
20013
  {
19743
20014
  className: "m-b-1",
19744
20015
  block: true,
19745
- size: import_components75.Size.MEDIUM,
19746
- type: import_components75.ControlType.ACCENT,
20016
+ size: import_components76.Size.MEDIUM,
20017
+ type: import_components76.ControlType.ACCENT,
19747
20018
  onClick: onSubmit,
19748
20019
  children: intl.formatMessage(CameraCapture_messages_default.reviewSubmit)
19749
20020
  }
19750
20021
  ),
19751
- /* @__PURE__ */ (0, import_jsx_runtime120.jsx)(
19752
- import_components75.Button,
20022
+ /* @__PURE__ */ (0, import_jsx_runtime121.jsx)(
20023
+ import_components76.Button,
19753
20024
  {
19754
20025
  className: "m-b-2",
19755
20026
  block: true,
19756
- size: import_components75.Size.MEDIUM,
19757
- type: import_components75.ControlType.ACCENT,
19758
- priority: import_components75.Priority.SECONDARY,
20027
+ size: import_components76.Size.MEDIUM,
20028
+ type: import_components76.ControlType.ACCENT,
20029
+ priority: import_components76.Priority.SECONDARY,
19759
20030
  onClick: onRetry,
19760
20031
  children: intl.formatMessage(CameraCapture_messages_default.reviewRetry)
19761
20032
  }
19762
20033
  )
19763
20034
  ] }) }) });
19764
20035
  };
19765
- var CaptureButton = ({ onClick }) => /* @__PURE__ */ (0, import_jsx_runtime120.jsx)(
20036
+ var CaptureButton = ({ onClick }) => /* @__PURE__ */ (0, import_jsx_runtime121.jsx)(
19766
20037
  "button",
19767
20038
  {
19768
20039
  type: "button",
19769
20040
  className: "camera-capture-btn m-b-2",
19770
20041
  "data-testid": "camera-capture-button",
19771
20042
  onClick,
19772
- children: /* @__PURE__ */ (0, import_jsx_runtime120.jsx)("span", { className: "camera-capture-btn-inner" })
20043
+ children: /* @__PURE__ */ (0, import_jsx_runtime121.jsx)("span", { className: "camera-capture-btn-inner" })
19773
20044
  }
19774
20045
  );
19775
20046
 
@@ -19787,11 +20058,11 @@ var OrientationLockOverlay_messages_default = (0, import_react_intl48.defineMess
19787
20058
  });
19788
20059
 
19789
20060
  // src/common/cameraCapture/components/orientationLockOverlay/OrientationLockOverlay.tsx
19790
- var import_jsx_runtime121 = require("react/jsx-runtime");
20061
+ var import_jsx_runtime122 = require("react/jsx-runtime");
19791
20062
  function OrientationLockOverlay() {
19792
20063
  const intl = (0, import_react_intl49.useIntl)();
19793
- return /* @__PURE__ */ (0, import_jsx_runtime121.jsxs)("div", { className: "orientation-lock-overlay", children: [
19794
- /* @__PURE__ */ (0, import_jsx_runtime121.jsx)(
20064
+ return /* @__PURE__ */ (0, import_jsx_runtime122.jsxs)("div", { className: "orientation-lock-overlay", children: [
20065
+ /* @__PURE__ */ (0, import_jsx_runtime122.jsx)(
19795
20066
  "img",
19796
20067
  {
19797
20068
  className: "m-b-3",
@@ -19801,7 +20072,7 @@ function OrientationLockOverlay() {
19801
20072
  alt: ""
19802
20073
  }
19803
20074
  ),
19804
- /* @__PURE__ */ (0, import_jsx_runtime121.jsx)("p", { className: "text-center m-b-0", children: intl.formatMessage(OrientationLockOverlay_messages_default.text) })
20075
+ /* @__PURE__ */ (0, import_jsx_runtime122.jsx)("p", { className: "text-center m-b-0", children: intl.formatMessage(OrientationLockOverlay_messages_default.text) })
19805
20076
  ] });
19806
20077
  }
19807
20078
  var OrientationLockOverlay_default = OrientationLockOverlay;
@@ -19976,7 +20247,7 @@ var getVideoConstraints = async (dir) => {
19976
20247
 
19977
20248
  // src/common/cameraCapture/overlay/Overlay.tsx
19978
20249
  var import_react61 = require("react");
19979
- var import_jsx_runtime122 = require("react/jsx-runtime");
20250
+ var import_jsx_runtime123 = require("react/jsx-runtime");
19980
20251
  var captureButtonHeight = 92;
19981
20252
  var reviewButtonsHeight = 120;
19982
20253
  var imageHeight = 40;
@@ -19998,18 +20269,18 @@ function Overlay({ overlay, outline, imageUrl, title, instructions, reviewInstru
19998
20269
  return () => window.removeEventListener("resize", listener);
19999
20270
  });
20000
20271
  let helperBoxHeight = (imageUrl ? imageHeight : 0) + (title ? titleHeight : 0) + (instructions ? instructionsHeight : 0);
20001
- let helperBox = /* @__PURE__ */ (0, import_jsx_runtime122.jsxs)(import_jsx_runtime122.Fragment, { children: [
20002
- imageUrl && /* @__PURE__ */ (0, import_jsx_runtime122.jsx)("img", { className: "camera-capture-img", src: imageUrl, alt: "" }),
20003
- title && /* @__PURE__ */ (0, import_jsx_runtime122.jsx)("h4", { className: "camera-capture-title", children: title }),
20004
- instructions && /* @__PURE__ */ (0, import_jsx_runtime122.jsx)("small", { className: "camera-capture-instructions", children: instructions })
20272
+ let helperBox = /* @__PURE__ */ (0, import_jsx_runtime123.jsxs)(import_jsx_runtime123.Fragment, { children: [
20273
+ imageUrl && /* @__PURE__ */ (0, import_jsx_runtime123.jsx)("img", { className: "camera-capture-img", src: imageUrl, alt: "" }),
20274
+ title && /* @__PURE__ */ (0, import_jsx_runtime123.jsx)("h4", { className: "camera-capture-title", children: title }),
20275
+ instructions && /* @__PURE__ */ (0, import_jsx_runtime123.jsx)("small", { className: "camera-capture-instructions", children: instructions })
20005
20276
  ] });
20006
20277
  const frameBottomMargin = captureButtonHeight + helperBoxHeight;
20007
20278
  if (reviewInstructions) {
20008
20279
  helperBoxHeight = frameBottomMargin - reviewButtonsHeight;
20009
- helperBox = /* @__PURE__ */ (0, import_jsx_runtime122.jsx)("small", { className: "camera-capture-instructions", children: reviewInstructions });
20280
+ helperBox = /* @__PURE__ */ (0, import_jsx_runtime123.jsx)("small", { className: "camera-capture-instructions", children: reviewInstructions });
20010
20281
  const frameWithReviewInstructionsMinBottomMargin = reviewButtonsHeight + reviewInstructionsHeight;
20011
20282
  if (frameBottomMargin < frameWithReviewInstructionsMinBottomMargin) {
20012
- helperBox = /* @__PURE__ */ (0, import_jsx_runtime122.jsx)(import_jsx_runtime122.Fragment, {});
20283
+ helperBox = /* @__PURE__ */ (0, import_jsx_runtime123.jsx)(import_jsx_runtime123.Fragment, {});
20013
20284
  }
20014
20285
  }
20015
20286
  const framePosition = {
@@ -20027,32 +20298,32 @@ function Overlay({ overlay, outline, imageUrl, title, instructions, reviewInstru
20027
20298
  width: "90%"
20028
20299
  }
20029
20300
  };
20030
- return /* @__PURE__ */ (0, import_jsx_runtime122.jsxs)("svg", { ref: svgReference, xmlns: "http://www.w3.org/2000/svg", children: [
20031
- /* @__PURE__ */ (0, import_jsx_runtime122.jsx)("defs", { children: /* @__PURE__ */ (0, import_jsx_runtime122.jsxs)("mask", { id: "mask", children: [
20032
- /* @__PURE__ */ (0, import_jsx_runtime122.jsx)("rect", { width: "100%", height: "100%", fill: "#fff" }),
20033
- /* @__PURE__ */ (0, import_jsx_runtime122.jsx)("image", __spreadValues({ href: overlay }, framePosition))
20301
+ return /* @__PURE__ */ (0, import_jsx_runtime123.jsxs)("svg", { ref: svgReference, xmlns: "http://www.w3.org/2000/svg", children: [
20302
+ /* @__PURE__ */ (0, import_jsx_runtime123.jsx)("defs", { children: /* @__PURE__ */ (0, import_jsx_runtime123.jsxs)("mask", { id: "mask", children: [
20303
+ /* @__PURE__ */ (0, import_jsx_runtime123.jsx)("rect", { width: "100%", height: "100%", fill: "#fff" }),
20304
+ /* @__PURE__ */ (0, import_jsx_runtime123.jsx)("image", __spreadValues({ href: overlay }, framePosition))
20034
20305
  ] }) }),
20035
- overlay && /* @__PURE__ */ (0, import_jsx_runtime122.jsx)("rect", { width: "100%", height: "100%", mask: "url(#mask)", fillOpacity: "0.72" }),
20036
- outline && /* @__PURE__ */ (0, import_jsx_runtime122.jsx)("image", __spreadValues({ href: outline }, framePosition)),
20037
- /* @__PURE__ */ (0, import_jsx_runtime122.jsx)("foreignObject", { width: "100%", height: "100%", children: /* @__PURE__ */ (0, import_jsx_runtime122.jsx)("div", __spreadProps(__spreadValues({ className: "camera-capture-text-and-image-container" }, helperBoxPosition), { children: helperBox })) })
20306
+ overlay && /* @__PURE__ */ (0, import_jsx_runtime123.jsx)("rect", { width: "100%", height: "100%", mask: "url(#mask)", fillOpacity: "0.72" }),
20307
+ outline && /* @__PURE__ */ (0, import_jsx_runtime123.jsx)("image", __spreadValues({ href: outline }, framePosition)),
20308
+ /* @__PURE__ */ (0, import_jsx_runtime123.jsx)("foreignObject", { width: "100%", height: "100%", children: /* @__PURE__ */ (0, import_jsx_runtime123.jsx)("div", __spreadProps(__spreadValues({ className: "camera-capture-text-and-image-container" }, helperBoxPosition), { children: helperBox })) })
20038
20309
  ] });
20039
20310
  }
20040
20311
  var Overlay_default = Overlay;
20041
20312
 
20042
20313
  // src/common/cameraCapture/screens/cameraErrorScreen/CameraErrorScreen.tsx
20043
- var import_components76 = require("@transferwise/components");
20044
- var import_jsx_runtime123 = require("react/jsx-runtime");
20314
+ var import_components77 = require("@transferwise/components");
20315
+ var import_jsx_runtime124 = require("react/jsx-runtime");
20045
20316
  function CameraErrorScreen({ title, description, actionButton, onAction }) {
20046
- return /* @__PURE__ */ (0, import_jsx_runtime123.jsx)("div", { className: "container p-t-5", children: /* @__PURE__ */ (0, import_jsx_runtime123.jsx)("div", { className: "row", children: /* @__PURE__ */ (0, import_jsx_runtime123.jsxs)("div", { className: "col-md-6 col-md-offset-3", children: [
20047
- /* @__PURE__ */ (0, import_jsx_runtime123.jsx)("h2", { className: "text-xs-center m-b-3", children: title }),
20048
- /* @__PURE__ */ (0, import_jsx_runtime123.jsx)("p", { className: "text-xs-center m-b-5", children: description }),
20049
- onAction && actionButton && /* @__PURE__ */ (0, import_jsx_runtime123.jsx)(import_components76.Button, { block: true, onClick: onAction, children: actionButton })
20317
+ return /* @__PURE__ */ (0, import_jsx_runtime124.jsx)("div", { className: "container p-t-5", children: /* @__PURE__ */ (0, import_jsx_runtime124.jsx)("div", { className: "row", children: /* @__PURE__ */ (0, import_jsx_runtime124.jsxs)("div", { className: "col-md-6 col-md-offset-3", children: [
20318
+ /* @__PURE__ */ (0, import_jsx_runtime124.jsx)("h2", { className: "text-xs-center m-b-3", children: title }),
20319
+ /* @__PURE__ */ (0, import_jsx_runtime124.jsx)("p", { className: "text-xs-center m-b-5", children: description }),
20320
+ onAction && actionButton && /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(import_components77.Button, { block: true, onClick: onAction, children: actionButton })
20050
20321
  ] }) }) });
20051
20322
  }
20052
20323
  var CameraErrorScreen_default = CameraErrorScreen;
20053
20324
 
20054
20325
  // src/common/cameraCapture/CameraCapture.tsx
20055
- var import_jsx_runtime124 = require("react/jsx-runtime");
20326
+ var import_jsx_runtime125 = require("react/jsx-runtime");
20056
20327
  function CameraCapture({
20057
20328
  direction = "back",
20058
20329
  overlay = "",
@@ -20160,8 +20431,8 @@ function CameraCapture({
20160
20431
  exitFullScreen();
20161
20432
  }
20162
20433
  }, [mode, exitFullScreen]);
20163
- const captureScreen = /* @__PURE__ */ (0, import_jsx_runtime124.jsxs)("div", { className: "camera-capture", children: [
20164
- videoConstraints && /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(
20434
+ const captureScreen = /* @__PURE__ */ (0, import_jsx_runtime125.jsxs)("div", { className: "camera-capture", children: [
20435
+ videoConstraints && /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(
20165
20436
  import_react_webcam.default,
20166
20437
  {
20167
20438
  ref: webcamReference,
@@ -20172,7 +20443,7 @@ function CameraCapture({
20172
20443
  onUserMedia: handleUserMedia
20173
20444
  }
20174
20445
  ),
20175
- /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(
20446
+ /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(
20176
20447
  Overlay_default,
20177
20448
  {
20178
20449
  overlay,
@@ -20182,8 +20453,8 @@ function CameraCapture({
20182
20453
  instructions
20183
20454
  }
20184
20455
  ),
20185
- shouldLockOrientation && /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(OrientationLockOverlay_default, {}),
20186
- ready && /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(
20456
+ shouldLockOrientation && /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(OrientationLockOverlay_default, {}),
20457
+ ready && /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(
20187
20458
  CaptureBottomBar,
20188
20459
  {
20189
20460
  onCapture: () => {
@@ -20192,9 +20463,9 @@ function CameraCapture({
20192
20463
  }
20193
20464
  )
20194
20465
  ] });
20195
- const reviewScreen = /* @__PURE__ */ (0, import_jsx_runtime124.jsxs)("div", { className: "camera-capture", children: [
20196
- /* @__PURE__ */ (0, import_jsx_runtime124.jsx)("img", { className: "review-image", src: reviewImage == null ? void 0 : reviewImage.source, alt: "" }),
20197
- /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(
20466
+ const reviewScreen = /* @__PURE__ */ (0, import_jsx_runtime125.jsxs)("div", { className: "camera-capture", children: [
20467
+ /* @__PURE__ */ (0, import_jsx_runtime125.jsx)("img", { className: "review-image", src: reviewImage == null ? void 0 : reviewImage.source, alt: "" }),
20468
+ /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(
20198
20469
  Overlay_default,
20199
20470
  {
20200
20471
  overlay,
@@ -20204,18 +20475,18 @@ function CameraCapture({
20204
20475
  reviewInstructions: intl.formatMessage(CameraCapture_messages_default.reviewInstructions)
20205
20476
  }
20206
20477
  ),
20207
- /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(ReviewBottomBar, { onSubmit: handleReviewSubmit, onRetry: handleReviewRetry })
20478
+ /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(ReviewBottomBar, { onSubmit: handleReviewSubmit, onRetry: handleReviewRetry })
20208
20479
  ] });
20209
- return /* @__PURE__ */ (0, import_jsx_runtime124.jsxs)("section", { children: [
20480
+ return /* @__PURE__ */ (0, import_jsx_runtime125.jsxs)("section", { children: [
20210
20481
  mode === "CAPTURE" /* CAPTURE */ && captureScreen,
20211
20482
  mode === "REVIEW" /* REVIEW */ && reviewScreen,
20212
- mode === "ERROR" /* ERROR */ && cameraError && /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(CameraErrorScreen_default, __spreadValues({}, cameraError))
20483
+ mode === "ERROR" /* ERROR */ && cameraError && /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(CameraErrorScreen_default, __spreadValues({}, cameraError))
20213
20484
  ] });
20214
20485
  }
20215
20486
  var CameraCapture_default = CameraCapture;
20216
20487
 
20217
20488
  // src/legacy/step/cameraStep/CameraStep.tsx
20218
- var import_jsx_runtime125 = require("react/jsx-runtime");
20489
+ var import_jsx_runtime126 = require("react/jsx-runtime");
20219
20490
  function blobToBase64(blob) {
20220
20491
  return new Promise((resolve, _) => {
20221
20492
  const reader = new FileReader();
@@ -20253,7 +20524,7 @@ function CameraStep(props) {
20253
20524
  });
20254
20525
  }
20255
20526
  };
20256
- return /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(
20527
+ return /* @__PURE__ */ (0, import_jsx_runtime126.jsx)(
20257
20528
  CameraCapture_default,
20258
20529
  {
20259
20530
  overlay,
@@ -20330,12 +20601,12 @@ var external_confirmation_messages_default2 = (0, import_react_intl51.defineMess
20330
20601
  });
20331
20602
 
20332
20603
  // src/legacy/step/externalConfirmationStep/ExternalConfirmationStep.tsx
20333
- var import_jsx_runtime126 = require("react/jsx-runtime");
20604
+ var import_jsx_runtime127 = require("react/jsx-runtime");
20334
20605
  var noop6 = () => {
20335
20606
  };
20336
20607
  function ExternalConfirmationStep({ url, onClose }) {
20337
20608
  const { formatMessage } = (0, import_react_intl52.useIntl)();
20338
- return /* @__PURE__ */ (0, import_jsx_runtime126.jsx)(
20609
+ return /* @__PURE__ */ (0, import_jsx_runtime127.jsx)(
20339
20610
  DynamicLayout_default,
20340
20611
  {
20341
20612
  components: [
@@ -20400,11 +20671,11 @@ function getOrigin2(url) {
20400
20671
  }
20401
20672
 
20402
20673
  // src/legacy/dynamicFlow/BackButton.tsx
20403
- var import_components78 = require("@transferwise/components");
20674
+ var import_components79 = require("@transferwise/components");
20404
20675
  var import_icons6 = require("@transferwise/icons");
20405
- var import_jsx_runtime127 = require("react/jsx-runtime");
20676
+ var import_jsx_runtime128 = require("react/jsx-runtime");
20406
20677
  function BackButton2({ title, action, onAction }) {
20407
- return /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("div", { className: "m-b-2", children: /* @__PURE__ */ (0, import_jsx_runtime127.jsxs)(
20678
+ return /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("div", { className: "m-b-2", children: /* @__PURE__ */ (0, import_jsx_runtime128.jsxs)(
20408
20679
  "a",
20409
20680
  {
20410
20681
  href: "/",
@@ -20415,8 +20686,8 @@ function BackButton2({ title, action, onAction }) {
20415
20686
  onAction(__spreadProps(__spreadValues({}, action), { skipValidation: true }));
20416
20687
  },
20417
20688
  children: [
20418
- /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("span", { className: "sr-only", children: title }),
20419
- /* @__PURE__ */ (0, import_jsx_runtime127.jsx)(import_components78.Avatar, { type: "icon", children: /* @__PURE__ */ (0, import_jsx_runtime127.jsx)(import_icons6.ArrowLeft, { size: "24" }) })
20689
+ /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("span", { className: "sr-only", children: title }),
20690
+ /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(import_components79.Avatar, { type: "icon", children: /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(import_icons6.ArrowLeft, { size: "24" }) })
20420
20691
  ]
20421
20692
  }
20422
20693
  ) });
@@ -20424,7 +20695,7 @@ function BackButton2({ title, action, onAction }) {
20424
20695
  var BackButton_default2 = BackButton2;
20425
20696
 
20426
20697
  // src/legacy/dynamicFlow/DynamicFlowStep.tsx
20427
- var import_jsx_runtime128 = require("react/jsx-runtime");
20698
+ var import_jsx_runtime129 = require("react/jsx-runtime");
20428
20699
  function DynamicFlowStep(props) {
20429
20700
  var _a, _b, _c;
20430
20701
  const { step, globalError, onAction } = props;
@@ -20433,20 +20704,20 @@ function DynamicFlowStep(props) {
20433
20704
  const { requiresManualTrigger, dismissConfirmation } = useExternal2(externalUrl);
20434
20705
  if (step === void 0) {
20435
20706
  if (globalError) {
20436
- return /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(DynamicAlert_default, { component: { context: "negative", markdown: globalError, margin: "lg" } });
20707
+ return /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(DynamicAlert_default, { component: { context: "negative", markdown: globalError, margin: "lg" } });
20437
20708
  }
20438
20709
  return null;
20439
20710
  }
20440
20711
  if (externalUrl && requiresManualTrigger) {
20441
- return /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(ExternalConfirmationStep_default, { url: externalUrl, onClose: dismissConfirmation });
20712
+ return /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(ExternalConfirmationStep_default, { url: externalUrl, onClose: dismissConfirmation });
20442
20713
  }
20443
20714
  if (isCameraStep(step)) {
20444
- return /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(CameraStep_default, __spreadProps(__spreadValues({}, props), { step }));
20715
+ return /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(CameraStep_default, __spreadProps(__spreadValues({}, props), { step }));
20445
20716
  }
20446
- return /* @__PURE__ */ (0, import_jsx_runtime128.jsxs)(import_jsx_runtime128.Fragment, { children: [
20447
- backButton && /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(BackButton_default2, __spreadProps(__spreadValues({}, backButton), { onAction })),
20448
- globalError ? /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(DynamicAlert_default, { component: { context: "negative", markdown: globalError, margin: "lg" } }) : null,
20449
- /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(LayoutStep_default, __spreadProps(__spreadValues({}, props), { stepSpecification: step }))
20717
+ return /* @__PURE__ */ (0, import_jsx_runtime129.jsxs)(import_jsx_runtime129.Fragment, { children: [
20718
+ backButton && /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(BackButton_default2, __spreadProps(__spreadValues({}, backButton), { onAction })),
20719
+ globalError ? /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(DynamicAlert_default, { component: { context: "negative", markdown: globalError, margin: "lg" } }) : null,
20720
+ /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(LayoutStep_default, __spreadProps(__spreadValues({}, props), { stepSpecification: step }))
20450
20721
  ] });
20451
20722
  }
20452
20723
 
@@ -20593,19 +20864,19 @@ var getSchemaReference = (component) => {
20593
20864
  var isInlineSchema = (schema) => schema !== void 0 && typeof schema === "object" && !Object.hasOwnProperty.call(schema, "$ref");
20594
20865
 
20595
20866
  // src/legacy/dynamicFlow/utils/useLoader.tsx
20596
- var import_components79 = require("@transferwise/components");
20867
+ var import_components80 = require("@transferwise/components");
20597
20868
  var import_react66 = require("react");
20598
- var import_jsx_runtime129 = require("react/jsx-runtime");
20869
+ var import_jsx_runtime130 = require("react/jsx-runtime");
20599
20870
  function useLoader(loaderConfig, initialState) {
20600
20871
  const config = __spreadValues({
20601
- size: import_components79.Size.EXTRA_LARGE,
20872
+ size: import_components80.Size.EXTRA_LARGE,
20602
20873
  initial: true,
20603
20874
  submission: false
20604
20875
  }, loaderConfig);
20605
20876
  const [loadingState, setLoadingState] = (0, import_react66.useState)(initialState);
20606
20877
  const shouldDisplayLoader = config.initial && loadingState === "initial" || config.submission && loadingState === "submission";
20607
- const loader = shouldDisplayLoader ? /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(
20608
- import_components79.Loader,
20878
+ const loader = shouldDisplayLoader ? /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(
20879
+ import_components80.Loader,
20609
20880
  {
20610
20881
  size: config.size,
20611
20882
  classNames: { "tw-loader": "tw-loader m-x-auto" },
@@ -20724,7 +20995,7 @@ var useErrorResponse = () => {
20724
20995
  };
20725
20996
 
20726
20997
  // src/legacy/dynamicFlow/DynamicFlow.tsx
20727
- var import_jsx_runtime130 = require("react/jsx-runtime");
20998
+ var import_jsx_runtime131 = require("react/jsx-runtime");
20728
20999
  var noop7 = () => {
20729
21000
  };
20730
21001
  var DynamicFlowComponent = ({
@@ -20967,7 +21238,7 @@ var DynamicFlowComponent = ({
20967
21238
  await performAction(action);
20968
21239
  }
20969
21240
  };
20970
- return /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(LogProvider, { flowId, stepId: (step == null ? void 0 : step.id) || (step == null ? void 0 : step.key), onLog, children: /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(EventsContextProvider, { metadata: analyticsMetadata, onEvent, children: /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(DynamicFlowProvider, { loading: isLoading || isDebouncing, children: /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(HttpClientProvider, { httpClient, children: /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(FeatureContextProvider, { features, children: loader !== null ? loader : /* @__PURE__ */ (0, import_jsx_runtime130.jsx)("div", { id: (step == null ? void 0 : step.id) || (step == null ? void 0 : step.key), className: "dynamic-flow-legacy", children: /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(
21241
+ return /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(LogProvider, { flowId, stepId: (step == null ? void 0 : step.id) || (step == null ? void 0 : step.key), onLog, children: /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(EventsContextProvider, { metadata: analyticsMetadata, onEvent, children: /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(DynamicFlowProvider, { loading: isLoading || isDebouncing, children: /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(HttpClientProvider, { httpClient, children: /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(FeatureContextProvider, { features, children: loader !== null ? loader : /* @__PURE__ */ (0, import_jsx_runtime131.jsx)("div", { id: (step == null ? void 0 : step.id) || (step == null ? void 0 : step.key), className: "dynamic-flow-legacy", children: /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(
20971
21242
  DynamicFlowStep,
20972
21243
  {
20973
21244
  step,
@@ -20984,7 +21255,7 @@ var DynamicFlowComponent = ({
20984
21255
  ) }) }) }) }) }) });
20985
21256
  };
20986
21257
  function DynamicFlow(props) {
20987
- return /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(ErrorBoundary_default, { onError: props.onError, children: /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(DynamicFlowComponent, __spreadValues({}, props)) });
21258
+ return /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(ErrorBoundary_default, { onError: props.onError, children: /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(DynamicFlowComponent, __spreadValues({}, props)) });
20988
21259
  }
20989
21260
  var DynamicFlow_default = DynamicFlow;
20990
21261
  var combineModels2 = (formModels) => Object.values(formModels).reduce((previous, model) => __spreadValues(__spreadValues({}, previous), model), {});
@@ -21001,19 +21272,19 @@ var shouldTriggerRefresh = (props) => {
21001
21272
  };
21002
21273
 
21003
21274
  // src/legacy/jsonSchemaForm/JsonSchemaForm.tsx
21004
- var import_jsx_runtime131 = require("react/jsx-runtime");
21275
+ var import_jsx_runtime132 = require("react/jsx-runtime");
21005
21276
  function JsonSchemaForm(props) {
21006
21277
  const schemaProps = __spreadValues({
21007
21278
  model: null,
21008
21279
  errors: null
21009
21280
  }, props);
21010
21281
  const { baseUrl = "", onEvent = noop8, onLog = noop8 } = props;
21011
- return /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(LogProvider, { flowId: "JsonSchemaForm", stepId: "JsonSchemaForm", onLog, children: /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(
21282
+ return /* @__PURE__ */ (0, import_jsx_runtime132.jsx)(LogProvider, { flowId: "JsonSchemaForm", stepId: "JsonSchemaForm", onLog, children: /* @__PURE__ */ (0, import_jsx_runtime132.jsx)(
21012
21283
  EventsContextProvider,
21013
21284
  {
21014
21285
  metadata: { flowId: "JsonSchemaForm", stepId: "JsonSchemaForm" },
21015
21286
  onEvent,
21016
- children: /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(HttpClientProviderFromBaseUrl, { baseUrl, children: /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(GenericSchema_default, __spreadValues({}, schemaProps)) })
21287
+ children: /* @__PURE__ */ (0, import_jsx_runtime132.jsx)(HttpClientProviderFromBaseUrl, { baseUrl, children: /* @__PURE__ */ (0, import_jsx_runtime132.jsx)(GenericSchema_default, __spreadValues({}, schemaProps)) })
21017
21288
  }
21018
21289
  ) });
21019
21290
  }