@wise/dynamic-flow-client-internal 3.1.0 → 3.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/build/main.js CHANGED
@@ -95,7 +95,7 @@ var require_main_min = __commonJS({
95
95
  };
96
96
  var pe = (e, t, o) => (o = e != null ? sg(pg(e)) : {}, sm(t || !e || !e.__esModule ? br(o, "default", { value: e, enumerable: true }) : o, e));
97
97
  var yg = (e) => sm(br({}, "__esModule", { value: true }), e);
98
- var Re = Ka((Zv, Fn) => {
98
+ var Re = Ka((tP, Fn) => {
99
99
  "use strict";
100
100
  (function() {
101
101
  "use strict";
@@ -150,21 +150,21 @@ var require_main_min = __commonJS({
150
150
  var Li = im(() => {
151
151
  "use strict";
152
152
  });
153
- var fo;
153
+ var yo;
154
154
  var Dn;
155
155
  var KC;
156
156
  var Di;
157
157
  var Lt;
158
- var vA;
159
- var PA;
158
+ var AA;
159
+ var MA;
160
160
  var Ti;
161
161
  var gc;
162
162
  var Cc = im(() => {
163
163
  "use strict";
164
164
  Li();
165
- fo = require("react"), Dn = require("react/jsx-runtime"), KC = "wise", Di = ({ code: e, intrinsicSize: t = 64, className: o = void 0 }) => {
166
- let [r, n] = (0, fo.useState)(null);
167
- (0, fo.useEffect)(() => {
165
+ yo = require("react"), Dn = require("react/jsx-runtime"), KC = "wise", Di = ({ code: e, intrinsicSize: t = 64, className: o = void 0 }) => {
166
+ let [r, n] = (0, yo.useState)(null);
167
+ (0, yo.useEffect)(() => {
168
168
  n(null);
169
169
  }, [e]);
170
170
  let a = t >= 150, i = r !== "unknown" ? `${e.toLowerCase()}${r == null && a ? "-detailed" : ""}` : KC;
@@ -175,7 +175,7 @@ var require_main_min = __commonJS({
175
175
  (function(e) {
176
176
  e.SMALL = "small", e.MEDIUM = "medium", e.LARGE = "large";
177
177
  })(Lt || (Lt = {}));
178
- vA = { [Lt.SMALL]: 200, [Lt.MEDIUM]: 300, [Lt.LARGE]: 500 }, PA = { [Lt.SMALL]: 200, [Lt.MEDIUM]: 300, [Lt.LARGE]: 500 };
178
+ AA = { [Lt.SMALL]: 200, [Lt.MEDIUM]: 300, [Lt.LARGE]: 500 }, MA = { [Lt.SMALL]: 200, [Lt.MEDIUM]: 300, [Lt.LARGE]: 500 };
179
179
  (function(e) {
180
180
  e.BELL = "bell", e.BRIEFCASE = "briefcase", e.BUSINESS_CARD = "business-card", e.CALENDAR = "calendar", e.CHECK_MARK = "check-mark", e.CLOSED_WINDOW = "closed-window", e.COIN_PILE_DOWN = "coin-pile-down", e.COIN_PILE_UP = "coin-pile-up", e.CONFETTI = "confetti", e.CONSTRUCTION_FENCE = "construction-fence", e.CONVERT = "convert", e.COOKIE = "cookie", e.DIGITAL_CARD_2 = "digital-card-2", e.DIGITAL_CARD = "digital-card", e.DOCUMENTS = "documents", e.DOOR = "door", e.ECO_CARD = "eco-card", e.ELECTRIC_PLUG = "electric-plug", e.EMAIL_SUCCESS = "email-success", e.EMAIL = "email", e.EXCLAMATION_MARK = "exclamation-mark", e.FLAG = "flag", e.FLOWER = "flower", e.GEAR = "gear", e.GLOBE = "globe", e.GRAPH = "graph", e.HEART_2 = "heart-2", e.HEART_3 = "heart-3", e.HEART_4 = "heart-4", e.HEART_5 = "heart-5", e.HEART = "heart", e.HOUSE = "house", e.ID_CARD = "id-card", e.INFINITE = "infinite", e.INVITE_LETTER = "invite-letter", e.JARS = "jars", e.KEY = "key", e.LIGHT_BULB = "light-bulb", e.LOCK = "lock", e.MAGNIFYING_GLASS = "magnifying-glass", e.MAP = "map", e.MARBLE_CARD_BUSINESS = "marble-card-business", e.MARBLE_CARD = "marble-card", e.MARBLE = "marble", e.MEGAPHONE = "megaphone", e.MULTI_CURRENCY = "multi-currency", e.ONE_INVITE_LETTER_OPENED = "one-invite-letter-opened", e.PALM_TREE = "palm-tree", e.PERCENTAGE = "percentage", e.PERSONAL_CARD = "personal-card", e.PHONES = "phones", e.PIE_CHART = "pie-chart", e.PLANE_2 = "plane-2", e.PLANE = "plane", e.PUZZLE_PIECES = "puzzle-pieces", e.QUESTION_MARK = "question-mark", e.RECEIVE = "receive", e.REMINDER_LETTER = "reminder-letter", e.SAND_TIMER = "sand-timer", e.SHOPPING_BAG = "shopping-bag", e.SKIP_AUTHENTICATION = "skip-authentication", e.SPEECH_BUBBLE = "speech-bubble", e.TOOL = "tool", e.TWO_INVITE_LETTERS_OPENED = "two-invite-letters-opened", e.WALLET = "wallet";
181
181
  })(Ti || (Ti = {}));
@@ -379,7 +379,7 @@ var require_main_min = __commonJS({
379
379
  } }).default;
380
380
  });
381
381
  });
382
- var Od = Ka((XO, zr) => {
382
+ var Od = Ka((QO, zr) => {
383
383
  "use strict";
384
384
  (function() {
385
385
  "use strict";
@@ -439,9 +439,9 @@ var require_main_min = __commonJS({
439
439
  } } }), t ? zr.exports = n : window.screenfull = n;
440
440
  })();
441
441
  });
442
- var vx = {};
443
- ug(vx, { DynamicFlow: () => xs, DynamicFlowRevamp: () => rg, JsonSchemaForm: () => vs, Layout: () => ke, convertStepToLayout: () => wr, inlineReferences: () => Mt, isValidSchema: () => ee, makeHttpClient: () => gn, translations: () => Bp });
444
- module2.exports = yg(vx);
442
+ var Ax = {};
443
+ ug(Ax, { DynamicFlow: () => xs, DynamicFlowRevamp: () => rg, JsonSchemaForm: () => vs, Layout: () => ke, convertStepToLayout: () => wr, inlineReferences: () => Mt, isValidSchema: () => ee, makeHttpClient: () => gn, translations: () => Bp });
444
+ module2.exports = yg(Ax);
445
445
  function wr(e, { displayStepTitle: t = true } = {}) {
446
446
  if (e.layout)
447
447
  return Mg(e, t);
@@ -958,7 +958,7 @@ var require_main_min = __commonJS({
958
958
  function gt(e) {
959
959
  return e.type === "object";
960
960
  }
961
- function ao(e) {
961
+ function no(e) {
962
962
  return rt(e) && e.oneOf.every((t) => t.type === "object");
963
963
  }
964
964
  function rt(e) {
@@ -994,7 +994,7 @@ var require_main_min = __commonJS({
994
994
  return e.type === "string" && e.format === "base64url";
995
995
  }
996
996
  var Wm = (e) => Rt(e) && ht(e) && eC(e.items);
997
- var io = (e) => Yg(e) ? "readOnly" : yn(e) ? "persistAsync" : ci(e) ? "validationAsync" : gt(e) ? "object" : Rt(e) ? "array" : Zg(e) ? "promotedOneOf" : rt(e) ? "oneOf" : li(e) ? "allOf" : kt(e) ? "basic" : null;
997
+ var ao = (e) => Yg(e) ? "readOnly" : yn(e) ? "persistAsync" : ci(e) ? "validationAsync" : gt(e) ? "object" : Rt(e) ? "array" : Zg(e) ? "promotedOneOf" : rt(e) ? "oneOf" : li(e) ? "allOf" : kt(e) ? "basic" : null;
998
998
  var _m = (e) => oC(e) && rC(e) && nC(e);
999
999
  var oC = (e) => !e.type || e.type === "form";
1000
1000
  var rC = (e) => {
@@ -1042,7 +1042,7 @@ var require_main_min = __commonJS({
1042
1042
  }, [e]), { requiresManualTrigger: !!(e && !t && !r), dismissConfirmation: a };
1043
1043
  }
1044
1044
  var Ir = require("react");
1045
- var so = require("react");
1045
+ var io = require("react");
1046
1046
  function Oo(e = "") {
1047
1047
  return !["https://", "http://", "data:"].some((t) => e.startsWith(t) && e.length > t.length);
1048
1048
  }
@@ -1061,19 +1061,19 @@ var require_main_min = __commonJS({
1061
1061
  return o;
1062
1062
  };
1063
1063
  var yi = require("react/jsx-runtime");
1064
- var Cn = (0, so.createContext)(void 0);
1064
+ var Cn = (0, io.createContext)(void 0);
1065
1065
  function Sn({ httpClient: e, children: t }) {
1066
1066
  return (0, yi.jsx)(Cn.Provider, { value: e, children: t });
1067
1067
  }
1068
1068
  function bn({ baseUrl: e, children: t }) {
1069
- let o = (0, so.useMemo)(() => gn(e), [e]);
1069
+ let o = (0, io.useMemo)(() => gn(e), [e]);
1070
1070
  return (0, yi.jsx)(Cn.Provider, { value: o, children: t });
1071
1071
  }
1072
1072
  var Se = () => {
1073
- let e = (0, so.useContext)(Cn);
1073
+ let e = (0, io.useContext)(Cn);
1074
1074
  return e != null ? e : fetch;
1075
1075
  };
1076
- var Qm = () => !!(0, so.useContext)(Cn);
1076
+ var Qm = () => !!(0, io.useContext)(Cn);
1077
1077
  function el(e, t) {
1078
1078
  let o = Se(), r = (0, Ir.useMemo)(() => {
1079
1079
  if (e)
@@ -1111,8 +1111,8 @@ var require_main_min = __commonJS({
1111
1111
  var bd = require("react");
1112
1112
  var wd = require("react-intl");
1113
1113
  var tl = require("react-intl");
1114
- var ve = (0, tl.defineMessages)({ genericErrorRetryHint: { id: "dynamicFlows.PersistAsyncSchema.genericError", defaultMessage: "Something went wrong, please try again.", description: "Generic error message for persist async schema" }, genericError: { id: "dynamicFlows.ErrorBoundary.errorAlert", defaultMessage: "Something went wrong.", description: "Generic error message for when something has gone wrong." }, retry: { id: "dynamicFlows.ErrorBoundary.retry", defaultMessage: "Retry", description: "Usually this follows the generic error and contains a link." } });
1115
- var bo = require("react");
1114
+ var xe = (0, tl.defineMessages)({ genericErrorRetryHint: { id: "dynamicFlows.PersistAsyncSchema.genericError", defaultMessage: "Something went wrong, please try again.", description: "Generic error message for persist async schema" }, genericError: { id: "dynamicFlows.ErrorBoundary.errorAlert", defaultMessage: "Something went wrong.", description: "Generic error message for when something has gone wrong." }, retry: { id: "dynamicFlows.ErrorBoundary.retry", defaultMessage: "Retry", description: "Usually this follows the generic error and contains a link." } });
1115
+ var So = require("react");
1116
1116
  var fd = require("react-intl");
1117
1117
  var ol = { DAY_MONTH_YEAR: "day-month-year", MONTH_YEAR: "month-year" };
1118
1118
  var j = { RADIO: "radio", CHECKBOX: "checkbox", SELECT: "select", EMAIL: "email", FILE: "file", DATE: "date", DATETIME: "date-time", DATELOOKUP: "date-lookup", TEL: "tel", NUMERIC: "numeric", NUMBER: "number", HIDDEN: "hidden", PASSWORD: "password", TEXT: "text", TEXTAREA: "textarea", UPLOAD: "upload", TAB: "tab" };
@@ -1157,7 +1157,7 @@ var require_main_min = __commonJS({
1157
1157
  }
1158
1158
  var Gt = fC;
1159
1159
  var Ar = require("react/jsx-runtime");
1160
- var mo = ({ icon: e, image: t }) => {
1160
+ var so = ({ icon: e, image: t }) => {
1161
1161
  if (e != null && e.name)
1162
1162
  return (0, Ar.jsx)(Lo.Avatar, { type: Lo.AvatarType.ICON, children: (0, Ar.jsx)(Gt, { type: e.name }) });
1163
1163
  if (e != null && e.text)
@@ -1218,10 +1218,10 @@ var require_main_min = __commonJS({
1218
1218
  };
1219
1219
  var SC = (e) => !e || !["neutral", "warning", "negative", "positive"].includes(e) ? "neutral" : e;
1220
1220
  var Ee = gC;
1221
- var lo = require("react/jsx-runtime");
1221
+ var mo = require("react/jsx-runtime");
1222
1222
  var bC = (e) => {
1223
1223
  let t = e.component, o = _(t.margin || t.border ? "lg" : "xs");
1224
- return !t.width || t.width === "xl" ? (0, lo.jsx)("div", { className: o + ul(t.border), children: (0, lo.jsx)(ke, { components: t.components, model: e.model, submitted: e.submitted, errors: e.errors, onModelChange: e.onModelChange, onAction: e.onAction, onPersistAsync: e.onPersistAsync }) }) : (0, lo.jsx)("div", { className: "row", children: (0, lo.jsx)("div", { className: o + wC(t), children: (0, lo.jsx)("div", { className: ul(t.border), children: (0, lo.jsx)(ke, { components: t.components, model: e.model, submitted: e.submitted, errors: e.errors, onModelChange: e.onModelChange, onAction: e.onAction, onPersistAsync: e.onPersistAsync }) }) }) });
1224
+ return !t.width || t.width === "xl" ? (0, mo.jsx)("div", { className: o + ul(t.border), children: (0, mo.jsx)(ke, { components: t.components, model: e.model, submitted: e.submitted, errors: e.errors, onModelChange: e.onModelChange, onAction: e.onAction, onPersistAsync: e.onPersistAsync }) }) : (0, mo.jsx)("div", { className: "row", children: (0, mo.jsx)("div", { className: o + wC(t), children: (0, mo.jsx)("div", { className: ul(t.border), children: (0, mo.jsx)(ke, { components: t.components, model: e.model, submitted: e.submitted, errors: e.errors, onModelChange: e.onModelChange, onAction: e.onAction, onPersistAsync: e.onPersistAsync }) }) }) });
1225
1225
  };
1226
1226
  var ul = (e) => e ? " well p-b-0" : "";
1227
1227
  var wC = (e) => {
@@ -1275,10 +1275,10 @@ var require_main_min = __commonJS({
1275
1275
  return (0, Cl.jsx)(gl.Button, { size: hl(t.size), type: a === "tertiary" ? void 0 : n, priority: a, block: true, className: m, disabled: i || t.disabled || r.disabled, onClick: () => o(r), children: (l = t.title) != null ? l : r.title });
1276
1276
  }
1277
1277
  var Ci = PC;
1278
- var co = require("react/jsx-runtime");
1278
+ var lo = require("react/jsx-runtime");
1279
1279
  var IC = (e) => {
1280
1280
  let t = e.component, { leftWidth: o, rightWidth: r } = AC(t.bias);
1281
- return (0, co.jsxs)("div", { className: `${_(t.margin || "xs")} row`, children: [(0, co.jsx)("div", { className: `${o} m-b-0`, children: (0, co.jsx)(ke, { components: t.left, model: e.model, submitted: e.submitted, errors: e.errors, onModelChange: e.onModelChange, onAction: e.onAction, onPersistAsync: e.onPersistAsync }) }), (0, co.jsx)("div", { className: `${r} m-b-0`, children: (0, co.jsx)(ke, { components: t.right, model: e.model, submitted: e.submitted, errors: e.errors, onModelChange: e.onModelChange, onAction: e.onAction, onPersistAsync: e.onPersistAsync }) })] });
1281
+ return (0, lo.jsxs)("div", { className: `${_(t.margin || "xs")} row`, children: [(0, lo.jsx)("div", { className: `${o} m-b-0`, children: (0, lo.jsx)(ke, { components: t.left, model: e.model, submitted: e.submitted, errors: e.errors, onModelChange: e.onModelChange, onAction: e.onAction, onPersistAsync: e.onPersistAsync }) }), (0, lo.jsx)("div", { className: `${r} m-b-0`, children: (0, lo.jsx)(ke, { components: t.right, model: e.model, submitted: e.submitted, errors: e.errors, onModelChange: e.onModelChange, onAction: e.onAction, onPersistAsync: e.onPersistAsync }) })] });
1282
1282
  };
1283
1283
  var AC = (e) => e === "left" ? { leftWidth: "col-md-8", rightWidth: "col-md-4" } : e === "right" ? { leftWidth: "col-md-4", rightWidth: "col-md-8" } : { leftWidth: "col-md-6", rightWidth: "col-md-6" };
1284
1284
  var Si = IC;
@@ -1286,7 +1286,7 @@ var require_main_min = __commonJS({
1286
1286
  var vn = require("react/jsx-runtime");
1287
1287
  function MC({ component: e, onAction: t }) {
1288
1288
  let { loading: o } = vo();
1289
- return (0, vn.jsx)("div", { className: _(e.margin), children: (0, vn.jsx)(Pn.NavigationOptionsList, { children: e.options.map((r) => (0, vn.jsx)(Pn.NavigationOption, { title: r.title, content: r.description, disabled: o || r.disabled, media: mo(r), showMediaCircle: false, showMediaAtAllSizes: true, onClick: () => t(r.action) }, JSON.stringify(r))) }) });
1289
+ return (0, vn.jsx)("div", { className: _(e.margin), children: (0, vn.jsx)(Pn.NavigationOptionsList, { children: e.options.map((r) => (0, vn.jsx)(Pn.NavigationOption, { title: r.title, content: r.description, disabled: o || r.disabled, media: so(r), showMediaCircle: false, showMediaAtAllSizes: true, onClick: () => t(r.action) }, JSON.stringify(r))) }) });
1290
1290
  }
1291
1291
  var bi = MC;
1292
1292
  var Sl = require("react/jsx-runtime");
@@ -1383,7 +1383,7 @@ var require_main_min = __commonJS({
1383
1383
  let { formatMessage: o } = (0, Nl.useIntl)(), { maxFileSizeError: r, maxItemsError: n, minItemsError: a } = Mr;
1384
1384
  return { maxFileSizeErrorMessage: o(r), maxItemsErrorMessage: o(n, { maxItems: e }), minItemsErrorMessage: o(a, { minItems: t }), requiredMessage: o(Dl.required) };
1385
1385
  }
1386
- var po = require("react/jsx-runtime");
1386
+ var co = require("react/jsx-runtime");
1387
1387
  function zl(e) {
1388
1388
  var R, A;
1389
1389
  let { onChange: t, schema: o } = e, r = Ce(), n = Mn(o), a = (0, Rr.useMemo)(() => o.$id || We(), [o.$id]), [i, m] = (0, Rr.useState)(false), [l, c] = (0, Rr.useState)(() => DC(e.model || [])), p = jl(o.items.persistAsync), y = o.items.persistAsync.schema, f = ko(y), u = async (O) => {
@@ -1405,7 +1405,7 @@ var require_main_min = __commonJS({
1405
1405
  t({ model: L, triggerSchema: o, triggerModel: L });
1406
1406
  }
1407
1407
  let h = Bl(l).map((O) => O.id), S = Ro(h, o, e.required), b = !!e.errors || (i || e.submitted) && !!S.length, w = "accepts" in y && y.accepts, F = "maxSize" in y && y.maxSize, x = C(s(s({ multiple: true, className: "form-control", files: l, fileInputName: a, id: a }, w ? { fileTypes: w } : void 0), F ? { sizeLimit: un(F) } : void 0), { sizeLimitErrorMessage: ((R = y.validationMessages) == null ? void 0 : R.maxSize) || n.maxFileSizeErrorMessage, maxFiles: e.schema.maxItems, maxFilesErrorMessage: ((A = e.schema.validationMessages) == null ? void 0 : A.maxItems) || n.maxItemsErrorMessage, uploadButtonTitle: y.title, description: y.description, disabled: e.disabled, onUploadFile: (O) => u(O.get(a)), onFilesChange: d, onDeleteFile: () => Promise.resolve() }), P = `${a}-feedback`;
1408
- return (0, po.jsxs)("div", { className: (0, Ul.default)("form-group", { "has-error": b }), children: [(0, po.jsx)("label", { className: "d-block control-label", htmlFor: a, children: e.schema.title }), (0, po.jsx)("div", { "aria-describedby": P, children: (0, po.jsx)(Rn.UploadInput, s({}, x)) }), (0, po.jsx)(it, { id: P, changed: i, submitted: e.submitted, errors: e.errors, schema: e.schema, validations: S, validationMessages: NC(o, !!e.required, n), infoMessage: null, focused: false, blurred: true })] });
1408
+ return (0, co.jsxs)("div", { className: (0, Ul.default)("form-group", { "has-error": b }), children: [(0, co.jsx)("label", { className: "d-block control-label", htmlFor: a, children: e.schema.title }), (0, co.jsx)("div", { "aria-describedby": P, children: (0, co.jsx)(Rn.UploadInput, s({}, x)) }), (0, co.jsx)(it, { id: P, changed: i, submitted: e.submitted, errors: e.errors, schema: e.schema, validations: S, validationMessages: NC(o, !!e.required, n), infoMessage: null, focused: false, blurred: true })] });
1409
1409
  }
1410
1410
  zl.defaultProps = { errors: null, required: false };
1411
1411
  var Pi = zl;
@@ -1424,12 +1424,12 @@ var require_main_min = __commonJS({
1424
1424
  }
1425
1425
  var No = require("@transferwise/components");
1426
1426
  var Yl = require("@transferwise/icons");
1427
- var uo = require("react");
1427
+ var po = require("react");
1428
1428
  var Zl = require("react-intl");
1429
1429
  var Hl = require("@transferwise/components");
1430
1430
  var $l = require("react/jsx-runtime");
1431
1431
  function ql({ item: e, onClick: t }) {
1432
- return (0, $l.jsx)(Hl.NavigationOption, { media: mo(e), title: e.title, content: e.description, showMediaAtAllSizes: true, onClick: t });
1432
+ return (0, $l.jsx)(Hl.NavigationOption, { media: so(e), title: e.title, content: e.description, showMediaAtAllSizes: true, onClick: t });
1433
1433
  }
1434
1434
  var Gl = require("react-intl");
1435
1435
  var _e = (0, Gl.defineMessages)({ addItemTitle: { id: "dynamicFlows.ArraySchema.addItemTitle", defaultMessage: "Add Item", description: "Label on the button used to open a form to add an item" }, addItem: { id: "dynamicFlows.ArraySchema.addItem", defaultMessage: "Save", description: "Label on the add button used to submit a form that adds an item" }, editItem: { id: "dynamicFlows.ArraySchema.editItem", defaultMessage: "Save", description: "Label on the edit button used to submit a form that edits an item" }, removeItem: { id: "dynamicFlows.ArraySchema.removeItem", defaultMessage: "Remove", description: "Label on the remove button used to confirm deletion of an item" } });
@@ -1457,7 +1457,7 @@ var require_main_min = __commonJS({
1457
1457
  if (r >= 0)
1458
1458
  return r;
1459
1459
  }
1460
- return ao(e) && re(t) && Object.keys(t).length >= 1 ? Vo(e, t) : ao(e) && !ue(e.default) && re(e.default) && Object.keys(e.default).length >= 1 ? Vo(e, e.default) : null;
1460
+ return no(e) && re(t) && Object.keys(t).length >= 1 ? Vo(e, t) : no(e) && !ue(e.default) && re(e.default) && Object.keys(e.default).length >= 1 ? Vo(e, e.default) : null;
1461
1461
  };
1462
1462
  var kr = (e, t) => {
1463
1463
  let o = (r) => !ue(t) && ee(t, r);
@@ -1483,7 +1483,7 @@ var require_main_min = __commonJS({
1483
1483
  return { value: t, title: l || n, description: c || a, icon: p || i, image: y || m };
1484
1484
  };
1485
1485
  var _t = (e) => {
1486
- let { schema: t, model: o, providesProp: r, getValueFromSchema: n } = e, a = io(t);
1486
+ let { schema: t, model: o, providesProp: r, getValueFromSchema: n } = e, a = ao(t);
1487
1487
  if (qC(t.summary, r))
1488
1488
  return n(t, o);
1489
1489
  switch (a) {
@@ -1508,7 +1508,7 @@ var require_main_min = __commonJS({
1508
1508
  };
1509
1509
  var jC = (e) => {
1510
1510
  let { schema: t, model: o } = e;
1511
- if (ao(t)) {
1511
+ if (no(t)) {
1512
1512
  if (!re(o))
1513
1513
  return null;
1514
1514
  let a = Vo(t, o);
@@ -1535,11 +1535,11 @@ var require_main_min = __commonJS({
1535
1535
  var bt = require("react/jsx-runtime");
1536
1536
  function $C({ schema: e, model: t, errors: o, submitted: r, required: n = false, onChange: a }) {
1537
1537
  var O;
1538
- let [i, m] = (0, uo.useState)(null), [l, c] = (0, uo.useState)(false), [p, y] = (0, uo.useState)(() => {
1538
+ let [i, m] = (0, po.useState)(null), [l, c] = (0, po.useState)(false), [p, y] = (0, po.useState)(() => {
1539
1539
  if (N(t) && !W(t))
1540
1540
  throw new Error("RepeatableSchema does not support object models. Ensure your array schema is wrapped inside an object schema.");
1541
1541
  return t ? t.map((v) => Ii(e.items, v, e == null ? void 0 : e.summary)) : null;
1542
- }), [f, u] = (0, uo.useState)({ item: null, model: null }), d = (0, uo.useMemo)(() => e.$id || We(), [e.$id]), g = (v) => {
1542
+ }), [f, u] = (0, po.useState)({ item: null, model: null }), d = (0, po.useMemo)(() => e.$id || We(), [e.$id]), g = (v) => {
1543
1543
  let L = v ? v.map(({ value: k }) => k) : null;
1544
1544
  a({ model: L, triggerSchema: e.items, triggerModel: L });
1545
1545
  }, h = () => {
@@ -1632,13 +1632,13 @@ var require_main_min = __commonJS({
1632
1632
  let { coerceValue: o = false } = t;
1633
1633
  if (!T(e)) {
1634
1634
  if (N(e)) {
1635
- yo({ received: "object", expected: "string" });
1635
+ uo({ received: "object", expected: "string" });
1636
1636
  return;
1637
1637
  }
1638
1638
  if (!D(e)) {
1639
1639
  if (o)
1640
1640
  return Oi({ received: typeof e, expected: "string" }), String(e);
1641
- yo({ received: typeof e, expected: "string" });
1641
+ uo({ received: typeof e, expected: "string" });
1642
1642
  return;
1643
1643
  }
1644
1644
  return e;
@@ -1652,13 +1652,13 @@ var require_main_min = __commonJS({
1652
1652
  return e;
1653
1653
  let r = { received: typeof e, expected: "string or number" };
1654
1654
  if (N(e)) {
1655
- yo(r);
1655
+ uo(r);
1656
1656
  return;
1657
1657
  }
1658
1658
  if (!D(e)) {
1659
1659
  if (o)
1660
1660
  return Oi(r), String(e);
1661
- yo(r);
1661
+ uo(r);
1662
1662
  return;
1663
1663
  }
1664
1664
  return e;
@@ -1670,7 +1670,7 @@ var require_main_min = __commonJS({
1670
1670
  if (!ft(e)) {
1671
1671
  if (o)
1672
1672
  return Oi({ received: typeof e, expected: "boolean" }), !!e;
1673
- yo({ received: typeof e, expected: "boolean" });
1673
+ uo({ received: typeof e, expected: "boolean" });
1674
1674
  return;
1675
1675
  }
1676
1676
  return e;
@@ -1678,7 +1678,7 @@ var require_main_min = __commonJS({
1678
1678
  var dc = (e) => {
1679
1679
  if (!T(e)) {
1680
1680
  if (!(e instanceof Date) && !D(e)) {
1681
- yo({ received: typeof e, expected: "string or Date" });
1681
+ uo({ received: typeof e, expected: "string or Date" });
1682
1682
  return;
1683
1683
  }
1684
1684
  return e;
@@ -1688,14 +1688,14 @@ var require_main_min = __commonJS({
1688
1688
  if (T(e))
1689
1689
  return null;
1690
1690
  if (!D(e))
1691
- return yo({ received: typeof e, expected: "string", fallback: "null" }), null;
1691
+ return uo({ received: typeof e, expected: "string", fallback: "null" }), null;
1692
1692
  let t = zm(e);
1693
1693
  return t === null && console.warn("Incorrectly formatted date string. Falling back to null."), t;
1694
1694
  };
1695
1695
  var Oi = ({ received: e, expected: t }) => {
1696
1696
  console.warn(`Value with type ${e} passed to control that only accepts type ${t}. Type will be coerced, but this behaviour will change in the future, so please fix your code.`);
1697
1697
  };
1698
- var yo = ({ received: e, expected: t, fallback: o = "undefined" }) => {
1698
+ var uo = ({ received: e, expected: t, fallback: o = "undefined" }) => {
1699
1699
  console.warn(`Value with type ${e} passed to control that only accepts type ${t}. Falling back to ${o}`);
1700
1700
  };
1701
1701
  var Ei = (e) => {
@@ -1811,8 +1811,8 @@ var require_main_min = __commonJS({
1811
1811
  var Kt = require("@transferwise/components");
1812
1812
  Cc();
1813
1813
  Li();
1814
- var OA = require("react");
1815
- var EA = require("react/jsx-runtime");
1814
+ var TA = require("react");
1815
+ var DA = require("react/jsx-runtime");
1816
1816
  var Je = require("react/jsx-runtime");
1817
1817
  var Sc = (e, t) => {
1818
1818
  switch (t) {
@@ -1917,7 +1917,7 @@ var require_main_min = __commonJS({
1917
1917
  Pc.defaultProps = { required: false, disabled: false };
1918
1918
  var Bi = Pc;
1919
1919
  var Rc = pe(Re());
1920
- var ho = require("react");
1920
+ var fo = require("react");
1921
1921
  var Nn = require("@transferwise/components");
1922
1922
  var Ic = require("react");
1923
1923
  var Mc = require("react/jsx-runtime");
@@ -1927,8 +1927,8 @@ var require_main_min = __commonJS({
1927
1927
  }
1928
1928
  var jo = require("react/jsx-runtime");
1929
1929
  function kc(e) {
1930
- let { model: t, schema: o, submitted: r, required: n, errors: a, onChange: i } = e, [m, l] = (0, ho.useState)({}), [c, p] = (0, ho.useState)(null), [y, f] = (0, ho.useState)([]), [u, d] = (0, ho.useState)(false), g = Se(), h = Ce();
1931
- (0, ho.useEffect)(() => {
1930
+ let { model: t, schema: o, submitted: r, required: n, errors: a, onChange: i } = e, [m, l] = (0, fo.useState)({}), [c, p] = (0, fo.useState)(null), [y, f] = (0, fo.useState)([]), [u, d] = (0, fo.useState)(false), g = Se(), h = Ce();
1931
+ (0, fo.useEffect)(() => {
1932
1932
  f(r ? Ct(t, o, !!n) : []);
1933
1933
  }, [t, o, r, n]);
1934
1934
  let S = async (v, L) => {
@@ -2055,7 +2055,7 @@ var require_main_min = __commonJS({
2055
2055
  let v = new AbortController();
2056
2056
  return S(v), v.signal;
2057
2057
  };
2058
- return (0, Wc.jsx)(go, s({}, { submitted: n || d, model: m, errors: f || a, infoMessage: p, onChange: (v) => {
2058
+ return (0, Wc.jsx)(ho, s({}, { submitted: n || d, model: m, errors: f || a, infoMessage: p, onChange: (v) => {
2059
2059
  i(C(s({}, v), { triggerSchema: t, triggerModel: v.model })), u(null), y(null), l(v.model);
2060
2060
  }, onBlur: () => {
2061
2061
  !T(m) && !Ge(m, c.current) && ee(m, t) && x(m, t.validationAsync);
@@ -2066,7 +2066,7 @@ var require_main_min = __commonJS({
2066
2066
  var Xe = require("react/jsx-runtime");
2067
2067
  var Kc = require("react");
2068
2068
  function FS(e) {
2069
- let { schema: t, model: o = null, errors: r = null, hideTitle: n = false, disabled: a = false } = e, i = C(s({}, e), { model: o, errors: r, hideTitle: n, disabled: a }), m = io(t), l = Ao();
2069
+ let { schema: t, model: o = null, errors: r = null, hideTitle: n = false, disabled: a = false } = e, i = C(s({}, e), { model: o, errors: r, hideTitle: n, disabled: a }), m = ao(t), l = Ao();
2070
2070
  switch ((0, _c.useEffect)(() => {
2071
2071
  xS(t, o, r) || l.error("Invalid schema or model", `Schema of type ${m || "undefined"} requested, but schema did not pass validation.`);
2072
2072
  }, [JSON.stringify(t), JSON.stringify(o), JSON.stringify(r), m, l]), m) {
@@ -2078,7 +2078,7 @@ var require_main_min = __commonJS({
2078
2078
  return (0, Xe.jsx)(Ki, s({}, i));
2079
2079
  case "basic": {
2080
2080
  let c = s({ infoMessage: null }, i);
2081
- return (0, Xe.jsx)(go, s({}, c));
2081
+ return (0, Xe.jsx)(ho, s({}, c));
2082
2082
  }
2083
2083
  case "object":
2084
2084
  return (0, Kc.createElement)(Or, C(s({}, i), { key: JSON.stringify(t) }));
@@ -2095,7 +2095,7 @@ var require_main_min = __commonJS({
2095
2095
  }
2096
2096
  var Be = FS;
2097
2097
  var xS = (e, t, o) => {
2098
- switch (io(e)) {
2098
+ switch (ao(e)) {
2099
2099
  case "persistAsync":
2100
2100
  return yn(e) && hn(t) && vr(o);
2101
2101
  case "validationAsync":
@@ -2107,7 +2107,7 @@ var require_main_min = __commonJS({
2107
2107
  case "array":
2108
2108
  return Rt(e) && Km(t) && vr(o);
2109
2109
  case "promotedOneOf":
2110
- return ao(e) && di(t);
2110
+ return no(e) && di(t);
2111
2111
  case "oneOf":
2112
2112
  return rt(e);
2113
2113
  case "allOf":
@@ -2319,15 +2319,15 @@ var require_main_min = __commonJS({
2319
2319
  var id = ({ title: e, value: t, onFocus: o, onChange: r }) => (0, $n.jsxs)("label", { className: "control-label d-inline", children: [e, (0, $n.jsx)(ad.Input, { type: "text", value: t, className: "m-t-1", onFocus: o, onChange: (n) => r(n.currentTarget.value) })] });
2320
2320
  var Gn = require("@transferwise/components");
2321
2321
  var sd = require("react-intl");
2322
- var Co = require("react/jsx-runtime");
2322
+ var go = require("react/jsx-runtime");
2323
2323
  function md({ results: e, emptyMessage: t, onSelect: o }) {
2324
- return e.length === 0 ? (0, Co.jsx)("p", { className: "m-t-2", children: t }) : (0, Co.jsx)(Gn.NavigationOptionsList, { children: e.map((r) => (0, Co.jsx)(Gn.NavigationOption, { title: r.title, content: r.description, media: mo(r), showMediaCircle: false, showMediaAtAllSizes: true, onClick: () => o(r) }, JSON.stringify(r))) });
2324
+ return e.length === 0 ? (0, go.jsx)("p", { className: "m-t-2", children: t }) : (0, go.jsx)(Gn.NavigationOptionsList, { children: e.map((r) => (0, go.jsx)(Gn.NavigationOption, { title: r.title, content: r.description, media: so(r), showMediaCircle: false, showMediaAtAllSizes: true, onClick: () => o(r) }, JSON.stringify(r))) });
2325
2325
  }
2326
2326
  function ld({ onRetrySearch: e }) {
2327
2327
  let t = (0, sd.useIntl)();
2328
- return (0, Co.jsxs)("p", { className: "m-t-2", children: [t.formatMessage(ve.genericError), "\xA0", (0, Co.jsx)("a", { href: "/", onClick: (o) => {
2328
+ return (0, go.jsxs)("p", { className: "m-t-2", children: [t.formatMessage(xe.genericError), "\xA0", (0, go.jsx)("a", { href: "/", onClick: (o) => {
2329
2329
  o.preventDefault(), e();
2330
- }, children: t.formatMessage(ve.retry) })] });
2330
+ }, children: t.formatMessage(xe.retry) })] });
2331
2331
  }
2332
2332
  var Wo = require("react");
2333
2333
  var cd = { "Content-Type": "application/json" };
@@ -2367,7 +2367,7 @@ var require_main_min = __commonJS({
2367
2367
  let [r, n] = e.split("?"), a = new URLSearchParams(n);
2368
2368
  return a.set(t, o), `${r}?${a.toString()}`;
2369
2369
  };
2370
- var So = require("react/jsx-runtime");
2370
+ var Co = require("react/jsx-runtime");
2371
2371
  var QS = 400;
2372
2372
  function eb({ component: e, onAction: t }) {
2373
2373
  let [o, r] = (0, Wn.useState)(""), { title: n, margin: a, url: i, method: m, param: l, emptyMessage: c } = e, { status: p, results: y, search: f } = dd({ url: i, method: m, param: l }), u = Ce(), d = (0, Wn.useMemo)(() => $t(f, QS), [f]), g = () => {
@@ -2383,7 +2383,7 @@ var require_main_min = __commonJS({
2383
2383
  }, b = () => {
2384
2384
  r(o), f(o);
2385
2385
  };
2386
- return (0, So.jsxs)("div", { className: _(a || "md"), children: [(0, So.jsx)(id, { title: n, value: o, onChange: h, onFocus: g }), p === "loading" && (0, So.jsx)(Vr, { component: { type: "loading-indicator", size: "sm" } }), p === "error" && (0, So.jsx)(ld, { onRetrySearch: b }), p === "success" && (0, So.jsx)(md, { results: y, emptyMessage: c, onSelect: S })] });
2386
+ return (0, Co.jsxs)("div", { className: _(a || "md"), children: [(0, Co.jsx)(id, { title: n, value: o, onChange: h, onFocus: g }), p === "loading" && (0, Co.jsx)(Vr, { component: { type: "loading-indicator", size: "sm" } }), p === "error" && (0, Co.jsx)(ld, { onRetrySearch: b }), p === "success" && (0, Co.jsx)(md, { results: y, emptyMessage: c, onSelect: S })] });
2387
2387
  }
2388
2388
  var ss = eb;
2389
2389
  var _n = require("@transferwise/components");
@@ -2426,7 +2426,7 @@ var require_main_min = __commonJS({
2426
2426
  return R ? null : (0, je.jsxs)(je.Fragment, { children: [e.schema.alert && (0, je.jsx)(Ee, { component: e.schema.alert }), (0, je.jsxs)("div", { className: (0, ud.default)(A), children: [O && (0, je.jsxs)("div", { className: "d-inline-block m-b-1", children: [(0, je.jsx)("label", { className: "control-label d-inline", htmlFor: w, children: e.schema.title }), !!v && (0, je.jsx)(Et, { help: v })] }), !O && !!v && (0, je.jsx)(Et, { help: v }), (0, je.jsx)(Er, { id: w, schema: e.schema, value: m, disabled: !!e.disabled, onChange: t, onFocus: a, onBlur: i, describedBy: L }), (0, je.jsx)(it, { id: L, changed: y, focused: u, blurred: g, submitted: e.submitted, errors: (U = e.errors) != null ? U : null, schema: e.schema, validations: S, infoMessage: e.infoMessage })] })] });
2427
2427
  };
2428
2428
  yd.defaultProps = { required: false, disabled: false, onBlur: null };
2429
- var go = yd;
2429
+ var ho = yd;
2430
2430
  var Cd = require("react/jsx-runtime");
2431
2431
  var ji = (e, t) => t[e];
2432
2432
  var hd = (e, t) => {
@@ -2435,11 +2435,11 @@ var require_main_min = __commonJS({
2435
2435
  };
2436
2436
  var rb = /* @__PURE__ */ new Set([j.RADIO, j.SELECT, j.DATELOOKUP, j.FILE, j.UPLOAD]);
2437
2437
  function gd(e) {
2438
- let { schema: t, required: o, submitted: r, errors: n, onChange: a, onPersistAsync: i } = e, m = (0, fd.useIntl)(), l = Se(), c = Ce(), [p, y] = (0, bo.useState)(null), f = Sd(p), [u, d] = (0, bo.useState)(null), [g, h] = (0, bo.useState)(false), [S, b] = (0, bo.useState)(null);
2439
- (0, bo.useEffect)(() => {
2438
+ let { schema: t, required: o, submitted: r, errors: n, onChange: a, onPersistAsync: i } = e, m = (0, fd.useIntl)(), l = Se(), c = Ce(), [p, y] = (0, So.useState)(null), f = Sd(p), [u, d] = (0, So.useState)(null), [g, h] = (0, So.useState)(false), [S, b] = (0, So.useState)(null);
2439
+ (0, So.useEffect)(() => {
2440
2440
  rb.has(Ni(t.persistAsync.schema)) && P();
2441
2441
  }, [p]);
2442
- let w = () => d(m.formatMessage(ve.genericErrorRetryHint)), F = async (O, v) => {
2442
+ let w = () => d(m.formatMessage(xe.genericErrorRetryHint)), F = async (O, v) => {
2443
2443
  let L = x(), k = { [v.param]: O };
2444
2444
  h(true);
2445
2445
  try {
@@ -2473,7 +2473,7 @@ var require_main_min = __commonJS({
2473
2473
  }, A = ({ model: O }) => {
2474
2474
  d(null), ee(O, t.persistAsync.schema) && y(O);
2475
2475
  };
2476
- return (0, Cd.jsx)(go, { required: o, submitted: r || g, schema: t.persistAsync.schema, errors: u || n, model: null, infoMessage: null, onChange: A, onBlur: R });
2476
+ return (0, Cd.jsx)(ho, { required: o, submitted: r || g, schema: t.persistAsync.schema, errors: u || n, model: null, infoMessage: null, onChange: A, onBlur: R });
2477
2477
  }
2478
2478
  gd.defaultProps = { required: false };
2479
2479
  var Ui = gd;
@@ -2517,10 +2517,10 @@ var require_main_min = __commonJS({
2517
2517
  throw new Error(d);
2518
2518
  }
2519
2519
  }
2520
- throw new Error(n.formatMessage(ve.genericErrorRetryHint));
2520
+ throw new Error(n.formatMessage(xe.genericErrorRetryHint));
2521
2521
  }
2522
2522
  let y = (f) => {
2523
- let u = ab(f) ? f.message : n.formatMessage(ve.genericErrorRetryHint);
2523
+ let u = ab(f) ? f.message : n.formatMessage(xe.genericErrorRetryHint);
2524
2524
  throw new Error(u);
2525
2525
  };
2526
2526
  return i;
@@ -2895,7 +2895,7 @@ var require_main_min = __commonJS({
2895
2895
  m(r, n, a), (!i || !Rb(i)) && m.flush();
2896
2896
  };
2897
2897
  }
2898
- var Rb = (e) => io(e) === "basic" && e.type !== "boolean" && e.format !== "base64url";
2898
+ var Rb = (e) => ao(e) === "basic" && e.type !== "boolean" && e.format !== "base64url";
2899
2899
  var Xo = require("react");
2900
2900
  var ip = (e) => {
2901
2901
  var u, d;
@@ -2953,7 +2953,7 @@ var require_main_min = __commonJS({
2953
2953
  var up = require("react/jsx-runtime");
2954
2954
  function pp({ onDismiss: e }) {
2955
2955
  let { formatMessage: t } = (0, dp.useIntl)();
2956
- return (0, up.jsx)(aa.Alert, { action: { text: t(ve.retry), href: window.location.href }, message: t(ve.genericError), type: aa.Sentiment.NEGATIVE, className: "m-b-3", onDismiss: e });
2956
+ return (0, up.jsx)(aa.Alert, { action: { text: t(xe.retry), href: window.location.href }, message: t(xe.genericError), type: aa.Sentiment.NEGATIVE, className: "m-b-3", onDismiss: e });
2957
2957
  }
2958
2958
  var Yo = require("react/jsx-runtime");
2959
2959
  var Lb = () => {
@@ -3057,8 +3057,8 @@ var require_main_min = __commonJS({
3057
3057
  var I;
3058
3058
  return s({ flowId: e, stepId: (d == null ? void 0 : d.id) || (d == null ? void 0 : d.key) }, (I = d == null ? void 0 : d.analytics) != null ? I : {});
3059
3059
  }, [e, d]), M = (0, pt.useMemo)(() => Qa(c, U), [c, U]), z = (0, pt.useCallback)(({ action: I, data: Y, etag: B }) => {
3060
- let { url: ge, method: no = "POST" } = I;
3061
- return t(ge != null ? ge : "", { method: no, headers: s({ "accept-language": y, "Content-Type": "application/json" }, B ? { "If-None-Match": B } : {}), credentials: "include", body: no === "GET" ? void 0 : JSON.stringify(Y) });
3060
+ let { url: ge, method: ro = "POST" } = I;
3061
+ return t(ge != null ? ge : "", { method: ro, headers: s({ "accept-language": y, "Content-Type": "application/json" }, B ? { "If-None-Match": B } : {}), credentials: "include", body: ro === "GET" ? void 0 : JSON.stringify(Y) });
3062
3062
  }, [t, y]), V = async (I, Y = {}) => {
3063
3063
  v(d ? "submission" : "initial"), M("Dynamic Flow - Step Submitted", { actionId: I.id || I.$id });
3064
3064
  try {
@@ -3125,7 +3125,7 @@ var require_main_min = __commonJS({
3125
3125
  }, ag = (I, Y) => {
3126
3126
  let { triggerSchema: B } = I;
3127
3127
  if (Ub(I)) {
3128
- let ge = B.refreshUrl || B.refreshFormUrl, no = (d == null ? void 0 : d.refreshUrl) || (d == null ? void 0 : d.refreshFormUrl), on = ge || no;
3128
+ let ge = B.refreshUrl || B.refreshFormUrl, ro = (d == null ? void 0 : d.refreshUrl) || (d == null ? void 0 : d.refreshFormUrl), on = ge || ro;
3129
3129
  on && de(on, ia(Y), h, B);
3130
3130
  }
3131
3131
  }, ig = async (I) => {
@@ -3135,8 +3135,8 @@ var require_main_min = __commonJS({
3135
3135
  yt(I.result);
3136
3136
  return;
3137
3137
  }
3138
- let { data: Y, method: B, skipValidation: ge } = I, no = s(s({}, ia(g)), Y);
3139
- Bb(B) ? (b(null), ge || R(true), (S || ge) && await V(I, no)) : await V(I);
3138
+ let { data: Y, method: B, skipValidation: ge } = I, ro = s(s({}, ia(g)), Y);
3139
+ Bb(B) ? (b(null), ge || R(true), (S || ge) && await V(I, ro)) : await V(I);
3140
3140
  };
3141
3141
  return (0, Dt.jsx)(ln, { flowId: e, stepId: (d == null ? void 0 : d.id) || (d == null ? void 0 : d.key), onLog: p, children: (0, Dt.jsx)(mn, { metadata: U, onEvent: c, children: (0, Dt.jsx)(ym, { loading: A, children: (0, Dt.jsx)(Sn, { httpClient: t, children: (0, Dt.jsx)(bm, { features: i, children: O !== null ? O : (0, Dt.jsx)(kn, { step: d, model: ia(g), submitted: P, globalError: u, formErrors: f, stepLayoutOptions: { displayStepTitle: a }, onAction: (I) => {
3142
3142
  ig(I);
@@ -3208,7 +3208,7 @@ var require_main_min = __commonJS({
3208
3208
  return "";
3209
3209
  }
3210
3210
  };
3211
- var wo = (e) => `${nw(e.align)} ${H(e.margin)}`;
3211
+ var bo = (e) => `${nw(e.align)} ${H(e.margin)}`;
3212
3212
  var jp = require("react/jsx-runtime");
3213
3213
  var aw = { canRenderType: "alert", render: ({ context: e, markdown: t, margin: o }) => (0, jp.jsx)(Up.Alert, { type: e, className: H(o), message: t }) };
3214
3214
  var zp = aw;
@@ -3420,7 +3420,7 @@ var require_main_min = __commonJS({
3420
3420
  var vt = require("react/jsx-runtime");
3421
3421
  var Uw = { canRenderType: "heading", render: (e) => (0, vt.jsx)(zw, s({}, e)) };
3422
3422
  function zw(e) {
3423
- let { text: t, size: o, align: r, margin: n, control: a } = e, i = wo({ align: r, margin: n });
3423
+ let { text: t, size: o, align: r, margin: n, control: a } = e, i = bo({ align: r, margin: n });
3424
3424
  return a === "display" ? (0, vt.jsx)(jw, { size: o, text: t, className: i }) : (0, vt.jsx)(Hw, { size: o, text: t, className: i });
3425
3425
  }
3426
3426
  function jw({ size: e, text: t, className: o }) {
@@ -3510,7 +3510,7 @@ var require_main_min = __commonJS({
3510
3510
  var Mu = Zw;
3511
3511
  var ku = require("@transferwise/components");
3512
3512
  var zs = require("react/jsx-runtime");
3513
- var Qw = { canRenderType: "markdown", render: ({ content: e, align: t, margin: o }) => (0, zs.jsx)("div", { className: wo({ align: t, margin: o }), children: (0, zs.jsx)(ku.Markdown, { config: { link: { target: "_blank" } }, children: e }) }) };
3513
+ var Qw = { canRenderType: "markdown", render: ({ content: e, align: t, margin: o }) => (0, zs.jsx)("div", { className: bo({ align: t, margin: o }), children: (0, zs.jsx)(ku.Markdown, { config: { link: { target: "_blank" } }, children: e }) }) };
3514
3514
  var Ou = Qw;
3515
3515
  var ba = require("@transferwise/components");
3516
3516
  var Eu = require("react");
@@ -3582,7 +3582,7 @@ var require_main_min = __commonJS({
3582
3582
  var Vt = require("react/jsx-runtime");
3583
3583
  var mF = { canRenderType: "paragraph", render: (e) => (0, Vt.jsx)(lF, s({}, e)) };
3584
3584
  function lF({ align: e, control: t, margin: o, text: r }) {
3585
- let n = wo({ align: e, margin: o });
3585
+ let n = bo({ align: e, margin: o });
3586
3586
  return t === "copyable" ? (0, Vt.jsx)(dF, { className: n, align: e, text: r }) : (0, Vt.jsx)(cF, { className: n, text: r });
3587
3587
  }
3588
3588
  function cF({ text: e, className: t }) {
@@ -3592,7 +3592,7 @@ var require_main_min = __commonJS({
3592
3592
  let { formatMessage: r } = (0, Gu.useIntl)(), n = $u(), a = () => {
3593
3593
  navigator.clipboard.writeText(e).then(() => n({ text: r(Go.copied) })).catch(() => {
3594
3594
  });
3595
- }, i = wo({ align: t, margin: "sm" });
3595
+ }, i = bo({ align: t, margin: "sm" });
3596
3596
  return (0, Vt.jsxs)("div", { className: o, children: [(0, Vt.jsx)(va.Input, { type: "text", value: e, readOnly: true, className: (0, Wu.default)("text-ellipsis", i) }), (0, Vt.jsx)(va.Button, { block: true, onClick: a, children: r(Go.copy) })] });
3597
3597
  }
3598
3598
  var _u = mF;
@@ -3643,9 +3643,9 @@ var require_main_min = __commonJS({
3643
3643
  }
3644
3644
  function CF({ state: e }) {
3645
3645
  let t = (0, Qu.useIntl)();
3646
- return (0, fe.jsxs)("p", { className: "m-t-2", children: [t.formatMessage(ve.genericError), "\xA0", (0, fe.jsx)("button", { type: "submit", onClick: (o) => {
3646
+ return (0, fe.jsxs)("p", { className: "m-t-2", children: [t.formatMessage(xe.genericError), "\xA0", (0, fe.jsx)("button", { type: "submit", onClick: (o) => {
3647
3647
  o.preventDefault(), e.onRetry();
3648
- }, children: t.formatMessage(ve.retry) })] });
3648
+ }, children: t.formatMessage(xe.retry) })] });
3649
3649
  }
3650
3650
  function SF({ state: e }) {
3651
3651
  return (0, fe.jsx)("p", { className: "m-t-2", children: e.message });
@@ -3812,7 +3812,7 @@ var require_main_min = __commonJS({
3812
3812
  var Ws = (e) => Oe(e) && Math.floor(e) === e;
3813
3813
  var Oa = (e) => typeof e == "boolean";
3814
3814
  var Q = (e) => !le(e) && (e == null ? void 0 : e.constructor) === Object;
3815
- var be = (e) => Array.isArray(e);
3815
+ var ve = (e) => Array.isArray(e);
3816
3816
  var EF = (e) => e === null;
3817
3817
  var LF = (e) => typeof e == "undefined";
3818
3818
  var le = (e) => EF(e) || LF(e);
@@ -3863,7 +3863,7 @@ var require_main_min = __commonJS({
3863
3863
  var Cy = (e) => Object.hasOwnProperty.call(e, "startComponents") && Object.hasOwnProperty.call(e, "endComponents");
3864
3864
  var Sy = (e) => "hidden" in e && e.hidden;
3865
3865
  var by = (e) => Object.hasOwnProperty.call(e, "editableComponent");
3866
- var oo = (e) => e != null && typeof e == "object" && !Array.isArray(e);
3866
+ var wo = (e) => e != null && typeof e == "object" && !Array.isArray(e);
3867
3867
  var tn = (e) => e != null && typeof e == "object" && !Array.isArray(e);
3868
3868
  var wy = (e) => Array.isArray(e);
3869
3869
  var Fy = (e) => "allOf" in e && !le(e.allOf);
@@ -3875,13 +3875,13 @@ var require_main_min = __commonJS({
3875
3875
  var Ay = (e) => "type" in e && e.type === "object";
3876
3876
  var My = (e) => "oneOf" in e && !le(e.oneOf);
3877
3877
  var Ry = (e) => "items" in e && !le(e.items);
3878
- var Ks = (e) => "items" in e && Q(e.items) && !be(e.items);
3878
+ var Ks = (e) => "items" in e && Q(e.items) && !ve(e.items);
3879
3879
  var Js = (e) => "type" in e && e.type === "string";
3880
3880
  var dr = (e) => Js(e) && e.format === "base64url";
3881
3881
  var pr = (e) => "persistAsync" in e && !le(e.persistAsync);
3882
3882
  var Te = async (e) => Promise.all(e.map(async (t) => t.getSubmittableValue())).then((t) => t.reduce((o, r) => ur(o, r), null));
3883
3883
  var De = (e) => e.map((t) => t.getLocalValue()).reduce((t, o) => DF(t, o), null);
3884
- var DF = (e, t) => e === null ? t : t === null ? e : oo(e) && oo(t) ? s(s({}, e), t) : t;
3884
+ var DF = (e, t) => e === null ? t : t === null ? e : wo(e) && wo(t) ? s(s({}, e), t) : t;
3885
3885
  var ur = (e, t) => e === null ? t : t === null ? e : tn(e) && tn(t) ? s(s({}, e), t) : t;
3886
3886
  var VF = ["step", "action", "exit"];
3887
3887
  var ky = async (e) => {
@@ -3949,7 +3949,7 @@ var require_main_min = __commonJS({
3949
3949
  return (0, Dy.jsx)(Xp, { value: o, children: e });
3950
3950
  }
3951
3951
  var tt = require("react");
3952
- var we = (e) => e.reduce((t, o) => o.validate() && t, true);
3952
+ var be = (e) => e.reduce((t, o) => o.validate() && t, true);
3953
3953
  var Ie = (e) => (t) => e.map((o) => o(t)).filter(K);
3954
3954
  var Vy = (e) => (t) => {
3955
3955
  let { summary: o, icon: r, image: n } = e, a = K(t) ? t : null;
@@ -3974,7 +3974,7 @@ var require_main_min = __commonJS({
3974
3974
  }, getLocalValue() {
3975
3975
  return De(this.components);
3976
3976
  }, validate() {
3977
- return we(this.getChildren());
3977
+ return be(this.getChildren());
3978
3978
  } });
3979
3979
  var Uy = () => Ys({ uid: "", loadingState: "idle", components: [] });
3980
3980
  var zy = (e) => C(s({ type: "alert" }, e), { getSubmittableValue: async () => null, getLocalValue: () => null, getSummary: () => ({}), validate: () => true });
@@ -4001,7 +4001,7 @@ var require_main_min = __commonJS({
4001
4001
  return e;
4002
4002
  }
4003
4003
  };
4004
- var ro = (e) => {
4004
+ var oo = (e) => {
4005
4005
  switch (e) {
4006
4006
  case "left":
4007
4007
  return "start";
@@ -4017,7 +4017,7 @@ var require_main_min = __commonJS({
4017
4017
  var Gy = (e) => e && e in Hy ? Hy[e] : "secondary";
4018
4018
  var fr = (e, { control: t, markdown: o, margin: r = "md", context: n = "neutral" }) => zy({ uid: e, control: t, markdown: o, margin: r, context: yr(n) });
4019
4019
  var Wy = (e) => C(s({ type: "heading" }, e), { getSubmittableValue: async () => null, getSummary: () => ({}), getLocalValue: () => null, validate: () => true });
4020
- var Da = (e, { align: t = "left", margin: o = "md", size: r = "md", control: n, text: a }) => Wy({ uid: e, align: ro(t), control: n, margin: o, size: r, text: a });
4020
+ var Da = (e, { align: t = "left", margin: o = "md", size: r = "md", control: n, text: a }) => Wy({ uid: e, align: oo(t), control: n, margin: o, size: r, text: a });
4021
4021
  var _y = (e) => C(s({}, e), { type: "box", getChildren() {
4022
4022
  return this.components;
4023
4023
  }, async getSubmittableValue() {
@@ -4027,13 +4027,16 @@ var require_main_min = __commonJS({
4027
4027
  }, getLocalValue() {
4028
4028
  return De(this.components);
4029
4029
  }, validate() {
4030
- return we(this.getChildren());
4030
+ return be(this.getChildren());
4031
4031
  } });
4032
4032
  var Ky = (e, { border: t = false, components: o, control: r, margin: n = "md", width: a = "xl" }, i) => _y({ uid: e, border: t, control: r, margin: n, width: a, components: o.map((m, l) => Ut(`${e}.box-${l}`, m, i)) });
4033
4033
  var Jy = (e) => C(s({ type: "button" }, e), { getSubmittableValue: async () => null, getLocalValue: () => null, getSummary: () => ({}), validate: () => true });
4034
- var Xy = (e, { action: t, context: o, control: r, disabled: n, margin: a = "md", pinOrder: i, size: m, title: l }, { onAction: c }) => Jy({ uid: e, context: HF({ context: o, action: t }), control: jF({ control: r, action: t }), disabled: zF({ disabled: n, action: t }), margin: a, pinOrder: i, size: m, title: UF({ title: l, action: t }), onClick: () => {
4035
- c(t);
4036
- } });
4034
+ var Xy = (e, { action: t, context: o, control: r, disabled: n, margin: a = "md", pinOrder: i, size: m, title: l }, { onAction: c, step: p }) => {
4035
+ let y = t != null && t.$ref ? s(s({}, qF(t.$ref, p == null ? void 0 : p.actions)), t) : t;
4036
+ return Jy({ uid: e, context: HF({ context: o, action: y }), control: jF({ control: r, action: y }), disabled: zF({ disabled: n, action: y }), margin: a, pinOrder: i, size: m, title: UF({ title: l, action: y }), onClick: () => {
4037
+ c(y);
4038
+ } });
4039
+ };
4037
4040
  var UF = ({ title: e, action: t }) => {
4038
4041
  var o;
4039
4042
  return (o = e != null ? e : t == null ? void 0 : t.title) != null ? o : "";
@@ -4044,6 +4047,12 @@ var require_main_min = __commonJS({
4044
4047
  };
4045
4048
  var jF = ({ control: e, action: t }) => e || (t != null && t.type ? Gy(t.type) : void 0);
4046
4049
  var HF = ({ context: e, action: t }) => e ? yr(e) : t != null && t.type ? $y(t.type) : "neutral";
4050
+ var qF = (e, t = []) => {
4051
+ let o = t.find((r) => r.$id === e);
4052
+ if (!o)
4053
+ throw new Error("Action reference not found in actions array.");
4054
+ return o;
4055
+ };
4047
4056
  var Yy = (e) => C(s({}, e), { type: "columns", getChildren() {
4048
4057
  return [...this.startComponents, ...this.endComponents];
4049
4058
  }, async getSubmittableValue() {
@@ -4053,7 +4062,7 @@ var require_main_min = __commonJS({
4053
4062
  }, getLocalValue() {
4054
4063
  return De(this.getChildren());
4055
4064
  }, validate() {
4056
- return we(this.getChildren());
4065
+ return be(this.getChildren());
4057
4066
  } });
4058
4067
  var Zy = (e, { control: t, left: o, right: r, bias: n = "none", margin: a = "md" }, i) => Yy({ uid: e, control: t, margin: a, bias: qy(n), startComponents: o.map((m, l) => Ut(`${e}.columns-start-${l}`, m, i)), endComponents: r.map((m, l) => Ut(`${e}.columns-end-${l}`, m, i)) });
4059
4068
  var Qy = (e) => C(s({ type: "decision" }, e), { getSubmittableValue: async () => null, getLocalValue: () => null, getSummary: () => ({}), validate: () => true });
@@ -4069,10 +4078,10 @@ var require_main_min = __commonJS({
4069
4078
  });
4070
4079
  };
4071
4080
  function Va({ value: e, signal: t, requestConfig: o }) {
4072
- let r = e instanceof File, { method: n, param: a } = o, i = r ? qF(a, e) : JSON.stringify({ [a]: e }), m = s({}, !r && { "Content-Type": "application/json" });
4081
+ let r = e instanceof File, { method: n, param: a } = o, i = r ? $F(a, e) : JSON.stringify({ [a]: e }), m = s({}, !r && { "Content-Type": "application/json" });
4073
4082
  return { method: n, headers: m, body: i, signal: t };
4074
4083
  }
4075
- var qF = (e, t) => {
4084
+ var $F = (e, t) => {
4076
4085
  let o = new FormData();
4077
4086
  return o.append(e, t), o;
4078
4087
  };
@@ -4092,7 +4101,7 @@ var require_main_min = __commonJS({
4092
4101
  if (p instanceof DOMException && p.name === "AbortError")
4093
4102
  return null;
4094
4103
  throw e((y) => {
4095
- y.errors = [p.message];
4104
+ y.errors = [p.message], y.persistedState.lastSubmitted = null;
4096
4105
  }), p;
4097
4106
  });
4098
4107
  return e((p) => {
@@ -4162,7 +4171,7 @@ var require_main_min = __commonJS({
4162
4171
  return u;
4163
4172
  if (a) {
4164
4173
  let g = Ve(p, a);
4165
- return C(s({}, u), { onBlur() {
4174
+ return C(s({}, u), { isPersisted: true, onBlur() {
4166
4175
  this.validate() && g(this.persistedState, this.getLocalValue()).catch(() => {
4167
4176
  });
4168
4177
  }, async getSubmittableValue() {
@@ -4203,10 +4212,10 @@ var require_main_min = __commonJS({
4203
4212
  let o = Ba(t, 1e3);
4204
4213
  return zt(e, o);
4205
4214
  };
4206
- var af = ({ maxItems: e }, t) => (o) => Oe(e) && be(o) && o.length > e ? t.maxItems(e) : null;
4207
- var sf = ({ minItems: e }, t) => (o) => Oe(e) && be(o) && o.length > 0 && o.length < e ? t.minFiles(e) : null;
4208
- var mf = ({ maxItems: e }, t) => (o) => Oe(e) && be(o) && o.length > e ? t.maxFiles(e) : null;
4209
- var lf = ({ minItems: e }, t) => (o) => Oe(e) && be(o) && o.length > 0 && o.length < e ? t.minItems(e) : null;
4215
+ var af = ({ maxItems: e }, t) => (o) => Oe(e) && ve(o) && o.length > e ? t.maxItems(e) : null;
4216
+ var sf = ({ minItems: e }, t) => (o) => Oe(e) && ve(o) && o.length > 0 && o.length < e ? t.minFiles(e) : null;
4217
+ var mf = ({ maxItems: e }, t) => (o) => Oe(e) && ve(o) && o.length > e ? t.maxFiles(e) : null;
4218
+ var lf = ({ minItems: e }, t) => (o) => Oe(e) && ve(o) && o.length > 0 && o.length < e ? t.minItems(e) : null;
4210
4219
  var cf = ({ maxLength: e }, t) => (o) => Oe(e) && K(o) && o.length > e ? t.maxLength(e) : null;
4211
4220
  var df = ({ minLength: e }, t) => (o) => Oe(e) && K(o) && o.length < e ? t.minLength(e) : null;
4212
4221
  var Ua = ({ maximum: e }, t) => (o) => Oe(e) && Oe(o) && o > e ? t.maximum(e) : null;
@@ -4214,7 +4223,7 @@ var require_main_min = __commonJS({
4214
4223
  var pf = ({ maximum: e }, t) => (o) => K(e) && K(o) && o > e ? t.maximumDate(e) : null;
4215
4224
  var uf = ({ minimum: e }, t) => (o) => K(e) && K(o) && o < e ? t.minimumDate(e) : null;
4216
4225
  var yf = ({ pattern: e }, t) => (o) => K(e) && K(o) && !new RegExp(e).test(o) ? t.pattern() : null;
4217
- var Fe = (e, t) => (o) => e && (be(o) && o.length === 0 || le(o)) ? t.required() : null;
4226
+ var we = (e, t) => (o) => e && (ve(o) && o.length === 0 || le(o)) ? t.required() : null;
4218
4227
  var Qe = (e) => {
4219
4228
  if (!e || e.length === 0)
4220
4229
  return "off";
@@ -4244,36 +4253,36 @@ var require_main_min = __commonJS({
4244
4253
  } catch (S) {
4245
4254
  throw p(), new Error(e);
4246
4255
  }
4247
- let h = d.status === 422 && Q(g) ? $F(m, g) : null;
4256
+ let h = d.status === 422 && Q(g) ? GF(m, g) : null;
4248
4257
  throw p(g), new Error(h != null ? h : e);
4249
4258
  };
4250
4259
  };
4251
- var $F = (e, t) => {
4260
+ var GF = (e, t) => {
4252
4261
  var r;
4253
4262
  let o = (r = t.validation) == null ? void 0 : r[e];
4254
4263
  return K(o) ? o : null;
4255
4264
  };
4256
4265
  var ut = (e, t) => ({ abortController: new AbortController(), lastSubmitted: le(t) ? null : e != null ? e : null, submission: Promise.resolve(t != null ? t : null) });
4257
- var xe = (e, t) => {
4258
- let { localValue: o, model: r } = e, n = GF(e, t), a = n ? ut(o, r) : ut();
4266
+ var Fe = (e, t) => {
4267
+ let { localValue: o, model: r } = e, n = WF(e, t), a = n ? ut(o, r) : ut();
4259
4268
  return { performPersistAsync: n, persistedState: a };
4260
4269
  };
4261
- var GF = (e, t) => {
4270
+ var WF = (e, t) => {
4262
4271
  let { schema: o, persistAsyncConfig: r } = e, { trackEvent: n, logEvent: a } = t;
4263
4272
  if (!r)
4264
4273
  return;
4265
- let { $id: i, analyticsId: m } = o, { getErrorMessageFunctions: l, httpClient: c } = t, p = WF(o) ? o.validationMessages : void 0, f = l(p).genericError();
4274
+ let { $id: i, analyticsId: m } = o, { getErrorMessageFunctions: l, httpClient: c } = t, p = _F(o) ? o.validationMessages : void 0, f = l(p).genericError();
4266
4275
  return hf({ genericErrorMessage: f, httpClient: c, logEvent: a, persistAsyncConfig: r, schemaId: m != null ? m : i, trackEvent: n });
4267
4276
  };
4268
- var WF = (e) => !!("validationMessages" in e && e.validationMessages);
4277
+ var _F = (e) => !!("validationMessages" in e && e.validationMessages);
4269
4278
  var Z = (e) => {
4270
4279
  var f;
4271
4280
  let { uid: t, schema: o, required: r, validationErrors: n } = e, { $id: a, analyticsId: i, control: m, description: l, keywords: c, title: p, hidden: y } = o;
4272
- return s(s({ uid: t, id: a != null ? a : t, analyticsId: (f = i != null ? i : a) != null ? f : "", control: m, description: l, disabled: _F(o) ? o.disabled : false, errors: K(n) ? [n] : [], hidden: !!y, keywords: c, required: !!r, title: p, summariser: Vy(o) }, KF(o) ? { help: o.help.markdown } : {}), JF(o) ? { placeholder: o.placeholder } : {});
4281
+ return s(s({ uid: t, id: a != null ? a : t, analyticsId: (f = i != null ? i : a) != null ? f : "", control: m, description: l, disabled: KF(o) ? o.disabled : false, errors: K(n) ? [n] : [], hidden: !!y, keywords: c, required: !!r, title: p, summariser: Vy(o) }, JF(o) ? { help: o.help.markdown } : {}), XF(o) ? { placeholder: o.placeholder } : {});
4273
4282
  };
4274
- var _F = (e) => "disabled" in e && e.disabled !== void 0;
4275
- var KF = (e) => !!("help" in e && e.help);
4276
- var JF = (e) => !!("placeholder" in e && e.placeholder);
4283
+ var KF = (e) => "disabled" in e && e.disabled !== void 0;
4284
+ var JF = (e) => !!("help" in e && e.help);
4285
+ var XF = (e) => !!("placeholder" in e && e.placeholder);
4277
4286
  var gf = ({ httpClient: e, validationAsyncConfig: t, schemaId: o, trackEvent: r }) => {
4278
4287
  let { method: n, param: a, url: i } = t, m = (l) => {
4279
4288
  let c = ja(l);
@@ -4287,7 +4296,7 @@ var require_main_min = __commonJS({
4287
4296
  } catch (d) {
4288
4297
  return m();
4289
4298
  }
4290
- let f = await y.json().catch(() => null), u = XF(f);
4299
+ let f = await y.json().catch(() => null), u = YF(f);
4291
4300
  if (y.ok)
4292
4301
  return r("ValidationAsync Succeeded", { schemaId: o }), u;
4293
4302
  if (y.status === 422 && u)
@@ -4295,7 +4304,7 @@ var require_main_min = __commonJS({
4295
4304
  return m(f);
4296
4305
  };
4297
4306
  };
4298
- var XF = (e) => {
4307
+ var YF = (e) => {
4299
4308
  if (!Q(e))
4300
4309
  return null;
4301
4310
  let { message: t } = e;
@@ -4303,20 +4312,20 @@ var require_main_min = __commonJS({
4303
4312
  };
4304
4313
  var Cf = () => ({ abortController: new AbortController(), lastSubmitted: null, messages: {} });
4305
4314
  var At = (e, t) => {
4306
- let o = YF(e, t), r = Cf();
4315
+ let o = ZF(e, t), r = Cf();
4307
4316
  return { performValidationAsync: o, validationState: r };
4308
4317
  };
4309
- var YF = (e, t) => {
4318
+ var ZF = (e, t) => {
4310
4319
  let { schema: o } = e, { trackEvent: r } = t;
4311
- if (!ZF(o))
4320
+ if (!QF(o))
4312
4321
  return;
4313
4322
  let { $id: n, analyticsId: a, validationAsync: i } = o, { httpClient: m } = t;
4314
4323
  return gf({ httpClient: m, validationAsyncConfig: i, schemaId: a != null ? a : n, trackEvent: r });
4315
4324
  };
4316
- var ZF = (e) => !!("validationAsync" in e && e.validationAsync);
4325
+ var QF = (e) => !!("validationAsync" in e && e.validationAsync);
4317
4326
  var Sf = (e, t) => {
4318
- let { schema: o, model: r, localValue: n, required: a = false } = e, { autocompleteHint: i, validationMessages: m, default: l } = o, { getErrorMessageFunctions: c, updateComponent: p, onRefresh: y } = t, f = c(m), { performPersistAsync: u, persistedState: d } = xe(e, t), { performValidationAsync: g, validationState: h } = At(e, t), S = Oe(n) ? n : null, b = Oe(r) ? r : l != null ? l : null, w = u ? S : b;
4319
- return nf(C(s({}, Z(e)), { autoComplete: Qe(i), checks: [Fe(a, f), za(o, f), Ua(o, f)], value: w, persistedState: d, validationState: h, performPersistAsync: u, performRefresh: hr(o, y), performValidationAsync: g }), p);
4327
+ let { schema: o, model: r, localValue: n, required: a = false } = e, { autocompleteHint: i, validationMessages: m, default: l } = o, { getErrorMessageFunctions: c, updateComponent: p, onRefresh: y } = t, f = c(m), { performPersistAsync: u, persistedState: d } = Fe(e, t), { performValidationAsync: g, validationState: h } = At(e, t), S = Oe(n) ? n : null, b = Oe(r) ? r : l != null ? l : null, w = u ? S : b;
4328
+ return nf(C(s({}, Z(e)), { autoComplete: Qe(i), checks: [we(a, f), za(o, f), Ua(o, f)], value: w, persistedState: d, validationState: h, performPersistAsync: u, performRefresh: hr(o, y), performValidationAsync: g }), p);
4320
4329
  };
4321
4330
  var bf = (e) => {
4322
4331
  let { uid: t, analyticsId: o, componentMap: r, control: n, description: a, displayOrder: i, help: m, hidden: l, summariser: c, title: p } = e;
@@ -4328,12 +4337,12 @@ var require_main_min = __commonJS({
4328
4337
  let y = c(this.getLocalValue()), f = Ae(this.getChildren());
4329
4338
  return Xs(y, f);
4330
4339
  }, getLocalValue() {
4331
- return QF(i, (y) => this.componentMap[y].getLocalValue());
4340
+ return ex(i, (y) => this.componentMap[y].getLocalValue());
4332
4341
  }, validate() {
4333
- return we(this.getChildren());
4342
+ return be(this.getChildren());
4334
4343
  } };
4335
4344
  };
4336
- var QF = (e, t) => e.reduce((o, r) => {
4345
+ var ex = (e, t) => e.reduce((o, r) => {
4337
4346
  let n = t(r);
4338
4347
  return s(s({}, o), n === null ? {} : { [r]: n });
4339
4348
  }, {});
@@ -4346,7 +4355,7 @@ var require_main_min = __commonJS({
4346
4355
  let g = c[d];
4347
4356
  if (g === void 0)
4348
4357
  throw new Error(`Object schema ${m} has no property named ${d}`);
4349
- return C(s({}, u), { [d]: et({ uid: `${o}.obj-${d}`, schema: g, model: tn(a) ? a[d] : null, localValue: oo(r) ? r[d] : null, required: (h = p == null ? void 0 : p.includes(d)) != null ? h : false, validationErrors: Q(i) ? i[d] : void 0 }, t) });
4358
+ return C(s({}, u), { [d]: et({ uid: `${o}.obj-${d}`, schema: g, model: tn(a) ? a[d] : null, localValue: wo(r) ? r[d] : null, required: (h = p == null ? void 0 : p.includes(d)) != null ? h : false, validationErrors: Q(i) ? i[d] : void 0 }, t) });
4350
4359
  }, {});
4351
4360
  return bf(C(s({}, Z(e)), { componentMap: f, displayOrder: l }));
4352
4361
  };
@@ -4361,7 +4370,7 @@ var require_main_min = __commonJS({
4361
4370
  }, getLocalValue() {
4362
4371
  return De(this.components);
4363
4372
  }, validate() {
4364
- return we(this.getChildren());
4373
+ return be(this.getChildren());
4365
4374
  } };
4366
4375
  };
4367
4376
  var xf = (e, t) => {
@@ -4404,7 +4413,7 @@ var require_main_min = __commonJS({
4404
4413
  return d;
4405
4414
  if (i) {
4406
4415
  let h = Ve(y, i);
4407
- return C(s({}, d), { onBlur() {
4416
+ return C(s({}, d), { isPersisted: true, onBlur() {
4408
4417
  this.validate() && h(this.persistedState, this.getLocalValue()).catch(() => {
4409
4418
  });
4410
4419
  }, async getSubmittableValue() {
@@ -4421,60 +4430,74 @@ var require_main_min = __commonJS({
4421
4430
  return d;
4422
4431
  };
4423
4432
  var Af = (e, t) => {
4424
- let { schema: o, localValue: r, model: n, required: a = false } = e, { autocompleteHint: i, validationMessages: m, default: l } = o, { getErrorMessageFunctions: c, updateComponent: p, onRefresh: y } = t, f = c(m), { performPersistAsync: u, persistedState: d } = xe(e, t), { performValidationAsync: g, validationState: h } = At(e, t), S = Ws(r) ? r : null, b = Ws(n) ? n : l != null ? l : null, w = u ? S : b, F = [Fe(a, f), za(o, f), Ua(o, f)];
4433
+ let { schema: o, localValue: r, model: n, required: a = false } = e, { autocompleteHint: i, validationMessages: m, default: l } = o, { getErrorMessageFunctions: c, updateComponent: p, onRefresh: y } = t, f = c(m), { performPersistAsync: u, persistedState: d } = Fe(e, t), { performValidationAsync: g, validationState: h } = At(e, t), S = Ws(r) ? r : null, b = Ws(n) ? n : l != null ? l : null, w = u ? S : b, F = [we(a, f), za(o, f), Ua(o, f)];
4425
4434
  return If(C(s({}, Z(e)), { autoComplete: Qe(i), checks: F, persistedState: d, value: w, validationState: h, performPersistAsync: u, performRefresh: hr(o, y), performValidationAsync: g }), p);
4426
4435
  };
4427
- var Ha = (e, t) => be(e) && be(t) ? e.every((o, r) => Ha(e[r], t[r])) : oo(e) && oo(t) ? Array.from(/* @__PURE__ */ new Set([...Object.keys(e), ...Object.keys(t)])).filter((n) => !le(e[n]) && !le(t[n])).every((n) => Ha(e[n], t[n])) : e === t;
4436
+ var Ha = (e, t) => {
4437
+ if (ve(e) && t.type === "repeatable") {
4438
+ let r = t.getChildren();
4439
+ return e.every((n, a) => {
4440
+ let i = r[a];
4441
+ return i ? Ha(n, i) : false;
4442
+ });
4443
+ }
4444
+ if (wo(e) && t.type === "object")
4445
+ return Array.from(/* @__PURE__ */ new Set([...Object.keys(e), ...Object.keys(t.componentMap)])).filter((a) => !le(e[a]) && !le(t.componentMap[a])).every((a) => Ha(e[a], t.componentMap[a]));
4446
+ let o = t.getLocalValue();
4447
+ return e instanceof File && o instanceof File ? tx(e, o) : "isPersisted" in t && t.isPersisted ? true : e === o;
4448
+ };
4449
+ var tx = (e, t) => e.name === t.name && e.type === t.type && e.size === t.size;
4428
4450
  var Mf = (e, t) => {
4429
- let S = e, { uid: o, checks: r, initialValue: n, options: a, performPersistAsync: i, performRefresh: m, summariser: l } = S, c = E(S, ["uid", "checks", "initialValue", "options", "performPersistAsync", "performRefresh", "summariser"]), p = a.map((b) => b.component), y = a.findIndex((b) => Ha(e.initialValue, b.component.getLocalValue())), f = ce(o, t), u = Ie(r), d = (b) => {
4430
- let w = u(b);
4431
- return f((F) => {
4432
- F.errors = w;
4433
- }), w;
4434
- }, g = C(s({ uid: o, type: "select", children: p, options: a, selectedIndex: y, value: null }, c), { getChildren() {
4451
+ let b = e, { uid: o, checks: r, initialValue: n, options: a, performPersistAsync: i, performRefresh: m, summariser: l } = b, c = E(b, ["uid", "checks", "initialValue", "options", "performPersistAsync", "performRefresh", "summariser"]), p = a.map((w) => w.component), y = a.map((w) => Ha(e.initialValue, w.component)), f = y.filter(ox).length === 1 ? y.indexOf(true) : null, u = ce(o, t), d = Ie(r), g = (w) => {
4452
+ let F = d(w);
4453
+ return u((x) => {
4454
+ x.errors = F;
4455
+ }), F;
4456
+ }, h = C(s({ uid: o, type: "select", children: p, options: a, selectedIndex: f, value: null }, c), { getChildren() {
4435
4457
  return this.children;
4436
4458
  }, getSelectedChild() {
4437
4459
  return this.selectedIndex !== null ? this.children[this.selectedIndex] : null;
4438
4460
  }, async getSubmittableValue() {
4439
- var b, w;
4440
- return (w = await ((b = this.getSelectedChild()) == null ? void 0 : b.getSubmittableValue())) != null ? w : null;
4461
+ var w, F;
4462
+ return (F = await ((w = this.getSelectedChild()) == null ? void 0 : w.getSubmittableValue())) != null ? F : null;
4441
4463
  }, getSummary() {
4442
- var b, w;
4443
- return (w = (b = this.getSelectedChild()) == null ? void 0 : b.getSummary()) != null ? w : {};
4464
+ var w, F;
4465
+ return (F = (w = this.getSelectedChild()) == null ? void 0 : w.getSummary()) != null ? F : {};
4444
4466
  }, getLocalValue() {
4445
- var b, w;
4446
- return (w = (b = this.getSelectedChild()) == null ? void 0 : b.getLocalValue()) != null ? w : null;
4467
+ var w, F;
4468
+ return (F = (w = this.getSelectedChild()) == null ? void 0 : w.getLocalValue()) != null ? F : null;
4447
4469
  }, onBlur() {
4448
- d(this.getLocalValue());
4470
+ g(this.getLocalValue());
4449
4471
  }, onFocus() {
4450
- }, onSelect(b) {
4451
- b !== null && this.analyticsId && e.trackEvent("OneOf Selected", { oneOfId: this.analyticsId, schemaId: this.children[b].analyticsId }), f((w) => {
4452
- w.errors = [], w.selectedIndex = b;
4472
+ }, onSelect(w) {
4473
+ w !== null && this.analyticsId && e.trackEvent("OneOf Selected", { oneOfId: this.analyticsId, schemaId: this.children[w].analyticsId }), u((F) => {
4474
+ F.errors = [], F.selectedIndex = w;
4453
4475
  }), m == null || m();
4454
4476
  }, validate() {
4455
- var F, x;
4456
- let b = (x = (F = this.getSelectedChild()) == null ? void 0 : F.validate()) != null ? x : true;
4457
- return d(this.getLocalValue()).length === 0 && b;
4477
+ var x, P;
4478
+ let w = (P = (x = this.getSelectedChild()) == null ? void 0 : x.validate()) != null ? P : true;
4479
+ return g(this.getLocalValue()).length === 0 && w;
4458
4480
  } });
4459
4481
  if (!i)
4460
- return g;
4461
- let h = Ve(f, i);
4462
- return C(s({}, g), { onSelect(b) {
4463
- g.onSelect.call(this, b), u(this.getLocalValue()).length === 0 && b !== null && h(this.persistedState, this.getLocalValue()).catch(() => {
4482
+ return h;
4483
+ let S = Ve(u, i);
4484
+ return C(s({}, h), { isPersisted: true, onSelect(w) {
4485
+ h.onSelect.call(this, w), d(this.getLocalValue()).length === 0 && w !== null && S(this.persistedState, this.getLocalValue()).catch(() => {
4464
4486
  });
4465
4487
  }, async getSubmittableValue() {
4466
- return h(this.persistedState, this.getLocalValue());
4488
+ return S(this.persistedState, this.getLocalValue());
4467
4489
  } });
4468
4490
  };
4491
+ var ox = (e) => e;
4469
4492
  var Rf = (e, t) => {
4470
4493
  var F, x;
4471
4494
  let { uid: o, localValue: r, schema: n, model: a, validationErrors: i, required: m = false } = e, l = (F = a != null ? a : n.default) != null ? F : null, c = n.oneOf.map((P, R) => {
4472
4495
  let { title: A = "", description: O, image: v, icon: L, keywords: k = [] } = P;
4473
- return { title: A, description: O, image: v, icon: L, keywords: k, disabled: "disabled" in P ? !!P.disabled : false, component: et({ uid: `${o}.oneOf-${R}`, schema: ex(P), model: l, localValue: r, validationErrors: i, required: m }, t) };
4474
- }), { getErrorMessageFunctions: p, updateComponent: y, trackEvent: f, onRefresh: u } = t, { default: d, validationMessages: g } = n, h = p(g), { performPersistAsync: S, persistedState: b } = xe(e, t), w = S ? r : (x = a != null ? a : d) != null ? x : null;
4475
- return Mf(C(s({}, Z(e)), { autoComplete: Qe(n.autocompleteHint), checks: n.hidden ? [] : [Fe(m, h)], options: c, initialValue: w, persistedState: b, performPersistAsync: S, performRefresh: zt(n, u), trackEvent: f }), y);
4496
+ return { title: A, description: O, image: v, icon: L, keywords: k, disabled: "disabled" in P ? !!P.disabled : false, component: et({ uid: `${o}.oneOf-${R}`, schema: rx(P), model: l, localValue: r, validationErrors: i, required: m }, t) };
4497
+ }), { getErrorMessageFunctions: p, updateComponent: y, trackEvent: f, onRefresh: u } = t, { default: d, validationMessages: g } = n, h = p(g), { performPersistAsync: S, persistedState: b } = Fe(e, t), w = S ? r : (x = a != null ? a : d) != null ? x : null;
4498
+ return Mf(C(s({}, Z(e)), { autoComplete: Qe(n.autocompleteHint), checks: n.hidden ? [] : [we(m, h)], options: c, initialValue: w, persistedState: b, performPersistAsync: S, performRefresh: zt(n, u), trackEvent: f }), y);
4476
4499
  };
4477
- var ex = (e) => {
4500
+ var rx = (e) => {
4478
4501
  let n = e, { title: t, description: o } = n;
4479
4502
  return E(n, ["title", "description"]);
4480
4503
  };
@@ -4505,7 +4528,7 @@ var require_main_min = __commonJS({
4505
4528
  return d;
4506
4529
  if (a) {
4507
4530
  let h = Ve(y, a);
4508
- return C(s({}, d), { onChange(S) {
4531
+ return C(s({}, d), { isPersisted: true, onChange(S) {
4509
4532
  d.onChange.call(this, S), f(S).length === 0 && h(this.persistedState, this.getLocalValue()).catch(() => {
4510
4533
  });
4511
4534
  }, async getSubmittableValue() {
@@ -4522,8 +4545,8 @@ var require_main_min = __commonJS({
4522
4545
  return d;
4523
4546
  };
4524
4547
  var Of = (e, t) => {
4525
- let { schema: o, localValue: r, model: n, required: a = false } = e, { autocompleteHint: i, default: m, minimum: l, maximum: c } = o, { getErrorMessageFunctions: p, updateComponent: y, onRefresh: f } = t, u = p(o.validationMessages), { performPersistAsync: d, persistedState: g } = xe(e, t), { performValidationAsync: h, validationState: S } = At(e, t), b = K(r) ? r : null, w = K(n) ? n : m != null ? m : null, F = d ? b : w;
4526
- return kf(C(s({}, Z(e)), { autoComplete: Qe(i), checks: o.hidden ? [] : [Fe(a, u), pf(o, u), uf(o, u)], minimumDate: l, maximumDate: c, value: F, persistedState: g, validationState: S, performPersistAsync: d, performRefresh: zt(o, f), performValidationAsync: h }), y);
4548
+ let { schema: o, localValue: r, model: n, required: a = false } = e, { autocompleteHint: i, default: m, minimum: l, maximum: c } = o, { getErrorMessageFunctions: p, updateComponent: y, onRefresh: f } = t, u = p(o.validationMessages), { performPersistAsync: d, persistedState: g } = Fe(e, t), { performValidationAsync: h, validationState: S } = At(e, t), b = K(r) ? r : null, w = K(n) ? n : m != null ? m : null, F = d ? b : w;
4549
+ return kf(C(s({}, Z(e)), { autoComplete: Qe(i), checks: o.hidden ? [] : [we(a, u), pf(o, u), uf(o, u)], minimumDate: l, maximumDate: c, value: F, persistedState: g, validationState: S, performPersistAsync: d, performRefresh: zt(o, f), performValidationAsync: h }), y);
4527
4550
  };
4528
4551
  var gr = async (e) => new Promise((t, o) => {
4529
4552
  let r = new FileReader();
@@ -4556,7 +4579,7 @@ var require_main_min = __commonJS({
4556
4579
  if (!m)
4557
4580
  return d;
4558
4581
  let g = Ve(y, m);
4559
- return C(s({}, d), { format: a, async onUpload(S) {
4582
+ return C(s({}, d), { format: a, isPersisted: true, async onUpload(S) {
4560
4583
  y((w) => {
4561
4584
  w.errors = [], w.value = S;
4562
4585
  });
@@ -4571,8 +4594,8 @@ var require_main_min = __commonJS({
4571
4594
  } });
4572
4595
  };
4573
4596
  var Ef = (e, t) => {
4574
- let { schema: o, localValue: r, model: n, required: a = false } = e, { accepts: i, autocompleteHint: m, maxSize: l, validationMessages: c } = o, { getErrorMessageFunctions: p, updateComponent: y, onRefresh: f } = t, u = p(c), { performPersistAsync: d } = xe(e, t), g = d ? ut(null, n) : ut(), h = mr(r) ? r : null, S = d ? h : null;
4575
- return qa(C(s({}, Z(e)), { accepts: i, autoComplete: Qe(m), checks: o.hidden ? [] : [Fe(a, u)], format: "base64", maxSize: l, value: S, persistedState: g, performPersistAsync: d, performRefresh: zt(o, f) }), y);
4597
+ let { schema: o, localValue: r, model: n, required: a = false } = e, { accepts: i, autocompleteHint: m, maxSize: l, validationMessages: c } = o, { getErrorMessageFunctions: p, updateComponent: y, onRefresh: f } = t, u = p(c), { performPersistAsync: d } = Fe(e, t), g = d ? ut(null, n) : ut(), h = mr(r) ? r : null, S = d ? h : null;
4598
+ return qa(C(s({}, Z(e)), { accepts: i, autoComplete: Qe(m), checks: o.hidden ? [] : [we(a, u)], format: "base64", maxSize: l, value: S, persistedState: g, performPersistAsync: d, performRefresh: zt(o, f) }), y);
4576
4599
  };
4577
4600
  var Lf = (e, t) => {
4578
4601
  let g = e, { uid: o, id: r, checks: n, performPersistAsync: a, performRefresh: i, performValidationAsync: m, summariser: l, value: c } = g, p = E(g, ["uid", "id", "checks", "performPersistAsync", "performRefresh", "performValidationAsync", "summariser", "value"]), y = ce(o, t), f = Ie(n), u = (h) => {
@@ -4601,7 +4624,7 @@ var require_main_min = __commonJS({
4601
4624
  return d;
4602
4625
  if (a) {
4603
4626
  let h = Ve(y, a);
4604
- return C(s({}, d), { onBlur() {
4627
+ return C(s({}, d), { isPersisted: true, onBlur() {
4605
4628
  this.validate() && h(this.persistedState, this.getLocalValue()).catch(() => {
4606
4629
  });
4607
4630
  }, async getSubmittableValue() {
@@ -4618,10 +4641,10 @@ var require_main_min = __commonJS({
4618
4641
  return d;
4619
4642
  };
4620
4643
  var Tf = (e, t) => {
4621
- let { schema: o, localValue: r, model: n, required: a = false } = e, { autocompleteHint: i, control: m, default: l, displayFormat: c, format: p, validationMessages: y } = o, { getErrorMessageFunctions: f, updateComponent: u, onRefresh: d } = t, g = tx(p), h = f(y), { performPersistAsync: S, persistedState: b } = xe(e, t), { performValidationAsync: w, validationState: F } = At(e, t), x = K(r) ? r : null, P = K(n) ? n : l != null ? l : null, R = S ? x : P;
4622
- return Lf(C(s({}, Z(e)), { autoComplete: Qe(i), checks: o.hidden ? [] : [Fe(a, h), cf(o, h), df(o, h), yf(o, h)], control: m != null ? m : g, displayFormat: c, value: R, persistedState: b, validationState: F, performPersistAsync: S, performRefresh: hr(o, d), performValidationAsync: w }), u);
4644
+ let { schema: o, localValue: r, model: n, required: a = false } = e, { autocompleteHint: i, control: m, default: l, displayFormat: c, format: p, validationMessages: y } = o, { getErrorMessageFunctions: f, updateComponent: u, onRefresh: d } = t, g = nx(p), h = f(y), { performPersistAsync: S, persistedState: b } = Fe(e, t), { performValidationAsync: w, validationState: F } = At(e, t), x = K(r) ? r : null, P = K(n) ? n : l != null ? l : null, R = S ? x : P;
4645
+ return Lf(C(s({}, Z(e)), { autoComplete: Qe(i), checks: o.hidden ? [] : [we(a, h), cf(o, h), df(o, h), yf(o, h)], control: m != null ? m : g, displayFormat: c, value: R, persistedState: b, validationState: F, performPersistAsync: S, performRefresh: hr(o, d), performValidationAsync: w }), u);
4623
4646
  };
4624
- var tx = (e) => {
4647
+ var nx = (e) => {
4625
4648
  if (e && ["numeric", "phone-number", "email", "password"].includes(e))
4626
4649
  return e;
4627
4650
  };
@@ -4645,7 +4668,7 @@ var require_main_min = __commonJS({
4645
4668
  }, getLocalValue() {
4646
4669
  return De(this.components);
4647
4670
  }, validate() {
4648
- return we(this.getChildren());
4671
+ return be(this.getChildren());
4649
4672
  } });
4650
4673
  var Nf = (e, t) => {
4651
4674
  let f = e, { uid: o, id: r, checks: n, components: a, summary: i, createEditableComponent: m, summariser: l } = f, c = E(f, ["uid", "id", "checks", "components", "summary", "createEditableComponent", "summariser"]), p = ce(o, t), y = Ie(n);
@@ -4682,18 +4705,18 @@ var require_main_min = __commonJS({
4682
4705
  }, getLocalValue() {
4683
4706
  return this.components.map((u) => u.getLocalValue());
4684
4707
  }, validate() {
4685
- let u = y(this.getLocalValue()), d = we(this.getChildren());
4708
+ let u = y(this.getLocalValue()), d = be(this.getChildren());
4686
4709
  return p((g) => {
4687
4710
  g.errors = u;
4688
4711
  }), u.length === 0 && d;
4689
4712
  } });
4690
4713
  };
4691
4714
  var Bf = (e, t) => {
4692
- let { getErrorMessageFunctions: o } = t, { uid: r, localValue: n, schema: a, model: i, required: m = false, validationErrors: l } = e, { items: c, addItemTitle: p, editItemTitle: y, summary: f } = a, u = be(n) ? n : [], d = i == null ? void 0 : i.map((S, b) => et({ uid: `${r}.arr-${b}`, schema: c, model: S, localValue: u == null ? void 0 : u[b], validationErrors: l }, t)), g = (S) => et({ uid: `${r}.arr-rnd-${ox()}`, schema: c, localValue: S, model: Zs(S), validationErrors: void 0 }, t), h = o(a.validationMessages);
4693
- return Nf(C(s({}, Z(e)), { addItemTitle: p, checks: a.hidden ? [] : [Fe(m, h), af(a, h), lf(a, h)], components: d != null ? d : [], editItemTitle: y, summary: f, createEditableComponent: g }), t.updateComponent);
4715
+ let { getErrorMessageFunctions: o } = t, { uid: r, localValue: n, schema: a, model: i, required: m = false, validationErrors: l } = e, { items: c, addItemTitle: p, editItemTitle: y, summary: f } = a, u = ve(n) ? n : [], d = i == null ? void 0 : i.map((S, b) => et({ uid: `${r}.arr-${b}`, schema: c, model: S, localValue: u == null ? void 0 : u[b], validationErrors: l }, t)), g = (S) => et({ uid: `${r}.arr-rnd-${ax()}`, schema: c, localValue: S, model: Zs(S), validationErrors: void 0 }, t), h = o(a.validationMessages);
4716
+ return Nf(C(s({}, Z(e)), { addItemTitle: p, checks: a.hidden ? [] : [we(m, h), af(a, h), lf(a, h)], components: d != null ? d : [], editItemTitle: y, summary: f, createEditableComponent: g }), t.updateComponent);
4694
4717
  };
4695
4718
  var Zs = (e) => e instanceof Array ? e.map(Zs) : Q(e) ? Object.fromEntries(Object.entries(e).map(([t, o]) => [t, Zs(o)])) : e instanceof File ? e.name : e;
4696
- var ox = () => Math.floor(Math.random() * 1e8);
4719
+ var ax = () => Math.floor(Math.random() * 1e8);
4697
4720
  var Uf = (e, t) => {
4698
4721
  let d = e, { uid: o, id: r, checks: n, format: a, performPersistAsync: i, summariser: m } = d, l = E(d, ["uid", "id", "checks", "format", "performPersistAsync", "summariser"]), c = ce(o, t), p = Ie(n), y = (g) => {
4699
4722
  let h = p(g);
@@ -4727,7 +4750,7 @@ var require_main_min = __commonJS({
4727
4750
  if (!i)
4728
4751
  return f;
4729
4752
  let u = rf(c, i);
4730
- return C(s({}, f), { format: a, async onUpload(g, h) {
4753
+ return C(s({}, f), { format: a, isPersisted: true, async onUpload(g, h) {
4731
4754
  await f.onUpload.call(this, g, h);
4732
4755
  let S = a === "blob" ? g : await gr(g);
4733
4756
  await u(S, h);
@@ -4741,28 +4764,28 @@ var require_main_min = __commonJS({
4741
4764
  } });
4742
4765
  };
4743
4766
  var zf = (e, t) => {
4744
- let { getErrorMessageFunctions: o } = t, { localValue: r, model: n, schema: a, required: i = false } = e, m = nx(a.items), { accepts: l, maxSize: c } = m, { minItems: p, maxItems: y, title: f, validationMessages: u } = a, d = o(u), g = [Fe(i, d), mf(a, d), sf(a, d)], h = ax(a.items), S = rx(a.items), b = C(s({}, e), { persistAsyncConfig: h, schema: m }), { performPersistAsync: w } = xe(b, t), F = w ? ix(r) : [], x = w && be(n) ? n.map((P) => ut(null, P)) : [];
4767
+ let { getErrorMessageFunctions: o } = t, { localValue: r, model: n, schema: a, required: i = false } = e, m = sx(a.items), { accepts: l, maxSize: c } = m, { minItems: p, maxItems: y, title: f, validationMessages: u } = a, d = o(u), g = [we(i, d), mf(a, d), sf(a, d)], h = mx(a.items), S = ix(a.items), b = C(s({}, e), { persistAsyncConfig: h, schema: m }), { performPersistAsync: w } = Fe(b, t), F = w ? lx(r) : [], x = w && ve(n) ? n.map((P) => ut(null, P)) : [];
4745
4768
  return Uf(C(s({}, Z(b)), { title: f, uploadLabel: m.title, accepts: l, autoComplete: "off", checks: a.hidden ? [] : g, format: S, maxSize: c, minItems: p, maxItems: y, required: i, value: F, persistedState: x, performPersistAsync: w }), t.updateComponent);
4746
4769
  };
4747
- var rx = (e) => dr(e) ? "base64" : cr(e.persistAsync.schema) ? "blob" : "base64";
4748
- var nx = (e) => dr(e) ? e : e.persistAsync.schema;
4749
- var ax = (e) => {
4770
+ var ix = (e) => dr(e) ? "base64" : cr(e.persistAsync.schema) ? "blob" : "base64";
4771
+ var sx = (e) => dr(e) ? e : e.persistAsync.schema;
4772
+ var mx = (e) => {
4750
4773
  if (!pr(e))
4751
4774
  return;
4752
4775
  let { persistAsync: t } = e, { idProperty: o, method: r, param: n, url: a } = t;
4753
4776
  return { idProperty: o, method: r, param: n, url: a };
4754
4777
  };
4755
- var ix = (e) => be(e) && e.every(mr) ? e : [];
4778
+ var lx = (e) => ve(e) && e.every(mr) ? e : [];
4756
4779
  var jf = (e, t) => {
4757
4780
  let { schema: o, model: r } = e, n = le(r) || wy(r) ? r : null;
4758
- if (sx(o))
4781
+ if (cx(o))
4759
4782
  return zf(C(s({}, e), { schema: o, model: n }), t);
4760
4783
  if (Ks(o))
4761
4784
  return Bf(C(s({}, e), { schema: o, model: n }), t);
4762
4785
  throw new Error("Currently only repeatable array schemas are supported");
4763
4786
  };
4764
- var sx = (e) => Ks(e) && (mx(e.items) || dr(e.items));
4765
- var mx = (e) => pr(e) && (cr(e.persistAsync.schema) || dr(e.persistAsync.schema));
4787
+ var cx = (e) => Ks(e) && (dx(e.items) || dr(e.items));
4788
+ var dx = (e) => pr(e) && (cr(e.persistAsync.schema) || dr(e.persistAsync.schema));
4766
4789
  var Hf = (e, t) => {
4767
4790
  let f = e, { uid: o, id: r, value: n, performPersistAsync: a, performRefresh: i, performValidationAsync: m, summariser: l } = f, c = E(f, ["uid", "id", "value", "performPersistAsync", "performRefresh", "performValidationAsync", "summariser"]), p = ce(o, t), y = s({ type: "boolean", uid: o, id: r, autoComplete: "", value: n, onBlur() {
4768
4791
  }, onFocus() {
@@ -4781,7 +4804,7 @@ var require_main_min = __commonJS({
4781
4804
  return y;
4782
4805
  if (a) {
4783
4806
  let u = Ve(p, a);
4784
- return C(s({}, y), { onChange(d) {
4807
+ return C(s({}, y), { isPersisted: true, onChange(d) {
4785
4808
  y.onChange.call(this, d), u(this.persistedState, this.getLocalValue()).catch(() => {
4786
4809
  });
4787
4810
  }, async getSubmittableValue() {
@@ -4798,13 +4821,13 @@ var require_main_min = __commonJS({
4798
4821
  return y;
4799
4822
  };
4800
4823
  var qf = (e, t) => {
4801
- let { schema: o, localValue: r, model: n } = e, { default: a } = o, { updateComponent: i, onRefresh: m } = t, l = zt(o, m), { performPersistAsync: c, persistedState: p } = xe(e, t), { performValidationAsync: y, validationState: f } = At(e, t), u = Oa(r) ? r : false, d = lx(n, a), g = c ? u : d;
4824
+ let { schema: o, localValue: r, model: n } = e, { default: a } = o, { updateComponent: i, onRefresh: m } = t, l = zt(o, m), { performPersistAsync: c, persistedState: p } = Fe(e, t), { performValidationAsync: y, validationState: f } = At(e, t), u = Oa(r) ? r : false, d = px(n, a), g = c ? u : d;
4802
4825
  return Hf(C(s({}, Z(e)), { value: g != null ? g : false, persistedState: p, validationState: f, performPersistAsync: c, performRefresh: l, performValidationAsync: y }), i);
4803
4826
  };
4804
- var lx = (e, t) => Oa(e) ? e : Oa(t) ? t : false;
4827
+ var px = (e, t) => Oa(e) ? e : Oa(t) ? t : false;
4805
4828
  var $f = (e, t) => {
4806
- let { schema: o, localValue: r, model: n, required: a = false } = e, { accepts: i, maxSize: m, validationMessages: l } = o, { getErrorMessageFunctions: c, updateComponent: p } = t, y = c(l), { performPersistAsync: f } = xe(e, t), u = f ? ut(null, n) : ut(), d = mr(r) ? r : null, g = f ? d : null;
4807
- return qa(C(s({}, Z(e)), { accepts: i, autoComplete: "off", format: "blob", maxSize: m, value: g, persistedState: u, performPersistAsync: f, checks: o.hidden ? [] : [Fe(a, y)] }), p);
4829
+ let { schema: o, localValue: r, model: n, required: a = false } = e, { accepts: i, maxSize: m, validationMessages: l } = o, { getErrorMessageFunctions: c, updateComponent: p } = t, y = c(l), { performPersistAsync: f } = Fe(e, t), u = f ? ut(null, n) : ut(), d = mr(r) ? r : null, g = f ? d : null;
4830
+ return qa(C(s({}, Z(e)), { accepts: i, autoComplete: "off", format: "blob", maxSize: m, value: g, persistedState: u, performPersistAsync: f, checks: o.hidden ? [] : [we(a, y)] }), p);
4808
4831
  };
4809
4832
  var et = (e, t) => {
4810
4833
  let { uid: o, schema: r } = e, { alert: n } = r;
@@ -4850,23 +4873,23 @@ var require_main_min = __commonJS({
4850
4873
  }, getLocalValue() {
4851
4874
  return De(this.getChildren());
4852
4875
  }, validate() {
4853
- return we(this.getChildren());
4876
+ return be(this.getChildren());
4854
4877
  } });
4855
- var _f = (e, { schemaId: t, control: o, margin: r = "md" }, n) => {
4856
- let { step: a, stepLocalValue: i } = n, { model: m, errors: l, schemas: c } = a, p = c.find((y) => y.$id === t);
4857
- if (!p)
4858
- throw new Error("Bad layout schemaId");
4859
- return Wf({ uid: e, components: [et({ uid: `${e}.form`, schema: p, model: m != null ? m : null, localValue: i, validationErrors: l == null ? void 0 : l.validation }, n)], control: o, margin: r });
4878
+ var _f = (e, { schemaId: t, schema: o, control: r, margin: n = "md" }, a) => {
4879
+ let { step: i, stepLocalValue: m } = a, { model: l, errors: c, schemas: p } = i, y = t != null ? t : o == null ? void 0 : o.$ref, f = p.find((u) => u.$id === y);
4880
+ if (!f)
4881
+ throw new Error("Schema not found in schemas array.");
4882
+ return Wf({ uid: e, components: [et({ uid: `${e}.form`, schema: f, model: l != null ? l : null, localValue: m, validationErrors: c == null ? void 0 : c.validation }, a)], control: r, margin: n });
4860
4883
  };
4861
4884
  var Kf = (e) => C(s({ type: "image" }, e), { getSubmittableValue: async () => null, getLocalValue: () => null, getSummary: () => ({}), validate: () => true });
4862
4885
  var Jf = (e, { accessibilityDescription: t, control: o, margin: r = "md", size: n = "md", text: a, url: i }) => Kf({ uid: e, accessibilityDescription: t != null ? t : a, control: o, margin: r, size: n, url: i });
4863
4886
  var $a = (e) => C(s({ type: "markdown" }, e), { getSubmittableValue: async () => null, getLocalValue: () => null, getSummary: () => ({}), validate: () => true });
4864
- var Xf = (e, { align: t = "left", control: o, margin: r = "md", markdown: n }) => $a({ uid: e, align: ro(t), content: n, control: o, margin: r });
4887
+ var Xf = (e, { align: t = "left", control: o, margin: r = "md", markdown: n }) => $a({ uid: e, align: oo(t), content: n, control: o, margin: r });
4865
4888
  var Yf = (e) => C(s({ type: "instructions" }, e), { getLocalValue: () => null, getSubmittableValue: async () => null, getSummary: () => ({}), validate: () => true });
4866
4889
  var Zf = (e, { control: t, items: o, margin: r = "md", title: n }) => Yf({ uid: e, control: t, items: o.map(({ context: a, text: i }) => ({ context: yr(a), text: i })), margin: r, title: n });
4867
4890
  var Qf = (e) => C(s({ type: "loading-indicator" }, e), { getSubmittableValue: async () => null, getLocalValue: () => null, getSummary: () => ({}), validate: () => true });
4868
4891
  var eh = (e, { size: t = "md", margin: o = "md", control: r }) => Qf({ uid: e, size: t, control: r, margin: o });
4869
- var th = (e, { align: t = "left", margin: o = "md", control: r, content: n }) => $a({ uid: e, align: ro(t), control: r, content: n, margin: o });
4892
+ var th = (e, { align: t = "left", margin: o = "md", control: r, content: n }) => $a({ uid: e, align: oo(t), control: r, content: n, margin: o });
4870
4893
  var oh = (e) => C(s({ type: "modal" }, e), { getChildren() {
4871
4894
  return this.content.components;
4872
4895
  }, getLocalValue() {
@@ -4876,32 +4899,32 @@ var require_main_min = __commonJS({
4876
4899
  }, getSummary() {
4877
4900
  return Ae(this.getChildren());
4878
4901
  }, validate() {
4879
- return we(this.getChildren());
4902
+ return be(this.getChildren());
4880
4903
  } });
4881
4904
  var rh = (e, { content: t, control: o, margin: r = "md", trigger: n }, a) => {
4882
4905
  let { components: i } = t;
4883
4906
  return oh({ uid: e, content: { components: i.map((m, l) => Ut(`${e}.modal-${l}`, m, a)) }, control: o, margin: r, trigger: n });
4884
4907
  };
4885
4908
  var nh = (e) => C(s({ type: "paragraph" }, e), { getSubmittableValue: async () => null, getSummary: () => ({}), getLocalValue: () => null, validate: () => true });
4886
- var ah = (e, { align: t = "left", control: o, margin: r = "md", text: n }) => nh({ uid: e, text: n, control: o, align: ro(t), margin: r });
4909
+ var ah = (e, { align: t = "left", control: o, margin: r = "md", text: n }) => nh({ uid: e, text: n, control: o, align: oo(t), margin: r });
4887
4910
  var ih = (e) => C(s({ type: "review" }, e), { getLocalValue: () => null, getSubmittableValue: async () => null, getSummary: () => ({}), validate: () => true });
4888
- var sh = (e, { fields: t, title: o, callToAction: r, control: n, margin: a = "md", orientation: i, action: m }, { onAction: l }) => ih({ uid: e, callToAction: cx(l, r, m), control: dx({ control: n, orientation: i }), fields: t.map((c) => {
4911
+ var sh = (e, { fields: t, title: o, callToAction: r, control: n, margin: a = "md", orientation: i, action: m }, { onAction: l }) => ih({ uid: e, callToAction: ux(l, r, m), control: yx({ control: n, orientation: i }), fields: t.map((c) => {
4889
4912
  var p;
4890
4913
  return C(s({}, c), { help: (p = c.help) == null ? void 0 : p.markdown });
4891
4914
  }), margin: a, title: o });
4892
- var cx = (e, t, o) => {
4915
+ var ux = (e, t, o) => {
4893
4916
  if (t)
4894
4917
  return { title: t.title, onClick: () => e(t.action) };
4895
4918
  if (o != null && o.title)
4896
4919
  return { title: o.title, onClick: () => e(o) };
4897
4920
  };
4898
- var dx = ({ control: e, orientation: t }) => {
4921
+ var yx = ({ control: e, orientation: t }) => {
4899
4922
  if (e)
4900
4923
  return e;
4901
4924
  if (t)
4902
4925
  return t;
4903
4926
  };
4904
- var px = 400;
4927
+ var fx = 400;
4905
4928
  var mh = (e, t, o, r) => {
4906
4929
  let { uid: n, control: a, emptyMessage: i, margin: m, title: l } = e, c = ce(n, r), p = new AbortController(), y = (g, h) => {
4907
4930
  p.abort(), p = new AbortController();
@@ -4919,7 +4942,7 @@ var require_main_min = __commonJS({
4919
4942
  g === "action" ? o(h) : (c((S) => {
4920
4943
  S.query = h.query;
4921
4944
  }), y(h.query, { method: h.method, param: h.param, url: h.url }));
4922
- }, u = Ba(y, px);
4945
+ }, u = Ba(y, fx);
4923
4946
  return { type: "search", uid: n, control: a, emptyMessage: i, margin: m, title: l, isLoading: false, query: "", results: [], getSubmittableValue: async () => null, getLocalValue: () => null, getSummary: () => ({}), validate: () => true, onChange: (g) => {
4924
4947
  c((h) => {
4925
4948
  h.query = g, h.isLoading = true;
@@ -4929,30 +4952,30 @@ var require_main_min = __commonJS({
4929
4952
  var lh = (e, t) => async ({ config: o = t, query: r, signal: n }) => {
4930
4953
  if (!r)
4931
4954
  return [];
4932
- let { method: a, param: i, url: m } = o, l = { "Content-Type": "application/json" }, p = await (a === "GET" ? e(yx(m, i, r), { method: a, headers: l, signal: n }) : e(m, { method: a, headers: l, signal: n, body: JSON.stringify({ [i]: r }) }));
4933
- return ux(p);
4955
+ let { method: a, param: i, url: m } = o, l = { "Content-Type": "application/json" }, p = await (a === "GET" ? e(gx(m, i, r), { method: a, headers: l, signal: n }) : e(m, { method: a, headers: l, signal: n, body: JSON.stringify({ [i]: r }) }));
4956
+ return hx(p);
4934
4957
  };
4935
- var ux = async (e) => {
4958
+ var hx = async (e) => {
4936
4959
  if (e.ok) {
4937
4960
  let t = await e.json().catch(() => null);
4938
- if (fx(t))
4961
+ if (Cx(t))
4939
4962
  return t.results.length === 0 ? [] : t.results;
4940
4963
  }
4941
4964
  throw Error("error response");
4942
4965
  };
4943
- var yx = (e, t, o) => {
4966
+ var gx = (e, t, o) => {
4944
4967
  let [r, n] = e.split("?"), a = new URLSearchParams(n);
4945
4968
  return a.set(t, o), `${r}?${a.toString()}`;
4946
4969
  };
4947
- var fx = (e) => Q(e) && "results" in e && be(e.results) && e.results.every((t) => Q(t) && "title" in t && "type" in t && "value" in t);
4970
+ var Cx = (e) => Q(e) && "results" in e && ve(e.results) && e.results.every((t) => Q(t) && "title" in t && "type" in t && "value" in t);
4948
4971
  var ch = (e, { control: t, emptyMessage: o = "", method: r, param: n, title: a, url: i, margin: m = "md" }, l) => {
4949
4972
  let { httpClient: c, onAction: p, updateComponent: y } = l, f = lh(c, { method: r, param: n, url: i });
4950
4973
  return mh({ uid: e, control: t, emptyMessage: o, margin: m, title: a }, f, p, y);
4951
4974
  };
4952
4975
  var Ga = (e) => C(s({ type: "status-list" }, e), { getLocalValue: () => null, getSubmittableValue: async () => null, getSummary: () => ({}), validate: () => true });
4953
4976
  var dh = (e, { control: t, items: o, margin: r = "md", title: n }) => Ga({ uid: e, control: t, items: o, margin: r, title: n });
4954
- var ph = (e, { control: t, items: o, margin: r = "md", title: n }) => Ga({ uid: e, control: t, items: o.map(({ description: a, icon: i, status: m, title: l }) => ({ description: a, icon: i, title: l, status: m ? hx(m) : void 0 })), margin: r, title: n });
4955
- var hx = (e) => {
4977
+ var ph = (e, { control: t, items: o, margin: r = "md", title: n }) => Ga({ uid: e, control: t, items: o.map(({ description: a, icon: i, status: m, title: l }) => ({ description: a, icon: i, title: l, status: m ? Sx(m) : void 0 })), margin: r, title: n });
4978
+ var Sx = (e) => {
4956
4979
  switch (e) {
4957
4980
  case "positive":
4958
4981
  return "done";
@@ -5023,7 +5046,7 @@ var require_main_min = __commonJS({
5023
5046
  var fh = (e) => e.reduce((t, o) => La(o) ? [...t, o, ...fh(o.getChildren())] : [...t, o], []);
5024
5047
  var Wa = require("react/jsx-runtime");
5025
5048
  var hh = Uy();
5026
- function gx({ localValue: e, step: t, displayStepTitle: o = true, loadingState: r, getErrorMessageFunctions: n, render: a, httpClient: i, trackEvent: m, logEvent: l, triggerSubmission: c, triggerRefresh: p }) {
5049
+ function bx({ localValue: e, step: t, displayStepTitle: o = true, loadingState: r, getErrorMessageFunctions: n, render: a, httpClient: i, trackEvent: m, logEvent: l, triggerSubmission: c, triggerRefresh: p }) {
5027
5050
  var S;
5028
5051
  let [y, f] = (0, tt.useState)(hh), u = (0, tt.useRef)(hh), d = (0, tt.useCallback)((b, w) => {
5029
5052
  w(yh([u.current], b)), f(() => {
@@ -5061,16 +5084,16 @@ var require_main_min = __commonJS({
5061
5084
  m("Step Shown");
5062
5085
  }, [(S = t.id) != null ? S : t.key]), (0, Wa.jsx)(Wa.Fragment, { children: a(y) });
5063
5086
  }
5064
- var gh = gx;
5087
+ var gh = bx;
5065
5088
  var Ch = ({ loadingState: e }, t) => ({ type: "step", loadingState: e, children: t });
5066
5089
  var Sh = ({ context: e, control: t, margin: o, markdown: r }) => ({ type: "alert", context: e, control: t, margin: o, markdown: r });
5067
5090
  var bh = ({ control: e, description: t, help: o, title: r }, n) => ({ type: "form-section", children: n, control: e, description: t, help: o, title: r });
5068
5091
  var Me = (e, t) => {
5069
5092
  var h, S;
5070
- let { autoComplete: o, control: r, description: n, disabled: a, errors: i, help: m, id: l, placeholder: c, required: p, title: y, onBlur: f, onFocus: u } = e, d = Cx(e) ? e.validationState : void 0, { messages: g } = d != null ? d : {};
5093
+ let { autoComplete: o, control: r, description: n, disabled: a, errors: i, help: m, id: l, placeholder: c, required: p, title: y, onBlur: f, onFocus: u } = e, d = wx(e) ? e.validationState : void 0, { messages: g } = d != null ? d : {};
5071
5094
  return { type: t, autoComplete: o, control: r, description: (h = g == null ? void 0 : g.success) != null ? h : n, disabled: a, error: (S = g == null ? void 0 : g.error) != null ? S : i[0], help: m, id: l, label: y, placeholder: c, required: p, value: e.getLocalValue(), onBlur: f.bind(e), onFocus: u.bind(e) };
5072
5095
  };
5073
- var Cx = (e) => !!("validationState" in e && e.validationState);
5096
+ var wx = (e) => !!("validationState" in e && e.validationState);
5074
5097
  var wh = (e) => {
5075
5098
  var t;
5076
5099
  return C(s({}, Me(e, "input-boolean")), { value: (t = e.value) != null ? t : false, onChange: e.onChange.bind(e) });
@@ -5113,10 +5136,10 @@ var require_main_min = __commonJS({
5113
5136
  };
5114
5137
  var Hh = ({ callToAction: e, control: t, fields: o, margin: r, title: n }) => ({ type: "review", callToAction: e, control: t, fields: o, margin: r, title: n });
5115
5138
  var qh = (e) => {
5116
- let { uid: t, control: o, emptyMessage: r, error: n, isLoading: a, margin: i, query: m, results: l, title: c } = e, p = e.onChange.bind(e), y = e.onSelect.bind(e), f = Sx({ emptyMessage: r, error: n, query: m, results: l, onChange: p, onSelect: y });
5139
+ let { uid: t, control: o, emptyMessage: r, error: n, isLoading: a, margin: i, query: m, results: l, title: c } = e, p = e.onChange.bind(e), y = e.onSelect.bind(e), f = Fx({ emptyMessage: r, error: n, query: m, results: l, onChange: p, onSelect: y });
5117
5140
  return { type: "search", id: t, control: o, isLoading: a, margin: i, query: m, state: f, title: c, onChange: p };
5118
5141
  };
5119
- var Sx = ({ emptyMessage: e, error: t, query: o, results: r, onChange: n, onSelect: a }) => o ? t ? { type: "error", onRetry: () => n(o) } : r.length === 0 ? { type: "noResults", message: e } : { type: "results", results: r.map((m) => C(s({}, m), { onClick: () => a(m) })) } : { type: "pending" };
5142
+ var Fx = ({ emptyMessage: e, error: t, query: o, results: r, onChange: n, onSelect: a }) => o ? t ? { type: "error", onRetry: () => n(o) } : r.length === 0 ? { type: "noResults", message: e } : { type: "results", results: r.map((m) => C(s({}, m), { onClick: () => a(m) })) } : { type: "pending" };
5120
5143
  var $h = (e, t) => {
5121
5144
  var l;
5122
5145
  let { options: o, selectedIndex: r, onSelect: n } = e, m = Me(e, "input-select"), { value: a } = m, i = E(m, ["value"]);
@@ -5215,9 +5238,9 @@ var require_main_min = __commonJS({
5215
5238
  };
5216
5239
  var em = require("@transferwise/formatting");
5217
5240
  function Zh(e, t) {
5218
- return (o) => bx(o != null ? o : {}, e, t);
5241
+ return (o) => xx(o != null ? o : {}, e, t);
5219
5242
  }
5220
- var bx = (e, t, o) => ({ minimum(r) {
5243
+ var xx = (e, t, o) => ({ minimum(r) {
5221
5244
  var n;
5222
5245
  return (n = e.minimum) != null ? n : t(ae.minimum, { minimum: r });
5223
5246
  }, maximum(r) {
@@ -5254,9 +5277,9 @@ var require_main_min = __commonJS({
5254
5277
  var r;
5255
5278
  return (r = e.required) != null ? r : t(ae.required);
5256
5279
  }, genericError() {
5257
- return t(ve.genericError);
5280
+ return t(xe.genericError);
5258
5281
  }, genericErrorWithRetry() {
5259
- return t(ve.genericErrorRetryHint);
5282
+ return t(xe.genericErrorRetryHint);
5260
5283
  } });
5261
5284
  var Yh = { timeZone: "UTC", dateStyle: "long" };
5262
5285
  var tm = require("react/jsx-runtime");
@@ -5332,16 +5355,16 @@ var require_main_min = __commonJS({
5332
5355
  L(de, void 0);
5333
5356
  }
5334
5357
  }, [S, r, O, L]), U = (0, he.useMemo)(() => Jh([Ey, ...i, Ty]), [i]);
5335
- return (0, tm.jsx)(Hr, { onError: l, children: d ? (0, tm.jsx)(gh, { displayStepTitle: o, step: d, localValue: h.current, loadingState: F, getErrorMessageFunctions: u, render: U, httpClient: r, trackEvent: O, logEvent: v, triggerSubmission: k, triggerRefresh: q }) : null });
5358
+ return (0, tm.jsx)(Hr, { onError: L, children: d ? (0, tm.jsx)(gh, { displayStepTitle: o, step: d, localValue: h.current, loadingState: F, getErrorMessageFunctions: u, render: U, httpClient: r, trackEvent: O, logEvent: v, triggerSubmission: k, triggerRefresh: q }) : null });
5336
5359
  }
5337
5360
  var om = require("react/jsx-runtime");
5338
- var wx = uy();
5339
- function Fx(e) {
5340
- let { httpClient: t } = e, { locale: o } = (0, og.useIntl)(), r = (0, tg.useMemo)(() => xx(t, o), [t, o]);
5341
- return (0, om.jsx)(Sn, { httpClient: r, children: (0, om.jsx)(eg, C(s({}, e), { renderers: wx })) });
5361
+ var vx = uy();
5362
+ function Px(e) {
5363
+ let { httpClient: t } = e, { locale: o } = (0, og.useIntl)(), r = (0, tg.useMemo)(() => Ix(t, o), [t, o]);
5364
+ return (0, om.jsx)(Sn, { httpClient: r, children: (0, om.jsx)(eg, C(s({}, e), { renderers: vx })) });
5342
5365
  }
5343
- var rg = Fx;
5344
- var xx = (e, t) => async (o, r) => e(o, ui(r, { credentials: "include", headers: { "accept-language": t } }));
5366
+ var rg = Px;
5367
+ var Ix = (e, t) => async (o, r) => e(o, ui(r, { credentials: "include", headers: { "accept-language": t } }));
5345
5368
  }
5346
5369
  });
5347
5370