@wise/dynamic-flow-client-internal 5.23.0-experimental-2dcb025 → 5.23.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.
package/build/main.mjs CHANGED
@@ -127,7 +127,7 @@ import { useDynamicFlow } from "@wise/dynamic-flow-client";
127
127
  // src/dynamicFlow/telemetry/app-version.ts
128
128
  var appVersion = (
129
129
  // eslint-disable-next-line @typescript-eslint/no-unsafe-member-access
130
- typeof process !== "undefined" ? "5.22.0" : "0.0.0"
130
+ typeof process !== "undefined" ? "5.23.1" : "0.0.0"
131
131
  );
132
132
 
133
133
  // src/dynamicFlow/context-menu/useContextMenu.tsx
@@ -311,7 +311,7 @@ var recursivelyRemoveNullish = (element) => {
311
311
  };
312
312
 
313
313
  // src/dynamicFlow/useWiseToCoreProps.tsx
314
- import { useMemo as useMemo3 } from "react";
314
+ import { useMemo as useMemo2 } from "react";
315
315
 
316
316
  // src/dynamicFlow/getMergedRenderers.tsx
317
317
  import { getDynamicSubflowRenderer } from "@wise/dynamic-flow-client";
@@ -642,7 +642,7 @@ var AvatarMedia = ({
642
642
  }
643
643
  );
644
644
  }
