@wise/dynamic-flow-client-internal 5.7.0 → 5.8.1

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.
Files changed (48) hide show
  1. package/build/main.css +9 -0
  2. package/build/main.js +353 -272
  3. package/build/main.mjs +276 -201
  4. package/build/types/dynamicFlow/DynamicFlow.d.ts +1 -0
  5. package/build/types/dynamicFlow/DynamicFlow.d.ts.map +1 -0
  6. package/build/types/dynamicFlow/DynamicFlowModal.d.ts +1 -0
  7. package/build/types/dynamicFlow/DynamicFlowModal.d.ts.map +1 -0
  8. package/build/types/dynamicFlow/DynamicFlowWiseProps.d.ts +1 -0
  9. package/build/types/dynamicFlow/DynamicFlowWiseProps.d.ts.map +1 -0
  10. package/build/types/dynamicFlow/DynamicFlowWithRef.d.ts +1 -0
  11. package/build/types/dynamicFlow/DynamicFlowWithRef.d.ts.map +1 -0
  12. package/build/types/dynamicFlow/getMergedRenderers.d.ts +1 -0
  13. package/build/types/dynamicFlow/getMergedRenderers.d.ts.map +1 -0
  14. package/build/types/dynamicFlow/messages.d.ts +1 -0
  15. package/build/types/dynamicFlow/messages.d.ts.map +1 -0
  16. package/build/types/dynamicFlow/renderers.d.ts +2 -1
  17. package/build/types/dynamicFlow/renderers.d.ts.map +1 -0
  18. package/build/types/dynamicFlow/telemetry/app-version.d.ts +1 -0
  19. package/build/types/dynamicFlow/telemetry/app-version.d.ts.map +1 -0
  20. package/build/types/dynamicFlow/telemetry/getLogEvent.d.ts +1 -0
  21. package/build/types/dynamicFlow/telemetry/getLogEvent.d.ts.map +1 -0
  22. package/build/types/dynamicFlow/telemetry/getTrackEvent.d.ts +1 -0
  23. package/build/types/dynamicFlow/telemetry/getTrackEvent.d.ts.map +1 -0
  24. package/build/types/dynamicFlow/telemetry/index.d.ts +1 -0
  25. package/build/types/dynamicFlow/telemetry/index.d.ts.map +1 -0
  26. package/build/types/dynamicFlow/useOnCopy.d.ts +1 -0
  27. package/build/types/dynamicFlow/useOnCopy.d.ts.map +1 -0
  28. package/build/types/dynamicFlow/useWiseHttpClient.d.ts +1 -0
  29. package/build/types/dynamicFlow/useWiseHttpClient.d.ts.map +1 -0
  30. package/build/types/dynamicFlow/useWiseToCoreProps.d.ts +1 -0
  31. package/build/types/dynamicFlow/useWiseToCoreProps.d.ts.map +1 -0
  32. package/build/types/i18n/index.d.ts +1 -0
  33. package/build/types/i18n/index.d.ts.map +1 -0
  34. package/build/types/index.d.ts +1 -0
  35. package/build/types/index.d.ts.map +1 -0
  36. package/build/types/stories/utils/fixtureHttpClient.d.ts +1 -0
  37. package/build/types/stories/utils/fixtureHttpClient.d.ts.map +1 -0
  38. package/build/types/test-utils/NeptuneProviders.d.ts +1 -0
  39. package/build/types/test-utils/NeptuneProviders.d.ts.map +1 -0
  40. package/build/types/test-utils/index.d.ts +1 -0
  41. package/build/types/test-utils/index.d.ts.map +1 -0
  42. package/build/types/test-utils/respond-with.d.ts +1 -0
  43. package/build/types/test-utils/respond-with.d.ts.map +1 -0
  44. package/build/types/test-utils/rtl-utils.d.ts +1 -0
  45. package/build/types/test-utils/rtl-utils.d.ts.map +1 -0
  46. package/build/types/test-utils/wait.d.ts +1 -0
  47. package/build/types/test-utils/wait.d.ts.map +1 -0
  48. package/package.json +17 -17
package/build/main.js CHANGED
@@ -144,7 +144,7 @@ var import_react22 = require("react");
144
144
  // src/dynamicFlow/telemetry/app-version.ts
145
145
  var appVersion = (
146
146
  // eslint-disable-next-line @typescript-eslint/no-unsafe-member-access
147
- typeof process !== "undefined" ? "5.7.0" : "0.0.0"
147
+ typeof process !== "undefined" ? "5.8.1" : "0.0.0"
148
148
  );
149
149
 
150
150
  // src/dynamicFlow/telemetry/getLogEvent.ts
@@ -693,7 +693,10 @@ function ButtonComponent(props) {
693
693
  const buttonProps = {
694
694
  v2: true,
695
695
  block: control !== "small",
696
- className: (0, import_classnames2.default)(getMargin(margin), { "d-block": control === "small" }),
696
+ className: (0, import_classnames2.default)(getMargin(margin), "df-button", {
697
+ small: control === "small",
698
+ "align-center": tags == null ? void 0 : tags.includes("align-center")
699
+ }),
697
700
  addonStart: control === "small" && media ? getAddonStartMedia(media) : void 0,
698
701
  disabled,
699
702
  priority: getPriority(control, tags),
@@ -2089,8 +2092,73 @@ function assertCurrencyCodeIsString(currencyCode) {
2089
2092
  }
2090
2093
  }
2091
2094
 
2092
- // ../renderers/src/MultiSelectInputRenderer.tsx
2095
+ // ../renderers/src/MultiSelectInputRenderer/InlineMultiSelectInputRendererComponent.tsx
2093
2096
  var import_components32 = require("@transferwise/components");
2097
+ var import_jsx_runtime52 = require("react/jsx-runtime");
2098
+ function InlineMultiSelectInputRendererComponent(props) {
2099
+ const {
2100
+ id,
2101
+ description,
2102
+ disabled,
2103
+ help,
2104
+ options,
2105
+ selectedIndices,
2106
+ title,
2107
+ validationState,
2108
+ onSelect
2109
+ } = props;
2110
+ return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
2111
+ FieldInput_default,
2112
+ {
2113
+ id,
2114
+ label: title,
2115
+ help,
2116
+ description,
2117
+ validation: validationState,
2118
+ children: options.map((option, index) => {
2119
+ var _a;
2120
+ const {
2121
+ title: itemTitle,
2122
+ description: subtitle,
2123
+ disabled: optionDisabled,
2124
+ media,
2125
+ additionalText,
2126
+ inlineAlert,
2127
+ supportingValues,
2128
+ childrenProps
2129
+ } = option;
2130
+ const key = (_a = childrenProps == null ? void 0 : childrenProps.uid) != null ? _a : index;
2131
+ return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
2132
+ import_components32.ListItem,
2133
+ {
2134
+ title: itemTitle,
2135
+ subtitle,
2136
+ valueTitle: supportingValues == null ? void 0 : supportingValues.value,
2137
+ valueSubtitle: supportingValues == null ? void 0 : supportingValues.subvalue,
2138
+ media: getMedia(media, false),
2139
+ prompt: getInlineAlert(inlineAlert),
2140
+ additionalInfo: additionalText ? /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(import_components32.ListItem.AdditionalInfo, { children: additionalText }) : void 0,
2141
+ disabled: disabled || optionDisabled,
2142
+ control: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
2143
+ import_components32.ListItem.Checkbox,
2144
+ {
2145
+ checked: selectedIndices.includes(index),
2146
+ onChange: (e) => {
2147
+ const newSelectedIndices = e.target.checked ? [...selectedIndices, index] : selectedIndices.filter((i) => i !== index);
2148
+ onSelect(newSelectedIndices);
2149
+ }
2150
+ }
2151
+ )
2152
+ },
2153
+ key
2154
+ );
2155
+ })
2156
+ }
2157
+ );
2158
+ }
2159
+
2160
+ // ../renderers/src/MultiSelectInputRenderer/MultiSelectInputRendererComponent.tsx
2161
+ var import_components33 = require("@transferwise/components");
2094
2162
  var import_react10 = require("react");
2095
2163
  var import_react_intl13 = require("react-intl");
2096
2164
 
@@ -2104,12 +2172,8 @@ var multi_select_messages_default = (0, import_react_intl12.defineMessages)({
2104
2172
  }
2105
2173
  });
2106
2174
 
