@wise/dynamic-flow-client-internal 5.23.0-experimental-2dcb025 → 5.23.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/build/main.js CHANGED
@@ -145,7 +145,7 @@ var import_dynamic_flow_client4 = require("@wise/dynamic-flow-client");
145
145
  // src/dynamicFlow/telemetry/app-version.ts
146
146
  var appVersion = (
147
147
  // eslint-disable-next-line @typescript-eslint/no-unsafe-member-access
148
- typeof process !== "undefined" ? "5.22.0" : "0.0.0"
148
+ typeof process !== "undefined" ? "5.23.0" : "0.0.0"
149
149
  );
150
150
 
151
151
  // src/dynamicFlow/context-menu/useContextMenu.tsx
@@ -1119,1383 +1119,49 @@ var getInlineAlertOrValidation = (validationState, inlineAlert) => {
1119
1119
  };
1120
1120
  var CheckboxInputRenderer_default = CheckboxInputRenderer;
1121
1121
 
1122
- // ../renderers/src/CollectionRenderer/CollectionRenderer.tsx
1123
- var import_components19 = require("@transferwise/components");
1124
-
1125
- // ../../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
1126
- var React = __toESM(require("react"), 1);
1127
- var import_react_dom = require("react-dom");
1128
-
1129
- // ../../node_modules/.pnpm/@tanstack+virtual-core@3.14.0/node_modules/@tanstack/virtual-core/dist/esm/utils.js
1130
- function memo(getDeps, fn, opts) {
1131
- var _a;
1132
- let deps = (_a = opts.initialDeps) != null ? _a : [];
1133
- let result;
1134
- let isInitial = true;
1135
- function memoizedFunction() {
1136
- var _a2, _b, _c;
1137
- let depTime;
1138
- if (opts.key && ((_a2 = opts.debug) == null ? void 0 : _a2.call(opts))) depTime = Date.now();
1139
- const newDeps = getDeps();
1140
- const depsChanged = newDeps.length !== deps.length || newDeps.some((dep, index) => deps[index] !== dep);
1141
- if (!depsChanged) {
1142
- return result;
1143
- }
1144
- deps = newDeps;
1145
- let resultTime;
1146
- if (opts.key && ((_b = opts.debug) == null ? void 0 : _b.call(opts))) resultTime = Date.now();
1147
- result = fn(...newDeps);
1148
- if (opts.key && ((_c = opts.debug) == null ? void 0 : _c.call(opts))) {
1149
- const depEndTime = Math.round((Date.now() - depTime) * 100) / 100;
1150
- const resultEndTime = Math.round((Date.now() - resultTime) * 100) / 100;
1151
- const resultFpsPercentage = resultEndTime / 16;
1152
- const pad = (str, num) => {
1153
- str = String(str);
1154
- while (str.length < num) {
1155
- str = " " + str;
1156
- }
1157
- return str;
1158
- };
1159
- console.info(
1160
- `%c\u23F1 ${pad(resultEndTime, 5)} /${pad(depEndTime, 5)} ms`,
1161
- `
1162
- font-size: .6rem;
1163
- font-weight: bold;
1164
- color: hsl(${Math.max(
1165
- 0,
1166
- Math.min(120 - 120 * resultFpsPercentage, 120)
1167
- )}deg 100% 31%);`,
1168
- opts == null ? void 0 : opts.key
1169
- );
1170
- }
1171
- if ((opts == null ? void 0 : opts.onChange) && !(isInitial && opts.skipInitialOnChange)) {
1172
- opts.onChange(result);
1173
- }
1174
- isInitial = false;
1175
- return result;
1176
- }
1177
- memoizedFunction.updateDeps = (newDeps) => {
1178
- deps = newDeps;
1179
- };
1180
- return memoizedFunction;
1181
- }
1182
- function notUndefined(value, msg) {
1183
- if (value === void 0) {
1184
- throw new Error(`Unexpected undefined${msg ? `: ${msg}` : ""}`);
1185
- } else {
1186
- return value;
1187
- }
1188
- }
1189
- var approxEqual = (a, b) => Math.abs(a - b) < 1.01;
1190
- var debounce = (targetWindow, fn, ms) => {
1191
- let timeoutId;
1192
- return function(...args) {
1193
- targetWindow.clearTimeout(timeoutId);
1194
- timeoutId = targetWindow.setTimeout(() => fn.apply(this, args), ms);
1195
- };
1196
- };
1197
-
1198
- // ../../node_modules/.pnpm/@tanstack+virtual-core@3.14.0/node_modules/@tanstack/virtual-core/dist/esm/index.js
1199
- var defaultKeyExtractor = (index) => index;
1200
- var defaultRangeExtractor = (range) => {
1201
- const start = Math.max(range.startIndex - range.overscan, 0);
1202
- const end = Math.min(range.endIndex + range.overscan, range.count - 1);
1203
- const arr = [];
1204
- for (let i = start; i <= end; i++) {
1205
- arr.push(i);
1206
- }
1207
- return arr;
1208
- };
1209
- var addEventListenerOptions = {
1210
- passive: true
1211
- };
1212
- var observeWindowRect = (instance, cb) => {
1213
- const element = instance.scrollElement;
1214
- if (!element) {
1215
- return;
1216
- }
1217
- const handler = () => {
1218
- cb({ width: element.innerWidth, height: element.innerHeight });
1219
- };
1220
- handler();
1221
- element.addEventListener("resize", handler, addEventListenerOptions);
1222
- return () => {
1223
- element.removeEventListener("resize", handler);
1224
- };
1225
- };
1226
- var supportsScrollend = typeof window == "undefined" ? true : "onscrollend" in window;
1227
- var observeWindowOffset = (instance, cb) => {
1228
- const element = instance.scrollElement;
1229
- if (!element) {
1230
- return;
1231
- }
1232
- const targetWindow = instance.targetWindow;
1233
- if (!targetWindow) {
1234
- return;
1235
- }
1236
- let offset = 0;
1237
- const fallback = instance.options.useScrollendEvent && supportsScrollend ? () => void 0 : debounce(
1238
- targetWindow,
1239
- () => {
1240
- cb(offset, false);
1241
- },
1242
- instance.options.isScrollingResetDelay
1243
- );
1244
- const createHandler = (isScrolling) => () => {
1245
- offset = element[instance.options.horizontal ? "scrollX" : "scrollY"];
1246
- fallback();
1247
- cb(offset, isScrolling);
1248
- };
1249
- const handler = createHandler(true);
1250
- const endHandler = createHandler(false);
1251
- element.addEventListener("scroll", handler, addEventListenerOptions);
1252
- const registerScrollendEvent = instance.options.useScrollendEvent && supportsScrollend;
1253
- if (registerScrollendEvent) {
1254
- element.addEventListener("scrollend", endHandler, addEventListenerOptions);
1255
- }
1256
- return () => {
1257
- element.removeEventListener("scroll", handler);
1258
- if (registerScrollendEvent) {
1259
- element.removeEventListener("scrollend", endHandler);
1260
- }
1261
- };
1262
- };
1263
- var measureElement = (element, entry, instance) => {
1264
- if (entry == null ? void 0 : entry.borderBoxSize) {
1265
- const box = entry.borderBoxSize[0];
1266
- if (box) {
1267
- const size = Math.round(
1268
- box[instance.options.horizontal ? "inlineSize" : "blockSize"]
1269
- );
1270
- return size;
1271
- }
1272
- }
1273
- return element[instance.options.horizontal ? "offsetWidth" : "offsetHeight"];
1274
- };
1275
- var windowScroll = (offset, {
1276
- adjustments = 0,
1277
- behavior
1278
- }, instance) => {
1279
- var _a, _b;
1280
- const toOffset = offset + adjustments;
1281
- (_b = (_a = instance.scrollElement) == null ? void 0 : _a.scrollTo) == null ? void 0 : _b.call(_a, {
1282
- [instance.options.horizontal ? "left" : "top"]: toOffset,
1283
- behavior
1284
- });
1285
- };
1286
- var Virtualizer = class {
1287
- constructor(opts) {
1288
- this.unsubs = [];
1289
- this.scrollElement = null;
1290
- this.targetWindow = null;
1291
- this.isScrolling = false;
1292
- this.scrollState = null;
1293
- this.measurementsCache = [];
1294
- this.itemSizeCache = /* @__PURE__ */ new Map();
1295
- this.laneAssignments = /* @__PURE__ */ new Map();
1296
- this.pendingMeasuredCacheIndexes = [];
1297
- this.prevLanes = void 0;
1298
- this.lanesChangedFlag = false;
1299
- this.lanesSettling = false;
1300
- this.scrollRect = null;
1301
- this.scrollOffset = null;
1302
- this.scrollDirection = null;
1303
- this.scrollAdjustments = 0;
1304
- this.elementsCache = /* @__PURE__ */ new Map();
1305
- this.now = () => {
1306
- var _a2;
1307
- var _a, _b, _c;
1308
- 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();
1309
- };
1310
- this.observer = /* @__PURE__ */ (() => {
1311
- let _ro = null;
1312
- const get = () => {
1313
- if (_ro) {
1314
- return _ro;
1315
- }
1316
- if (!this.targetWindow || !this.targetWindow.ResizeObserver) {
1317
- return null;
1318
- }
1319
- return _ro = new this.targetWindow.ResizeObserver((entries) => {
1320
- entries.forEach((entry) => {
1321
- const run = () => {
1322
- const node = entry.target;
1323
- const index = this.indexFromElement(node);
1324
- if (!node.isConnected) {
1325
- this.observer.unobserve(node);
1326
- return;
1327
- }
1328
- if (this.shouldMeasureDuringScroll(index)) {
1329
- this.resizeItem(
1330
- index,
1331
- this.options.measureElement(node, entry, this)
1332
- );
1333
- }
1334
- };
1335
- this.options.useAnimationFrameWithResizeObserver ? requestAnimationFrame(run) : run();
1336
- });
1337
- });
1338
- };
1339
- return {
1340
- disconnect: () => {
1341
- var _a;
1342
- (_a = get()) == null ? void 0 : _a.disconnect();
1343
- _ro = null;
1344
- },
1345
- observe: (target) => {
1346
- var _a;
1347
- return (_a = get()) == null ? void 0 : _a.observe(target, { box: "border-box" });
1348
- },
1349
- unobserve: (target) => {
1350
- var _a;
1351
- return (_a = get()) == null ? void 0 : _a.unobserve(target);
1352
- }
1353
- };
1354
- })();
1355
- this.range = null;
1356
- this.setOptions = (opts2) => {
1357
- Object.entries(opts2).forEach(([key, value]) => {
1358
- if (typeof value === "undefined") delete opts2[key];
1359
- });
1360
- this.options = __spreadValues({
1361
- debug: false,
1362
- initialOffset: 0,
1363
- overscan: 1,
1364
- paddingStart: 0,
1365
- paddingEnd: 0,
1366
- scrollPaddingStart: 0,
1367
- scrollPaddingEnd: 0,
1368
- horizontal: false,
1369
- getItemKey: defaultKeyExtractor,
1370
- rangeExtractor: defaultRangeExtractor,
1371
- onChange: () => {
1372
- },
1373
- measureElement,
1374
- initialRect: { width: 0, height: 0 },
1375
- scrollMargin: 0,
1376
- gap: 0,
1377
- indexAttribute: "data-index",
1378
- initialMeasurementsCache: [],
1379
- lanes: 1,
1380
- isScrollingResetDelay: 150,
1381
- enabled: true,
1382
- isRtl: false,
1383
- useScrollendEvent: false,
1384
- useAnimationFrameWithResizeObserver: false,
1385
- laneAssignmentMode: "estimate"
1386
- }, opts2);
1387
- };
1388
- this.notify = (sync) => {
1389
- var _a, _b;
1390
- (_b = (_a = this.options).onChange) == null ? void 0 : _b.call(_a, this, sync);
1391
- };
1392
- this.maybeNotify = memo(
1393
- () => {
1394
- this.calculateRange();
1395
- return [
1396
- this.isScrolling,
1397
- this.range ? this.range.startIndex : null,
1398
- this.range ? this.range.endIndex : null
1399
- ];
1400
- },
1401
- (isScrolling) => {
1402
- this.notify(isScrolling);
1403
- },
1404
- {
1405
- key: "maybeNotify",
1406
- debug: () => this.options.debug,
1407
- initialDeps: [
1408
- this.isScrolling,
1409
- this.range ? this.range.startIndex : null,
1410
- this.range ? this.range.endIndex : null
1411
- ]
1412
- }
1413
- );
1414
- this.cleanup = () => {
1415
- this.unsubs.filter(Boolean).forEach((d) => d());
1416
- this.unsubs = [];
1417
- this.observer.disconnect();
1418
- if (this.rafId != null && this.targetWindow) {
1419
- this.targetWindow.cancelAnimationFrame(this.rafId);
1420
- this.rafId = null;
1421
- }
1422
- this.scrollState = null;
1423
- this.scrollElement = null;
1424
- this.targetWindow = null;
1425
- };
1426
- this._didMount = () => {
1427
- return () => {
1428
- this.cleanup();
1429
- };
1430
- };
1431
- this._willUpdate = () => {
1432
- var _a2;
1433
- var _a;
1434
- const scrollElement = this.options.enabled ? this.options.getScrollElement() : null;
1435
- if (this.scrollElement !== scrollElement) {
1436
- this.cleanup();
1437
- if (!scrollElement) {
1438
- this.maybeNotify();
1439
- return;
1440
- }
1441
- this.scrollElement = scrollElement;
1442
- if (this.scrollElement && "ownerDocument" in this.scrollElement) {
1443
- this.targetWindow = this.scrollElement.ownerDocument.defaultView;
1444
- } else {
1445
- this.targetWindow = (_a2 = (_a = this.scrollElement) == null ? void 0 : _a.window) != null ? _a2 : null;
1446
- }
1447
- this.elementsCache.forEach((cached) => {
1448
- this.observer.observe(cached);
1449
- });
1450
- this.unsubs.push(
1451
- this.options.observeElementRect(this, (rect) => {
1452
- this.scrollRect = rect;
1453
- this.maybeNotify();
1454
- })
1455
- );
1456
- this.unsubs.push(
1457
- this.options.observeElementOffset(this, (offset, isScrolling) => {
1458
- this.scrollAdjustments = 0;
1459
- this.scrollDirection = isScrolling ? this.getScrollOffset() < offset ? "forward" : "backward" : null;
1460
- this.scrollOffset = offset;
1461
- this.isScrolling = isScrolling;
1462
- if (this.scrollState) {
1463
- this.scheduleScrollReconcile();
1464
- }
1465
- this.maybeNotify();
1466
- })
1467
- );
1468
- this._scrollToOffset(this.getScrollOffset(), {
1469
- adjustments: void 0,
1470
- behavior: void 0
1471
- });
1472
- }
1473
- };
1474
- this.rafId = null;
1475
- this.getSize = () => {
1476
- var _a;
1477
- if (!this.options.enabled) {
1478
- this.scrollRect = null;
1479
- return 0;
1480
- }
1481
- this.scrollRect = (_a = this.scrollRect) != null ? _a : this.options.initialRect;
1482
- return this.scrollRect[this.options.horizontal ? "width" : "height"];
1483
- };
1484
- this.getScrollOffset = () => {
1485
- var _a;
1486
- if (!this.options.enabled) {
1487
- this.scrollOffset = null;
1488
- return 0;
1489
- }
1490
- this.scrollOffset = (_a = this.scrollOffset) != null ? _a : typeof this.options.initialOffset === "function" ? this.options.initialOffset() : this.options.initialOffset;
1491
- return this.scrollOffset;
1492
- };
1493
- this.getFurthestMeasurement = (measurements, index) => {
1494
- const furthestMeasurementsFound = /* @__PURE__ */ new Map();
1495
- const furthestMeasurements = /* @__PURE__ */ new Map();
1496
- for (let m = index - 1; m >= 0; m--) {
1497
- const measurement = measurements[m];
1498
- if (furthestMeasurementsFound.has(measurement.lane)) {
1499
- continue;
1500
- }
1501
- const previousFurthestMeasurement = furthestMeasurements.get(
1502
- measurement.lane
1503
- );
1504
- if (previousFurthestMeasurement == null || measurement.end > previousFurthestMeasurement.end) {
1505
- furthestMeasurements.set(measurement.lane, measurement);
1506
- } else if (measurement.end < previousFurthestMeasurement.end) {
1507
- furthestMeasurementsFound.set(measurement.lane, true);
1508
- }
1509
- if (furthestMeasurementsFound.size === this.options.lanes) {
1510
- break;
1511
- }
1512
- }
1513
- return furthestMeasurements.size === this.options.lanes ? Array.from(furthestMeasurements.values()).sort((a, b) => {
1514
- if (a.end === b.end) {
1515
- return a.index - b.index;
1516
- }
1517
- return a.end - b.end;
1518
- })[0] : void 0;
1519
- };
1520
- this.getMeasurementOptions = memo(
1521
- () => [
1522
- this.options.count,
1523
- this.options.paddingStart,
1524
- this.options.scrollMargin,
1525
- this.options.getItemKey,
1526
- this.options.enabled,
1527
- this.options.lanes,
1528
- this.options.laneAssignmentMode
1529
- ],
1530
- (count, paddingStart, scrollMargin, getItemKey, enabled, lanes, laneAssignmentMode) => {
1531
- const lanesChanged = this.prevLanes !== void 0 && this.prevLanes !== lanes;
1532
- if (lanesChanged) {
1533
- this.lanesChangedFlag = true;
1534
- }
1535
- this.prevLanes = lanes;
1536
- this.pendingMeasuredCacheIndexes = [];
1537
- return {
1538
- count,
1539
- paddingStart,
1540
- scrollMargin,
1541
- getItemKey,
1542
- enabled,
1543
- lanes,
1544
- laneAssignmentMode
1545
- };
1546
- },
1547
- {
1548
- key: false
1549
- }
1550
- );
1551
- this.getMeasurements = memo(
1552
- () => [this.getMeasurementOptions(), this.itemSizeCache],
1553
- ({
1554
- count,
1555
- paddingStart,
1556
- scrollMargin,
1557
- getItemKey,
1558
- enabled,
1559
- lanes,
1560
- laneAssignmentMode
1561
- }, itemSizeCache) => {
1562
- if (!enabled) {
1563
- this.measurementsCache = [];
1564
- this.itemSizeCache.clear();
1565
- this.laneAssignments.clear();
1566
- return [];
1567
- }
1568
- if (this.laneAssignments.size > count) {
1569
- for (const index of this.laneAssignments.keys()) {
1570
- if (index >= count) {
1571
- this.laneAssignments.delete(index);
1572
- }
1573
- }
1574
- }
1575
- if (this.lanesChangedFlag) {
1576
- this.lanesChangedFlag = false;
1577
- this.lanesSettling = true;
1578
- this.measurementsCache = [];
1579
- this.itemSizeCache.clear();
1580
- this.laneAssignments.clear();
1581
- this.pendingMeasuredCacheIndexes = [];
1582
- }
1583
- if (this.measurementsCache.length === 0 && !this.lanesSettling) {
1584
- this.measurementsCache = this.options.initialMeasurementsCache;
1585
- this.measurementsCache.forEach((item) => {
1586
- this.itemSizeCache.set(item.key, item.size);
1587
- });
1588
- }
1589
- const min = this.lanesSettling ? 0 : this.pendingMeasuredCacheIndexes.length > 0 ? Math.min(...this.pendingMeasuredCacheIndexes) : 0;
1590
- this.pendingMeasuredCacheIndexes = [];
1591
- if (this.lanesSettling && this.measurementsCache.length === count) {
1592
- this.lanesSettling = false;
1593
- }
1594
- const measurements = this.measurementsCache.slice(0, min);
1595
- const laneLastIndex = new Array(lanes).fill(
1596
- void 0
1597
- );
1598
- for (let m = 0; m < min; m++) {
1599
- const item = measurements[m];
1600
- if (item) {
1601
- laneLastIndex[item.lane] = m;
1602
- }
1603
- }
1604
- for (let i = min; i < count; i++) {
1605
- const key = getItemKey(i);
1606
- const cachedLane = this.laneAssignments.get(i);
1607
- let lane;
1608
- let start;
1609
- const shouldCacheLane = laneAssignmentMode === "estimate" || itemSizeCache.has(key);
1610
- if (cachedLane !== void 0 && this.options.lanes > 1) {
1611
- lane = cachedLane;
1612
- const prevIndex = laneLastIndex[lane];
1613
- const prevInLane = prevIndex !== void 0 ? measurements[prevIndex] : void 0;
1614
- start = prevInLane ? prevInLane.end + this.options.gap : paddingStart + scrollMargin;
1615
- } else {
1616
- const furthestMeasurement = this.options.lanes === 1 ? measurements[i - 1] : this.getFurthestMeasurement(measurements, i);
1617
- start = furthestMeasurement ? furthestMeasurement.end + this.options.gap : paddingStart + scrollMargin;
1618
- lane = furthestMeasurement ? furthestMeasurement.lane : i % this.options.lanes;
1619
- if (this.options.lanes > 1 && shouldCacheLane) {
1620
- this.laneAssignments.set(i, lane);
1621
- }
1622
- }
1623
- const measuredSize = itemSizeCache.get(key);
1624
- const size = typeof measuredSize === "number" ? measuredSize : this.options.estimateSize(i);
1625
- const end = start + size;
1626
- measurements[i] = {
1627
- index: i,
1628
- start,
1629
- size,
1630
- end,
1631
- key,
1632
- lane
1633
- };
1634
- laneLastIndex[lane] = i;
1635
- }
1636
- this.measurementsCache = measurements;
1637
- return measurements;
1638
- },
1639
- {
1640
- key: "getMeasurements",
1641
- debug: () => this.options.debug
1642
- }
1643
- );
1644
- this.calculateRange = memo(
1645
- () => [
1646
- this.getMeasurements(),
1647
- this.getSize(),
1648
- this.getScrollOffset(),
1649
- this.options.lanes
1650
- ],
1651
- (measurements, outerSize, scrollOffset, lanes) => {
1652
- return this.range = measurements.length > 0 && outerSize > 0 ? calculateRange({
1653
- measurements,
1654
- outerSize,
1655
- scrollOffset,
1656
- lanes
1657
- }) : null;
1658
- },
1659
- {
1660
- key: "calculateRange",
1661
- debug: () => this.options.debug
1662
- }
1663
- );
1664
- this.getVirtualIndexes = memo(
1665
- () => {
1666
- let startIndex = null;
1667
- let endIndex = null;
1668
- const range = this.calculateRange();
1669
- if (range) {
1670
- startIndex = range.startIndex;
1671
- endIndex = range.endIndex;
1672
- }
1673
- this.maybeNotify.updateDeps([this.isScrolling, startIndex, endIndex]);
1674
- return [
1675
- this.options.rangeExtractor,
1676
- this.options.overscan,
1677
- this.options.count,
1678
- startIndex,
1679
- endIndex
1680
- ];
1681
- },
1682
- (rangeExtractor, overscan, count, startIndex, endIndex) => {
1683
- return startIndex === null || endIndex === null ? [] : rangeExtractor({
1684
- startIndex,
1685
- endIndex,
1686
- overscan,
1687
- count
1688
- });
1689
- },
1690
- {
1691
- key: "getVirtualIndexes",
1692
- debug: () => this.options.debug
1693
- }
1694
- );
1695
- this.indexFromElement = (node) => {
1696
- const attributeName = this.options.indexAttribute;
1697
- const indexStr = node.getAttribute(attributeName);
1698
- if (!indexStr) {
1699
- console.warn(
1700
- `Missing attribute name '${attributeName}={index}' on measured element.`
1701
- );
1702
- return -1;
1703
- }
1704
- return parseInt(indexStr, 10);
1705
- };
1706
- this.shouldMeasureDuringScroll = (index) => {
1707
- var _a2;
1708
- var _a;
1709
- if (!this.scrollState || this.scrollState.behavior !== "smooth") {
1710
- return true;
1711
- }
1712
- const scrollIndex = (_a2 = this.scrollState.index) != null ? _a2 : (_a = this.getVirtualItemForOffset(this.scrollState.lastTargetOffset)) == null ? void 0 : _a.index;
1713
- if (scrollIndex !== void 0 && this.range) {
1714
- const bufferSize = Math.max(
1715
- this.options.overscan,
1716
- Math.ceil((this.range.endIndex - this.range.startIndex) / 2)
1717
- );
1718
- const minIndex = Math.max(0, scrollIndex - bufferSize);
1719
- const maxIndex = Math.min(
1720
- this.options.count - 1,
1721
- scrollIndex + bufferSize
1722
- );
1723
- return index >= minIndex && index <= maxIndex;
1724
- }
1725
- return true;
1726
- };
1727
- this.measureElement = (node) => {
1728
- if (!node) {
1729
- this.elementsCache.forEach((cached, key2) => {
1730
- if (!cached.isConnected) {
1731
- this.observer.unobserve(cached);
1732
- this.elementsCache.delete(key2);
1733
- }
1734
- });
1735
- return;
1736
- }
1737
- const index = this.indexFromElement(node);
1738
- const key = this.options.getItemKey(index);
1739
- const prevNode = this.elementsCache.get(key);
1740
- if (prevNode !== node) {
1741
- if (prevNode) {
1742
- this.observer.unobserve(prevNode);
1743
- }
1744
- this.observer.observe(node);
1745
- this.elementsCache.set(key, node);
1746
- }
1747
- if ((!this.isScrolling || this.scrollState) && this.shouldMeasureDuringScroll(index)) {
1748
- this.resizeItem(index, this.options.measureElement(node, void 0, this));
1749
- }
1750
- };
1751
- this.resizeItem = (index, size) => {
1752
- var _a2;
1753
- var _a;
1754
- const item = this.measurementsCache[index];
1755
- if (!item) return;
1756
- const itemSize = (_a2 = this.itemSizeCache.get(item.key)) != null ? _a2 : item.size;
1757
- const delta = size - itemSize;
1758
- if (delta !== 0) {
1759
- 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)) {
1760
- if (this.options.debug) {
1761
- console.info("correction", delta);
1762
- }
1763
- this._scrollToOffset(this.getScrollOffset(), {
1764
- adjustments: this.scrollAdjustments += delta,
1765
- behavior: void 0
1766
- });
1767
- }
1768
- this.pendingMeasuredCacheIndexes.push(item.index);
1769
- this.itemSizeCache = new Map(this.itemSizeCache.set(item.key, size));
1770
- this.notify(false);
1771
- }
1772
- };
1773
- this.getVirtualItems = memo(
1774
- () => [this.getVirtualIndexes(), this.getMeasurements()],
1775
- (indexes, measurements) => {
1776
- const virtualItems = [];
1777
- for (let k = 0, len = indexes.length; k < len; k++) {
1778
- const i = indexes[k];
1779
- const measurement = measurements[i];
1780
- virtualItems.push(measurement);
1781
- }
1782
- return virtualItems;
1783
- },
1784
- {
1785
- key: "getVirtualItems",
1786
- debug: () => this.options.debug
1787
- }
1788
- );
1789
- this.getVirtualItemForOffset = (offset) => {
1790
- const measurements = this.getMeasurements();
1791
- if (measurements.length === 0) {
1792
- return void 0;
1793
- }
1794
- return notUndefined(
1795
- measurements[findNearestBinarySearch(
1796
- 0,
1797
- measurements.length - 1,
1798
- (index) => notUndefined(measurements[index]).start,
1799
- offset
1800
- )]
1801
- );
1802
- };
1803
- this.getMaxScrollOffset = () => {
1804
- if (!this.scrollElement) return 0;
1805
- if ("scrollHeight" in this.scrollElement) {
1806
- return this.options.horizontal ? this.scrollElement.scrollWidth - this.scrollElement.clientWidth : this.scrollElement.scrollHeight - this.scrollElement.clientHeight;
1807
- } else {
1808
- const doc = this.scrollElement.document.documentElement;
1809
- return this.options.horizontal ? doc.scrollWidth - this.scrollElement.innerWidth : doc.scrollHeight - this.scrollElement.innerHeight;
1810
- }
1811
- };
1812
- this.getOffsetForAlignment = (toOffset, align, itemSize = 0) => {
1813
- if (!this.scrollElement) return 0;
1814
- const size = this.getSize();
1815
- const scrollOffset = this.getScrollOffset();
1816
- if (align === "auto") {
1817
- align = toOffset >= scrollOffset + size ? "end" : "start";
1818
- }
1819
- if (align === "center") {
1820
- toOffset += (itemSize - size) / 2;
1821
- } else if (align === "end") {
1822
- toOffset -= size;
1823
- }
1824
- const maxOffset = this.getMaxScrollOffset();
1825
- return Math.max(Math.min(maxOffset, toOffset), 0);
1826
- };
1827
- this.getOffsetForIndex = (index, align = "auto") => {
1828
- index = Math.max(0, Math.min(index, this.options.count - 1));
1829
- const size = this.getSize();
1830
- const scrollOffset = this.getScrollOffset();
1831
- const item = this.measurementsCache[index];
1832
- if (!item) return;
1833
- if (align === "auto") {
1834
- if (item.end >= scrollOffset + size - this.options.scrollPaddingEnd) {
1835
- align = "end";
1836
- } else if (item.start <= scrollOffset + this.options.scrollPaddingStart) {
1837
- align = "start";
1838
- } else {
1839
- return [scrollOffset, align];
1840
- }
1841
- }
1842
- if (align === "end" && index === this.options.count - 1) {
1843
- return [this.getMaxScrollOffset(), align];
1844
- }
1845
- const toOffset = align === "end" ? item.end + this.options.scrollPaddingEnd : item.start - this.options.scrollPaddingStart;
1846
- return [
1847
- this.getOffsetForAlignment(toOffset, align, item.size),
1848
- align
1849
- ];
1850
- };
1851
- this.scrollToOffset = (toOffset, { align = "start", behavior = "auto" } = {}) => {
1852
- const offset = this.getOffsetForAlignment(toOffset, align);
1853
- const now = this.now();
1854
- this.scrollState = {
1855
- index: null,
1856
- align,
1857
- behavior,
1858
- startedAt: now,
1859
- lastTargetOffset: offset,
1860
- stableFrames: 0
1861
- };
1862
- this._scrollToOffset(offset, { adjustments: void 0, behavior });
1863
- this.scheduleScrollReconcile();
1864
- };
1865
- this.scrollToIndex = (index, {
1866
- align: initialAlign = "auto",
1867
- behavior = "auto"
1868
- } = {}) => {
1869
- index = Math.max(0, Math.min(index, this.options.count - 1));
1870
- const offsetInfo = this.getOffsetForIndex(index, initialAlign);
1871
- if (!offsetInfo) {
1872
- return;
1873
- }
1874
- const [offset, align] = offsetInfo;
1875
- const now = this.now();
1876
- this.scrollState = {
1877
- index,
1878
- align,
1879
- behavior,
1880
- startedAt: now,
1881
- lastTargetOffset: offset,
1882
- stableFrames: 0
1883
- };
1884
- this._scrollToOffset(offset, { adjustments: void 0, behavior });
1885
- this.scheduleScrollReconcile();
1886
- };
1887
- this.scrollBy = (delta, { behavior = "auto" } = {}) => {
1888
- const offset = this.getScrollOffset() + delta;
1889
- const now = this.now();
1890
- this.scrollState = {
1891
- index: null,
1892
- align: "start",
1893
- behavior,
1894
- startedAt: now,
1895
- lastTargetOffset: offset,
1896
- stableFrames: 0
1897
- };
1898
- this._scrollToOffset(offset, { adjustments: void 0, behavior });
1899
- this.scheduleScrollReconcile();
1900
- };
1901
- this.getTotalSize = () => {
1902
- var _a2;
1903
- var _a;
1904
- const measurements = this.getMeasurements();
1905
- let end;
1906
- if (measurements.length === 0) {
1907
- end = this.options.paddingStart;
1908
- } else if (this.options.lanes === 1) {
1909
- end = (_a2 = (_a = measurements[measurements.length - 1]) == null ? void 0 : _a.end) != null ? _a2 : 0;
1910
- } else {
1911
- const endByLane = Array(this.options.lanes).fill(null);
1912
- let endIndex = measurements.length - 1;
1913
- while (endIndex >= 0 && endByLane.some((val) => val === null)) {
1914
- const item = measurements[endIndex];
1915
- if (endByLane[item.lane] === null) {
1916
- endByLane[item.lane] = item.end;
1917
- }
1918
- endIndex--;
1919
- }
1920
- end = Math.max(...endByLane.filter((val) => val !== null));
1921
- }
1922
- return Math.max(
1923
- end - this.options.scrollMargin + this.options.paddingEnd,
1924
- 0
1925
- );
1926
- };
1927
- this._scrollToOffset = (offset, {
1928
- adjustments,
1929
- behavior
1930
- }) => {
1931
- this.options.scrollToFn(offset, { behavior, adjustments }, this);
1932
- };
1933
- this.measure = () => {
1934
- this.itemSizeCache = /* @__PURE__ */ new Map();
1935
- this.laneAssignments = /* @__PURE__ */ new Map();
1936
- this.notify(false);
1937
- };
1938
- this.setOptions(opts);
1939
- }
1940
- scheduleScrollReconcile() {
1941
- if (!this.targetWindow) {
1942
- this.scrollState = null;
1943
- return;
1944
- }
1945
- if (this.rafId != null) return;
1946
- this.rafId = this.targetWindow.requestAnimationFrame(() => {
1947
- this.rafId = null;
1948
- this.reconcileScroll();
1949
- });
1950
- }
1951
- reconcileScroll() {
1952
- if (!this.scrollState) return;
1953
- const el = this.scrollElement;
1954
- if (!el) return;
1955
- const MAX_RECONCILE_MS = 5e3;
1956
- if (this.now() - this.scrollState.startedAt > MAX_RECONCILE_MS) {
1957
- this.scrollState = null;
1958
- return;
1959
- }
1960
- const offsetInfo = this.scrollState.index != null ? this.getOffsetForIndex(this.scrollState.index, this.scrollState.align) : void 0;
1961
- const targetOffset = offsetInfo ? offsetInfo[0] : this.scrollState.lastTargetOffset;
1962
- const STABLE_FRAMES = 1;
1963
- const targetChanged = targetOffset !== this.scrollState.lastTargetOffset;
1964
- if (!targetChanged && approxEqual(targetOffset, this.getScrollOffset())) {
1965
- this.scrollState.stableFrames++;
1966
- if (this.scrollState.stableFrames >= STABLE_FRAMES) {
1967
- this.scrollState = null;
1968
- return;
1969
- }
1970
- } else {
1971
- this.scrollState.stableFrames = 0;
1972
- if (targetChanged) {
1973
- this.scrollState.lastTargetOffset = targetOffset;
1974
- this.scrollState.behavior = "auto";
1975
- this._scrollToOffset(targetOffset, {
1976
- adjustments: void 0,
1977
- behavior: "auto"
1978
- });
1979
- }
1980
- }
1981
- this.scheduleScrollReconcile();
1982
- }
1983
- };
1984
- var findNearestBinarySearch = (low, high, getCurrentValue, value) => {
1985
- while (low <= high) {
1986
- const middle = (low + high) / 2 | 0;
1987
- const currentValue = getCurrentValue(middle);
1988
- if (currentValue < value) {
1989
- low = middle + 1;
1990
- } else if (currentValue > value) {
1991
- high = middle - 1;
1992
- } else {
1993
- return middle;
1994
- }
1995
- }
1996
- if (low > 0) {
1997
- return low - 1;
1998
- } else {
1999
- return 0;
2000
- }
2001
- };
2002
- function calculateRange({
2003
- measurements,
2004
- outerSize,
2005
- scrollOffset,
2006
- lanes
2007
- }) {
2008
- const lastIndex = measurements.length - 1;
2009
- const getOffset = (index) => measurements[index].start;
2010
- if (measurements.length <= lanes) {
2011
- return {
2012
- startIndex: 0,
2013
- endIndex: lastIndex
2014
- };
2015
- }
2016
- let startIndex = findNearestBinarySearch(
2017
- 0,
2018
- lastIndex,
2019
- getOffset,
2020
- scrollOffset
2021
- );
2022
- let endIndex = startIndex;
2023
- if (lanes === 1) {
2024
- while (endIndex < lastIndex && measurements[endIndex].end < scrollOffset + outerSize) {
2025
- endIndex++;
2026
- }
2027
- } else if (lanes > 1) {
2028
- const endPerLane = Array(lanes).fill(0);
2029
- while (endIndex < lastIndex && endPerLane.some((pos) => pos < scrollOffset + outerSize)) {
2030
- const item = measurements[endIndex];
2031
- endPerLane[item.lane] = item.end;
2032
- endIndex++;
2033
- }
2034
- const startPerLane = Array(lanes).fill(scrollOffset + outerSize);
2035
- while (startIndex >= 0 && startPerLane.some((pos) => pos >= scrollOffset)) {
2036
- const item = measurements[startIndex];
2037
- startPerLane[item.lane] = item.start;
2038
- startIndex--;
2039
- }
2040
- startIndex = Math.max(0, startIndex - startIndex % lanes);
2041
- endIndex = Math.min(lastIndex, endIndex + (lanes - 1 - endIndex % lanes));
2042
- }
2043
- return { startIndex, endIndex };
2044
- }
2045
-
2046
- // ../../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
2047
- var useIsomorphicLayoutEffect = typeof document !== "undefined" ? React.useLayoutEffect : React.useEffect;
2048
- function useVirtualizerBase(_a) {
2049
- var _b = _a, {
2050
- useFlushSync = true
2051
- } = _b, options = __objRest(_b, [
2052
- "useFlushSync"
2053
- ]);
2054
- const rerender = React.useReducer(() => ({}), {})[1];
2055
- const resolvedOptions = __spreadProps(__spreadValues({}, options), {
2056
- onChange: (instance2, sync) => {
2057
- var _a2;
2058
- if (useFlushSync && sync) {
2059
- (0, import_react_dom.flushSync)(rerender);
2060
- } else {
2061
- rerender();
2062
- }
2063
- (_a2 = options.onChange) == null ? void 0 : _a2.call(options, instance2, sync);
2064
- }
2065
- });
2066
- const [instance] = React.useState(
2067
- () => new Virtualizer(resolvedOptions)
2068
- );
2069
- instance.setOptions(resolvedOptions);
2070
- useIsomorphicLayoutEffect(() => {
2071
- return instance._didMount();
2072
- }, []);
2073
- useIsomorphicLayoutEffect(() => {
2074
- return instance._willUpdate();
2075
- });
2076
- return instance;
2077
- }
2078
- function useWindowVirtualizer(options) {
2079
- return useVirtualizerBase(__spreadValues({
2080
- getScrollElement: () => typeof document !== "undefined" ? window : null,
2081
- observeElementRect: observeWindowRect,
2082
- observeElementOffset: observeWindowOffset,
2083
- scrollToFn: windowScroll,
2084
- initialOffset: () => typeof document !== "undefined" ? window.scrollY : 0
2085
- }, options));
2086
- }
2087
-
2088
- // ../renderers/src/CollectionRenderer/components/ContentComponent.tsx
2089
- var import_components13 = require("@transferwise/components");
2090
- var import_react6 = require("react");
2091
-
2092
- // ../renderers/src/step/StepFooter.tsx
2093
- var import_components12 = require("@transferwise/components");
2094
- var import_react5 = require("react");
2095
- var import_react_intl6 = require("react-intl");
2096
-
2097
- // ../renderers/src/messages/step.messages.ts
2098
- var import_react_intl5 = require("react-intl");
2099
- var step_messages_default = (0, import_react_intl5.defineMessages)({
2100
- scrollToBottom: {
2101
- id: "df.wise.step.scrollToBottom",
2102
- defaultMessage: "Scroll to bottom",
2103
- 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."
2104
- }
2105
- });
2106
-
2107
- // ../renderers/src/step/StepFooter.tsx
2108
- var import_jsx_runtime24 = require("react/jsx-runtime");
2109
- var SCROLL_TO_BOTTOM = "scroll-to-bottom";
2110
- var StepFooter = ({ footer, tags }) => {
2111
- if (tags == null ? void 0 : tags.includes(SCROLL_TO_BOTTOM)) {
2112
- return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(FooterWithScrollButton, { footer });
2113
- }
2114
- return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(DefaultFooter, { footer });
2115
- };
2116
- var DefaultFooter = ({ footer }) => {
2117
- const hasFooter = footer && Array.isArray(footer) && footer.length > 0;
2118
- return hasFooter ? /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { className: "df-step-fixed__footer", children: footer }) : void 0;
2119
- };
2120
- var FooterWithScrollButton = ({ footer }) => {
2121
- const { formatMessage } = (0, import_react_intl6.useIntl)();
2122
- const endOfLayoutRef = (0, import_react5.useRef)(null);
2123
- const isElementVisible = useIsElementVisible(endOfLayoutRef);
2124
- const scrollButton = /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
2125
- import_components12.Button,
2126
- {
2127
- className: "m-b-1",
2128
- v2: true,
2129
- block: true,
2130
- priority: "tertiary",
2131
- onClick: () => {
2132
- var _a;
2133
- (_a = endOfLayoutRef.current) == null ? void 0 : _a.scrollIntoView({ behavior: "smooth" });
2134
- },
2135
- children: formatMessage(step_messages_default.scrollToBottom)
2136
- }
2137
- );
2138
- const hasStepFooterContent = footer && Array.isArray(footer) && footer.length > 0;
2139
- if (isElementVisible && !hasStepFooterContent) {
2140
- return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { ref: endOfLayoutRef, "aria-hidden": "true" });
2141
- }
2142
- return /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(import_jsx_runtime24.Fragment, { children: [
2143
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { ref: endOfLayoutRef, "aria-hidden": "true" }),
2144
- /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)("div", { className: "df-step-fixed__footer", children: [
2145
- !isElementVisible && scrollButton,
2146
- footer
2147
- ] })
2148
- ] });
2149
- };
2150
- var useIsElementVisible = (elementRef) => {
2151
- const [isVisible, setIsVisible] = (0, import_react5.useState)(false);
2152
- (0, import_react5.useEffect)(() => {
2153
- const element = elementRef.current;
2154
- if (!element) return;
2155
- const observer = new IntersectionObserver(([entry]) => {
2156
- setIsVisible(entry.isIntersecting);
2157
- });
2158
- observer.observe(element);
2159
- return () => observer.disconnect();
2160
- }, [elementRef]);
2161
- return isVisible;
2162
- };
2163
-
2164
- // ../renderers/src/CollectionRenderer/components/ContentComponent.tsx
2165
- var import_jsx_runtime25 = require("react/jsx-runtime");
2166
- var ContentComponent = (props) => {
2167
- const { state, status, SectionHeader, Item } = props;
2168
- const endOfContentRef = (0, import_react6.useRef)(null);
2169
- const isBottomVisible = useIsElementVisible(endOfContentRef);
2170
- (0, import_react6.useEffect)(() => {
2171
- var _a;
2172
- if (isBottomVisible && status.type === "idle" && status.loadMore) {
2173
- (_a = status.loadMore) == null ? void 0 : _a.call(status);
2174
- }
2175
- }, [isBottomVisible]);
2176
- const stateCount = state.sections.reduce(
2177
- (total, section) => section.items.length + total + (section.title ? 1 : 0),
2178
- 0
2179
- );
2180
- const items = (0, import_react6.useMemo)(() => {
2181
- return state.sections.reduce((acc, section) => {
2182
- return [
2183
- ...acc,
2184
- ...section.title ? [
2185
- {
2186
- type: "header",
2187
- title: section.title,
2188
- items: section.items,
2189
- id: section.id
2190
- }
2191
- ] : [],
2192
- ...section.items.map((item) => ({
2193
- item,
2194
- type: "item"
2195
- }))
2196
- ];
2197
- }, []);
2198
- }, [stateCount]);
2199
- const listRef = (0, import_react6.useRef)(null);
2200
- const listOffsetRef = (0, import_react6.useRef)(0);
2201
- (0, import_react6.useLayoutEffect)(() => {
2202
- var _a, _b;
2203
- listOffsetRef.current = (_b = (_a = listRef.current) == null ? void 0 : _a.offsetTop) != null ? _b : 0;
2204
- });
2205
- const virtualizer = useWindowVirtualizer({
2206
- count: stateCount,
2207
- estimateSize: () => 120,
2208
- // todo, we could be clever here. Is it worth it?
2209
- overscan: 10,
2210
- scrollMargin: listOffsetRef.current
2211
- });
2212
- return /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("div", { ref: listRef, children: [
2213
- state.beforeSections,
2214
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
2215
- "div",
2216
- {
2217
- style: {
2218
- height: `${virtualizer.getTotalSize()}px`,
2219
- width: "100%",
2220
- position: "relative"
2221
- },
2222
- children: virtualizer.getVirtualItems().map((item) => {
2223
- const i = items[item.index];
2224
- if (!i) {
2225
- return null;
2226
- }
2227
- return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
2228
- "div",
2229
- {
2230
- ref: virtualizer.measureElement,
2231
- "data-index": item.index,
2232
- style: {
2233
- position: "absolute",
2234
- top: 0,
2235
- left: 0,
2236
- width: "100%",
2237
- transform: `translateY(${item.start - virtualizer.options.scrollMargin}px)`
2238
- },
2239
- children: i.type === "header" ? /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(SectionHeader, __spreadValues({}, i)) : /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(Item, __spreadValues({}, i.item))
2240
- },
2241
- item.key
2242
- );
2243
- })
2244
- }
2245
- ),
2246
- /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("div", { ref: endOfContentRef, className: "d-flex m-x-auto m-y-2", children: [
2247
- status.type === "idle" || status.type === "loading" && status.reason === "pagination" ? /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(import_components13.ProcessIndicator, { size: "xs" }) : null,
2248
- status.type === "error" && status.reason === "pagination" ? /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("div", { className: "d-flex m-x-auto", children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(import_components13.Button, { v2: true, size: "sm", priority: "secondary-neutral", onClick: status.retry, children: "Load more" }) }) : null
2249
- ] }),
2250
- state.afterSections
2251
- ] });
2252
- };
2253
-
2254
- // ../renderers/src/CollectionRenderer/components/SearchComponent.tsx
2255
- var import_components14 = require("@transferwise/components");
2256
- var import_icons = require("@transferwise/icons");
2257
- var import_jsx_runtime26 = require("react/jsx-runtime");
2258
- var SearchComponent = ({ state, features }) => {
2259
- const { search } = state;
2260
- if (!search) {
2261
- return;
2262
- }
2263
- return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
2264
- FieldInput_default,
2265
- {
2266
- id: "search",
2267
- description: "",
2268
- validation: void 0,
2269
- help: "",
2270
- label: search.title,
2271
- features,
2272
- children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(import_components14.InputGroup, { addonStart: { content: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(import_icons.Search, { size: 24 }) }, children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
2273
- import_components14.Input,
2274
- {
2275
- id: "search",
2276
- name: "search",
2277
- shape: "pill",
2278
- placeholder: search.hint,
2279
- type: "text",
2280
- value: search.query,
2281
- onChange: ({ currentTarget: { value } }) => {
2282
- search.onChange(value);
2283
- }
2284
- }
2285
- ) })
2286
- }
2287
- );
2288
- };
2289
-
2290
- // ../renderers/src/CollectionRenderer/components/FilterComponent.tsx
2291
- var import_components15 = require("@transferwise/components");
2292
- var import_jsx_runtime27 = require("react/jsx-runtime");
2293
- var FiltersComponent = ({ state }) => {
2294
- const { filters } = state;
2295
- return filters.map((filter) => {
2296
- var _a;
2297
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(FilterComponent, __spreadValues({}, filter), JSON.stringify((_a = filter.options) == null ? void 0 : _a.map((o) => o.value)));
2298
- });
2299
- };
2300
- var FilterComponent = (filter) => {
2301
- const { multiSelect, options } = filter;
2302
- if (!options) {
2303
- return null;
2304
- }
2305
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
2306
- import_components15.Chips,
2307
- {
2308
- className: "m-b-1",
2309
- multiple: multiSelect,
2310
- selected: options.some((option) => option.selected) ? options.filter((option) => option.selected).map((option) => option.value) : multiSelect ? [] : "",
2311
- chips: [
2312
- ...multiSelect ? [
2313
- {
2314
- value: "",
2315
- // this is a placeholder for now, only for single selects, when it is not possible to de-select options
2316
- label: "All"
2317
- }
2318
- ] : [],
2319
- ...options.map((option) => ({
2320
- value: option.value,
2321
- label: option.title
2322
- }))
2323
- ],
2324
- onChange: (value) => {
2325
- var _a;
2326
- if (value.selectedValue === "") {
2327
- options == null ? void 0 : options.filter((option) => option.selected).map((option) => option == null ? void 0 : option.onSelect());
2328
- return;
2329
- }
2330
- (_a = options == null ? void 0 : options.find((option) => value.selectedValue === option.value)) == null ? void 0 : _a.onSelect();
2331
- }
2332
- },
2333
- JSON.stringify(options)
2334
- );
2335
- };
2336
-
2337
- // ../renderers/src/CollectionRenderer/components/ItemComponent.tsx
2338
- var import_components18 = require("@transferwise/components");
2339
-
2340
- // ../renderers/src/utils/listItem/getAdditionalInfo.tsx
2341
- var import_components16 = require("@transferwise/components");
2342
- var import_jsx_runtime28 = require("react/jsx-runtime");
2343
- var getAdditionalInfo = (additionalInfo) => {
2344
- var _a, _b;
2345
- if (!additionalInfo) {
2346
- return void 0;
2347
- }
2348
- const { href, text, onClick } = additionalInfo;
2349
- if (href || onClick) {
2350
- return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
2351
- import_components16.ListItem.AdditionalInfo,
2352
- {
2353
- action: __spreadValues({
2354
- label: text
2355
- }, (_b = (_a = additionalInfo.getAnchorProps) == null ? void 0 : _a.call(additionalInfo)) != null ? _b : { onClick })
2356
- }
2357
- );
2358
- }
2359
- return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(import_components16.ListItem.AdditionalInfo, { children: additionalInfo == null ? void 0 : additionalInfo.text });
2360
- };
2361
-
2362
- // ../renderers/src/utils/listItem/getCTAControl.tsx
2363
- var import_components17 = require("@transferwise/components");
2364
- var import_jsx_runtime29 = require("react/jsx-runtime");
2365
- var getCTAControl = (callToAction, { ctaSecondary, fullyInteractive }) => {
2366
- if (!callToAction) {
2367
- return void 0;
2368
- }
2369
- const { accessibilityDescription, title, context } = callToAction;
2370
- const { priority, sentiment } = getPriorityAndSentiment(ctaSecondary, context);
2371
- return /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
2372
- import_components17.ListItem.Button,
2373
- __spreadProps(__spreadValues({}, callToAction.getAnchorProps()), {
2374
- partiallyInteractive: !fullyInteractive,
2375
- priority,
2376
- "aria-description": accessibilityDescription,
2377
- sentiment,
2378
- children: title
2379
- })
2380
- );
2381
- };
2382
- var getPriorityAndSentiment = (ctaSecondary, context) => {
2383
- if (context === "negative") {
2384
- return { priority: "secondary", sentiment: "negative" };
2385
- }
2386
- return { priority: ctaSecondary ? "secondary" : "secondary-neutral", sentiment: "default" };
2387
- };
2388
-
2389
- // ../renderers/src/utils/listItem/shouldUseAvatar.ts
2390
- var shouldUseAvatar = (control, tags) => {
2391
- var _a;
2392
- return control === "with-avatar" || ((_a = tags == null ? void 0 : tags.includes("with-avatar")) != null ? _a : false);
2393
- };
1122
+ // ../renderers/src/ColumnsRenderer.tsx
1123
+ var import_classnames3 = __toESM(require_classnames());
2394
1124
 