645
- const avatarsWithoutBadges = avatars.filter(({ asset, icon }) => asset || icon).slice(0, 2).map(({ asset, icon, backgroundColor, color }) => ({
645
+ const avatarsWithoutBadges = avatars.filter(({ asset, icon }) => Boolean(asset || icon)).slice(0, 2).map(({ asset, icon, backgroundColor, color }) => ({
646
646
  asset: icon != null ? icon : asset,
647
647
  style: { backgroundColor, color }
648
648
  }));
@@ -723,22 +723,25 @@ var getImageNode = (image, size) => {
723
723
 
724
724
  // ../renderers/src/components/Media/LegacyMedia.tsx
725
725
  import { AvatarView as AvatarView3 } from "@transferwise/components";
726
- import { jsx as jsx12 } from "react/jsx-runtime";
726
+ import { Fragment, jsx as jsx12, jsxs as jsxs3 } from "react/jsx-runtime";
727
727
  var LegacyMedia = ({ image, icon, preferAvatar, size }) => {
728
728
  const imageNode = getImageNode(image, size);
729
729
  const iconNode = getIconNode(icon);
730
730
  const badge = getBadgedMedia(iconNode, imageNode, size);
731
731
  if (badge) {
732
- return badge;
732
+ return /* @__PURE__ */ jsx12(Fragment, { children: badge });
733
733
  }
734
734
  if (imageNode) {
735
- return preferAvatar ? /* @__PURE__ */ jsx12(AvatarView3, { children: imageNode }) : imageNode;
735
+ return preferAvatar ? /* @__PURE__ */ jsx12(AvatarView3, { children: imageNode }) : /* @__PURE__ */ jsxs3(Fragment, { children: [
736
+ imageNode,
737
+ " "
738
+ ] });
736
739
  }
737
740
  if (iconNode && icon) {
738
741
  if ("text" in icon || size === 48) {
739
742
  return /* @__PURE__ */ jsx12(AvatarView3, { size, children: iconNode });
740
743
  }
741
- return iconNode;
744
+ return /* @__PURE__ */ jsx12(Fragment, { children: iconNode });
742
745
  }
743
746
  return null;
744
747
  };
@@ -911,9 +914,9 @@ function Help({ help, onClick }) {
911
914
  var Help_default = Help;
912
915
 
913
916
  // ../renderers/src/components/LabelContentWithHelp.tsx
914
- import { jsx as jsx18, jsxs as jsxs3 } from "react/jsx-runtime";
917
+ import { jsx as jsx18, jsxs as jsxs4 } from "react/jsx-runtime";
915
918
  function LabelContentWithHelp({ text, help }) {
916
- return /* @__PURE__ */ jsxs3("div", { children: [
919
+ return /* @__PURE__ */ jsxs4("div", { children: [
917
920
  text,
918
921
  /* @__PURE__ */ jsx18(Help_default, { help })
919
922
  ] });
@@ -1101,1383 +1104,49 @@ var getInlineAlertOrValidation = (validationState, inlineAlert) => {
1101
1104
  };
1102
1105
  var CheckboxInputRenderer_default = CheckboxInputRenderer;
1103
1106
 
1104
- // ../renderers/src/CollectionRenderer/CollectionRenderer.tsx
1105
- import { InlinePrompt, Link as DSLink } from "@transferwise/components";
1106
-
1107
- // ../../node_modules/.pnpm/@tanstack+react-virtual@3.13.24_react-dom@19.2.7_react@19.2.7__react@19.2.7/node_modules/@tanstack/react-virtual/dist/esm/index.js
1108
- import * as React from "react";
1109
- import { flushSync } from "react-dom";
1110
-
1111
- // ../../node_modules/.pnpm/@tanstack+virtual-core@3.14.0/node_modules/@tanstack/virtual-core/dist/esm/utils.js
1112
- function memo(getDeps, fn, opts) {
1113
- var _a;
1114
- let deps = (_a = opts.initialDeps) != null ? _a : [];
1115
- let result;
1116
- let isInitial = true;
1117
- function memoizedFunction() {
1118
- var _a2, _b, _c;
1119
- let depTime;
1120
- if (opts.key && ((_a2 = opts.debug) == null ? void 0 : _a2.call(opts))) depTime = Date.now();
1121
- const newDeps = getDeps();
1122
- const depsChanged = newDeps.length !== deps.length || newDeps.some((dep, index) => deps[index] !== dep);
1123
- if (!depsChanged) {
1124
- return result;
1125
- }
1126
- deps = newDeps;
1127
- let resultTime;
1128
- if (opts.key && ((_b = opts.debug) == null ? void 0 : _b.call(opts))) resultTime = Date.now();
1129
- result = fn(...newDeps);
1130
- if (opts.key && ((_c = opts.debug) == null ? void 0 : _c.call(opts))) {
1131
- const depEndTime = Math.round((Date.now() - depTime) * 100) / 100;
1132
- const resultEndTime = Math.round((Date.now() - resultTime) * 100) / 100;
1133
- const resultFpsPercentage = resultEndTime / 16;
1134
- const pad = (str, num) => {
1135
- str = String(str);
1136
- while (str.length < num) {
1137
- str = " " + str;
1138
- }
1139
- return str;
1140
- };
1141
- console.info(
1142
- `%c\u23F1 ${pad(resultEndTime, 5)} /${pad(depEndTime, 5)} ms`,
1143
- `
1144
- font-size: .6rem;
1145
- font-weight: bold;
1146
- color: hsl(${Math.max(
1147
- 0,
1148
- Math.min(120 - 120 * resultFpsPercentage, 120)
1149
- )}deg 100% 31%);`,
1150
- opts == null ? void 0 : opts.key
1151
- );
1152
- }
1153
- if ((opts == null ? void 0 : opts.onChange) && !(isInitial && opts.skipInitialOnChange)) {
1154
- opts.onChange(result);
1155
- }
1156
- isInitial = false;
1157
- return result;
1158
- }
1159
- memoizedFunction.updateDeps = (newDeps) => {
1160
- deps = newDeps;
1161
- };
1162
- return memoizedFunction;
1163
- }
1164
- function notUndefined(value, msg) {
1165
- if (value === void 0) {
1166
- throw new Error(`Unexpected undefined${msg ? `: ${msg}` : ""}`);
1167
- } else {
1168
- return value;
1169
- }
1170
- }
1171
- var approxEqual = (a, b) => Math.abs(a - b) < 1.01;
1172
- var debounce = (targetWindow, fn, ms) => {
1173
- let timeoutId;
1174
- return function(...args) {
1175
- targetWindow.clearTimeout(timeoutId);
1176
- timeoutId = targetWindow.setTimeout(() => fn.apply(this, args), ms);
1177
- };
1178
- };
1179
-
1180
- // ../../node_modules/.pnpm/@tanstack+virtual-core@3.14.0/node_modules/@tanstack/virtual-core/dist/esm/index.js
1181
- var defaultKeyExtractor = (index) => index;
1182
- var defaultRangeExtractor = (range) => {
1183
- const start = Math.max(range.startIndex - range.overscan, 0);
1184
- const end = Math.min(range.endIndex + range.overscan, range.count - 1);
1185
- const arr = [];
1186
- for (let i = start; i <= end; i++) {
1187
- arr.push(i);
1188
- }
1189
- return arr;
1190
- };
1191
- var addEventListenerOptions = {
1192
- passive: true
1193
- };
1194
- var observeWindowRect = (instance, cb) => {
1195
- const element = instance.scrollElement;
1196
- if (!element) {
1197
- return;
1198
- }
1199
- const handler = () => {
1200
- cb({ width: element.innerWidth, height: element.innerHeight });
1201
- };
1202
- handler();
1203
- element.addEventListener("resize", handler, addEventListenerOptions);
1204
- return () => {
1205
- element.removeEventListener("resize", handler);
1206
- };
1207
- };
1208
- var supportsScrollend = typeof window == "undefined" ? true : "onscrollend" in window;
1209
- var observeWindowOffset = (instance, cb) => {
1210
- const element = instance.scrollElement;
1211
- if (!element) {
1212
- return;
1213
- }
1214
- const targetWindow = instance.targetWindow;
1215
- if (!targetWindow) {
1216
- return;
1217
- }
1218
- let offset = 0;
1219
- const fallback = instance.options.useScrollendEvent && supportsScrollend ? () => void 0 : debounce(
1220
- targetWindow,
1221
- () => {
1222
- cb(offset, false);
1223
- },
1224
- instance.options.isScrollingResetDelay
1225
- );
1226
- const createHandler = (isScrolling) => () => {
1227
- offset = element[instance.options.horizontal ? "scrollX" : "scrollY"];
1228
- fallback();
1229
- cb(offset, isScrolling);
1230
- };
1231
- const handler = createHandler(true);
1232
- const endHandler = createHandler(false);
1233
- element.addEventListener("scroll", handler, addEventListenerOptions);
1234
- const registerScrollendEvent = instance.options.useScrollendEvent && supportsScrollend;
1235
- if (registerScrollendEvent) {
1236
- element.addEventListener("scrollend", endHandler, addEventListenerOptions);
1237
- }
1238
- return () => {
1239
- element.removeEventListener("scroll", handler);
1240
- if (registerScrollendEvent) {
1241
- element.removeEventListener("scrollend", endHandler);
1242
- }
1243
- };
1244
- };
1245
- var measureElement = (element, entry, instance) => {
1246
- if (entry == null ? void 0 : entry.borderBoxSize) {
1247
- const box = entry.borderBoxSize[0];
1248
- if (box) {
1249
- const size = Math.round(
1250
- box[instance.options.horizontal ? "inlineSize" : "blockSize"]
1251
- );
1252
- return size;
1253
- }
1254
- }
1255
- return element[instance.options.horizontal ? "offsetWidth" : "offsetHeight"];
1256
- };
1257
- var windowScroll = (offset, {
1258
- adjustments = 0,
1259
- behavior
1260
- }, instance) => {
1261
- var _a, _b;
1262
- const toOffset = offset + adjustments;
1263
- (_b = (_a = instance.scrollElement) == null ? void 0 : _a.scrollTo) == null ? void 0 : _b.call(_a, {
1264
- [instance.options.horizontal ? "left" : "top"]: toOffset,
1265
- behavior
1266
- });
1267
- };
1268
- var Virtualizer = class {
1269
- constructor(opts) {
1270
- this.unsubs = [];
1271
- this.scrollElement = null;
1272
- this.targetWindow = null;
1273
- this.isScrolling = false;
1274
- this.scrollState = null;
1275
- this.measurementsCache = [];
1276
- this.itemSizeCache = /* @__PURE__ */ new Map();
1277
- this.laneAssignments = /* @__PURE__ */ new Map();
1278
- this.pendingMeasuredCacheIndexes = [];
1279
- this.prevLanes = void 0;
1280
- this.lanesChangedFlag = false;
1281
- this.lanesSettling = false;
1282
- this.scrollRect = null;
1283
- this.scrollOffset = null;
1284
- this.scrollDirection = null;
1285
- this.scrollAdjustments = 0;
1286
- this.elementsCache = /* @__PURE__ */ new Map();
1287
- this.now = () => {
1288
- var _a2;
1289
- var _a, _b, _c;
1290
- return (_a2 = (_c = (_b = (_a = this.targetWindow) == null ? void 0 : _a.performance) == null ? void 0 : _b.now) == null ? void 0 : _c.call(_b)) != null ? _a2 : Date.now();
1291
- };
1292
- this.observer = /* @__PURE__ */ (() => {
1293
- let _ro = null;
1294
- const get = () => {
1295
- if (_ro) {
1296
- return _ro;
1297
- }
1298
- if (!this.targetWindow || !this.targetWindow.ResizeObserver) {
1299
- return null;
1300
- }
1301
- return _ro = new this.targetWindow.ResizeObserver((entries) => {
1302
- entries.forEach((entry) => {
1303
- const run = () => {
1304
- const node = entry.target;
1305
- const index = this.indexFromElement(node);
1306
- if (!node.isConnected) {
1307
- this.observer.unobserve(node);
1308
- return;
1309
- }
1310
- if (this.shouldMeasureDuringScroll(index)) {
1311
- this.resizeItem(
1312
- index,
1313
- this.options.measureElement(node, entry, this)
1314
- );
1315
- }
1316
- };
1317
- this.options.useAnimationFrameWithResizeObserver ? requestAnimationFrame(run) : run();
1318
- });
1319
- });
1320
- };
1321
- return {
1322
- disconnect: () => {
1323
- var _a;
1324
- (_a = get()) == null ? void 0 : _a.disconnect();
1325
- _ro = null;
1326
- },
1327
- observe: (target) => {
1328
- var _a;
1329
- return (_a = get()) == null ? void 0 : _a.observe(target, { box: "border-box" });
1330
- },
1331
- unobserve: (target) => {
1332
- var _a;
1333
- return (_a = get()) == null ? void 0 : _a.unobserve(target);
1334
- }
1335
- };
1336
- })();
1337
- this.range = null;
1338
- this.setOptions = (opts2) => {
1339
- Object.entries(opts2).forEach(([key, value]) => {
1340
- if (typeof value === "undefined") delete opts2[key];
1341
- });
1342
- this.options = __spreadValues({
1343
- debug: false,
1344
- initialOffset: 0,
1345
- overscan: 1,
1346
- paddingStart: 0,
1347
- paddingEnd: 0,
1348
- scrollPaddingStart: 0,
1349
- scrollPaddingEnd: 0,
1350
- horizontal: false,
1351
- getItemKey: defaultKeyExtractor,
1352
- rangeExtractor: defaultRangeExtractor,
1353
- onChange: () => {
1354
- },
1355
- measureElement,
1356
- initialRect: { width: 0, height: 0 },
1357
- scrollMargin: 0,
1358
- gap: 0,
1359
- indexAttribute: "data-index",
1360
- initialMeasurementsCache: [],
1361
- lanes: 1,
1362
- isScrollingResetDelay: 150,
1363
- enabled: true,
1364
- isRtl: false,
1365
- useScrollendEvent: false,
1366
- useAnimationFrameWithResizeObserver: false,
1367
- laneAssignmentMode: "estimate"
1368
- }, opts2);
1369
- };
1370
- this.notify = (sync) => {
1371
- var _a, _b;
1372
- (_b = (_a = this.options).onChange) == null ? void 0 : _b.call(_a, this, sync);
1373
- };
1374
- this.maybeNotify = memo(
1375
- () => {
1376
- this.calculateRange();
1377
- return [
1378
- this.isScrolling,
1379
- this.range ? this.range.startIndex : null,
1380
- this.range ? this.range.endIndex : null
1381
- ];
1382
- },
1383
- (isScrolling) => {
1384
- this.notify(isScrolling);
1385
- },
1386
- {
1387
- key: "maybeNotify",
1388
- debug: () => this.options.debug,
1389
- initialDeps: [
1390
- this.isScrolling,
1391
- this.range ? this.range.startIndex : null,
1392
- this.range ? this.range.endIndex : null
1393
- ]
1394
- }
1395
- );
1396
- this.cleanup = () => {
1397
- this.unsubs.filter(Boolean).forEach((d) => d());
1398
- this.unsubs = [];
1399
- this.observer.disconnect();
1400
- if (this.rafId != null && this.targetWindow) {
1401
- this.targetWindow.cancelAnimationFrame(this.rafId);
1402
- this.rafId = null;
1403
- }
1404
- this.scrollState = null;
1405
- this.scrollElement = null;
1406
- this.targetWindow = null;
1407
- };
1408
- this._didMount = () => {
1409
- return () => {
1410
- this.cleanup();
1411
- };
1412
- };
1413
- this._willUpdate = () => {
1414
- var _a2;
1415
- var _a;
1416
- const scrollElement = this.options.enabled ? this.options.getScrollElement() : null;
1417
- if (this.scrollElement !== scrollElement) {
1418
- this.cleanup();
1419
- if (!scrollElement) {
1420
- this.maybeNotify();
1421
- return;
1422
- }
1423
- this.scrollElement = scrollElement;
1424
- if (this.scrollElement && "ownerDocument" in this.scrollElement) {
1425
- this.targetWindow = this.scrollElement.ownerDocument.defaultView;
1426
- } else {
1427
- this.targetWindow = (_a2 = (_a = this.scrollElement) == null ? void 0 : _a.window) != null ? _a2 : null;
1428
- }
1429
- this.elementsCache.forEach((cached) => {
1430
- this.observer.observe(cached);
1431
- });
1432
- this.unsubs.push(
1433
- this.options.observeElementRect(this, (rect) => {
1434
- this.scrollRect = rect;
1435
- this.maybeNotify();
1436
- })
1437
- );
1438
- this.unsubs.push(
1439
- this.options.observeElementOffset(this, (offset, isScrolling) => {
1440
- this.scrollAdjustments = 0;
1441
- this.scrollDirection = isScrolling ? this.getScrollOffset() < offset ? "forward" : "backward" : null;
1442
- this.scrollOffset = offset;
1443
- this.isScrolling = isScrolling;
1444
- if (this.scrollState) {
1445
- this.scheduleScrollReconcile();
1446
- }
1447
- this.maybeNotify();
1448
- })
1449
- );
1450
- this._scrollToOffset(this.getScrollOffset(), {
1451
- adjustments: void 0,
1452
- behavior: void 0
1453
- });
1454
- }
1455
- };
1456
- this.rafId = null;
1457
- this.getSize = () => {
1458
- var _a;
1459
- if (!this.options.enabled) {
1460
- this.scrollRect = null;
1461
- return 0;
1462
- }
1463
- this.scrollRect = (_a = this.scrollRect) != null ? _a : this.options.initialRect;
1464
- return this.scrollRect[this.options.horizontal ? "width" : "height"];
1465
- };
1466
- this.getScrollOffset = () => {
1467
- var _a;
1468
- if (!this.options.enabled) {
1469
- this.scrollOffset = null;
1470
- return 0;
1471
- }
1472
- this.scrollOffset = (_a = this.scrollOffset) != null ? _a : typeof this.options.initialOffset === "function" ? this.options.initialOffset() : this.options.initialOffset;
1473
- return this.scrollOffset;
1474
- };
1475
- this.getFurthestMeasurement = (measurements, index) => {
1476
- const furthestMeasurementsFound = /* @__PURE__ */ new Map();
1477
- const furthestMeasurements = /* @__PURE__ */ new Map();
1478
- for (let m = index - 1; m >= 0; m--) {
1479
- const measurement = measurements[m];
1480
- if (furthestMeasurementsFound.has(measurement.lane)) {
1481
- continue;
1482
- }
1483
- const previousFurthestMeasurement = furthestMeasurements.get(
1484
- measurement.lane
1485
- );
1486
- if (previousFurthestMeasurement == null || measurement.end > previousFurthestMeasurement.end) {
1487
- furthestMeasurements.set(measurement.lane, measurement);
1488
- } else if (measurement.end < previousFurthestMeasurement.end) {
1489
- furthestMeasurementsFound.set(measurement.lane, true);
1490
- }
1491
- if (furthestMeasurementsFound.size === this.options.lanes) {
1492
- break;
1493
- }
1494
- }
1495
- return furthestMeasurements.size === this.options.lanes ? Array.from(furthestMeasurements.values()).sort((a, b) => {
1496
- if (a.end === b.end) {
1497
- return a.index - b.index;
1498
- }
1499
- return a.end - b.end;
1500
- })[0] : void 0;
1501
- };
1502
- this.getMeasurementOptions = memo(
1503
- () => [
1504
- this.options.count,
1505
- this.options.paddingStart,
1506
- this.options.scrollMargin,
1507
- this.options.getItemKey,
1508
- this.options.enabled,
1509
- this.options.lanes,
1510
- this.options.laneAssignmentMode
1511
- ],
1512
- (count, paddingStart, scrollMargin, getItemKey, enabled, lanes, laneAssignmentMode) => {
1513
- const lanesChanged = this.prevLanes !== void 0 && this.prevLanes !== lanes;
1514
- if (lanesChanged) {
1515
- this.lanesChangedFlag = true;
1516
- }
1517
- this.prevLanes = lanes;
1518
- this.pendingMeasuredCacheIndexes = [];
1519
- return {
1520
- count,
1521
- paddingStart,
1522
- scrollMargin,
1523
- getItemKey,
1524
- enabled,
1525
- lanes,
1526
- laneAssignmentMode
1527
- };
1528
- },
1529
- {
1530
- key: false
1531
- }
1532
- );
1533
- this.getMeasurements = memo(
1534
- () => [this.getMeasurementOptions(), this.itemSizeCache],
1535
- ({
1536
- count,
1537
- paddingStart,
1538
- scrollMargin,
1539
- getItemKey,
1540
- enabled,
1541
- lanes,
1542
- laneAssignmentMode
1543
- }, itemSizeCache) => {
1544
- if (!enabled) {
1545
- this.measurementsCache = [];
1546
- this.itemSizeCache.clear();
1547
- this.laneAssignments.clear();
1548
- return [];
1549
- }
1550
- if (this.laneAssignments.size > count) {
1551
- for (const index of this.laneAssignments.keys()) {
1552
- if (index >= count) {
1553
- this.laneAssignments.delete(index);
1554
- }
1555
- }
1556
- }
1557
- if (this.lanesChangedFlag) {
1558
- this.lanesChangedFlag = false;
1559
- this.lanesSettling = true;
1560
- this.measurementsCache = [];
1561
- this.itemSizeCache.clear();
1562
- this.laneAssignments.clear();
1563
- this.pendingMeasuredCacheIndexes = [];
1564
- }
1565
- if (this.measurementsCache.length === 0 && !this.lanesSettling) {
1566
- this.measurementsCache = this.options.initialMeasurementsCache;
1567
- this.measurementsCache.forEach((item) => {
1568
- this.itemSizeCache.set(item.key, item.size);
1569
- });
1570
- }
1571
- const min = this.lanesSettling ? 0 : this.pendingMeasuredCacheIndexes.length > 0 ? Math.min(...this.pendingMeasuredCacheIndexes) : 0;
1572
- this.pendingMeasuredCacheIndexes = [];
1573
- if (this.lanesSettling && this.measurementsCache.length === count) {
1574
- this.lanesSettling = false;
1575
- }
1576
- const measurements = this.measurementsCache.slice(0, min);
1577
- const laneLastIndex = new Array(lanes).fill(
1578
- void 0
1579
- );
1580
- for (let m = 0; m < min; m++) {
1581
- const item = measurements[m];
1582
- if (item) {
1583
- laneLastIndex[item.lane] = m;
1584
- }
1585
- }
1586
- for (let i = min; i < count; i++) {
1587
- const key = getItemKey(i);
1588
- const cachedLane = this.laneAssignments.get(i);
1589
- let lane;
1590
- let start;
1591
- const shouldCacheLane = laneAssignmentMode === "estimate" || itemSizeCache.has(key);
1592
- if (cachedLane !== void 0 && this.options.lanes > 1) {
1593
- lane = cachedLane;
1594
- const prevIndex = laneLastIndex[lane];
1595
- const prevInLane = prevIndex !== void 0 ? measurements[prevIndex] : void 0;
1596
- start = prevInLane ? prevInLane.end + this.options.gap : paddingStart + scrollMargin;
1597
- } else {
1598
- const furthestMeasurement = this.options.lanes === 1 ? measurements[i - 1] : this.getFurthestMeasurement(measurements, i);
1599
- start = furthestMeasurement ? furthestMeasurement.end + this.options.gap : paddingStart + scrollMargin;
1600
- lane = furthestMeasurement ? furthestMeasurement.lane : i % this.options.lanes;
1601
- if (this.options.lanes > 1 && shouldCacheLane) {
1602
- this.laneAssignments.set(i, lane);
1603
- }
1604
- }
1605
- const measuredSize = itemSizeCache.get(key);
1606
- const size = typeof measuredSize === "number" ? measuredSize : this.options.estimateSize(i);
1607
- const end = start + size;
1608
- measurements[i] = {
1609
- index: i,
1610
- start,
1611
- size,
1612
- end,
1613
- key,
1614
- lane
1615
- };
1616
- laneLastIndex[lane] = i;
1617
- }
1618
- this.measurementsCache = measurements;
1619
- return measurements;
1620
- },
1621
- {
1622
- key: "getMeasurements",
1623
- debug: () => this.options.debug
1624
- }
1625
- );
1626
- this.calculateRange = memo(
1627
- () => [
1628
- this.getMeasurements(),
1629
- this.getSize(),
1630
- this.getScrollOffset(),
1631
- this.options.lanes
1632
- ],
1633
- (measurements, outerSize, scrollOffset, lanes) => {
1634
- return this.range = measurements.length > 0 && outerSize > 0 ? calculateRange({
1635
- measurements,
1636
- outerSize,
1637
- scrollOffset,
1638
- lanes
1639
- }) : null;
1640
- },
1641
- {
1642
- key: "calculateRange",
1643
- debug: () => this.options.debug
1644
- }
1645
- );
1646
- this.getVirtualIndexes = memo(
1647
- () => {
1648
- let startIndex = null;
1649
- let endIndex = null;
1650
- const range = this.calculateRange();
1651
- if (range) {
1652
- startIndex = range.startIndex;
1653
- endIndex = range.endIndex;
1654
- }
1655
- this.maybeNotify.updateDeps([this.isScrolling, startIndex, endIndex]);
1656
- return [
1657
- this.options.rangeExtractor,
1658
- this.options.overscan,
1659
- this.options.count,
1660
- startIndex,
1661
- endIndex
1662
- ];
1663
- },
1664
- (rangeExtractor, overscan, count, startIndex, endIndex) => {
1665
- return startIndex === null || endIndex === null ? [] : rangeExtractor({
1666
- startIndex,
1667
- endIndex,
1668
- overscan,
1669
- count
1670
- });
1671
- },
1672
- {
1673
- key: "getVirtualIndexes",
1674
- debug: () => this.options.debug
1675
- }
1676
- );
1677
- this.indexFromElement = (node) => {
1678
- const attributeName = this.options.indexAttribute;
1679
- const indexStr = node.getAttribute(attributeName);
1680
- if (!indexStr) {
1681
- console.warn(
1682
- `Missing attribute name '${attributeName}={index}' on measured element.`
1683
- );
1684
- return -1;
1685
- }
1686
- return parseInt(indexStr, 10);
1687
- };
1688
- this.shouldMeasureDuringScroll = (index) => {
1689
- var _a2;
1690
- var _a;
1691
- if (!this.scrollState || this.scrollState.behavior !== "smooth") {
1692
- return true;
1693
- }
1694
- const scrollIndex = (_a2 = this.scrollState.index) != null ? _a2 : (_a = this.getVirtualItemForOffset(this.scrollState.lastTargetOffset)) == null ? void 0 : _a.index;
1695
- if (scrollIndex !== void 0 && this.range) {
1696
- const bufferSize = Math.max(
1697
- this.options.overscan,
1698
- Math.ceil((this.range.endIndex - this.range.startIndex) / 2)
1699
- );
1700
- const minIndex = Math.max(0, scrollIndex - bufferSize);
1701
- const maxIndex = Math.min(
1702
- this.options.count - 1,
1703
- scrollIndex + bufferSize
1704
- );
1705
- return index >= minIndex && index <= maxIndex;
1706
- }
1707
- return true;
1708
- };
1709
- this.measureElement = (node) => {
1710
- if (!node) {
1711
- this.elementsCache.forEach((cached, key2) => {
1712
- if (!cached.isConnected) {
1713
- this.observer.unobserve(cached);
1714
- this.elementsCache.delete(key2);
1715
- }
1716
- });
1717
- return;
1718
- }
1719
- const index = this.indexFromElement(node);
1720
- const key = this.options.getItemKey(index);
1721
- const prevNode = this.elementsCache.get(key);
1722
- if (prevNode !== node) {
1723
- if (prevNode) {
1724
- this.observer.unobserve(prevNode);
1725
- }
1726
- this.observer.observe(node);
1727
- this.elementsCache.set(key, node);
1728
- }
1729
- if ((!this.isScrolling || this.scrollState) && this.shouldMeasureDuringScroll(index)) {
1730
- this.resizeItem(index, this.options.measureElement(node, void 0, this));
1731
- }
1732
- };
1733
- this.resizeItem = (index, size) => {
1734
- var _a2;
1735
- var _a;
1736
- const item = this.measurementsCache[index];
1737
- if (!item) return;
1738
- const itemSize = (_a2 = this.itemSizeCache.get(item.key)) != null ? _a2 : item.size;
1739
- const delta = size - itemSize;
1740
- if (delta !== 0) {
1741
- if (((_a = this.scrollState) == null ? void 0 : _a.behavior) !== "smooth" && (this.shouldAdjustScrollPositionOnItemSizeChange !== void 0 ? this.shouldAdjustScrollPositionOnItemSizeChange(item, delta, this) : item.start < this.getScrollOffset() + this.scrollAdjustments)) {
1742
- if (this.options.debug) {
1743
- console.info("correction", delta);
1744
- }
1745
- this._scrollToOffset(this.getScrollOffset(), {
1746
- adjustments: this.scrollAdjustments += delta,
1747
- behavior: void 0
1748
- });
1749
- }
1750
- this.pendingMeasuredCacheIndexes.push(item.index);
1751
- this.itemSizeCache = new Map(this.itemSizeCache.set(item.key, size));
1752
- this.notify(false);
1753
- }
1754
- };
1755
- this.getVirtualItems = memo(
1756
- () => [this.getVirtualIndexes(), this.getMeasurements()],
1757
- (indexes, measurements) => {
1758
- const virtualItems = [];
1759
- for (let k = 0, len = indexes.length; k < len; k++) {
1760
- const i = indexes[k];
1761
- const measurement = measurements[i];
1762
- virtualItems.push(measurement);
1763
- }
1764
- return virtualItems;
1765
- },
1766
- {
1767
- key: "getVirtualItems",
1768
- debug: () => this.options.debug
1769
- }
1770
- );
1771
- this.getVirtualItemForOffset = (offset) => {
1772
- const measurements = this.getMeasurements();
1773
- if (measurements.length === 0) {
1774
- return void 0;
1775
- }
1776
- return notUndefined(
1777
- measurements[findNearestBinarySearch(
1778
- 0,
1779
- measurements.length - 1,
1780
- (index) => notUndefined(measurements[index]).start,
1781
- offset
1782
- )]
1783
- );
1784
- };
1785
- this.getMaxScrollOffset = () => {
1786
- if (!this.scrollElement) return 0;
1787
- if ("scrollHeight" in this.scrollElement) {
1788
- return this.options.horizontal ? this.scrollElement.scrollWidth - this.scrollElement.clientWidth : this.scrollElement.scrollHeight - this.scrollElement.clientHeight;
1789
- } else {
1790
- const doc = this.scrollElement.document.documentElement;
1791
- return this.options.horizontal ? doc.scrollWidth - this.scrollElement.innerWidth : doc.scrollHeight - this.scrollElement.innerHeight;
1792
- }
1793
- };
1794
- this.getOffsetForAlignment = (toOffset, align, itemSize = 0) => {
1795
- if (!this.scrollElement) return 0;
1796
- const size = this.getSize();
1797
- const scrollOffset = this.getScrollOffset();
1798
- if (align === "auto") {
1799
- align = toOffset >= scrollOffset + size ? "end" : "start";
1800
- }
1801
- if (align === "center") {
1802
- toOffset += (itemSize - size) / 2;
1803
- } else if (align === "end") {
1804
- toOffset -= size;
1805
- }
1806
- const maxOffset = this.getMaxScrollOffset();
1807
- return Math.max(Math.min(maxOffset, toOffset), 0);
1808
- };
1809
- this.getOffsetForIndex = (index, align = "auto") => {
1810
- index = Math.max(0, Math.min(index, this.options.count - 1));
1811
- const size = this.getSize();
1812
- const scrollOffset = this.getScrollOffset();
1813
- const item = this.measurementsCache[index];
1814
- if (!item) return;
1815
- if (align === "auto") {
1816
- if (item.end >= scrollOffset + size - this.options.scrollPaddingEnd) {
1817
- align = "end";
1818
- } else if (item.start <= scrollOffset + this.options.scrollPaddingStart) {
1819
- align = "start";
1820
- } else {
1821
- return [scrollOffset, align];
1822
- }
1823
- }
1824
- if (align === "end" && index === this.options.count - 1) {
1825
- return [this.getMaxScrollOffset(), align];
1826
- }
1827
- const toOffset = align === "end" ? item.end + this.options.scrollPaddingEnd : item.start - this.options.scrollPaddingStart;
1828
- return [
1829
- this.getOffsetForAlignment(toOffset, align, item.size),
1830
- align
1831
- ];
1832
- };
1833
- this.scrollToOffset = (toOffset, { align = "start", behavior = "auto" } = {}) => {
1834
- const offset = this.getOffsetForAlignment(toOffset, align);
1835
- const now = this.now();
1836
- this.scrollState = {
1837
- index: null,
1838
- align,
1839
- behavior,
1840
- startedAt: now,
1841
- lastTargetOffset: offset,
1842
- stableFrames: 0
1843
- };
1844
- this._scrollToOffset(offset, { adjustments: void 0, behavior });
1845
- this.scheduleScrollReconcile();
1846
- };
1847
- this.scrollToIndex = (index, {
1848
- align: initialAlign = "auto",
1849
- behavior = "auto"
1850
- } = {}) => {
1851
- index = Math.max(0, Math.min(index, this.options.count - 1));
1852
- const offsetInfo = this.getOffsetForIndex(index, initialAlign);
1853
- if (!offsetInfo) {
1854
- return;
1855
- }
1856
- const [offset, align] = offsetInfo;
1857
- const now = this.now();
1858
- this.scrollState = {
1859
- index,
1860
- align,
1861
- behavior,
1862
- startedAt: now,
1863
- lastTargetOffset: offset,
1864
- stableFrames: 0
1865
- };
1866
- this._scrollToOffset(offset, { adjustments: void 0, behavior });
1867
- this.scheduleScrollReconcile();
1868
- };
1869
- this.scrollBy = (delta, { behavior = "auto" } = {}) => {
1870
- const offset = this.getScrollOffset() + delta;
1871
- const now = this.now();
1872
- this.scrollState = {
1873
- index: null,
1874
- align: "start",
1875
- behavior,
1876
- startedAt: now,
1877
- lastTargetOffset: offset,
1878
- stableFrames: 0
1879
- };
1880
- this._scrollToOffset(offset, { adjustments: void 0, behavior });
1881
- this.scheduleScrollReconcile();
1882
- };
1883
- this.getTotalSize = () => {
1884
- var _a2;
1885
- var _a;
1886
- const measurements = this.getMeasurements();
1887
- let end;
1888
- if (measurements.length === 0) {
1889
- end = this.options.paddingStart;
1890
- } else if (this.options.lanes === 1) {
1891
- end = (_a2 = (_a = measurements[measurements.length - 1]) == null ? void 0 : _a.end) != null ? _a2 : 0;
1892
- } else {
1893
- const endByLane = Array(this.options.lanes).fill(null);
1894
- let endIndex = measurements.length - 1;
1895
- while (endIndex >= 0 && endByLane.some((val) => val === null)) {
1896
- const item = measurements[endIndex];
1897
- if (endByLane[item.lane] === null) {
1898
- endByLane[item.lane] = item.end;
1899
- }
1900
- endIndex--;
1901
- }
1902
- end = Math.max(...endByLane.filter((val) => val !== null));
1903
- }
1904
- return Math.max(
1905
- end - this.options.scrollMargin + this.options.paddingEnd,
1906
- 0
1907
- );
1908
- };
1909
- this._scrollToOffset = (offset, {
1910
- adjustments,
1911
- behavior
1912
- }) => {
1913
- this.options.scrollToFn(offset, { behavior, adjustments }, this);
1914
- };
1915
- this.measure = () => {
1916
- this.itemSizeCache = /* @__PURE__ */ new Map();
1917
- this.laneAssignments = /* @__PURE__ */ new Map();
1918
- this.notify(false);
1919
- };
1920
- this.setOptions(opts);
1921
- }
1922
- scheduleScrollReconcile() {
1923
- if (!this.targetWindow) {
1924
- this.scrollState = null;
1925
- return;
1926
- }
1927
- if (this.rafId != null) return;
1928
- this.rafId = this.targetWindow.requestAnimationFrame(() => {
1929
- this.rafId = null;
1930
- this.reconcileScroll();
1931
- });
1932
- }
1933
- reconcileScroll() {
1934
- if (!this.scrollState) return;
1935
- const el = this.scrollElement;
1936
- if (!el) return;
1937
- const MAX_RECONCILE_MS = 5e3;
1938
- if (this.now() - this.scrollState.startedAt > MAX_RECONCILE_MS) {
1939
- this.scrollState = null;
1940
- return;
1941
- }
1942
- const offsetInfo = this.scrollState.index != null ? this.getOffsetForIndex(this.scrollState.index, this.scrollState.align) : void 0;
1943
- const targetOffset = offsetInfo ? offsetInfo[0] : this.scrollState.lastTargetOffset;
1944
- const STABLE_FRAMES = 1;
1945
- const targetChanged = targetOffset !== this.scrollState.lastTargetOffset;
1946
- if (!targetChanged && approxEqual(targetOffset, this.getScrollOffset())) {
1947
- this.scrollState.stableFrames++;
1948
- if (this.scrollState.stableFrames >= STABLE_FRAMES) {
1949
- this.scrollState = null;
1950
- return;
1951
- }
1952
- } else {
1953
- this.scrollState.stableFrames = 0;
1954
- if (targetChanged) {
1955
- this.scrollState.lastTargetOffset = targetOffset;
1956
- this.scrollState.behavior = "auto";
1957
- this._scrollToOffset(targetOffset, {
1958
- adjustments: void 0,
1959
- behavior: "auto"
1960
- });
1961
- }
1962
- }
1963
- this.scheduleScrollReconcile();
1964
- }
1965
- };
1966
- var findNearestBinarySearch = (low, high, getCurrentValue, value) => {
1967
- while (low <= high) {
1968
- const middle = (low + high) / 2 | 0;
1969
- const currentValue = getCurrentValue(middle);
1970
- if (currentValue < value) {
1971
- low = middle + 1;
1972
- } else if (currentValue > value) {
1973
- high = middle - 1;
1974
- } else {
1975
- return middle;
1976
- }
1977
- }
1978
- if (low > 0) {
1979
- return low - 1;
1980
- } else {
1981
- return 0;
1982
- }
1983
- };
1984
- function calculateRange({
1985
- measurements,
1986
- outerSize,
1987
- scrollOffset,
1988
- lanes
1989
- }) {
1990
- const lastIndex = measurements.length - 1;
1991
- const getOffset = (index) => measurements[index].start;
1992
- if (measurements.length <= lanes) {
1993
- return {
1994
- startIndex: 0,
1995
- endIndex: lastIndex
1996
- };
1997
- }
1998
- let startIndex = findNearestBinarySearch(
1999
- 0,
2000
- lastIndex,
2001
- getOffset,
2002
- scrollOffset
2003
- );
2004
- let endIndex = startIndex;
2005
- if (lanes === 1) {
2006
- while (endIndex < lastIndex && measurements[endIndex].end < scrollOffset + outerSize) {
2007
- endIndex++;
2008
- }
2009
- } else if (lanes > 1) {
2010
- const endPerLane = Array(lanes).fill(0);
2011
- while (endIndex < lastIndex && endPerLane.some((pos) => pos < scrollOffset + outerSize)) {
2012
- const item = measurements[endIndex];
2013
- endPerLane[item.lane] = item.end;
2014
- endIndex++;
2015
- }
2016
- const startPerLane = Array(lanes).fill(scrollOffset + outerSize);
2017
- while (startIndex >= 0 && startPerLane.some((pos) => pos >= scrollOffset)) {
2018
- const item = measurements[startIndex];
2019
- startPerLane[item.lane] = item.start;
2020
- startIndex--;
2021
- }
2022
- startIndex = Math.max(0, startIndex - startIndex % lanes);
2023
- endIndex = Math.min(lastIndex, endIndex + (lanes - 1 - endIndex % lanes));
2024
- }
2025
- return { startIndex, endIndex };
2026
- }
2027
-
2028
- // ../../node_modules/.pnpm/@tanstack+react-virtual@3.13.24_react-dom@19.2.7_react@19.2.7__react@19.2.7/node_modules/@tanstack/react-virtual/dist/esm/index.js
2029
- var useIsomorphicLayoutEffect = typeof document !== "undefined" ? React.useLayoutEffect : React.useEffect;
2030
- function useVirtualizerBase(_a) {
2031
- var _b = _a, {
2032
- useFlushSync = true
2033
- } = _b, options = __objRest(_b, [
2034
- "useFlushSync"
2035
- ]);
2036
- const rerender = React.useReducer(() => ({}), {})[1];
2037
- const resolvedOptions = __spreadProps(__spreadValues({}, options), {
2038
- onChange: (instance2, sync) => {
2039
- var _a2;
2040
- if (useFlushSync && sync) {
2041
- flushSync(rerender);
2042
- } else {
2043
- rerender();
2044
- }
2045
- (_a2 = options.onChange) == null ? void 0 : _a2.call(options, instance2, sync);
2046
- }
2047
- });
2048
- const [instance] = React.useState(
2049
- () => new Virtualizer(resolvedOptions)
2050
- );
2051
- instance.setOptions(resolvedOptions);
2052
- useIsomorphicLayoutEffect(() => {
2053
- return instance._didMount();
2054
- }, []);
2055
- useIsomorphicLayoutEffect(() => {
2056
- return instance._willUpdate();
2057
- });
2058
- return instance;
2059
- }
2060
- function useWindowVirtualizer(options) {
2061
- return useVirtualizerBase(__spreadValues({
2062
- getScrollElement: () => typeof document !== "undefined" ? window : null,
2063
- observeElementRect: observeWindowRect,
2064
- observeElementOffset: observeWindowOffset,
2065
- scrollToFn: windowScroll,
2066
- initialOffset: () => typeof document !== "undefined" ? window.scrollY : 0
2067
- }, options));
2068
- }
2069
-
2070
- // ../renderers/src/CollectionRenderer/components/ContentComponent.tsx
2071
- import { ProcessIndicator, Button as Button4 } from "@transferwise/components";
2072
- import { useRef as useRef3, useEffect as useEffect7, useMemo, useLayoutEffect as useLayoutEffect2 } from "react";
2073
-
2074
- // ../renderers/src/step/StepFooter.tsx
2075
- import { Button as Button3 } from "@transferwise/components";
2076
- import { useEffect as useEffect6, useRef as useRef2, useState as useState5 } from "react";
2077
- import { useIntl as useIntl3 } from "react-intl";
2078
-
2079
- // ../renderers/src/messages/step.messages.ts
2080
- import { defineMessages as defineMessages3 } from "react-intl";
2081
- var step_messages_default = defineMessages3({
2082
- scrollToBottom: {
2083
- id: "df.wise.step.scrollToBottom",
2084
- defaultMessage: "Scroll to bottom",
2085
- description: "Label for a button that appears when the content of a step is too long and the user needs to scroll to the bottom to see all the content."
2086
- }
2087
- });
2088
-
2089
- // ../renderers/src/step/StepFooter.tsx
2090
- import { Fragment, jsx as jsx24, jsxs as jsxs4 } from "react/jsx-runtime";
2091
- var SCROLL_TO_BOTTOM = "scroll-to-bottom";
2092
- var StepFooter = ({ footer, tags }) => {
2093
- if (tags == null ? void 0 : tags.includes(SCROLL_TO_BOTTOM)) {
2094
- return /* @__PURE__ */ jsx24(FooterWithScrollButton, { footer });
2095
- }
2096
- return /* @__PURE__ */ jsx24(DefaultFooter, { footer });
2097
- };
2098
- var DefaultFooter = ({ footer }) => {
2099
- const hasFooter = footer && Array.isArray(footer) && footer.length > 0;
2100
- return hasFooter ? /* @__PURE__ */ jsx24("div", { className: "df-step-fixed__footer", children: footer }) : void 0;
2101
- };
2102
- var FooterWithScrollButton = ({ footer }) => {
2103
- const { formatMessage } = useIntl3();
2104
- const endOfLayoutRef = useRef2(null);
2105
- const isElementVisible = useIsElementVisible(endOfLayoutRef);
2106
- const scrollButton = /* @__PURE__ */ jsx24(
2107
- Button3,
2108
- {
2109
- className: "m-b-1",
2110
- v2: true,
2111
- block: true,
2112
- priority: "tertiary",
2113
- onClick: () => {
2114
- var _a;
2115
- (_a = endOfLayoutRef.current) == null ? void 0 : _a.scrollIntoView({ behavior: "smooth" });
2116
- },
2117
- children: formatMessage(step_messages_default.scrollToBottom)
2118
- }
2119
- );
2120
- const hasStepFooterContent = footer && Array.isArray(footer) && footer.length > 0;
2121
- if (isElementVisible && !hasStepFooterContent) {
2122
- return /* @__PURE__ */ jsx24("div", { ref: endOfLayoutRef, "aria-hidden": "true" });
2123
- }
2124
- return /* @__PURE__ */ jsxs4(Fragment, { children: [
2125
- /* @__PURE__ */ jsx24("div", { ref: endOfLayoutRef, "aria-hidden": "true" }),
2126
- /* @__PURE__ */ jsxs4("div", { className: "df-step-fixed__footer", children: [
2127
- !isElementVisible && scrollButton,
2128
- footer
2129
- ] })
2130
- ] });
2131
- };
2132
- var useIsElementVisible = (elementRef) => {
2133
- const [isVisible, setIsVisible] = useState5(false);
2134
- useEffect6(() => {
2135
- const element = elementRef.current;
2136
- if (!element) return;
2137
- const observer = new IntersectionObserver(([entry]) => {
2138
- setIsVisible(entry.isIntersecting);
2139
- });
2140
- observer.observe(element);
2141
- return () => observer.disconnect();
2142
- }, [elementRef]);
2143
- return isVisible;
2144
- };
1107
+ // ../renderers/src/ColumnsRenderer.tsx
1108
+ var import_classnames3 = __toESM(require_classnames());
2145
1109
 
2146
- // ../renderers/src/CollectionRenderer/components/ContentComponent.tsx
2147
- import { jsx as jsx25, jsxs as jsxs5 } from "react/jsx-runtime";
2148
- var ContentComponent = (props) => {
2149
- const { state, status, SectionHeader, Item } = props;
2150
- const endOfContentRef = useRef3(null);
2151
- const isBottomVisible = useIsElementVisible(endOfContentRef);
2152
- useEffect7(() => {
2153
- var _a;
2154
- if (isBottomVisible && status.type === "idle" && status.loadMore) {
2155
- (_a = status.loadMore) == null ? void 0 : _a.call(status);
2156
- }
2157
- }, [isBottomVisible]);
2158
- const stateCount = state.sections.reduce(
2159
- (total, section) => section.items.length + total + (section.title ? 1 : 0),
2160
- 0
1110
+ // ../renderers/src/utils/useIsCollapsed.ts
1111
+ import { useEffect as useEffect5, useState as useState4 } from "react";
1112
+ var COLLAPSE_QUERY = "(max-width: 767.98px)";
1113
+ var supportsMatchMedia = () => typeof window !== "undefined" && !!window.matchMedia;
1114
+ var useIsCollapsed = () => {
1115
+ const [collapsed, setCollapsed] = useState4(
1116
+ () => supportsMatchMedia() && window.matchMedia(COLLAPSE_QUERY).matches
2161
1117
  );
2162
- const items = useMemo(() => {
2163
- return state.sections.reduce((acc, section) => {
2164
- return [
2165
- ...acc,
2166
- ...section.title ? [
2167
- {
2168
- type: "header",
2169
- title: section.title,
2170
- items: section.items,
2171
- id: section.id
2172
- }
2173
- ] : [],
2174
- ...section.items.map((item) => ({
2175
- item,
2176
- type: "item"
2177
- }))
2178
- ];
2179
- }, []);
2180
- }, [stateCount]);
2181
- const listRef = useRef3(null);
2182
- const listOffsetRef = useRef3(0);
2183
- useLayoutEffect2(() => {
2184
- var _a, _b;
2185
- listOffsetRef.current = (_b = (_a = listRef.current) == null ? void 0 : _a.offsetTop) != null ? _b : 0;
2186
- });
2187
- const virtualizer = useWindowVirtualizer({
2188
- count: stateCount,
2189
- estimateSize: () => 120,
2190
- // todo, we could be clever here. Is it worth it?
2191
- overscan: 10,
2192
- scrollMargin: listOffsetRef.current
2193
- });
2194
- return /* @__PURE__ */ jsxs5("div", { ref: listRef, children: [
2195
- state.beforeSections,
2196
- /* @__PURE__ */ jsx25(
2197
- "div",
2198
- {
2199
- style: {
2200
- height: `${virtualizer.getTotalSize()}px`,
2201
- width: "100%",
2202
- position: "relative"
2203
- },
2204
- children: virtualizer.getVirtualItems().map((item) => {
2205
- const i = items[item.index];
2206
- if (!i) {
2207
- return null;
2208
- }
2209
- return /* @__PURE__ */ jsx25(
2210
- "div",
2211
- {
2212
- ref: virtualizer.measureElement,
2213
- "data-index": item.index,
2214
- style: {
2215
- position: "absolute",
2216
- top: 0,
2217
- left: 0,
2218
- width: "100%",
2219
- transform: `translateY(${item.start - virtualizer.options.scrollMargin}px)`
2220
- },
2221
- children: i.type === "header" ? /* @__PURE__ */ jsx25(SectionHeader, __spreadValues({}, i)) : /* @__PURE__ */ jsx25(Item, __spreadValues({}, i.item))
2222
- },
2223
- item.key
2224
- );
2225
- })
2226
- }
2227
- ),
2228
- /* @__PURE__ */ jsxs5("div", { ref: endOfContentRef, className: "d-flex m-x-auto m-y-2", children: [
2229
- status.type === "idle" || status.type === "loading" && status.reason === "pagination" ? /* @__PURE__ */ jsx25(ProcessIndicator, { size: "xs" }) : null,
2230
- status.type === "error" && status.reason === "pagination" ? /* @__PURE__ */ jsx25("div", { className: "d-flex m-x-auto", children: /* @__PURE__ */ jsx25(Button4, { v2: true, size: "sm", priority: "secondary-neutral", onClick: status.retry, children: "Load more" }) }) : null
2231
- ] }),
2232
- state.afterSections
2233
- ] });
2234
- };
2235
-
2236
- // ../renderers/src/CollectionRenderer/components/SearchComponent.tsx
2237
- import { InputGroup, Input } from "@transferwise/components";
2238
- import { Search } from "@transferwise/icons";
2239
- import { jsx as jsx26 } from "react/jsx-runtime";
2240
- var SearchComponent = ({ state, features }) => {
2241
- const { search } = state;
2242
- if (!search) {
2243
- return;
2244
- }
2245
- return /* @__PURE__ */ jsx26(
2246
- FieldInput_default,
2247
- {
2248
- id: "search",
2249
- description: "",
2250
- validation: void 0,
2251
- help: "",
2252
- label: search.title,
2253
- features,
2254
- children: /* @__PURE__ */ jsx26(InputGroup, { addonStart: { content: /* @__PURE__ */ jsx26(Search, { size: 24 }) }, children: /* @__PURE__ */ jsx26(
2255
- Input,
2256
- {
2257
- id: "search",
2258
- name: "search",
2259
- shape: "pill",
2260
- placeholder: search.hint,
2261
- type: "text",
2262
- value: search.query,
2263
- onChange: ({ currentTarget: { value } }) => {
2264
- search.onChange(value);
2265
- }
2266
- }
2267
- ) })
1118
+ useEffect5(() => {
1119
+ if (supportsMatchMedia()) {
1120
+ const mql = window.matchMedia(COLLAPSE_QUERY);
1121
+ const update = () => setCollapsed(mql.matches);
1122
+ mql.addEventListener("change", update);
1123
+ return () => mql.removeEventListener("change", update);
2268
1124
  }
2269
- );
2270
- };
2271
-
2272
- // ../renderers/src/CollectionRenderer/components/FilterComponent.tsx
2273
- import { Chips } from "@transferwise/components";
2274
- import { jsx as jsx27 } from "react/jsx-runtime";
2275
- var FiltersComponent = ({ state }) => {
2276
- const { filters } = state;
2277
- return filters.map((filter) => {
2278
- var _a;
2279
- return /* @__PURE__ */ jsx27(FilterComponent, __spreadValues({}, filter), JSON.stringify((_a = filter.options) == null ? void 0 : _a.map((o) => o.value)));
2280
- });
2281
- };
2282
- var FilterComponent = (filter) => {
2283
- const { multiSelect, options } = filter;
2284
- if (!options) {
2285
- return null;
2286
- }
2287
- return /* @__PURE__ */ jsx27(
2288
- Chips,
2289
- {
2290
- className: "m-b-1",
2291
- multiple: multiSelect,
2292
- selected: options.some((option) => option.selected) ? options.filter((option) => option.selected).map((option) => option.value) : multiSelect ? [] : "",
2293
- chips: [
2294
- ...multiSelect ? [
2295
- {
2296
- value: "",
2297
- // this is a placeholder for now, only for single selects, when it is not possible to de-select options
2298
- label: "All"
2299
- }
2300
- ] : [],
2301
- ...options.map((option) => ({
2302
- value: option.value,
2303
- label: option.title
2304
- }))
2305
- ],
2306
- onChange: (value) => {
2307
- var _a;
2308
- if (value.selectedValue === "") {
2309
- options == null ? void 0 : options.filter((option) => option.selected).map((option) => option == null ? void 0 : option.onSelect());
2310
- return;
2311
- }
2312
- (_a = options == null ? void 0 : options.find((option) => value.selectedValue === option.value)) == null ? void 0 : _a.onSelect();
2313
- }
2314
- },
2315
- JSON.stringify(options)
2316
- );
2317
- };
2318
-
2319
- // ../renderers/src/CollectionRenderer/components/ItemComponent.tsx
2320
- import { ListItem as ListItem6 } from "@transferwise/components";
2321
-
2322
- // ../renderers/src/utils/listItem/getAdditionalInfo.tsx
2323
- import { ListItem as ListItem4 } from "@transferwise/components";
2324
- import { jsx as jsx28 } from "react/jsx-runtime";
2325
- var getAdditionalInfo = (additionalInfo) => {
2326
- var _a, _b;
2327
- if (!additionalInfo) {
2328
1125
  return void 0;
2329
- }
2330
- const { href, text, onClick } = additionalInfo;
2331
- if (href || onClick) {
2332
- return /* @__PURE__ */ jsx28(
2333
- ListItem4.AdditionalInfo,
2334
- {
2335
- action: __spreadValues({
2336
- label: text
2337
- }, (_b = (_a = additionalInfo.getAnchorProps) == null ? void 0 : _a.call(additionalInfo)) != null ? _b : { onClick })
2338
- }
2339
- );
2340
- }
2341
- return /* @__PURE__ */ jsx28(ListItem4.AdditionalInfo, { children: additionalInfo == null ? void 0 : additionalInfo.text });
2342
- };
2343
-
2344
- // ../renderers/src/utils/listItem/getCTAControl.tsx
2345
- import { ListItem as ListItem5 } from "@transferwise/components";
2346
- import { jsx as jsx29 } from "react/jsx-runtime";
2347
- var getCTAControl = (callToAction, { ctaSecondary, fullyInteractive }) => {
2348
- if (!callToAction) {
2349
- return void 0;
2350
- }
2351
- const { accessibilityDescription, title, context } = callToAction;
2352
- const { priority, sentiment } = getPriorityAndSentiment(ctaSecondary, context);
2353
- return /* @__PURE__ */ jsx29(
2354
- ListItem5.Button,
2355
- __spreadProps(__spreadValues({}, callToAction.getAnchorProps()), {
2356
- partiallyInteractive: !fullyInteractive,
2357
- priority,
2358
- "aria-description": accessibilityDescription,
2359
- sentiment,
2360
- children: title
2361
- })
2362
- );
2363
- };
2364
- var getPriorityAndSentiment = (ctaSecondary, context) => {
2365
- if (context === "negative") {
2366
- return { priority: "secondary", sentiment: "negative" };
2367
- }
2368
- return { priority: ctaSecondary ? "secondary" : "secondary-neutral", sentiment: "default" };
2369
- };
2370
-
2371
- // ../renderers/src/utils/listItem/shouldUseAvatar.ts
2372
- var shouldUseAvatar = (control, tags) => {
2373
- var _a;
2374
- return control === "with-avatar" || ((_a = tags == null ? void 0 : tags.includes("with-avatar")) != null ? _a : false);
2375
- };
2376
-
2377
- // ../renderers/src/CollectionRenderer/components/ItemComponent.tsx
2378
- import { jsx as jsx30 } from "react/jsx-runtime";
2379
- var ItemComponent = (props) => {
2380
- var _a, _b;
2381
- const {
2382
- title,
2383
- description,
2384
- supportingValues,
2385
- media,
2386
- additionalInfo,
2387
- inlineAlert,
2388
- href,
2389
- onClick,
2390
- callToAction,
2391
- tags,
2392
- parentTags,
2393
- control
2394
- } = props;
2395
- const controlOptions = {
2396
- ctaSecondary: (_a = tags == null ? void 0 : tags.includes("cta-secondary")) != null ? _a : false,
2397
- fullyInteractive: (_b = (tags == null ? void 0 : tags.includes("fully-interactive")) && (additionalInfo == null ? void 0 : additionalInfo.onClick) == null) != null ? _b : false
2398
- };
2399
- return /* @__PURE__ */ jsx30(
2400
- ListItem6,
2401
- {
2402
- title,
2403
- subtitle: description,
2404
- valueTitle: supportingValues == null ? void 0 : supportingValues.value,
2405
- valueSubtitle: supportingValues == null ? void 0 : supportingValues.subvalue,
2406
- media: getMedia(media, shouldUseAvatar(control, parentTags)),
2407
- prompt: getInlineAlert(inlineAlert),
2408
- additionalInfo: getAdditionalInfo(additionalInfo),
2409
- control: onClick || href ? getNavigationControl(onClick, href) : getCTAControl(callToAction, controlOptions)
2410
- },
2411
- title
2412
- );
2413
- };
2414
- var getNavigationControl = (onClick, href) => {
2415
- if (href) {
2416
- return /* @__PURE__ */ jsx30(ListItem6.Navigation, { href });
2417
- }
2418
- if (onClick) {
2419
- return /* @__PURE__ */ jsx30(ListItem6.Navigation, { onClick });
2420
- }
2421
- return null;
2422
- };
2423
-
2424
- // ../renderers/src/CollectionRenderer/components/SectionHeaderComponent.tsx
2425
- import { jsx as jsx31 } from "react/jsx-runtime";
2426
- var SectionHeaderComponent = ({
2427
- title,
2428
- callToAction
2429
- }) => /* @__PURE__ */ jsx31(Header, { title, callToAction });
2430
-
2431
- // ../renderers/src/CollectionRenderer/createCollectionRenderer.tsx
2432
- import { jsx as jsx32 } from "react/jsx-runtime";
2433
- var createCollectionRenderer = (canRender, components) => {
2434
- const componeontsWithDefaults = __spreadValues({
2435
- Search: SearchComponent,
2436
- Filters: FiltersComponent,
2437
- Filter: FilterComponent,
2438
- Item: ItemComponent,
2439
- SectionHeader: SectionHeaderComponent,
2440
- Results: ContentComponent
2441
- }, components);
2442
- return {
2443
- canRenderType: "collection",
2444
- canRender,
2445
- render: (props) => {
2446
- return /* @__PURE__ */ jsx32(CollectionRendererComponent, __spreadValues(__spreadValues({}, props), componeontsWithDefaults));
2447
- }
2448
- };
2449
- };
2450
-
2451
- // ../renderers/src/CollectionRenderer/CollectionRenderer.tsx
2452
- import { Fragment as Fragment2, jsx as jsx33, jsxs as jsxs6 } from "react/jsx-runtime";
2453
- var CollectionRendererComponent = (props) => {
2454
- const { status, Search: Search4, Filters, Results } = props;
2455
- return /* @__PURE__ */ jsxs6(Fragment2, { children: [
2456
- /* @__PURE__ */ jsx33(Search4, __spreadValues({}, props)),
2457
- /* @__PURE__ */ jsx33(Filters, __spreadValues({}, props)),
2458
- status.type === "idle" || status.reason === "pagination" ? /* @__PURE__ */ jsx33(Results, __spreadValues({}, props)) : void 0,
2459
- status.type === "error" && status.reason === "search" && /* @__PURE__ */ jsxs6(InlinePrompt, { width: "full", sentiment: "negative", children: [
2460
- "Something went wrong,\xA0",
2461
- /* @__PURE__ */ jsx33(DSLink, { onClick: status.retry, children: "click here to retry" })
2462
- ] })
2463
- ] });
1126
+ }, []);
1127
+ return collapsed;
2464
1128
  };
2465
- var CollectionRenderer = createCollectionRenderer(() => true, {
2466
- Search: (props) => /* @__PURE__ */ jsx33(SearchComponent, __spreadValues({}, props)),
2467
- Filters: (props) => /* @__PURE__ */ jsx33(FiltersComponent, __spreadValues({}, props)),
2468
- Filter: (props) => /* @__PURE__ */ jsx33(FilterComponent, __spreadValues({}, props)),
2469
- Item: (props) => /* @__PURE__ */ jsx33(ItemComponent, __spreadValues({}, props)),
2470
- SectionHeader: (props) => /* @__PURE__ */ jsx33(SectionHeaderComponent, __spreadValues({}, props)),
2471
- Results: (props) => /* @__PURE__ */ jsx33(ContentComponent, __spreadValues({}, props))
2472
- });
2473
- var CollectionRenderer_default = CollectionRenderer;
2474
1129
 
2475
1130
  // ../renderers/src/ColumnsRenderer.tsx
2476
- var import_classnames3 = __toESM(require_classnames());
2477
- import { jsx as jsx34, jsxs as jsxs7 } from "react/jsx-runtime";
1131
+ import { jsx as jsx24, jsxs as jsxs5 } from "react/jsx-runtime";
1132
+ var RIGHT_FIRST_STACKING = "right-first-stacking";
2478
1133
  var ColumnsRenderer = {
2479
1134
  canRenderType: "columns",
2480
- render: ({ bias, margin, startChildren, endChildren }) => /* @__PURE__ */ jsxs7(
1135
+ render: ColumnsRendererComponent
1136
+ };
1137
+ function ColumnsRendererComponent({
1138
+ bias,
1139
+ margin,
1140
+ startChildren,
1141
+ endChildren,
1142
+ tags
1143
+ }) {
1144
+ var _a;
1145
+ const isCollapsed = useIsCollapsed();
1146
+ const reverse = isCollapsed && ((_a = tags == null ? void 0 : tags.includes(RIGHT_FIRST_STACKING)) != null ? _a : false);
1147
+ const startColumn = /* @__PURE__ */ jsx24("div", { className: "df-columns-renderer-column", children: startChildren });
1148
+ const endColumn = /* @__PURE__ */ jsx24("div", { className: "df-columns-renderer-column", children: endChildren });
1149
+ return /* @__PURE__ */ jsxs5(
2481
1150
  "div",
2482
1151
  {
2483
1152
  className: (0, import_classnames3.default)("df-columns-renderer-container", getMargin(margin), {
@@ -2485,12 +1154,12 @@ var ColumnsRenderer = {
2485
1154
  "df-columns-renderer-bias-end": bias === "end"
2486
1155
  }),
2487
1156
  children: [
2488
- /* @__PURE__ */ jsx34("div", { className: "df-columns-renderer-column", children: startChildren }),
2489
- /* @__PURE__ */ jsx34("div", { className: "df-columns-renderer-column", children: endChildren })
1157
+ reverse ? endColumn : startColumn,
1158
+ reverse ? startColumn : endColumn
2490
1159
  ]
2491
- }
2492
- )
2493
- };
1160
+ }
1161
+ );
1162
+ }
2494
1163
  var ColumnsRenderer_default = ColumnsRenderer;
2495
1164
 
2496
1165
  // ../renderers/src/components/VariableDateInput.tsx
@@ -2521,7 +1190,7 @@ var dateToDateString = (date) => {
2521
1190
  };
2522
1191
 
2523
1192
  // ../renderers/src/components/VariableDateInput.tsx
2524
- import { jsx as jsx35 } from "react/jsx-runtime";
1193
+ import { jsx as jsx25 } from "react/jsx-runtime";
2525
1194
  function VariableDateInput({
2526
1195
  control,
2527
1196
  inputProps
@@ -2537,7 +1206,7 @@ function VariableDateInput({
2537
1206
  onFocus
2538
1207
  } = inputProps;
2539
1208
  if (control === "date-lookup") {
2540
- return /* @__PURE__ */ jsx35(
1209
+ return /* @__PURE__ */ jsx25(
2541
1210
  DateLookup,
2542
1211
  {
2543
1212
  value: dateStringToDateOrNull(inputProps.value),
@@ -2553,7 +1222,7 @@ function VariableDateInput({
2553
1222
  }
2554
1223
  );
2555
1224
  }
2556
- return /* @__PURE__ */ jsx35(
1225
+ return /* @__PURE__ */ jsx25(
2557
1226
  DateInput,
2558
1227
  __spreadProps(__spreadValues({}, inputProps), {
2559
1228
  dayAutoComplete: getAutocompleteString(autoComplete, "day"),
@@ -2570,7 +1239,7 @@ var getAutocompleteString = (value, suffix) => {
2570
1239
  var VariableDateInput_default = VariableDateInput;
2571
1240
 
2572
1241
  // ../renderers/src/DateInputRenderer.tsx
2573
- import { jsx as jsx36 } from "react/jsx-runtime";
1242
+ import { jsx as jsx26 } from "react/jsx-runtime";
2574
1243
  var DateInputRenderer = {
2575
1244
  canRenderType: "input-date",
2576
1245
  render: (props) => {
@@ -2595,7 +1264,7 @@ var DateInputRenderer = {
2595
1264
  ]);
2596
1265
  const value = initialValue != null ? initialValue : "";
2597
1266
  const inputProps = __spreadProps(__spreadValues({}, rest), { value, id });
2598
- return /* @__PURE__ */ jsx36(
1267
+ return /* @__PURE__ */ jsx26(
2599
1268
  FieldInput_default,
2600
1269
  {
2601
1270
  id,
@@ -2606,7 +1275,7 @@ var DateInputRenderer = {
2606
1275
  loadingState: props.fieldLoadingState,
2607
1276
  help,
2608
1277
  features: props.features,
2609
- children: /* @__PURE__ */ jsx36(VariableDateInput_default, { control, inputProps })
1278
+ children: /* @__PURE__ */ jsx26(VariableDateInput_default, { control, inputProps })
2610
1279
  }
2611
1280
  );
2612
1281
  }
@@ -2614,16 +1283,44 @@ var DateInputRenderer = {
2614
1283
  var DateInputRenderer_default = DateInputRenderer;
2615
1284
 
2616
1285
  // ../renderers/src/DecisionRenderer/DecisionRenderer.tsx
2617
- import { ListItem as ListItem7 } from "@transferwise/components";
1286
+ import { ListItem as ListItem5 } from "@transferwise/components";
1287
+
1288
+ // ../renderers/src/utils/listItem/getAdditionalInfo.tsx
1289
+ import { ListItem as ListItem4 } from "@transferwise/components";
1290
+ import { jsx as jsx27 } from "react/jsx-runtime";
1291
+ var getAdditionalInfo = (additionalInfo) => {
1292
+ var _a, _b;
1293
+ if (!additionalInfo) {
1294
+ return void 0;
1295
+ }
1296
+ const { href, text, onClick } = additionalInfo;
1297
+ if (href || onClick) {
1298
+ return /* @__PURE__ */ jsx27(
1299
+ ListItem4.AdditionalInfo,
1300
+ {
1301
+ action: __spreadValues({
1302
+ label: text
1303
+ }, (_b = (_a = additionalInfo.getAnchorProps) == null ? void 0 : _a.call(additionalInfo)) != null ? _b : { onClick })
1304
+ }
1305
+ );
1306
+ }
1307
+ return /* @__PURE__ */ jsx27(ListItem4.AdditionalInfo, { children: additionalInfo == null ? void 0 : additionalInfo.text });
1308
+ };
1309
+
1310
+ // ../renderers/src/utils/listItem/shouldUseAvatar.ts
1311
+ var shouldUseAvatar = (control, tags) => {
1312
+ var _a;
1313
+ return control === "with-avatar" || ((_a = tags == null ? void 0 : tags.includes("with-avatar")) != null ? _a : false);
1314
+ };
2618
1315
 
2619
1316
  // ../renderers/src/DecisionRenderer/DecisionWrapper.tsx
2620
- import { Header as Header3, SearchInput } from "@transferwise/components";
2621
- import { useState as useState6 } from "react";
2622
- import { useIntl as useIntl5 } from "react-intl";
1317
+ import { Header as Header2, SearchInput } from "@transferwise/components";
1318
+ import { useState as useState5 } from "react";
1319
+ import { useIntl as useIntl4 } from "react-intl";
2623
1320
 
2624
1321
  // ../renderers/src/messages/filter.messages.ts
2625
- import { defineMessages as defineMessages4 } from "react-intl";
2626
- var filter_messages_default = defineMessages4({
1322
+ import { defineMessages as defineMessages3 } from "react-intl";
1323
+ var filter_messages_default = defineMessages3({
2627
1324
  placeholder: {
2628
1325
  id: "df.wise.filter.placeholder",
2629
1326
  defaultMessage: "Start typing to search",
@@ -2689,12 +1386,12 @@ function filterAndSortDecisionOptions(selectOptions, query) {
2689
1386
  var normalizeAndRemoveAccents = (text) => text.trim().toLowerCase().normalize("NFKD").replace(new RegExp("\\p{Diacritic}", "gu"), "");
2690
1387
 
2691
1388
  // ../renderers/src/DecisionRenderer/GroupedDecisionList.tsx
2692
- import { Header as Header2, Section } from "@transferwise/components";
2693
- import { useIntl as useIntl4 } from "react-intl";
1389
+ import { Header, Section } from "@transferwise/components";
1390
+ import { useIntl as useIntl3 } from "react-intl";
2694
1391
 
2695
1392
  // ../renderers/src/messages/group.messages.ts
2696
- import { defineMessages as defineMessages5 } from "react-intl";
2697
- var group_messages_default = defineMessages5({
1393
+ import { defineMessages as defineMessages4 } from "react-intl";
1394
+ var group_messages_default = defineMessages4({
2698
1395
  all: {
2699
1396
  id: "df.wise.group.all",
2700
1397
  defaultMessage: "All",
@@ -2728,19 +1425,19 @@ var getGroupsFromTags = (knownTags, items) => {
2728
1425
  };
2729
1426
 
2730
1427
  // ../renderers/src/DecisionRenderer/GroupedDecisionList.tsx
2731
- import { Fragment as Fragment3, jsx as jsx37, jsxs as jsxs8 } from "react/jsx-runtime";
1428
+ import { Fragment as Fragment2, jsx as jsx28, jsxs as jsxs6 } from "react/jsx-runtime";
2732
1429
  var groupingTags = Object.keys(group_messages_default).filter((key) => key !== "all");
2733
1430
  var isGroupedDecision = (options) => {
2734
1431
  return getGroupsFromTags(groupingTags, options).length > 0;
2735
1432
  };
2736
1433
  var GroupedDecisionList = (_a) => {
2737
1434
  var _b = _a, { renderDecisionList: renderDecisionList2 } = _b, rest = __objRest(_b, ["renderDecisionList"]);
2738
- const { formatMessage } = useIntl4();
1435
+ const { formatMessage } = useIntl3();
2739
1436
  const { options } = rest;
2740
1437
  const itemsByTag = [...getGroupsFromTags(groupingTags, options), { tag: "all", items: options }];
2741
- return /* @__PURE__ */ jsx37(Fragment3, { children: itemsByTag.map(({ tag, items }) => /* @__PURE__ */ jsxs8(Section, { children: [
2742
- /* @__PURE__ */ jsx37(
2743
- Header2,
1438
+ return /* @__PURE__ */ jsx28(Fragment2, { children: itemsByTag.map(({ tag, items }) => /* @__PURE__ */ jsxs6(Section, { children: [
1439
+ /* @__PURE__ */ jsx28(
1440
+ Header,
2744
1441
  {
2745
1442
  as: "h2",
2746
1443
  title: tag in group_messages_default ? formatMessage(group_messages_default[tag]) : tag
@@ -2751,25 +1448,25 @@ var GroupedDecisionList = (_a) => {
2751
1448
  };
2752
1449
 
2753
1450
  // ../renderers/src/DecisionRenderer/DecisionWrapper.tsx
2754
- import { Fragment as Fragment4, jsx as jsx38, jsxs as jsxs9 } from "react/jsx-runtime";
1451
+ import { Fragment as Fragment3, jsx as jsx29, jsxs as jsxs7 } from "react/jsx-runtime";
2755
1452
  var DecisionWrapper = (props) => {
2756
- return /* @__PURE__ */ jsxs9("div", { className: getMargin(props.margin), children: [
2757
- props.title && /* @__PURE__ */ jsx38(Header3, { as: "h2", title: props.title }),
2758
- props.control === "filtered" ? /* @__PURE__ */ jsx38(FilteredDecisionList, __spreadValues({}, props)) : /* @__PURE__ */ jsx38(UnfilteredDecisionList, __spreadValues({}, props))
1453
+ return /* @__PURE__ */ jsxs7("div", { className: getMargin(props.margin), children: [
1454
+ props.title && /* @__PURE__ */ jsx29(Header2, { as: "h2", title: props.title }),
1455
+ props.control === "filtered" ? /* @__PURE__ */ jsx29(FilteredDecisionList, __spreadValues({}, props)) : /* @__PURE__ */ jsx29(UnfilteredDecisionList, __spreadValues({}, props))
2759
1456
  ] });
2760
1457
  };
2761
1458
  var UnfilteredDecisionList = (_a) => {
2762
1459
  var _b = _a, { renderDecisionList: renderDecisionList2 } = _b, rest = __objRest(_b, ["renderDecisionList"]);
2763
- return isGroupedDecision(rest.options) ? /* @__PURE__ */ jsx38(GroupedDecisionList, __spreadProps(__spreadValues({}, rest), { renderDecisionList: renderDecisionList2 })) : renderDecisionList2(rest);
1460
+ return isGroupedDecision(rest.options) ? /* @__PURE__ */ jsx29(GroupedDecisionList, __spreadProps(__spreadValues({}, rest), { renderDecisionList: renderDecisionList2 })) : renderDecisionList2(rest);
2764
1461
  };
2765
1462
  var FilteredDecisionList = (props) => {
2766
- const { formatMessage } = useIntl5();
2767
- const [query, setQuery] = useState6("");
1463
+ const { formatMessage } = useIntl4();
1464
+ const [query, setQuery] = useState5("");
2768
1465
  const { control, options, renderDecisionList: renderDecisionList2 } = props;
2769
1466
  const filteredOptions = (query == null ? void 0 : query.length) > 0 ? filterAndSortDecisionOptions(options, query) : options;
2770
1467
  const isGrouped = isGroupedDecision(options);
2771
- return /* @__PURE__ */ jsxs9(Fragment4, { children: [
2772
- /* @__PURE__ */ jsx38(
1468
+ return /* @__PURE__ */ jsxs7(Fragment3, { children: [
1469
+ /* @__PURE__ */ jsx29(
2773
1470
  SearchInput,
2774
1471
  {
2775
1472
  placeholder: formatMessage(filter_messages_default.placeholder),
@@ -2781,25 +1478,25 @@ var FilteredDecisionList = (props) => {
2781
1478
  }
2782
1479
  }
2783
1480
  ),
2784
- isGrouped && query.length === 0 ? /* @__PURE__ */ jsx38(GroupedDecisionList, __spreadValues({}, props)) : /* @__PURE__ */ jsxs9(Fragment4, { children: [
2785
- query.length > 0 && /* @__PURE__ */ jsx38(Header3, { as: "h2", title: formatMessage(filter_messages_default.results), className: "m-t-4" }),
1481
+ isGrouped && query.length === 0 ? /* @__PURE__ */ jsx29(GroupedDecisionList, __spreadValues({}, props)) : /* @__PURE__ */ jsxs7(Fragment3, { children: [
1482
+ query.length > 0 && /* @__PURE__ */ jsx29(Header2, { as: "h2", title: formatMessage(filter_messages_default.results), className: "m-t-4" }),
2786
1483
  filteredOptions.length > 0 ? renderDecisionList2({
2787
1484
  control,
2788
1485
  className: query.length === 0 ? "m-t-3" : "",
2789
1486
  options: filteredOptions
2790
- }) : /* @__PURE__ */ jsx38("p", { children: formatMessage(filter_messages_default.noResults) })
1487
+ }) : /* @__PURE__ */ jsx29("p", { children: formatMessage(filter_messages_default.noResults) })
2791
1488
  ] })
2792
1489
  ] });
2793
1490
  };
2794
1491
 
2795
1492
  // ../renderers/src/DecisionRenderer/DecisionRenderer.tsx
2796
- import { Fragment as Fragment5, jsx as jsx39 } from "react/jsx-runtime";
1493
+ import { Fragment as Fragment4, jsx as jsx30 } from "react/jsx-runtime";
2797
1494
  var DecisionRenderer = {
2798
1495
  canRenderType: "decision",
2799
- render: (props) => /* @__PURE__ */ jsx39(DecisionWrapper, __spreadProps(__spreadValues({}, props), { renderDecisionList }))
1496
+ render: (props) => /* @__PURE__ */ jsx30(DecisionWrapper, __spreadProps(__spreadValues({}, props), { renderDecisionList }))
2800
1497
  };
2801
1498
  var renderDecisionList = ({ options, control }) => {
2802
- return /* @__PURE__ */ jsx39(Fragment5, { children: options.map((_a) => {
1499
+ return /* @__PURE__ */ jsx30(Fragment4, { children: options.map((_a) => {
2803
1500
  var _b = _a, { onClick } = _b, rest = __objRest(_b, ["onClick"]);
2804
1501
  const {
2805
1502
  description,
@@ -2812,8 +1509,8 @@ var renderDecisionList = ({ options, control }) => {
2812
1509
  supportingValues,
2813
1510
  tags
2814
1511
  } = rest;
2815
- return /* @__PURE__ */ jsx39(
2816
- ListItem7,
1512
+ return /* @__PURE__ */ jsx30(
1513
+ ListItem5,
2817
1514
  {
2818
1515
  title: itemTitle,
2819
1516
  subtitle: description,
@@ -2824,7 +1521,7 @@ var renderDecisionList = ({ options, control }) => {
2824
1521
  media: getMedia(media, shouldUseAvatar(control, tags)),
2825
1522
  prompt: getInlineAlert(inlineAlert),
2826
1523
  additionalInfo: additionalText ? getAdditionalInfo({ text: additionalText }) : void 0,
2827
- control: /* @__PURE__ */ jsx39(ListItem7.Navigation, __spreadValues({}, getAnchorProps()))
1524
+ control: /* @__PURE__ */ jsx30(ListItem5.Navigation, __spreadValues({}, getAnchorProps()))
2828
1525
  },
2829
1526
  JSON.stringify(rest)
2830
1527
  );
@@ -2834,7 +1531,7 @@ var DecisionRenderer_default = DecisionRenderer;
2834
1531
 
2835
1532
  // ../renderers/src/DividerRenderer.tsx
2836
1533
  import { Divider } from "@transferwise/components";
2837
- import { jsx as jsx40 } from "react/jsx-runtime";
1534
+ import { jsx as jsx31 } from "react/jsx-runtime";
2838
1535
  var mapControlToLevel = (control) => {
2839
1536
  switch (control) {
2840
1537
  case "section":
@@ -2847,16 +1544,16 @@ var mapControlToLevel = (control) => {
2847
1544
  };
2848
1545
  var DividerRenderer = {
2849
1546
  canRenderType: "divider",
2850
- render: ({ margin, control }) => /* @__PURE__ */ jsx40(Divider, { className: `m-t-0 d-block ${getMargin(margin)}`, level: mapControlToLevel(control) })
1547
+ render: ({ margin, control }) => /* @__PURE__ */ jsx31(Divider, { className: `m-t-0 d-block ${getMargin(margin)}`, level: mapControlToLevel(control) })
2851
1548
  };
2852
1549
  var DividerRenderer_default = DividerRenderer;
2853
1550
 
2854
1551
  // ../renderers/src/ExternalConfirmationRenderer.tsx
2855
- import { Button as Button5, Markdown as Markdown2, Modal } from "@transferwise/components";
1552
+ import { Button as Button3, Markdown as Markdown2, Modal } from "@transferwise/components";
2856
1553
 
2857
1554
  // ../renderers/src/messages/external-confirmation.messages.ts
2858
- import { defineMessages as defineMessages6 } from "react-intl";
2859
- var external_confirmation_messages_default = defineMessages6({
1555
+ import { defineMessages as defineMessages5 } from "react-intl";
1556
+ var external_confirmation_messages_default = defineMessages5({
2860
1557
  title: {
2861
1558
  id: "df.wise.ExternalConfirmation.title",
2862
1559
  defaultMessage: "Please confirm",
@@ -2880,9 +1577,9 @@ var external_confirmation_messages_default = defineMessages6({
2880
1577
  });
2881
1578
 
2882
1579
  // ../renderers/src/ExternalConfirmationRenderer.tsx
2883
- import { useIntl as useIntl6 } from "react-intl";
2884
- import { useEffect as useEffect8 } from "react";
2885
- import { Fragment as Fragment6, jsx as jsx41, jsxs as jsxs10 } from "react/jsx-runtime";
1580
+ import { useIntl as useIntl5 } from "react-intl";
1581
+ import { useEffect as useEffect6 } from "react";
1582
+ import { Fragment as Fragment5, jsx as jsx32, jsxs as jsxs8 } from "react/jsx-runtime";
2886
1583
  var ExternalConfirmationRenderer = {
2887
1584
  canRenderType: "external-confirmation",
2888
1585
  render: ExternalConfirmationRendererComponent
@@ -2893,20 +1590,20 @@ function ExternalConfirmationRendererComponent({
2893
1590
  open,
2894
1591
  onCancel
2895
1592
  }) {
2896
- const { formatMessage } = useIntl6();
2897
- useEffect8(() => {
1593
+ const { formatMessage } = useIntl5();
1594
+ useEffect6(() => {
2898
1595
  open();
2899
1596
  }, []);
2900
- return /* @__PURE__ */ jsx41(
1597
+ return /* @__PURE__ */ jsx32(
2901
1598
  Modal,
2902
1599
  {
2903
1600
  open: visible,
2904
1601
  title: formatMessage(external_confirmation_messages_default.title),
2905
- body: /* @__PURE__ */ jsxs10(Fragment6, { children: [
2906
- /* @__PURE__ */ jsx41(Markdown2, { config: { link: { target: "_blank" } }, className: "text-xs-center m-b-5", children: formatMessage(external_confirmation_messages_default.description, { origin: getOrigin(url) }) }),
2907
- /* @__PURE__ */ jsx41("div", { className: "df-box-renderer-fixed-width", children: /* @__PURE__ */ jsxs10("div", { className: "df-box-renderer-width-lg", children: [
2908
- /* @__PURE__ */ jsx41(
2909
- Button5,
1602
+ body: /* @__PURE__ */ jsxs8(Fragment5, { children: [
1603
+ /* @__PURE__ */ jsx32(Markdown2, { config: { link: { target: "_blank" } }, className: "text-xs-center m-b-5", children: formatMessage(external_confirmation_messages_default.description, { origin: getOrigin(url) }) }),
1604
+ /* @__PURE__ */ jsx32("div", { className: "df-box-renderer-fixed-width", children: /* @__PURE__ */ jsxs8("div", { className: "df-box-renderer-width-lg", children: [
1605
+ /* @__PURE__ */ jsx32(
1606
+ Button3,
2910
1607
  {
2911
1608
  v2: true,
2912
1609
  block: true,
@@ -2919,7 +1616,7 @@ function ExternalConfirmationRendererComponent({
2919
1616
  children: formatMessage(external_confirmation_messages_default.open)
2920
1617
  }
2921
1618
  ),
2922
- /* @__PURE__ */ jsx41(Button5, { v2: true, block: true, className: "m-b-2", priority: "tertiary", size: "md", onClick: onCancel, children: formatMessage(external_confirmation_messages_default.cancel) })
1619
+ /* @__PURE__ */ jsx32(Button3, { v2: true, block: true, className: "m-b-2", priority: "tertiary", size: "md", onClick: onCancel, children: formatMessage(external_confirmation_messages_default.cancel) })
2923
1620
  ] }) })
2924
1621
  ] }),
2925
1622
  onClose: onCancel
@@ -2936,27 +1633,27 @@ function getOrigin(url) {
2936
1633
  var ExternalConfirmationRenderer_default = ExternalConfirmationRenderer;
2937
1634
 
2938
1635
  // ../renderers/src/FormRenderer.tsx
2939
- import { jsx as jsx42 } from "react/jsx-runtime";
1636
+ import { jsx as jsx33 } from "react/jsx-runtime";
2940
1637
  var FormRenderer = {
2941
1638
  canRenderType: "form",
2942
- render: ({ children, margin }) => /* @__PURE__ */ jsx42("div", { className: getMargin(margin), children })
1639
+ render: ({ children, margin }) => /* @__PURE__ */ jsx33("div", { className: getMargin(margin), children })
2943
1640
  };
2944
1641
  var FormRenderer_default = FormRenderer;
2945
1642
 
2946
1643
  // ../renderers/src/FormSectionRenderer.tsx
2947
- import { Header as Header4 } from "@transferwise/components";
2948
- import { jsx as jsx43, jsxs as jsxs11 } from "react/jsx-runtime";
1644
+ import { Header as Header3 } from "@transferwise/components";
1645
+ import { jsx as jsx34, jsxs as jsxs9 } from "react/jsx-runtime";
2949
1646
  var FormSectionRenderer = {
2950
1647
  canRenderType: "form-section",
2951
- render: ({ title, description, children }) => /* @__PURE__ */ jsxs11("fieldset", { children: [
2952
- title && /* @__PURE__ */ jsx43(
2953
- Header4,
1648
+ render: ({ title, description, children }) => /* @__PURE__ */ jsxs9("fieldset", { children: [
1649
+ title && /* @__PURE__ */ jsx34(
1650
+ Header3,
2954
1651
  {
2955
1652
  as: "h2",
2956
1653
  title
2957
1654
  }
2958
1655
  ),
2959
- description && /* @__PURE__ */ jsx43("p", { children: description }),
1656
+ description && /* @__PURE__ */ jsx34("p", { children: description }),
2960
1657
  children
2961
1658
  ] })
2962
1659
  };
@@ -2964,18 +1661,18 @@ var FormSectionRenderer_default = FormSectionRenderer;
2964
1661
 
2965
1662
  // ../renderers/src/HeadingRenderer.tsx
2966
1663
  import { Display, Title } from "@transferwise/components";
2967
- import { jsx as jsx44 } from "react/jsx-runtime";
1664
+ import { jsx as jsx35 } from "react/jsx-runtime";
2968
1665
  var HeadingRenderer = {
2969
1666
  canRenderType: "heading",
2970
- render: (props) => /* @__PURE__ */ jsx44(Heading, __spreadValues({}, props))
1667
+ render: (props) => /* @__PURE__ */ jsx35(Heading, __spreadValues({}, props))
2971
1668
  };
2972
1669
  function Heading(props) {
2973
1670
  const { text, size, align, margin, control } = props;
2974
1671
  const className = getTextAlignmentAndMargin({ align, margin });
2975
- return control === "display" ? /* @__PURE__ */ jsx44(DisplayHeading, { size, text, className }) : /* @__PURE__ */ jsx44(StandardHeading, { size, text, className });
1672
+ return control === "display" ? /* @__PURE__ */ jsx35(DisplayHeading, { size, text, className }) : /* @__PURE__ */ jsx35(StandardHeading, { size, text, className });
2976
1673
  }
2977
1674
  function DisplayHeading({ size, text, className }) {
2978
- return /* @__PURE__ */ jsx44(Display, { type: getDisplayType(size), className, children: text });
1675
+ return /* @__PURE__ */ jsx35(Display, { type: getDisplayType(size), className, children: text });
2979
1676
  }
2980
1677
  var getDisplayType = (size) => {
2981
1678
  switch (size) {
@@ -2991,7 +1688,7 @@ var getDisplayType = (size) => {
2991
1688
  }
2992
1689
  };
2993
1690
  function StandardHeading({ size, text, className }) {
2994
- return /* @__PURE__ */ jsx44(Title, { type: getTitleTypeBySize(size), className, children: text });
1691
+ return /* @__PURE__ */ jsx35(Title, { type: getTitleTypeBySize(size), className, children: text });
2995
1692
  }
2996
1693
  var getTitleTypeBySize = (size) => {
2997
1694
  var _a;
@@ -3008,7 +1705,7 @@ var HeadingRenderer_default = HeadingRenderer;
3008
1705
 
3009
1706
  // ../renderers/src/ImageRenderer/UrlImage.tsx
3010
1707
  import { Image } from "@transferwise/components";
3011
- import { useEffect as useEffect9, useState as useState7 } from "react";
1708
+ import { useEffect as useEffect7, useState as useState6 } from "react";
3012
1709
 
3013
1710
  // ../renderers/src/utils/api-utils.ts
3014
1711
  function isRelativePath(url = "") {
@@ -3018,7 +1715,7 @@ function isRelativePath(url = "") {
3018
1715
  }
3019
1716
 
3020
1717
  // ../renderers/src/ImageRenderer/UrlImage.tsx
3021
- import { jsx as jsx45 } from "react/jsx-runtime";
1718
+ import { jsx as jsx36 } from "react/jsx-runtime";
3022
1719
  function UrlImage({
3023
1720
  accessibilityDescription,
3024
1721
  align,
@@ -3027,13 +1724,13 @@ function UrlImage({
3027
1724
  uri,
3028
1725
  httpClient
3029
1726
  }) {
3030
- const [imageSource, setImageSource] = useState7("");
3031
- useEffect9(() => {
1727
+ const [imageSource, setImageSource] = useState6("");
1728
+ useEffect7(() => {
3032
1729
  if (!uri.startsWith("urn:")) {
3033
1730
  void getImageSource(httpClient, uri).then(setImageSource);
3034
1731
  }
3035
1732
  }, [uri, httpClient]);
3036
- return /* @__PURE__ */ jsx45("div", { className: `df-image ${align} ${size || "md"} ${getMargin(margin)}`, children: /* @__PURE__ */ jsx45(
1733
+ return /* @__PURE__ */ jsx36("div", { className: `df-image ${align} ${size || "md"} ${getMargin(margin)}`, children: /* @__PURE__ */ jsx36(
3037
1734
  Image,
3038
1735
  {
3039
1736
  className: "df-reserve-space",
@@ -3077,7 +1774,7 @@ var getImageSource = async (httpClient, imageUrl) => {
3077
1774
  };
3078
1775
 
3079
1776
  // ../renderers/src/ImageRenderer/UrnFlagImage.tsx
3080
- import { jsx as jsx46 } from "react/jsx-runtime";
1777
+ import { jsx as jsx37 } from "react/jsx-runtime";
3081
1778
  var maxFlagSize = 600;
3082
1779
  function UrnFlagImage({
3083
1780
  accessibilityDescription,
@@ -3086,7 +1783,7 @@ function UrnFlagImage({
3086
1783
  size,
3087
1784
  uri
3088
1785
  }) {
3089
- return /* @__PURE__ */ jsx46("div", { className: `df-image ${align} ${size || "md"} ${getMargin(margin)}`, children: /* @__PURE__ */ jsx46(UrnFlag, { size: maxFlagSize, urn: uri, accessibilityDescription }) });
1786
+ return /* @__PURE__ */ jsx37("div", { className: `df-image ${align} ${size || "md"} ${getMargin(margin)}`, children: /* @__PURE__ */ jsx37(UrnFlag, { size: maxFlagSize, urn: uri, accessibilityDescription }) });
3090
1787
  }
3091
1788
 
3092
1789
  // ../renderers/src/ImageRenderer/UrnIllustration.tsx
@@ -3094,18 +1791,18 @@ import {
3094
1791
  Illustration,
3095
1792
  isIllustrationSupport3D
3096
1793
  } from "@wise/art";
3097
- import { useState as useState8 } from "react";
1794
+ import { useState as useState7 } from "react";
3098
1795
 
3099
1796
  // ../renderers/src/ImageRenderer/isAnimated.ts
3100
1797
  var isAnimated = (uri) => {
3101
1798
  const { rComponents } = stringToURN(uri);
3102
- return rComponents["type"] === "animated";
1799
+ return rComponents.type === "animated";
3103
1800
  };
3104
1801
 
3105
1802
  // ../renderers/src/ImageRenderer/SafeIllustration3D.tsx
3106
1803
  import { Illustration3D } from "@wise/art";
3107
1804
  import { Component } from "react";
3108
- import { jsx as jsx47 } from "react/jsx-runtime";
1805
+ import { jsx as jsx38 } from "react/jsx-runtime";
3109
1806
  var Illustration3DErrorBoundary = class extends Component {
3110
1807
  constructor(props) {
3111
1808
  super(props);
@@ -3117,7 +1814,7 @@ var Illustration3DErrorBoundary = class extends Component {
3117
1814
  componentDidCatch() {
3118
1815
  this.props.onError();
3119
1816
  }
3120
- render() {
1817
+ async render() {
3121
1818
  if (this.state.hasError) {
3122
1819
  return null;
3123
1820
  }
@@ -3129,12 +1826,12 @@ var SafeIllustration3D = ({
3129
1826
  size,
3130
1827
  onError
3131
1828
  }) => {
3132
- return /* @__PURE__ */ jsx47(Illustration3DErrorBoundary, { onError, children: /* @__PURE__ */ jsx47(Illustration3D, { name, size }) });
1829
+ return /* @__PURE__ */ jsx38(Illustration3DErrorBoundary, { onError, children: /* @__PURE__ */ jsx38(Illustration3D, { name, size }) });
3133
1830
  };
3134
1831
  var SafeIllustration3D_default = SafeIllustration3D;
3135
1832
 
3136
1833
  // ../renderers/src/ImageRenderer/UrnIllustration.tsx
3137
- import { jsx as jsx48 } from "react/jsx-runtime";
1834
+ import { jsx as jsx39 } from "react/jsx-runtime";
3138
1835
  var urnPrefix = "urn:wise:illustrations:";
3139
1836
  var isUrnIllustration = (uri) => uri.startsWith(urnPrefix);
3140
1837
  function UrnIllustration({
@@ -3144,12 +1841,12 @@ function UrnIllustration({
3144
1841
  size,
3145
1842
  uri
3146
1843
  }) {
3147
- const [has3DFailed, setHas3DFailed] = useState8(false);
1844
+ const [has3DFailed, setHas3DFailed] = useState7(false);
3148
1845
  const illustrationSize = getIllustrationSize(size);
3149
1846
  const illustrationName = getIllustrationName(uri);
3150
1847
  const illustration3DName = getIllustration3DName(uri);
3151
1848
  if (illustration3DName && isAnimated(uri) && !has3DFailed) {
3152
- return /* @__PURE__ */ jsx48("div", { className: `df-image ${align} ${getMargin(margin)}`, children: /* @__PURE__ */ jsx48(
1849
+ return /* @__PURE__ */ jsx39("div", { className: `df-image ${align} ${getMargin(margin)}`, children: /* @__PURE__ */ jsx39(
3153
1850
  SafeIllustration3D_default,
3154
1851
  {
3155
1852
  name: illustration3DName,
@@ -3158,7 +1855,7 @@ function UrnIllustration({
3158
1855
  }
3159
1856
  ) });
3160
1857
  }
3161
- return /* @__PURE__ */ jsx48("div", { className: `df-image ${align} ${getMargin(margin)}`, children: /* @__PURE__ */ jsx48(
1858
+ return /* @__PURE__ */ jsx39("div", { className: `df-image ${align} ${getMargin(margin)}`, children: /* @__PURE__ */ jsx39(
3162
1859
  Illustration,
3163
1860
  {
3164
1861
  className: "df-illustration",
@@ -3178,32 +1875,32 @@ var getIllustration3DName = (uri) => {
3178
1875
  };
3179
1876
 
3180
1877
  // ../renderers/src/ImageRenderer/UrnImage.tsx
3181
- import { jsx as jsx49 } from "react/jsx-runtime";
1878
+ import { jsx as jsx40 } from "react/jsx-runtime";
3182
1879
  var isUrnImage = (uri) => uri.startsWith("urn:");
3183
1880
  function UrnImage(props) {
3184
1881
  const { uri } = props;
3185
1882
  if (isUrnIllustration(uri)) {
3186
- return /* @__PURE__ */ jsx49(UrnIllustration, __spreadValues({}, props));
1883
+ return /* @__PURE__ */ jsx40(UrnIllustration, __spreadValues({}, props));
3187
1884
  }
3188
1885
  if (isUrnFlag(uri)) {
3189
- return /* @__PURE__ */ jsx49(UrnFlagImage, __spreadValues({}, props));
1886
+ return /* @__PURE__ */ jsx40(UrnFlagImage, __spreadValues({}, props));
3190
1887
  }
3191
1888
  return null;
3192
1889
  }
3193
1890
 
3194
1891
  // ../renderers/src/ImageRenderer/ImageRenderer.tsx
3195
- import { jsx as jsx50 } from "react/jsx-runtime";
1892
+ import { jsx as jsx41 } from "react/jsx-runtime";
3196
1893
  var ImageRenderer = {
3197
1894
  canRenderType: "image",
3198
- render: (props) => isUrnImage(props.uri) ? /* @__PURE__ */ jsx50(UrnImage, __spreadValues({}, props)) : /* @__PURE__ */ jsx50(UrlImage, __spreadValues({}, props))
1895
+ render: (props) => isUrnImage(props.uri) ? /* @__PURE__ */ jsx41(UrnImage, __spreadValues({}, props)) : /* @__PURE__ */ jsx41(UrlImage, __spreadValues({}, props))
3199
1896
  };
3200
1897
 
3201
1898
  // ../renderers/src/ImageRenderer/index.tsx
3202
1899
  var ImageRenderer_default = ImageRenderer;
3203
1900
 
3204
1901
  // ../renderers/src/InstructionsRenderer.tsx
3205
- import { Header as Header5, InstructionsList } from "@transferwise/components";
3206
- import { jsx as jsx51, jsxs as jsxs12 } from "react/jsx-runtime";
1902
+ import { Header as Header4, InstructionsList } from "@transferwise/components";
1903
+ import { jsx as jsx42, jsxs as jsxs10 } from "react/jsx-runtime";
3207
1904
  var doContext = ["positive", "neutral"];
3208
1905
  var dontContext = ["warning", "negative"];
3209
1906
  var InstructionsRenderer = {
@@ -3211,16 +1908,16 @@ var InstructionsRenderer = {
3211
1908
  render: ({ items, margin, title }) => {
3212
1909
  const dos = items.filter((item) => doContext.includes(item.context)).map(({ text }) => text);
3213
1910
  const donts = items.filter((item) => dontContext.includes(item.context)).map(({ text }) => text);
3214
- return /* @__PURE__ */ jsxs12("div", { className: getMargin(margin), children: [
3215
- title ? /* @__PURE__ */ jsx51(Header5, { title }) : null,
3216
- /* @__PURE__ */ jsx51(InstructionsList, { dos, donts })
1911
+ return /* @__PURE__ */ jsxs10("div", { className: getMargin(margin), children: [
1912
+ title ? /* @__PURE__ */ jsx42(Header4, { title }) : null,
1913
+ /* @__PURE__ */ jsx42(InstructionsList, { dos, donts })
3217
1914
  ] });
3218
1915
  }
3219
1916
  };
3220
1917
  var InstructionsRenderer_default = InstructionsRenderer;
3221
1918
 
3222
1919
  // ../renderers/src/IntegerInputRenderer.tsx
3223
- import { Input as Input2, InputGroup as InputGroup2 } from "@transferwise/components";
1920
+ import { Input, InputGroup } from "@transferwise/components";
3224
1921
 
3225
1922
  // ../renderers/src/utils/input-utils.ts
3226
1923
  var onWheel = (event) => {
@@ -3245,7 +1942,7 @@ function pick(obj, ...keys) {
3245
1942
  }
3246
1943
 
3247
1944
  // ../renderers/src/IntegerInputRenderer.tsx
3248
- import { jsx as jsx52 } from "react/jsx-runtime";
1945
+ import { jsx as jsx43 } from "react/jsx-runtime";
3249
1946
  var IntegerInputRenderer = {
3250
1947
  canRenderType: "input-integer",
3251
1948
  render: (props) => {
@@ -3260,7 +1957,7 @@ var IntegerInputRenderer = {
3260
1957
  "maximum",
3261
1958
  "minimum"
3262
1959
  );
3263
- return /* @__PURE__ */ jsx52(
1960
+ return /* @__PURE__ */ jsx43(
3264
1961
  FieldInput_default,
3265
1962
  {
3266
1963
  id,
@@ -3271,8 +1968,8 @@ var IntegerInputRenderer = {
3271
1968
  loadingState: props.fieldLoadingState,
3272
1969
  help,
3273
1970
  features: props.features,
3274
- children: /* @__PURE__ */ jsx52(InputGroup2, { addonStart: getInputGroupAddonStart(media), children: /* @__PURE__ */ jsx52(
3275
- Input2,
1971
+ children: /* @__PURE__ */ jsx43(InputGroup, { addonStart: getInputGroupAddonStart(media), children: /* @__PURE__ */ jsx43(
1972
+ Input,
3276
1973
  __spreadValues({
3277
1974
  id,
3278
1975
  name: id,
@@ -3294,12 +1991,39 @@ var IntegerInputRenderer = {
3294
1991
  var IntegerInputRenderer_default = IntegerInputRenderer;
3295
1992
 
3296
1993
  // ../renderers/src/ListRenderer.tsx
3297
- import { ListItem as ListItem8 } from "@transferwise/components";
1994
+ import { ListItem as ListItem7 } from "@transferwise/components";
1995
+
1996
+ // ../renderers/src/utils/listItem/getCTAControl.tsx
1997
+ import { ListItem as ListItem6 } from "@transferwise/components";
1998
+ import { jsx as jsx44 } from "react/jsx-runtime";
1999
+ var getCTAControl = (callToAction, { ctaSecondary, fullyInteractive }) => {
2000
+ if (!callToAction) {
2001
+ return void 0;
2002
+ }
2003
+ const { accessibilityDescription, title, context } = callToAction;
2004
+ const { priority, sentiment } = getPriorityAndSentiment(ctaSecondary, context);
2005
+ return /* @__PURE__ */ jsx44(
2006
+ ListItem6.Button,
2007
+ __spreadProps(__spreadValues({}, callToAction.getAnchorProps()), {
2008
+ partiallyInteractive: !fullyInteractive,
2009
+ priority,
2010
+ "aria-description": accessibilityDescription,
2011
+ sentiment,
2012
+ children: title
2013
+ })
2014
+ );
2015
+ };
2016
+ var getPriorityAndSentiment = (ctaSecondary, context) => {
2017
+ if (context === "negative") {
2018
+ return { priority: "secondary", sentiment: "negative" };
2019
+ }
2020
+ return { priority: ctaSecondary ? "secondary" : "secondary-neutral", sentiment: "default" };
2021
+ };
3298
2022
 
3299
2023
  // ../renderers/src/components/Header.tsx
3300
2024
  import { Header as DSHeader } from "@transferwise/components";
3301
- import { jsx as jsx53 } from "react/jsx-runtime";
3302
- var Header = ({ title, callToAction }) => (title || callToAction) && /* @__PURE__ */ jsx53(DSHeader, { title: title != null ? title : "", action: getHeaderAction(callToAction) });
2025
+ import { jsx as jsx45 } from "react/jsx-runtime";
2026
+ var Header5 = ({ title, callToAction }) => (title || callToAction) && /* @__PURE__ */ jsx45(DSHeader, { title: title != null ? title : "", action: getHeaderAction(callToAction) });
3303
2027
  var getHeaderAction = (callToAction) => {
3304
2028
  if (!callToAction) {
3305
2029
  return void 0;
@@ -3311,11 +2035,11 @@ var getHeaderAction = (callToAction) => {
3311
2035
  };
3312
2036
 
3313
2037
  // ../renderers/src/ListRenderer.tsx
3314
- import { jsx as jsx54, jsxs as jsxs13 } from "react/jsx-runtime";
2038
+ import { jsx as jsx46, jsxs as jsxs11 } from "react/jsx-runtime";
3315
2039
  var ListRenderer = {
3316
2040
  canRenderType: "list",
3317
- render: ({ callToAction, control, margin, items, tags, title }) => /* @__PURE__ */ jsxs13("div", { className: getMargin(margin), children: [
3318
- /* @__PURE__ */ jsx54(Header, { title, callToAction }),
2041
+ render: ({ callToAction, control, margin, items, tags, title }) => /* @__PURE__ */ jsxs11("div", { className: getMargin(margin), children: [
2042
+ /* @__PURE__ */ jsx46(Header5, { title, callToAction }),
3319
2043
  items.map((item) => {
3320
2044
  var _a, _b;
3321
2045
  const {
@@ -3332,8 +2056,8 @@ var ListRenderer = {
3332
2056
  ctaSecondary: (_a = itemTags == null ? void 0 : itemTags.includes("cta-secondary")) != null ? _a : false,
3333
2057
  fullyInteractive: (_b = (tags == null ? void 0 : tags.includes("fully-interactive")) && (additionalInfo == null ? void 0 : additionalInfo.onClick) == null) != null ? _b : false
3334
2058
  };
3335
- return /* @__PURE__ */ jsx54(
3336
- ListItem8,
2059
+ return /* @__PURE__ */ jsx46(
2060
+ ListItem7,
3337
2061
  {
3338
2062
  title: itemTitle,
3339
2063
  subtitle: description,
@@ -3353,10 +2077,10 @@ var ListRenderer_default = ListRenderer;
3353
2077
 
3354
2078
  // ../renderers/src/LoadingIndicatorRenderer.tsx
3355
2079
  import { Loader } from "@transferwise/components";
3356
- import { jsx as jsx55 } from "react/jsx-runtime";
2080
+ import { jsx as jsx47 } from "react/jsx-runtime";
3357
2081
  var LoadingIndicatorRenderer = {
3358
2082
  canRenderType: "loading-indicator",
3359
- render: ({ margin, size }) => /* @__PURE__ */ jsx55(
2083
+ render: ({ margin, size }) => /* @__PURE__ */ jsx47(
3360
2084
  Loader,
3361
2085
  {
3362
2086
  size,
@@ -3370,10 +2094,10 @@ var LoadingIndicatorRenderer_default = LoadingIndicatorRenderer;
3370
2094
  // ../renderers/src/MarkdownRenderer.tsx
3371
2095
  import { Markdown as Markdown3 } from "@transferwise/components";
3372
2096
  var import_classnames4 = __toESM(require_classnames());
3373
- import { jsx as jsx56 } from "react/jsx-runtime";
2097
+ import { jsx as jsx48 } from "react/jsx-runtime";
3374
2098
  var MarkdownRenderer = {
3375
2099
  canRenderType: "markdown",
3376
- render: ({ content, align, margin, size }) => /* @__PURE__ */ jsx56("div", { className: getTextAlignmentAndMargin({ align, margin }), children: /* @__PURE__ */ jsx56(
2100
+ render: ({ content, align, margin, size }) => /* @__PURE__ */ jsx48("div", { className: getTextAlignmentAndMargin({ align, margin }), children: /* @__PURE__ */ jsx48(
3377
2101
  Markdown3,
3378
2102
  {
3379
2103
  className: (0, import_classnames4.default)(
@@ -3388,16 +2112,16 @@ var MarkdownRenderer = {
3388
2112
  var MarkdownRenderer_default = MarkdownRenderer;
3389
2113
 
3390
2114
  // ../renderers/src/MediaRenderer.tsx
3391
- import { jsx as jsx57 } from "react/jsx-runtime";
2115
+ import { jsx as jsx49 } from "react/jsx-runtime";
3392
2116
  var MediaRenderer = {
3393
2117
  canRenderType: "media",
3394
2118
  render: (_a) => {
3395
2119
  var _b = _a, { media } = _b, rest = __objRest(_b, ["media"]);
3396
2120
  switch (media.type) {
3397
2121
  case "avatar":
3398
- return /* @__PURE__ */ jsx57(AvatarMediaRendererComponent, __spreadValues({ media }, rest));
2122
+ return /* @__PURE__ */ jsx49(AvatarMediaRendererComponent, __spreadValues({ media }, rest));
3399
2123
  case "image":
3400
- return /* @__PURE__ */ jsx57(ImageMediaRendererComponent, __spreadValues({ media }, rest));
2124
+ return /* @__PURE__ */ jsx49(ImageMediaRendererComponent, __spreadValues({ media }, rest));
3401
2125
  case "legacy":
3402
2126
  return null;
3403
2127
  }
@@ -3409,7 +2133,7 @@ var AvatarMediaRendererComponent = ({
3409
2133
  margin,
3410
2134
  size
3411
2135
  }) => {
3412
- return /* @__PURE__ */ jsx57("div", { className: `df-media-layout-avatar ${align} ${getMargin(margin)}`, children: /* @__PURE__ */ jsx57(Media, { media, size: mapAvatarMediaSize(size) }) });
2136
+ return /* @__PURE__ */ jsx49("div", { className: `df-media-layout-avatar ${align} ${getMargin(margin)}`, children: /* @__PURE__ */ jsx49(Media, { media, size: mapAvatarMediaSize(size) }) });
3413
2137
  };
3414
2138
  var ImageMediaRendererComponent = (_a) => {
3415
2139
  var _b = _a, {
@@ -3417,7 +2141,7 @@ var ImageMediaRendererComponent = (_a) => {
3417
2141
  } = _b, rest = __objRest(_b, [
3418
2142
  "media"
3419
2143
  ]);
3420
- return isUrnImage(media.uri) ? /* @__PURE__ */ jsx57(UrnImage, __spreadValues({ uri: media.uri, accessibilityDescription: media.accessibilityDescription }, rest)) : /* @__PURE__ */ jsx57(UrlImage, __spreadValues({ uri: media.uri, accessibilityDescription: media.accessibilityDescription }, rest));
2144
+ return isUrnImage(media.uri) ? /* @__PURE__ */ jsx49(UrnImage, __spreadValues({ uri: media.uri, accessibilityDescription: media.accessibilityDescription }, rest)) : /* @__PURE__ */ jsx49(UrlImage, __spreadValues({ uri: media.uri, accessibilityDescription: media.accessibilityDescription }, rest));
3421
2145
  };
3422
2146
  var mapAvatarMediaSize = (size) => {
3423
2147
  switch (size) {
@@ -3435,20 +2159,20 @@ var mapAvatarMediaSize = (size) => {
3435
2159
  };
3436
2160
 
3437
2161
  // ../renderers/src/ModalLayoutRenderer.tsx
3438
- import { Button as Button6, Modal as Modal2 } from "@transferwise/components";
3439
- import { useState as useState9 } from "react";
3440
- import { jsx as jsx58, jsxs as jsxs14 } from "react/jsx-runtime";
2162
+ import { Button as Button4, Modal as Modal2 } from "@transferwise/components";
2163
+ import { useState as useState8 } from "react";
2164
+ import { jsx as jsx50, jsxs as jsxs12 } from "react/jsx-runtime";
3441
2165
  var ModalLayoutRenderer = {
3442
2166
  canRenderType: "modal-layout",
3443
- render: (props) => /* @__PURE__ */ jsx58(DFModal, __spreadValues({}, props))
2167
+ render: (props) => /* @__PURE__ */ jsx50(DFModal, __spreadValues({}, props))
3444
2168
  };
3445
2169
  var ModalLayoutRenderer_default = ModalLayoutRenderer;
3446
2170
  function DFModal({ content, margin, trigger }) {
3447
- const [visible, setVisible] = useState9(false);
2171
+ const [visible, setVisible] = useState8(false);
3448
2172
  const { children, title } = content;
3449
- return /* @__PURE__ */ jsxs14("div", { className: getMargin(margin), children: [
3450
- /* @__PURE__ */ jsx58(Button6, { v2: true, priority: "tertiary", block: true, onClick: () => setVisible(true), children: trigger.title }),
3451
- /* @__PURE__ */ jsx58(
2173
+ return /* @__PURE__ */ jsxs12("div", { className: getMargin(margin), children: [
2174
+ /* @__PURE__ */ jsx50(Button4, { v2: true, priority: "tertiary", block: true, onClick: () => setVisible(true), children: trigger.title }),
2175
+ /* @__PURE__ */ jsx50(
3452
2176
  Modal2,
3453
2177
  {
3454
2178
  scroll: "content",
@@ -3464,19 +2188,19 @@ function DFModal({ content, margin, trigger }) {
3464
2188
 
3465
2189
  // ../renderers/src/ModalRenderer.tsx
3466
2190
  import { Modal as Modal3 } from "@transferwise/components";
3467
- import { jsx as jsx59 } from "react/jsx-runtime";
2191
+ import { jsx as jsx51 } from "react/jsx-runtime";
3468
2192
  var ModalRenderer = {
3469
2193
  canRenderType: "modal",
3470
2194
  render: ({ title, children, open, onClose }) => {
3471
- return /* @__PURE__ */ jsx59(Modal3, { open, title, body: children, onClose });
2195
+ return /* @__PURE__ */ jsx51(Modal3, { open, title, body: children, onClose });
3472
2196
  }
3473
2197
  };
3474
2198
 
3475
2199
  // ../renderers/src/MoneyInputRenderer.tsx
3476
2200
  import { MoneyInput } from "@transferwise/components";
3477
- import { useEffect as useEffect10 } from "react";
3478
- import { useIntl as useIntl7 } from "react-intl";
3479
- import { jsx as jsx60 } from "react/jsx-runtime";
2201
+ import { useEffect as useEffect8 } from "react";
2202
+ import { useIntl as useIntl6 } from "react-intl";
2203
+ import { jsx as jsx52 } from "react/jsx-runtime";
3480
2204
  var groupingTags2 = Object.keys(group_messages_default).filter((key) => key !== "all");
3481
2205
  var MoneyInputRenderer = {
3482
2206
  canRenderType: "money-input",
@@ -3497,13 +2221,13 @@ function MoneyInputRendererComponent(props) {
3497
2221
  onAmountChange,
3498
2222
  onCurrencyChange
3499
2223
  } = props;
3500
- useEffect10(() => {
2224
+ useEffect8(() => {
3501
2225
  if (!isValidIndex(selectedCurrencyIndex, currencies.length)) {
3502
2226
  onCurrencyChange(0);
3503
2227
  }
3504
2228
  }, [selectedCurrencyIndex, onCurrencyChange, currencies.length]);
3505
- const { formatMessage } = useIntl7();
3506
- return /* @__PURE__ */ jsx60(
2229
+ const { formatMessage } = useIntl6();
2230
+ return /* @__PURE__ */ jsx52(
3507
2231
  FieldInput_default,
3508
2232
  {
3509
2233
  id: uid,
@@ -3512,7 +2236,7 @@ function MoneyInputRendererComponent(props) {
3512
2236
  validation: validationState,
3513
2237
  help,
3514
2238
  features: props.features,
3515
- children: /* @__PURE__ */ jsx60(
2239
+ children: /* @__PURE__ */ jsx52(
3516
2240
  MoneyInput,
3517
2241
  {
3518
2242
  amount: parseFloatOrNull(amountValue),
@@ -3574,8 +2298,8 @@ function assertCurrencyCodeIsString(currencyCode) {
3574
2298
  }
3575
2299
 
3576
2300
  // ../renderers/src/MultiSelectInputRenderer/InlineComponent.tsx
3577
- import { ListItem as ListItem9 } from "@transferwise/components";
3578
- import { jsx as jsx61 } from "react/jsx-runtime";
2301
+ import { ListItem as ListItem8 } from "@transferwise/components";
2302
+ import { jsx as jsx53 } from "react/jsx-runtime";
3579
2303
  function InlineComponent(props) {
3580
2304
  const {
3581
2305
  id,
@@ -3589,7 +2313,7 @@ function InlineComponent(props) {
3589
2313
  validationState,
3590
2314
  onSelect
3591
2315
  } = props;
3592
- return /* @__PURE__ */ jsx61(
2316
+ return /* @__PURE__ */ jsx53(
3593
2317
  FieldInput_default,
3594
2318
  {
3595
2319
  id,
@@ -3611,8 +2335,8 @@ function InlineComponent(props) {
3611
2335
  childrenProps
3612
2336
  } = option;
3613
2337
  const key = (_a = childrenProps == null ? void 0 : childrenProps.uid) != null ? _a : index;
3614
- return /* @__PURE__ */ jsx61(
3615
- ListItem9,
2338
+ return /* @__PURE__ */ jsx53(
2339
+ ListItem8,
3616
2340
  {
3617
2341
  title: itemTitle,
3618
2342
  subtitle,
@@ -3620,10 +2344,10 @@ function InlineComponent(props) {
3620
2344
  valueSubtitle: supportingValues == null ? void 0 : supportingValues.subvalue,
3621
2345
  media: getMedia(media, false),
3622
2346
  prompt: getInlineAlert(inlineAlert),
3623
- additionalInfo: additionalText ? /* @__PURE__ */ jsx61(ListItem9.AdditionalInfo, { children: additionalText }) : void 0,
2347
+ additionalInfo: additionalText ? /* @__PURE__ */ jsx53(ListItem8.AdditionalInfo, { children: additionalText }) : void 0,
3624
2348
  disabled: disabled || optionDisabled,
3625
- control: /* @__PURE__ */ jsx61(
3626
- ListItem9.Checkbox,
2349
+ control: /* @__PURE__ */ jsx53(
2350
+ ListItem8.Checkbox,
3627
2351
  {
3628
2352
  checked: selectedIndices.includes(index),
3629
2353
  onChange: (e) => {
@@ -3642,12 +2366,12 @@ function InlineComponent(props) {
3642
2366
 
3643
2367
  // ../renderers/src/MultiSelectInputRenderer/DefaultComponent.tsx
3644
2368
  import { SelectInput, SelectInputOptionContent } from "@transferwise/components";
3645
- import { useState as useState10 } from "react";
3646
- import { useIntl as useIntl8 } from "react-intl";
2369
+ import { useState as useState9 } from "react";
2370
+ import { useIntl as useIntl7 } from "react-intl";
3647
2371
 
3648
2372
  // ../renderers/src/messages/multi-select.messages.ts
3649
- import { defineMessages as defineMessages7 } from "react-intl";
3650
- var multi_select_messages_default = defineMessages7({
2373
+ import { defineMessages as defineMessages6 } from "react-intl";
2374
+ var multi_select_messages_default = defineMessages6({
3651
2375
  summary: {
3652
2376
  id: "df.wise.MultiSelect.summary",
3653
2377
  defaultMessage: "{first} and {count} more",
@@ -3656,10 +2380,10 @@ var multi_select_messages_default = defineMessages7({
3656
2380
  });
3657
2381
 
3658
2382
  // ../renderers/src/MultiSelectInputRenderer/DefaultComponent.tsx
3659
- import { jsx as jsx62 } from "react/jsx-runtime";
2383
+ import { jsx as jsx54 } from "react/jsx-runtime";
3660
2384
  function DefaultComponent(props) {
3661
- const { formatMessage } = useIntl8();
3662
- const [stagedIndices, setStagedIndices] = useState10();
2385
+ const { formatMessage } = useIntl7();
2386
+ const [stagedIndices, setStagedIndices] = useState9();
3663
2387
  const {
3664
2388
  id,
3665
2389
  autoComplete,
@@ -3698,12 +2422,12 @@ function DefaultComponent(props) {
3698
2422
  const contentProps = {
3699
2423
  title: option.title,
3700
2424
  description: option.description,
3701
- icon: /* @__PURE__ */ jsx62(OptionMedia, { media: option.media, preferAvatar: false })
2425
+ icon: /* @__PURE__ */ jsx54(OptionMedia, { media: option.media, preferAvatar: false })
3702
2426
  };
3703
- return /* @__PURE__ */ jsx62(SelectInputOptionContent, __spreadValues({}, contentProps));
2427
+ return /* @__PURE__ */ jsx54(SelectInputOptionContent, __spreadValues({}, contentProps));
3704
2428
  };
3705
2429
  const extraProps = { autoComplete };
3706
- return /* @__PURE__ */ jsx62(
2430
+ return /* @__PURE__ */ jsx54(
3707
2431
  FieldInput_default,
3708
2432
  {
3709
2433
  id,
@@ -3712,7 +2436,7 @@ function DefaultComponent(props) {
3712
2436
  description,
3713
2437
  validation: validationState,
3714
2438
  features,
3715
- children: /* @__PURE__ */ jsx62(
2439
+ children: /* @__PURE__ */ jsx54(
3716
2440
  SelectInput,
3717
2441
  __spreadValues({
3718
2442
  id,
@@ -3752,7 +2476,7 @@ function DefaultComponent(props) {
3752
2476
 
3753
2477
  // ../renderers/src/MultiSelectInputRenderer/InlineCheckboxComponent.tsx
3754
2478
  import { Checkbox as Checkbox2 } from "@transferwise/components";
3755
- import { jsx as jsx63 } from "react/jsx-runtime";
2479
+ import { jsx as jsx55 } from "react/jsx-runtime";
3756
2480
  function InlineCheckboxComponent(props) {
3757
2481
  const {
3758
2482
  id,
@@ -3766,7 +2490,7 @@ function InlineCheckboxComponent(props) {
3766
2490
  validationState,
3767
2491
  onSelect
3768
2492
  } = props;
3769
- return /* @__PURE__ */ jsx63(
2493
+ return /* @__PURE__ */ jsx55(
3770
2494
  FieldInput_default,
3771
2495
  {
3772
2496
  id,
@@ -3795,24 +2519,24 @@ function InlineCheckboxComponent(props) {
3795
2519
  onSelect(newSelectedIndices);
3796
2520
  }
3797
2521
  };
3798
- return /* @__PURE__ */ jsx63(Checkbox2, __spreadProps(__spreadValues({}, checkboxProps), { className: "m-t-1" }), key);
2522
+ return /* @__PURE__ */ jsx55(Checkbox2, __spreadProps(__spreadValues({}, checkboxProps), { className: "m-t-1" }), key);
3799
2523
  })
3800
2524
  }
3801
2525
  );
3802
2526
  }
3803
2527
 
3804
2528
  // ../renderers/src/MultiSelectInputRenderer/MultiSelectInputRenderer.tsx
3805
- import { jsx as jsx64 } from "react/jsx-runtime";
2529
+ import { jsx as jsx56 } from "react/jsx-runtime";
3806
2530
  var MultiSelectInputRenderer = {
3807
2531
  canRenderType: "input-multi-select",
3808
2532
  render: (props) => {
3809
2533
  switch (props.control) {
3810
2534
  case "inline":
3811
- return /* @__PURE__ */ jsx64(InlineComponent, __spreadValues({}, props));
2535
+ return /* @__PURE__ */ jsx56(InlineComponent, __spreadValues({}, props));
3812
2536
  case "inline-checkbox-group":
3813
- return /* @__PURE__ */ jsx64(InlineCheckboxComponent, __spreadValues({}, props));
2537
+ return /* @__PURE__ */ jsx56(InlineCheckboxComponent, __spreadValues({}, props));
3814
2538
  default:
3815
- return /* @__PURE__ */ jsx64(DefaultComponent, __spreadValues({}, props));
2539
+ return /* @__PURE__ */ jsx56(DefaultComponent, __spreadValues({}, props));
3816
2540
  }
3817
2541
  }
3818
2542
  };
@@ -3823,7 +2547,7 @@ import { Status, UploadInput } from "@transferwise/components";
3823
2547
  // ../renderers/src/components/UploadFieldInput.tsx
3824
2548
  var import_classnames5 = __toESM(require_classnames());
3825
2549
  import { InlineAlert as InlineAlert2 } from "@transferwise/components";
3826
- import { jsx as jsx65, jsxs as jsxs15 } from "react/jsx-runtime";
2550
+ import { jsx as jsx57, jsxs as jsxs13 } from "react/jsx-runtime";
3827
2551
  function UploadFieldInput({
3828
2552
  id,
3829
2553
  children,
@@ -3833,10 +2557,10 @@ function UploadFieldInput({
3833
2557
  validation,
3834
2558
  features
3835
2559
  }) {
3836
- const labelContent = label && help ? /* @__PURE__ */ jsx65(LabelContentWithHelp, { text: label, help }) : label;
2560
+ const labelContent = label && help ? /* @__PURE__ */ jsx57(LabelContentWithHelp, { text: label, help }) : label;
3837
2561
  const descriptionId = description ? `${id}-description` : void 0;
3838
2562
  const { ref } = useScrollToError(validation, features);
3839
- return /* @__PURE__ */ jsxs15(
2563
+ return /* @__PURE__ */ jsxs13(
3840
2564
  "div",
3841
2565
  {
3842
2566
  ref,
@@ -3844,9 +2568,9 @@ function UploadFieldInput({
3844
2568
  "has-error": (validation == null ? void 0 : validation.status) === "invalid"
3845
2569
  }),
3846
2570
  children: [
3847
- /* @__PURE__ */ jsx65("label", { htmlFor: id, className: "control-label", children: labelContent }),
2571
+ /* @__PURE__ */ jsx57("label", { htmlFor: id, className: "control-label", children: labelContent }),
3848
2572
  children,
3849
- (validation == null ? void 0 : validation.status) === "invalid" && /* @__PURE__ */ jsx65(InlineAlert2, { type: "negative", id: descriptionId, children: validation.message })
2573
+ (validation == null ? void 0 : validation.status) === "invalid" && /* @__PURE__ */ jsx57(InlineAlert2, { type: "negative", id: descriptionId, children: validation.message })
3850
2574
  ]
3851
2575
  }
3852
2576
  );
@@ -3881,7 +2605,7 @@ var getSizeLimit = (maxSize) => {
3881
2605
  };
3882
2606
 
3883
2607
  // ../renderers/src/MultiUploadInputRenderer.tsx
3884
- import { jsx as jsx66 } from "react/jsx-runtime";
2608
+ import { jsx as jsx58 } from "react/jsx-runtime";
3885
2609
  var MultiUploadInputRenderer = {
3886
2610
  canRenderType: "input-upload-multi",
3887
2611
  render: (props) => {
@@ -3907,7 +2631,7 @@ var MultiUploadInputRenderer = {
3907
2631
  };
3908
2632
  const onDeleteFile = async (fileId) => onRemoveFile(value.findIndex((file) => file.id === fileId));
3909
2633
  const descriptionId = description ? `${id}-description` : void 0;
3910
- return /* @__PURE__ */ jsx66(
2634
+ return /* @__PURE__ */ jsx58(
3911
2635
  UploadFieldInput_default,
3912
2636
  {
3913
2637
  id,
@@ -3916,17 +2640,17 @@ var MultiUploadInputRenderer = {
3916
2640
  validation: validationState,
3917
2641
  help,
3918
2642
  features,
3919
- children: /* @__PURE__ */ jsx66(
2643
+ children: /* @__PURE__ */ jsx58(
3920
2644
  UploadInput,
3921
2645
  {
3922
2646
  id,
3923
2647
  "aria-describedby": descriptionId,
3924
2648
  description,
3925
2649
  disabled,
3926
- files: value.map(({ id: id2, file, validationState: validationState2 }) => ({
3927
- id: id2,
2650
+ files: value.map(({ id: fileId, file, validationState: fileValidationState }) => ({
2651
+ id: fileId,
3928
2652
  filename: file.name,
3929
- status: (validationState2 == null ? void 0 : validationState2.status) === "invalid" ? Status.FAILED : Status.SUCCEEDED
2653
+ status: (fileValidationState == null ? void 0 : fileValidationState.status) === "invalid" ? Status.FAILED : Status.SUCCEEDED
3930
2654
  })),
3931
2655
  fileTypes: acceptsToFileTypes(accepts),
3932
2656
  maxFiles: maxItems,
@@ -3944,8 +2668,8 @@ var MultiUploadInputRenderer = {
3944
2668
  var MultiUploadInputRenderer_default = MultiUploadInputRenderer;
3945
2669
 
3946
2670
  // ../renderers/src/NumberInputRenderer.tsx
3947
- import { Input as Input3, InputGroup as InputGroup3 } from "@transferwise/components";
3948
- import { jsx as jsx67 } from "react/jsx-runtime";
2671
+ import { Input as Input2, InputGroup as InputGroup2 } from "@transferwise/components";
2672
+ import { jsx as jsx59 } from "react/jsx-runtime";
3949
2673
  var NumberInputRenderer = {
3950
2674
  canRenderType: "input-number",
3951
2675
  render: (props) => {
@@ -3959,7 +2683,7 @@ var NumberInputRenderer = {
3959
2683
  "maximum",
3960
2684
  "minimum"
3961
2685
  );
3962
- return /* @__PURE__ */ jsx67(
2686
+ return /* @__PURE__ */ jsx59(
3963
2687
  FieldInput_default,
3964
2688
  {
3965
2689
  id,
@@ -3970,8 +2694,8 @@ var NumberInputRenderer = {
3970
2694
  loadingState: props.fieldLoadingState,
3971
2695
  help,
3972
2696
  features: props.features,
3973
- children: /* @__PURE__ */ jsx67(InputGroup3, { addonStart: getInputGroupAddonStart(media), children: /* @__PURE__ */ jsx67(
3974
- Input3,
2697
+ children: /* @__PURE__ */ jsx59(InputGroup2, { addonStart: getInputGroupAddonStart(media), children: /* @__PURE__ */ jsx59(
2698
+ Input2,
3975
2699
  __spreadValues({
3976
2700
  id,
3977
2701
  name: id,
@@ -3991,7 +2715,7 @@ var NumberInputRenderer = {
3991
2715
  var NumberInputRenderer_default = NumberInputRenderer;
3992
2716
 
3993
2717
  // ../renderers/src/ParagraphRenderer.tsx
3994
- import { useIntl as useIntl9 } from "react-intl";
2718
+ import { useIntl as useIntl8 } from "react-intl";
3995
2719
 
3996
2720
  // ../renderers/src/hooks/useSnackBarIfAvailable.ts
3997
2721
  import { SnackbarContext } from "@transferwise/components";
@@ -4004,11 +2728,11 @@ function useSnackBarIfAvailable() {
4004
2728
 
4005
2729
  // ../renderers/src/ParagraphRenderer.tsx
4006
2730
  var import_classnames6 = __toESM(require_classnames());
4007
- import { Button as Button7, Input as Input4 } from "@transferwise/components";
2731
+ import { Button as Button5, Input as Input3 } from "@transferwise/components";
4008
2732
 
4009
2733
  // ../renderers/src/messages/paragraph.messages.ts
4010
- import { defineMessages as defineMessages8 } from "react-intl";
4011
- var paragraph_messages_default = defineMessages8({
2734
+ import { defineMessages as defineMessages7 } from "react-intl";
2735
+ var paragraph_messages_default = defineMessages7({
4012
2736
  copy: {
4013
2737
  id: "df.wise.DynamicParagraph.copy",
4014
2738
  defaultMessage: "Copy",
@@ -4022,14 +2746,14 @@ var paragraph_messages_default = defineMessages8({
4022
2746
  });
4023
2747
 
4024
2748
  // ../renderers/src/ParagraphRenderer.tsx
4025
- import { jsx as jsx68, jsxs as jsxs16 } from "react/jsx-runtime";
2749
+ import { jsx as jsx60, jsxs as jsxs14 } from "react/jsx-runtime";
4026
2750
  var ParagraphRenderer = {
4027
2751
  canRenderType: "paragraph",
4028
- render: (props) => /* @__PURE__ */ jsx68(Paragraph, __spreadValues({}, props))
2752
+ render: (props) => /* @__PURE__ */ jsx60(Paragraph, __spreadValues({}, props))
4029
2753
  };
4030
2754
  function Paragraph({ align, control, margin, size, text }) {
4031
2755
  const className = getTextAlignmentAndMargin({ align, margin });
4032
- return control === "copyable" ? /* @__PURE__ */ jsx68(CopyableParagraph, { className, align, text }) : /* @__PURE__ */ jsx68(
2756
+ return control === "copyable" ? /* @__PURE__ */ jsx60(CopyableParagraph, { className, align, text }) : /* @__PURE__ */ jsx60(
4033
2757
  "p",
4034
2758
  {
4035
2759
  className: `${["xs", "sm"].includes(size) ? "np-text-body-default" : "np-text-body-large"} ${className}`,
@@ -4042,16 +2766,16 @@ function CopyableParagraph({
4042
2766
  align,
4043
2767
  className
4044
2768
  }) {
4045
- const { formatMessage } = useIntl9();
2769
+ const { formatMessage } = useIntl8();
4046
2770
  const createSnackbar = useSnackBarIfAvailable();
4047
2771
  const copy = () => {
4048
2772
  navigator.clipboard.writeText(text).then(() => createSnackbar({ text: formatMessage(paragraph_messages_default.copied) })).catch(() => {
4049
2773
  });
4050
2774
  };
4051
2775
  const inputAlignmentClasses = getTextAlignmentAndMargin({ align, margin: "sm" });
4052
- return /* @__PURE__ */ jsxs16("div", { className, children: [
4053
- /* @__PURE__ */ jsx68(
4054
- Input4,
2776
+ return /* @__PURE__ */ jsxs14("div", { className, children: [
2777
+ /* @__PURE__ */ jsx60(
2778
+ Input3,
4055
2779
  {
4056
2780
  type: "text",
4057
2781
  value: text,
@@ -4059,23 +2783,23 @@ function CopyableParagraph({
4059
2783
  className: (0, import_classnames6.default)("text-ellipsis", inputAlignmentClasses)
4060
2784
  }
4061
2785
  ),
4062
- /* @__PURE__ */ jsx68(Button7, { v2: true, block: true, onClick: copy, children: formatMessage(paragraph_messages_default.copy) })
2786
+ /* @__PURE__ */ jsx60(Button5, { v2: true, block: true, onClick: copy, children: formatMessage(paragraph_messages_default.copy) })
4063
2787
  ] });
4064
2788
  }
4065
2789
  var ParagraphRenderer_default = ParagraphRenderer;
4066
2790
 
4067
2791
  // ../renderers/src/ProgressRenderer.tsx
4068
2792
  import { ProgressBar } from "@transferwise/components";
4069
- import { jsx as jsx69 } from "react/jsx-runtime";
2793
+ import { jsx as jsx61 } from "react/jsx-runtime";
4070
2794
  var ProgressRenderer = {
4071
2795
  canRenderType: "progress",
4072
2796
  render: ({ uid, title, help, progress, progressText, margin, description }) => {
4073
- return /* @__PURE__ */ jsx69(
2797
+ return /* @__PURE__ */ jsx61(
4074
2798
  ProgressBar,
4075
2799
  {
4076
2800
  id: uid,
4077
2801
  className: getMargin(margin),
4078
- title: title && help ? /* @__PURE__ */ jsx69(LabelContentWithHelp, { text: title, help }) : title,
2802
+ title: title && help ? /* @__PURE__ */ jsx61(LabelContentWithHelp, { text: title, help }) : title,
4079
2803
  description,
4080
2804
  progress: {
4081
2805
  max: 1,
@@ -4089,14 +2813,14 @@ var ProgressRenderer = {
4089
2813
 
4090
2814
  // ../renderers/src/RepeatableRenderer.tsx
4091
2815
  var import_classnames7 = __toESM(require_classnames());
4092
- import { Button as Button8, Header as Header6, InlineAlert as InlineAlert3, Modal as Modal4, NavigationOption } from "@transferwise/components";
2816
+ import { Button as Button6, Header as Header6, InlineAlert as InlineAlert3, Modal as Modal4, NavigationOption } from "@transferwise/components";
4093
2817
  import { Plus } from "@transferwise/icons";
4094
- import { useState as useState11 } from "react";
4095
- import { useIntl as useIntl10 } from "react-intl";
2818
+ import { useState as useState10 } from "react";
2819
+ import { useIntl as useIntl9 } from "react-intl";
4096
2820
 
4097
2821
  // ../renderers/src/messages/repeatable.messages.ts
4098
- import { defineMessages as defineMessages9 } from "react-intl";
4099
- var repeatable_messages_default = defineMessages9({
2822
+ import { defineMessages as defineMessages8 } from "react-intl";
2823
+ var repeatable_messages_default = defineMessages8({
4100
2824
  addItemTitle: {
4101
2825
  id: "df.wise.ArraySchema.addItemTitle",
4102
2826
  defaultMessage: "Add Item",
@@ -4120,10 +2844,10 @@ var repeatable_messages_default = defineMessages9({
4120
2844
  });
4121
2845
 
4122
2846
  // ../renderers/src/RepeatableRenderer.tsx
4123
- import { Fragment as Fragment7, jsx as jsx70, jsxs as jsxs17 } from "react/jsx-runtime";
2847
+ import { Fragment as Fragment6, jsx as jsx62, jsxs as jsxs15 } from "react/jsx-runtime";
4124
2848
  var RepeatableRenderer = {
4125
2849
  canRenderType: "repeatable",
4126
- render: (props) => /* @__PURE__ */ jsx70(Repeatable, __spreadValues({}, props))
2850
+ render: (props) => /* @__PURE__ */ jsx62(Repeatable, __spreadValues({}, props))
4127
2851
  };
4128
2852
  function Repeatable(props) {
4129
2853
  const {
@@ -4140,8 +2864,8 @@ function Repeatable(props) {
4140
2864
  onSave,
4141
2865
  onRemove
4142
2866
  } = props;
4143
- const { formatMessage } = useIntl10();
4144
- const [openModalType, setOpenModalType] = useState11(null);
2867
+ const { formatMessage } = useIntl9();
2868
+ const [openModalType, setOpenModalType] = useState10(null);
4145
2869
  const { ref } = useScrollToError(validationState, features);
4146
2870
  const onAddItem = () => {
4147
2871
  onAdd();
@@ -4164,43 +2888,43 @@ function Repeatable(props) {
4164
2888
  const onCancelEdit = () => {
4165
2889
  setOpenModalType(null);
4166
2890
  };
4167
- return /* @__PURE__ */ jsxs17(Fragment7, { children: [
4168
- /* @__PURE__ */ jsxs17("div", { ref, children: [
4169
- title && /* @__PURE__ */ jsx70(Header6, { title }),
4170
- description && /* @__PURE__ */ jsx70("p", { children: description }),
4171
- /* @__PURE__ */ jsxs17(
2891
+ return /* @__PURE__ */ jsxs15(Fragment6, { children: [
2892
+ /* @__PURE__ */ jsxs15("div", { ref, children: [
2893
+ title && /* @__PURE__ */ jsx62(Header6, { title }),
2894
+ description && /* @__PURE__ */ jsx62("p", { children: description }),
2895
+ /* @__PURE__ */ jsxs15(
4172
2896
  "div",
4173
2897
  {
4174
2898
  className: (0, import_classnames7.default)("form-group", {
4175
2899
  "has-error": (validationState == null ? void 0 : validationState.status) === "invalid"
4176
2900
  }),
4177
2901
  children: [
4178
- items == null ? void 0 : items.map((item, index) => /* @__PURE__ */ jsx70(ItemSummaryOption, { item, onClick: () => onEditItem(index) }, item.id)),
4179
- /* @__PURE__ */ jsx70(
2902
+ items == null ? void 0 : items.map((item, index) => /* @__PURE__ */ jsx62(ItemSummaryOption, { item, onClick: () => onEditItem(index) }, item.id)),
2903
+ /* @__PURE__ */ jsx62(
4180
2904
  NavigationOption,
4181
2905
  {
4182
- media: /* @__PURE__ */ jsx70(Plus, {}),
2906
+ media: /* @__PURE__ */ jsx62(Plus, {}),
4183
2907
  title: addItemTitle || formatMessage(repeatable_messages_default.addItemTitle),
4184
2908
  showMediaAtAllSizes: true,
4185
2909
  onClick: () => onAddItem()
4186
2910
  }
4187
2911
  ),
4188
- (validationState == null ? void 0 : validationState.status) === "invalid" && /* @__PURE__ */ jsx70(InlineAlert3, { type: "negative", children: validationState.message })
2912
+ (validationState == null ? void 0 : validationState.status) === "invalid" && /* @__PURE__ */ jsx62(InlineAlert3, { type: "negative", children: validationState.message })
4189
2913
  ]
4190
2914
  }
4191
2915
  )
4192
2916
  ] }),
4193
- /* @__PURE__ */ jsx70(
2917
+ /* @__PURE__ */ jsx62(
4194
2918
  Modal4,
4195
2919
  {
4196
2920
  open: openModalType !== null,
4197
2921
  title: (openModalType === "add" ? addItemTitle : editItemTitle) || formatMessage(repeatable_messages_default.addItemTitle),
4198
- body: /* @__PURE__ */ jsxs17(Fragment7, { children: [
4199
- /* @__PURE__ */ jsx70("div", { className: "m-b-2", children: editableItem }),
4200
- /* @__PURE__ */ jsxs17("div", { children: [
4201
- /* @__PURE__ */ jsx70(Button8, { priority: "primary", block: true, className: "m-b-2", onClick: () => onSaveItem(), children: formatMessage(repeatable_messages_default.addItem) }),
4202
- /* @__PURE__ */ jsx70(
4203
- Button8,
2922
+ body: /* @__PURE__ */ jsxs15(Fragment6, { children: [
2923
+ /* @__PURE__ */ jsx62("div", { className: "m-b-2", children: editableItem }),
2924
+ /* @__PURE__ */ jsxs15("div", { children: [
2925
+ /* @__PURE__ */ jsx62(Button6, { priority: "primary", block: true, className: "m-b-2", onClick: () => onSaveItem(), children: formatMessage(repeatable_messages_default.addItem) }),
2926
+ /* @__PURE__ */ jsx62(
2927
+ Button6,
4204
2928
  {
4205
2929
  v2: true,
4206
2930
  priority: "secondary",
@@ -4221,10 +2945,10 @@ function ItemSummaryOption({
4221
2945
  item,
4222
2946
  onClick
4223
2947
  }) {
4224
- return /* @__PURE__ */ jsx70(
2948
+ return /* @__PURE__ */ jsx62(
4225
2949
  NavigationOption,
4226
2950
  {
4227
- media: /* @__PURE__ */ jsx70(OptionMedia, { media: item.media, preferAvatar: false }),
2951
+ media: /* @__PURE__ */ jsx62(OptionMedia, { media: item.media, preferAvatar: false }),
4228
2952
  title: item.title,
4229
2953
  content: item.description,
4230
2954
  showMediaAtAllSizes: true,
@@ -4237,14 +2961,14 @@ var RepeatableRenderer_default = RepeatableRenderer;
4237
2961
 
4238
2962
  // ../renderers/src/ReviewLegacyRenderer.tsx
4239
2963
  import { DefinitionList } from "@transferwise/components";
4240
- import { Fragment as Fragment8, jsx as jsx71, jsxs as jsxs18 } from "react/jsx-runtime";
2964
+ import { Fragment as Fragment7, jsx as jsx63, jsxs as jsxs16 } from "react/jsx-runtime";
4241
2965
  var ReviewRenderer = {
4242
2966
  canRenderType: "review",
4243
2967
  render: ({ callToAction, control, fields, margin, title, trackEvent }) => {
4244
2968
  const orientation = mapControlToDefinitionListLayout(control);
4245
- return /* @__PURE__ */ jsxs18("div", { className: getMargin(margin), children: [
4246
- /* @__PURE__ */ jsx71(Header, { title, callToAction }),
4247
- /* @__PURE__ */ jsx71("div", { className: margin, children: /* @__PURE__ */ jsx71(
2969
+ return /* @__PURE__ */ jsxs16("div", { className: getMargin(margin), children: [
2970
+ /* @__PURE__ */ jsx63(Header5, { title, callToAction }),
2971
+ /* @__PURE__ */ jsx63("div", { className: margin, children: /* @__PURE__ */ jsx63(
4248
2972
  DefinitionList,
4249
2973
  {
4250
2974
  layout: orientation,
@@ -4282,20 +3006,20 @@ var mapControlToDefinitionListLayout = (control) => {
4282
3006
  };
4283
3007
  var getFieldLabel = (label, help, onClick) => {
4284
3008
  if (help) {
4285
- return /* @__PURE__ */ jsxs18(Fragment8, { children: [
3009
+ return /* @__PURE__ */ jsxs16(Fragment7, { children: [
4286
3010
  label,
4287
3011
  " ",
4288
- /* @__PURE__ */ jsx71(Help_default, { help, onClick })
3012
+ /* @__PURE__ */ jsx63(Help_default, { help, onClick })
4289
3013
  ] });
4290
3014
  }
4291
3015
  return label;
4292
3016
  };
4293
3017
 
4294
3018
  // ../renderers/src/ReviewRenderer.tsx
4295
- import { ListItem as ListItem10, Markdown as Markdown4, Popover } from "@transferwise/components";
3019
+ import { ListItem as ListItem9, Markdown as Markdown4, Popover } from "@transferwise/components";
4296
3020
  import { QuestionMarkCircle } from "@transferwise/icons";
4297
- import { useIntl as useIntl11 } from "react-intl";
4298
- import { jsx as jsx72, jsxs as jsxs19 } from "react/jsx-runtime";
3021
+ import { useIntl as useIntl10 } from "react-intl";
3022
+ import { jsx as jsx64, jsxs as jsxs17 } from "react/jsx-runtime";
4299
3023
  var IGNORED_CONTROLS = [
4300
3024
  "horizontal",
4301
3025
  "horizontal-end-aligned",
@@ -4305,7 +3029,7 @@ var IGNORED_CONTROLS = [
4305
3029
  var ReviewRenderer2 = {
4306
3030
  canRenderType: "review",
4307
3031
  canRender: ({ control }) => control ? !IGNORED_CONTROLS.includes(control) : true,
4308
- render: (props) => /* @__PURE__ */ jsx72(Review, __spreadValues({}, props))
3032
+ render: (props) => /* @__PURE__ */ jsx64(Review, __spreadValues({}, props))
4309
3033
  };
4310
3034
  var Review = ({
4311
3035
  callToAction,
@@ -4316,9 +3040,9 @@ var Review = ({
4316
3040
  title,
4317
3041
  trackEvent
4318
3042
  }) => {
4319
- const intl = useIntl11();
4320
- return /* @__PURE__ */ jsxs19("div", { className: getMargin(margin), children: [
4321
- /* @__PURE__ */ jsx72(Header, { title, callToAction }),
3043
+ const intl = useIntl10();
3044
+ return /* @__PURE__ */ jsxs17("div", { className: getMargin(margin), children: [
3045
+ /* @__PURE__ */ jsx64(Header5, { title, callToAction }),
4322
3046
  fields.map((field) => {
4323
3047
  var _a, _b, _c;
4324
3048
  const {
@@ -4336,8 +3060,8 @@ var Review = ({
4336
3060
  ctaSecondary: (_a = itemTags == null ? void 0 : itemTags.includes("cta-secondary")) != null ? _a : false,
4337
3061
  fullyInteractive: (_b = (tags == null ? void 0 : tags.includes("fully-interactive")) && (additionalInfo == null ? void 0 : additionalInfo.onClick) == null) != null ? _b : false
4338
3062
  };
4339
- return /* @__PURE__ */ jsx72(
4340
- ListItem10,
3063
+ return /* @__PURE__ */ jsx64(
3064
+ ListItem9,
4341
3065
  {
4342
3066
  title: value,
4343
3067
  subtitle: label,
@@ -4357,18 +3081,18 @@ var Review = ({
4357
3081
  ] });
4358
3082
  };
4359
3083
  var getHelpControl = (help, ariaLabel, onClick) => {
4360
- return /* @__PURE__ */ jsx72(Popover, { content: /* @__PURE__ */ jsx72(Markdown4, { config: { link: { target: "_blank" } }, children: help }), children: /* @__PURE__ */ jsx72(ListItem10.IconButton, { partiallyInteractive: true, "aria-label": ariaLabel, onClick, children: /* @__PURE__ */ jsx72(QuestionMarkCircle, {}) }) });
3084
+ return /* @__PURE__ */ jsx64(Popover, { content: /* @__PURE__ */ jsx64(Markdown4, { config: { link: { target: "_blank" } }, children: help }), children: /* @__PURE__ */ jsx64(ListItem9.IconButton, { partiallyInteractive: true, "aria-label": ariaLabel, onClick, children: /* @__PURE__ */ jsx64(QuestionMarkCircle, {}) }) });
4361
3085
  };
4362
3086
  var ReviewRenderer_default = ReviewRenderer2;
4363
3087
 
4364
3088
  // ../renderers/src/SearchRenderer/BlockSearchRendererComponent.tsx
4365
- import { Input as Input5, InputGroup as InputGroup4, List, ListItem as ListItem11, Markdown as Markdown5 } from "@transferwise/components";
4366
- import { useState as useState12 } from "react";
4367
- import { useIntl as useIntl13 } from "react-intl";
3089
+ import { Input as Input4, InputGroup as InputGroup3, List, ListItem as ListItem10, Markdown as Markdown5 } from "@transferwise/components";
3090
+ import { useState as useState11 } from "react";
3091
+ import { useIntl as useIntl12 } from "react-intl";
4368
3092
 
4369
3093
  // ../renderers/src/messages/search.messages.ts
4370
- import { defineMessages as defineMessages10 } from "react-intl";
4371
- var search_messages_default = defineMessages10({
3094
+ import { defineMessages as defineMessages9 } from "react-intl";
3095
+ var search_messages_default = defineMessages9({
4372
3096
  loading: {
4373
3097
  id: "df.wise.SearchLayout.loading",
4374
3098
  defaultMessage: "Loading...",
@@ -4377,11 +3101,11 @@ var search_messages_default = defineMessages10({
4377
3101
  });
4378
3102
 
4379
3103
  // ../renderers/src/SearchRenderer/ErrorResult.tsx
4380
- import { useIntl as useIntl12 } from "react-intl";
3104
+ import { useIntl as useIntl11 } from "react-intl";
4381
3105
 
4382
3106
  // ../renderers/src/messages/generic-error.messages.ts
4383
- import { defineMessages as defineMessages11 } from "react-intl";
4384
- var generic_error_messages_default = defineMessages11({
3107
+ import { defineMessages as defineMessages10 } from "react-intl";
3108
+ var generic_error_messages_default = defineMessages10({
4385
3109
  genericErrorRetryHint: {
4386
3110
  id: "df.wise.PersistAsyncSchema.genericError",
4387
3111
  defaultMessage: "Something went wrong, please try again.",
@@ -4400,20 +3124,20 @@ var generic_error_messages_default = defineMessages11({
4400
3124
  });
4401
3125
 
4402
3126
  // ../renderers/src/SearchRenderer/ErrorResult.tsx
4403
- import { Link } from "@transferwise/components";
4404
- import { jsx as jsx73, jsxs as jsxs20 } from "react/jsx-runtime";
3127
+ import { Link as DSLink } from "@transferwise/components";
3128
+ import { jsx as jsx65, jsxs as jsxs18 } from "react/jsx-runtime";
4405
3129
  function ErrorResult({ state }) {
4406
- const intl = useIntl12();
4407
- return /* @__PURE__ */ jsxs20("p", { className: "m-t-2", children: [
3130
+ const intl = useIntl11();
3131
+ return /* @__PURE__ */ jsxs18("p", { className: "m-t-2", children: [
4408
3132
  intl.formatMessage(generic_error_messages_default.genericError),
4409
3133
  "\xA0",
4410
- /* @__PURE__ */ jsx73(Link, { onClick: () => state.onRetry(), children: intl.formatMessage(generic_error_messages_default.retry) })
3134
+ /* @__PURE__ */ jsx65(DSLink, { onClick: () => state.onRetry(), children: intl.formatMessage(generic_error_messages_default.retry) })
4411
3135
  ] });
4412
3136
  }
4413
3137
 
4414
3138
  // ../renderers/src/SearchRenderer/BlockSearchRendererComponent.tsx
4415
- import { Search as Search2 } from "@transferwise/icons";
4416
- import { Fragment as Fragment9, jsx as jsx74, jsxs as jsxs21 } from "react/jsx-runtime";
3139
+ import { Search } from "@transferwise/icons";
3140
+ import { Fragment as Fragment8, jsx as jsx66, jsxs as jsxs19 } from "react/jsx-runtime";
4417
3141
  function BlockSearchRendererComponent({
4418
3142
  id,
4419
3143
  hint,
@@ -4426,10 +3150,10 @@ function BlockSearchRendererComponent({
4426
3150
  trackEvent,
4427
3151
  onChange
4428
3152
  }) {
4429
- const [hasSearched, setHasSearched] = useState12(false);
4430
- const { formatMessage } = useIntl13();
4431
- return /* @__PURE__ */ jsxs21("div", { className: getMargin(margin), children: [
4432
- /* @__PURE__ */ jsx74(
3153
+ const [hasSearched, setHasSearched] = useState11(false);
3154
+ const { formatMessage } = useIntl12();
3155
+ return /* @__PURE__ */ jsxs19("div", { className: getMargin(margin), children: [
3156
+ /* @__PURE__ */ jsx66(
4433
3157
  FieldInput_default,
4434
3158
  {
4435
3159
  id,
@@ -4438,12 +3162,13 @@ function BlockSearchRendererComponent({
4438
3162
  help: "",
4439
3163
  label: title,
4440
3164
  features,
4441
- children: /* @__PURE__ */ jsx74(InputGroup4, { addonStart: { content: /* @__PURE__ */ jsx74(Search2, { size: 24 }) }, children: /* @__PURE__ */ jsx74(
4442
- Input5,
3165
+ children: /* @__PURE__ */ jsx66(InputGroup3, { addonStart: { content: /* @__PURE__ */ jsx66(Search, { size: 24 }) }, children: /* @__PURE__ */ jsx66(
3166
+ Input4,
4443
3167
  {
4444
3168
  id,
4445
3169
  name: id,
4446
3170
  placeholder: hint,
3171
+ shape: "pill",
4447
3172
  type: "text",
4448
3173
  value: query,
4449
3174
  onChange: ({ currentTarget: { value } }) => {
@@ -4457,7 +3182,7 @@ function BlockSearchRendererComponent({
4457
3182
  ) })
4458
3183
  }
4459
3184
  ),
4460
- isLoading ? /* @__PURE__ */ jsx74("span", { children: formatMessage(search_messages_default.loading) }) : /* @__PURE__ */ jsx74(SearchResultContent, { state, trackEvent })
3185
+ isLoading ? /* @__PURE__ */ jsx66("span", { children: formatMessage(search_messages_default.loading) }) : /* @__PURE__ */ jsx66(SearchResultContent, { state, trackEvent })
4461
3186
  ] });
4462
3187
  }
4463
3188
  function SearchResultContent({
@@ -4466,39 +3191,39 @@ function SearchResultContent({
4466
3191
  }) {
4467
3192
  switch (state.type) {
4468
3193
  case "error":
4469
- return /* @__PURE__ */ jsx74(ErrorResult, { state });
3194
+ return /* @__PURE__ */ jsx66(ErrorResult, { state });
4470
3195
  case "results":
4471
- return /* @__PURE__ */ jsx74(SearchResults, { state, trackEvent });
3196
+ return /* @__PURE__ */ jsx66(SearchResults, { state, trackEvent });
4472
3197
  case "layout":
4473
- return /* @__PURE__ */ jsxs21(Fragment9, { children: [
3198
+ return /* @__PURE__ */ jsxs19(Fragment8, { children: [
4474
3199
  " ",
4475
3200
  state.layout,
4476
3201
  " "
4477
3202
  ] });
4478
3203
  case "noResults":
4479
- return /* @__PURE__ */ jsx74(EmptySearchResult, { state });
3204
+ return /* @__PURE__ */ jsx66(EmptySearchResult, { state });
4480
3205
  case "pending":
4481
3206
  default:
4482
3207
  return null;
4483
3208
  }
4484
3209
  }
4485
3210
  function EmptySearchResult({ state }) {
4486
- return /* @__PURE__ */ jsx74(Markdown5, { className: "m-t-2", config: { link: { target: "_blank" } }, children: state.message });
3211
+ return /* @__PURE__ */ jsx66(Markdown5, { className: "m-t-2", config: { link: { target: "_blank" } }, children: state.message });
4487
3212
  }
4488
3213
  function SearchResults({
4489
3214
  state,
4490
3215
  trackEvent
4491
3216
  }) {
4492
- return /* @__PURE__ */ jsx74(List, { children: state.results.map((result) => {
3217
+ return /* @__PURE__ */ jsx66(List, { children: state.results.map((result) => {
4493
3218
  const { media } = result;
4494
- return /* @__PURE__ */ jsx74(
4495
- ListItem11,
3219
+ return /* @__PURE__ */ jsx66(
3220
+ ListItem10,
4496
3221
  {
4497
3222
  title: result.title,
4498
3223
  subtitle: result.description,
4499
- media: media ? /* @__PURE__ */ jsx74(OptionMedia, { media, preferAvatar: false }) : void 0,
4500
- control: /* @__PURE__ */ jsx74(
4501
- ListItem11.Navigation,
3224
+ media: media ? /* @__PURE__ */ jsx66(OptionMedia, { media, preferAvatar: false }) : void 0,
3225
+ control: /* @__PURE__ */ jsx66(
3226
+ ListItem10.Navigation,
4502
3227
  {
4503
3228
  onClick: () => {
4504
3229
  trackEvent("Search Result Selected", __spreadValues({
@@ -4517,10 +3242,10 @@ var BlockSearchRendererComponent_default = BlockSearchRendererComponent;
4517
3242
 
4518
3243
  // ../renderers/src/SearchRenderer/InlineSearchRendererComponent.tsx
4519
3244
  import { Markdown as Markdown6, Typeahead } from "@transferwise/components";
4520
- import { Search as Search3 } from "@transferwise/icons";
4521
- import { useState as useState13 } from "react";
4522
- import { useIntl as useIntl14 } from "react-intl";
4523
- import { jsx as jsx75 } from "react/jsx-runtime";
3245
+ import { Search as Search2 } from "@transferwise/icons";
3246
+ import { useState as useState12 } from "react";
3247
+ import { useIntl as useIntl13 } from "react-intl";
3248
+ import { jsx as jsx67 } from "react/jsx-runtime";
4524
3249
  function InlineSearchRenderer({
4525
3250
  id,
4526
3251
  hint,
@@ -4532,9 +3257,9 @@ function InlineSearchRenderer({
4532
3257
  onChange,
4533
3258
  trackEvent
4534
3259
  }) {
4535
- const [hasSearched, setHasSearched] = useState13(false);
4536
- const intl = useIntl14();
4537
- return /* @__PURE__ */ jsx75("div", { className: getMargin(margin), children: /* @__PURE__ */ jsx75(
3260
+ const [hasSearched, setHasSearched] = useState12(false);
3261
+ const intl = useIntl13();
3262
+ return /* @__PURE__ */ jsx67("div", { className: getMargin(margin), children: /* @__PURE__ */ jsx67(
4538
3263
  FieldInput_default,
4539
3264
  {
4540
3265
  id,
@@ -4543,7 +3268,7 @@ function InlineSearchRenderer({
4543
3268
  help: "",
4544
3269
  label: title,
4545
3270
  features,
4546
- children: /* @__PURE__ */ jsx75(
3271
+ children: /* @__PURE__ */ jsx67(
4547
3272
  Typeahead,
4548
3273
  {
4549
3274
  id: "typeahead-input-id",
@@ -4552,10 +3277,10 @@ function InlineSearchRenderer({
4552
3277
  size: "md",
4553
3278
  placeholder: hint,
4554
3279
  maxHeight: 100,
4555
- footer: /* @__PURE__ */ jsx75(TypeaheadFooter, { state, isLoading }),
3280
+ footer: /* @__PURE__ */ jsx67(TypeaheadFooter, { state, isLoading }),
4556
3281
  multiple: false,
4557
3282
  clearable: false,
4558
- addon: /* @__PURE__ */ jsx75(Search3, { size: 24 }),
3283
+ addon: /* @__PURE__ */ jsx67(Search2, { size: 24 }),
4559
3284
  options: state.type === "results" ? state.results.map(mapResultToTypeaheadOption) : [],
4560
3285
  minQueryLength: 1,
4561
3286
  onChange: (values) => {
@@ -4592,28 +3317,28 @@ function mapResultToTypeaheadOption(result) {
4592
3317
  };
4593
3318
  }
4594
3319
  function TypeaheadFooter({ state, isLoading }) {
4595
- const { formatMessage } = useIntl14();
3320
+ const { formatMessage } = useIntl13();
4596
3321
  if (state.type === "layout") {
4597
- return /* @__PURE__ */ jsx75("div", { className: "m-x-1 m-y-1", children: state.layout });
3322
+ return /* @__PURE__ */ jsx67("div", { className: "m-x-1 m-y-1", children: state.layout });
4598
3323
  }
4599
3324
  if (state.type === "noResults") {
4600
- return /* @__PURE__ */ jsx75(Markdown6, { className: "m-t-2 m-x-2", config: { link: { target: "_blank" } }, children: state.message });
3325
+ return /* @__PURE__ */ jsx67(Markdown6, { className: "m-t-2 m-x-2", config: { link: { target: "_blank" } }, children: state.message });
4601
3326
  }
4602
3327
  if (state.type === "error") {
4603
- return /* @__PURE__ */ jsx75("div", { className: "m-t-2 m-x-2", children: /* @__PURE__ */ jsx75(ErrorResult, { state }) });
3328
+ return /* @__PURE__ */ jsx67("div", { className: "m-t-2 m-x-2", children: /* @__PURE__ */ jsx67(ErrorResult, { state }) });
4604
3329
  }
4605
3330
  if (state.type === "pending" || isLoading) {
4606
- return /* @__PURE__ */ jsx75("p", { className: "m-t-2 m-x-2", children: formatMessage(search_messages_default.loading) });
3331
+ return /* @__PURE__ */ jsx67("p", { className: "m-t-2 m-x-2", children: formatMessage(search_messages_default.loading) });
4607
3332
  }
4608
3333
  return null;
4609
3334
  }
4610
3335
  var InlineSearchRendererComponent_default = InlineSearchRenderer;
4611
3336
 
4612
3337
  // ../renderers/src/SearchRenderer/SearchRenderer.tsx
4613
- import { jsx as jsx76 } from "react/jsx-runtime";
3338
+ import { jsx as jsx68 } from "react/jsx-runtime";
4614
3339
  var SearchRenderer = {
4615
3340
  canRenderType: "search",
4616
- render: (props) => props.control === "inline" ? /* @__PURE__ */ jsx76(InlineSearchRendererComponent_default, __spreadValues({}, props)) : /* @__PURE__ */ jsx76(BlockSearchRendererComponent_default, __spreadValues({}, props))
3341
+ render: (props) => props.control === "inline" ? /* @__PURE__ */ jsx68(InlineSearchRendererComponent_default, __spreadValues({}, props)) : /* @__PURE__ */ jsx68(BlockSearchRendererComponent_default, __spreadValues({}, props))
4617
3342
  };
4618
3343
  var SearchRenderer_default = SearchRenderer;
4619
3344
 
@@ -4642,12 +3367,12 @@ var getHeaderAction2 = (callToAction) => {
4642
3367
  };
4643
3368
 
4644
3369
  // ../renderers/src/SectionRenderer.tsx
4645
- import { jsx as jsx77, jsxs as jsxs22 } from "react/jsx-runtime";
3370
+ import { jsx as jsx69, jsxs as jsxs20 } from "react/jsx-runtime";
4646
3371
  var SectionRenderer = {
4647
3372
  canRenderType: "section",
4648
3373
  render: ({ children, callToAction, margin, title }) => {
4649
- return /* @__PURE__ */ jsxs22("section", { className: getMargin(margin), children: [
4650
- (title || callToAction) && /* @__PURE__ */ jsx77(Header7, { title: title != null ? title : "", action: getHeaderAction2(callToAction) }),
3374
+ return /* @__PURE__ */ jsxs20("section", { className: getMargin(margin), children: [
3375
+ (title || callToAction) && /* @__PURE__ */ jsx69(Header7, { title: title != null ? title : "", action: getHeaderAction2(callToAction) }),
4651
3376
  children
4652
3377
  ] });
4653
3378
  }
@@ -4656,7 +3381,7 @@ var SectionRenderer_default = SectionRenderer;
4656
3381
 
4657
3382
  // ../renderers/src/SelectInputRenderer/RadioInputRendererComponent.tsx
4658
3383
  import { RadioGroup } from "@transferwise/components";
4659
- import { Fragment as Fragment10, jsx as jsx78, jsxs as jsxs23 } from "react/jsx-runtime";
3384
+ import { Fragment as Fragment9, jsx as jsx70, jsxs as jsxs21 } from "react/jsx-runtime";
4660
3385
  function RadioInputRendererComponent(props) {
4661
3386
  const {
4662
3387
  id,
@@ -4671,8 +3396,8 @@ function RadioInputRendererComponent(props) {
4671
3396
  validationState,
4672
3397
  onSelect
4673
3398
  } = props;
4674
- return /* @__PURE__ */ jsxs23(Fragment10, { children: [
4675
- /* @__PURE__ */ jsx78(
3399
+ return /* @__PURE__ */ jsxs21(Fragment9, { children: [
3400
+ /* @__PURE__ */ jsx70(
4676
3401
  FieldInput_default,
4677
3402
  {
4678
3403
  id,
@@ -4681,7 +3406,7 @@ function RadioInputRendererComponent(props) {
4681
3406
  description,
4682
3407
  validation: validationState,
4683
3408
  features,
4684
- children: /* @__PURE__ */ jsx78("span", { children: /* @__PURE__ */ jsx78(
3409
+ children: /* @__PURE__ */ jsx70("span", { children: /* @__PURE__ */ jsx70(
4685
3410
  RadioGroup,
4686
3411
  {
4687
3412
  name: id,
@@ -4690,7 +3415,7 @@ function RadioInputRendererComponent(props) {
4690
3415
  value: index,
4691
3416
  secondary: option.description,
4692
3417
  disabled: option.disabled || disabled,
4693
- avatar: /* @__PURE__ */ jsx78(OptionMedia, { media: option.media, preferAvatar: false })
3418
+ avatar: /* @__PURE__ */ jsx70(OptionMedia, { media: option.media, preferAvatar: false })
4694
3419
  })),
4695
3420
  selectedValue: selectedIndex != null ? selectedIndex : void 0,
4696
3421
  onChange: onSelect
@@ -4705,8 +3430,8 @@ function RadioInputRendererComponent(props) {
4705
3430
 
4706
3431
  // ../renderers/src/SelectInputRenderer/TabInputRendererComponent.tsx
4707
3432
  import { Tabs } from "@transferwise/components";
4708
- import { useEffect as useEffect11 } from "react";
4709
- import { Fragment as Fragment11, jsx as jsx79, jsxs as jsxs24 } from "react/jsx-runtime";
3433
+ import { useEffect as useEffect9 } from "react";
3434
+ import { Fragment as Fragment10, jsx as jsx71, jsxs as jsxs22 } from "react/jsx-runtime";
4710
3435
  function TabInputRendererComponent(props) {
4711
3436
  const {
4712
3437
  id,
@@ -4721,13 +3446,13 @@ function TabInputRendererComponent(props) {
4721
3446
  validationState,
4722
3447
  onSelect
4723
3448
  } = props;
4724
- useEffect11(() => {
3449
+ useEffect9(() => {
4725
3450
  if (!isValidIndex2(selectedIndex, options.length)) {
4726
3451
  onSelect(0);
4727
3452
  }
4728
3453
  }, [selectedIndex, onSelect, options.length]);
4729
- return /* @__PURE__ */ jsxs24(Fragment11, { children: [
4730
- /* @__PURE__ */ jsx79(
3454
+ return /* @__PURE__ */ jsxs22(Fragment10, { children: [
3455
+ /* @__PURE__ */ jsx71(
4731
3456
  FieldInput_default,
4732
3457
  {
4733
3458
  id,
@@ -4736,7 +3461,7 @@ function TabInputRendererComponent(props) {
4736
3461
  description,
4737
3462
  validation: validationState,
4738
3463
  features,
4739
- children: /* @__PURE__ */ jsx79(
3464
+ children: /* @__PURE__ */ jsx71(
4740
3465
  Tabs,
4741
3466
  {
4742
3467
  name: id,
@@ -4745,7 +3470,7 @@ function TabInputRendererComponent(props) {
4745
3470
  title: option.title,
4746
3471
  // if we pass null, we get some props-types console errors
4747
3472
  // eslint-disable-next-line react/jsx-no-useless-fragment
4748
- content: /* @__PURE__ */ jsx79(Fragment11, {}),
3473
+ content: /* @__PURE__ */ jsx71(Fragment10, {}),
4749
3474
  disabled: option.disabled || disabled
4750
3475
  })),
4751
3476
  onTabSelect: onSelect
@@ -4760,7 +3485,7 @@ var isValidIndex2 = (index, options) => index !== null && index >= 0 && index <
4760
3485
 
4761
3486
  // ../renderers/src/SelectInputRenderer/SelectInputRendererComponent.tsx
4762
3487
  import { SelectInput as SelectInput2, SelectInputOptionContent as SelectInputOptionContent2 } from "@transferwise/components";
4763
- import { Fragment as Fragment12, jsx as jsx80, jsxs as jsxs25 } from "react/jsx-runtime";
3488
+ import { Fragment as Fragment11, jsx as jsx72, jsxs as jsxs23 } from "react/jsx-runtime";
4764
3489
  function SelectInputRendererComponent(props) {
4765
3490
  const {
4766
3491
  id,
@@ -4801,13 +3526,13 @@ function SelectInputRendererComponent(props) {
4801
3526
  } : {
4802
3527
  title: option.title,
4803
3528
  description: option.description,
4804
- icon: /* @__PURE__ */ jsx80(OptionMedia, { media: option.media, preferAvatar: false })
3529
+ icon: /* @__PURE__ */ jsx72(OptionMedia, { media: option.media, preferAvatar: false })
4805
3530
  };
4806
- return /* @__PURE__ */ jsx80(SelectInputOptionContent2, __spreadValues({}, contentProps));
3531
+ return /* @__PURE__ */ jsx72(SelectInputOptionContent2, __spreadValues({}, contentProps));
4807
3532
  };
4808
3533
  const extraProps = { autoComplete };
4809
- return /* @__PURE__ */ jsxs25(Fragment12, { children: [
4810
- /* @__PURE__ */ jsx80(
3534
+ return /* @__PURE__ */ jsxs23(Fragment11, { children: [
3535
+ /* @__PURE__ */ jsx72(
4811
3536
  FieldInput_default,
4812
3537
  {
4813
3538
  id,
@@ -4816,7 +3541,7 @@ function SelectInputRendererComponent(props) {
4816
3541
  description,
4817
3542
  validation: validationState,
4818
3543
  features,
4819
- children: /* @__PURE__ */ jsx80(
3544
+ children: /* @__PURE__ */ jsx72(
4820
3545
  SelectInput2,
4821
3546
  __spreadValues({
4822
3547
  name: id,
@@ -4837,9 +3562,9 @@ function SelectInputRendererComponent(props) {
4837
3562
  }
4838
3563
 
4839
3564
  // ../renderers/src/SelectInputRenderer/SegmentedInputRendererComponent.tsx
4840
- import { useEffect as useEffect12 } from "react";
3565
+ import { useEffect as useEffect10 } from "react";
4841
3566
  import { SegmentedControl } from "@transferwise/components";
4842
- import { Fragment as Fragment13, jsx as jsx81, jsxs as jsxs26 } from "react/jsx-runtime";
3567
+ import { Fragment as Fragment12, jsx as jsx73, jsxs as jsxs24 } from "react/jsx-runtime";
4843
3568
  function SegmentedInputRendererComponent(props) {
4844
3569
  const {
4845
3570
  id,
@@ -4853,13 +3578,13 @@ function SegmentedInputRendererComponent(props) {
4853
3578
  validationState,
4854
3579
  onSelect
4855
3580
  } = props;
4856
- useEffect12(() => {
3581
+ useEffect10(() => {
4857
3582
  if (!isValidIndex3(selectedIndex, options.length)) {
4858
3583
  onSelect(0);
4859
3584
  }
4860
3585
  }, [selectedIndex, onSelect, options.length]);
4861
- return /* @__PURE__ */ jsxs26(Fragment13, { children: [
4862
- /* @__PURE__ */ jsx81(
3586
+ return /* @__PURE__ */ jsxs24(Fragment12, { children: [
3587
+ /* @__PURE__ */ jsx73(
4863
3588
  FieldInput_default,
4864
3589
  {
4865
3590
  id,
@@ -4868,7 +3593,7 @@ function SegmentedInputRendererComponent(props) {
4868
3593
  description,
4869
3594
  validation: validationState,
4870
3595
  features,
4871
- children: /* @__PURE__ */ jsx81(
3596
+ children: /* @__PURE__ */ jsx73(
4872
3597
  SegmentedControl,
4873
3598
  {
4874
3599
  name: `${id}-segmented-control`,
@@ -4885,14 +3610,14 @@ function SegmentedInputRendererComponent(props) {
4885
3610
  )
4886
3611
  }
4887
3612
  ),
4888
- /* @__PURE__ */ jsx81("div", { id: `${id}-children`, children })
3613
+ /* @__PURE__ */ jsx73("div", { id: `${id}-children`, children })
4889
3614
  ] });
4890
3615
  }
4891
3616
  var isValidIndex3 = (index, options) => index !== null && index >= 0 && index < options;
4892
3617
 
4893
3618
  // ../renderers/src/SelectInputRenderer/RadioItemRendererComponent.tsx
4894
- import { Header as Header8, InlineAlert as InlineAlert4, List as List2, ListItem as ListItem12 } from "@transferwise/components";
4895
- import { jsx as jsx82, jsxs as jsxs27 } from "react/jsx-runtime";
3619
+ import { Header as Header8, InlineAlert as InlineAlert4, List as List2, ListItem as ListItem11 } from "@transferwise/components";
3620
+ import { jsx as jsx74, jsxs as jsxs25 } from "react/jsx-runtime";
4896
3621
  function RadioItemRendererComponent(props) {
4897
3622
  const {
4898
3623
  id,
@@ -4908,23 +3633,23 @@ function RadioItemRendererComponent(props) {
4908
3633
  onSelect
4909
3634
  } = props;
4910
3635
  const { ref } = useScrollToError(validationState, features);
4911
- return /* @__PURE__ */ jsxs27("div", { ref, children: [
4912
- rootTitle && /* @__PURE__ */ jsx82(
3636
+ return /* @__PURE__ */ jsxs25("div", { ref, children: [
3637
+ rootTitle && /* @__PURE__ */ jsx74(
4913
3638
  Header8,
4914
3639
  {
4915
3640
  as: "h2",
4916
- title: help ? /* @__PURE__ */ jsx82(LabelContentWithHelp, { text: rootTitle, help }) : rootTitle
3641
+ title: help ? /* @__PURE__ */ jsx74(LabelContentWithHelp, { text: rootTitle, help }) : rootTitle
4917
3642
  }
4918
3643
  ),
4919
- rootDescription && /* @__PURE__ */ jsx82("p", { children: rootDescription }),
4920
- /* @__PURE__ */ jsx82(List2, { children: options.map(
4921
- ({ title, description, additionalText, inlineAlert, disabled, media, supportingValues }, index) => /* @__PURE__ */ jsx82(
4922
- ListItem12,
3644
+ rootDescription && /* @__PURE__ */ jsx74("p", { children: rootDescription }),
3645
+ /* @__PURE__ */ jsx74(List2, { children: options.map(
3646
+ ({ title, description, additionalText, inlineAlert, disabled, media, supportingValues }, index) => /* @__PURE__ */ jsx74(
3647
+ ListItem11,
4923
3648
  __spreadValues({
4924
3649
  title,
4925
3650
  subtitle: description,
4926
- control: /* @__PURE__ */ jsx82(
4927
- ListItem12.Radio,
3651
+ control: /* @__PURE__ */ jsx74(
3652
+ ListItem11.Radio,
4928
3653
  {
4929
3654
  name: title,
4930
3655
  checked: selectedIndex === index,
@@ -4939,50 +3664,50 @@ function RadioItemRendererComponent(props) {
4939
3664
  title
4940
3665
  )
4941
3666
  ) }, `${id}-${selectedIndex}`),
4942
- (validationState == null ? void 0 : validationState.status) === "invalid" && /* @__PURE__ */ jsx82(InlineAlert4, { type: "negative", children: validationState.message }),
3667
+ (validationState == null ? void 0 : validationState.status) === "invalid" && /* @__PURE__ */ jsx74(InlineAlert4, { type: "negative", children: validationState.message }),
4943
3668
  children
4944
3669
  ] });
4945
3670
  }
4946
3671
 
4947
3672
  // ../renderers/src/SelectInputRenderer/SelectInputRenderer.tsx
4948
- import { jsx as jsx83 } from "react/jsx-runtime";
3673
+ import { jsx as jsx75 } from "react/jsx-runtime";
4949
3674
  var SelectInputRenderer = {
4950
3675
  canRenderType: "input-select",
4951
3676
  render: (props) => {
4952
3677
  switch (props.control) {
4953
3678
  case "radio":
4954
- return /* @__PURE__ */ jsx83(RadioInputRendererComponent, __spreadValues({}, props));
3679
+ return /* @__PURE__ */ jsx75(RadioInputRendererComponent, __spreadValues({}, props));
4955
3680
  case "radio-item":
4956
- return /* @__PURE__ */ jsx83(RadioItemRendererComponent, __spreadValues({}, props));
3681
+ return /* @__PURE__ */ jsx75(RadioItemRendererComponent, __spreadValues({}, props));
4957
3682
  case "tab":
4958
- return props.options.length > 3 ? /* @__PURE__ */ jsx83(SelectInputRendererComponent, __spreadValues({}, props)) : /* @__PURE__ */ jsx83(TabInputRendererComponent, __spreadValues({}, props));
3683
+ return props.options.length > 3 ? /* @__PURE__ */ jsx75(SelectInputRendererComponent, __spreadValues({}, props)) : /* @__PURE__ */ jsx75(TabInputRendererComponent, __spreadValues({}, props));
4959
3684
  case "segmented":
4960
- return props.options.length > 3 ? /* @__PURE__ */ jsx83(SelectInputRendererComponent, __spreadValues({}, props)) : /* @__PURE__ */ jsx83(SegmentedInputRendererComponent, __spreadValues({}, props));
3685
+ return props.options.length > 3 ? /* @__PURE__ */ jsx75(SelectInputRendererComponent, __spreadValues({}, props)) : /* @__PURE__ */ jsx75(SegmentedInputRendererComponent, __spreadValues({}, props));
4961
3686
  case "select":
4962
3687
  default:
4963
- return /* @__PURE__ */ jsx83(SelectInputRendererComponent, __spreadValues({}, props));
3688
+ return /* @__PURE__ */ jsx75(SelectInputRendererComponent, __spreadValues({}, props));
4964
3689
  }
4965
3690
  }
4966
3691
  };
4967
3692
  var SelectInputRenderer_default = SelectInputRenderer;
4968
3693
 
4969
3694
  // ../renderers/src/StatusListRenderer.tsx
4970
- import { AvatarView as AvatarView4, Header as Header9, ListItem as ListItem13 } from "@transferwise/components";
4971
- import { jsx as jsx84, jsxs as jsxs28 } from "react/jsx-runtime";
3695
+ import { AvatarView as AvatarView4, Header as Header9, ListItem as ListItem12 } from "@transferwise/components";
3696
+ import { jsx as jsx76, jsxs as jsxs26 } from "react/jsx-runtime";
4972
3697
  var StatusListRenderer = {
4973
3698
  canRenderType: "status-list",
4974
- render: ({ margin, items, title }) => /* @__PURE__ */ jsxs28("div", { className: getMargin(margin), children: [
4975
- title ? /* @__PURE__ */ jsx84(Header9, { title }) : null,
3699
+ render: ({ margin, items, title }) => /* @__PURE__ */ jsxs26("div", { className: getMargin(margin), children: [
3700
+ title ? /* @__PURE__ */ jsx76(Header9, { title }) : null,
4976
3701
  items.map((item) => {
4977
3702
  const { callToAction, description, title: itemTitle } = item;
4978
- return /* @__PURE__ */ jsx84(
4979
- ListItem13,
3703
+ return /* @__PURE__ */ jsx76(
3704
+ ListItem12,
4980
3705
  {
4981
3706
  title: itemTitle,
4982
3707
  subtitle: description,
4983
- media: /* @__PURE__ */ jsx84(StatusListItemMedia, __spreadValues({}, item)),
4984
- additionalInfo: callToAction ? /* @__PURE__ */ jsx84(
4985
- ListItem13.AdditionalInfo,
3708
+ media: /* @__PURE__ */ jsx76(StatusListItemMedia, __spreadValues({}, item)),
3709
+ additionalInfo: callToAction ? /* @__PURE__ */ jsx76(
3710
+ ListItem12.AdditionalInfo,
4986
3711
  {
4987
3712
  action: __spreadValues({
4988
3713
  label: callToAction.title
@@ -5000,10 +3725,10 @@ var StatusListItemMedia = ({ icon, status }) => {
5000
3725
  return void 0;
5001
3726
  }
5002
3727
  if ("name" in icon) {
5003
- return /* @__PURE__ */ jsx84(AvatarView4, { badge: { status: mapStatus(status) }, children: /* @__PURE__ */ jsx84(DynamicIcon_default, { name: icon.name }) });
3728
+ return /* @__PURE__ */ jsx76(AvatarView4, { badge: { status: mapStatus(status) }, children: /* @__PURE__ */ jsx76(DynamicIcon_default, { name: icon.name }) });
5004
3729
  }
5005
3730
  if ("text" in icon) {
5006
- return /* @__PURE__ */ jsx84(AvatarView4, { badge: { status: mapStatus(status) }, children: icon.text });
3731
+ return /* @__PURE__ */ jsx76(AvatarView4, { badge: { status: mapStatus(status) }, children: icon.text });
5007
3732
  }
5008
3733
  return void 0;
5009
3734
  };
@@ -5021,12 +3746,12 @@ var StatusListRenderer_default = StatusListRenderer;
5021
3746
 
5022
3747
  // ../renderers/src/utils/useCustomTheme.ts
5023
3748
  import { useTheme } from "@wise/components-theming";
5024
- import { useEffect as useEffect13, useMemo as useMemo2 } from "react";
3749
+ import { useEffect as useEffect11, useMemo } from "react";
5025
3750
  var ThemeRequiredEventName = "Theme Required";
5026
3751
  var useCustomTheme = (theme, trackEvent) => {
5027
3752
  const theming = useTheme();
5028
- const previousTheme = useMemo2(() => theming.theme, []);
5029
- useEffect13(() => {
3753
+ const previousTheme = useMemo(() => theming.theme, []);
3754
+ useEffect11(() => {
5030
3755
  theming.setTheme(theme);
5031
3756
  trackEvent(ThemeRequiredEventName, { theme });
5032
3757
  return theme !== previousTheme ? () => {
@@ -5037,14 +3762,86 @@ var useCustomTheme = (theme, trackEvent) => {
5037
3762
  }, []);
5038
3763
  };
5039
3764
 
3765
+ // ../renderers/src/step/StepFooter.tsx
3766
+ import { Button as Button7 } from "@transferwise/components";
3767
+ import { useEffect as useEffect12, useRef as useRef2, useState as useState13 } from "react";
3768
+ import { useIntl as useIntl14 } from "react-intl";
3769
+
3770
+ // ../renderers/src/messages/step.messages.ts
3771
+ import { defineMessages as defineMessages11 } from "react-intl";
3772
+ var step_messages_default = defineMessages11({
3773
+ scrollToBottom: {
3774
+ id: "df.wise.step.scrollToBottom",
3775
+ defaultMessage: "Scroll to bottom",
3776
+ description: "Label for a button that appears when the content of a step is too long and the user needs to scroll to the bottom to see all the content."
3777
+ }
3778
+ });
3779
+
3780
+ // ../renderers/src/step/StepFooter.tsx
3781
+ import { Fragment as Fragment13, jsx as jsx77, jsxs as jsxs27 } from "react/jsx-runtime";
3782
+ var SCROLL_TO_BOTTOM = "scroll-to-bottom";
3783
+ var StepFooter = ({ footer, tags }) => {
3784
+ if (tags == null ? void 0 : tags.includes(SCROLL_TO_BOTTOM)) {
3785
+ return /* @__PURE__ */ jsx77(FooterWithScrollButton, { footer });
3786
+ }
3787
+ return /* @__PURE__ */ jsx77(DefaultFooter, { footer });
3788
+ };
3789
+ var DefaultFooter = ({ footer }) => {
3790
+ const hasFooter = footer && Array.isArray(footer) && footer.length > 0;
3791
+ return hasFooter ? /* @__PURE__ */ jsx77("div", { className: "df-step-fixed__footer", children: footer }) : void 0;
3792
+ };
3793
+ var FooterWithScrollButton = ({ footer }) => {
3794
+ const { formatMessage } = useIntl14();
3795
+ const endOfLayoutRef = useRef2(null);
3796
+ const isElementVisible = useIsElementVisible(endOfLayoutRef);
3797
+ const scrollButton = /* @__PURE__ */ jsx77(
3798
+ Button7,
3799
+ {
3800
+ className: "m-b-1",
3801
+ v2: true,
3802
+ block: true,
3803
+ priority: "tertiary",
3804
+ onClick: () => {
3805
+ var _a;
3806
+ (_a = endOfLayoutRef.current) == null ? void 0 : _a.scrollIntoView({ behavior: "smooth" });
3807
+ },
3808
+ children: formatMessage(step_messages_default.scrollToBottom)
3809
+ }
3810
+ );
3811
+ const hasStepFooterContent = footer && Array.isArray(footer) && footer.length > 0;
3812
+ if (isElementVisible && !hasStepFooterContent) {
3813
+ return /* @__PURE__ */ jsx77("div", { ref: endOfLayoutRef, "aria-hidden": "true" });
3814
+ }
3815
+ return /* @__PURE__ */ jsxs27(Fragment13, { children: [
3816
+ /* @__PURE__ */ jsx77("div", { ref: endOfLayoutRef, "aria-hidden": "true" }),
3817
+ /* @__PURE__ */ jsxs27("div", { className: "df-step-fixed__footer", children: [
3818
+ !isElementVisible && scrollButton,
3819
+ footer
3820
+ ] })
3821
+ ] });
3822
+ };
3823
+ var useIsElementVisible = (elementRef) => {
3824
+ const [isVisible, setIsVisible] = useState13(false);
3825
+ useEffect12(() => {
3826
+ const element = elementRef.current;
3827
+ if (!element) return;
3828
+ const observer = new IntersectionObserver(([entry]) => {
3829
+ setIsVisible(entry.isIntersecting);
3830
+ });
3831
+ observer.observe(element);
3832
+ return () => observer.disconnect();
3833
+ }, [elementRef]);
3834
+ return isVisible;
3835
+ };
3836
+
5040
3837
  // ../renderers/src/step/StepHeader.tsx
5041
3838
  import { Title as Title2 } from "@transferwise/components";
5042
- import { Fragment as Fragment14, jsx as jsx85, jsxs as jsxs29 } from "react/jsx-runtime";
3839
+ import { Fragment as Fragment14, jsx as jsx78, jsxs as jsxs28 } from "react/jsx-runtime";
5043
3840
  var StepHeader = ({ title, description, tags }) => {
5044
3841
  const { titleType, alignmentClassName } = getHeaderStyle(tags);
5045
- return /* @__PURE__ */ jsxs29(Fragment14, { children: [
5046
- title ? /* @__PURE__ */ jsx85(Title2, { as: "h1", type: titleType, className: `${alignmentClassName} m-b-2`, children: title }) : void 0,
5047
- description ? /* @__PURE__ */ jsx85("p", { className: `${alignmentClassName} np-text-body-large`, children: description }) : void 0
3842
+ return /* @__PURE__ */ jsxs28(Fragment14, { children: [
3843
+ title ? /* @__PURE__ */ jsx78(Title2, { as: "h1", type: titleType, className: `${alignmentClassName} m-b-2`, children: title }) : void 0,
3844
+ description ? /* @__PURE__ */ jsx78("p", { className: `${alignmentClassName} np-text-body-large`, children: description }) : void 0
5048
3845
  ] });
5049
3846
  };
5050
3847
  var getHeaderStyle = (tags) => {
@@ -5070,30 +3867,30 @@ var back_messages_default = defineMessages12({
5070
3867
  });
5071
3868
 
5072
3869
  // ../renderers/src/step/topbar/BackButton.tsx
5073
- import { jsx as jsx86, jsxs as jsxs30 } from "react/jsx-runtime";
3870
+ import { jsx as jsx79, jsxs as jsxs29 } from "react/jsx-runtime";
5074
3871
  function BackButton({ title, onClick }) {
5075
3872
  const { formatMessage } = useIntl15();
5076
- return /* @__PURE__ */ jsxs30(IconButton, { className: "df-back-button", priority: "tertiary", onClick, children: [
5077
- /* @__PURE__ */ jsx86("span", { className: "sr-only", children: title != null ? title : formatMessage(back_messages_default.back) }),
5078
- /* @__PURE__ */ jsx86(ArrowLeft, {})
3873
+ return /* @__PURE__ */ jsxs29(IconButton, { className: "df-back-button", priority: "tertiary", onClick, children: [
3874
+ /* @__PURE__ */ jsx79("span", { className: "sr-only", children: title != null ? title : formatMessage(back_messages_default.back) }),
3875
+ /* @__PURE__ */ jsx79(ArrowLeft, {})
5079
3876
  ] });
5080
3877
  }
5081
3878
 
5082
3879
  // ../renderers/src/step/topbar/Toolbar.tsx
5083
- import { Button as Button9, IconButton as IconButton2 } from "@transferwise/components";
5084
- import { jsx as jsx87, jsxs as jsxs31 } from "react/jsx-runtime";
3880
+ import { Button as Button8, IconButton as IconButton2 } from "@transferwise/components";
3881
+ import { jsx as jsx80, jsxs as jsxs30 } from "react/jsx-runtime";
5085
3882
  var Toolbar = ({ items }) => {
5086
- return (items == null ? void 0 : items.length) > 0 ? /* @__PURE__ */ jsx87("div", { className: "df-toolbar", children: items.map((item, index) => /* @__PURE__ */ jsx87(ToolbarButton, __spreadValues({}, item), `${item.type}-${index}-${item.title}`)) }) : null;
3883
+ return (items == null ? void 0 : items.length) > 0 ? /* @__PURE__ */ jsx80("div", { className: "df-toolbar", children: items.map((item, index) => /* @__PURE__ */ jsx80(ToolbarButton, __spreadValues({}, item), `${item.type}-${index}-${item.title}`)) }) : null;
5087
3884
  };
5088
3885
  function ToolbarButton(props) {
5089
- return prefersMedia(props.control) ? /* @__PURE__ */ jsx87(MediaToolbarButton, __spreadValues({}, props)) : /* @__PURE__ */ jsx87(TextToolbarButton, __spreadValues({}, props));
3886
+ return prefersMedia(props.control) ? /* @__PURE__ */ jsx80(MediaToolbarButton, __spreadValues({}, props)) : /* @__PURE__ */ jsx80(TextToolbarButton, __spreadValues({}, props));
5090
3887
  }
5091
3888
  function MediaToolbarButton(props) {
5092
3889
  var _a;
5093
3890
  const { context, control, media, accessibilityDescription, disabled, onClick } = props;
5094
3891
  const priority = getIconButtonPriority(control);
5095
3892
  const type = getSentiment2(context);
5096
- return /* @__PURE__ */ jsxs31(
3893
+ return /* @__PURE__ */ jsxs30(
5097
3894
  IconButton2,
5098
3895
  {
5099
3896
  className: "df-toolbar-button",
@@ -5103,7 +3900,7 @@ function MediaToolbarButton(props) {
5103
3900
  type,
5104
3901
  onClick,
5105
3902
  children: [
5106
- accessibilityDescription ? /* @__PURE__ */ jsx87("span", { className: "sr-only", children: accessibilityDescription }) : null,
3903
+ accessibilityDescription ? /* @__PURE__ */ jsx80("span", { className: "sr-only", children: accessibilityDescription }) : null,
5107
3904
  media ? (_a = getAddonStartMedia(media)) == null ? void 0 : _a.value : null
5108
3905
  ]
5109
3906
  }
@@ -5114,8 +3911,8 @@ function TextToolbarButton(props) {
5114
3911
  const addonStart = media ? getAddonStartMedia(media) : void 0;
5115
3912
  const priority = getPriority2(control);
5116
3913
  const sentiment = getSentiment2(context);
5117
- return /* @__PURE__ */ jsx87(
5118
- Button9,
3914
+ return /* @__PURE__ */ jsx80(
3915
+ Button8,
5119
3916
  {
5120
3917
  v2: true,
5121
3918
  size: "sm",
@@ -5144,18 +3941,18 @@ var getIconButtonPriority = (control) => {
5144
3941
  };
5145
3942
 
5146
3943
  // ../renderers/src/step/topbar/TopBar.tsx
5147
- import { jsx as jsx88, jsxs as jsxs32 } from "react/jsx-runtime";
3944
+ import { jsx as jsx81, jsxs as jsxs31 } from "react/jsx-runtime";
5148
3945
  function TopBar({ back, toolbar, tags }) {
5149
3946
  const isBackAllowed = !(tags == null ? void 0 : tags.includes("non-dismissible"));
5150
3947
  const backCTA = isBackAllowed ? back : void 0;
5151
- return backCTA || toolbar ? /* @__PURE__ */ jsxs32("div", { className: "d-flex m-b-2", children: [
5152
- backCTA ? /* @__PURE__ */ jsx88(BackButton, __spreadValues({}, backCTA)) : null,
5153
- toolbar ? /* @__PURE__ */ jsx88(Toolbar, __spreadValues({}, toolbar)) : null
3948
+ return backCTA || toolbar ? /* @__PURE__ */ jsxs31("div", { className: "d-flex m-b-2", children: [
3949
+ backCTA ? /* @__PURE__ */ jsx81(BackButton, __spreadValues({}, backCTA)) : null,
3950
+ toolbar ? /* @__PURE__ */ jsx81(Toolbar, __spreadValues({}, toolbar)) : null
5154
3951
  ] }) : null;
5155
3952
  }
5156
3953
 
5157
3954
  // ../renderers/src/step/SplashCelebrationStepRenderer.tsx
5158
- import { jsx as jsx89, jsxs as jsxs33 } from "react/jsx-runtime";
3955
+ import { jsx as jsx82, jsxs as jsxs32 } from "react/jsx-runtime";
5159
3956
  var SplashCelebrationStepRenderer = {
5160
3957
  canRenderType: "step",
5161
3958
  canRender: ({ control }) => control === "splash-celebration",
@@ -5164,16 +3961,16 @@ var SplashCelebrationStepRenderer = {
5164
3961
  function SplashCelebrationStepRendererComponent(props) {
5165
3962
  const { back, title, description, toolbar, children, footer, tags, trackEvent } = props;
5166
3963
  useCustomTheme("forest-green", trackEvent);
5167
- return /* @__PURE__ */ jsxs33("div", { className: "splash-screen m-t-5", children: [
5168
- /* @__PURE__ */ jsx89(TopBar, { back, toolbar, tags }),
5169
- title || description ? /* @__PURE__ */ jsx89("div", { className: "m-b-4", children: /* @__PURE__ */ jsx89(StepHeader, { title, description, tags }) }) : void 0,
3964
+ return /* @__PURE__ */ jsxs32("div", { className: "splash-screen m-t-5", children: [
3965
+ /* @__PURE__ */ jsx82(TopBar, { back, toolbar, tags }),
3966
+ title || description ? /* @__PURE__ */ jsx82("div", { className: "m-b-4", children: /* @__PURE__ */ jsx82(StepHeader, { title, description, tags }) }) : void 0,
5170
3967
  children,
5171
- /* @__PURE__ */ jsx89(StepFooter, { footer, tags })
3968
+ /* @__PURE__ */ jsx82(StepFooter, { footer, tags })
5172
3969
  ] });
5173
3970
  }
5174
3971
 
5175
3972
  // ../renderers/src/step/SplashStepRenderer.tsx
5176
- import { jsx as jsx90, jsxs as jsxs34 } from "react/jsx-runtime";
3973
+ import { jsx as jsx83, jsxs as jsxs33 } from "react/jsx-runtime";
5177
3974
  var SplashStepRenderer = {
5178
3975
  canRenderType: "step",
5179
3976
  canRender: ({ control }) => control === "splash",
@@ -5181,55 +3978,55 @@ var SplashStepRenderer = {
5181
3978
  };
5182
3979
  function SplashStepRendererComponent(props) {
5183
3980
  const { back, title, description, toolbar, children, footer, tags } = props;
5184
- return /* @__PURE__ */ jsxs34("div", { className: "splash-screen m-t-5", children: [
5185
- /* @__PURE__ */ jsx90(TopBar, { back, toolbar, tags }),
5186
- title || description ? /* @__PURE__ */ jsx90("div", { className: "m-b-4", children: /* @__PURE__ */ jsx90(StepHeader, { title, description, tags }) }) : void 0,
3981
+ return /* @__PURE__ */ jsxs33("div", { className: "splash-screen m-t-5", children: [
3982
+ /* @__PURE__ */ jsx83(TopBar, { back, toolbar, tags }),
3983
+ title || description ? /* @__PURE__ */ jsx83("div", { className: "m-b-4", children: /* @__PURE__ */ jsx83(StepHeader, { title, description, tags }) }) : void 0,
5187
3984
  children,
5188
- /* @__PURE__ */ jsx90(StepFooter, { footer, tags })
3985
+ /* @__PURE__ */ jsx83(StepFooter, { footer, tags })
5189
3986
  ] });
5190
3987
  }
5191
3988
 
5192
3989
  // ../renderers/src/step/StepRenderer.tsx
5193
3990
  import { Alert as Alert2 } from "@transferwise/components";
5194
- import { jsx as jsx91, jsxs as jsxs35 } from "react/jsx-runtime";
3991
+ import { jsx as jsx84, jsxs as jsxs34 } from "react/jsx-runtime";
5195
3992
  var StepRenderer = {
5196
3993
  canRenderType: "step",
5197
3994
  render: StepRendererComponent
5198
3995
  };
5199
3996
  function StepRendererComponent(props) {
5200
3997
  const { back, description, error, title, children, toolbar, footer, tags } = props;
5201
- return /* @__PURE__ */ jsxs35("div", { children: [
5202
- /* @__PURE__ */ jsx91(TopBar, { back, toolbar, tags }),
5203
- title || description ? /* @__PURE__ */ jsx91("div", { className: "m-b-4", children: /* @__PURE__ */ jsx91(StepHeader, { title, description, tags }) }) : void 0,
5204
- error ? /* @__PURE__ */ jsx91(Alert2, { type: "negative", className: "m-b-2", message: error }) : null,
3998
+ return /* @__PURE__ */ jsxs34("div", { children: [
3999
+ /* @__PURE__ */ jsx84(TopBar, { back, toolbar, tags }),
4000
+ title || description ? /* @__PURE__ */ jsx84("div", { className: "m-b-4", children: /* @__PURE__ */ jsx84(StepHeader, { title, description, tags }) }) : void 0,
4001
+ error ? /* @__PURE__ */ jsx84(Alert2, { type: "negative", className: "m-b-2", message: error }) : null,
5205
4002
  children,
5206
- /* @__PURE__ */ jsx91(StepFooter, { footer, tags })
4003
+ /* @__PURE__ */ jsx84(StepFooter, { footer, tags })
5207
4004
  ] });
5208
4005
  }
5209
4006
 
5210
4007
  // ../renderers/src/TabsRenderer.tsx
5211
- import { Chips as Chips2, SegmentedControl as SegmentedControl2, Tabs as Tabs2 } from "@transferwise/components";
4008
+ import { Chips, SegmentedControl as SegmentedControl2, Tabs as Tabs2 } from "@transferwise/components";
5212
4009
  import { useState as useState14 } from "react";
5213
- import { jsx as jsx92, jsxs as jsxs36 } from "react/jsx-runtime";
4010
+ import { jsx as jsx85, jsxs as jsxs35 } from "react/jsx-runtime";
5214
4011
  var TabsRenderer = {
5215
4012
  canRenderType: "tabs",
5216
4013
  render: (props) => {
5217
4014
  switch (props.control) {
5218
4015
  case "segmented":
5219
4016
  if (props.tabs.length > 3) {
5220
- return /* @__PURE__ */ jsx92(TabsRendererComponent, __spreadValues({}, props));
4017
+ return /* @__PURE__ */ jsx85(TabsRendererComponent, __spreadValues({}, props));
5221
4018
  }
5222
- return /* @__PURE__ */ jsx92(SegmentedTabsRendererComponent, __spreadValues({}, props));
4019
+ return /* @__PURE__ */ jsx85(SegmentedTabsRendererComponent, __spreadValues({}, props));
5223
4020
  case "chips":
5224
- return /* @__PURE__ */ jsx92(ChipsTabsRendererComponent, __spreadValues({}, props));
4021
+ return /* @__PURE__ */ jsx85(ChipsTabsRendererComponent, __spreadValues({}, props));
5225
4022
  default:
5226
- return /* @__PURE__ */ jsx92(TabsRendererComponent, __spreadValues({}, props));
4023
+ return /* @__PURE__ */ jsx85(TabsRendererComponent, __spreadValues({}, props));
5227
4024
  }
5228
4025
  }
5229
4026
  };
5230
4027
  function TabsRendererComponent({ uid, margin, tabs }) {
5231
4028
  const [selectedIndex, setSelectedIndex] = useState14(0);
5232
- return /* @__PURE__ */ jsx92("div", { className: getMargin(margin), children: /* @__PURE__ */ jsx92(
4029
+ return /* @__PURE__ */ jsx85("div", { className: getMargin(margin), children: /* @__PURE__ */ jsx85(
5233
4030
  Tabs2,
5234
4031
  {
5235
4032
  name: uid,
@@ -5237,7 +4034,7 @@ function TabsRendererComponent({ uid, margin, tabs }) {
5237
4034
  tabs: tabs.map((option) => ({
5238
4035
  title: option.title,
5239
4036
  disabled: false,
5240
- content: /* @__PURE__ */ jsxs36("div", { className: "m-t-2", children: [
4037
+ content: /* @__PURE__ */ jsxs35("div", { className: "m-t-2", children: [
5241
4038
  " ",
5242
4039
  option.children,
5243
4040
  " "
@@ -5250,8 +4047,8 @@ function TabsRendererComponent({ uid, margin, tabs }) {
5250
4047
  function SegmentedTabsRendererComponent({ uid, margin, tabs }) {
5251
4048
  var _a;
5252
4049
  const [selectedIndex, setSelectedIndex] = useState14(0);
5253
- return /* @__PURE__ */ jsxs36("div", { className: getMargin(margin), children: [
5254
- /* @__PURE__ */ jsx92(
4050
+ return /* @__PURE__ */ jsxs35("div", { className: getMargin(margin), children: [
4051
+ /* @__PURE__ */ jsx85(
5255
4052
  SegmentedControl2,
5256
4053
  {
5257
4054
  name: uid,
@@ -5266,37 +4063,37 @@ function SegmentedTabsRendererComponent({ uid, margin, tabs }) {
5266
4063
  onChange: (value) => setSelectedIndex(Number(value))
5267
4064
  }
5268
4065
  ),
5269
- /* @__PURE__ */ jsx92("div", { id: `${uid}-children`, className: "m-t-2", children: (_a = tabs[selectedIndex]) == null ? void 0 : _a.children })
4066
+ /* @__PURE__ */ jsx85("div", { id: `${uid}-children`, className: "m-t-2", children: (_a = tabs[selectedIndex]) == null ? void 0 : _a.children })
5270
4067
  ] });
5271
4068
  }
5272
4069
  function ChipsTabsRendererComponent({ margin, tabs }) {
5273
4070
  var _a;
5274
4071
  const [selectedIndex, setSelectedIndex] = useState14(0);
5275
- return /* @__PURE__ */ jsxs36("div", { className: getMargin(margin), children: [
5276
- /* @__PURE__ */ jsx92("div", { className: "chips-container", children: /* @__PURE__ */ jsx92(
5277
- Chips2,
4072
+ return /* @__PURE__ */ jsxs35("div", { className: getMargin(margin), children: [
4073
+ /* @__PURE__ */ jsx85("div", { className: "chips-container", children: /* @__PURE__ */ jsx85(
4074
+ Chips,
5278
4075
  {
5279
4076
  chips: tabs.map((tab, index) => ({ label: tab.title, value: index })),
5280
4077
  selected: selectedIndex,
5281
4078
  onChange: ({ selectedValue }) => setSelectedIndex(Number(selectedValue))
5282
4079
  }
5283
4080
  ) }),
5284
- /* @__PURE__ */ jsx92("div", { className: "m-t-2", children: (_a = tabs[selectedIndex]) == null ? void 0 : _a.children })
4081
+ /* @__PURE__ */ jsx85("div", { className: "m-t-2", children: (_a = tabs[selectedIndex]) == null ? void 0 : _a.children })
5285
4082
  ] });
5286
4083
  }
5287
4084
 
5288
4085
  // ../renderers/src/TextInputRenderer.tsx
5289
- import { InputGroup as InputGroup5 } from "@transferwise/components";
4086
+ import { InputGroup as InputGroup4 } from "@transferwise/components";
5290
4087
 
5291
4088
  // ../renderers/src/components/VariableTextInput.tsx
5292
4089
  import {
5293
- Input as Input6,
4090
+ Input as Input5,
5294
4091
  InputWithDisplayFormat,
5295
4092
  PhoneNumberInput,
5296
4093
  TextArea,
5297
4094
  TextareaWithDisplayFormat
5298
4095
  } from "@transferwise/components";
5299
- import { jsx as jsx93 } from "react/jsx-runtime";
4096
+ import { jsx as jsx86 } from "react/jsx-runtime";
5300
4097
  var commonKeys = [
5301
4098
  "autoComplete",
5302
4099
  "autoCapitalize",
@@ -5315,12 +4112,12 @@ function VariableTextInput(inputProps) {
5315
4112
  const commonProps = __spreadProps(__spreadValues({}, pick(inputProps, ...commonKeys)), { name: id });
5316
4113
  switch (control) {
5317
4114
  case "email":
5318
- return /* @__PURE__ */ jsx93(TextInput, __spreadProps(__spreadValues({}, commonProps), { type: "email", onChange }));
4115
+ return /* @__PURE__ */ jsx86(TextInput, __spreadProps(__spreadValues({}, commonProps), { type: "email", onChange }));
5319
4116
  case "password":
5320
- return /* @__PURE__ */ jsx93(TextInput, __spreadProps(__spreadValues({}, commonProps), { type: "password", onChange }));
4117
+ return /* @__PURE__ */ jsx86(TextInput, __spreadProps(__spreadValues({}, commonProps), { type: "password", onChange }));
5321
4118
  case "numeric": {
5322
4119
  const numericProps = __spreadProps(__spreadValues({}, commonProps), { type: "number", onWheel });
5323
- return /* @__PURE__ */ jsx93(
4120
+ return /* @__PURE__ */ jsx86(
5324
4121
  TextInput,
5325
4122
  __spreadProps(__spreadValues({}, numericProps), {
5326
4123
  onChange: (newValue) => {
@@ -5331,21 +4128,21 @@ function VariableTextInput(inputProps) {
5331
4128
  );
5332
4129
  }
5333
4130
  case "phone-number":
5334
- return /* @__PURE__ */ jsx93(PhoneNumberInput, __spreadProps(__spreadValues({ initialValue: value }, commonProps), { onChange }));
4131
+ return /* @__PURE__ */ jsx86(PhoneNumberInput, __spreadProps(__spreadValues({ initialValue: value }, commonProps), { onChange }));
5335
4132
  default: {
5336
- return /* @__PURE__ */ jsx93(TextInput, __spreadProps(__spreadValues({}, commonProps), { type: "text", onChange }));
4133
+ return /* @__PURE__ */ jsx86(TextInput, __spreadProps(__spreadValues({}, commonProps), { type: "text", onChange }));
5337
4134
  }
5338
4135
  }
5339
4136
  }
5340
4137
  function TextInput(props) {
5341
4138
  const _a = props, { control, displayFormat, onChange } = _a, commonProps = __objRest(_a, ["control", "displayFormat", "onChange"]);
5342
4139
  const InputWithPattern = control === "textarea" ? TextareaWithDisplayFormat : InputWithDisplayFormat;
5343
- const InputWithoutPattern = control === "textarea" ? TextArea : Input6;
5344
- return displayFormat ? /* @__PURE__ */ jsx93(InputWithPattern, __spreadProps(__spreadValues({ displayPattern: displayFormat }, commonProps), { onChange })) : /* @__PURE__ */ jsx93(InputWithoutPattern, __spreadProps(__spreadValues({}, commonProps), { onChange: (e) => onChange(e.target.value) }));
4140
+ const InputWithoutPattern = control === "textarea" ? TextArea : Input5;
4141
+ return displayFormat ? /* @__PURE__ */ jsx86(InputWithPattern, __spreadProps(__spreadValues({ displayPattern: displayFormat }, commonProps), { onChange })) : /* @__PURE__ */ jsx86(InputWithoutPattern, __spreadProps(__spreadValues({}, commonProps), { onChange: (e) => onChange(e.target.value) }));
5345
4142
  }
5346
4143
 
5347
4144
  // ../renderers/src/TextInputRenderer.tsx
5348
- import { jsx as jsx94 } from "react/jsx-runtime";
4145
+ import { jsx as jsx87 } from "react/jsx-runtime";
5349
4146
  var TextInputRenderer = {
5350
4147
  canRenderType: "input-text",
5351
4148
  render: (props) => {
@@ -5378,7 +4175,7 @@ var TextInputRenderer = {
5378
4175
  }
5379
4176
  }
5380
4177
  });
5381
- return /* @__PURE__ */ jsx94(
4178
+ return /* @__PURE__ */ jsx87(
5382
4179
  FieldInput_default,
5383
4180
  {
5384
4181
  id,
@@ -5389,7 +4186,7 @@ var TextInputRenderer = {
5389
4186
  loadingState: props.fieldLoadingState,
5390
4187
  help,
5391
4188
  features: props.features,
5392
- children: /* @__PURE__ */ jsx94(InputGroup5, { addonStart: getInputGroupAddonStart(media), children: /* @__PURE__ */ jsx94(VariableTextInput, __spreadValues({}, inputProps)) })
4189
+ children: /* @__PURE__ */ jsx87(InputGroup4, { addonStart: getInputGroupAddonStart(media), children: /* @__PURE__ */ jsx87(VariableTextInput, __spreadValues({}, inputProps)) })
5393
4190
  }
5394
4191
  );
5395
4192
  }
@@ -5403,7 +4200,7 @@ import { Status as Status2, Upload, UploadInput as UploadInput2 } from "@transfe
5403
4200
  var getRandomId = () => Math.random().toString(36).substring(2);
5404
4201
 
5405
4202
  // ../renderers/src/UploadInputRenderer.tsx
5406
- import { jsx as jsx95 } from "react/jsx-runtime";
4203
+ import { jsx as jsx88 } from "react/jsx-runtime";
5407
4204
  var UploadInputRenderer = {
5408
4205
  canRenderType: "input-upload",
5409
4206
  render: (props) => {
@@ -5430,7 +4227,7 @@ var UploadInputRenderer = {
5430
4227
  };
5431
4228
  return (
5432
4229
  // We don't pass help here as there is no sensible place to display it
5433
- /* @__PURE__ */ jsx95(
4230
+ /* @__PURE__ */ jsx88(
5434
4231
  UploadFieldInput_default,
5435
4232
  {
5436
4233
  id,
@@ -5438,7 +4235,7 @@ var UploadInputRenderer = {
5438
4235
  description: void 0,
5439
4236
  validation: validationState,
5440
4237
  features,
5441
- children: /* @__PURE__ */ jsx95(
4238
+ children: /* @__PURE__ */ jsx88(
5442
4239
  UploadInput2,
5443
4240
  {
5444
4241
  id,
@@ -5506,7 +4303,7 @@ var LargeUploadRenderer = {
5506
4303
  };
5507
4304
  const filetypes = acceptsToFileTypes(accepts);
5508
4305
  const usAccept = filetypes === "*" ? "*" : filetypes.join(",");
5509
- return /* @__PURE__ */ jsx95(
4306
+ return /* @__PURE__ */ jsx88(
5510
4307
  FieldInput_default,
5511
4308
  {
5512
4309
  id,
@@ -5515,7 +4312,7 @@ var LargeUploadRenderer = {
5515
4312
  validation: validationState,
5516
4313
  help,
5517
4314
  features,
5518
- children: /* @__PURE__ */ jsx95(
4315
+ children: /* @__PURE__ */ jsx88(
5519
4316
  Upload,
5520
4317
  __spreadProps(__spreadValues({}, uploadProps), {
5521
4318
  usAccept,
@@ -5533,7 +4330,7 @@ var LargeUploadRenderer = {
5533
4330
  // ../renderers/src/UpsellRenderer.tsx
5534
4331
  import { Nudge } from "@transferwise/components";
5535
4332
  import { useState as useState15 } from "react";
5536
- import { jsx as jsx96 } from "react/jsx-runtime";
4333
+ import { jsx as jsx89 } from "react/jsx-runtime";
5537
4334
  var UpsellRenderer = {
5538
4335
  canRenderType: "upsell",
5539
4336
  render: UpsellRendererComponent
@@ -5541,7 +4338,7 @@ var UpsellRenderer = {
5541
4338
  function UpsellRendererComponent(props) {
5542
4339
  const { text, callToAction, media, margin, onDismiss } = props;
5543
4340
  const [isVisible, setIsVisible] = useState15(true);
5544
- return isVisible ? /* @__PURE__ */ jsx96(
4341
+ return isVisible ? /* @__PURE__ */ jsx89(
5545
4342
  Nudge,
5546
4343
  {
5547
4344
  className: getMargin(margin),
@@ -5590,7 +4387,7 @@ var supportedMediaNames = [
5590
4387
  // ../renderers/src/ButtonRenderer/CircularButtonRenderer.tsx
5591
4388
  import { CircularButton } from "@transferwise/components";
5592
4389
  var import_classnames8 = __toESM(require_classnames());
5593
- import { jsx as jsx97 } from "react/jsx-runtime";
4390
+ import { jsx as jsx90 } from "react/jsx-runtime";
5594
4391
  var CircularButtonRenderer = {
5595
4392
  canRenderType: "button",
5596
4393
  canRender: ({ control }) => control === "circular",
@@ -5600,7 +4397,7 @@ function CircularButtonComponent(props) {
5600
4397
  var _a;
5601
4398
  const { context, disabled, margin, media, tags, title, onClick } = props;
5602
4399
  const priority = tags == null ? void 0 : tags.find((tag) => tag === "primary" || tag === "secondary");
5603
- return /* @__PURE__ */ jsx97("div", { className: (0, import_classnames8.default)(getMargin(margin), "df-button", "circular"), children: /* @__PURE__ */ jsx97(
4400
+ return /* @__PURE__ */ jsx90("div", { className: (0, import_classnames8.default)(getMargin(margin), "df-button", "circular"), children: /* @__PURE__ */ jsx90(
5604
4401
  CircularButton,
5605
4402
  {
5606
4403
  disabled,
@@ -5620,7 +4417,6 @@ var getWiseRenderers = () => [
5620
4417
  CheckboxInputRenderer_default,
5621
4418
  CircularButtonRenderer,
5622
4419
  BoxRenderer_default,
5623
- CollectionRenderer_default,
5624
4420
  ButtonRenderer,
5625
4421
  ColumnsRenderer_default,
5626
4422
  DateInputRenderer_default,
@@ -5665,11 +4461,11 @@ var getWiseRenderers = () => [
5665
4461
 
5666
4462
  // ../renderers/src/InitialLoadingStateRenderer.tsx
5667
4463
  import { Loader as Loader2 } from "@transferwise/components";
5668
- import { jsx as jsx98 } from "react/jsx-runtime";
4464
+ import { jsx as jsx91 } from "react/jsx-runtime";
5669
4465
  var InitialLoadingStateRenderer = {
5670
4466
  canRenderType: "loading-state",
5671
4467
  canRender: ({ stepLoadingState }) => stepLoadingState === "initial",
5672
- render: () => /* @__PURE__ */ jsx98(
4468
+ render: () => /* @__PURE__ */ jsx91(
5673
4469
  Loader2,
5674
4470
  {
5675
4471
  size: "md",
@@ -5682,24 +4478,24 @@ var InitialLoadingStateRenderer = {
5682
4478
  // src/dynamicFlow/DynamicFlowModal.tsx
5683
4479
  import { useDynamicFlowModal } from "@wise/dynamic-flow-client";
5684
4480
  import { Modal as Modal5 } from "@transferwise/components";
5685
- import { jsx as jsx99 } from "react/jsx-runtime";
4481
+ import { jsx as jsx92 } from "react/jsx-runtime";
5686
4482
  function DynamicFlowModal(props) {
5687
4483
  const _a = props, { className = "" } = _a, rest = __objRest(_a, ["className"]);
5688
4484
  const dfProps = useWiseToCoreProps(rest);
5689
4485
  const df = useDynamicFlowModal(dfProps);
5690
- return /* @__PURE__ */ jsx99(
4486
+ return /* @__PURE__ */ jsx92(
5691
4487
  Modal5,
5692
4488
  __spreadProps(__spreadValues({
5693
4489
  className: `dynamic-flow-modal ${className}`,
5694
4490
  disableDimmerClickToClose: true
5695
4491
  }, df.modal), {
5696
- body: /* @__PURE__ */ jsx99("div", { className: "dynamic-flow-modal", children: df.modal.body })
4492
+ body: /* @__PURE__ */ jsx92("div", { className: "dynamic-flow-modal", children: df.modal.body })
5697
4493
  })
5698
4494
  );
5699
4495
  }
5700
4496
 
5701
4497
  // src/dynamicFlow/getMergedRenderers.tsx
5702
- import { jsx as jsx100 } from "react/jsx-runtime";
4498
+ import { jsx as jsx93 } from "react/jsx-runtime";
5703
4499
  var wiseRenderers = getWiseRenderers();
5704
4500
  var getMergedRenderers = (props) => {
5705
4501
  var _d, _e;
@@ -5713,7 +4509,7 @@ var getMergedRenderers = (props) => {
5713
4509
  method: initialRequest.method,
5714
4510
  data: initialRequest.body
5715
4511
  };
5716
- return presentation.type === "push" ? /* @__PURE__ */ jsx100(DynamicFlow, __spreadProps(__spreadValues(__spreadValues({}, restProps), rest), { features: subflowFeatures, initialAction: action })) : /* @__PURE__ */ jsx100(
4512
+ return presentation.type === "push" ? /* @__PURE__ */ jsx93(DynamicFlow, __spreadProps(__spreadValues(__spreadValues({}, restProps), rest), { features: subflowFeatures, initialAction: action })) : /* @__PURE__ */ jsx93(
5717
4513
  DynamicFlowModal,
5718
4514
  __spreadProps(__spreadValues(__spreadValues({}, restProps), rest), {
5719
4515
  features: subflowFeatures,
@@ -5872,10 +4668,10 @@ var useWiseToCoreProps = (props) => {
5872
4668
  onLog
5873
4669
  } = props;
5874
4670
  const httpClient = useWiseHttpClient(customFetch);
5875
- const mergedRenderers = useMemo3(() => getMergedRenderers(props), [renderers]);
4671
+ const mergedRenderers = useMemo2(() => getMergedRenderers(props), [renderers]);
5876
4672
  const createSnackBar = useCreateSnackBar();
5877
- const logEvent = useMemo3(() => getLogEvent(onLog), [onLog]);
5878
- const trackEvent = useMemo3(() => getTrackEvent(onEvent, onAnalytics), [onEvent, onAnalytics]);
4673
+ const logEvent = useMemo2(() => getLogEvent(onLog), [onLog]);
4674
+ const trackEvent = useMemo2(() => getTrackEvent(onEvent, onAnalytics), [onEvent, onAnalytics]);
5879
4675
  const onCopy = useOnCopy();
5880
4676
  return __spreadProps(__spreadValues({}, props), {
5881
4677
  httpClient,
@@ -5907,13 +4703,13 @@ var openLinkInNewTab = (url) => {
5907
4703
  };
5908
4704
 
5909
4705
  // src/dynamicFlow/DynamicFlow.tsx
5910
- import { jsxs as jsxs37 } from "react/jsx-runtime";
4706
+ import { jsxs as jsxs36 } from "react/jsx-runtime";
5911
4707
  function DynamicFlow(props) {
5912
4708
  const { className = "" } = props;
5913
4709
  const dfProps = useWiseToCoreProps(props);
5914
4710
  const df = useDynamicFlow(dfProps);
5915
4711
  const { onContextMenu, contextMenu } = useDFContextMenu(df.controller);
5916
- return /* @__PURE__ */ jsxs37("div", { className, onContextMenu, children: [
4712
+ return /* @__PURE__ */ jsxs36("div", { className, onContextMenu, children: [
5917
4713
  df.view,
5918
4714
  contextMenu
5919
4715
  ] });
@@ -5925,7 +4721,7 @@ import {
5925
4721
  useImperativeHandle
5926
4722
  } from "react";
5927
4723
  import { useDynamicFlow as useDynamicFlow2 } from "@wise/dynamic-flow-client";
5928
- import { jsx as jsx101 } from "react/jsx-runtime";
4724
+ import { jsx as jsx94 } from "react/jsx-runtime";
5929
4725
  var DynamicFlowWithRef = forwardRef(function DynamicFlowWithRef2(props, ref) {
5930
4726
  const { className = "" } = props;
5931
4727
  const dfProps = useWiseToCoreProps(props);
@@ -5941,14 +4737,14 @@ var DynamicFlowWithRef = forwardRef(function DynamicFlowWithRef2(props, ref) {
5941
4737
  }),
5942
4738
  [df]
5943
4739
  );
5944
- return /* @__PURE__ */ jsx101("div", { className, children: df.view });
4740
+ return /* @__PURE__ */ jsx94("div", { className, children: df.view });
5945
4741
  });
5946
4742
 
5947
4743
  // src/index.ts
5948
4744
  import { findRendererPropsByType } from "@wise/dynamic-flow-client";
5949
4745
 
5950
4746
  // src/dynamicFlow/renderers.tsx
5951
- var Header10 = Header;
4747
+ var Header10 = Header5;
5952
4748
  var Media2 = Media;
5953
4749
  var getMargin2 = getMargin;
5954
4750