2107
- // ../renderers/src/MultiSelectInputRenderer.tsx
2108
- var import_jsx_runtime52 = require("react/jsx-runtime");
2109
- var MultiSelectInputRenderer = {
2110
- canRenderType: "input-multi-select",
2111
- render: (props) => /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(MultiSelectInputRendererComponent, __spreadValues({}, props))
2112
- };
2175
+ // ../renderers/src/MultiSelectInputRenderer/MultiSelectInputRendererComponent.tsx
2176
+ var import_jsx_runtime53 = require("react/jsx-runtime");
2113
2177
  function MultiSelectInputRendererComponent(props) {
2114
2178
  const { formatMessage } = (0, import_react_intl13.useIntl)();
2115
2179
  const [stagedIndices, setStagedIndices] = (0, import_react10.useState)();
@@ -2150,12 +2214,12 @@ function MultiSelectInputRendererComponent(props) {
2150
2214
  const contentProps = {
2151
2215
  title: option.title,
2152
2216
  description: option.description,
2153
- icon: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(OptionMedia, { media: option.media, preferAvatar: false })
2217
+ icon: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(OptionMedia, { media: option.media, preferAvatar: false })
2154
2218
  };
2155
- return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(import_components32.SelectInputOptionContent, __spreadValues({}, contentProps));
2219
+ return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(import_components33.SelectInputOptionContent, __spreadValues({}, contentProps));
2156
2220
  };
2157
2221
  const extraProps = { autoComplete };
2158
- return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
2222
+ return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
2159
2223
  FieldInput_default,
2160
2224
  {
2161
2225
  id,
@@ -2163,8 +2227,8 @@ function MultiSelectInputRendererComponent(props) {
2163
2227
  help,
2164
2228
  description,
2165
2229
  validation: validationState,
2166
- children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
2167
- import_components32.SelectInput,
2230
+ children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
2231
+ import_components33.SelectInput,
2168
2232
  __spreadValues({
2169
2233
  id,
2170
2234
  items: options.map((option, index) => {
@@ -2200,15 +2264,23 @@ function MultiSelectInputRendererComponent(props) {
2200
2264
  }
2201
2265
  );
2202
2266
  }
2203
- var MultiSelectInputRenderer_default = MultiSelectInputRenderer;
2267
+
2268
+ // ../renderers/src/MultiSelectInputRenderer/MultiSelectInputRenderer.tsx
2269
+ var import_jsx_runtime54 = require("react/jsx-runtime");
2270
+ var MultiSelectInputRenderer = {
2271
+ canRenderType: "input-multi-select",
2272
+ render: (props) => {
2273
+ return props.control === "inline" ? /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(InlineMultiSelectInputRendererComponent, __spreadValues({}, props)) : /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(MultiSelectInputRendererComponent, __spreadValues({}, props));
2274
+ }
2275
+ };
2204
2276
 
2205
2277
  // ../renderers/src/MultiUploadInputRenderer.tsx
2206
- var import_components34 = require("@transferwise/components");
2278
+ var import_components35 = require("@transferwise/components");
2207
2279
 
2208
2280
  // ../renderers/src/components/UploadFieldInput.tsx
2209
- var import_components33 = require("@transferwise/components");
2281
+ var import_components34 = require("@transferwise/components");
2210
2282
  var import_classnames4 = __toESM(require_classnames());
2211
- var import_jsx_runtime53 = require("react/jsx-runtime");
2283
+ var import_jsx_runtime55 = require("react/jsx-runtime");
2212
2284
  function UploadFieldInput({
2213
2285
  id,
2214
2286
  children,
@@ -2217,18 +2289,18 @@ function UploadFieldInput({
2217
2289
  help,
2218
2290
  validation
2219
2291
  }) {
2220
- const labelContent = label && help ? /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(LabelContentWithHelp, { text: label, help }) : label;
2292
+ const labelContent = label && help ? /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(LabelContentWithHelp, { text: label, help }) : label;
2221
2293
  const descriptionId = description ? `${id}-description` : void 0;
2222
- return /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(
2294
+ return /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(
2223
2295
  "div",
2224
2296
  {
2225
2297
  className: (0, import_classnames4.default)("form-group d-block", {
2226
2298
  "has-error": (validation == null ? void 0 : validation.status) === "invalid"
2227
2299
  }),
2228
2300
  children: [
2229
- /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("label", { htmlFor: id, className: "control-label", children: labelContent }),
2301
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("label", { htmlFor: id, className: "control-label", children: labelContent }),
2230
2302
  children,
2231
- (validation == null ? void 0 : validation.status) === "invalid" && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(import_components33.InlineAlert, { type: "negative", id: descriptionId, children: validation.message })
2303
+ (validation == null ? void 0 : validation.status) === "invalid" && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(import_components34.InlineAlert, { type: "negative", id: descriptionId, children: validation.message })
2232
2304
  ]
2233
2305
  }
2234
2306
  );
@@ -2263,7 +2335,7 @@ var getSizeLimit = (maxSize) => {
2263
2335
  };
2264
2336
 
2265
2337
  // ../renderers/src/MultiUploadInputRenderer.tsx
2266
- var import_jsx_runtime54 = require("react/jsx-runtime");
2338
+ var import_jsx_runtime56 = require("react/jsx-runtime");
2267
2339
  var MultiUploadInputRenderer = {
2268
2340
  canRenderType: "input-upload-multi",
2269
2341
  render: (props) => {
@@ -2288,7 +2360,7 @@ var MultiUploadInputRenderer = {
2288
2360
  };
2289
2361
  const onDeleteFile = async (fileId) => onRemoveFile(value.findIndex((file) => file.id === fileId));
2290
2362
  const descriptionId = description ? `${id}-description` : void 0;
2291
- return /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
2363
+ return /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
2292
2364
  UploadFieldInput_default,
2293
2365
  {
2294
2366
  id,
@@ -2296,8 +2368,8 @@ var MultiUploadInputRenderer = {
2296
2368
  description,
2297
2369
  validation: validationState,
2298
2370
  help,
2299
- children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
2300
- import_components34.UploadInput,
2371
+ children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
2372
+ import_components35.UploadInput,
2301
2373
  {
2302
2374
  id,
2303
2375
  "aria-describedby": descriptionId,
@@ -2306,7 +2378,7 @@ var MultiUploadInputRenderer = {
2306
2378
  files: value.map(({ id: id2, file, validationState: validationState2 }) => ({
2307
2379
  id: id2,
2308
2380
  filename: file.name,
2309
- status: (validationState2 == null ? void 0 : validationState2.status) === "invalid" ? import_components34.Status.FAILED : import_components34.Status.SUCCEEDED
2381
+ status: (validationState2 == null ? void 0 : validationState2.status) === "invalid" ? import_components35.Status.FAILED : import_components35.Status.SUCCEEDED
2310
2382
  })),
2311
2383
  fileTypes: acceptsToFileTypes(accepts),
2312
2384
  maxFiles: maxItems,
@@ -2324,8 +2396,8 @@ var MultiUploadInputRenderer = {
2324
2396
  var MultiUploadInputRenderer_default = MultiUploadInputRenderer;
2325
2397
 
2326
2398
  // ../renderers/src/NumberInputRenderer.tsx
2327
- var import_components35 = require("@transferwise/components");
2328
- var import_jsx_runtime55 = require("react/jsx-runtime");
2399
+ var import_components36 = require("@transferwise/components");
2400
+ var import_jsx_runtime57 = require("react/jsx-runtime");
2329
2401
  var NumberInputRenderer = {
2330
2402
  canRenderType: "input-number",
2331
2403
  render: (props) => {
@@ -2339,7 +2411,7 @@ var NumberInputRenderer = {
2339
2411
  "maximum",
2340
2412
  "minimum"
2341
2413
  );
2342
- return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
2414
+ return /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
2343
2415
  FieldInput_default,
2344
2416
  {
2345
2417
  id,
@@ -2347,8 +2419,8 @@ var NumberInputRenderer = {
2347
2419
  description,
2348
2420
  validation: validationState,
2349
2421
  help,
2350
- children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(import_components35.InputGroup, { addonStart: getInputGroupAddonStart(media), children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
2351
- import_components35.Input,
2422
+ children: /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(import_components36.InputGroup, { addonStart: getInputGroupAddonStart(media), children: /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
2423
+ import_components36.Input,
2352
2424
  __spreadValues({
2353
2425
  id,
2354
2426
  name: id,
@@ -2371,16 +2443,16 @@ var NumberInputRenderer_default = NumberInputRenderer;
2371
2443
  var import_react_intl15 = require("react-intl");
2372
2444
 
2373
2445
  // ../renderers/src/hooks/useSnackBarIfAvailable.ts
2374
- var import_components36 = require("@transferwise/components");
2446
+ var import_components37 = require("@transferwise/components");
2375
2447
  var import_react11 = require("react");
2376
2448
  function useSnackBarIfAvailable() {
2377
- const context = (0, import_react11.useContext)(import_components36.SnackbarContext);
2449
+ const context = (0, import_react11.useContext)(import_components37.SnackbarContext);
2378
2450
  return context ? context.createSnackbar : () => {
2379
2451
  };
2380
2452
  }
2381
2453
 
2382
2454
  // ../renderers/src/ParagraphRenderer.tsx
2383
- var import_components37 = require("@transferwise/components");
2455
+ var import_components38 = require("@transferwise/components");
2384
2456
  var import_classnames5 = __toESM(require_classnames());
2385
2457
 
2386
2458
  // ../renderers/src/messages/paragraph.messages.ts
@@ -2399,14 +2471,14 @@ var paragraph_messages_default = (0, import_react_intl14.defineMessages)({
2399
2471
  });
2400
2472
 
2401
2473
  // ../renderers/src/ParagraphRenderer.tsx
2402
- var import_jsx_runtime56 = require("react/jsx-runtime");
2474
+ var import_jsx_runtime58 = require("react/jsx-runtime");
2403
2475
  var ParagraphRenderer = {
2404
2476
  canRenderType: "paragraph",
2405
- render: (props) => /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(Paragraph, __spreadValues({}, props))
2477
+ render: (props) => /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(Paragraph, __spreadValues({}, props))
2406
2478
  };
2407
2479
  function Paragraph({ align, control, margin, size, text }) {
2408
2480
  const className = getTextAlignmentAndMargin({ align, margin });
2409
- return control === "copyable" ? /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(CopyableParagraph, { className, align, text }) : /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
2481
+ return control === "copyable" ? /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(CopyableParagraph, { className, align, text }) : /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
2410
2482
  "p",
2411
2483
  {
2412
2484
  className: `${["xs", "sm"].includes(size) ? "np-text-body-default" : "np-text-body-large"} ${className}`,
@@ -2426,9 +2498,9 @@ function CopyableParagraph({
2426
2498
  });
2427
2499
  };
2428
2500
  const inputAlignmentClasses = getTextAlignmentAndMargin({ align, margin: "sm" });
2429
- return /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)("div", { className, children: [
2430
- /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
2431
- import_components37.Input,
2501
+ return /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className, children: [
2502
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
2503
+ import_components38.Input,
2432
2504
  {
2433
2505
  type: "text",
2434
2506
  value: text,
@@ -2436,23 +2508,23 @@ function CopyableParagraph({
2436
2508
  className: (0, import_classnames5.default)("text-ellipsis", inputAlignmentClasses)
2437
2509
  }
2438
2510
  ),
2439
- /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(import_components37.Button, { v2: true, block: true, onClick: copy, children: formatMessage(paragraph_messages_default.copy) })
2511
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_components38.Button, { v2: true, block: true, onClick: copy, children: formatMessage(paragraph_messages_default.copy) })
2440
2512
  ] });
2441
2513
  }
2442
2514
  var ParagraphRenderer_default = ParagraphRenderer;
2443
2515
 
2444
2516
  // ../renderers/src/ProgressRenderer.tsx
2445
- var import_components38 = require("@transferwise/components");
2446
- var import_jsx_runtime57 = require("react/jsx-runtime");
2517
+ var import_components39 = require("@transferwise/components");
2518
+ var import_jsx_runtime59 = require("react/jsx-runtime");
2447
2519
  var ProgressRenderer = {
2448
2520
  canRenderType: "progress",
2449
2521
  render: ({ uid, title, help, progress, progressText, margin, description }) => {
2450
- return /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
2451
- import_components38.ProgressBar,
2522
+ return /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
2523
+ import_components39.ProgressBar,
2452
2524
  {
2453
2525
  id: uid,
2454
2526
  className: getMargin(margin),
2455
- title: title && help ? /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(LabelContentWithHelp, { text: title, help }) : title,
2527
+ title: title && help ? /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(LabelContentWithHelp, { text: title, help }) : title,
2456
2528
  description,
2457
2529
  progress: {
2458
2530
  max: 1,
@@ -2465,7 +2537,7 @@ var ProgressRenderer = {
2465
2537
  };
2466
2538
 
2467
2539
  // ../renderers/src/RepeatableRenderer.tsx
2468
- var import_components39 = require("@transferwise/components");
2540
+ var import_components40 = require("@transferwise/components");
2469
2541
  var import_icons = require("@transferwise/icons");
2470
2542
  var import_classnames6 = __toESM(require_classnames());
2471
2543
  var import_react12 = require("react");
@@ -2497,10 +2569,10 @@ var repeatable_messages_default = (0, import_react_intl16.defineMessages)({
2497
2569
  });
2498
2570
 
2499
2571
  // ../renderers/src/RepeatableRenderer.tsx
2500
- var import_jsx_runtime58 = require("react/jsx-runtime");
2572
+ var import_jsx_runtime60 = require("react/jsx-runtime");
2501
2573
  var RepeatableRenderer = {
2502
2574
  canRenderType: "repeatable",
2503
- render: (props) => /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(Repeatable, __spreadValues({}, props))
2575
+ render: (props) => /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(Repeatable, __spreadValues({}, props))
2504
2576
  };
2505
2577
  function Repeatable(props) {
2506
2578
  const {
@@ -2539,41 +2611,41 @@ function Repeatable(props) {
2539
2611
  const onCancelEdit = () => {
2540
2612
  setOpenModalType(null);
2541
2613
  };
2542
- return /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(import_jsx_runtime58.Fragment, { children: [
2543
- title && /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_components39.Header, { title }),
2544
- description && /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("p", { children: description }),
2545
- /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(
2614
+ return /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(import_jsx_runtime60.Fragment, { children: [
2615
+ title && /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(import_components40.Header, { title }),
2616
+ description && /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("p", { children: description }),
2617
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(
2546
2618
  "div",
2547
2619
  {
2548
2620
  className: (0, import_classnames6.default)("form-group", {
2549
2621
  "has-error": (validationState == null ? void 0 : validationState.status) === "invalid"
2550
2622
  }),
2551
2623
  children: [
2552
- items == null ? void 0 : items.map((item, index) => /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(ItemSummaryOption, { item, onClick: () => onEditItem(index) }, item.id)),
2553
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
2554
- import_components39.NavigationOption,
2624
+ items == null ? void 0 : items.map((item, index) => /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(ItemSummaryOption, { item, onClick: () => onEditItem(index) }, item.id)),
2625
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
2626
+ import_components40.NavigationOption,
2555
2627
  {
2556
- media: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_icons.Plus, {}),
2628
+ media: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(import_icons.Plus, {}),
2557
2629
  title: addItemTitle || formatMessage(repeatable_messages_default.addItemTitle),
2558
2630
  showMediaAtAllSizes: true,
2559
2631
  onClick: () => onAddItem()
2560
2632
  }
2561
2633
  ),
2562
- (validationState == null ? void 0 : validationState.status) === "invalid" && /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_components39.InlineAlert, { type: "negative", children: validationState.message })
2634
+ (validationState == null ? void 0 : validationState.status) === "invalid" && /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(import_components40.InlineAlert, { type: "negative", children: validationState.message })
2563
2635
  ]
2564
2636
  }
2565
2637
  ),
2566
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
2567
- import_components39.Modal,
2638
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
2639
+ import_components40.Modal,
2568
2640
  {
2569
2641
  open: openModalType !== null,
2570
2642
  title: (openModalType === "add" ? addItemTitle : editItemTitle) || formatMessage(repeatable_messages_default.addItemTitle),
2571
- body: /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(import_jsx_runtime58.Fragment, { children: [
2572
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { className: "m-b-2", children: editableItem }),
2573
- /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { children: [
2574
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_components39.Button, { priority: "primary", block: true, className: "m-b-2", onClick: () => onSaveItem(), children: formatMessage(repeatable_messages_default.addItem) }),
2575
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
2576
- import_components39.Button,
2643
+ body: /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(import_jsx_runtime60.Fragment, { children: [
2644
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { className: "m-b-2", children: editableItem }),
2645
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("div", { children: [
2646
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(import_components40.Button, { priority: "primary", block: true, className: "m-b-2", onClick: () => onSaveItem(), children: formatMessage(repeatable_messages_default.addItem) }),
2647
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
2648
+ import_components40.Button,
2577
2649
  {
2578
2650
  v2: true,
2579
2651
  priority: "secondary",
@@ -2594,10 +2666,10 @@ function ItemSummaryOption({
2594
2666
  item,
2595
2667
  onClick
2596
2668
  }) {
2597
- return /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
2598
- import_components39.NavigationOption,
2669
+ return /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
2670
+ import_components40.NavigationOption,
2599
2671
  {
2600
- media: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(OptionMedia, { media: item.media, preferAvatar: false }),
2672
+ media: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(OptionMedia, { media: item.media, preferAvatar: false }),
2601
2673
  title: item.title,
2602
2674
  content: item.description,
2603
2675
  showMediaAtAllSizes: true,
@@ -2609,16 +2681,16 @@ function ItemSummaryOption({
2609
2681
  var RepeatableRenderer_default = RepeatableRenderer;
2610
2682
 
2611
2683
  // ../renderers/src/ReviewLegacyRenderer.tsx
2612
- var import_components40 = require("@transferwise/components");
2613
- var import_jsx_runtime59 = require("react/jsx-runtime");
2684
+ var import_components41 = require("@transferwise/components");
2685
+ var import_jsx_runtime61 = require("react/jsx-runtime");
2614
2686
  var ReviewRenderer = {
2615
2687
  canRenderType: "review",
2616
2688
  render: ({ callToAction, control, fields, margin, title, trackEvent }) => {
2617
2689
  const orientation = mapControlToDefinitionListLayout(control);
2618
- return /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("div", { className: getMargin(margin), children: [
2619
- /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(Header5, { title, callToAction }),
2620
- /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("div", { className: margin, children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
2621
- import_components40.DefinitionList,
2690
+ return /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)("div", { className: getMargin(margin), children: [
2691
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(Header5, { title, callToAction }),
2692
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("div", { className: margin, children: /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
2693
+ import_components41.DefinitionList,
2622
2694
  {
2623
2695
  layout: orientation,
2624
2696
  definitions: fields.map(
@@ -2655,20 +2727,20 @@ var mapControlToDefinitionListLayout = (control) => {
2655
2727
  };
2656
2728
  var getFieldLabel = (label, help, onClick) => {
2657
2729
  if (help) {
2658
- return /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)(import_jsx_runtime59.Fragment, { children: [
2730
+ return /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)(import_jsx_runtime61.Fragment, { children: [
2659
2731
  label,
2660
2732
  " ",
2661
- /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(Help_default, { help, onClick })
2733
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(Help_default, { help, onClick })
2662
2734
  ] });
2663
2735
  }
2664
2736
  return label;
2665
2737
  };
2666
2738
 
2667
2739
  // ../renderers/src/ReviewRenderer.tsx
2668
- var import_components41 = require("@transferwise/components");
2740
+ var import_components42 = require("@transferwise/components");
2669
2741
  var import_icons2 = require("@transferwise/icons");
2670
2742
  var import_react_intl18 = require("react-intl");
2671
- var import_jsx_runtime60 = require("react/jsx-runtime");
2743
+ var import_jsx_runtime62 = require("react/jsx-runtime");
2672
2744
  var IGNORED_CONTROLS = [
2673
2745
  "horizontal",
2674
2746
  "horizontal-end-aligned",
@@ -2678,7 +2750,7 @@ var IGNORED_CONTROLS = [
2678
2750
  var ReviewRenderer2 = {
2679
2751
  canRenderType: "review",
2680
2752
  canRender: ({ control }) => control ? !IGNORED_CONTROLS.includes(control) : true,
2681
- render: (props) => /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(Review, __spreadValues({}, props))
2753
+ render: (props) => /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(Review, __spreadValues({}, props))
2682
2754
  };
2683
2755
  var Review = ({
2684
2756
  callToAction,
@@ -2690,8 +2762,8 @@ var Review = ({
2690
2762
  trackEvent
2691
2763
  }) => {
2692
2764
  const intl = (0, import_react_intl18.useIntl)();
2693
- return /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("div", { className: getMargin(margin), children: [
2694
- /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(Header5, { title, callToAction }),
2765
+ return /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)("div", { className: getMargin(margin), children: [
2766
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(Header5, { title, callToAction }),
2695
2767
  fields.map((field) => {
2696
2768
  var _a, _b, _c;
2697
2769
  const {
@@ -2709,8 +2781,8 @@ var Review = ({
2709
2781
  ctaSecondary: (_a = itemTags == null ? void 0 : itemTags.includes("cta-secondary")) != null ? _a : false,
2710
2782
  fullyInteractive: (_b = (tags == null ? void 0 : tags.includes("fully-interactive")) && (additionalInfo == null ? void 0 : additionalInfo.onClick) == null) != null ? _b : false
2711
2783
  };
2712
- return /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
2713
- import_components41.ListItem,
2784
+ return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
2785
+ import_components42.ListItem,
2714
2786
  {
2715
2787
  title: value,
2716
2788
  subtitle: label,
@@ -2730,12 +2802,12 @@ var Review = ({
2730
2802
  ] });
2731
2803
  };
2732
2804
  var getHelpControl = (help, ariaLabel, onClick) => {
2733
- return /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(import_components41.Popover, { content: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(import_components41.Markdown, { config: { link: { target: "_blank" } }, children: help }), children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(import_components41.ListItem.IconButton, { partiallyInteractive: true, "aria-label": ariaLabel, onClick, children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(import_icons2.QuestionMarkCircle, {}) }) });
2805
+ return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(import_components42.Popover, { content: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(import_components42.Markdown, { config: { link: { target: "_blank" } }, children: help }), children: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(import_components42.ListItem.IconButton, { partiallyInteractive: true, "aria-label": ariaLabel, onClick, children: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(import_icons2.QuestionMarkCircle, {}) }) });
2734
2806
  };
2735
2807
  var ReviewRenderer_default = ReviewRenderer2;
2736
2808
 
2737
2809
  // ../renderers/src/SearchRenderer/BlockSearchRendererComponent.tsx
2738
- var import_components43 = require("@transferwise/components");
2810
+ var import_components44 = require("@transferwise/components");
2739
2811
  var import_react13 = require("react");
2740
2812
  var import_react_intl22 = require("react-intl");
2741
2813
 
@@ -2773,20 +2845,20 @@ var generic_error_messages_default = (0, import_react_intl20.defineMessages)({
2773
2845
  });
2774
2846
 
2775
2847
  // ../renderers/src/SearchRenderer/ErrorResult.tsx
2776
- var import_components42 = require("@transferwise/components");
2777
- var import_jsx_runtime61 = require("react/jsx-runtime");
2848
+ var import_components43 = require("@transferwise/components");
2849
+ var import_jsx_runtime63 = require("react/jsx-runtime");
2778
2850
  function ErrorResult({ state }) {
2779
2851
  const intl = (0, import_react_intl21.useIntl)();
2780
- return /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)("p", { className: "m-t-2", children: [
2852
+ return /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)("p", { className: "m-t-2", children: [
2781
2853
  intl.formatMessage(generic_error_messages_default.genericError),
2782
2854
  "\xA0",
2783
- /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(import_components42.Link, { onClick: () => state.onRetry(), children: intl.formatMessage(generic_error_messages_default.retry) })
2855
+ /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(import_components43.Link, { onClick: () => state.onRetry(), children: intl.formatMessage(generic_error_messages_default.retry) })
2784
2856
  ] });
2785
2857
  }
2786
2858
 
2787
2859
  // ../renderers/src/SearchRenderer/BlockSearchRendererComponent.tsx
2788
2860
  var import_icons3 = require("@transferwise/icons");
2789
- var import_jsx_runtime62 = require("react/jsx-runtime");
2861
+ var import_jsx_runtime64 = require("react/jsx-runtime");
2790
2862
  function BlockSearchRendererComponent({
2791
2863
  id,
2792
2864
  hint,
@@ -2800,9 +2872,9 @@ function BlockSearchRendererComponent({
2800
2872
  }) {
2801
2873
  const [hasSearched, setHasSearched] = (0, import_react13.useState)(false);
2802
2874
  const { formatMessage } = (0, import_react_intl22.useIntl)();
2803
- return /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)("div", { className: getMargin(margin), children: [
2804
- /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(FieldInput_default, { id, description: "", validation: void 0, help: "", label: title, children: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(import_components43.InputGroup, { addonStart: { content: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(import_icons3.Search, { size: 24 }) }, children: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
2805
- import_components43.Input,
2875
+ return /* @__PURE__ */ (0, import_jsx_runtime64.jsxs)("div", { className: getMargin(margin), children: [
2876
+ /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(FieldInput_default, { id, description: "", validation: void 0, help: "", label: title, children: /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(import_components44.InputGroup, { addonStart: { content: /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(import_icons3.Search, { size: 24 }) }, children: /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(
2877
+ import_components44.Input,
2806
2878
  {
2807
2879
  id,
2808
2880
  name: id,
@@ -2818,7 +2890,7 @@ function BlockSearchRendererComponent({
2818
2890
  }
2819
2891
  }
2820
2892
  ) }) }),
2821
- isLoading ? /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("span", { children: formatMessage(search_messages_default.loading) }) : /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(SearchResultContent, { state, trackEvent })
2893
+ isLoading ? /* @__PURE__ */ (0, import_jsx_runtime64.jsx)("span", { children: formatMessage(search_messages_default.loading) }) : /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(SearchResultContent, { state, trackEvent })
2822
2894
  ] });
2823
2895
  }
2824
2896
  function SearchResultContent({
@@ -2827,33 +2899,39 @@ function SearchResultContent({
2827
2899
  }) {
2828
2900
  switch (state.type) {
2829
2901
  case "error":
2830
- return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(ErrorResult, { state });
2902
+ return /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(ErrorResult, { state });
2831
2903
  case "results":
2832
- return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(SearchResults, { state, trackEvent });
2904
+ return /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(SearchResults, { state, trackEvent });
2905
+ case "layout":
2906
+ return /* @__PURE__ */ (0, import_jsx_runtime64.jsxs)(import_jsx_runtime64.Fragment, { children: [
2907
+ " ",
2908
+ state.layout,
2909
+ " "
2910
+ ] });
2833
2911
  case "noResults":
2834
- return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(EmptySearchResult, { state });
2912
+ return /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(EmptySearchResult, { state });
2835
2913
  case "pending":
2836
2914
  default:
2837
2915
  return null;
2838
2916
  }
2839
2917
  }
2840
2918
  function EmptySearchResult({ state }) {
2841
- return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(import_components43.Markdown, { className: "m-t-2", config: { link: { target: "_blank" } }, children: state.message });
2919
+ return /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(import_components44.Markdown, { className: "m-t-2", config: { link: { target: "_blank" } }, children: state.message });
2842
2920
  }
2843
2921
  function SearchResults({
2844
2922
  state,
2845
2923
  trackEvent
2846
2924
  }) {
2847
- return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(import_components43.List, { children: state.results.map((result) => {
2925
+ return /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(import_components44.List, { children: state.results.map((result) => {
2848
2926
  const { media } = result;
2849
- return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
2850
- import_components43.ListItem,
2927
+ return /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(
2928
+ import_components44.ListItem,
2851
2929
  {
2852
2930
  title: result.title,
2853
2931
  subtitle: result.description,
2854
- media: media ? /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(OptionMedia, { media, preferAvatar: false }) : void 0,
2855
- control: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
2856
- import_components43.ListItem.Navigation,
2932
+ media: media ? /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(OptionMedia, { media, preferAvatar: false }) : void 0,
2933
+ control: /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(
2934
+ import_components44.ListItem.Navigation,
2857
2935
  {
2858
2936
  onClick: () => {
2859
2937
  trackEvent("Search Result Selected", __spreadValues({
@@ -2871,11 +2949,11 @@ function SearchResults({
2871
2949
  var BlockSearchRendererComponent_default = BlockSearchRendererComponent;
2872
2950
 
2873
2951
  // ../renderers/src/SearchRenderer/InlineSearchRendererComponent.tsx
2874
- var import_components44 = require("@transferwise/components");
2952
+ var import_components45 = require("@transferwise/components");
2875
2953
  var import_icons4 = require("@transferwise/icons");
2876
2954
  var import_react14 = require("react");
2877
2955
  var import_react_intl23 = require("react-intl");
2878
- var import_jsx_runtime63 = require("react/jsx-runtime");
2956
+ var import_jsx_runtime65 = require("react/jsx-runtime");
2879
2957
  function InlineSearchRenderer({
2880
2958
  id,
2881
2959
  hint,
@@ -2888,8 +2966,8 @@ function InlineSearchRenderer({
2888
2966
  }) {
2889
2967
  const [hasSearched, setHasSearched] = (0, import_react14.useState)(false);
2890
2968
  const intl = (0, import_react_intl23.useIntl)();
2891
- return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("div", { className: getMargin(margin), children: /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(FieldInput_default, { id, description: "", validation: void 0, help: "", label: title, children: /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
2892
- import_components44.Typeahead,
2969
+ return /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("div", { className: getMargin(margin), children: /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(FieldInput_default, { id, description: "", validation: void 0, help: "", label: title, children: /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(
2970
+ import_components45.Typeahead,
2893
2971
  {
2894
2972
  id: "typeahead-input-id",
2895
2973
  intl,
@@ -2897,10 +2975,10 @@ function InlineSearchRenderer({
2897
2975
  size: "md",
2898
2976
  placeholder: hint,
2899
2977
  maxHeight: 100,
2900
- footer: /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(TypeaheadFooter, { state, isLoading }),
2978
+ footer: /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(TypeaheadFooter, { state, isLoading }),
2901
2979
  multiple: false,
2902
2980
  clearable: false,
2903
- addon: /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(import_icons4.Search, { size: 24 }),
2981
+ addon: /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(import_icons4.Search, { size: 24 }),
2904
2982
  options: state.type === "results" ? state.results.map(mapResultToTypeaheadOption) : [],
2905
2983
  minQueryLength: 1,
2906
2984
  onChange: (values) => {
@@ -2936,29 +3014,32 @@ function mapResultToTypeaheadOption(result) {
2936
3014
  }
2937
3015
  function TypeaheadFooter({ state, isLoading }) {
2938
3016
  const { formatMessage } = (0, import_react_intl23.useIntl)();
3017
+ if (state.type === "layout") {
3018
+ return /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("div", { className: "m-x-1 m-y-1", children: state.layout });
3019
+ }
2939
3020
  if (state.type === "noResults") {
2940
- return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(import_components44.Markdown, { className: "m-t-2 m-x-2", config: { link: { target: "_blank" } }, children: state.message });
3021
+ return /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(import_components45.Markdown, { className: "m-t-2 m-x-2", config: { link: { target: "_blank" } }, children: state.message });
2941
3022
  }
2942
3023
  if (state.type === "error") {
2943
- return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("div", { className: "m-t-2 m-x-2", children: /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(ErrorResult, { state }) });
3024
+ return /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("div", { className: "m-t-2 m-x-2", children: /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(ErrorResult, { state }) });
2944
3025
  }
2945
3026
  if (state.type === "pending" || isLoading) {
2946
- return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("p", { className: "m-t-2 m-x-2", children: formatMessage(search_messages_default.loading) });
3027
+ return /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("p", { className: "m-t-2 m-x-2", children: formatMessage(search_messages_default.loading) });
2947
3028
  }
2948
3029
  return null;
2949
3030
  }
2950
3031
  var InlineSearchRendererComponent_default = InlineSearchRenderer;
2951
3032
 
2952
3033
  // ../renderers/src/SearchRenderer/SearchRenderer.tsx
2953
- var import_jsx_runtime64 = require("react/jsx-runtime");
3034
+ var import_jsx_runtime66 = require("react/jsx-runtime");
2954
3035
  var SearchRenderer = {
2955
3036
  canRenderType: "search",
2956
- render: (props) => props.control === "inline" ? /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(InlineSearchRendererComponent_default, __spreadValues({}, props)) : /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(BlockSearchRendererComponent_default, __spreadValues({}, props))
3037
+ render: (props) => props.control === "inline" ? /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(InlineSearchRendererComponent_default, __spreadValues({}, props)) : /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(BlockSearchRendererComponent_default, __spreadValues({}, props))
2957
3038
  };
2958
3039
  var SearchRenderer_default = SearchRenderer;
2959
3040
 
2960
3041
  // ../renderers/src/SectionRenderer.tsx
2961
- var import_components45 = require("@transferwise/components");
3042
+ var import_components46 = require("@transferwise/components");
2962
3043
 
2963
3044
  // ../renderers/src/utils/getHeaderAction.tsx
2964
3045
  var getHeaderAction2 = (callToAction) => {
@@ -2982,12 +3063,12 @@ var getHeaderAction2 = (callToAction) => {
2982
3063
  };
2983
3064
 
2984
3065
  // ../renderers/src/SectionRenderer.tsx
2985
- var import_jsx_runtime65 = require("react/jsx-runtime");
3066
+ var import_jsx_runtime67 = require("react/jsx-runtime");
2986
3067
  var SectionRenderer = {
2987
3068
  canRenderType: "section",
2988
3069
  render: ({ children, callToAction, margin, title }) => {
2989
- return /* @__PURE__ */ (0, import_jsx_runtime65.jsxs)("section", { className: getMargin(margin), children: [
2990
- (title || callToAction) && /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(import_components45.Header, { title: title != null ? title : "", action: getHeaderAction2(callToAction) }),
3070
+ return /* @__PURE__ */ (0, import_jsx_runtime67.jsxs)("section", { className: getMargin(margin), children: [
3071
+ (title || callToAction) && /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(import_components46.Header, { title: title != null ? title : "", action: getHeaderAction2(callToAction) }),
2991
3072
  children
2992
3073
  ] });
2993
3074
  }
@@ -2995,8 +3076,8 @@ var SectionRenderer = {
2995
3076
  var SectionRenderer_default = SectionRenderer;
2996
3077
 
2997
3078
  // ../renderers/src/SelectInputRenderer/RadioInputRendererComponent.tsx
2998
- var import_components46 = require("@transferwise/components");
2999
- var import_jsx_runtime66 = require("react/jsx-runtime");
3079
+ var import_components47 = require("@transferwise/components");
3080
+ var import_jsx_runtime68 = require("react/jsx-runtime");
3000
3081
  function RadioInputRendererComponent(props) {
3001
3082
  const {
3002
3083
  id,
@@ -3010,8 +3091,8 @@ function RadioInputRendererComponent(props) {
3010
3091
  validationState,
3011
3092
  onSelect
3012
3093
  } = props;
3013
- return /* @__PURE__ */ (0, import_jsx_runtime66.jsxs)(import_jsx_runtime66.Fragment, { children: [
3014
- /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(
3094
+ return /* @__PURE__ */ (0, import_jsx_runtime68.jsxs)(import_jsx_runtime68.Fragment, { children: [
3095
+ /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
3015
3096
  FieldInput_default,
3016
3097
  {
3017
3098
  id,
@@ -3019,8 +3100,8 @@ function RadioInputRendererComponent(props) {
3019
3100
  help,
3020
3101
  description,
3021
3102
  validation: validationState,
3022
- children: /* @__PURE__ */ (0, import_jsx_runtime66.jsx)("span", { children: /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(
3023
- import_components46.RadioGroup,
3103
+ children: /* @__PURE__ */ (0, import_jsx_runtime68.jsx)("span", { children: /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
3104
+ import_components47.RadioGroup,
3024
3105
  {
3025
3106
  name: id,
3026
3107
  radios: options.map((option, index) => ({
@@ -3028,7 +3109,7 @@ function RadioInputRendererComponent(props) {
3028
3109
  value: index,
3029
3110
  secondary: option.description,
3030
3111
  disabled: option.disabled || disabled,
3031
- avatar: /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(OptionMedia, { media: option.media, preferAvatar: false })
3112
+ avatar: /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(OptionMedia, { media: option.media, preferAvatar: false })
3032
3113
  })),
3033
3114
  selectedValue: selectedIndex != null ? selectedIndex : void 0,
3034
3115
  onChange: onSelect
@@ -3042,9 +3123,9 @@ function RadioInputRendererComponent(props) {
3042
3123
  }
3043
3124
 
3044
3125
  // ../renderers/src/SelectInputRenderer/TabInputRendererComponent.tsx
3045
- var import_components47 = require("@transferwise/components");
3126
+ var import_components48 = require("@transferwise/components");
3046
3127
  var import_react15 = require("react");
3047
- var import_jsx_runtime67 = require("react/jsx-runtime");
3128
+ var import_jsx_runtime69 = require("react/jsx-runtime");
3048
3129
  function TabInputRendererComponent(props) {
3049
3130
  const {
3050
3131
  id,
@@ -3063,8 +3144,8 @@ function TabInputRendererComponent(props) {
3063
3144
  onSelect(0);
3064
3145
  }
3065
3146
  }, [selectedIndex, onSelect, options.length]);
3066
- return /* @__PURE__ */ (0, import_jsx_runtime67.jsxs)(import_jsx_runtime67.Fragment, { children: [
3067
- /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
3147
+ return /* @__PURE__ */ (0, import_jsx_runtime69.jsxs)(import_jsx_runtime69.Fragment, { children: [
3148
+ /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(
3068
3149
  FieldInput_default,
3069
3150
  {
3070
3151
  id,
@@ -3072,8 +3153,8 @@ function TabInputRendererComponent(props) {
3072
3153
  help,
3073
3154
  description,
3074
3155
  validation: validationState,
3075
- children: /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
3076
- import_components47.Tabs,
3156
+ children: /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(
3157
+ import_components48.Tabs,
3077
3158
  {
3078
3159
  name: id,
3079
3160
  selected: selectedIndex != null ? selectedIndex : 0,
@@ -3081,7 +3162,7 @@ function TabInputRendererComponent(props) {
3081
3162
  title: option.title,
3082
3163
  // if we pass null, we get some props-types console errors
3083
3164
  // eslint-disable-next-line react/jsx-no-useless-fragment
3084
- content: /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(import_jsx_runtime67.Fragment, {}),
3165
+ content: /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(import_jsx_runtime69.Fragment, {}),
3085
3166
  disabled: option.disabled || disabled
3086
3167
  })),
3087
3168
  onTabSelect: onSelect
@@ -3095,8 +3176,8 @@ function TabInputRendererComponent(props) {
3095
3176
  var isValidIndex2 = (index, options) => index !== null && index >= 0 && index < options;
3096
3177
 
3097
3178
  // ../renderers/src/SelectInputRenderer/SelectInputRendererComponent.tsx
3098
- var import_components48 = require("@transferwise/components");
3099
- var import_jsx_runtime68 = require("react/jsx-runtime");
3179
+ var import_components49 = require("@transferwise/components");
3180
+ var import_jsx_runtime70 = require("react/jsx-runtime");
3100
3181
  function SelectInputRendererComponent(props) {
3101
3182
  const {
3102
3183
  id,
@@ -3136,13 +3217,13 @@ function SelectInputRendererComponent(props) {
3136
3217
  } : {
3137
3218
  title: option.title,
3138
3219
  description: option.description,
3139
- icon: /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(OptionMedia, { media: option.media, preferAvatar: false })
3220
+ icon: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(OptionMedia, { media: option.media, preferAvatar: false })
3140
3221
  };
3141
- return /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(import_components48.SelectInputOptionContent, __spreadValues({}, contentProps));
3222
+ return /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_components49.SelectInputOptionContent, __spreadValues({}, contentProps));
3142
3223
  };
3143
3224
  const extraProps = { autoComplete };
3144
- return /* @__PURE__ */ (0, import_jsx_runtime68.jsxs)(import_jsx_runtime68.Fragment, { children: [
3145
- /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
3225
+ return /* @__PURE__ */ (0, import_jsx_runtime70.jsxs)(import_jsx_runtime70.Fragment, { children: [
3226
+ /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(
3146
3227
  FieldInput_default,
3147
3228
  {
3148
3229
  id,
@@ -3150,8 +3231,8 @@ function SelectInputRendererComponent(props) {
3150
3231
  help,
3151
3232
  description,
3152
3233
  validation: validationState,
3153
- children: /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
3154
- import_components48.SelectInput,
3234
+ children: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(
3235
+ import_components49.SelectInput,
3155
3236
  __spreadValues({
3156
3237
  name: id,
3157
3238
  placeholder,
@@ -3172,8 +3253,8 @@ function SelectInputRendererComponent(props) {
3172
3253
 
3173
3254
  // ../renderers/src/SelectInputRenderer/SegmentedInputRendererComponent.tsx
3174
3255
  var import_react16 = require("react");
3175
- var import_components49 = require("@transferwise/components");
3176
- var import_jsx_runtime69 = require("react/jsx-runtime");
3256
+ var import_components50 = require("@transferwise/components");
3257
+ var import_jsx_runtime71 = require("react/jsx-runtime");
3177
3258
  function SegmentedInputRendererComponent(props) {
3178
3259
  const {
3179
3260
  id,
@@ -3191,8 +3272,8 @@ function SegmentedInputRendererComponent(props) {
3191
3272
  onSelect(0);
3192
3273
  }
3193
3274
  }, [selectedIndex, onSelect, options.length]);
3194
- return /* @__PURE__ */ (0, import_jsx_runtime69.jsxs)(import_jsx_runtime69.Fragment, { children: [
3195
- /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(
3275
+ return /* @__PURE__ */ (0, import_jsx_runtime71.jsxs)(import_jsx_runtime71.Fragment, { children: [
3276
+ /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(
3196
3277
  FieldInput_default,
3197
3278
  {
3198
3279
  id,
@@ -3200,8 +3281,8 @@ function SegmentedInputRendererComponent(props) {
3200
3281
  help,
3201
3282
  description,
3202
3283
  validation: validationState,
3203
- children: /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(
3204
- import_components49.SegmentedControl,
3284
+ children: /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(
3285
+ import_components50.SegmentedControl,
3205
3286
  {
3206
3287
  name: `${id}-segmented-control`,
3207
3288
  value: String(selectedIndex),
@@ -3217,14 +3298,14 @@ function SegmentedInputRendererComponent(props) {
3217
3298
  )
3218
3299
  }
3219
3300
  ),
3220
- /* @__PURE__ */ (0, import_jsx_runtime69.jsx)("div", { id: `${id}-children`, children })
3301
+ /* @__PURE__ */ (0, import_jsx_runtime71.jsx)("div", { id: `${id}-children`, children })
3221
3302
  ] });
3222
3303
  }
3223
3304
  var isValidIndex3 = (index, options) => index !== null && index >= 0 && index < options;
3224
3305
 
3225
3306
  // ../renderers/src/SelectInputRenderer/RadioItemRendererComponent.tsx
3226
- var import_components50 = require("@transferwise/components");
3227
- var import_jsx_runtime70 = require("react/jsx-runtime");
3307
+ var import_components51 = require("@transferwise/components");
3308
+ var import_jsx_runtime72 = require("react/jsx-runtime");
3228
3309
  function RadioItemRendererComponent(props) {
3229
3310
  const {
3230
3311
  id,
@@ -3238,23 +3319,23 @@ function RadioItemRendererComponent(props) {
3238
3319
  validationState,
3239
3320
  onSelect
3240
3321
  } = props;
3241
- return /* @__PURE__ */ (0, import_jsx_runtime70.jsxs)(import_jsx_runtime70.Fragment, { children: [
3242
- rootTitle && /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(
3243
- import_components50.Header,
3322
+ return /* @__PURE__ */ (0, import_jsx_runtime72.jsxs)(import_jsx_runtime72.Fragment, { children: [
3323
+ rootTitle && /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(
3324
+ import_components51.Header,
3244
3325
  {
3245
3326
  as: "h2",
3246
- title: help ? /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(LabelContentWithHelp, { text: rootTitle, help }) : rootTitle
3327
+ title: help ? /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(LabelContentWithHelp, { text: rootTitle, help }) : rootTitle
3247
3328
  }
3248
3329
  ),
3249
- rootDescription && /* @__PURE__ */ (0, import_jsx_runtime70.jsx)("p", { children: rootDescription }),
3250
- /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_components50.List, { children: options.map(
3251
- ({ title, description, additionalText, inlineAlert, disabled, media, supportingValues }, index) => /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(
3252
- import_components50.ListItem,
3330
+ rootDescription && /* @__PURE__ */ (0, import_jsx_runtime72.jsx)("p", { children: rootDescription }),
3331
+ /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_components51.List, { children: options.map(
3332
+ ({ title, description, additionalText, inlineAlert, disabled, media, supportingValues }, index) => /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(
3333
+ import_components51.ListItem,
3253
3334
  __spreadValues({
3254
3335
  title,
3255
3336
  subtitle: description,
3256
- control: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(
3257
- import_components50.ListItem.Radio,
3337
+ control: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(
3338
+ import_components51.ListItem.Radio,
3258
3339
  {
3259
3340
  name: title,
3260
3341
  checked: selectedIndex === index,
@@ -3269,50 +3350,50 @@ function RadioItemRendererComponent(props) {
3269
3350
  title
3270
3351
  )
3271
3352
  ) }, `${id}-${selectedIndex}`),
3272
- (validationState == null ? void 0 : validationState.status) === "invalid" && /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_components50.InlineAlert, { type: "negative", children: validationState.message }),
3353
+ (validationState == null ? void 0 : validationState.status) === "invalid" && /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_components51.InlineAlert, { type: "negative", children: validationState.message }),
3273
3354
  children
3274
3355
  ] });
3275
3356
  }
3276
3357
 
3277
3358
  // ../renderers/src/SelectInputRenderer/SelectInputRenderer.tsx
3278
- var import_jsx_runtime71 = require("react/jsx-runtime");
3359
+ var import_jsx_runtime73 = require("react/jsx-runtime");
3279
3360
  var SelectInputRenderer = {
3280
3361
  canRenderType: "input-select",
3281
3362
  render: (props) => {
3282
3363
  switch (props.control) {
3283
3364
  case "radio":
3284
- return /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(RadioInputRendererComponent, __spreadValues({}, props));
3365
+ return /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(RadioInputRendererComponent, __spreadValues({}, props));
3285
3366
  case "radio-item":
3286
- return /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(RadioItemRendererComponent, __spreadValues({}, props));
3367
+ return /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(RadioItemRendererComponent, __spreadValues({}, props));
3287
3368
  case "tab":
3288
- return props.options.length > 3 ? /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(SelectInputRendererComponent, __spreadValues({}, props)) : /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(TabInputRendererComponent, __spreadValues({}, props));
3369
+ return props.options.length > 3 ? /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(SelectInputRendererComponent, __spreadValues({}, props)) : /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(TabInputRendererComponent, __spreadValues({}, props));
3289
3370
  case "segmented":
3290
- return props.options.length > 3 ? /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(SelectInputRendererComponent, __spreadValues({}, props)) : /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(SegmentedInputRendererComponent, __spreadValues({}, props));
3371
+ return props.options.length > 3 ? /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(SelectInputRendererComponent, __spreadValues({}, props)) : /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(SegmentedInputRendererComponent, __spreadValues({}, props));
3291
3372
  case "select":
3292
3373
  default:
3293
- return /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(SelectInputRendererComponent, __spreadValues({}, props));
3374
+ return /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(SelectInputRendererComponent, __spreadValues({}, props));
3294
3375
  }
3295
3376
  }
3296
3377
  };
3297
3378
  var SelectInputRenderer_default = SelectInputRenderer;
3298
3379
 
3299
3380
  // ../renderers/src/StatusListRenderer.tsx
3300
- var import_components51 = require("@transferwise/components");
3301
- var import_jsx_runtime72 = require("react/jsx-runtime");
3381
+ var import_components52 = require("@transferwise/components");
3382
+ var import_jsx_runtime74 = require("react/jsx-runtime");
3302
3383
  var StatusListRenderer = {
3303
3384
  canRenderType: "status-list",
3304
- render: ({ margin, items, title }) => /* @__PURE__ */ (0, import_jsx_runtime72.jsxs)("div", { className: getMargin(margin), children: [
3305
- title ? /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_components51.Header, { title }) : null,
3385
+ render: ({ margin, items, title }) => /* @__PURE__ */ (0, import_jsx_runtime74.jsxs)("div", { className: getMargin(margin), children: [
3386
+ title ? /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(import_components52.Header, { title }) : null,
3306
3387
  items.map((item) => {
3307
3388
  const { callToAction, description, icon, status, title: itemTitle } = item;
3308
- return /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(
3309
- import_components51.ListItem,
3389
+ return /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(
3390
+ import_components52.ListItem,
3310
3391
  {
3311
3392
  title: itemTitle,
3312
3393
  subtitle: description,
3313
- media: icon && "name" in icon ? /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_components51.AvatarView, { badge: { status: mapStatus(status) }, children: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(DynamicIcon_default, { name: icon.name }) }) : void 0,
3314
- additionalInfo: callToAction ? /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(
3315
- import_components51.ListItem.AdditionalInfo,
3394
+ media: icon && "name" in icon ? /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(import_components52.AvatarView, { badge: { status: mapStatus(status) }, children: /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(DynamicIcon_default, { name: icon.name }) }) : void 0,
3395
+ additionalInfo: callToAction ? /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(
3396
+ import_components52.ListItem.AdditionalInfo,
3316
3397
  {
3317
3398
  action: {
3318
3399
  href: callToAction.href,
@@ -3359,7 +3440,7 @@ var useCustomTheme = (theme, trackEvent) => {
3359
3440
  };
3360
3441
 
3361
3442
  // ../renderers/src/step/topbar/BackButton.tsx
3362
- var import_components52 = require("@transferwise/components");
3443
+ var import_components53 = require("@transferwise/components");
3363
3444
  var import_icons5 = require("@transferwise/icons");
3364
3445
  var import_react_intl25 = require("react-intl");
3365
3446
 
@@ -3374,31 +3455,31 @@ var back_messages_default = (0, import_react_intl24.defineMessages)({
3374
3455
  });
3375
3456
 
3376
3457
  // ../renderers/src/step/topbar/BackButton.tsx
3377
- var import_jsx_runtime73 = require("react/jsx-runtime");
3458
+ var import_jsx_runtime75 = require("react/jsx-runtime");
3378
3459
  function BackButton({ title, onClick }) {
3379
3460
  const { formatMessage } = (0, import_react_intl25.useIntl)();
3380
- return /* @__PURE__ */ (0, import_jsx_runtime73.jsxs)(import_components52.IconButton, { className: "df-back-button", priority: "tertiary", onClick, children: [
3381
- /* @__PURE__ */ (0, import_jsx_runtime73.jsx)("span", { className: "sr-only", children: title != null ? title : formatMessage(back_messages_default.back) }),
3382
- /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(import_icons5.ArrowLeft, {})
3461
+ return /* @__PURE__ */ (0, import_jsx_runtime75.jsxs)(import_components53.IconButton, { className: "df-back-button", priority: "tertiary", onClick, children: [
3462
+ /* @__PURE__ */ (0, import_jsx_runtime75.jsx)("span", { className: "sr-only", children: title != null ? title : formatMessage(back_messages_default.back) }),
3463
+ /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(import_icons5.ArrowLeft, {})
3383
3464
  ] });
3384
3465
  }
3385
3466
 
3386
3467
  // ../renderers/src/step/topbar/Toolbar.tsx
3387
- var import_components53 = require("@transferwise/components");
3388
- var import_jsx_runtime74 = require("react/jsx-runtime");
3468
+ var import_components54 = require("@transferwise/components");
3469
+ var import_jsx_runtime76 = require("react/jsx-runtime");
3389
3470
  var Toolbar = ({ items }) => {
3390
- return (items == null ? void 0 : items.length) > 0 ? /* @__PURE__ */ (0, import_jsx_runtime74.jsx)("div", { className: "df-toolbar", children: items.map((item, index) => /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(ToolbarButton, __spreadValues({}, item), `${item.type}-${index}-${item.title}`)) }) : null;
3471
+ return (items == null ? void 0 : items.length) > 0 ? /* @__PURE__ */ (0, import_jsx_runtime76.jsx)("div", { className: "df-toolbar", children: items.map((item, index) => /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(ToolbarButton, __spreadValues({}, item), `${item.type}-${index}-${item.title}`)) }) : null;
3391
3472
  };
3392
3473
  function ToolbarButton(props) {
3393
- return prefersMedia(props.control) ? /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(MediaToolbarButton, __spreadValues({}, props)) : /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(TextToolbarButton, __spreadValues({}, props));
3474
+ return prefersMedia(props.control) ? /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(MediaToolbarButton, __spreadValues({}, props)) : /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(TextToolbarButton, __spreadValues({}, props));
3394
3475
  }
3395
3476
  function MediaToolbarButton(props) {
3396
3477
  var _a;
3397
3478
  const { context, control, media, accessibilityDescription, disabled, onClick } = props;
3398
3479
  const priority = getIconButtonPriority(control);
3399
3480
  const type = getSentiment2(context);
3400
- return /* @__PURE__ */ (0, import_jsx_runtime74.jsxs)(
3401
- import_components53.IconButton,
3481
+ return /* @__PURE__ */ (0, import_jsx_runtime76.jsxs)(
3482
+ import_components54.IconButton,
3402
3483
  {
3403
3484
  className: "df-toolbar-button",
3404
3485
  disabled,
@@ -3407,7 +3488,7 @@ function MediaToolbarButton(props) {
3407
3488
  type,
3408
3489
  onClick,
3409
3490
  children: [
3410
- accessibilityDescription ? /* @__PURE__ */ (0, import_jsx_runtime74.jsx)("span", { className: "sr-only", children: accessibilityDescription }) : null,
3491
+ accessibilityDescription ? /* @__PURE__ */ (0, import_jsx_runtime76.jsx)("span", { className: "sr-only", children: accessibilityDescription }) : null,
3411
3492
  media ? (_a = getAddonStartMedia(media)) == null ? void 0 : _a.value : null
3412
3493
  ]
3413
3494
  }
@@ -3418,8 +3499,8 @@ function TextToolbarButton(props) {
3418
3499
  const addonStart = media ? getAddonStartMedia(media) : void 0;
3419
3500
  const priority = getPriority2(control);
3420
3501
  const sentiment = getSentiment2(context);
3421
- return /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(
3422
- import_components53.Button,
3502
+ return /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(
3503
+ import_components54.Button,
3423
3504
  {
3424
3505
  v2: true,
3425
3506
  size: "sm",
@@ -3448,16 +3529,16 @@ var getIconButtonPriority = (control) => {
3448
3529
  };
3449
3530
 
3450
3531
  // ../renderers/src/step/topbar/TopBar.tsx
3451
- var import_jsx_runtime75 = require("react/jsx-runtime");
3532
+ var import_jsx_runtime77 = require("react/jsx-runtime");
3452
3533
  function TopBar({ back, toolbar }) {
3453
- return back || toolbar ? /* @__PURE__ */ (0, import_jsx_runtime75.jsxs)("div", { className: "d-flex m-b-2", children: [
3454
- back ? /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(BackButton, __spreadValues({}, back)) : null,
3455
- toolbar ? /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(Toolbar, __spreadValues({}, toolbar)) : null
3534
+ return back || toolbar ? /* @__PURE__ */ (0, import_jsx_runtime77.jsxs)("div", { className: "d-flex m-b-2", children: [
3535
+ back ? /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(BackButton, __spreadValues({}, back)) : null,
3536
+ toolbar ? /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(Toolbar, __spreadValues({}, toolbar)) : null
3456
3537
  ] }) : null;
3457
3538
  }
3458
3539
 
3459
3540
  // ../renderers/src/step/SplashCelebrationStepRenderer.tsx
3460
- var import_jsx_runtime76 = require("react/jsx-runtime");
3541
+ var import_jsx_runtime78 = require("react/jsx-runtime");
3461
3542
  var SplashCelebrationStepRenderer = {
3462
3543
  canRenderType: "step",
3463
3544
  canRender: ({ control }) => control === "splash-celebration",
@@ -3467,15 +3548,15 @@ function SplashCelebrationStepRendererComponent(props) {
3467
3548
  const { back, toolbar, children, footer, trackEvent } = props;
3468
3549
  const hasFooter = footer && Array.isArray(footer) && footer.length > 0;
3469
3550
  useCustomTheme("forest-green", trackEvent);
3470
- return /* @__PURE__ */ (0, import_jsx_runtime76.jsxs)("div", { className: "splash-screen m-t-5", children: [
3471
- /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(TopBar, { back, toolbar }),
3551
+ return /* @__PURE__ */ (0, import_jsx_runtime78.jsxs)("div", { className: "splash-screen m-t-5", children: [
3552
+ /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(TopBar, { back, toolbar }),
3472
3553
  children,
3473
- hasFooter ? /* @__PURE__ */ (0, import_jsx_runtime76.jsx)("div", { className: "df-step-fixed__footer", children: footer }) : void 0
3554
+ hasFooter ? /* @__PURE__ */ (0, import_jsx_runtime78.jsx)("div", { className: "df-step-fixed__footer", children: footer }) : void 0
3474
3555
  ] });
3475
3556
  }
3476
3557
 
3477
3558
  // ../renderers/src/step/SplashStepRenderer.tsx
3478
- var import_jsx_runtime77 = require("react/jsx-runtime");
3559
+ var import_jsx_runtime79 = require("react/jsx-runtime");
3479
3560
  var SplashStepRenderer = {
3480
3561
  canRenderType: "step",
3481
3562
  canRender: ({ control }) => control === "splash",
@@ -3484,16 +3565,16 @@ var SplashStepRenderer = {
3484
3565
  function SplashStepRendererComponent(props) {
3485
3566
  const { back, toolbar, children, footer } = props;
3486
3567
  const hasFooter = footer && Array.isArray(footer) && footer.length > 0;
3487
- return /* @__PURE__ */ (0, import_jsx_runtime77.jsxs)("div", { className: "splash-screen m-t-5", children: [
3488
- /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(TopBar, { back, toolbar }),
3568
+ return /* @__PURE__ */ (0, import_jsx_runtime79.jsxs)("div", { className: "splash-screen m-t-5", children: [
3569
+ /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(TopBar, { back, toolbar }),
3489
3570
  children,
3490
- hasFooter ? /* @__PURE__ */ (0, import_jsx_runtime77.jsx)("div", { className: "df-step-fixed__footer", children: footer }) : void 0
3571
+ hasFooter ? /* @__PURE__ */ (0, import_jsx_runtime79.jsx)("div", { className: "df-step-fixed__footer", children: footer }) : void 0
3491
3572
  ] });
3492
3573
  }
3493
3574
 
3494
3575
  // ../renderers/src/step/StepRenderer.tsx
3495
- var import_components54 = require("@transferwise/components");
3496
- var import_jsx_runtime78 = require("react/jsx-runtime");
3576
+ var import_components55 = require("@transferwise/components");
3577
+ var import_jsx_runtime80 = require("react/jsx-runtime");
3497
3578
  var StepRenderer = {
3498
3579
  canRenderType: "step",
3499
3580
  render: StepRendererComponent
@@ -3501,19 +3582,19 @@ var StepRenderer = {
3501
3582
  function StepRendererComponent(props) {
3502
3583
  const { back, description, error, title, children, toolbar, footer, tags } = props;
3503
3584
  const hasFooter = footer && Array.isArray(footer) && footer.length > 0;
3504
- return /* @__PURE__ */ (0, import_jsx_runtime78.jsxs)("div", { children: [
3505
- /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(TopBar, { back, toolbar }),
3506
- title || description ? /* @__PURE__ */ (0, import_jsx_runtime78.jsx)("div", { className: "m-b-4", children: /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(Header10, { title, description, tags }) }) : void 0,
3507
- error ? /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(import_components54.Alert, { type: "negative", className: "m-b-2", message: error }) : null,
3585
+ return /* @__PURE__ */ (0, import_jsx_runtime80.jsxs)("div", { children: [
3586
+ /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(TopBar, { back, toolbar }),
3587
+ title || description ? /* @__PURE__ */ (0, import_jsx_runtime80.jsx)("div", { className: "m-b-4", children: /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(Header10, { title, description, tags }) }) : void 0,
3588
+ error ? /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(import_components55.Alert, { type: "negative", className: "m-b-2", message: error }) : null,
3508
3589
  children,
3509
- hasFooter ? /* @__PURE__ */ (0, import_jsx_runtime78.jsx)("div", { className: "df-step-fixed__footer", children: footer }) : void 0
3590
+ hasFooter ? /* @__PURE__ */ (0, import_jsx_runtime80.jsx)("div", { className: "df-step-fixed__footer", children: footer }) : void 0
3510
3591
  ] });
3511
3592
  }
3512
3593
  var Header10 = ({ title, description, tags }) => {
3513
3594
  const { titleType, alignmentClassName } = getHeaderStyle(tags);
3514
- return /* @__PURE__ */ (0, import_jsx_runtime78.jsxs)(import_jsx_runtime78.Fragment, { children: [
3515
- title ? /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(import_components54.Title, { as: "h1", type: titleType, className: `${alignmentClassName} m-b-2`, children: title }) : void 0,
3516
- description ? /* @__PURE__ */ (0, import_jsx_runtime78.jsx)("p", { className: `${alignmentClassName} np-text-body-large`, children: description }) : void 0
3595
+ return /* @__PURE__ */ (0, import_jsx_runtime80.jsxs)(import_jsx_runtime80.Fragment, { children: [
3596
+ title ? /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(import_components55.Title, { as: "h1", type: titleType, className: `${alignmentClassName} m-b-2`, children: title }) : void 0,
3597
+ description ? /* @__PURE__ */ (0, import_jsx_runtime80.jsx)("p", { className: `${alignmentClassName} np-text-body-large`, children: description }) : void 0
3517
3598
  ] });
3518
3599
  };
3519
3600
  var getHeaderStyle = (tags) => {
@@ -3524,36 +3605,36 @@ var getHeaderStyle = (tags) => {
3524
3605
  };
3525
3606
 
3526
3607
  // ../renderers/src/TabsRenderer.tsx
3527
- var import_components55 = require("@transferwise/components");
3608
+ var import_components56 = require("@transferwise/components");
3528
3609
  var import_react18 = require("react");
3529
- var import_jsx_runtime79 = require("react/jsx-runtime");
3610
+ var import_jsx_runtime81 = require("react/jsx-runtime");
3530
3611
  var TabsRenderer = {
3531
3612
  canRenderType: "tabs",
3532
3613
  render: (props) => {
3533
3614
  switch (props.control) {
3534
3615
  case "segmented":
3535
3616
  if (props.tabs.length > 3) {
3536
- return /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(TabsRendererComponent, __spreadValues({}, props));
3617
+ return /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(TabsRendererComponent, __spreadValues({}, props));
3537
3618
  }
3538
- return /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(SegmentedTabsRendererComponent, __spreadValues({}, props));
3619
+ return /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(SegmentedTabsRendererComponent, __spreadValues({}, props));
3539
3620
  case "chips":
3540
- return /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(ChipsTabsRendererComponent, __spreadValues({}, props));
3621
+ return /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(ChipsTabsRendererComponent, __spreadValues({}, props));
3541
3622
  default:
3542
- return /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(TabsRendererComponent, __spreadValues({}, props));
3623
+ return /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(TabsRendererComponent, __spreadValues({}, props));
3543
3624
  }
3544
3625
  }
3545
3626
  };
3546
3627
  function TabsRendererComponent({ uid, margin, tabs }) {
3547
3628
  const [selectedIndex, setSelectedIndex] = (0, import_react18.useState)(0);
3548
- return /* @__PURE__ */ (0, import_jsx_runtime79.jsx)("div", { className: getMargin(margin), children: /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(
3549
- import_components55.Tabs,
3629
+ return /* @__PURE__ */ (0, import_jsx_runtime81.jsx)("div", { className: getMargin(margin), children: /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(
3630
+ import_components56.Tabs,
3550
3631
  {
3551
3632
  name: uid,
3552
3633
  selected: selectedIndex != null ? selectedIndex : 0,
3553
3634
  tabs: tabs.map((option) => ({
3554
3635
  title: option.title,
3555
3636
  disabled: false,
3556
- content: /* @__PURE__ */ (0, import_jsx_runtime79.jsxs)("div", { className: "m-t-2", children: [
3637
+ content: /* @__PURE__ */ (0, import_jsx_runtime81.jsxs)("div", { className: "m-t-2", children: [
3557
3638
  " ",
3558
3639
  option.children,
3559
3640
  " "
@@ -3566,9 +3647,9 @@ function TabsRendererComponent({ uid, margin, tabs }) {
3566
3647
  function SegmentedTabsRendererComponent({ uid, margin, tabs }) {
3567
3648
  var _a;
3568
3649
  const [selectedIndex, setSelectedIndex] = (0, import_react18.useState)(0);
3569
- return /* @__PURE__ */ (0, import_jsx_runtime79.jsxs)("div", { className: getMargin(margin), children: [
3570
- /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(
3571
- import_components55.SegmentedControl,
3650
+ return /* @__PURE__ */ (0, import_jsx_runtime81.jsxs)("div", { className: getMargin(margin), children: [
3651
+ /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(
3652
+ import_components56.SegmentedControl,
3572
3653
  {
3573
3654
  name: uid,
3574
3655
  value: String(selectedIndex),
@@ -3582,31 +3663,31 @@ function SegmentedTabsRendererComponent({ uid, margin, tabs }) {
3582
3663
  onChange: (value) => setSelectedIndex(Number(value))
3583
3664
  }
3584
3665
  ),
3585
- /* @__PURE__ */ (0, import_jsx_runtime79.jsx)("div", { id: `${uid}-children`, className: "m-t-2", children: (_a = tabs[selectedIndex]) == null ? void 0 : _a.children })
3666
+ /* @__PURE__ */ (0, import_jsx_runtime81.jsx)("div", { id: `${uid}-children`, className: "m-t-2", children: (_a = tabs[selectedIndex]) == null ? void 0 : _a.children })
3586
3667
  ] });
3587
3668
  }
3588
3669
  function ChipsTabsRendererComponent({ margin, tabs }) {
3589
3670
  var _a;
3590
3671
  const [selectedIndex, setSelectedIndex] = (0, import_react18.useState)(0);
3591
- return /* @__PURE__ */ (0, import_jsx_runtime79.jsxs)("div", { className: getMargin(margin), children: [
3592
- /* @__PURE__ */ (0, import_jsx_runtime79.jsx)("div", { className: "chips-container", children: /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(
3593
- import_components55.Chips,
3672
+ return /* @__PURE__ */ (0, import_jsx_runtime81.jsxs)("div", { className: getMargin(margin), children: [
3673
+ /* @__PURE__ */ (0, import_jsx_runtime81.jsx)("div", { className: "chips-container", children: /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(
3674
+ import_components56.Chips,
3594
3675
  {
3595
3676
  chips: tabs.map((tab, index) => ({ label: tab.title, value: index })),
3596
3677
  selected: selectedIndex,
3597
3678
  onChange: ({ selectedValue }) => setSelectedIndex(Number(selectedValue))
3598
3679
  }
3599
3680
  ) }),
3600
- /* @__PURE__ */ (0, import_jsx_runtime79.jsx)("div", { className: "m-t-2", children: (_a = tabs[selectedIndex]) == null ? void 0 : _a.children })
3681
+ /* @__PURE__ */ (0, import_jsx_runtime81.jsx)("div", { className: "m-t-2", children: (_a = tabs[selectedIndex]) == null ? void 0 : _a.children })
3601
3682
  ] });
3602
3683
  }
3603
3684
 
3604
3685
  // ../renderers/src/TextInputRenderer.tsx
3605
- var import_components57 = require("@transferwise/components");
3686
+ var import_components58 = require("@transferwise/components");
3606
3687
 
3607
3688
  // ../renderers/src/components/VariableTextInput.tsx
3608
- var import_components56 = require("@transferwise/components");
3609
- var import_jsx_runtime80 = require("react/jsx-runtime");
3689
+ var import_components57 = require("@transferwise/components");
3690
+ var import_jsx_runtime82 = require("react/jsx-runtime");
3610
3691
  var commonKeys = [
3611
3692
  "autoComplete",
3612
3693
  "autoCapitalize",
@@ -3625,12 +3706,12 @@ function VariableTextInput(inputProps) {
3625
3706
  const commonProps = __spreadProps(__spreadValues({}, pick(inputProps, ...commonKeys)), { name: id });
3626
3707
  switch (control) {
3627
3708
  case "email":
3628
- return /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(TextInput, __spreadProps(__spreadValues({}, commonProps), { type: "email", onChange }));
3709
+ return /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(TextInput, __spreadProps(__spreadValues({}, commonProps), { type: "email", onChange }));
3629
3710
  case "password":
3630
- return /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(TextInput, __spreadProps(__spreadValues({}, commonProps), { type: "password", onChange }));
3711
+ return /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(TextInput, __spreadProps(__spreadValues({}, commonProps), { type: "password", onChange }));
3631
3712
  case "numeric": {
3632
3713
  const numericProps = __spreadProps(__spreadValues({}, commonProps), { type: "number", onWheel });
3633
- return /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(
3714
+ return /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(
3634
3715
  TextInput,
3635
3716
  __spreadProps(__spreadValues({}, numericProps), {
3636
3717
  onChange: (newValue) => {
@@ -3641,21 +3722,21 @@ function VariableTextInput(inputProps) {
3641
3722
  );
3642
3723
  }
3643
3724
  case "phone-number":
3644
- return /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(import_components56.PhoneNumberInput, __spreadProps(__spreadValues({ initialValue: value }, commonProps), { onChange }));
3725
+ return /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(import_components57.PhoneNumberInput, __spreadProps(__spreadValues({ initialValue: value }, commonProps), { onChange }));
3645
3726
  default: {
3646
- return /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(TextInput, __spreadProps(__spreadValues({}, commonProps), { type: "text", onChange }));
3727
+ return /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(TextInput, __spreadProps(__spreadValues({}, commonProps), { type: "text", onChange }));
3647
3728
  }
3648
3729
  }
3649
3730
  }
3650
3731
  function TextInput(props) {
3651
3732
  const _a = props, { control, displayFormat, onChange } = _a, commonProps = __objRest(_a, ["control", "displayFormat", "onChange"]);
3652
- const InputWithPattern = control === "textarea" ? import_components56.TextareaWithDisplayFormat : import_components56.InputWithDisplayFormat;
3653
- const InputWithoutPattern = control === "textarea" ? import_components56.TextArea : import_components56.Input;
3654
- return displayFormat ? /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(InputWithPattern, __spreadProps(__spreadValues({ displayPattern: displayFormat }, commonProps), { onChange })) : /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(InputWithoutPattern, __spreadProps(__spreadValues({}, commonProps), { onChange: (e) => onChange(e.target.value) }));
3733
+ const InputWithPattern = control === "textarea" ? import_components57.TextareaWithDisplayFormat : import_components57.InputWithDisplayFormat;
3734
+ const InputWithoutPattern = control === "textarea" ? import_components57.TextArea : import_components57.Input;
3735
+ return displayFormat ? /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(InputWithPattern, __spreadProps(__spreadValues({ displayPattern: displayFormat }, commonProps), { onChange })) : /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(InputWithoutPattern, __spreadProps(__spreadValues({}, commonProps), { onChange: (e) => onChange(e.target.value) }));
3655
3736
  }
3656
3737
 
3657
3738
  // ../renderers/src/TextInputRenderer.tsx
3658
- var import_jsx_runtime81 = require("react/jsx-runtime");
3739
+ var import_jsx_runtime83 = require("react/jsx-runtime");
3659
3740
  var TextInputRenderer = {
3660
3741
  canRenderType: "input-text",
3661
3742
  render: (props) => {
@@ -3688,7 +3769,7 @@ var TextInputRenderer = {
3688
3769
  }
3689
3770
  }
3690
3771
  });
3691
- return /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(
3772
+ return /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(
3692
3773
  FieldInput_default,
3693
3774
  {
3694
3775
  id,
@@ -3696,7 +3777,7 @@ var TextInputRenderer = {
3696
3777
  description,
3697
3778
  validation: validationState,
3698
3779
  help,
3699
- children: /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(import_components57.InputGroup, { addonStart: getInputGroupAddonStart(media), children: /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(VariableTextInput, __spreadValues({}, inputProps)) })
3780
+ children: /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(import_components58.InputGroup, { addonStart: getInputGroupAddonStart(media), children: /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(VariableTextInput, __spreadValues({}, inputProps)) })
3700
3781
  }
3701
3782
  );
3702
3783
  }
@@ -3704,13 +3785,13 @@ var TextInputRenderer = {
3704
3785
  var TextInputRenderer_default = TextInputRenderer;
3705
3786
 
3706
3787
  // ../renderers/src/UploadInputRenderer.tsx
3707
- var import_components58 = require("@transferwise/components");
3788
+ var import_components59 = require("@transferwise/components");
3708
3789
 
3709
3790
  // ../renderers/src/utils/getRandomId.ts
3710
3791
  var getRandomId = () => Math.random().toString(36).substring(2);
3711
3792
 
3712
3793
  // ../renderers/src/UploadInputRenderer.tsx
3713
- var import_jsx_runtime82 = require("react/jsx-runtime");
3794
+ var import_jsx_runtime84 = require("react/jsx-runtime");
3714
3795
  var UploadInputRenderer = {
3715
3796
  canRenderType: "input-upload",
3716
3797
  render: (props) => {
@@ -3726,15 +3807,15 @@ var UploadInputRenderer = {
3726
3807
  };
3727
3808
  return (
3728
3809
  // We don't pass help here as there is no sensible place to display it
3729
- /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(
3810
+ /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(
3730
3811
  UploadFieldInput_default,
3731
3812
  {
3732
3813
  id,
3733
3814
  label: void 0,
3734
3815
  description: void 0,
3735
3816
  validation: validationState,
3736
- children: /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(
3737
- import_components58.UploadInput,
3817
+ children: /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(
3818
+ import_components59.UploadInput,
3738
3819
  {
3739
3820
  id,
3740
3821
  description,
@@ -3744,7 +3825,7 @@ var UploadInputRenderer = {
3744
3825
  {
3745
3826
  id: "my-file",
3746
3827
  filename: value.name,
3747
- status: (validationState == null ? void 0 : validationState.status) === "invalid" ? import_components58.Status.FAILED : import_components58.Status.SUCCEEDED
3828
+ status: (validationState == null ? void 0 : validationState.status) === "invalid" ? import_components59.Status.FAILED : import_components59.Status.SUCCEEDED
3748
3829
  }
3749
3830
  ] : void 0,
3750
3831
  fileTypes: acceptsToFileTypes(accepts),
@@ -3799,7 +3880,7 @@ var LargeUploadRenderer = {
3799
3880
  };
3800
3881
  const filetypes = acceptsToFileTypes(accepts);
3801
3882
  const usAccept = filetypes === "*" ? "*" : filetypes.join(",");
3802
- return /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(
3883
+ return /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(
3803
3884
  FieldInput_default,
3804
3885
  {
3805
3886
  id,
@@ -3807,8 +3888,8 @@ var LargeUploadRenderer = {
3807
3888
  description,
3808
3889
  validation: validationState,
3809
3890
  help,
3810
- children: /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(
3811
- import_components58.Upload,
3891
+ children: /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(
3892
+ import_components59.Upload,
3812
3893
  __spreadProps(__spreadValues({}, uploadProps), {
3813
3894
  usAccept,
3814
3895
  usDisabled: disabled,
@@ -3823,9 +3904,9 @@ var LargeUploadRenderer = {
3823
3904
  };
3824
3905
 
3825
3906
  // ../renderers/src/UpsellRenderer.tsx
3826
- var import_components59 = require("@transferwise/components");
3907
+ var import_components60 = require("@transferwise/components");
3827
3908
  var import_react19 = require("react");
3828
- var import_jsx_runtime83 = require("react/jsx-runtime");
3909
+ var import_jsx_runtime85 = require("react/jsx-runtime");
3829
3910
  var UpsellRenderer = {
3830
3911
  canRenderType: "upsell",
3831
3912
  render: UpsellRendererComponent
@@ -3833,8 +3914,8 @@ var UpsellRenderer = {
3833
3914
  function UpsellRendererComponent(props) {
3834
3915
  const { text, callToAction, media, margin, onDismiss } = props;
3835
3916
  const [isVisible, setIsVisible] = (0, import_react19.useState)(true);
3836
- return isVisible ? /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(
3837
- import_components59.Nudge,
3917
+ return isVisible ? /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(
3918
+ import_components60.Nudge,
3838
3919
  {
3839
3920
  className: getMargin(margin),
3840
3921
  mediaName: getMediaName(media),
@@ -3905,7 +3986,7 @@ var getWiseRenderers = () => [
3905
3986
  ModalRenderer,
3906
3987
  ModalLayoutRenderer_default,
3907
3988
  MoneyInputRenderer,
3908
- MultiSelectInputRenderer_default,
3989
+ MultiSelectInputRenderer,
3909
3990
  MultiUploadInputRenderer_default,
3910
3991
  NumberInputRenderer_default,
3911
3992
  ParagraphRenderer_default,
@@ -3928,7 +4009,7 @@ var getWiseRenderers = () => [
3928
4009
  ];
3929
4010
 
3930
4011
  // ../renderers/src/subflow/getSubflowRenderer.tsx
3931
- var import_jsx_runtime84 = require("react/jsx-runtime");
4012
+ var import_jsx_runtime86 = require("react/jsx-runtime");
3932
4013
  var getSubflowRenderer = ({
3933
4014
  Component: Component2,
3934
4015
  canRender
@@ -3937,7 +4018,7 @@ var getSubflowRenderer = ({
3937
4018
  canRenderType: "subflow",
3938
4019
  canRender,
3939
4020
  render: (props) => {
3940
- return /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(
4021
+ return /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(
3941
4022
  Component2,
3942
4023
  {
3943
4024
  presentation: props.presentation,
@@ -4016,25 +4097,25 @@ var handleRejection = (error) => {
4016
4097
 
4017
4098
  // src/dynamicFlow/DynamicFlowModal.tsx
4018
4099
  var import_dynamic_flow_client2 = require("@wise/dynamic-flow-client");
4019
- var import_components60 = require("@transferwise/components");
4020
- var import_jsx_runtime85 = require("react/jsx-runtime");
4100
+ var import_components61 = require("@transferwise/components");
4101
+ var import_jsx_runtime87 = require("react/jsx-runtime");
4021
4102
  function DynamicFlowModal(props) {
4022
4103
  const _a = props, { className = "" } = _a, rest = __objRest(_a, ["className"]);
4023
4104
  const dfProps = useWiseToCoreProps(rest);
4024
4105
  const df = (0, import_dynamic_flow_client2.useDynamicFlowModal)(dfProps);
4025
- return /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(
4026
- import_components60.Modal,
4106
+ return /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(
4107
+ import_components61.Modal,
4027
4108
  __spreadProps(__spreadValues({
4028
4109
  className: `dynamic-flow-modal ${className}`,
4029
4110
  disableDimmerClickToClose: true
4030
4111
  }, df.modal), {
4031
- body: /* @__PURE__ */ (0, import_jsx_runtime85.jsx)("div", { className: "dynamic-flow-modal", children: df.modal.body })
4112
+ body: /* @__PURE__ */ (0, import_jsx_runtime87.jsx)("div", { className: "dynamic-flow-modal", children: df.modal.body })
4032
4113
  })
4033
4114
  );
4034
4115
  }
4035
4116
 
4036
4117
  // src/dynamicFlow/getMergedRenderers.tsx
4037
- var import_jsx_runtime86 = require("react/jsx-runtime");
4118
+ var import_jsx_runtime88 = require("react/jsx-runtime");
4038
4119
  var wiseRenderers = getWiseRenderers();
4039
4120
  var getMergedRenderers = (props) => {
4040
4121
  var _d;
@@ -4048,7 +4129,7 @@ var getMergedRenderers = (props) => {
4048
4129
  method: initialRequest.method,
4049
4130
  data: initialRequest.body
4050
4131
  };
4051
- return presentation.type === "push" ? /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(DynamicFlow, __spreadProps(__spreadValues(__spreadValues({}, restProps), rest), { features: subflowFeatures, initialAction: action })) : /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(
4132
+ return presentation.type === "push" ? /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(DynamicFlow, __spreadProps(__spreadValues(__spreadValues({}, restProps), rest), { features: subflowFeatures, initialAction: action })) : /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(
4052
4133
  DynamicFlowModal,
4053
4134
  __spreadProps(__spreadValues(__spreadValues({}, restProps), rest), {
4054
4135
  features: subflowFeatures,
@@ -4098,18 +4179,18 @@ var openLinkInNewTab = (url) => {
4098
4179
  };
4099
4180
 
4100
4181
  // src/dynamicFlow/DynamicFlow.tsx
4101
- var import_jsx_runtime87 = require("react/jsx-runtime");
4182
+ var import_jsx_runtime89 = require("react/jsx-runtime");
4102
4183
  function DynamicFlow(props) {
4103
4184
  const { className = "" } = props;
4104
4185
  const dfProps = useWiseToCoreProps(props);
4105
4186
  const df = (0, import_dynamic_flow_client3.useDynamicFlow)(dfProps);
4106
- return /* @__PURE__ */ (0, import_jsx_runtime87.jsx)("div", { className, children: df.view });
4187
+ return /* @__PURE__ */ (0, import_jsx_runtime89.jsx)("div", { className, children: df.view });
4107
4188
  }
4108
4189
 
4109
4190
  // src/dynamicFlow/DynamicFlowWithRef.tsx
4110
4191
  var import_react23 = require("react");
4111
4192
  var import_dynamic_flow_client4 = require("@wise/dynamic-flow-client");
4112
- var import_jsx_runtime88 = require("react/jsx-runtime");
4193
+ var import_jsx_runtime90 = require("react/jsx-runtime");
4113
4194
  var DynamicFlowWithRef = (0, import_react23.forwardRef)(function DynamicFlowWithRef2(props, ref) {
4114
4195
  const { className = "" } = props;
4115
4196
  const dfProps = useWiseToCoreProps(props);
@@ -4125,7 +4206,7 @@ var DynamicFlowWithRef = (0, import_react23.forwardRef)(function DynamicFlowWith
4125
4206
  }),
4126
4207
  [df]
4127
4208
  );
4128
- return /* @__PURE__ */ (0, import_jsx_runtime88.jsx)("div", { className, children: df.view });
4209
+ return /* @__PURE__ */ (0, import_jsx_runtime90.jsx)("div", { className, children: df.view });
4129
4210
  });
4130
4211
 
4131
4212
  // src/index.ts