2395
- // ../renderers/src/CollectionRenderer/components/ItemComponent.tsx
2396
- var import_jsx_runtime30 = require("react/jsx-runtime");
2397
- var ItemComponent = (props) => {
2398
- var _a, _b;
2399
- const {
2400
- title,
2401
- description,
2402
- supportingValues,
2403
- media,
2404
- additionalInfo,
2405
- inlineAlert,
2406
- href,
2407
- onClick,
2408
- callToAction,
2409
- tags,
2410
- parentTags,
2411
- control
2412
- } = props;
2413
- const controlOptions = {
2414
- ctaSecondary: (_a = tags == null ? void 0 : tags.includes("cta-secondary")) != null ? _a : false,
2415
- fullyInteractive: (_b = (tags == null ? void 0 : tags.includes("fully-interactive")) && (additionalInfo == null ? void 0 : additionalInfo.onClick) == null) != null ? _b : false
2416
- };
2417
- return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
2418
- import_components18.ListItem,
2419
- {
2420
- title,
2421
- subtitle: description,
2422
- valueTitle: supportingValues == null ? void 0 : supportingValues.value,
2423
- valueSubtitle: supportingValues == null ? void 0 : supportingValues.subvalue,
2424
- media: getMedia(media, shouldUseAvatar(control, parentTags)),
2425
- prompt: getInlineAlert(inlineAlert),
2426
- additionalInfo: getAdditionalInfo(additionalInfo),
2427
- control: onClick || href ? getNavigationControl(onClick, href) : getCTAControl(callToAction, controlOptions)
2428
- },
2429
- title
1125
+ // ../renderers/src/utils/useIsCollapsed.ts
1126
+ var import_react5 = require("react");
1127
+ var COLLAPSE_QUERY = "(max-width: 767.98px)";
1128
+ var supportsMatchMedia = () => typeof window !== "undefined" && !!window.matchMedia;
1129
+ var useIsCollapsed = () => {
1130
+ const [collapsed, setCollapsed] = (0, import_react5.useState)(
1131
+ () => supportsMatchMedia() && window.matchMedia(COLLAPSE_QUERY).matches
2430
1132
  );
2431
- };
2432
- var getNavigationControl = (onClick, href) => {
2433
- if (href) {
2434
- return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(import_components18.ListItem.Navigation, { href });
2435
- }
2436
- if (onClick) {
2437
- return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(import_components18.ListItem.Navigation, { onClick });
2438
- }
2439
- return null;
2440
- };
2441
-
2442
- // ../renderers/src/CollectionRenderer/components/SectionHeaderComponent.tsx
2443
- var import_jsx_runtime31 = require("react/jsx-runtime");
2444
- var SectionHeaderComponent = ({
2445
- title,
2446
- callToAction
2447
- }) => /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(Header, { title, callToAction });
2448
-
2449
- // ../renderers/src/CollectionRenderer/createCollectionRenderer.tsx
2450
- var import_jsx_runtime32 = require("react/jsx-runtime");
2451
- var createCollectionRenderer = (canRender, components) => {
2452
- const componeontsWithDefaults = __spreadValues({
2453
- Search: SearchComponent,
2454
- Filters: FiltersComponent,
2455
- Filter: FilterComponent,
2456
- Item: ItemComponent,
2457
- SectionHeader: SectionHeaderComponent,
2458
- Results: ContentComponent
2459
- }, components);
2460
- return {
2461
- canRenderType: "collection",
2462
- canRender,
2463
- render: (props) => {
2464
- return /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(CollectionRendererComponent, __spreadValues(__spreadValues({}, props), componeontsWithDefaults));
1133
+ (0, import_react5.useEffect)(() => {
1134
+ if (supportsMatchMedia()) {
1135
+ const mql = window.matchMedia(COLLAPSE_QUERY);
1136
+ const update = () => setCollapsed(mql.matches);
1137
+ mql.addEventListener("change", update);
1138
+ return () => mql.removeEventListener("change", update);
2465
1139
  }
2466
- };
2467
- };
2468
-
2469
- // ../renderers/src/CollectionRenderer/CollectionRenderer.tsx
2470
- var import_jsx_runtime33 = require("react/jsx-runtime");
2471
- var CollectionRendererComponent = (props) => {
2472
- const { status, Search: Search4, Filters, Results } = props;
2473
- return /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)(import_jsx_runtime33.Fragment, { children: [
2474
- /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(Search4, __spreadValues({}, props)),
2475
- /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(Filters, __spreadValues({}, props)),
2476
- status.type === "idle" || status.reason === "pagination" ? /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(Results, __spreadValues({}, props)) : void 0,
2477
- status.type === "error" && status.reason === "search" && /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)(import_components19.InlinePrompt, { width: "full", sentiment: "negative", children: [
2478
- "Something went wrong,\xA0",
2479
- /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(import_components19.Link, { onClick: status.retry, children: "click here to retry" })
2480
- ] })
2481
- ] });
1140
+ return void 0;
1141
+ }, []);
1142
+ return collapsed;
2482
1143
  };
2483
- var CollectionRenderer = createCollectionRenderer(() => true, {
2484
- Search: (props) => /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(SearchComponent, __spreadValues({}, props)),
2485
- Filters: (props) => /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(FiltersComponent, __spreadValues({}, props)),
2486
- Filter: (props) => /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(FilterComponent, __spreadValues({}, props)),
2487
- Item: (props) => /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(ItemComponent, __spreadValues({}, props)),
2488
- SectionHeader: (props) => /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(SectionHeaderComponent, __spreadValues({}, props)),
2489
- Results: (props) => /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(ContentComponent, __spreadValues({}, props))
2490
- });
2491
- var CollectionRenderer_default = CollectionRenderer;
2492
1144
 
2493
1145
  // ../renderers/src/ColumnsRenderer.tsx
2494
- var import_classnames3 = __toESM(require_classnames());
2495
- var import_jsx_runtime34 = require("react/jsx-runtime");
1146
+ var import_jsx_runtime24 = require("react/jsx-runtime");
1147
+ var RIGHT_FIRST_STACKING = "right-first-stacking";
2496
1148
  var ColumnsRenderer = {
2497
1149
  canRenderType: "columns",
2498
- render: ({ bias, margin, startChildren, endChildren }) => /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)(
1150
+ render: ColumnsRendererComponent
1151
+ };
1152
+ function ColumnsRendererComponent({
1153
+ bias,
1154
+ margin,
1155
+ startChildren,
1156
+ endChildren,
1157
+ tags
1158
+ }) {
1159
+ var _a;
1160
+ const isCollapsed = useIsCollapsed();
1161
+ const reverse = isCollapsed && ((_a = tags == null ? void 0 : tags.includes(RIGHT_FIRST_STACKING)) != null ? _a : false);
1162
+ const startColumn = /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { className: "df-columns-renderer-column", children: startChildren });
1163
+ const endColumn = /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { className: "df-columns-renderer-column", children: endChildren });
1164
+ return /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(
2499
1165
  "div",
2500
1166
  {
2501
1167
  className: (0, import_classnames3.default)("df-columns-renderer-container", getMargin(margin), {
@@ -2503,16 +1169,16 @@ var ColumnsRenderer = {
2503
1169
  "df-columns-renderer-bias-end": bias === "end"
2504
1170
  }),
2505
1171
  children: [
2506
- /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("div", { className: "df-columns-renderer-column", children: startChildren }),
2507
- /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("div", { className: "df-columns-renderer-column", children: endChildren })
1172
+ reverse ? endColumn : startColumn,
1173
+ reverse ? startColumn : endColumn
2508
1174
  ]
2509
1175
  }
2510
- )
2511
- };
1176
+ );
1177
+ }
2512
1178
  var ColumnsRenderer_default = ColumnsRenderer;
2513
1179
 
2514
1180
  // ../renderers/src/components/VariableDateInput.tsx
2515
- var import_components20 = require("@transferwise/components");
1181
+ var import_components12 = require("@transferwise/components");
2516
1182
 
2517
1183
  // ../renderers/src/validators/type-validators.ts
2518
1184
  var isNumber = (value) => typeof value === "number" && !Number.isNaN(value);
@@ -2539,7 +1205,7 @@ var dateToDateString = (date) => {
2539
1205
  };
2540
1206
 
2541
1207
  // ../renderers/src/components/VariableDateInput.tsx
2542
- var import_jsx_runtime35 = require("react/jsx-runtime");
1208
+ var import_jsx_runtime25 = require("react/jsx-runtime");
2543
1209
  function VariableDateInput({
2544
1210
  control,
2545
1211
  inputProps
@@ -2555,8 +1221,8 @@ function VariableDateInput({
2555
1221
  onFocus
2556
1222
  } = inputProps;
2557
1223
  if (control === "date-lookup") {
2558
- return /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
2559
- import_components20.DateLookup,
1224
+ return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
1225
+ import_components12.DateLookup,
2560
1226
  {
2561
1227
  value: dateStringToDateOrNull(inputProps.value),
2562
1228
  min: dateStringToDateOrNull(minimumDate),
@@ -2571,8 +1237,8 @@ function VariableDateInput({
2571
1237
  }
2572
1238
  );
2573
1239
  }
2574
- return /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
2575
- import_components20.DateInput,
1240
+ return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
1241
+ import_components12.DateInput,
2576
1242
  __spreadProps(__spreadValues({}, inputProps), {
2577
1243
  dayAutoComplete: getAutocompleteString(autoComplete, "day"),
2578
1244
  yearAutoComplete: getAutocompleteString(autoComplete, "year")
@@ -2588,7 +1254,7 @@ var getAutocompleteString = (value, suffix) => {
2588
1254
  var VariableDateInput_default = VariableDateInput;
2589
1255
 
2590
1256
  // ../renderers/src/DateInputRenderer.tsx
2591
- var import_jsx_runtime36 = require("react/jsx-runtime");
1257
+ var import_jsx_runtime26 = require("react/jsx-runtime");
2592
1258
  var DateInputRenderer = {
2593
1259
  canRenderType: "input-date",
2594
1260
  render: (props) => {
@@ -2613,7 +1279,7 @@ var DateInputRenderer = {
2613
1279
  ]);
2614
1280
  const value = initialValue != null ? initialValue : "";
2615
1281
  const inputProps = __spreadProps(__spreadValues({}, rest), { value, id });
2616
- return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
1282
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
2617
1283
  FieldInput_default,
2618
1284
  {
2619
1285
  id,
@@ -2624,7 +1290,7 @@ var DateInputRenderer = {
2624
1290
  loadingState: props.fieldLoadingState,
2625
1291
  help,
2626
1292
  features: props.features,
2627
- children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(VariableDateInput_default, { control, inputProps })
1293
+ children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(VariableDateInput_default, { control, inputProps })
2628
1294
  }
2629
1295
  );
2630
1296
  }
@@ -2632,16 +1298,44 @@ var DateInputRenderer = {
2632
1298
  var DateInputRenderer_default = DateInputRenderer;
2633
1299
 
2634
1300
  // ../renderers/src/DecisionRenderer/DecisionRenderer.tsx
2635
- var import_components23 = require("@transferwise/components");
1301
+ var import_components16 = require("@transferwise/components");
1302
+
1303
+ // ../renderers/src/utils/listItem/getAdditionalInfo.tsx
1304
+ var import_components13 = require("@transferwise/components");
1305
+ var import_jsx_runtime27 = require("react/jsx-runtime");
1306
+ var getAdditionalInfo = (additionalInfo) => {
1307
+ var _a, _b;
1308
+ if (!additionalInfo) {
1309
+ return void 0;
1310
+ }
1311
+ const { href, text, onClick } = additionalInfo;
1312
+ if (href || onClick) {
1313
+ return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
1314
+ import_components13.ListItem.AdditionalInfo,
1315
+ {
1316
+ action: __spreadValues({
1317
+ label: text
1318
+ }, (_b = (_a = additionalInfo.getAnchorProps) == null ? void 0 : _a.call(additionalInfo)) != null ? _b : { onClick })
1319
+ }
1320
+ );
1321
+ }
1322
+ return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(import_components13.ListItem.AdditionalInfo, { children: additionalInfo == null ? void 0 : additionalInfo.text });
1323
+ };
1324
+
1325
+ // ../renderers/src/utils/listItem/shouldUseAvatar.ts
1326
+ var shouldUseAvatar = (control, tags) => {
1327
+ var _a;
1328
+ return control === "with-avatar" || ((_a = tags == null ? void 0 : tags.includes("with-avatar")) != null ? _a : false);
1329
+ };
2636
1330
 
2637
1331
  // ../renderers/src/DecisionRenderer/DecisionWrapper.tsx
2638
- var import_components22 = require("@transferwise/components");
2639
- var import_react7 = require("react");
2640
- var import_react_intl10 = require("react-intl");
1332
+ var import_components15 = require("@transferwise/components");
1333
+ var import_react6 = require("react");
1334
+ var import_react_intl8 = require("react-intl");
2641
1335
 
2642
1336
  // ../renderers/src/messages/filter.messages.ts
2643
- var import_react_intl7 = require("react-intl");
2644
- var filter_messages_default = (0, import_react_intl7.defineMessages)({
1337
+ var import_react_intl5 = require("react-intl");
1338
+ var filter_messages_default = (0, import_react_intl5.defineMessages)({
2645
1339
  placeholder: {
2646
1340
  id: "df.wise.filter.placeholder",
2647
1341
  defaultMessage: "Start typing to search",
@@ -2707,12 +1401,12 @@ function filterAndSortDecisionOptions(selectOptions, query) {
2707
1401
  var normalizeAndRemoveAccents = (text) => text.trim().toLowerCase().normalize("NFKD").replace(new RegExp("\\p{Diacritic}", "gu"), "");
2708
1402
 
2709
1403
  // ../renderers/src/DecisionRenderer/GroupedDecisionList.tsx
2710
- var import_components21 = require("@transferwise/components");
2711
- var import_react_intl9 = require("react-intl");
1404
+ var import_components14 = require("@transferwise/components");
1405
+ var import_react_intl7 = require("react-intl");
2712
1406
 
2713
1407
  // ../renderers/src/messages/group.messages.ts
2714
- var import_react_intl8 = require("react-intl");
2715
- var group_messages_default = (0, import_react_intl8.defineMessages)({
1408
+ var import_react_intl6 = require("react-intl");
1409
+ var group_messages_default = (0, import_react_intl6.defineMessages)({
2716
1410
  all: {
2717
1411
  id: "df.wise.group.all",
2718
1412
  defaultMessage: "All",
@@ -2746,19 +1440,19 @@ var getGroupsFromTags = (knownTags, items) => {
2746
1440
  };
2747
1441
 
2748
1442
  // ../renderers/src/DecisionRenderer/GroupedDecisionList.tsx
2749
- var import_jsx_runtime37 = require("react/jsx-runtime");
1443
+ var import_jsx_runtime28 = require("react/jsx-runtime");
2750
1444
  var groupingTags = Object.keys(group_messages_default).filter((key) => key !== "all");
2751
1445
  var isGroupedDecision = (options) => {
2752
1446
  return getGroupsFromTags(groupingTags, options).length > 0;
2753
1447
  };
2754
1448
  var GroupedDecisionList = (_a) => {
2755
1449
  var _b = _a, { renderDecisionList: renderDecisionList2 } = _b, rest = __objRest(_b, ["renderDecisionList"]);
2756
- const { formatMessage } = (0, import_react_intl9.useIntl)();
1450
+ const { formatMessage } = (0, import_react_intl7.useIntl)();
2757
1451
  const { options } = rest;
2758
1452
  const itemsByTag = [...getGroupsFromTags(groupingTags, options), { tag: "all", items: options }];
2759
- return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_jsx_runtime37.Fragment, { children: itemsByTag.map(({ tag, items }) => /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(import_components21.Section, { children: [
2760
- /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
2761
- import_components21.Header,
1453
+ return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(import_jsx_runtime28.Fragment, { children: itemsByTag.map(({ tag, items }) => /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(import_components14.Section, { children: [
1454
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
1455
+ import_components14.Header,
2762
1456
  {
2763
1457
  as: "h2",
2764
1458
  title: tag in group_messages_default ? formatMessage(group_messages_default[tag]) : tag
@@ -2769,26 +1463,26 @@ var GroupedDecisionList = (_a) => {
2769
1463
  };
2770
1464
 
2771
1465
  // ../renderers/src/DecisionRenderer/DecisionWrapper.tsx
2772
- var import_jsx_runtime38 = require("react/jsx-runtime");
1466
+ var import_jsx_runtime29 = require("react/jsx-runtime");
2773
1467
  var DecisionWrapper = (props) => {
2774
- return /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)("div", { className: getMargin(props.margin), children: [
2775
- props.title && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(import_components22.Header, { as: "h2", title: props.title }),
2776
- props.control === "filtered" ? /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(FilteredDecisionList, __spreadValues({}, props)) : /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(UnfilteredDecisionList, __spreadValues({}, props))
1468
+ return /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)("div", { className: getMargin(props.margin), children: [
1469
+ props.title && /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_components15.Header, { as: "h2", title: props.title }),
1470
+ props.control === "filtered" ? /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(FilteredDecisionList, __spreadValues({}, props)) : /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(UnfilteredDecisionList, __spreadValues({}, props))
2777
1471
  ] });
2778
1472
  };
2779
1473
  var UnfilteredDecisionList = (_a) => {
2780
1474
  var _b = _a, { renderDecisionList: renderDecisionList2 } = _b, rest = __objRest(_b, ["renderDecisionList"]);
2781
- return isGroupedDecision(rest.options) ? /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(GroupedDecisionList, __spreadProps(__spreadValues({}, rest), { renderDecisionList: renderDecisionList2 })) : renderDecisionList2(rest);
1475
+ return isGroupedDecision(rest.options) ? /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(GroupedDecisionList, __spreadProps(__spreadValues({}, rest), { renderDecisionList: renderDecisionList2 })) : renderDecisionList2(rest);
2782
1476
  };
2783
1477
  var FilteredDecisionList = (props) => {
2784
- const { formatMessage } = (0, import_react_intl10.useIntl)();
2785
- const [query, setQuery] = (0, import_react7.useState)("");
1478
+ const { formatMessage } = (0, import_react_intl8.useIntl)();
1479
+ const [query, setQuery] = (0, import_react6.useState)("");
2786
1480
  const { control, options, renderDecisionList: renderDecisionList2 } = props;
2787
1481
  const filteredOptions = (query == null ? void 0 : query.length) > 0 ? filterAndSortDecisionOptions(options, query) : options;
2788
1482
  const isGrouped = isGroupedDecision(options);
2789
- return /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)(import_jsx_runtime38.Fragment, { children: [
2790
- /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
2791
- import_components22.SearchInput,
1483
+ return /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(import_jsx_runtime29.Fragment, { children: [
1484
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
1485
+ import_components15.SearchInput,
2792
1486
  {
2793
1487
  placeholder: formatMessage(filter_messages_default.placeholder),
2794
1488
  value: query,
@@ -2799,25 +1493,25 @@ var FilteredDecisionList = (props) => {
2799
1493
  }
2800
1494
  }
2801
1495
  ),
2802
- isGrouped && query.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(GroupedDecisionList, __spreadValues({}, props)) : /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)(import_jsx_runtime38.Fragment, { children: [
2803
- query.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(import_components22.Header, { as: "h2", title: formatMessage(filter_messages_default.results), className: "m-t-4" }),
1496
+ isGrouped && query.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(GroupedDecisionList, __spreadValues({}, props)) : /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(import_jsx_runtime29.Fragment, { children: [
1497
+ query.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_components15.Header, { as: "h2", title: formatMessage(filter_messages_default.results), className: "m-t-4" }),
2804
1498
  filteredOptions.length > 0 ? renderDecisionList2({
2805
1499
  control,
2806
1500
  className: query.length === 0 ? "m-t-3" : "",
2807
1501
  options: filteredOptions
2808
- }) : /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("p", { children: formatMessage(filter_messages_default.noResults) })
1502
+ }) : /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("p", { children: formatMessage(filter_messages_default.noResults) })
2809
1503
  ] })
2810
1504
  ] });
2811
1505
  };
2812
1506
 
2813
1507
  // ../renderers/src/DecisionRenderer/DecisionRenderer.tsx
2814
- var import_jsx_runtime39 = require("react/jsx-runtime");
1508
+ var import_jsx_runtime30 = require("react/jsx-runtime");
2815
1509
  var DecisionRenderer = {
2816
1510
  canRenderType: "decision",
2817
- render: (props) => /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(DecisionWrapper, __spreadProps(__spreadValues({}, props), { renderDecisionList }))
1511
+ render: (props) => /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(DecisionWrapper, __spreadProps(__spreadValues({}, props), { renderDecisionList }))
2818
1512
  };
2819
1513
  var renderDecisionList = ({ options, control }) => {
2820
- return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_jsx_runtime39.Fragment, { children: options.map((_a) => {
1514
+ return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(import_jsx_runtime30.Fragment, { children: options.map((_a) => {
2821
1515
  var _b = _a, { onClick } = _b, rest = __objRest(_b, ["onClick"]);
2822
1516
  const {
2823
1517
  description,
@@ -2830,8 +1524,8 @@ var renderDecisionList = ({ options, control }) => {
2830
1524
  supportingValues,
2831
1525
  tags
2832
1526
  } = rest;
2833
- return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
2834
- import_components23.ListItem,
1527
+ return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
1528
+ import_components16.ListItem,
2835
1529
  {
2836
1530
  title: itemTitle,
2837
1531
  subtitle: description,
@@ -2842,7 +1536,7 @@ var renderDecisionList = ({ options, control }) => {
2842
1536
  media: getMedia(media, shouldUseAvatar(control, tags)),
2843
1537
  prompt: getInlineAlert(inlineAlert),
2844
1538
  additionalInfo: additionalText ? getAdditionalInfo({ text: additionalText }) : void 0,
2845
- control: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_components23.ListItem.Navigation, __spreadValues({}, getAnchorProps()))
1539
+ control: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(import_components16.ListItem.Navigation, __spreadValues({}, getAnchorProps()))
2846
1540
  },
2847
1541
  JSON.stringify(rest)
2848
1542
  );
@@ -2851,8 +1545,8 @@ var renderDecisionList = ({ options, control }) => {
2851
1545
  var DecisionRenderer_default = DecisionRenderer;
2852
1546
 
2853
1547
  // ../renderers/src/DividerRenderer.tsx
2854
- var import_components24 = require("@transferwise/components");
2855
- var import_jsx_runtime40 = require("react/jsx-runtime");
1548
+ var import_components17 = require("@transferwise/components");
1549
+ var import_jsx_runtime31 = require("react/jsx-runtime");
2856
1550
  var mapControlToLevel = (control) => {
2857
1551
  switch (control) {
2858
1552
  case "section":
@@ -2865,16 +1559,16 @@ var mapControlToLevel = (control) => {
2865
1559
  };
2866
1560
  var DividerRenderer = {
2867
1561
  canRenderType: "divider",
2868
- render: ({ margin, control }) => /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_components24.Divider, { className: `m-t-0 d-block ${getMargin(margin)}`, level: mapControlToLevel(control) })
1562
+ render: ({ margin, control }) => /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(import_components17.Divider, { className: `m-t-0 d-block ${getMargin(margin)}`, level: mapControlToLevel(control) })
2869
1563
  };
2870
1564
  var DividerRenderer_default = DividerRenderer;
2871
1565
 
2872
1566
  // ../renderers/src/ExternalConfirmationRenderer.tsx
2873
- var import_components25 = require("@transferwise/components");
1567
+ var import_components18 = require("@transferwise/components");
2874
1568
 
2875
1569
  // ../renderers/src/messages/external-confirmation.messages.ts
2876
- var import_react_intl11 = require("react-intl");
2877
- var external_confirmation_messages_default = (0, import_react_intl11.defineMessages)({
1570
+ var import_react_intl9 = require("react-intl");
1571
+ var external_confirmation_messages_default = (0, import_react_intl9.defineMessages)({
2878
1572
  title: {
2879
1573
  id: "df.wise.ExternalConfirmation.title",
2880
1574
  defaultMessage: "Please confirm",
@@ -2898,9 +1592,9 @@ var external_confirmation_messages_default = (0, import_react_intl11.defineMessa
2898
1592
  });
2899
1593
 
2900
1594
  // ../renderers/src/ExternalConfirmationRenderer.tsx
2901
- var import_react_intl12 = require("react-intl");
2902
- var import_react8 = require("react");
2903
- var import_jsx_runtime41 = require("react/jsx-runtime");
1595
+ var import_react_intl10 = require("react-intl");
1596
+ var import_react7 = require("react");
1597
+ var import_jsx_runtime32 = require("react/jsx-runtime");
2904
1598
  var ExternalConfirmationRenderer = {
2905
1599
  canRenderType: "external-confirmation",
2906
1600
  render: ExternalConfirmationRendererComponent
@@ -2911,20 +1605,20 @@ function ExternalConfirmationRendererComponent({
2911
1605
  open,
2912
1606
  onCancel
2913
1607
  }) {
2914
- const { formatMessage } = (0, import_react_intl12.useIntl)();
2915
- (0, import_react8.useEffect)(() => {
1608
+ const { formatMessage } = (0, import_react_intl10.useIntl)();
1609
+ (0, import_react7.useEffect)(() => {
2916
1610
  open();
2917
1611
  }, []);
2918
- return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
2919
- import_components25.Modal,
1612
+ return /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
1613
+ import_components18.Modal,
2920
1614
  {
2921
1615
  open: visible,
2922
1616
  title: formatMessage(external_confirmation_messages_default.title),
2923
- body: /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)(import_jsx_runtime41.Fragment, { children: [
2924
- /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(import_components25.Markdown, { config: { link: { target: "_blank" } }, className: "text-xs-center m-b-5", children: formatMessage(external_confirmation_messages_default.description, { origin: getOrigin(url) }) }),
2925
- /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("div", { className: "df-box-renderer-fixed-width", children: /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)("div", { className: "df-box-renderer-width-lg", children: [
2926
- /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
2927
- import_components25.Button,
1617
+ body: /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)(import_jsx_runtime32.Fragment, { children: [
1618
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(import_components18.Markdown, { config: { link: { target: "_blank" } }, className: "text-xs-center m-b-5", children: formatMessage(external_confirmation_messages_default.description, { origin: getOrigin(url) }) }),
1619
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)("div", { className: "df-box-renderer-fixed-width", children: /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)("div", { className: "df-box-renderer-width-lg", children: [
1620
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
1621
+ import_components18.Button,
2928
1622
  {
2929
1623
  v2: true,
2930
1624
  block: true,
@@ -2937,7 +1631,7 @@ function ExternalConfirmationRendererComponent({
2937
1631
  children: formatMessage(external_confirmation_messages_default.open)
2938
1632
  }
2939
1633
  ),
2940
- /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(import_components25.Button, { v2: true, block: true, className: "m-b-2", priority: "tertiary", size: "md", onClick: onCancel, children: formatMessage(external_confirmation_messages_default.cancel) })
1634
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(import_components18.Button, { v2: true, block: true, className: "m-b-2", priority: "tertiary", size: "md", onClick: onCancel, children: formatMessage(external_confirmation_messages_default.cancel) })
2941
1635
  ] }) })
2942
1636
  ] }),
2943
1637
  onClose: onCancel
@@ -2954,46 +1648,46 @@ function getOrigin(url) {
2954
1648
  var ExternalConfirmationRenderer_default = ExternalConfirmationRenderer;
2955
1649
 
2956
1650
  // ../renderers/src/FormRenderer.tsx
2957
- var import_jsx_runtime42 = require("react/jsx-runtime");
1651
+ var import_jsx_runtime33 = require("react/jsx-runtime");
2958
1652
  var FormRenderer = {
2959
1653
  canRenderType: "form",
2960
- render: ({ children, margin }) => /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { className: getMargin(margin), children })
1654
+ render: ({ children, margin }) => /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("div", { className: getMargin(margin), children })
2961
1655
  };
2962
1656
  var FormRenderer_default = FormRenderer;
2963
1657
 
2964
1658
  // ../renderers/src/FormSectionRenderer.tsx
2965
- var import_components26 = require("@transferwise/components");
2966
- var import_jsx_runtime43 = require("react/jsx-runtime");
1659
+ var import_components19 = require("@transferwise/components");
1660
+ var import_jsx_runtime34 = require("react/jsx-runtime");
2967
1661
  var FormSectionRenderer = {
2968
1662
  canRenderType: "form-section",
2969
- render: ({ title, description, children }) => /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)("fieldset", { children: [
2970
- title && /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
2971
- import_components26.Header,
1663
+ render: ({ title, description, children }) => /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)("fieldset", { children: [
1664
+ title && /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
1665
+ import_components19.Header,
2972
1666
  {
2973
1667
  as: "h2",
2974
1668
  title
2975
1669
  }
2976
1670
  ),
2977
- description && /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("p", { children: description }),
1671
+ description && /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("p", { children: description }),
2978
1672
  children
2979
1673
  ] })
2980
1674
  };
2981
1675
  var FormSectionRenderer_default = FormSectionRenderer;
2982
1676
 
2983
1677
  // ../renderers/src/HeadingRenderer.tsx
2984
- var import_components27 = require("@transferwise/components");
2985
- var import_jsx_runtime44 = require("react/jsx-runtime");
1678
+ var import_components20 = require("@transferwise/components");
1679
+ var import_jsx_runtime35 = require("react/jsx-runtime");
2986
1680
  var HeadingRenderer = {
2987
1681
  canRenderType: "heading",
2988
- render: (props) => /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(Heading, __spreadValues({}, props))
1682
+ render: (props) => /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(Heading, __spreadValues({}, props))
2989
1683
  };
2990
1684
  function Heading(props) {
2991
1685
  const { text, size, align, margin, control } = props;
2992
1686
  const className = getTextAlignmentAndMargin({ align, margin });
2993
- return control === "display" ? /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(DisplayHeading, { size, text, className }) : /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(StandardHeading, { size, text, className });
1687
+ return control === "display" ? /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(DisplayHeading, { size, text, className }) : /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(StandardHeading, { size, text, className });
2994
1688
  }
2995
1689
  function DisplayHeading({ size, text, className }) {
2996
- return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_components27.Display, { type: getDisplayType(size), className, children: text });
1690
+ return /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(import_components20.Display, { type: getDisplayType(size), className, children: text });
2997
1691
  }
2998
1692
  var getDisplayType = (size) => {
2999
1693
  switch (size) {
@@ -3009,7 +1703,7 @@ var getDisplayType = (size) => {
3009
1703
  }
3010
1704
  };
3011
1705
  function StandardHeading({ size, text, className }) {
3012
- return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_components27.Title, { type: getTitleTypeBySize(size), className, children: text });
1706
+ return /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(import_components20.Title, { type: getTitleTypeBySize(size), className, children: text });
3013
1707
  }
3014
1708
  var getTitleTypeBySize = (size) => {
3015
1709
  var _a;
@@ -3025,8 +1719,8 @@ var getTitleTypeBySize = (size) => {
3025
1719
  var HeadingRenderer_default = HeadingRenderer;
3026
1720
 
3027
1721
  // ../renderers/src/ImageRenderer/UrlImage.tsx
3028
- var import_components28 = require("@transferwise/components");
3029
- var import_react9 = require("react");
1722
+ var import_components21 = require("@transferwise/components");
1723
+ var import_react8 = require("react");
3030
1724
 
3031
1725
  // ../renderers/src/utils/api-utils.ts
3032
1726
  function isRelativePath(url = "") {
@@ -3036,7 +1730,7 @@ function isRelativePath(url = "") {
3036
1730
  }
3037
1731
 
3038
1732
  // ../renderers/src/ImageRenderer/UrlImage.tsx
3039
- var import_jsx_runtime45 = require("react/jsx-runtime");
1733
+ var import_jsx_runtime36 = require("react/jsx-runtime");
3040
1734
  function UrlImage({
3041
1735
  accessibilityDescription,
3042
1736
  align,
@@ -3045,14 +1739,14 @@ function UrlImage({
3045
1739
  uri,
3046
1740
  httpClient
3047
1741
  }) {
3048
- const [imageSource, setImageSource] = (0, import_react9.useState)("");
3049
- (0, import_react9.useEffect)(() => {
1742
+ const [imageSource, setImageSource] = (0, import_react8.useState)("");
1743
+ (0, import_react8.useEffect)(() => {
3050
1744
  if (!uri.startsWith("urn:")) {
3051
1745
  void getImageSource(httpClient, uri).then(setImageSource);
3052
1746
  }
3053
1747
  }, [uri, httpClient]);
3054
- return /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("div", { className: `df-image ${align} ${size || "md"} ${getMargin(margin)}`, children: /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
3055
- import_components28.Image,
1748
+ return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("div", { className: `df-image ${align} ${size || "md"} ${getMargin(margin)}`, children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
1749
+ import_components21.Image,
3056
1750
  {
3057
1751
  className: "df-reserve-space",
3058
1752
  alt: accessibilityDescription != null ? accessibilityDescription : "",
@@ -3095,7 +1789,7 @@ var getImageSource = async (httpClient, imageUrl) => {
3095
1789
  };
3096
1790
 
3097
1791
  // ../renderers/src/ImageRenderer/UrnFlagImage.tsx
3098
- var import_jsx_runtime46 = require("react/jsx-runtime");
1792
+ var import_jsx_runtime37 = require("react/jsx-runtime");
3099
1793
  var maxFlagSize = 600;
3100
1794
  function UrnFlagImage({
3101
1795
  accessibilityDescription,
@@ -3104,12 +1798,12 @@ function UrnFlagImage({
3104
1798
  size,
3105
1799
  uri
3106
1800
  }) {
3107
- return /* @__PURE__ */ (0, import_jsx_runtime46.jsx)("div", { className: `df-image ${align} ${size || "md"} ${getMargin(margin)}`, children: /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(UrnFlag, { size: maxFlagSize, urn: uri, accessibilityDescription }) });
1801
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("div", { className: `df-image ${align} ${size || "md"} ${getMargin(margin)}`, children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(UrnFlag, { size: maxFlagSize, urn: uri, accessibilityDescription }) });
3108
1802
  }
3109
1803
 
3110
1804
  // ../renderers/src/ImageRenderer/UrnIllustration.tsx
3111
1805
  var import_art4 = require("@wise/art");
3112
- var import_react11 = require("react");
1806
+ var import_react10 = require("react");
3113
1807
 
3114
1808
  // ../renderers/src/ImageRenderer/isAnimated.ts
3115
1809
  var isAnimated = (uri) => {
@@ -3119,9 +1813,9 @@ var isAnimated = (uri) => {
3119
1813
 
3120
1814
  // ../renderers/src/ImageRenderer/SafeIllustration3D.tsx
3121
1815
  var import_art3 = require("@wise/art");
3122
- var import_react10 = require("react");
3123
- var import_jsx_runtime47 = require("react/jsx-runtime");
3124
- var Illustration3DErrorBoundary = class extends import_react10.Component {
1816
+ var import_react9 = require("react");
1817
+ var import_jsx_runtime38 = require("react/jsx-runtime");
1818
+ var Illustration3DErrorBoundary = class extends import_react9.Component {
3125
1819
  constructor(props) {
3126
1820
  super(props);
3127
1821
  this.state = { hasError: false };
@@ -3144,12 +1838,12 @@ var SafeIllustration3D = ({
3144
1838
  size,
3145
1839
  onError
3146
1840
  }) => {
3147
- return /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(Illustration3DErrorBoundary, { onError, children: /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(import_art3.Illustration3D, { name, size }) });
1841
+ return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(Illustration3DErrorBoundary, { onError, children: /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(import_art3.Illustration3D, { name, size }) });
3148
1842
  };
3149
1843
  var SafeIllustration3D_default = SafeIllustration3D;
3150
1844
 
3151
1845
  // ../renderers/src/ImageRenderer/UrnIllustration.tsx
3152
- var import_jsx_runtime48 = require("react/jsx-runtime");
1846
+ var import_jsx_runtime39 = require("react/jsx-runtime");
3153
1847
  var urnPrefix = "urn:wise:illustrations:";
3154
1848
  var isUrnIllustration = (uri) => uri.startsWith(urnPrefix);
3155
1849
  function UrnIllustration({
@@ -3159,12 +1853,12 @@ function UrnIllustration({
3159
1853
  size,
3160
1854
  uri
3161
1855
  }) {
3162
- const [has3DFailed, setHas3DFailed] = (0, import_react11.useState)(false);
1856
+ const [has3DFailed, setHas3DFailed] = (0, import_react10.useState)(false);
3163
1857
  const illustrationSize = getIllustrationSize(size);
3164
1858
  const illustrationName = getIllustrationName(uri);
3165
1859
  const illustration3DName = getIllustration3DName(uri);
3166
1860
  if (illustration3DName && isAnimated(uri) && !has3DFailed) {
3167
- return /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("div", { className: `df-image ${align} ${getMargin(margin)}`, children: /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
1861
+ return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("div", { className: `df-image ${align} ${getMargin(margin)}`, children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
3168
1862
  SafeIllustration3D_default,
3169
1863
  {
3170
1864
  name: illustration3DName,
@@ -3173,7 +1867,7 @@ function UrnIllustration({
3173
1867
  }
3174
1868
  ) });
3175
1869
  }
3176
- return /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("div", { className: `df-image ${align} ${getMargin(margin)}`, children: /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
1870
+ return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("div", { className: `df-image ${align} ${getMargin(margin)}`, children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
3177
1871
  import_art4.Illustration,
3178
1872
  {
3179
1873
  className: "df-illustration",
@@ -3193,32 +1887,32 @@ var getIllustration3DName = (uri) => {
3193
1887
  };
3194
1888
 
3195
1889
  // ../renderers/src/ImageRenderer/UrnImage.tsx
3196
- var import_jsx_runtime49 = require("react/jsx-runtime");
1890
+ var import_jsx_runtime40 = require("react/jsx-runtime");
3197
1891
  var isUrnImage = (uri) => uri.startsWith("urn:");
3198
1892
  function UrnImage(props) {
3199
1893
  const { uri } = props;
3200
1894
  if (isUrnIllustration(uri)) {
3201
- return /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(UrnIllustration, __spreadValues({}, props));
1895
+ return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(UrnIllustration, __spreadValues({}, props));
3202
1896
  }
3203
1897
  if (isUrnFlag(uri)) {
3204
- return /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(UrnFlagImage, __spreadValues({}, props));
1898
+ return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(UrnFlagImage, __spreadValues({}, props));
3205
1899
  }
3206
1900
  return null;
3207
1901
  }
3208
1902
 
3209
1903
  // ../renderers/src/ImageRenderer/ImageRenderer.tsx
3210
- var import_jsx_runtime50 = require("react/jsx-runtime");
1904
+ var import_jsx_runtime41 = require("react/jsx-runtime");
3211
1905
  var ImageRenderer = {
3212
1906
  canRenderType: "image",
3213
- render: (props) => isUrnImage(props.uri) ? /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(UrnImage, __spreadValues({}, props)) : /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(UrlImage, __spreadValues({}, props))
1907
+ render: (props) => isUrnImage(props.uri) ? /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(UrnImage, __spreadValues({}, props)) : /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(UrlImage, __spreadValues({}, props))
3214
1908
  };
3215
1909
 
3216
1910
  // ../renderers/src/ImageRenderer/index.tsx
3217
1911
  var ImageRenderer_default = ImageRenderer;
3218
1912
 
3219
1913
  // ../renderers/src/InstructionsRenderer.tsx
3220
- var import_components29 = require("@transferwise/components");
3221
- var import_jsx_runtime51 = require("react/jsx-runtime");
1914
+ var import_components22 = require("@transferwise/components");
1915
+ var import_jsx_runtime42 = require("react/jsx-runtime");
3222
1916
  var doContext = ["positive", "neutral"];
3223
1917
  var dontContext = ["warning", "negative"];
3224
1918
  var InstructionsRenderer = {
@@ -3226,16 +1920,16 @@ var InstructionsRenderer = {
3226
1920
  render: ({ items, margin, title }) => {
3227
1921
  const dos = items.filter((item) => doContext.includes(item.context)).map(({ text }) => text);
3228
1922
  const donts = items.filter((item) => dontContext.includes(item.context)).map(({ text }) => text);
3229
- return /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)("div", { className: getMargin(margin), children: [
3230
- title ? /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_components29.Header, { title }) : null,
3231
- /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_components29.InstructionsList, { dos, donts })
1923
+ return /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)("div", { className: getMargin(margin), children: [
1924
+ title ? /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(import_components22.Header, { title }) : null,
1925
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(import_components22.InstructionsList, { dos, donts })
3232
1926
  ] });
3233
1927
  }
3234
1928
  };
3235
1929
  var InstructionsRenderer_default = InstructionsRenderer;
3236
1930
 
3237
1931
  // ../renderers/src/IntegerInputRenderer.tsx
3238
- var import_components30 = require("@transferwise/components");
1932
+ var import_components23 = require("@transferwise/components");
3239
1933
 
3240
1934
  // ../renderers/src/utils/input-utils.ts
3241
1935
  var onWheel = (event) => {
@@ -3260,7 +1954,7 @@ function pick(obj, ...keys) {
3260
1954
  }
3261
1955
 
3262
1956
  // ../renderers/src/IntegerInputRenderer.tsx
3263
- var import_jsx_runtime52 = require("react/jsx-runtime");
1957
+ var import_jsx_runtime43 = require("react/jsx-runtime");
3264
1958
  var IntegerInputRenderer = {
3265
1959
  canRenderType: "input-integer",
3266
1960
  render: (props) => {
@@ -3275,7 +1969,7 @@ var IntegerInputRenderer = {
3275
1969
  "maximum",
3276
1970
  "minimum"
3277
1971
  );
3278
- return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
1972
+ return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
3279
1973
  FieldInput_default,
3280
1974
  {
3281
1975
  id,
@@ -3286,8 +1980,8 @@ var IntegerInputRenderer = {
3286
1980
  loadingState: props.fieldLoadingState,
3287
1981
  help,
3288
1982
  features: props.features,
3289
- children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(import_components30.InputGroup, { addonStart: getInputGroupAddonStart(media), children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
3290
- import_components30.Input,
1983
+ children: /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(import_components23.InputGroup, { addonStart: getInputGroupAddonStart(media), children: /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
1984
+ import_components23.Input,
3291
1985
  __spreadValues({
3292
1986
  id,
3293
1987
  name: id,
@@ -3309,12 +2003,39 @@ var IntegerInputRenderer = {
3309
2003
  var IntegerInputRenderer_default = IntegerInputRenderer;
3310
2004
 
3311
2005
  // ../renderers/src/ListRenderer.tsx
3312
- var import_components32 = require("@transferwise/components");
2006
+ var import_components26 = require("@transferwise/components");
2007
+
2008
+ // ../renderers/src/utils/listItem/getCTAControl.tsx
2009
+ var import_components24 = require("@transferwise/components");
2010
+ var import_jsx_runtime44 = require("react/jsx-runtime");
2011
+ var getCTAControl = (callToAction, { ctaSecondary, fullyInteractive }) => {
2012
+ if (!callToAction) {
2013
+ return void 0;
2014
+ }
2015
+ const { accessibilityDescription, title, context } = callToAction;
2016
+ const { priority, sentiment } = getPriorityAndSentiment(ctaSecondary, context);
2017
+ return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
2018
+ import_components24.ListItem.Button,
2019
+ __spreadProps(__spreadValues({}, callToAction.getAnchorProps()), {
2020
+ partiallyInteractive: !fullyInteractive,
2021
+ priority,
2022
+ "aria-description": accessibilityDescription,
2023
+ sentiment,
2024
+ children: title
2025
+ })
2026
+ );
2027
+ };
2028
+ var getPriorityAndSentiment = (ctaSecondary, context) => {
2029
+ if (context === "negative") {
2030
+ return { priority: "secondary", sentiment: "negative" };
2031
+ }
2032
+ return { priority: ctaSecondary ? "secondary" : "secondary-neutral", sentiment: "default" };
2033
+ };
3313
2034
 
3314
2035
  // ../renderers/src/components/Header.tsx
3315
- var import_components31 = require("@transferwise/components");
3316
- var import_jsx_runtime53 = require("react/jsx-runtime");
3317
- var Header = ({ title, callToAction }) => (title || callToAction) && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(import_components31.Header, { title: title != null ? title : "", action: getHeaderAction(callToAction) });
2036
+ var import_components25 = require("@transferwise/components");
2037
+ var import_jsx_runtime45 = require("react/jsx-runtime");
2038
+ var Header5 = ({ title, callToAction }) => (title || callToAction) && /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(import_components25.Header, { title: title != null ? title : "", action: getHeaderAction(callToAction) });
3318
2039
  var getHeaderAction = (callToAction) => {
3319
2040
  if (!callToAction) {
3320
2041
  return void 0;
@@ -3326,11 +2047,11 @@ var getHeaderAction = (callToAction) => {
3326
2047
  };
3327
2048
 
3328
2049
  // ../renderers/src/ListRenderer.tsx
3329
- var import_jsx_runtime54 = require("react/jsx-runtime");
2050
+ var import_jsx_runtime46 = require("react/jsx-runtime");
3330
2051
  var ListRenderer = {
3331
2052
  canRenderType: "list",
3332
- render: ({ callToAction, control, margin, items, tags, title }) => /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)("div", { className: getMargin(margin), children: [
3333
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(Header, { title, callToAction }),
2053
+ render: ({ callToAction, control, margin, items, tags, title }) => /* @__PURE__ */ (0, import_jsx_runtime46.jsxs)("div", { className: getMargin(margin), children: [
2054
+ /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(Header5, { title, callToAction }),
3334
2055
  items.map((item) => {
3335
2056
  var _a, _b;
3336
2057
  const {
@@ -3347,8 +2068,8 @@ var ListRenderer = {
3347
2068
  ctaSecondary: (_a = itemTags == null ? void 0 : itemTags.includes("cta-secondary")) != null ? _a : false,
3348
2069
  fullyInteractive: (_b = (tags == null ? void 0 : tags.includes("fully-interactive")) && (additionalInfo == null ? void 0 : additionalInfo.onClick) == null) != null ? _b : false
3349
2070
  };
3350
- return /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
3351
- import_components32.ListItem,
2071
+ return /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(
2072
+ import_components26.ListItem,
3352
2073
  {
3353
2074
  title: itemTitle,
3354
2075
  subtitle: description,
@@ -3367,12 +2088,12 @@ var ListRenderer = {
3367
2088
  var ListRenderer_default = ListRenderer;
3368
2089
 
3369
2090
  // ../renderers/src/LoadingIndicatorRenderer.tsx
3370
- var import_components33 = require("@transferwise/components");
3371
- var import_jsx_runtime55 = require("react/jsx-runtime");
2091
+ var import_components27 = require("@transferwise/components");
2092
+ var import_jsx_runtime47 = require("react/jsx-runtime");
3372
2093
  var LoadingIndicatorRenderer = {
3373
2094
  canRenderType: "loading-indicator",
3374
- render: ({ margin, size }) => /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
3375
- import_components33.Loader,
2095
+ render: ({ margin, size }) => /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
2096
+ import_components27.Loader,
3376
2097
  {
3377
2098
  size,
3378
2099
  classNames: { "tw-loader": `tw-loader m-x-auto ${getMargin(margin)}` },
@@ -3383,13 +2104,13 @@ var LoadingIndicatorRenderer = {
3383
2104
  var LoadingIndicatorRenderer_default = LoadingIndicatorRenderer;
3384
2105
 
3385
2106
  // ../renderers/src/MarkdownRenderer.tsx
3386
- var import_components34 = require("@transferwise/components");
2107
+ var import_components28 = require("@transferwise/components");
3387
2108
  var import_classnames4 = __toESM(require_classnames());
3388
- var import_jsx_runtime56 = require("react/jsx-runtime");
2109
+ var import_jsx_runtime48 = require("react/jsx-runtime");
3389
2110
  var MarkdownRenderer = {
3390
2111
  canRenderType: "markdown",
3391
- render: ({ content, align, margin, size }) => /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("div", { className: getTextAlignmentAndMargin({ align, margin }), children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
3392
- import_components34.Markdown,
2112
+ render: ({ content, align, margin, size }) => /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("div", { className: getTextAlignmentAndMargin({ align, margin }), children: /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
2113
+ import_components28.Markdown,
3393
2114
  {
3394
2115
  className: (0, import_classnames4.default)(
3395
2116
  "df-markdown",
@@ -3403,16 +2124,16 @@ var MarkdownRenderer = {
3403
2124
  var MarkdownRenderer_default = MarkdownRenderer;
3404
2125
 
3405
2126
  // ../renderers/src/MediaRenderer.tsx
3406
- var import_jsx_runtime57 = require("react/jsx-runtime");
2127
+ var import_jsx_runtime49 = require("react/jsx-runtime");
3407
2128
  var MediaRenderer = {
3408
2129
  canRenderType: "media",
3409
2130
  render: (_a) => {
3410
2131
  var _b = _a, { media } = _b, rest = __objRest(_b, ["media"]);
3411
2132
  switch (media.type) {
3412
2133
  case "avatar":
3413
- return /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(AvatarMediaRendererComponent, __spreadValues({ media }, rest));
2134
+ return /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(AvatarMediaRendererComponent, __spreadValues({ media }, rest));
3414
2135
  case "image":
3415
- return /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(ImageMediaRendererComponent, __spreadValues({ media }, rest));
2136
+ return /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(ImageMediaRendererComponent, __spreadValues({ media }, rest));
3416
2137
  case "legacy":
3417
2138
  return null;
3418
2139
  }
@@ -3424,7 +2145,7 @@ var AvatarMediaRendererComponent = ({
3424
2145
  margin,
3425
2146
  size
3426
2147
  }) => {
3427
- return /* @__PURE__ */ (0, import_jsx_runtime57.jsx)("div", { className: `df-media-layout-avatar ${align} ${getMargin(margin)}`, children: /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(Media, { media, size: mapAvatarMediaSize(size) }) });
2148
+ return /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("div", { className: `df-media-layout-avatar ${align} ${getMargin(margin)}`, children: /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(Media, { media, size: mapAvatarMediaSize(size) }) });
3428
2149
  };
3429
2150
  var ImageMediaRendererComponent = (_a) => {
3430
2151
  var _b = _a, {
@@ -3432,7 +2153,7 @@ var ImageMediaRendererComponent = (_a) => {
3432
2153
  } = _b, rest = __objRest(_b, [
3433
2154
  "media"
3434
2155
  ]);
3435
- return isUrnImage(media.uri) ? /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(UrnImage, __spreadValues({ uri: media.uri, accessibilityDescription: media.accessibilityDescription }, rest)) : /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(UrlImage, __spreadValues({ uri: media.uri, accessibilityDescription: media.accessibilityDescription }, rest));
2156
+ return isUrnImage(media.uri) ? /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(UrnImage, __spreadValues({ uri: media.uri, accessibilityDescription: media.accessibilityDescription }, rest)) : /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(UrlImage, __spreadValues({ uri: media.uri, accessibilityDescription: media.accessibilityDescription }, rest));
3436
2157
  };
3437
2158
  var mapAvatarMediaSize = (size) => {
3438
2159
  switch (size) {
@@ -3450,21 +2171,21 @@ var mapAvatarMediaSize = (size) => {
3450
2171
  };
3451
2172
 
3452
2173
  // ../renderers/src/ModalLayoutRenderer.tsx
3453
- var import_components35 = require("@transferwise/components");
3454
- var import_react12 = require("react");
3455
- var import_jsx_runtime58 = require("react/jsx-runtime");
2174
+ var import_components29 = require("@transferwise/components");
2175
+ var import_react11 = require("react");
2176
+ var import_jsx_runtime50 = require("react/jsx-runtime");
3456
2177
  var ModalLayoutRenderer = {
3457
2178
  canRenderType: "modal-layout",
3458
- render: (props) => /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(DFModal, __spreadValues({}, props))
2179
+ render: (props) => /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(DFModal, __spreadValues({}, props))
3459
2180
  };
3460
2181
  var ModalLayoutRenderer_default = ModalLayoutRenderer;
3461
2182
  function DFModal({ content, margin, trigger }) {
3462
- const [visible, setVisible] = (0, import_react12.useState)(false);
2183
+ const [visible, setVisible] = (0, import_react11.useState)(false);
3463
2184
  const { children, title } = content;
3464
- return /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: getMargin(margin), children: [
3465
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_components35.Button, { v2: true, priority: "tertiary", block: true, onClick: () => setVisible(true), children: trigger.title }),
3466
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
3467
- import_components35.Modal,
2185
+ return /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)("div", { className: getMargin(margin), children: [
2186
+ /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(import_components29.Button, { v2: true, priority: "tertiary", block: true, onClick: () => setVisible(true), children: trigger.title }),
2187
+ /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
2188
+ import_components29.Modal,
3468
2189
  {
3469
2190
  scroll: "content",
3470
2191
  open: visible,
@@ -3478,20 +2199,20 @@ function DFModal({ content, margin, trigger }) {
3478
2199
  }
3479
2200
 
3480
2201
  // ../renderers/src/ModalRenderer.tsx
3481
- var import_components36 = require("@transferwise/components");
3482
- var import_jsx_runtime59 = require("react/jsx-runtime");
2202
+ var import_components30 = require("@transferwise/components");
2203
+ var import_jsx_runtime51 = require("react/jsx-runtime");
3483
2204
  var ModalRenderer = {
3484
2205
  canRenderType: "modal",
3485
2206
  render: ({ title, children, open, onClose }) => {
3486
- return /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(import_components36.Modal, { open, title, body: children, onClose });
2207
+ return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_components30.Modal, { open, title, body: children, onClose });
3487
2208
  }
3488
2209
  };
3489
2210
 
3490
2211
  // ../renderers/src/MoneyInputRenderer.tsx
3491
- var import_components37 = require("@transferwise/components");
3492
- var import_react13 = require("react");
3493
- var import_react_intl13 = require("react-intl");
3494
- var import_jsx_runtime60 = require("react/jsx-runtime");
2212
+ var import_components31 = require("@transferwise/components");
2213
+ var import_react12 = require("react");
2214
+ var import_react_intl11 = require("react-intl");
2215
+ var import_jsx_runtime52 = require("react/jsx-runtime");
3495
2216
  var groupingTags2 = Object.keys(group_messages_default).filter((key) => key !== "all");
3496
2217
  var MoneyInputRenderer = {
3497
2218
  canRenderType: "money-input",
@@ -3512,13 +2233,13 @@ function MoneyInputRendererComponent(props) {
3512
2233
  onAmountChange,
3513
2234
  onCurrencyChange
3514
2235
  } = props;
3515
- (0, import_react13.useEffect)(() => {
2236
+ (0, import_react12.useEffect)(() => {
3516
2237
  if (!isValidIndex(selectedCurrencyIndex, currencies.length)) {
3517
2238
  onCurrencyChange(0);
3518
2239
  }
3519
2240
  }, [selectedCurrencyIndex, onCurrencyChange, currencies.length]);
3520
- const { formatMessage } = (0, import_react_intl13.useIntl)();
3521
- return /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
2241
+ const { formatMessage } = (0, import_react_intl11.useIntl)();
2242
+ return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
3522
2243
  FieldInput_default,
3523
2244
  {
3524
2245
  id: uid,
@@ -3527,8 +2248,8 @@ function MoneyInputRendererComponent(props) {
3527
2248
  validation: validationState,
3528
2249
  help,
3529
2250
  features: props.features,
3530
- children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
3531
- import_components37.MoneyInput,
2251
+ children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
2252
+ import_components31.MoneyInput,
3532
2253
  {
3533
2254
  amount: parseFloatOrNull(amountValue),
3534
2255
  searchPlaceholder: "",
@@ -3589,8 +2310,8 @@ function assertCurrencyCodeIsString(currencyCode) {
3589
2310
  }
3590
2311
 
3591
2312
  // ../renderers/src/MultiSelectInputRenderer/InlineComponent.tsx
3592
- var import_components38 = require("@transferwise/components");
3593
- var import_jsx_runtime61 = require("react/jsx-runtime");
2313
+ var import_components32 = require("@transferwise/components");
2314
+ var import_jsx_runtime53 = require("react/jsx-runtime");
3594
2315
  function InlineComponent(props) {
3595
2316
  const {
3596
2317
  id,
@@ -3604,7 +2325,7 @@ function InlineComponent(props) {
3604
2325
  validationState,
3605
2326
  onSelect
3606
2327
  } = props;
3607
- return /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
2328
+ return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
3608
2329
  FieldInput_default,
3609
2330
  {
3610
2331
  id,
@@ -3626,8 +2347,8 @@ function InlineComponent(props) {
3626
2347
  childrenProps
3627
2348
  } = option;
3628
2349
  const key = (_a = childrenProps == null ? void 0 : childrenProps.uid) != null ? _a : index;
3629
- return /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
3630
- import_components38.ListItem,
2350
+ return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
2351
+ import_components32.ListItem,
3631
2352
  {
3632
2353
  title: itemTitle,
3633
2354
  subtitle,
@@ -3635,10 +2356,10 @@ function InlineComponent(props) {
3635
2356
  valueSubtitle: supportingValues == null ? void 0 : supportingValues.subvalue,
3636
2357
  media: getMedia(media, false),
3637
2358
  prompt: getInlineAlert(inlineAlert),
3638
- additionalInfo: additionalText ? /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(import_components38.ListItem.AdditionalInfo, { children: additionalText }) : void 0,
2359
+ additionalInfo: additionalText ? /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(import_components32.ListItem.AdditionalInfo, { children: additionalText }) : void 0,
3639
2360
  disabled: disabled || optionDisabled,
3640
- control: /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
3641
- import_components38.ListItem.Checkbox,
2361
+ control: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
2362
+ import_components32.ListItem.Checkbox,
3642
2363
  {
3643
2364
  checked: selectedIndices.includes(index),
3644
2365
  onChange: (e) => {
@@ -3656,13 +2377,13 @@ function InlineComponent(props) {
3656
2377
  }
3657
2378
 
3658
2379
  // ../renderers/src/MultiSelectInputRenderer/DefaultComponent.tsx
3659
- var import_components39 = require("@transferwise/components");
3660
- var import_react14 = require("react");
3661
- var import_react_intl15 = require("react-intl");
2380
+ var import_components33 = require("@transferwise/components");
2381
+ var import_react13 = require("react");
2382
+ var import_react_intl13 = require("react-intl");
3662
2383
 
3663
2384
  // ../renderers/src/messages/multi-select.messages.ts
3664
- var import_react_intl14 = require("react-intl");
3665
- var multi_select_messages_default = (0, import_react_intl14.defineMessages)({
2385
+ var import_react_intl12 = require("react-intl");
2386
+ var multi_select_messages_default = (0, import_react_intl12.defineMessages)({
3666
2387
  summary: {
3667
2388
  id: "df.wise.MultiSelect.summary",
3668
2389
  defaultMessage: "{first} and {count} more",
@@ -3671,10 +2392,10 @@ var multi_select_messages_default = (0, import_react_intl14.defineMessages)({
3671
2392
  });
3672
2393
 
3673
2394
  // ../renderers/src/MultiSelectInputRenderer/DefaultComponent.tsx
3674
- var import_jsx_runtime62 = require("react/jsx-runtime");
2395
+ var import_jsx_runtime54 = require("react/jsx-runtime");
3675
2396
  function DefaultComponent(props) {
3676
- const { formatMessage } = (0, import_react_intl15.useIntl)();
3677
- const [stagedIndices, setStagedIndices] = (0, import_react14.useState)();
2397
+ const { formatMessage } = (0, import_react_intl13.useIntl)();
2398
+ const [stagedIndices, setStagedIndices] = (0, import_react13.useState)();
3678
2399
  const {
3679
2400
  id,
3680
2401
  autoComplete,
@@ -3713,12 +2434,12 @@ function DefaultComponent(props) {
3713
2434
  const contentProps = {
3714
2435
  title: option.title,
3715
2436
  description: option.description,
3716
- icon: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(OptionMedia, { media: option.media, preferAvatar: false })
2437
+ icon: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(OptionMedia, { media: option.media, preferAvatar: false })
3717
2438
  };
3718
- return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(import_components39.SelectInputOptionContent, __spreadValues({}, contentProps));
2439
+ return /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_components33.SelectInputOptionContent, __spreadValues({}, contentProps));
3719
2440
  };
3720
2441
  const extraProps = { autoComplete };
3721
- return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
2442
+ return /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
3722
2443
  FieldInput_default,
3723
2444
  {
3724
2445
  id,
@@ -3727,8 +2448,8 @@ function DefaultComponent(props) {
3727
2448
  description,
3728
2449
  validation: validationState,
3729
2450
  features,
3730
- children: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
3731
- import_components39.SelectInput,
2451
+ children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
2452
+ import_components33.SelectInput,
3732
2453
  __spreadValues({
3733
2454
  id,
3734
2455
  items: options.map((option, index) => {
@@ -3765,9 +2486,9 @@ function DefaultComponent(props) {
3765
2486
  );
3766
2487
  }
3767
2488
 
3768
- // ../renderers/src/MultiSelectInputRenderer/InlineCheckboxComponent.tsx
3769
- var import_components40 = require("@transferwise/components");
3770
- var import_jsx_runtime63 = require("react/jsx-runtime");
2489
+ // ../renderers/src/MultiSelectInputRenderer/InlineCheckboxComponent.tsx
2490
+ var import_components34 = require("@transferwise/components");
2491
+ var import_jsx_runtime55 = require("react/jsx-runtime");
3771
2492
  function InlineCheckboxComponent(props) {
3772
2493
  const {
3773
2494
  id,
@@ -3781,7 +2502,7 @@ function InlineCheckboxComponent(props) {
3781
2502
  validationState,
3782
2503
  onSelect
3783
2504
  } = props;
3784
- return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
2505
+ return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
3785
2506
  FieldInput_default,
3786
2507
  {
3787
2508
  id,
@@ -3810,35 +2531,35 @@ function InlineCheckboxComponent(props) {
3810
2531
  onSelect(newSelectedIndices);
3811
2532
  }
3812
2533
  };
3813
- return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(import_components40.Checkbox, __spreadProps(__spreadValues({}, checkboxProps), { className: "m-t-1" }), key);
2534
+ return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(import_components34.Checkbox, __spreadProps(__spreadValues({}, checkboxProps), { className: "m-t-1" }), key);
3814
2535
  })
3815
2536
  }
3816
2537
  );
3817
2538
  }
3818
2539
 
3819
2540
  // ../renderers/src/MultiSelectInputRenderer/MultiSelectInputRenderer.tsx
3820
- var import_jsx_runtime64 = require("react/jsx-runtime");
2541
+ var import_jsx_runtime56 = require("react/jsx-runtime");
3821
2542
  var MultiSelectInputRenderer = {
3822
2543
  canRenderType: "input-multi-select",
3823
2544
  render: (props) => {
3824
2545
  switch (props.control) {
3825
2546
  case "inline":
3826
- return /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(InlineComponent, __spreadValues({}, props));
2547
+ return /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(InlineComponent, __spreadValues({}, props));
3827
2548
  case "inline-checkbox-group":
3828
- return /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(InlineCheckboxComponent, __spreadValues({}, props));
2549
+ return /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(InlineCheckboxComponent, __spreadValues({}, props));
3829
2550
  default:
3830
- return /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(DefaultComponent, __spreadValues({}, props));
2551
+ return /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(DefaultComponent, __spreadValues({}, props));
3831
2552
  }
3832
2553
  }
3833
2554
  };
3834
2555
 
3835
2556
  // ../renderers/src/MultiUploadInputRenderer.tsx
3836
- var import_components42 = require("@transferwise/components");
2557
+ var import_components36 = require("@transferwise/components");
3837
2558
 
3838
2559
  // ../renderers/src/components/UploadFieldInput.tsx
3839
- var import_components41 = require("@transferwise/components");
2560
+ var import_components35 = require("@transferwise/components");
3840
2561
  var import_classnames5 = __toESM(require_classnames());
3841
- var import_jsx_runtime65 = require("react/jsx-runtime");
2562
+ var import_jsx_runtime57 = require("react/jsx-runtime");
3842
2563
  function UploadFieldInput({
3843
2564
  id,
3844
2565
  children,
@@ -3848,10 +2569,10 @@ function UploadFieldInput({
3848
2569
  validation,
3849
2570
  features
3850
2571
  }) {
3851
- const labelContent = label && help ? /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(LabelContentWithHelp, { text: label, help }) : label;
2572
+ const labelContent = label && help ? /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(LabelContentWithHelp, { text: label, help }) : label;
3852
2573
  const descriptionId = description ? `${id}-description` : void 0;
3853
2574
  const { ref } = useScrollToError(validation, features);
3854
- return /* @__PURE__ */ (0, import_jsx_runtime65.jsxs)(
2575
+ return /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)(
3855
2576
  "div",
3856
2577
  {
3857
2578
  ref,
@@ -3859,9 +2580,9 @@ function UploadFieldInput({
3859
2580
  "has-error": (validation == null ? void 0 : validation.status) === "invalid"
3860
2581
  }),
3861
2582
  children: [
3862
- /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("label", { htmlFor: id, className: "control-label", children: labelContent }),
2583
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsx)("label", { htmlFor: id, className: "control-label", children: labelContent }),
3863
2584
  children,
3864
- (validation == null ? void 0 : validation.status) === "invalid" && /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(import_components41.InlineAlert, { type: "negative", id: descriptionId, children: validation.message })
2585
+ (validation == null ? void 0 : validation.status) === "invalid" && /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(import_components35.InlineAlert, { type: "negative", id: descriptionId, children: validation.message })
3865
2586
  ]
3866
2587
  }
3867
2588
  );
@@ -3896,7 +2617,7 @@ var getSizeLimit = (maxSize) => {
3896
2617
  };
3897
2618
 
3898
2619
  // ../renderers/src/MultiUploadInputRenderer.tsx
3899
- var import_jsx_runtime66 = require("react/jsx-runtime");
2620
+ var import_jsx_runtime58 = require("react/jsx-runtime");
3900
2621
  var MultiUploadInputRenderer = {
3901
2622
  canRenderType: "input-upload-multi",
3902
2623
  render: (props) => {
@@ -3922,7 +2643,7 @@ var MultiUploadInputRenderer = {
3922
2643
  };
3923
2644
  const onDeleteFile = async (fileId) => onRemoveFile(value.findIndex((file) => file.id === fileId));
3924
2645
  const descriptionId = description ? `${id}-description` : void 0;
3925
- return /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(
2646
+ return /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
3926
2647
  UploadFieldInput_default,
3927
2648
  {
3928
2649
  id,
@@ -3931,8 +2652,8 @@ var MultiUploadInputRenderer = {
3931
2652
  validation: validationState,
3932
2653
  help,
3933
2654
  features,
3934
- children: /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(
3935
- import_components42.UploadInput,
2655
+ children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
2656
+ import_components36.UploadInput,
3936
2657
  {
3937
2658
  id,
3938
2659
  "aria-describedby": descriptionId,
@@ -3941,7 +2662,7 @@ var MultiUploadInputRenderer = {
3941
2662
  files: value.map(({ id: id2, file, validationState: validationState2 }) => ({
3942
2663
  id: id2,
3943
2664
  filename: file.name,
3944
- status: (validationState2 == null ? void 0 : validationState2.status) === "invalid" ? import_components42.Status.FAILED : import_components42.Status.SUCCEEDED
2665
+ status: (validationState2 == null ? void 0 : validationState2.status) === "invalid" ? import_components36.Status.FAILED : import_components36.Status.SUCCEEDED
3945
2666
  })),
3946
2667
  fileTypes: acceptsToFileTypes(accepts),
3947
2668
  maxFiles: maxItems,
@@ -3959,8 +2680,8 @@ var MultiUploadInputRenderer = {
3959
2680
  var MultiUploadInputRenderer_default = MultiUploadInputRenderer;
3960
2681
 
3961
2682
  // ../renderers/src/NumberInputRenderer.tsx
3962
- var import_components43 = require("@transferwise/components");
3963
- var import_jsx_runtime67 = require("react/jsx-runtime");
2683
+ var import_components37 = require("@transferwise/components");
2684
+ var import_jsx_runtime59 = require("react/jsx-runtime");
3964
2685
  var NumberInputRenderer = {
3965
2686
  canRenderType: "input-number",
3966
2687
  render: (props) => {
@@ -3974,7 +2695,7 @@ var NumberInputRenderer = {
3974
2695
  "maximum",
3975
2696
  "minimum"
3976
2697
  );
3977
- return /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
2698
+ return /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
3978
2699
  FieldInput_default,
3979
2700
  {
3980
2701
  id,
@@ -3985,8 +2706,8 @@ var NumberInputRenderer = {
3985
2706
  loadingState: props.fieldLoadingState,
3986
2707
  help,
3987
2708
  features: props.features,
3988
- children: /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(import_components43.InputGroup, { addonStart: getInputGroupAddonStart(media), children: /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
3989
- import_components43.Input,
2709
+ children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(import_components37.InputGroup, { addonStart: getInputGroupAddonStart(media), children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
2710
+ import_components37.Input,
3990
2711
  __spreadValues({
3991
2712
  id,
3992
2713
  name: id,
@@ -4006,24 +2727,24 @@ var NumberInputRenderer = {
4006
2727
  var NumberInputRenderer_default = NumberInputRenderer;
4007
2728
 
4008
2729
  // ../renderers/src/ParagraphRenderer.tsx
4009
- var import_react_intl17 = require("react-intl");
2730
+ var import_react_intl15 = require("react-intl");
4010
2731
 
4011
2732
  // ../renderers/src/hooks/useSnackBarIfAvailable.ts
4012
- var import_components44 = require("@transferwise/components");
4013
- var import_react15 = require("react");
2733
+ var import_components38 = require("@transferwise/components");
2734
+ var import_react14 = require("react");
4014
2735
  function useSnackBarIfAvailable() {
4015
- const context = (0, import_react15.useContext)(import_components44.SnackbarContext);
2736
+ const context = (0, import_react14.useContext)(import_components38.SnackbarContext);
4016
2737
  return context ? context.createSnackbar : () => {
4017
2738
  };
4018
2739
  }
4019
2740
 
4020
2741
  // ../renderers/src/ParagraphRenderer.tsx
4021
- var import_components45 = require("@transferwise/components");
2742
+ var import_components39 = require("@transferwise/components");
4022
2743
  var import_classnames6 = __toESM(require_classnames());
4023
2744
 
4024
2745
  // ../renderers/src/messages/paragraph.messages.ts
4025
- var import_react_intl16 = require("react-intl");
4026
- var paragraph_messages_default = (0, import_react_intl16.defineMessages)({
2746
+ var import_react_intl14 = require("react-intl");
2747
+ var paragraph_messages_default = (0, import_react_intl14.defineMessages)({
4027
2748
  copy: {
4028
2749
  id: "df.wise.DynamicParagraph.copy",
4029
2750
  defaultMessage: "Copy",
@@ -4037,14 +2758,14 @@ var paragraph_messages_default = (0, import_react_intl16.defineMessages)({
4037
2758
  });
4038
2759
 
4039
2760
  // ../renderers/src/ParagraphRenderer.tsx
4040
- var import_jsx_runtime68 = require("react/jsx-runtime");
2761
+ var import_jsx_runtime60 = require("react/jsx-runtime");
4041
2762
  var ParagraphRenderer = {
4042
2763
  canRenderType: "paragraph",
4043
- render: (props) => /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(Paragraph, __spreadValues({}, props))
2764
+ render: (props) => /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(Paragraph, __spreadValues({}, props))
4044
2765
  };
4045
2766
  function Paragraph({ align, control, margin, size, text }) {
4046
2767
  const className = getTextAlignmentAndMargin({ align, margin });
4047
- return control === "copyable" ? /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(CopyableParagraph, { className, align, text }) : /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
2768
+ return control === "copyable" ? /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(CopyableParagraph, { className, align, text }) : /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
4048
2769
  "p",
4049
2770
  {
4050
2771
  className: `${["xs", "sm"].includes(size) ? "np-text-body-default" : "np-text-body-large"} ${className}`,
@@ -4057,16 +2778,16 @@ function CopyableParagraph({
4057
2778
  align,
4058
2779
  className
4059
2780
  }) {
4060
- const { formatMessage } = (0, import_react_intl17.useIntl)();
2781
+ const { formatMessage } = (0, import_react_intl15.useIntl)();
4061
2782
  const createSnackbar = useSnackBarIfAvailable();
4062
2783
  const copy = () => {
4063
2784
  navigator.clipboard.writeText(text).then(() => createSnackbar({ text: formatMessage(paragraph_messages_default.copied) })).catch(() => {
4064
2785
  });
4065
2786
  };
4066
2787
  const inputAlignmentClasses = getTextAlignmentAndMargin({ align, margin: "sm" });
4067
- return /* @__PURE__ */ (0, import_jsx_runtime68.jsxs)("div", { className, children: [
4068
- /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
4069
- import_components45.Input,
2788
+ return /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("div", { className, children: [
2789
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
2790
+ import_components39.Input,
4070
2791
  {
4071
2792
  type: "text",
4072
2793
  value: text,
@@ -4074,23 +2795,23 @@ function CopyableParagraph({
4074
2795
  className: (0, import_classnames6.default)("text-ellipsis", inputAlignmentClasses)
4075
2796
  }
4076
2797
  ),
4077
- /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(import_components45.Button, { v2: true, block: true, onClick: copy, children: formatMessage(paragraph_messages_default.copy) })
2798
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(import_components39.Button, { v2: true, block: true, onClick: copy, children: formatMessage(paragraph_messages_default.copy) })
4078
2799
  ] });
4079
2800
  }
4080
2801
  var ParagraphRenderer_default = ParagraphRenderer;
4081
2802
 
4082
2803
  // ../renderers/src/ProgressRenderer.tsx
4083
- var import_components46 = require("@transferwise/components");
4084
- var import_jsx_runtime69 = require("react/jsx-runtime");
2804
+ var import_components40 = require("@transferwise/components");
2805
+ var import_jsx_runtime61 = require("react/jsx-runtime");
4085
2806
  var ProgressRenderer = {
4086
2807
  canRenderType: "progress",
4087
2808
  render: ({ uid, title, help, progress, progressText, margin, description }) => {
4088
- return /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(
4089
- import_components46.ProgressBar,
2809
+ return /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
2810
+ import_components40.ProgressBar,
4090
2811
  {
4091
2812
  id: uid,
4092
2813
  className: getMargin(margin),
4093
- title: title && help ? /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(LabelContentWithHelp, { text: title, help }) : title,
2814
+ title: title && help ? /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(LabelContentWithHelp, { text: title, help }) : title,
4094
2815
  description,
4095
2816
  progress: {
4096
2817
  max: 1,
@@ -4103,15 +2824,15 @@ var ProgressRenderer = {
4103
2824
  };
4104
2825
 
4105
2826
  // ../renderers/src/RepeatableRenderer.tsx
4106
- var import_components47 = require("@transferwise/components");
4107
- var import_icons2 = require("@transferwise/icons");
2827
+ var import_components41 = require("@transferwise/components");
2828
+ var import_icons = require("@transferwise/icons");
4108
2829
  var import_classnames7 = __toESM(require_classnames());
4109
- var import_react16 = require("react");
4110
- var import_react_intl19 = require("react-intl");
2830
+ var import_react15 = require("react");
2831
+ var import_react_intl17 = require("react-intl");
4111
2832
 
4112
2833
  // ../renderers/src/messages/repeatable.messages.ts
4113
- var import_react_intl18 = require("react-intl");
4114
- var repeatable_messages_default = (0, import_react_intl18.defineMessages)({
2834
+ var import_react_intl16 = require("react-intl");
2835
+ var repeatable_messages_default = (0, import_react_intl16.defineMessages)({
4115
2836
  addItemTitle: {
4116
2837
  id: "df.wise.ArraySchema.addItemTitle",
4117
2838
  defaultMessage: "Add Item",
@@ -4135,10 +2856,10 @@ var repeatable_messages_default = (0, import_react_intl18.defineMessages)({
4135
2856
  });
4136
2857
 
4137
2858
  // ../renderers/src/RepeatableRenderer.tsx
4138
- var import_jsx_runtime70 = require("react/jsx-runtime");
2859
+ var import_jsx_runtime62 = require("react/jsx-runtime");
4139
2860
  var RepeatableRenderer = {
4140
2861
  canRenderType: "repeatable",
4141
- render: (props) => /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(Repeatable, __spreadValues({}, props))
2862
+ render: (props) => /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(Repeatable, __spreadValues({}, props))
4142
2863
  };
4143
2864
  function Repeatable(props) {
4144
2865
  const {
@@ -4155,8 +2876,8 @@ function Repeatable(props) {
4155
2876
  onSave,
4156
2877
  onRemove
4157
2878
  } = props;
4158
- const { formatMessage } = (0, import_react_intl19.useIntl)();
4159
- const [openModalType, setOpenModalType] = (0, import_react16.useState)(null);
2879
+ const { formatMessage } = (0, import_react_intl17.useIntl)();
2880
+ const [openModalType, setOpenModalType] = (0, import_react15.useState)(null);
4160
2881
  const { ref } = useScrollToError(validationState, features);
4161
2882
  const onAddItem = () => {
4162
2883
  onAdd();
@@ -4179,43 +2900,43 @@ function Repeatable(props) {
4179
2900
  const onCancelEdit = () => {
4180
2901
  setOpenModalType(null);
4181
2902
  };
4182
- return /* @__PURE__ */ (0, import_jsx_runtime70.jsxs)(import_jsx_runtime70.Fragment, { children: [
4183
- /* @__PURE__ */ (0, import_jsx_runtime70.jsxs)("div", { ref, children: [
4184
- title && /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_components47.Header, { title }),
4185
- description && /* @__PURE__ */ (0, import_jsx_runtime70.jsx)("p", { children: description }),
4186
- /* @__PURE__ */ (0, import_jsx_runtime70.jsxs)(
2903
+ return /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)(import_jsx_runtime62.Fragment, { children: [
2904
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)("div", { ref, children: [
2905
+ title && /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(import_components41.Header, { title }),
2906
+ description && /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("p", { children: description }),
2907
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)(
4187
2908
  "div",
4188
2909
  {
4189
2910
  className: (0, import_classnames7.default)("form-group", {
4190
2911
  "has-error": (validationState == null ? void 0 : validationState.status) === "invalid"
4191
2912
  }),
4192
2913
  children: [
4193
- items == null ? void 0 : items.map((item, index) => /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(ItemSummaryOption, { item, onClick: () => onEditItem(index) }, item.id)),
4194
- /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(
4195
- import_components47.NavigationOption,
2914
+ items == null ? void 0 : items.map((item, index) => /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(ItemSummaryOption, { item, onClick: () => onEditItem(index) }, item.id)),
2915
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
2916
+ import_components41.NavigationOption,
4196
2917
  {
4197
- media: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_icons2.Plus, {}),
2918
+ media: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(import_icons.Plus, {}),
4198
2919
  title: addItemTitle || formatMessage(repeatable_messages_default.addItemTitle),
4199
2920
  showMediaAtAllSizes: true,
4200
2921
  onClick: () => onAddItem()
4201
2922
  }
4202
2923
  ),
4203
- (validationState == null ? void 0 : validationState.status) === "invalid" && /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_components47.InlineAlert, { type: "negative", children: validationState.message })
2924
+ (validationState == null ? void 0 : validationState.status) === "invalid" && /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(import_components41.InlineAlert, { type: "negative", children: validationState.message })
4204
2925
  ]
4205
2926
  }
4206
2927
  )
4207
2928
  ] }),
4208
- /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(
4209
- import_components47.Modal,
2929
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
2930
+ import_components41.Modal,
4210
2931
  {
4211
2932
  open: openModalType !== null,
4212
2933
  title: (openModalType === "add" ? addItemTitle : editItemTitle) || formatMessage(repeatable_messages_default.addItemTitle),
4213
- body: /* @__PURE__ */ (0, import_jsx_runtime70.jsxs)(import_jsx_runtime70.Fragment, { children: [
4214
- /* @__PURE__ */ (0, import_jsx_runtime70.jsx)("div", { className: "m-b-2", children: editableItem }),
4215
- /* @__PURE__ */ (0, import_jsx_runtime70.jsxs)("div", { children: [
4216
- /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_components47.Button, { priority: "primary", block: true, className: "m-b-2", onClick: () => onSaveItem(), children: formatMessage(repeatable_messages_default.addItem) }),
4217
- /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(
4218
- import_components47.Button,
2934
+ body: /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)(import_jsx_runtime62.Fragment, { children: [
2935
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("div", { className: "m-b-2", children: editableItem }),
2936
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)("div", { children: [
2937
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(import_components41.Button, { priority: "primary", block: true, className: "m-b-2", onClick: () => onSaveItem(), children: formatMessage(repeatable_messages_default.addItem) }),
2938
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
2939
+ import_components41.Button,
4219
2940
  {
4220
2941
  v2: true,
4221
2942
  priority: "secondary",
@@ -4236,10 +2957,10 @@ function ItemSummaryOption({
4236
2957
  item,
4237
2958
  onClick
4238
2959
  }) {
4239
- return /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(
4240
- import_components47.NavigationOption,
2960
+ return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
2961
+ import_components41.NavigationOption,
4241
2962
  {
4242
- media: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(OptionMedia, { media: item.media, preferAvatar: false }),
2963
+ media: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(OptionMedia, { media: item.media, preferAvatar: false }),
4243
2964
  title: item.title,
4244
2965
  content: item.description,
4245
2966
  showMediaAtAllSizes: true,
@@ -4251,16 +2972,16 @@ function ItemSummaryOption({
4251
2972
  var RepeatableRenderer_default = RepeatableRenderer;
4252
2973
 
4253
2974
  // ../renderers/src/ReviewLegacyRenderer.tsx
4254
- var import_components48 = require("@transferwise/components");
4255
- var import_jsx_runtime71 = require("react/jsx-runtime");
2975
+ var import_components42 = require("@transferwise/components");
2976
+ var import_jsx_runtime63 = require("react/jsx-runtime");
4256
2977
  var ReviewRenderer = {
4257
2978
  canRenderType: "review",
4258
2979
  render: ({ callToAction, control, fields, margin, title, trackEvent }) => {
4259
2980
  const orientation = mapControlToDefinitionListLayout(control);
4260
- return /* @__PURE__ */ (0, import_jsx_runtime71.jsxs)("div", { className: getMargin(margin), children: [
4261
- /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(Header, { title, callToAction }),
4262
- /* @__PURE__ */ (0, import_jsx_runtime71.jsx)("div", { className: margin, children: /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(
4263
- import_components48.DefinitionList,
2981
+ return /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)("div", { className: getMargin(margin), children: [
2982
+ /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(Header5, { title, callToAction }),
2983
+ /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("div", { className: margin, children: /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
2984
+ import_components42.DefinitionList,
4264
2985
  {
4265
2986
  layout: orientation,
4266
2987
  definitions: fields.map(
@@ -4297,20 +3018,20 @@ var mapControlToDefinitionListLayout = (control) => {
4297
3018
  };
4298
3019
  var getFieldLabel = (label, help, onClick) => {
4299
3020
  if (help) {
4300
- return /* @__PURE__ */ (0, import_jsx_runtime71.jsxs)(import_jsx_runtime71.Fragment, { children: [
3021
+ return /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)(import_jsx_runtime63.Fragment, { children: [
4301
3022
  label,
4302
3023
  " ",
4303
- /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(Help_default, { help, onClick })
3024
+ /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(Help_default, { help, onClick })
4304
3025
  ] });
4305
3026
  }
4306
3027
  return label;
4307
3028
  };
4308
3029
 
4309
3030
  // ../renderers/src/ReviewRenderer.tsx
4310
- var import_components49 = require("@transferwise/components");
4311
- var import_icons3 = require("@transferwise/icons");
4312
- var import_react_intl20 = require("react-intl");
4313
- var import_jsx_runtime72 = require("react/jsx-runtime");
3031
+ var import_components43 = require("@transferwise/components");
3032
+ var import_icons2 = require("@transferwise/icons");
3033
+ var import_react_intl18 = require("react-intl");
3034
+ var import_jsx_runtime64 = require("react/jsx-runtime");
4314
3035
  var IGNORED_CONTROLS = [
4315
3036
  "horizontal",
4316
3037
  "horizontal-end-aligned",
@@ -4320,7 +3041,7 @@ var IGNORED_CONTROLS = [
4320
3041
  var ReviewRenderer2 = {
4321
3042
  canRenderType: "review",
4322
3043
  canRender: ({ control }) => control ? !IGNORED_CONTROLS.includes(control) : true,
4323
- render: (props) => /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(Review, __spreadValues({}, props))
3044
+ render: (props) => /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(Review, __spreadValues({}, props))
4324
3045
  };
4325
3046
  var Review = ({
4326
3047
  callToAction,
@@ -4331,9 +3052,9 @@ var Review = ({
4331
3052
  title,
4332
3053
  trackEvent
4333
3054
  }) => {
4334
- const intl = (0, import_react_intl20.useIntl)();
4335
- return /* @__PURE__ */ (0, import_jsx_runtime72.jsxs)("div", { className: getMargin(margin), children: [
4336
- /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(Header, { title, callToAction }),
3055
+ const intl = (0, import_react_intl18.useIntl)();
3056
+ return /* @__PURE__ */ (0, import_jsx_runtime64.jsxs)("div", { className: getMargin(margin), children: [
3057
+ /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(Header5, { title, callToAction }),
4337
3058
  fields.map((field) => {
4338
3059
  var _a, _b, _c;
4339
3060
  const {
@@ -4351,8 +3072,8 @@ var Review = ({
4351
3072
  ctaSecondary: (_a = itemTags == null ? void 0 : itemTags.includes("cta-secondary")) != null ? _a : false,
4352
3073
  fullyInteractive: (_b = (tags == null ? void 0 : tags.includes("fully-interactive")) && (additionalInfo == null ? void 0 : additionalInfo.onClick) == null) != null ? _b : false
4353
3074
  };
4354
- return /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(
4355
- import_components49.ListItem,
3075
+ return /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(
3076
+ import_components43.ListItem,
4356
3077
  {
4357
3078
  title: value,
4358
3079
  subtitle: label,
@@ -4372,18 +3093,18 @@ var Review = ({
4372
3093
  ] });
4373
3094
  };
4374
3095
  var getHelpControl = (help, ariaLabel, onClick) => {
4375
- return /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_components49.Popover, { content: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_components49.Markdown, { config: { link: { target: "_blank" } }, children: help }), children: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_components49.ListItem.IconButton, { partiallyInteractive: true, "aria-label": ariaLabel, onClick, children: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_icons3.QuestionMarkCircle, {}) }) });
3096
+ return /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(import_components43.Popover, { content: /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(import_components43.Markdown, { config: { link: { target: "_blank" } }, children: help }), children: /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(import_components43.ListItem.IconButton, { partiallyInteractive: true, "aria-label": ariaLabel, onClick, children: /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(import_icons2.QuestionMarkCircle, {}) }) });
4376
3097
  };
4377
3098
  var ReviewRenderer_default = ReviewRenderer2;
4378
3099
 
4379
3100
  // ../renderers/src/SearchRenderer/BlockSearchRendererComponent.tsx
4380
- var import_components51 = require("@transferwise/components");
4381
- var import_react17 = require("react");
4382
- var import_react_intl24 = require("react-intl");
3101
+ var import_components45 = require("@transferwise/components");
3102
+ var import_react16 = require("react");
3103
+ var import_react_intl22 = require("react-intl");
4383
3104
 
4384
3105
  // ../renderers/src/messages/search.messages.ts
4385
- var import_react_intl21 = require("react-intl");
4386
- var search_messages_default = (0, import_react_intl21.defineMessages)({
3106
+ var import_react_intl19 = require("react-intl");
3107
+ var search_messages_default = (0, import_react_intl19.defineMessages)({
4387
3108
  loading: {
4388
3109
  id: "df.wise.SearchLayout.loading",
4389
3110
  defaultMessage: "Loading...",
@@ -4392,11 +3113,11 @@ var search_messages_default = (0, import_react_intl21.defineMessages)({
4392
3113
  });
4393
3114
 
4394
3115
  // ../renderers/src/SearchRenderer/ErrorResult.tsx
4395
- var import_react_intl23 = require("react-intl");
3116
+ var import_react_intl21 = require("react-intl");
4396
3117
 
4397
3118
  // ../renderers/src/messages/generic-error.messages.ts
4398
- var import_react_intl22 = require("react-intl");
4399
- var generic_error_messages_default = (0, import_react_intl22.defineMessages)({
3119
+ var import_react_intl20 = require("react-intl");
3120
+ var generic_error_messages_default = (0, import_react_intl20.defineMessages)({
4400
3121
  genericErrorRetryHint: {
4401
3122
  id: "df.wise.PersistAsyncSchema.genericError",
4402
3123
  defaultMessage: "Something went wrong, please try again.",
@@ -4415,20 +3136,20 @@ var generic_error_messages_default = (0, import_react_intl22.defineMessages)({
4415
3136
  });
4416
3137
 
4417
3138
  // ../renderers/src/SearchRenderer/ErrorResult.tsx
4418
- var import_components50 = require("@transferwise/components");
4419
- var import_jsx_runtime73 = require("react/jsx-runtime");
3139
+ var import_components44 = require("@transferwise/components");
3140
+ var import_jsx_runtime65 = require("react/jsx-runtime");
4420
3141
  function ErrorResult({ state }) {
4421
- const intl = (0, import_react_intl23.useIntl)();
4422
- return /* @__PURE__ */ (0, import_jsx_runtime73.jsxs)("p", { className: "m-t-2", children: [
3142
+ const intl = (0, import_react_intl21.useIntl)();
3143
+ return /* @__PURE__ */ (0, import_jsx_runtime65.jsxs)("p", { className: "m-t-2", children: [
4423
3144
  intl.formatMessage(generic_error_messages_default.genericError),
4424
3145
  "\xA0",
4425
- /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(import_components50.Link, { onClick: () => state.onRetry(), children: intl.formatMessage(generic_error_messages_default.retry) })
3146
+ /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(import_components44.Link, { onClick: () => state.onRetry(), children: intl.formatMessage(generic_error_messages_default.retry) })
4426
3147
  ] });
4427
3148
  }
4428
3149
 
4429
3150
  // ../renderers/src/SearchRenderer/BlockSearchRendererComponent.tsx
4430
- var import_icons4 = require("@transferwise/icons");
4431
- var import_jsx_runtime74 = require("react/jsx-runtime");
3151
+ var import_icons3 = require("@transferwise/icons");
3152
+ var import_jsx_runtime66 = require("react/jsx-runtime");
4432
3153
  function BlockSearchRendererComponent({
4433
3154
  id,
4434
3155
  hint,
@@ -4441,10 +3162,10 @@ function BlockSearchRendererComponent({
4441
3162
  trackEvent,
4442
3163
  onChange
4443
3164
  }) {
4444
- const [hasSearched, setHasSearched] = (0, import_react17.useState)(false);
4445
- const { formatMessage } = (0, import_react_intl24.useIntl)();
4446
- return /* @__PURE__ */ (0, import_jsx_runtime74.jsxs)("div", { className: getMargin(margin), children: [
4447
- /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(
3165
+ const [hasSearched, setHasSearched] = (0, import_react16.useState)(false);
3166
+ const { formatMessage } = (0, import_react_intl22.useIntl)();
3167
+ return /* @__PURE__ */ (0, import_jsx_runtime66.jsxs)("div", { className: getMargin(margin), children: [
3168
+ /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(
4448
3169
  FieldInput_default,
4449
3170
  {
4450
3171
  id,
@@ -4453,8 +3174,8 @@ function BlockSearchRendererComponent({
4453
3174
  help: "",
4454
3175
  label: title,
4455
3176
  features,
4456
- children: /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(import_components51.InputGroup, { addonStart: { content: /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(import_icons4.Search, { size: 24 }) }, children: /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(
4457
- import_components51.Input,
3177
+ children: /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(import_components45.InputGroup, { addonStart: { content: /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(import_icons3.Search, { size: 24 }) }, children: /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(
3178
+ import_components45.Input,
4458
3179
  {
4459
3180
  id,
4460
3181
  name: id,
@@ -4472,7 +3193,7 @@ function BlockSearchRendererComponent({
4472
3193
  ) })
4473
3194
  }
4474
3195
  ),
4475
- isLoading ? /* @__PURE__ */ (0, import_jsx_runtime74.jsx)("span", { children: formatMessage(search_messages_default.loading) }) : /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(SearchResultContent, { state, trackEvent })
3196
+ isLoading ? /* @__PURE__ */ (0, import_jsx_runtime66.jsx)("span", { children: formatMessage(search_messages_default.loading) }) : /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(SearchResultContent, { state, trackEvent })
4476
3197
  ] });
4477
3198
  }
4478
3199
  function SearchResultContent({
@@ -4481,39 +3202,39 @@ function SearchResultContent({
4481
3202
  }) {
4482
3203
  switch (state.type) {
4483
3204
  case "error":
4484
- return /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(ErrorResult, { state });
3205
+ return /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(ErrorResult, { state });
4485
3206
  case "results":
4486
- return /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(SearchResults, { state, trackEvent });
3207
+ return /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(SearchResults, { state, trackEvent });
4487
3208
  case "layout":
4488
- return /* @__PURE__ */ (0, import_jsx_runtime74.jsxs)(import_jsx_runtime74.Fragment, { children: [
3209
+ return /* @__PURE__ */ (0, import_jsx_runtime66.jsxs)(import_jsx_runtime66.Fragment, { children: [
4489
3210
  " ",
4490
3211
  state.layout,
4491
3212
  " "
4492
3213
  ] });
4493
3214
  case "noResults":
4494
- return /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(EmptySearchResult, { state });
3215
+ return /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(EmptySearchResult, { state });
4495
3216
  case "pending":
4496
3217
  default:
4497
3218
  return null;
4498
3219
  }
4499
3220
  }
4500
3221
  function EmptySearchResult({ state }) {
4501
- return /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(import_components51.Markdown, { className: "m-t-2", config: { link: { target: "_blank" } }, children: state.message });
3222
+ return /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(import_components45.Markdown, { className: "m-t-2", config: { link: { target: "_blank" } }, children: state.message });
4502
3223
  }
4503
3224
  function SearchResults({
4504
3225
  state,
4505
3226
  trackEvent
4506
3227
  }) {
4507
- return /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(import_components51.List, { children: state.results.map((result) => {
3228
+ return /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(import_components45.List, { children: state.results.map((result) => {
4508
3229
  const { media } = result;
4509
- return /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(
4510
- import_components51.ListItem,
3230
+ return /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(
3231
+ import_components45.ListItem,
4511
3232
  {
4512
3233
  title: result.title,
4513
3234
  subtitle: result.description,
4514
- media: media ? /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(OptionMedia, { media, preferAvatar: false }) : void 0,
4515
- control: /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(
4516
- import_components51.ListItem.Navigation,
3235
+ media: media ? /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(OptionMedia, { media, preferAvatar: false }) : void 0,
3236
+ control: /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(
3237
+ import_components45.ListItem.Navigation,
4517
3238
  {
4518
3239
  onClick: () => {
4519
3240
  trackEvent("Search Result Selected", __spreadValues({
@@ -4531,11 +3252,11 @@ function SearchResults({
4531
3252
  var BlockSearchRendererComponent_default = BlockSearchRendererComponent;
4532
3253
 
4533
3254
  // ../renderers/src/SearchRenderer/InlineSearchRendererComponent.tsx
4534
- var import_components52 = require("@transferwise/components");
4535
- var import_icons5 = require("@transferwise/icons");
4536
- var import_react18 = require("react");
4537
- var import_react_intl25 = require("react-intl");
4538
- var import_jsx_runtime75 = require("react/jsx-runtime");
3255
+ var import_components46 = require("@transferwise/components");
3256
+ var import_icons4 = require("@transferwise/icons");
3257
+ var import_react17 = require("react");
3258
+ var import_react_intl23 = require("react-intl");
3259
+ var import_jsx_runtime67 = require("react/jsx-runtime");
4539
3260
  function InlineSearchRenderer({
4540
3261
  id,
4541
3262
  hint,
@@ -4547,9 +3268,9 @@ function InlineSearchRenderer({
4547
3268
  onChange,
4548
3269
  trackEvent
4549
3270
  }) {
4550
- const [hasSearched, setHasSearched] = (0, import_react18.useState)(false);
4551
- const intl = (0, import_react_intl25.useIntl)();
4552
- return /* @__PURE__ */ (0, import_jsx_runtime75.jsx)("div", { className: getMargin(margin), children: /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(
3271
+ const [hasSearched, setHasSearched] = (0, import_react17.useState)(false);
3272
+ const intl = (0, import_react_intl23.useIntl)();
3273
+ return /* @__PURE__ */ (0, import_jsx_runtime67.jsx)("div", { className: getMargin(margin), children: /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
4553
3274
  FieldInput_default,
4554
3275
  {
4555
3276
  id,
@@ -4558,8 +3279,8 @@ function InlineSearchRenderer({
4558
3279
  help: "",
4559
3280
  label: title,
4560
3281
  features,
4561
- children: /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(
4562
- import_components52.Typeahead,
3282
+ children: /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
3283
+ import_components46.Typeahead,
4563
3284
  {
4564
3285
  id: "typeahead-input-id",
4565
3286
  intl,
@@ -4567,10 +3288,10 @@ function InlineSearchRenderer({
4567
3288
  size: "md",
4568
3289
  placeholder: hint,
4569
3290
  maxHeight: 100,
4570
- footer: /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(TypeaheadFooter, { state, isLoading }),
3291
+ footer: /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(TypeaheadFooter, { state, isLoading }),
4571
3292
  multiple: false,
4572
3293
  clearable: false,
4573
- addon: /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(import_icons5.Search, { size: 24 }),
3294
+ addon: /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(import_icons4.Search, { size: 24 }),
4574
3295
  options: state.type === "results" ? state.results.map(mapResultToTypeaheadOption) : [],
4575
3296
  minQueryLength: 1,
4576
3297
  onChange: (values) => {
@@ -4607,33 +3328,33 @@ function mapResultToTypeaheadOption(result) {
4607
3328
  };
4608
3329
  }
4609
3330
  function TypeaheadFooter({ state, isLoading }) {
4610
- const { formatMessage } = (0, import_react_intl25.useIntl)();
3331
+ const { formatMessage } = (0, import_react_intl23.useIntl)();
4611
3332
  if (state.type === "layout") {
4612
- return /* @__PURE__ */ (0, import_jsx_runtime75.jsx)("div", { className: "m-x-1 m-y-1", children: state.layout });
3333
+ return /* @__PURE__ */ (0, import_jsx_runtime67.jsx)("div", { className: "m-x-1 m-y-1", children: state.layout });
4613
3334
  }
4614
3335
  if (state.type === "noResults") {
4615
- return /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(import_components52.Markdown, { className: "m-t-2 m-x-2", config: { link: { target: "_blank" } }, children: state.message });
3336
+ return /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(import_components46.Markdown, { className: "m-t-2 m-x-2", config: { link: { target: "_blank" } }, children: state.message });
4616
3337
  }
4617
3338
  if (state.type === "error") {
4618
- return /* @__PURE__ */ (0, import_jsx_runtime75.jsx)("div", { className: "m-t-2 m-x-2", children: /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(ErrorResult, { state }) });
3339
+ return /* @__PURE__ */ (0, import_jsx_runtime67.jsx)("div", { className: "m-t-2 m-x-2", children: /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(ErrorResult, { state }) });
4619
3340
  }
4620
3341
  if (state.type === "pending" || isLoading) {
4621
- return /* @__PURE__ */ (0, import_jsx_runtime75.jsx)("p", { className: "m-t-2 m-x-2", children: formatMessage(search_messages_default.loading) });
3342
+ return /* @__PURE__ */ (0, import_jsx_runtime67.jsx)("p", { className: "m-t-2 m-x-2", children: formatMessage(search_messages_default.loading) });
4622
3343
  }
4623
3344
  return null;
4624
3345
  }
4625
3346
  var InlineSearchRendererComponent_default = InlineSearchRenderer;
4626
3347
 
4627
3348
  // ../renderers/src/SearchRenderer/SearchRenderer.tsx
4628
- var import_jsx_runtime76 = require("react/jsx-runtime");
3349
+ var import_jsx_runtime68 = require("react/jsx-runtime");
4629
3350
  var SearchRenderer = {
4630
3351
  canRenderType: "search",
4631
- render: (props) => props.control === "inline" ? /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(InlineSearchRendererComponent_default, __spreadValues({}, props)) : /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(BlockSearchRendererComponent_default, __spreadValues({}, props))
3352
+ render: (props) => props.control === "inline" ? /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(InlineSearchRendererComponent_default, __spreadValues({}, props)) : /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(BlockSearchRendererComponent_default, __spreadValues({}, props))
4632
3353
  };
4633
3354
  var SearchRenderer_default = SearchRenderer;
4634
3355
 
4635
3356
  // ../renderers/src/SectionRenderer.tsx
4636
- var import_components53 = require("@transferwise/components");
3357
+ var import_components47 = require("@transferwise/components");
4637
3358
 
4638
3359
  // ../renderers/src/utils/getHeaderAction.tsx
4639
3360
  var getHeaderAction2 = (callToAction) => {
@@ -4657,12 +3378,12 @@ var getHeaderAction2 = (callToAction) => {
4657
3378
  };
4658
3379
 
4659
3380
  // ../renderers/src/SectionRenderer.tsx
4660
- var import_jsx_runtime77 = require("react/jsx-runtime");
3381
+ var import_jsx_runtime69 = require("react/jsx-runtime");
4661
3382
  var SectionRenderer = {
4662
3383
  canRenderType: "section",
4663
3384
  render: ({ children, callToAction, margin, title }) => {
4664
- return /* @__PURE__ */ (0, import_jsx_runtime77.jsxs)("section", { className: getMargin(margin), children: [
4665
- (title || callToAction) && /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(import_components53.Header, { title: title != null ? title : "", action: getHeaderAction2(callToAction) }),
3385
+ return /* @__PURE__ */ (0, import_jsx_runtime69.jsxs)("section", { className: getMargin(margin), children: [
3386
+ (title || callToAction) && /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(import_components47.Header, { title: title != null ? title : "", action: getHeaderAction2(callToAction) }),
4666
3387
  children
4667
3388
  ] });
4668
3389
  }
@@ -4670,8 +3391,8 @@ var SectionRenderer = {
4670
3391
  var SectionRenderer_default = SectionRenderer;
4671
3392
 
4672
3393
  // ../renderers/src/SelectInputRenderer/RadioInputRendererComponent.tsx
4673
- var import_components54 = require("@transferwise/components");
4674
- var import_jsx_runtime78 = require("react/jsx-runtime");
3394
+ var import_components48 = require("@transferwise/components");
3395
+ var import_jsx_runtime70 = require("react/jsx-runtime");
4675
3396
  function RadioInputRendererComponent(props) {
4676
3397
  const {
4677
3398
  id,
@@ -4686,8 +3407,8 @@ function RadioInputRendererComponent(props) {
4686
3407
  validationState,
4687
3408
  onSelect
4688
3409
  } = props;
4689
- return /* @__PURE__ */ (0, import_jsx_runtime78.jsxs)(import_jsx_runtime78.Fragment, { children: [
4690
- /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(
3410
+ return /* @__PURE__ */ (0, import_jsx_runtime70.jsxs)(import_jsx_runtime70.Fragment, { children: [
3411
+ /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(
4691
3412
  FieldInput_default,
4692
3413
  {
4693
3414
  id,
@@ -4696,8 +3417,8 @@ function RadioInputRendererComponent(props) {
4696
3417
  description,
4697
3418
  validation: validationState,
4698
3419
  features,
4699
- children: /* @__PURE__ */ (0, import_jsx_runtime78.jsx)("span", { children: /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(
4700
- import_components54.RadioGroup,
3420
+ children: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)("span", { children: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(
3421
+ import_components48.RadioGroup,
4701
3422
  {
4702
3423
  name: id,
4703
3424
  radios: options.map((option, index) => ({
@@ -4705,7 +3426,7 @@ function RadioInputRendererComponent(props) {
4705
3426
  value: index,
4706
3427
  secondary: option.description,
4707
3428
  disabled: option.disabled || disabled,
4708
- avatar: /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(OptionMedia, { media: option.media, preferAvatar: false })
3429
+ avatar: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(OptionMedia, { media: option.media, preferAvatar: false })
4709
3430
  })),
4710
3431
  selectedValue: selectedIndex != null ? selectedIndex : void 0,
4711
3432
  onChange: onSelect
@@ -4719,9 +3440,9 @@ function RadioInputRendererComponent(props) {
4719
3440
  }
4720
3441
 
4721
3442
  // ../renderers/src/SelectInputRenderer/TabInputRendererComponent.tsx
4722
- var import_components55 = require("@transferwise/components");
4723
- var import_react19 = require("react");
4724
- var import_jsx_runtime79 = require("react/jsx-runtime");
3443
+ var import_components49 = require("@transferwise/components");
3444
+ var import_react18 = require("react");
3445
+ var import_jsx_runtime71 = require("react/jsx-runtime");
4725
3446
  function TabInputRendererComponent(props) {
4726
3447
  const {
4727
3448
  id,
@@ -4736,13 +3457,13 @@ function TabInputRendererComponent(props) {
4736
3457
  validationState,
4737
3458
  onSelect
4738
3459
  } = props;
4739
- (0, import_react19.useEffect)(() => {
3460
+ (0, import_react18.useEffect)(() => {
4740
3461
  if (!isValidIndex2(selectedIndex, options.length)) {
4741
3462
  onSelect(0);
4742
3463
  }
4743
3464
  }, [selectedIndex, onSelect, options.length]);
4744
- return /* @__PURE__ */ (0, import_jsx_runtime79.jsxs)(import_jsx_runtime79.Fragment, { children: [
4745
- /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(
3465
+ return /* @__PURE__ */ (0, import_jsx_runtime71.jsxs)(import_jsx_runtime71.Fragment, { children: [
3466
+ /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(
4746
3467
  FieldInput_default,
4747
3468
  {
4748
3469
  id,
@@ -4751,8 +3472,8 @@ function TabInputRendererComponent(props) {
4751
3472
  description,
4752
3473
  validation: validationState,
4753
3474
  features,
4754
- children: /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(
4755
- import_components55.Tabs,
3475
+ children: /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(
3476
+ import_components49.Tabs,
4756
3477
  {
4757
3478
  name: id,
4758
3479
  selected: selectedIndex != null ? selectedIndex : 0,
@@ -4760,7 +3481,7 @@ function TabInputRendererComponent(props) {
4760
3481
  title: option.title,
4761
3482
  // if we pass null, we get some props-types console errors
4762
3483
  // eslint-disable-next-line react/jsx-no-useless-fragment
4763
- content: /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(import_jsx_runtime79.Fragment, {}),
3484
+ content: /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(import_jsx_runtime71.Fragment, {}),
4764
3485
  disabled: option.disabled || disabled
4765
3486
  })),
4766
3487
  onTabSelect: onSelect
@@ -4774,8 +3495,8 @@ function TabInputRendererComponent(props) {
4774
3495
  var isValidIndex2 = (index, options) => index !== null && index >= 0 && index < options;
4775
3496
 
4776
3497
  // ../renderers/src/SelectInputRenderer/SelectInputRendererComponent.tsx
4777
- var import_components56 = require("@transferwise/components");
4778
- var import_jsx_runtime80 = require("react/jsx-runtime");
3498
+ var import_components50 = require("@transferwise/components");
3499
+ var import_jsx_runtime72 = require("react/jsx-runtime");
4779
3500
  function SelectInputRendererComponent(props) {
4780
3501
  const {
4781
3502
  id,
@@ -4816,13 +3537,13 @@ function SelectInputRendererComponent(props) {
4816
3537
  } : {
4817
3538
  title: option.title,
4818
3539
  description: option.description,
4819
- icon: /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(OptionMedia, { media: option.media, preferAvatar: false })
3540
+ icon: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(OptionMedia, { media: option.media, preferAvatar: false })
4820
3541
  };
4821
- return /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(import_components56.SelectInputOptionContent, __spreadValues({}, contentProps));
3542
+ return /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_components50.SelectInputOptionContent, __spreadValues({}, contentProps));
4822
3543
  };
4823
3544
  const extraProps = { autoComplete };
4824
- return /* @__PURE__ */ (0, import_jsx_runtime80.jsxs)(import_jsx_runtime80.Fragment, { children: [
4825
- /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(
3545
+ return /* @__PURE__ */ (0, import_jsx_runtime72.jsxs)(import_jsx_runtime72.Fragment, { children: [
3546
+ /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(
4826
3547
  FieldInput_default,
4827
3548
  {
4828
3549
  id,
@@ -4831,8 +3552,8 @@ function SelectInputRendererComponent(props) {
4831
3552
  description,
4832
3553
  validation: validationState,
4833
3554
  features,
4834
- children: /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(
4835
- import_components56.SelectInput,
3555
+ children: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(
3556
+ import_components50.SelectInput,
4836
3557
  __spreadValues({
4837
3558
  name: id,
4838
3559
  placeholder,
@@ -4852,9 +3573,9 @@ function SelectInputRendererComponent(props) {
4852
3573
  }
4853
3574
 
4854
3575
  // ../renderers/src/SelectInputRenderer/SegmentedInputRendererComponent.tsx
4855
- var import_react20 = require("react");
4856
- var import_components57 = require("@transferwise/components");
4857
- var import_jsx_runtime81 = require("react/jsx-runtime");
3576
+ var import_react19 = require("react");
3577
+ var import_components51 = require("@transferwise/components");
3578
+ var import_jsx_runtime73 = require("react/jsx-runtime");
4858
3579
  function SegmentedInputRendererComponent(props) {
4859
3580
  const {
4860
3581
  id,
@@ -4868,13 +3589,13 @@ function SegmentedInputRendererComponent(props) {
4868
3589
  validationState,
4869
3590
  onSelect
4870
3591
  } = props;
4871
- (0, import_react20.useEffect)(() => {
3592
+ (0, import_react19.useEffect)(() => {
4872
3593
  if (!isValidIndex3(selectedIndex, options.length)) {
4873
3594
  onSelect(0);
4874
3595
  }
4875
3596
  }, [selectedIndex, onSelect, options.length]);
4876
- return /* @__PURE__ */ (0, import_jsx_runtime81.jsxs)(import_jsx_runtime81.Fragment, { children: [
4877
- /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(
3597
+ return /* @__PURE__ */ (0, import_jsx_runtime73.jsxs)(import_jsx_runtime73.Fragment, { children: [
3598
+ /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(
4878
3599
  FieldInput_default,
4879
3600
  {
4880
3601
  id,
@@ -4883,8 +3604,8 @@ function SegmentedInputRendererComponent(props) {
4883
3604
  description,
4884
3605
  validation: validationState,
4885
3606
  features,
4886
- children: /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(
4887
- import_components57.SegmentedControl,
3607
+ children: /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(
3608
+ import_components51.SegmentedControl,
4888
3609
  {
4889
3610
  name: `${id}-segmented-control`,
4890
3611
  value: String(selectedIndex),
@@ -4900,14 +3621,14 @@ function SegmentedInputRendererComponent(props) {
4900
3621
  )
4901
3622
  }
4902
3623
  ),
4903
- /* @__PURE__ */ (0, import_jsx_runtime81.jsx)("div", { id: `${id}-children`, children })
3624
+ /* @__PURE__ */ (0, import_jsx_runtime73.jsx)("div", { id: `${id}-children`, children })
4904
3625
  ] });
4905
3626
  }
4906
3627
  var isValidIndex3 = (index, options) => index !== null && index >= 0 && index < options;
4907
3628
 
4908
3629
  // ../renderers/src/SelectInputRenderer/RadioItemRendererComponent.tsx
4909
- var import_components58 = require("@transferwise/components");
4910
- var import_jsx_runtime82 = require("react/jsx-runtime");
3630
+ var import_components52 = require("@transferwise/components");
3631
+ var import_jsx_runtime74 = require("react/jsx-runtime");
4911
3632
  function RadioItemRendererComponent(props) {
4912
3633
  const {
4913
3634
  id,
@@ -4923,23 +3644,23 @@ function RadioItemRendererComponent(props) {
4923
3644
  onSelect
4924
3645
  } = props;
4925
3646
  const { ref } = useScrollToError(validationState, features);
4926
- return /* @__PURE__ */ (0, import_jsx_runtime82.jsxs)("div", { ref, children: [
4927
- rootTitle && /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(
4928
- import_components58.Header,
3647
+ return /* @__PURE__ */ (0, import_jsx_runtime74.jsxs)("div", { ref, children: [
3648
+ rootTitle && /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(
3649
+ import_components52.Header,
4929
3650
  {
4930
3651
  as: "h2",
4931
- title: help ? /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(LabelContentWithHelp, { text: rootTitle, help }) : rootTitle
3652
+ title: help ? /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(LabelContentWithHelp, { text: rootTitle, help }) : rootTitle
4932
3653
  }
4933
3654
  ),
4934
- rootDescription && /* @__PURE__ */ (0, import_jsx_runtime82.jsx)("p", { children: rootDescription }),
4935
- /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(import_components58.List, { children: options.map(
4936
- ({ title, description, additionalText, inlineAlert, disabled, media, supportingValues }, index) => /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(
4937
- import_components58.ListItem,
3655
+ rootDescription && /* @__PURE__ */ (0, import_jsx_runtime74.jsx)("p", { children: rootDescription }),
3656
+ /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(import_components52.List, { children: options.map(
3657
+ ({ title, description, additionalText, inlineAlert, disabled, media, supportingValues }, index) => /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(
3658
+ import_components52.ListItem,
4938
3659
  __spreadValues({
4939
3660
  title,
4940
3661
  subtitle: description,
4941
- control: /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(
4942
- import_components58.ListItem.Radio,
3662
+ control: /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(
3663
+ import_components52.ListItem.Radio,
4943
3664
  {
4944
3665
  name: title,
4945
3666
  checked: selectedIndex === index,
@@ -4954,50 +3675,50 @@ function RadioItemRendererComponent(props) {
4954
3675
  title
4955
3676
  )
4956
3677
  ) }, `${id}-${selectedIndex}`),
4957
- (validationState == null ? void 0 : validationState.status) === "invalid" && /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(import_components58.InlineAlert, { type: "negative", children: validationState.message }),
3678
+ (validationState == null ? void 0 : validationState.status) === "invalid" && /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(import_components52.InlineAlert, { type: "negative", children: validationState.message }),
4958
3679
  children
4959
3680
  ] });
4960
3681
  }
4961
3682
 
4962
3683
  // ../renderers/src/SelectInputRenderer/SelectInputRenderer.tsx
4963
- var import_jsx_runtime83 = require("react/jsx-runtime");
3684
+ var import_jsx_runtime75 = require("react/jsx-runtime");
4964
3685
  var SelectInputRenderer = {
4965
3686
  canRenderType: "input-select",
4966
3687
  render: (props) => {
4967
3688
  switch (props.control) {
4968
3689
  case "radio":
4969
- return /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(RadioInputRendererComponent, __spreadValues({}, props));
3690
+ return /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(RadioInputRendererComponent, __spreadValues({}, props));
4970
3691
  case "radio-item":
4971
- return /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(RadioItemRendererComponent, __spreadValues({}, props));
3692
+ return /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(RadioItemRendererComponent, __spreadValues({}, props));
4972
3693
  case "tab":
4973
- return props.options.length > 3 ? /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(SelectInputRendererComponent, __spreadValues({}, props)) : /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(TabInputRendererComponent, __spreadValues({}, props));
3694
+ return props.options.length > 3 ? /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(SelectInputRendererComponent, __spreadValues({}, props)) : /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(TabInputRendererComponent, __spreadValues({}, props));
4974
3695
  case "segmented":
4975
- return props.options.length > 3 ? /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(SelectInputRendererComponent, __spreadValues({}, props)) : /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(SegmentedInputRendererComponent, __spreadValues({}, props));
3696
+ return props.options.length > 3 ? /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(SelectInputRendererComponent, __spreadValues({}, props)) : /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(SegmentedInputRendererComponent, __spreadValues({}, props));
4976
3697
  case "select":
4977
3698
  default:
4978
- return /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(SelectInputRendererComponent, __spreadValues({}, props));
3699
+ return /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(SelectInputRendererComponent, __spreadValues({}, props));
4979
3700
  }
4980
3701
  }
4981
3702
  };
4982
3703
  var SelectInputRenderer_default = SelectInputRenderer;
4983
3704
 
4984
3705
  // ../renderers/src/StatusListRenderer.tsx
4985
- var import_components59 = require("@transferwise/components");
4986
- var import_jsx_runtime84 = require("react/jsx-runtime");
3706
+ var import_components53 = require("@transferwise/components");
3707
+ var import_jsx_runtime76 = require("react/jsx-runtime");
4987
3708
  var StatusListRenderer = {
4988
3709
  canRenderType: "status-list",
4989
- render: ({ margin, items, title }) => /* @__PURE__ */ (0, import_jsx_runtime84.jsxs)("div", { className: getMargin(margin), children: [
4990
- title ? /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(import_components59.Header, { title }) : null,
3710
+ render: ({ margin, items, title }) => /* @__PURE__ */ (0, import_jsx_runtime76.jsxs)("div", { className: getMargin(margin), children: [
3711
+ title ? /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(import_components53.Header, { title }) : null,
4991
3712
  items.map((item) => {
4992
3713
  const { callToAction, description, title: itemTitle } = item;
4993
- return /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(
4994
- import_components59.ListItem,
3714
+ return /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(
3715
+ import_components53.ListItem,
4995
3716
  {
4996
3717
  title: itemTitle,
4997
3718
  subtitle: description,
4998
- media: /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(StatusListItemMedia, __spreadValues({}, item)),
4999
- additionalInfo: callToAction ? /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(
5000
- import_components59.ListItem.AdditionalInfo,
3719
+ media: /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(StatusListItemMedia, __spreadValues({}, item)),
3720
+ additionalInfo: callToAction ? /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(
3721
+ import_components53.ListItem.AdditionalInfo,
5001
3722
  {
5002
3723
  action: __spreadValues({
5003
3724
  label: callToAction.title
@@ -5015,10 +3736,10 @@ var StatusListItemMedia = ({ icon, status }) => {
5015
3736
  return void 0;
5016
3737
  }
5017
3738
  if ("name" in icon) {
5018
- return /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(import_components59.AvatarView, { badge: { status: mapStatus(status) }, children: /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(DynamicIcon_default, { name: icon.name }) });
3739
+ return /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(import_components53.AvatarView, { badge: { status: mapStatus(status) }, children: /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(DynamicIcon_default, { name: icon.name }) });
5019
3740
  }
5020
3741
  if ("text" in icon) {
5021
- return /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(import_components59.AvatarView, { badge: { status: mapStatus(status) }, children: icon.text });
3742
+ return /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(import_components53.AvatarView, { badge: { status: mapStatus(status) }, children: icon.text });
5022
3743
  }
5023
3744
  return void 0;
5024
3745
  };
@@ -5036,12 +3757,12 @@ var StatusListRenderer_default = StatusListRenderer;
5036
3757
 
5037
3758
  // ../renderers/src/utils/useCustomTheme.ts
5038
3759
  var import_components_theming = require("@wise/components-theming");
5039
- var import_react21 = require("react");
3760
+ var import_react20 = require("react");
5040
3761
  var ThemeRequiredEventName = "Theme Required";
5041
3762
  var useCustomTheme = (theme, trackEvent) => {
5042
3763
  const theming = (0, import_components_theming.useTheme)();
5043
- const previousTheme = (0, import_react21.useMemo)(() => theming.theme, []);
5044
- (0, import_react21.useEffect)(() => {
3764
+ const previousTheme = (0, import_react20.useMemo)(() => theming.theme, []);
3765
+ (0, import_react20.useEffect)(() => {
5045
3766
  theming.setTheme(theme);
5046
3767
  trackEvent(ThemeRequiredEventName, { theme });
5047
3768
  return theme !== previousTheme ? () => {
@@ -5052,14 +3773,86 @@ var useCustomTheme = (theme, trackEvent) => {
5052
3773
  }, []);
5053
3774
  };
5054
3775
 
3776
+ // ../renderers/src/step/StepFooter.tsx
3777
+ var import_components54 = require("@transferwise/components");
3778
+ var import_react21 = require("react");
3779
+ var import_react_intl25 = require("react-intl");
3780
+
3781
+ // ../renderers/src/messages/step.messages.ts
3782
+ var import_react_intl24 = require("react-intl");
3783
+ var step_messages_default = (0, import_react_intl24.defineMessages)({
3784
+ scrollToBottom: {
3785
+ id: "df.wise.step.scrollToBottom",
3786
+ defaultMessage: "Scroll to bottom",
3787
+ 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."
3788
+ }
3789
+ });
3790
+
3791
+ // ../renderers/src/step/StepFooter.tsx
3792
+ var import_jsx_runtime77 = require("react/jsx-runtime");
3793
+ var SCROLL_TO_BOTTOM = "scroll-to-bottom";
3794
+ var StepFooter = ({ footer, tags }) => {
3795
+ if (tags == null ? void 0 : tags.includes(SCROLL_TO_BOTTOM)) {
3796
+ return /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(FooterWithScrollButton, { footer });
3797
+ }
3798
+ return /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(DefaultFooter, { footer });
3799
+ };
3800
+ var DefaultFooter = ({ footer }) => {
3801
+ const hasFooter = footer && Array.isArray(footer) && footer.length > 0;
3802
+ return hasFooter ? /* @__PURE__ */ (0, import_jsx_runtime77.jsx)("div", { className: "df-step-fixed__footer", children: footer }) : void 0;
3803
+ };
3804
+ var FooterWithScrollButton = ({ footer }) => {
3805
+ const { formatMessage } = (0, import_react_intl25.useIntl)();
3806
+ const endOfLayoutRef = (0, import_react21.useRef)(null);
3807
+ const isElementVisible = useIsElementVisible(endOfLayoutRef);
3808
+ const scrollButton = /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(
3809
+ import_components54.Button,
3810
+ {
3811
+ className: "m-b-1",
3812
+ v2: true,
3813
+ block: true,
3814
+ priority: "tertiary",
3815
+ onClick: () => {
3816
+ var _a;
3817
+ (_a = endOfLayoutRef.current) == null ? void 0 : _a.scrollIntoView({ behavior: "smooth" });
3818
+ },
3819
+ children: formatMessage(step_messages_default.scrollToBottom)
3820
+ }
3821
+ );
3822
+ const hasStepFooterContent = footer && Array.isArray(footer) && footer.length > 0;
3823
+ if (isElementVisible && !hasStepFooterContent) {
3824
+ return /* @__PURE__ */ (0, import_jsx_runtime77.jsx)("div", { ref: endOfLayoutRef, "aria-hidden": "true" });
3825
+ }
3826
+ return /* @__PURE__ */ (0, import_jsx_runtime77.jsxs)(import_jsx_runtime77.Fragment, { children: [
3827
+ /* @__PURE__ */ (0, import_jsx_runtime77.jsx)("div", { ref: endOfLayoutRef, "aria-hidden": "true" }),
3828
+ /* @__PURE__ */ (0, import_jsx_runtime77.jsxs)("div", { className: "df-step-fixed__footer", children: [
3829
+ !isElementVisible && scrollButton,
3830
+ footer
3831
+ ] })
3832
+ ] });
3833
+ };
3834
+ var useIsElementVisible = (elementRef) => {
3835
+ const [isVisible, setIsVisible] = (0, import_react21.useState)(false);
3836
+ (0, import_react21.useEffect)(() => {
3837
+ const element = elementRef.current;
3838
+ if (!element) return;
3839
+ const observer = new IntersectionObserver(([entry]) => {
3840
+ setIsVisible(entry.isIntersecting);
3841
+ });
3842
+ observer.observe(element);
3843
+ return () => observer.disconnect();
3844
+ }, [elementRef]);
3845
+ return isVisible;
3846
+ };
3847
+
5055
3848
  // ../renderers/src/step/StepHeader.tsx
5056
- var import_components60 = require("@transferwise/components");
5057
- var import_jsx_runtime85 = require("react/jsx-runtime");
3849
+ var import_components55 = require("@transferwise/components");
3850
+ var import_jsx_runtime78 = require("react/jsx-runtime");
5058
3851
  var StepHeader = ({ title, description, tags }) => {
5059
3852
  const { titleType, alignmentClassName } = getHeaderStyle(tags);
5060
- return /* @__PURE__ */ (0, import_jsx_runtime85.jsxs)(import_jsx_runtime85.Fragment, { children: [
5061
- title ? /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(import_components60.Title, { as: "h1", type: titleType, className: `${alignmentClassName} m-b-2`, children: title }) : void 0,
5062
- description ? /* @__PURE__ */ (0, import_jsx_runtime85.jsx)("p", { className: `${alignmentClassName} np-text-body-large`, children: description }) : void 0
3853
+ return /* @__PURE__ */ (0, import_jsx_runtime78.jsxs)(import_jsx_runtime78.Fragment, { children: [
3854
+ title ? /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(import_components55.Title, { as: "h1", type: titleType, className: `${alignmentClassName} m-b-2`, children: title }) : void 0,
3855
+ description ? /* @__PURE__ */ (0, import_jsx_runtime78.jsx)("p", { className: `${alignmentClassName} np-text-body-large`, children: description }) : void 0
5063
3856
  ] });
5064
3857
  };
5065
3858
  var getHeaderStyle = (tags) => {
@@ -5070,8 +3863,8 @@ var getHeaderStyle = (tags) => {
5070
3863
  };
5071
3864
 
5072
3865
  // ../renderers/src/step/topbar/BackButton.tsx
5073
- var import_components61 = require("@transferwise/components");
5074
- var import_icons6 = require("@transferwise/icons");
3866
+ var import_components56 = require("@transferwise/components");
3867
+ var import_icons5 = require("@transferwise/icons");
5075
3868
  var import_react_intl27 = require("react-intl");
5076
3869
 
5077
3870
  // ../renderers/src/messages/back.messages.ts
@@ -5085,31 +3878,31 @@ var back_messages_default = (0, import_react_intl26.defineMessages)({
5085
3878
  });
5086
3879
 
5087
3880
  // ../renderers/src/step/topbar/BackButton.tsx
5088
- var import_jsx_runtime86 = require("react/jsx-runtime");
3881
+ var import_jsx_runtime79 = require("react/jsx-runtime");
5089
3882
  function BackButton({ title, onClick }) {
5090
3883
  const { formatMessage } = (0, import_react_intl27.useIntl)();
5091
- return /* @__PURE__ */ (0, import_jsx_runtime86.jsxs)(import_components61.IconButton, { className: "df-back-button", priority: "tertiary", onClick, children: [
5092
- /* @__PURE__ */ (0, import_jsx_runtime86.jsx)("span", { className: "sr-only", children: title != null ? title : formatMessage(back_messages_default.back) }),
5093
- /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(import_icons6.ArrowLeft, {})
3884
+ return /* @__PURE__ */ (0, import_jsx_runtime79.jsxs)(import_components56.IconButton, { className: "df-back-button", priority: "tertiary", onClick, children: [
3885
+ /* @__PURE__ */ (0, import_jsx_runtime79.jsx)("span", { className: "sr-only", children: title != null ? title : formatMessage(back_messages_default.back) }),
3886
+ /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(import_icons5.ArrowLeft, {})
5094
3887
  ] });
5095
3888
  }
5096
3889
 
5097
3890
  // ../renderers/src/step/topbar/Toolbar.tsx
5098
- var import_components62 = require("@transferwise/components");
5099
- var import_jsx_runtime87 = require("react/jsx-runtime");
3891
+ var import_components57 = require("@transferwise/components");
3892
+ var import_jsx_runtime80 = require("react/jsx-runtime");
5100
3893
  var Toolbar = ({ items }) => {
5101
- return (items == null ? void 0 : items.length) > 0 ? /* @__PURE__ */ (0, import_jsx_runtime87.jsx)("div", { className: "df-toolbar", children: items.map((item, index) => /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(ToolbarButton, __spreadValues({}, item), `${item.type}-${index}-${item.title}`)) }) : null;
3894
+ return (items == null ? void 0 : items.length) > 0 ? /* @__PURE__ */ (0, import_jsx_runtime80.jsx)("div", { className: "df-toolbar", children: items.map((item, index) => /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(ToolbarButton, __spreadValues({}, item), `${item.type}-${index}-${item.title}`)) }) : null;
5102
3895
  };
5103
3896
  function ToolbarButton(props) {
5104
- return prefersMedia(props.control) ? /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(MediaToolbarButton, __spreadValues({}, props)) : /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(TextToolbarButton, __spreadValues({}, props));
3897
+ return prefersMedia(props.control) ? /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(MediaToolbarButton, __spreadValues({}, props)) : /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(TextToolbarButton, __spreadValues({}, props));
5105
3898
  }
5106
3899
  function MediaToolbarButton(props) {
5107
3900
  var _a;
5108
3901
  const { context, control, media, accessibilityDescription, disabled, onClick } = props;
5109
3902
  const priority = getIconButtonPriority(control);
5110
3903
  const type = getSentiment2(context);
5111
- return /* @__PURE__ */ (0, import_jsx_runtime87.jsxs)(
5112
- import_components62.IconButton,
3904
+ return /* @__PURE__ */ (0, import_jsx_runtime80.jsxs)(
3905
+ import_components57.IconButton,
5113
3906
  {
5114
3907
  className: "df-toolbar-button",
5115
3908
  disabled,
@@ -5118,7 +3911,7 @@ function MediaToolbarButton(props) {
5118
3911
  type,
5119
3912
  onClick,
5120
3913
  children: [
5121
- accessibilityDescription ? /* @__PURE__ */ (0, import_jsx_runtime87.jsx)("span", { className: "sr-only", children: accessibilityDescription }) : null,
3914
+ accessibilityDescription ? /* @__PURE__ */ (0, import_jsx_runtime80.jsx)("span", { className: "sr-only", children: accessibilityDescription }) : null,
5122
3915
  media ? (_a = getAddonStartMedia(media)) == null ? void 0 : _a.value : null
5123
3916
  ]
5124
3917
  }
@@ -5129,8 +3922,8 @@ function TextToolbarButton(props) {
5129
3922
  const addonStart = media ? getAddonStartMedia(media) : void 0;
5130
3923
  const priority = getPriority2(control);
5131
3924
  const sentiment = getSentiment2(context);
5132
- return /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(
5133
- import_components62.Button,
3925
+ return /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(
3926
+ import_components57.Button,
5134
3927
  {
5135
3928
  v2: true,
5136
3929
  size: "sm",
@@ -5159,18 +3952,18 @@ var getIconButtonPriority = (control) => {
5159
3952
  };
5160
3953
 
5161
3954
  // ../renderers/src/step/topbar/TopBar.tsx
5162
- var import_jsx_runtime88 = require("react/jsx-runtime");
3955
+ var import_jsx_runtime81 = require("react/jsx-runtime");
5163
3956
  function TopBar({ back, toolbar, tags }) {
5164
3957
  const isBackAllowed = !(tags == null ? void 0 : tags.includes("non-dismissible"));
5165
3958
  const backCTA = isBackAllowed ? back : void 0;
5166
- return backCTA || toolbar ? /* @__PURE__ */ (0, import_jsx_runtime88.jsxs)("div", { className: "d-flex m-b-2", children: [
5167
- backCTA ? /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(BackButton, __spreadValues({}, backCTA)) : null,
5168
- toolbar ? /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(Toolbar, __spreadValues({}, toolbar)) : null
3959
+ return backCTA || toolbar ? /* @__PURE__ */ (0, import_jsx_runtime81.jsxs)("div", { className: "d-flex m-b-2", children: [
3960
+ backCTA ? /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(BackButton, __spreadValues({}, backCTA)) : null,
3961
+ toolbar ? /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(Toolbar, __spreadValues({}, toolbar)) : null
5169
3962
  ] }) : null;
5170
3963
  }
5171
3964
 
5172
3965
  // ../renderers/src/step/SplashCelebrationStepRenderer.tsx
5173
- var import_jsx_runtime89 = require("react/jsx-runtime");
3966
+ var import_jsx_runtime82 = require("react/jsx-runtime");
5174
3967
  var SplashCelebrationStepRenderer = {
5175
3968
  canRenderType: "step",
5176
3969
  canRender: ({ control }) => control === "splash-celebration",
@@ -5179,16 +3972,16 @@ var SplashCelebrationStepRenderer = {
5179
3972
  function SplashCelebrationStepRendererComponent(props) {
5180
3973
  const { back, title, description, toolbar, children, footer, tags, trackEvent } = props;
5181
3974
  useCustomTheme("forest-green", trackEvent);
5182
- return /* @__PURE__ */ (0, import_jsx_runtime89.jsxs)("div", { className: "splash-screen m-t-5", children: [
5183
- /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(TopBar, { back, toolbar, tags }),
5184
- title || description ? /* @__PURE__ */ (0, import_jsx_runtime89.jsx)("div", { className: "m-b-4", children: /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(StepHeader, { title, description, tags }) }) : void 0,
3975
+ return /* @__PURE__ */ (0, import_jsx_runtime82.jsxs)("div", { className: "splash-screen m-t-5", children: [
3976
+ /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(TopBar, { back, toolbar, tags }),
3977
+ title || description ? /* @__PURE__ */ (0, import_jsx_runtime82.jsx)("div", { className: "m-b-4", children: /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(StepHeader, { title, description, tags }) }) : void 0,
5185
3978
  children,
5186
- /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(StepFooter, { footer, tags })
3979
+ /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(StepFooter, { footer, tags })
5187
3980
  ] });
5188
3981
  }
5189
3982
 
5190
3983
  // ../renderers/src/step/SplashStepRenderer.tsx
5191
- var import_jsx_runtime90 = require("react/jsx-runtime");
3984
+ var import_jsx_runtime83 = require("react/jsx-runtime");
5192
3985
  var SplashStepRenderer = {
5193
3986
  canRenderType: "step",
5194
3987
  canRender: ({ control }) => control === "splash",
@@ -5196,63 +3989,63 @@ var SplashStepRenderer = {
5196
3989
  };
5197
3990
  function SplashStepRendererComponent(props) {
5198
3991
  const { back, title, description, toolbar, children, footer, tags } = props;
5199
- return /* @__PURE__ */ (0, import_jsx_runtime90.jsxs)("div", { className: "splash-screen m-t-5", children: [
5200
- /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(TopBar, { back, toolbar, tags }),
5201
- title || description ? /* @__PURE__ */ (0, import_jsx_runtime90.jsx)("div", { className: "m-b-4", children: /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(StepHeader, { title, description, tags }) }) : void 0,
3992
+ return /* @__PURE__ */ (0, import_jsx_runtime83.jsxs)("div", { className: "splash-screen m-t-5", children: [
3993
+ /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(TopBar, { back, toolbar, tags }),
3994
+ title || description ? /* @__PURE__ */ (0, import_jsx_runtime83.jsx)("div", { className: "m-b-4", children: /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(StepHeader, { title, description, tags }) }) : void 0,
5202
3995
  children,
5203
- /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(StepFooter, { footer, tags })
3996
+ /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(StepFooter, { footer, tags })
5204
3997
  ] });
5205
3998
  }
5206
3999
 
5207
4000
  // ../renderers/src/step/StepRenderer.tsx
5208
- var import_components63 = require("@transferwise/components");
5209
- var import_jsx_runtime91 = require("react/jsx-runtime");
4001
+ var import_components58 = require("@transferwise/components");
4002
+ var import_jsx_runtime84 = require("react/jsx-runtime");
5210
4003
  var StepRenderer = {
5211
4004
  canRenderType: "step",
5212
4005
  render: StepRendererComponent
5213
4006
  };
5214
4007
  function StepRendererComponent(props) {
5215
4008
  const { back, description, error, title, children, toolbar, footer, tags } = props;
5216
- return /* @__PURE__ */ (0, import_jsx_runtime91.jsxs)("div", { children: [
5217
- /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(TopBar, { back, toolbar, tags }),
5218
- title || description ? /* @__PURE__ */ (0, import_jsx_runtime91.jsx)("div", { className: "m-b-4", children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(StepHeader, { title, description, tags }) }) : void 0,
5219
- error ? /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(import_components63.Alert, { type: "negative", className: "m-b-2", message: error }) : null,
4009
+ return /* @__PURE__ */ (0, import_jsx_runtime84.jsxs)("div", { children: [
4010
+ /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(TopBar, { back, toolbar, tags }),
4011
+ title || description ? /* @__PURE__ */ (0, import_jsx_runtime84.jsx)("div", { className: "m-b-4", children: /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(StepHeader, { title, description, tags }) }) : void 0,
4012
+ error ? /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(import_components58.Alert, { type: "negative", className: "m-b-2", message: error }) : null,
5220
4013
  children,
5221
- /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(StepFooter, { footer, tags })
4014
+ /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(StepFooter, { footer, tags })
5222
4015
  ] });
5223
4016
  }
5224
4017
 
5225
4018
  // ../renderers/src/TabsRenderer.tsx
5226
- var import_components64 = require("@transferwise/components");
4019
+ var import_components59 = require("@transferwise/components");
5227
4020
  var import_react22 = require("react");
5228
- var import_jsx_runtime92 = require("react/jsx-runtime");
4021
+ var import_jsx_runtime85 = require("react/jsx-runtime");
5229
4022
  var TabsRenderer = {
5230
4023
  canRenderType: "tabs",
5231
4024
  render: (props) => {
5232
4025
  switch (props.control) {
5233
4026
  case "segmented":
5234
4027
  if (props.tabs.length > 3) {
5235
- return /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(TabsRendererComponent, __spreadValues({}, props));
4028
+ return /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(TabsRendererComponent, __spreadValues({}, props));
5236
4029
  }
5237
- return /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(SegmentedTabsRendererComponent, __spreadValues({}, props));
4030
+ return /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(SegmentedTabsRendererComponent, __spreadValues({}, props));
5238
4031
  case "chips":
5239
- return /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(ChipsTabsRendererComponent, __spreadValues({}, props));
4032
+ return /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(ChipsTabsRendererComponent, __spreadValues({}, props));
5240
4033
  default:
5241
- return /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(TabsRendererComponent, __spreadValues({}, props));
4034
+ return /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(TabsRendererComponent, __spreadValues({}, props));
5242
4035
  }
5243
4036
  }
5244
4037
  };
5245
4038
  function TabsRendererComponent({ uid, margin, tabs }) {
5246
4039
  const [selectedIndex, setSelectedIndex] = (0, import_react22.useState)(0);
5247
- return /* @__PURE__ */ (0, import_jsx_runtime92.jsx)("div", { className: getMargin(margin), children: /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(
5248
- import_components64.Tabs,
4040
+ return /* @__PURE__ */ (0, import_jsx_runtime85.jsx)("div", { className: getMargin(margin), children: /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(
4041
+ import_components59.Tabs,
5249
4042
  {
5250
4043
  name: uid,
5251
4044
  selected: selectedIndex != null ? selectedIndex : 0,
5252
4045
  tabs: tabs.map((option) => ({
5253
4046
  title: option.title,
5254
4047
  disabled: false,
5255
- content: /* @__PURE__ */ (0, import_jsx_runtime92.jsxs)("div", { className: "m-t-2", children: [
4048
+ content: /* @__PURE__ */ (0, import_jsx_runtime85.jsxs)("div", { className: "m-t-2", children: [
5256
4049
  " ",
5257
4050
  option.children,
5258
4051
  " "
@@ -5265,9 +4058,9 @@ function TabsRendererComponent({ uid, margin, tabs }) {
5265
4058
  function SegmentedTabsRendererComponent({ uid, margin, tabs }) {
5266
4059
  var _a;
5267
4060
  const [selectedIndex, setSelectedIndex] = (0, import_react22.useState)(0);
5268
- return /* @__PURE__ */ (0, import_jsx_runtime92.jsxs)("div", { className: getMargin(margin), children: [
5269
- /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(
5270
- import_components64.SegmentedControl,
4061
+ return /* @__PURE__ */ (0, import_jsx_runtime85.jsxs)("div", { className: getMargin(margin), children: [
4062
+ /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(
4063
+ import_components59.SegmentedControl,
5271
4064
  {
5272
4065
  name: uid,
5273
4066
  value: String(selectedIndex),
@@ -5281,31 +4074,31 @@ function SegmentedTabsRendererComponent({ uid, margin, tabs }) {
5281
4074
  onChange: (value) => setSelectedIndex(Number(value))
5282
4075
  }
5283
4076
  ),
5284
- /* @__PURE__ */ (0, import_jsx_runtime92.jsx)("div", { id: `${uid}-children`, className: "m-t-2", children: (_a = tabs[selectedIndex]) == null ? void 0 : _a.children })
4077
+ /* @__PURE__ */ (0, import_jsx_runtime85.jsx)("div", { id: `${uid}-children`, className: "m-t-2", children: (_a = tabs[selectedIndex]) == null ? void 0 : _a.children })
5285
4078
  ] });
5286
4079
  }
5287
4080
  function ChipsTabsRendererComponent({ margin, tabs }) {
5288
4081
  var _a;
5289
4082
  const [selectedIndex, setSelectedIndex] = (0, import_react22.useState)(0);
5290
- return /* @__PURE__ */ (0, import_jsx_runtime92.jsxs)("div", { className: getMargin(margin), children: [
5291
- /* @__PURE__ */ (0, import_jsx_runtime92.jsx)("div", { className: "chips-container", children: /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(
5292
- import_components64.Chips,
4083
+ return /* @__PURE__ */ (0, import_jsx_runtime85.jsxs)("div", { className: getMargin(margin), children: [
4084
+ /* @__PURE__ */ (0, import_jsx_runtime85.jsx)("div", { className: "chips-container", children: /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(
4085
+ import_components59.Chips,
5293
4086
  {
5294
4087
  chips: tabs.map((tab, index) => ({ label: tab.title, value: index })),
5295
4088
  selected: selectedIndex,
5296
4089
  onChange: ({ selectedValue }) => setSelectedIndex(Number(selectedValue))
5297
4090
  }
5298
4091
  ) }),
5299
- /* @__PURE__ */ (0, import_jsx_runtime92.jsx)("div", { className: "m-t-2", children: (_a = tabs[selectedIndex]) == null ? void 0 : _a.children })
4092
+ /* @__PURE__ */ (0, import_jsx_runtime85.jsx)("div", { className: "m-t-2", children: (_a = tabs[selectedIndex]) == null ? void 0 : _a.children })
5300
4093
  ] });
5301
4094
  }
5302
4095
 
5303
4096
  // ../renderers/src/TextInputRenderer.tsx
5304
- var import_components66 = require("@transferwise/components");
4097
+ var import_components61 = require("@transferwise/components");
5305
4098
 
5306
4099
  // ../renderers/src/components/VariableTextInput.tsx
5307
- var import_components65 = require("@transferwise/components");
5308
- var import_jsx_runtime93 = require("react/jsx-runtime");
4100
+ var import_components60 = require("@transferwise/components");
4101
+ var import_jsx_runtime86 = require("react/jsx-runtime");
5309
4102
  var commonKeys = [
5310
4103
  "autoComplete",
5311
4104
  "autoCapitalize",
@@ -5324,12 +4117,12 @@ function VariableTextInput(inputProps) {
5324
4117
  const commonProps = __spreadProps(__spreadValues({}, pick(inputProps, ...commonKeys)), { name: id });
5325
4118
  switch (control) {
5326
4119
  case "email":
5327
- return /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(TextInput, __spreadProps(__spreadValues({}, commonProps), { type: "email", onChange }));
4120
+ return /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(TextInput, __spreadProps(__spreadValues({}, commonProps), { type: "email", onChange }));
5328
4121
  case "password":
5329
- return /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(TextInput, __spreadProps(__spreadValues({}, commonProps), { type: "password", onChange }));
4122
+ return /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(TextInput, __spreadProps(__spreadValues({}, commonProps), { type: "password", onChange }));
5330
4123
  case "numeric": {
5331
4124
  const numericProps = __spreadProps(__spreadValues({}, commonProps), { type: "number", onWheel });
5332
- return /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(
4125
+ return /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(
5333
4126
  TextInput,
5334
4127
  __spreadProps(__spreadValues({}, numericProps), {
5335
4128
  onChange: (newValue) => {
@@ -5340,21 +4133,21 @@ function VariableTextInput(inputProps) {
5340
4133
  );
5341
4134
  }
5342
4135
  case "phone-number":
5343
- return /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(import_components65.PhoneNumberInput, __spreadProps(__spreadValues({ initialValue: value }, commonProps), { onChange }));
4136
+ return /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(import_components60.PhoneNumberInput, __spreadProps(__spreadValues({ initialValue: value }, commonProps), { onChange }));
5344
4137
  default: {
5345
- return /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(TextInput, __spreadProps(__spreadValues({}, commonProps), { type: "text", onChange }));
4138
+ return /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(TextInput, __spreadProps(__spreadValues({}, commonProps), { type: "text", onChange }));
5346
4139
  }
5347
4140
  }
5348
4141
  }
5349
4142
  function TextInput(props) {
5350
4143
  const _a = props, { control, displayFormat, onChange } = _a, commonProps = __objRest(_a, ["control", "displayFormat", "onChange"]);
5351
- const InputWithPattern = control === "textarea" ? import_components65.TextareaWithDisplayFormat : import_components65.InputWithDisplayFormat;
5352
- const InputWithoutPattern = control === "textarea" ? import_components65.TextArea : import_components65.Input;
5353
- return displayFormat ? /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(InputWithPattern, __spreadProps(__spreadValues({ displayPattern: displayFormat }, commonProps), { onChange })) : /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(InputWithoutPattern, __spreadProps(__spreadValues({}, commonProps), { onChange: (e) => onChange(e.target.value) }));
4144
+ const InputWithPattern = control === "textarea" ? import_components60.TextareaWithDisplayFormat : import_components60.InputWithDisplayFormat;
4145
+ const InputWithoutPattern = control === "textarea" ? import_components60.TextArea : import_components60.Input;
4146
+ return displayFormat ? /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(InputWithPattern, __spreadProps(__spreadValues({ displayPattern: displayFormat }, commonProps), { onChange })) : /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(InputWithoutPattern, __spreadProps(__spreadValues({}, commonProps), { onChange: (e) => onChange(e.target.value) }));
5354
4147
  }
5355
4148
 
5356
4149
  // ../renderers/src/TextInputRenderer.tsx
5357
- var import_jsx_runtime94 = require("react/jsx-runtime");
4150
+ var import_jsx_runtime87 = require("react/jsx-runtime");
5358
4151
  var TextInputRenderer = {
5359
4152
  canRenderType: "input-text",
5360
4153
  render: (props) => {
@@ -5387,7 +4180,7 @@ var TextInputRenderer = {
5387
4180
  }
5388
4181
  }
5389
4182
  });
5390
- return /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(
4183
+ return /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(
5391
4184
  FieldInput_default,
5392
4185
  {
5393
4186
  id,
@@ -5398,7 +4191,7 @@ var TextInputRenderer = {
5398
4191
  loadingState: props.fieldLoadingState,
5399
4192
  help,
5400
4193
  features: props.features,
5401
- children: /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(import_components66.InputGroup, { addonStart: getInputGroupAddonStart(media), children: /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(VariableTextInput, __spreadValues({}, inputProps)) })
4194
+ children: /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(import_components61.InputGroup, { addonStart: getInputGroupAddonStart(media), children: /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(VariableTextInput, __spreadValues({}, inputProps)) })
5402
4195
  }
5403
4196
  );
5404
4197
  }
@@ -5406,13 +4199,13 @@ var TextInputRenderer = {
5406
4199
  var TextInputRenderer_default = TextInputRenderer;
5407
4200
 
5408
4201
  // ../renderers/src/UploadInputRenderer.tsx
5409
- var import_components67 = require("@transferwise/components");
4202
+ var import_components62 = require("@transferwise/components");
5410
4203
 
5411
4204
  // ../renderers/src/utils/getRandomId.ts
5412
4205
  var getRandomId = () => Math.random().toString(36).substring(2);
5413
4206
 
5414
4207
  // ../renderers/src/UploadInputRenderer.tsx
5415
- var import_jsx_runtime95 = require("react/jsx-runtime");
4208
+ var import_jsx_runtime88 = require("react/jsx-runtime");
5416
4209
  var UploadInputRenderer = {
5417
4210
  canRenderType: "input-upload",
5418
4211
  render: (props) => {
@@ -5439,7 +4232,7 @@ var UploadInputRenderer = {
5439
4232
  };
5440
4233
  return (
5441
4234
  // We don't pass help here as there is no sensible place to display it
5442
- /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(
4235
+ /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(
5443
4236
  UploadFieldInput_default,
5444
4237
  {
5445
4238
  id,
@@ -5447,8 +4240,8 @@ var UploadInputRenderer = {
5447
4240
  description: void 0,
5448
4241
  validation: validationState,
5449
4242
  features,
5450
- children: /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(
5451
- import_components67.UploadInput,
4243
+ children: /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(
4244
+ import_components62.UploadInput,
5452
4245
  {
5453
4246
  id,
5454
4247
  description,
@@ -5458,7 +4251,7 @@ var UploadInputRenderer = {
5458
4251
  {
5459
4252
  id: "my-file",
5460
4253
  filename: value.name,
5461
- status: (validationState == null ? void 0 : validationState.status) === "invalid" ? import_components67.Status.FAILED : import_components67.Status.SUCCEEDED
4254
+ status: (validationState == null ? void 0 : validationState.status) === "invalid" ? import_components62.Status.FAILED : import_components62.Status.SUCCEEDED
5462
4255
  }
5463
4256
  ] : void 0,
5464
4257
  fileTypes: acceptsToFileTypes(accepts),
@@ -5515,7 +4308,7 @@ var LargeUploadRenderer = {
5515
4308
  };
5516
4309
  const filetypes = acceptsToFileTypes(accepts);
5517
4310
  const usAccept = filetypes === "*" ? "*" : filetypes.join(",");
5518
- return /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(
4311
+ return /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(
5519
4312
  FieldInput_default,
5520
4313
  {
5521
4314
  id,
@@ -5524,8 +4317,8 @@ var LargeUploadRenderer = {
5524
4317
  validation: validationState,
5525
4318
  help,
5526
4319
  features,
5527
- children: /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(
5528
- import_components67.Upload,
4320
+ children: /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(
4321
+ import_components62.Upload,
5529
4322
  __spreadProps(__spreadValues({}, uploadProps), {
5530
4323
  usAccept,
5531
4324
  usDisabled: disabled,
@@ -5540,9 +4333,9 @@ var LargeUploadRenderer = {
5540
4333
  };
5541
4334
 
5542
4335
  // ../renderers/src/UpsellRenderer.tsx
5543
- var import_components68 = require("@transferwise/components");
4336
+ var import_components63 = require("@transferwise/components");
5544
4337
  var import_react23 = require("react");
5545
- var import_jsx_runtime96 = require("react/jsx-runtime");
4338
+ var import_jsx_runtime89 = require("react/jsx-runtime");
5546
4339
  var UpsellRenderer = {
5547
4340
  canRenderType: "upsell",
5548
4341
  render: UpsellRendererComponent
@@ -5550,8 +4343,8 @@ var UpsellRenderer = {
5550
4343
  function UpsellRendererComponent(props) {
5551
4344
  const { text, callToAction, media, margin, onDismiss } = props;
5552
4345
  const [isVisible, setIsVisible] = (0, import_react23.useState)(true);
5553
- return isVisible ? /* @__PURE__ */ (0, import_jsx_runtime96.jsx)(
5554
- import_components68.Nudge,
4346
+ return isVisible ? /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(
4347
+ import_components63.Nudge,
5555
4348
  {
5556
4349
  className: getMargin(margin),
5557
4350
  mediaName: getMediaName(media),
@@ -5597,9 +4390,9 @@ var supportedMediaNames = [
5597
4390
  ];
5598
4391
 
5599
4392
  // ../renderers/src/ButtonRenderer/CircularButtonRenderer.tsx
5600
- var import_components69 = require("@transferwise/components");
4393
+ var import_components64 = require("@transferwise/components");
5601
4394
  var import_classnames8 = __toESM(require_classnames());
5602
- var import_jsx_runtime97 = require("react/jsx-runtime");
4395
+ var import_jsx_runtime90 = require("react/jsx-runtime");
5603
4396
  var CircularButtonRenderer = {
5604
4397
  canRenderType: "button",
5605
4398
  canRender: ({ control }) => control === "circular",
@@ -5609,8 +4402,8 @@ function CircularButtonComponent(props) {
5609
4402
  var _a;
5610
4403
  const { context, disabled, margin, media, tags, title, onClick } = props;
5611
4404
  const priority = tags == null ? void 0 : tags.find((tag) => tag === "primary" || tag === "secondary");
5612
- return /* @__PURE__ */ (0, import_jsx_runtime97.jsx)("div", { className: (0, import_classnames8.default)(getMargin(margin), "df-button", "circular"), children: /* @__PURE__ */ (0, import_jsx_runtime97.jsx)(
5613
- import_components69.CircularButton,
4405
+ return /* @__PURE__ */ (0, import_jsx_runtime90.jsx)("div", { className: (0, import_classnames8.default)(getMargin(margin), "df-button", "circular"), children: /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(
4406
+ import_components64.CircularButton,
5614
4407
  {
5615
4408
  disabled,
5616
4409
  priority: priority != null ? priority : "secondary",
@@ -5629,7 +4422,6 @@ var getWiseRenderers = () => [
5629
4422
  CheckboxInputRenderer_default,
5630
4423
  CircularButtonRenderer,
5631
4424
  BoxRenderer_default,
5632
- CollectionRenderer_default,
5633
4425
  ButtonRenderer,
5634
4426
  ColumnsRenderer_default,
5635
4427
  DateInputRenderer_default,
@@ -5673,13 +4465,13 @@ var getWiseRenderers = () => [
5673
4465
  ];
5674
4466
 
5675
4467
  // ../renderers/src/InitialLoadingStateRenderer.tsx
5676
- var import_components70 = require("@transferwise/components");
5677
- var import_jsx_runtime98 = require("react/jsx-runtime");
4468
+ var import_components65 = require("@transferwise/components");
4469
+ var import_jsx_runtime91 = require("react/jsx-runtime");
5678
4470
  var InitialLoadingStateRenderer = {
5679
4471
  canRenderType: "loading-state",
5680
4472
  canRender: ({ stepLoadingState }) => stepLoadingState === "initial",
5681
- render: () => /* @__PURE__ */ (0, import_jsx_runtime98.jsx)(
5682
- import_components70.Loader,
4473
+ render: () => /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
4474
+ import_components65.Loader,
5683
4475
  {
5684
4476
  size: "md",
5685
4477
  classNames: { "tw-loader": `tw-loader m-x-auto ${getMargin("md")}` },
@@ -5690,25 +4482,25 @@ var InitialLoadingStateRenderer = {
5690
4482
 
5691
4483
  // src/dynamicFlow/DynamicFlowModal.tsx
5692
4484
  var import_dynamic_flow_client = require("@wise/dynamic-flow-client");
5693
- var import_components71 = require("@transferwise/components");
5694
- var import_jsx_runtime99 = require("react/jsx-runtime");
4485
+ var import_components66 = require("@transferwise/components");
4486
+ var import_jsx_runtime92 = require("react/jsx-runtime");
5695
4487
  function DynamicFlowModal(props) {
5696
4488
  const _a = props, { className = "" } = _a, rest = __objRest(_a, ["className"]);
5697
4489
  const dfProps = useWiseToCoreProps(rest);
5698
4490
  const df = (0, import_dynamic_flow_client.useDynamicFlowModal)(dfProps);
5699
- return /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(
5700
- import_components71.Modal,
4491
+ return /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(
4492
+ import_components66.Modal,
5701
4493
  __spreadProps(__spreadValues({
5702
4494
  className: `dynamic-flow-modal ${className}`,
5703
4495
  disableDimmerClickToClose: true
5704
4496
  }, df.modal), {
5705
- body: /* @__PURE__ */ (0, import_jsx_runtime99.jsx)("div", { className: "dynamic-flow-modal", children: df.modal.body })
4497
+ body: /* @__PURE__ */ (0, import_jsx_runtime92.jsx)("div", { className: "dynamic-flow-modal", children: df.modal.body })
5706
4498
  })
5707
4499
  );
5708
4500
  }
5709
4501
 
5710
4502
  // src/dynamicFlow/getMergedRenderers.tsx
5711
- var import_jsx_runtime100 = require("react/jsx-runtime");
4503
+ var import_jsx_runtime93 = require("react/jsx-runtime");
5712
4504
  var wiseRenderers = getWiseRenderers();
5713
4505
  var getMergedRenderers = (props) => {
5714
4506
  var _d, _e;
@@ -5722,7 +4514,7 @@ var getMergedRenderers = (props) => {
5722
4514
  method: initialRequest.method,
5723
4515
  data: initialRequest.body
5724
4516
  };
5725
- return presentation.type === "push" ? /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(DynamicFlow, __spreadProps(__spreadValues(__spreadValues({}, restProps), rest), { features: subflowFeatures, initialAction: action })) : /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(
4517
+ return presentation.type === "push" ? /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(DynamicFlow, __spreadProps(__spreadValues(__spreadValues({}, restProps), rest), { features: subflowFeatures, initialAction: action })) : /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(
5726
4518
  DynamicFlowModal,
5727
4519
  __spreadProps(__spreadValues(__spreadValues({}, restProps), rest), {
5728
4520
  features: subflowFeatures,
@@ -5916,13 +4708,13 @@ var openLinkInNewTab = (url) => {
5916
4708
  };
5917
4709
 
5918
4710
  // src/dynamicFlow/DynamicFlow.tsx
5919
- var import_jsx_runtime101 = require("react/jsx-runtime");
4711
+ var import_jsx_runtime94 = require("react/jsx-runtime");
5920
4712
  function DynamicFlow(props) {
5921
4713
  const { className = "" } = props;
5922
4714
  const dfProps = useWiseToCoreProps(props);
5923
4715
  const df = (0, import_dynamic_flow_client4.useDynamicFlow)(dfProps);
5924
4716
  const { onContextMenu, contextMenu } = useDFContextMenu(df.controller);
5925
- return /* @__PURE__ */ (0, import_jsx_runtime101.jsxs)("div", { className, onContextMenu, children: [
4717
+ return /* @__PURE__ */ (0, import_jsx_runtime94.jsxs)("div", { className, onContextMenu, children: [
5926
4718
  df.view,
5927
4719
  contextMenu
5928
4720
  ] });
@@ -5931,7 +4723,7 @@ function DynamicFlow(props) {
5931
4723
  // src/dynamicFlow/DynamicFlowWithRef.tsx
5932
4724
  var import_react27 = require("react");
5933
4725
  var import_dynamic_flow_client5 = require("@wise/dynamic-flow-client");
5934
- var import_jsx_runtime102 = require("react/jsx-runtime");
4726
+ var import_jsx_runtime95 = require("react/jsx-runtime");
5935
4727
  var DynamicFlowWithRef = (0, import_react27.forwardRef)(function DynamicFlowWithRef2(props, ref) {
5936
4728
  const { className = "" } = props;
5937
4729
  const dfProps = useWiseToCoreProps(props);
@@ -5947,14 +4739,14 @@ var DynamicFlowWithRef = (0, import_react27.forwardRef)(function DynamicFlowWith
5947
4739
  }),
5948
4740
  [df]
5949
4741
  );
5950
- return /* @__PURE__ */ (0, import_jsx_runtime102.jsx)("div", { className, children: df.view });
4742
+ return /* @__PURE__ */ (0, import_jsx_runtime95.jsx)("div", { className, children: df.view });
5951
4743
  });
5952
4744
 
5953
4745
  // src/index.ts
5954
4746
  var import_dynamic_flow_client8 = require("@wise/dynamic-flow-client");
5955
4747
 
5956
4748
  // src/dynamicFlow/renderers.tsx
5957
- var Header10 = Header;
4749
+ var Header10 = Header5;
5958
4750
  var Media2 = Media;
5959
4751
  var getMargin2 = getMargin;
5960
4752