@wise/dynamic-flow-client-internal 2.2.1 → 2.2.2
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 +731 -732
- package/build/main.min.js +1 -1
- package/package.json +2 -2
package/build/main.js
CHANGED
|
@@ -52,39 +52,39 @@ var require_main_min = __commonJS({
|
|
|
52
52
|
"../core/build/main.min.js"(exports, module2) {
|
|
53
53
|
"use strict";
|
|
54
54
|
var Fl = Object.create;
|
|
55
|
-
var
|
|
55
|
+
var Wt = Object.defineProperty;
|
|
56
56
|
var Cl = Object.defineProperties;
|
|
57
57
|
var xl = Object.getOwnPropertyDescriptor;
|
|
58
58
|
var vl = Object.getOwnPropertyDescriptors;
|
|
59
59
|
var Al = Object.getOwnPropertyNames;
|
|
60
|
-
var
|
|
60
|
+
var ja = Object.getOwnPropertySymbols;
|
|
61
61
|
var Ol = Object.getPrototypeOf;
|
|
62
|
-
var
|
|
62
|
+
var Ua = Object.prototype.hasOwnProperty;
|
|
63
63
|
var Pl = Object.prototype.propertyIsEnumerable;
|
|
64
|
-
var
|
|
64
|
+
var Va = (e, t, r) => t in e ? Wt(e, t, { enumerable: true, configurable: true, writable: true, value: r }) : e[t] = r;
|
|
65
65
|
var i = (e, t) => {
|
|
66
66
|
for (var r in t || (t = {}))
|
|
67
|
-
|
|
68
|
-
if (
|
|
69
|
-
for (var r of
|
|
70
|
-
Pl.call(t, r) &&
|
|
67
|
+
Ua.call(t, r) && Va(e, r, t[r]);
|
|
68
|
+
if (ja)
|
|
69
|
+
for (var r of ja(t))
|
|
70
|
+
Pl.call(t, r) && Va(e, r, t[r]);
|
|
71
71
|
return e;
|
|
72
72
|
};
|
|
73
73
|
var b = (e, t) => Cl(e, vl(t));
|
|
74
|
-
var
|
|
74
|
+
var za = (e, t) => () => (t || e((t = { exports: {} }).exports, t), t.exports);
|
|
75
75
|
var Ml = (e, t) => {
|
|
76
76
|
for (var r in t)
|
|
77
|
-
|
|
77
|
+
Wt(e, r, { get: t[r], enumerable: true });
|
|
78
78
|
};
|
|
79
|
-
var
|
|
79
|
+
var Ha = (e, t, r, o) => {
|
|
80
80
|
if (t && typeof t == "object" || typeof t == "function")
|
|
81
81
|
for (let a of Al(t))
|
|
82
|
-
!
|
|
82
|
+
!Ua.call(e, a) && a !== r && Wt(e, a, { get: () => t[a], enumerable: !(o = xl(t, a)) || o.enumerable });
|
|
83
83
|
return e;
|
|
84
84
|
};
|
|
85
|
-
var qe = (e, t, r) => (r = e != null ? Fl(Ol(e)) : {},
|
|
86
|
-
var kl = (e) =>
|
|
87
|
-
var st =
|
|
85
|
+
var qe = (e, t, r) => (r = e != null ? Fl(Ol(e)) : {}, Ha(t || !e || !e.__esModule ? Wt(r, "default", { value: e, enumerable: true }) : r, e));
|
|
86
|
+
var kl = (e) => Ha(Wt({}, "__esModule", { value: true }), e);
|
|
87
|
+
var st = za((Nf, Tr) => {
|
|
88
88
|
"use strict";
|
|
89
89
|
(function() {
|
|
90
90
|
"use strict";
|
|
@@ -113,16 +113,16 @@ var require_main_min = __commonJS({
|
|
|
113
113
|
}
|
|
114
114
|
return o.join(" ");
|
|
115
115
|
}
|
|
116
|
-
typeof
|
|
116
|
+
typeof Tr != "undefined" && Tr.exports ? (r.default = r, Tr.exports = r) : typeof define == "function" && typeof define.amd == "object" && define.amd ? define("classnames", [], function() {
|
|
117
117
|
return r;
|
|
118
118
|
}) : window.classNames = r;
|
|
119
119
|
})();
|
|
120
120
|
});
|
|
121
|
-
var
|
|
121
|
+
var Qs = za((cr, xa) => {
|
|
122
122
|
"use strict";
|
|
123
123
|
(function(t, r) {
|
|
124
|
-
typeof
|
|
125
|
-
})(
|
|
124
|
+
typeof cr == "object" && typeof xa == "object" ? xa.exports = r(require("react")) : typeof define == "function" && define.amd ? define(["react"], r) : typeof cr == "object" ? cr.Webcam = r(require("react")) : t.Webcam = r(t.React);
|
|
125
|
+
})(cr, function(e) {
|
|
126
126
|
return function(t) {
|
|
127
127
|
var r = {};
|
|
128
128
|
function o(a) {
|
|
@@ -301,8 +301,8 @@ var require_main_min = __commonJS({
|
|
|
301
301
|
y.onUserMedia(p);
|
|
302
302
|
}, f.prototype.render = function() {
|
|
303
303
|
var m = this, p = this, y = p.state, S = p.props, g = S.audio, F = S.forceScreenshotSourceSize, w = S.onUserMedia, A = S.onUserMediaError, O = S.screenshotFormat, x = S.screenshotQuality, M = S.minScreenshotWidth, R = S.minScreenshotHeight, v = S.audioConstraints, T = S.videoConstraints, H = S.imageSmoothing, L = S.mirrored, P = S.style, B = P === void 0 ? {} : P, k = S.children, ne = u(S, ["audio", "forceScreenshotSourceSize", "onUserMedia", "onUserMediaError", "screenshotFormat", "screenshotQuality", "minScreenshotWidth", "minScreenshotHeight", "audioConstraints", "videoConstraints", "imageSmoothing", "mirrored", "style", "children"]), ve = L ? l(l({}, B), { transform: (B.transform || "") + " scaleX(-1)" }) : B, _ = { getScreenshot: this.getScreenshot.bind(this) };
|
|
304
|
-
return a.createElement(a.Fragment, null, a.createElement("video", l({ autoPlay: true, src: y.src, muted: !g, playsInline: true, ref: function(
|
|
305
|
-
m.video =
|
|
304
|
+
return a.createElement(a.Fragment, null, a.createElement("video", l({ autoPlay: true, src: y.src, muted: !g, playsInline: true, ref: function(ue) {
|
|
305
|
+
m.video = ue;
|
|
306
306
|
}, style: ve }, ne)), k && k(_));
|
|
307
307
|
}, f.defaultProps = { audio: false, forceScreenshotSourceSize: false, imageSmoothing: true, mirrored: false, onUserMedia: function() {
|
|
308
308
|
}, onUserMediaError: function() {
|
|
@@ -314,10 +314,10 @@ var require_main_min = __commonJS({
|
|
|
314
314
|
} }).default;
|
|
315
315
|
});
|
|
316
316
|
});
|
|
317
|
-
var
|
|
318
|
-
Ml(
|
|
319
|
-
module2.exports = kl(
|
|
320
|
-
function
|
|
317
|
+
var np = {};
|
|
318
|
+
Ml(np, { DynamicFlow: () => Na, JsonSchemaForm: () => Ra, Layout: () => me, convertStepToLayout: () => _t, inlineReferences: () => Ge, isValidSchema: () => $, makeHttpClient: () => vr, translations: () => yl });
|
|
319
|
+
module2.exports = kl(np);
|
|
320
|
+
function _t(e, { displayStepTitle: t = true } = {}) {
|
|
321
321
|
if (e.layout)
|
|
322
322
|
return ql(e, t);
|
|
323
323
|
switch (e.type) {
|
|
@@ -331,25 +331,25 @@ var require_main_min = __commonJS({
|
|
|
331
331
|
return Dl(e);
|
|
332
332
|
}
|
|
333
333
|
}
|
|
334
|
-
function
|
|
334
|
+
function fo(e) {
|
|
335
335
|
let t = [];
|
|
336
|
-
if (e.title && t.push(
|
|
337
|
-
let r =
|
|
336
|
+
if (e.title && t.push(ho(e.title)), e.image) {
|
|
337
|
+
let r = qa(e.image);
|
|
338
338
|
t.push(r);
|
|
339
339
|
}
|
|
340
|
-
return e.description && t.push(
|
|
340
|
+
return e.description && t.push(go(e.description)), t;
|
|
341
341
|
}
|
|
342
342
|
function El(e) {
|
|
343
|
-
return [...
|
|
343
|
+
return [...fo(e), Il(e)];
|
|
344
344
|
}
|
|
345
345
|
function Il(e) {
|
|
346
346
|
return { type: "external", requestUrl: e.requestUrl, polling: e.polling, responseHandlers: e.responseHandlers, retryTitle: e.retryTitle };
|
|
347
347
|
}
|
|
348
348
|
function Dl(e) {
|
|
349
|
-
let t =
|
|
349
|
+
let t = fo(e);
|
|
350
350
|
if (e.reviewFields && t.push(Vl(e.reviewFields)), e.schemas && t.push(...zl(e)), e.actions) {
|
|
351
|
-
let r = e.actions.map(
|
|
352
|
-
t.push(
|
|
351
|
+
let r = e.actions.map(gr);
|
|
352
|
+
t.push(yo(r, "md"));
|
|
353
353
|
}
|
|
354
354
|
return t;
|
|
355
355
|
}
|
|
@@ -360,25 +360,25 @@ var require_main_min = __commonJS({
|
|
|
360
360
|
let r = jl(e.details.image);
|
|
361
361
|
t.push(r);
|
|
362
362
|
}
|
|
363
|
-
e.details.title && t.push(
|
|
363
|
+
e.details.title && t.push(ho(e.details.title)), e.details.description && t.push(go(e.details.description));
|
|
364
364
|
}
|
|
365
365
|
if (e.actions) {
|
|
366
|
-
let r = e.actions.map((o) =>
|
|
367
|
-
t.push(
|
|
366
|
+
let r = e.actions.map((o) => gr(b(i({}, o), { type: o.type || "primary" })));
|
|
367
|
+
t.push(yo(r, "md"));
|
|
368
368
|
}
|
|
369
369
|
return t;
|
|
370
370
|
}
|
|
371
371
|
function Tl(e) {
|
|
372
|
-
let t =
|
|
372
|
+
let t = fo(e);
|
|
373
373
|
return e.options && t.push(Rl(e.options)), t;
|
|
374
374
|
}
|
|
375
|
-
function
|
|
375
|
+
function yo(e, t) {
|
|
376
376
|
return { type: "box", width: t || "md", components: e };
|
|
377
377
|
}
|
|
378
|
-
function
|
|
378
|
+
function ho(e) {
|
|
379
379
|
return { type: "heading", text: e, size: "lg", margin: "lg", align: "center" };
|
|
380
380
|
}
|
|
381
|
-
function
|
|
381
|
+
function go(e) {
|
|
382
382
|
return { type: "paragraph", text: e, align: "center" };
|
|
383
383
|
}
|
|
384
384
|
function Nl(e) {
|
|
@@ -390,13 +390,13 @@ var require_main_min = __commonJS({
|
|
|
390
390
|
function Bl(e) {
|
|
391
391
|
return { title: e.title, description: e.description, action: { title: e.title, method: "GET", url: e.url, disabled: e.disabled } };
|
|
392
392
|
}
|
|
393
|
-
function
|
|
393
|
+
function qa(e) {
|
|
394
394
|
return { type: "image", url: e.url, text: e.text, margin: e.margin || "lg", size: e.size || "md" };
|
|
395
395
|
}
|
|
396
396
|
function jl(e) {
|
|
397
|
-
return typeof e == "string" ? { type: "image", url: e, text: void 0, margin: "lg", size: "md" } :
|
|
397
|
+
return typeof e == "string" ? { type: "image", url: e, text: void 0, margin: "lg", size: "md" } : qa(e);
|
|
398
398
|
}
|
|
399
|
-
function
|
|
399
|
+
function gr(e) {
|
|
400
400
|
return { type: "button", action: b(i({}, e), { title: e.title }) };
|
|
401
401
|
}
|
|
402
402
|
function Vl(e) {
|
|
@@ -409,7 +409,7 @@ var require_main_min = __commonJS({
|
|
|
409
409
|
let t = [];
|
|
410
410
|
if (e.schemas && e.schemas[0]) {
|
|
411
411
|
let r = e.schemas[0], o = Nl(r);
|
|
412
|
-
Hl() ? t.push(o) : t.push(
|
|
412
|
+
Hl() ? t.push(o) : t.push(yo([o], "md"));
|
|
413
413
|
}
|
|
414
414
|
return t;
|
|
415
415
|
}
|
|
@@ -417,30 +417,30 @@ var require_main_min = __commonJS({
|
|
|
417
417
|
return false;
|
|
418
418
|
}
|
|
419
419
|
function ql(e, t) {
|
|
420
|
-
return [...t && e.title ? [
|
|
420
|
+
return [...t && e.title ? [ho(e.title)] : [], ...e.description ? [go(e.description)] : [], ...e.layout || []];
|
|
421
421
|
}
|
|
422
422
|
function Ge({ layout: e, schemas: t, actions: r, model: o }) {
|
|
423
423
|
return e ? t ? e.map((a) => a.type === "form" ? Gl({ formComponent: a, schemas: t }) : a.type === "decision" ? $l({ decisionComponent: a, actions: r }) : a.type === "button" ? Wl({ actionComponent: a, actions: r }) : a.type === "box" ? _l({ boxComponent: a, schemas: t, actions: r, model: o }) : a.type === "columns" ? Kl({ columnsComponent: a, schemas: t, actions: r, model: o }) : a) : e : [];
|
|
424
424
|
}
|
|
425
425
|
function Gl({ formComponent: e, schemas: t }) {
|
|
426
426
|
if (e.schemaId)
|
|
427
|
-
return { type: "form", margin: e.margin, schema:
|
|
428
|
-
if (e.schema &&
|
|
429
|
-
return { type: "form", margin: e.margin, schema:
|
|
430
|
-
if (e.schema && !
|
|
427
|
+
return { type: "form", margin: e.margin, schema: Ga(t, e.schemaId) };
|
|
428
|
+
if (e.schema && Sr(e.schema) && e.schema.$ref)
|
|
429
|
+
return { type: "form", margin: e.margin, schema: Ga(t, e.schema.$ref) };
|
|
430
|
+
if (e.schema && !Sr(e.schema))
|
|
431
431
|
return i({}, e);
|
|
432
432
|
throw new Error('Invalid form layout component. Missing "schema" or "schemaId" properties.');
|
|
433
433
|
}
|
|
434
434
|
function $l({ decisionComponent: e, actions: t }) {
|
|
435
435
|
var o;
|
|
436
|
-
let r = (o = e == null ? void 0 : e.options) == null ? void 0 : o.map((a) => a.action &&
|
|
436
|
+
let r = (o = e == null ? void 0 : e.options) == null ? void 0 : o.map((a) => a.action && Sr(a.action) ? b(i({}, a), { action: $a(t, a.action.$ref) }) : a);
|
|
437
437
|
return b(i({}, e), { options: r });
|
|
438
438
|
}
|
|
439
439
|
function Wl({ actionComponent: e, actions: t }) {
|
|
440
440
|
var r;
|
|
441
|
-
if (e.action &&
|
|
442
|
-
let o =
|
|
443
|
-
return
|
|
441
|
+
if (e.action && Sr(e.action) && ((r = e.action) != null && r.$ref)) {
|
|
442
|
+
let o = $a(t, e.action.$ref);
|
|
443
|
+
return gr(o);
|
|
444
444
|
}
|
|
445
445
|
return e;
|
|
446
446
|
}
|
|
@@ -450,76 +450,76 @@ var require_main_min = __commonJS({
|
|
|
450
450
|
function Kl({ columnsComponent: e, schemas: t, actions: r, model: o }) {
|
|
451
451
|
return b(i({}, e), { left: Ge({ layout: e.left, schemas: t, actions: r, model: o }), right: Ge({ layout: e.right, schemas: t, actions: r, model: o }) });
|
|
452
452
|
}
|
|
453
|
-
function
|
|
453
|
+
function Ga(e, t) {
|
|
454
454
|
let r = e.find((o) => o.$id === t);
|
|
455
455
|
if (!r)
|
|
456
456
|
throw new Error(`Fatal Error. Schema not found. $id ${t}`);
|
|
457
457
|
return r;
|
|
458
458
|
}
|
|
459
|
-
function
|
|
459
|
+
function $a(e, t) {
|
|
460
460
|
let r = e.find((o) => o.$id === t);
|
|
461
461
|
if (!r)
|
|
462
462
|
throw new Error(`Fatal Error. Action not found. $id ${t}`);
|
|
463
463
|
return r;
|
|
464
464
|
}
|
|
465
|
-
function
|
|
465
|
+
function Sr(e) {
|
|
466
466
|
return Object.prototype.hasOwnProperty.call(e, "$ref");
|
|
467
467
|
}
|
|
468
468
|
var xe = require("react");
|
|
469
|
-
var
|
|
470
|
-
var
|
|
471
|
-
var
|
|
472
|
-
function
|
|
473
|
-
let [e, t] = (0,
|
|
474
|
-
return { addPendingPromise: (0,
|
|
469
|
+
var Zm = require("react-intl");
|
|
470
|
+
var wt = require("react");
|
|
471
|
+
var br = require("react");
|
|
472
|
+
function Wa() {
|
|
473
|
+
let [e, t] = (0, br.useState)(0);
|
|
474
|
+
return { addPendingPromise: (0, br.useCallback)((o) => {
|
|
475
475
|
t((a) => a + 1), o.catch(Xl).finally(() => Jl(() => t((a) => Math.max(0, a - 1))));
|
|
476
476
|
}, [t]), pendingPromises: e };
|
|
477
477
|
}
|
|
478
478
|
var Jl = (e) => setTimeout(() => e(), 0);
|
|
479
479
|
var Xl = () => {
|
|
480
480
|
};
|
|
481
|
-
var
|
|
482
|
-
var
|
|
481
|
+
var Xa = require("react/jsx-runtime");
|
|
482
|
+
var _a = { loading: false, registerPersistAsyncPromise: (e) => {
|
|
483
483
|
} };
|
|
484
|
-
var
|
|
485
|
-
var
|
|
486
|
-
let { pendingPromises: r, addPendingPromise: o } =
|
|
487
|
-
return (0,
|
|
484
|
+
var Ka = (0, wt.createContext)(_a);
|
|
485
|
+
var Ja = ({ loading: e, children: t }) => {
|
|
486
|
+
let { pendingPromises: r, addPendingPromise: o } = Wa(), a = (0, wt.useMemo)(() => ({ loading: e || r > 0, registerPersistAsyncPromise: o }), [e, r, o]);
|
|
487
|
+
return (0, Xa.jsx)(Ka.Provider, { value: a, children: t });
|
|
488
488
|
};
|
|
489
|
-
var
|
|
490
|
-
var
|
|
491
|
-
var
|
|
492
|
-
var
|
|
489
|
+
var wr = () => (0, wt.useContext)(Ka) || _a;
|
|
490
|
+
var Ft = require("react");
|
|
491
|
+
var Za = require("react/jsx-runtime");
|
|
492
|
+
var Ya = (0, Ft.createContext)({ triggerEvent: () => {
|
|
493
493
|
} });
|
|
494
|
-
var
|
|
495
|
-
let o = (0,
|
|
496
|
-
return (0,
|
|
494
|
+
var Fr = ({ metadata: e, children: t, onEvent: r }) => {
|
|
495
|
+
let o = (0, Ft.useMemo)(() => ({ triggerEvent: So(r, e) }), [r, e]);
|
|
496
|
+
return (0, Za.jsx)(Ya.Provider, { value: o, children: t });
|
|
497
497
|
};
|
|
498
498
|
function Q() {
|
|
499
|
-
let { triggerEvent: e } = (0,
|
|
499
|
+
let { triggerEvent: e } = (0, Ft.useContext)(Ya);
|
|
500
500
|
return e;
|
|
501
501
|
}
|
|
502
|
-
var
|
|
502
|
+
var So = (e, t) => (r, o = {}) => {
|
|
503
503
|
try {
|
|
504
504
|
e(r, i(i({}, t), o));
|
|
505
505
|
} catch (a) {
|
|
506
506
|
}
|
|
507
507
|
};
|
|
508
508
|
var ot = require("react");
|
|
509
|
-
function
|
|
509
|
+
function Qa(e) {
|
|
510
510
|
return e >= 200 && e < 300;
|
|
511
511
|
}
|
|
512
|
-
function
|
|
512
|
+
function Cr(e) {
|
|
513
513
|
return e === 422;
|
|
514
514
|
}
|
|
515
|
-
function
|
|
515
|
+
function xr(e = "") {
|
|
516
516
|
return ["https://", "http://", "data:"].some((t) => e.slice(0, t.length) === t && e.length > t.length) === false;
|
|
517
517
|
}
|
|
518
|
-
var
|
|
518
|
+
var vr = (e, t) => (r, o) => {
|
|
519
519
|
let a = Yl(r, e || ""), n = Zl(o == null ? void 0 : o.headers, t);
|
|
520
520
|
return fetch(a, b(i({}, o || {}), { headers: n }));
|
|
521
521
|
};
|
|
522
|
-
var Yl = (e, t) => typeof e == "string" &&
|
|
522
|
+
var Yl = (e, t) => typeof e == "string" && xr(e) ? t + e : e;
|
|
523
523
|
var Zl = (e, t) => {
|
|
524
524
|
if (!e && !t)
|
|
525
525
|
return {};
|
|
@@ -528,16 +528,16 @@ var require_main_min = __commonJS({
|
|
|
528
528
|
r.set(o, a);
|
|
529
529
|
return r;
|
|
530
530
|
};
|
|
531
|
-
var
|
|
532
|
-
var
|
|
533
|
-
var
|
|
534
|
-
var
|
|
535
|
-
let r = (0, ot.useMemo)(() =>
|
|
536
|
-
return (0,
|
|
531
|
+
var bo = require("react/jsx-runtime");
|
|
532
|
+
var Ar = (0, ot.createContext)(void 0);
|
|
533
|
+
var en = ({ httpClient: e, children: t }) => (0, bo.jsx)(Ar.Provider, { value: e, children: t });
|
|
534
|
+
var Or = ({ baseUrl: e, children: t }) => {
|
|
535
|
+
let r = (0, ot.useMemo)(() => vr(e), [e]);
|
|
536
|
+
return (0, bo.jsx)(Ar.Provider, { value: r, children: t });
|
|
537
537
|
};
|
|
538
|
-
var te = () => (0, ot.useContext)(
|
|
539
|
-
var
|
|
540
|
-
var
|
|
538
|
+
var te = () => (0, ot.useContext)(Ar) || fetch;
|
|
539
|
+
var tn = () => !!(0, ot.useContext)(Ar);
|
|
540
|
+
var Ct = require("react");
|
|
541
541
|
var on = require("react/jsx-runtime");
|
|
542
542
|
var at = (e, t, r = "UNKNOWN-FLOW-ID", o = "UNKNOWN-FLOW-ID") => (a, n, s) => {
|
|
543
543
|
try {
|
|
@@ -545,13 +545,13 @@ var require_main_min = __commonJS({
|
|
|
545
545
|
} catch (l) {
|
|
546
546
|
}
|
|
547
547
|
};
|
|
548
|
-
var rn = (0,
|
|
549
|
-
var
|
|
550
|
-
let a = (0,
|
|
548
|
+
var rn = (0, Ct.createContext)(null);
|
|
549
|
+
var Pr = ({ flowId: e, stepId: t, children: r, onLog: o }) => {
|
|
550
|
+
let a = (0, Ct.useMemo)(() => ({ debug: at("debug", o, e, t), info: at("info", o, e, t), warning: at("warning", o, e, t), error: at("error", o, e, t), critical: at("critical", o, e, t) }), [o, e, t]);
|
|
551
551
|
return (0, on.jsx)(rn.Provider, { value: a, children: r });
|
|
552
552
|
};
|
|
553
|
-
var
|
|
554
|
-
let e = (0,
|
|
553
|
+
var xt = () => {
|
|
554
|
+
let e = (0, Ct.useContext)(rn);
|
|
555
555
|
if (e == null)
|
|
556
556
|
throw new Error("Logging context not found. Did you forget to wrap your component in a <LogProvider />?");
|
|
557
557
|
return e;
|
|
@@ -564,7 +564,7 @@ var require_main_min = __commonJS({
|
|
|
564
564
|
var q = (e) => Array.isArray(e);
|
|
565
565
|
var E = (e) => e === null;
|
|
566
566
|
var X = (e) => typeof e == "undefined";
|
|
567
|
-
var
|
|
567
|
+
var vt = (e) => I(e) && e.length === 0 || (N(e) || q(e)) && Object.keys(e).length === 0;
|
|
568
568
|
function nn(e, t) {
|
|
569
569
|
return t.oneOf.some((r) => $e(e, r) === e) ? e : null;
|
|
570
570
|
}
|
|
@@ -574,10 +574,10 @@ var require_main_min = __commonJS({
|
|
|
574
574
|
return r.length === 0 ? null : (o = r.find((a) => a.some((n) => n !== null))) != null ? o : r[0];
|
|
575
575
|
}
|
|
576
576
|
function Ql(e, t) {
|
|
577
|
-
return !Le(t) || !Oe(t) ? null :
|
|
577
|
+
return !Le(t) || !Oe(t) ? null : wo(e, t);
|
|
578
578
|
}
|
|
579
579
|
function mn(e) {
|
|
580
|
-
return I(e) && !
|
|
580
|
+
return I(e) && !vt(e) ? e : null;
|
|
581
581
|
}
|
|
582
582
|
function ln(e) {
|
|
583
583
|
return V(e) ? e : null;
|
|
@@ -585,7 +585,7 @@ var require_main_min = __commonJS({
|
|
|
585
585
|
function cn(e) {
|
|
586
586
|
return Ae(e) ? e : null;
|
|
587
587
|
}
|
|
588
|
-
function
|
|
588
|
+
function wo(e, t) {
|
|
589
589
|
if (!q(e) || !Oe(t))
|
|
590
590
|
return null;
|
|
591
591
|
if (e.length > 0) {
|
|
@@ -593,12 +593,12 @@ var require_main_min = __commonJS({
|
|
|
593
593
|
if (!e.every((o) => typeof o === r))
|
|
594
594
|
return new Array(e.length).fill(null);
|
|
595
595
|
}
|
|
596
|
-
return e.map((r) =>
|
|
596
|
+
return e.map((r) => At(r, t.items));
|
|
597
597
|
}
|
|
598
598
|
function dn(e, t) {
|
|
599
599
|
return Object.keys(t.properties).reduce((r, o) => {
|
|
600
600
|
if (e && !X(e[o])) {
|
|
601
|
-
let a = e[o], n = t.properties[o], s =
|
|
601
|
+
let a = e[o], n = t.properties[o], s = At(a, n);
|
|
602
602
|
if (!E(s))
|
|
603
603
|
return b(i({}, r), { [o]: s });
|
|
604
604
|
}
|
|
@@ -620,7 +620,7 @@ var require_main_min = __commonJS({
|
|
|
620
620
|
return W(a) && W(n) ? b(i({}, r), { [o]: fn(a, n) }) : b(i({}, r), { [o]: t[o] });
|
|
621
621
|
}, i({}, e));
|
|
622
622
|
}
|
|
623
|
-
var
|
|
623
|
+
var At = (e, t) => W(e) ? ie(e, t) : Fo(e) ? ec(e, t) : $e(e, t);
|
|
624
624
|
function $e(e, t) {
|
|
625
625
|
if (E(e))
|
|
626
626
|
return null;
|
|
@@ -646,9 +646,9 @@ var require_main_min = __commonJS({
|
|
|
646
646
|
return Te(t) || Le(t) || E(e) ? null : t.allOf ? un(e, t) : t.oneOf ? pn(e, t) : !X(t.const) && e === t.const ? e : Pe(t) ? dn(e, t) : null;
|
|
647
647
|
}
|
|
648
648
|
function ec(e, t) {
|
|
649
|
-
return fe(t) ? sn(e, t) : Le(t) ?
|
|
649
|
+
return fe(t) ? sn(e, t) : Le(t) ? wo(e, t) : null;
|
|
650
650
|
}
|
|
651
|
-
function
|
|
651
|
+
function Kt(e, t = false) {
|
|
652
652
|
return !t || !X(e);
|
|
653
653
|
}
|
|
654
654
|
function yn(e, t = false) {
|
|
@@ -663,10 +663,10 @@ var require_main_min = __commonJS({
|
|
|
663
663
|
function Sn(e, t) {
|
|
664
664
|
return t === void 0 ? true : e == null ? false : !!new RegExp(t).test(e);
|
|
665
665
|
}
|
|
666
|
-
function
|
|
666
|
+
function Co(e, t) {
|
|
667
667
|
return !V(t) && !I(t) || (V(e) || I(e)) && e <= t;
|
|
668
668
|
}
|
|
669
|
-
function
|
|
669
|
+
function xo(e, t) {
|
|
670
670
|
return !V(t) && !I(t) || (V(e) || I(e)) && e >= t;
|
|
671
671
|
}
|
|
672
672
|
function bn(e, t) {
|
|
@@ -677,53 +677,53 @@ var require_main_min = __commonJS({
|
|
|
677
677
|
}
|
|
678
678
|
function We(e, t, r) {
|
|
679
679
|
if (t.const)
|
|
680
|
-
return
|
|
680
|
+
return Po(e, t, r);
|
|
681
681
|
if (E(e))
|
|
682
682
|
return r ? ["required"] : [];
|
|
683
683
|
if (Cn(t))
|
|
684
|
-
return
|
|
684
|
+
return vo(e, t, r);
|
|
685
685
|
switch (t.type) {
|
|
686
686
|
case "number":
|
|
687
|
-
return
|
|
687
|
+
return Mr(e, t, r);
|
|
688
688
|
case "integer":
|
|
689
|
-
return
|
|
689
|
+
return Ao(e, t, r);
|
|
690
690
|
case "boolean":
|
|
691
|
-
return
|
|
691
|
+
return Oo(e, t, r);
|
|
692
692
|
case "array":
|
|
693
|
-
return
|
|
693
|
+
return Ot(e, t, r);
|
|
694
694
|
case "object":
|
|
695
695
|
return tc(e, t);
|
|
696
696
|
default:
|
|
697
697
|
return [];
|
|
698
698
|
}
|
|
699
699
|
}
|
|
700
|
-
function
|
|
700
|
+
function vo(e, t, r) {
|
|
701
701
|
if (!I(e) && !E(e))
|
|
702
702
|
return ["type"];
|
|
703
703
|
if (e === "" && r)
|
|
704
704
|
return ["required"];
|
|
705
705
|
let o = [];
|
|
706
|
-
return
|
|
706
|
+
return Kt(e, r) || o.push("required"), hn(e, t.minLength) || o.push("minLength"), gn(e, t.maxLength) || o.push("maxLength"), Sn(e, t.pattern) || o.push("pattern"), xo(e, t.minimum) || o.push("minimum"), Co(e, t.maximum) || o.push("maximum"), o;
|
|
707
707
|
}
|
|
708
|
-
function
|
|
708
|
+
function Mr(e, t, r) {
|
|
709
709
|
if (!V(e) && !E(e))
|
|
710
710
|
return ["type"];
|
|
711
711
|
let o = [];
|
|
712
|
-
return
|
|
712
|
+
return Kt(e, r) || o.push("required"), xo(e, t.minimum) || o.push("minimum"), Co(e, t.maximum) || o.push("maximum"), o;
|
|
713
713
|
}
|
|
714
|
-
function
|
|
715
|
-
return an(e) ?
|
|
714
|
+
function Ao(e, t, r) {
|
|
715
|
+
return an(e) ? Mr(e, t, r) : ["type"];
|
|
716
716
|
}
|
|
717
|
-
function
|
|
717
|
+
function Oo(e, t, r) {
|
|
718
718
|
if (!Ae(e) && !E(e))
|
|
719
719
|
return ["type"];
|
|
720
720
|
let o = [];
|
|
721
|
-
return
|
|
721
|
+
return Kt(e, r) || o.push("required"), o;
|
|
722
722
|
}
|
|
723
|
-
function
|
|
724
|
-
return
|
|
723
|
+
function Po(e, t, r) {
|
|
724
|
+
return Kt(e, r) ? e !== t.const ? ["const"] : [] : ["required"];
|
|
725
725
|
}
|
|
726
|
-
function
|
|
726
|
+
function Ot(e, t, r) {
|
|
727
727
|
if (!q(e) && !E(e))
|
|
728
728
|
return ["type"];
|
|
729
729
|
if (!yn(e, r))
|
|
@@ -738,19 +738,19 @@ var require_main_min = __commonJS({
|
|
|
738
738
|
return W(e) ? q(t.required) ? t.required.map((o) => typeof e[o] != "undefined").reduce((o, a) => o && a, true) ? [] : ["required"] : [] : ["type"];
|
|
739
739
|
}
|
|
740
740
|
function rc(e, t) {
|
|
741
|
-
return !
|
|
741
|
+
return !vo(e, t).length;
|
|
742
742
|
}
|
|
743
743
|
function oc(e, t) {
|
|
744
|
-
return !
|
|
744
|
+
return !Mr(e, t).length;
|
|
745
745
|
}
|
|
746
746
|
function ac(e, t) {
|
|
747
|
-
return !
|
|
747
|
+
return !Ao(e, t).length;
|
|
748
748
|
}
|
|
749
749
|
function nc(e, t) {
|
|
750
|
-
return !
|
|
750
|
+
return !Oo(e, t).length;
|
|
751
751
|
}
|
|
752
752
|
function ic(e, t) {
|
|
753
|
-
return !
|
|
753
|
+
return !Po(e, t).length;
|
|
754
754
|
}
|
|
755
755
|
function sc(e, t) {
|
|
756
756
|
return !N(e) || t.type !== "object" || !N(t.properties) ? false : Object.keys(t.properties).map((r) => mc(e[r], t.properties[r], t.required && t.required.includes(r))).every((r) => r);
|
|
@@ -759,7 +759,7 @@ var require_main_min = __commonJS({
|
|
|
759
759
|
return t.hidden ? true : typeof e == "undefined" ? !r : $(e, t);
|
|
760
760
|
}
|
|
761
761
|
function lc(e, t) {
|
|
762
|
-
return t.type !== "array" || !N(t.items) ||
|
|
762
|
+
return t.type !== "array" || !N(t.items) || Ot(e, t).length > 0 ? false : Array.isArray(e) && Oe(t) && e.map((r) => $(r, t.items)).every((r) => r);
|
|
763
763
|
}
|
|
764
764
|
function cc(e, t) {
|
|
765
765
|
return q(t.oneOf) ? t.oneOf.some((r) => $(e, r)) : false;
|
|
@@ -827,7 +827,7 @@ var require_main_min = __commonJS({
|
|
|
827
827
|
return r.length === o.length && r.every((a) => Object.prototype.hasOwnProperty.call(t, a) && Ke(e[a], t[a]));
|
|
828
828
|
};
|
|
829
829
|
var An = (e) => typeof e == "object" && e !== null;
|
|
830
|
-
function
|
|
830
|
+
function kr(e) {
|
|
831
831
|
return Math.floor(e / 1024);
|
|
832
832
|
}
|
|
833
833
|
var On = (e) => new Promise((t, r) => {
|
|
@@ -847,7 +847,7 @@ var require_main_min = __commonJS({
|
|
|
847
847
|
function ye(e) {
|
|
848
848
|
return !X(e == null ? void 0 : e.const);
|
|
849
849
|
}
|
|
850
|
-
function
|
|
850
|
+
function Jt(e) {
|
|
851
851
|
return !!e && !ye(e);
|
|
852
852
|
}
|
|
853
853
|
var yc = (e) => !!e.readOnly && Te(e);
|
|
@@ -865,10 +865,10 @@ var require_main_min = __commonJS({
|
|
|
865
865
|
function fe(e) {
|
|
866
866
|
return !!e.oneOf;
|
|
867
867
|
}
|
|
868
|
-
function
|
|
868
|
+
function Mo(e) {
|
|
869
869
|
return !!e.allOf;
|
|
870
870
|
}
|
|
871
|
-
function
|
|
871
|
+
function Pt(e) {
|
|
872
872
|
return e.type === "blob";
|
|
873
873
|
}
|
|
874
874
|
function Le(e) {
|
|
@@ -881,13 +881,13 @@ var require_main_min = __commonJS({
|
|
|
881
881
|
function Cn(e) {
|
|
882
882
|
return e.type === "string";
|
|
883
883
|
}
|
|
884
|
-
function
|
|
884
|
+
function Er(e) {
|
|
885
885
|
return !!e.persistAsync;
|
|
886
886
|
}
|
|
887
887
|
function Sc(e) {
|
|
888
|
-
return
|
|
888
|
+
return Er(e) && (Pt(e.persistAsync.schema) || bc(e.persistAsync.schema));
|
|
889
889
|
}
|
|
890
|
-
var
|
|
890
|
+
var ko = (e) => Te(e) && !!e.validationAsync;
|
|
891
891
|
function bc(e) {
|
|
892
892
|
return e.type === "string" && e.format === "base64url";
|
|
893
893
|
}
|
|
@@ -895,7 +895,7 @@ var require_main_min = __commonJS({
|
|
|
895
895
|
return e.type === "string" && e.format === "base64url";
|
|
896
896
|
}
|
|
897
897
|
var kn = (e) => Le(e) && Oe(e) && Sc(e.items);
|
|
898
|
-
var it = (e) => yc(e) ? "readOnly" :
|
|
898
|
+
var it = (e) => yc(e) ? "readOnly" : Er(e) ? "persistAsync" : ko(e) ? "validationAsync" : Pe(e) ? "object" : Le(e) ? "array" : hc(e) ? "promotedOneOf" : fe(e) ? "oneOf" : Mo(e) ? "allOf" : Te(e) ? "basic" : null;
|
|
899
899
|
var En = (e) => wc(e) && Fc(e) && Cc(e);
|
|
900
900
|
var wc = (e) => !e.type || e.type === "form";
|
|
901
901
|
var Fc = (e) => {
|
|
@@ -905,7 +905,7 @@ var require_main_min = __commonJS({
|
|
|
905
905
|
var Cc = (e) => {
|
|
906
906
|
if (!e.schemas)
|
|
907
907
|
return false;
|
|
908
|
-
let t =
|
|
908
|
+
let t = Ir(e.schemas);
|
|
909
909
|
if ((t == null ? void 0 : t.length) !== 1)
|
|
910
910
|
return false;
|
|
911
911
|
let r = t[0];
|
|
@@ -914,28 +914,28 @@ var require_main_min = __commonJS({
|
|
|
914
914
|
let o = Object.values(r.properties)[0];
|
|
915
915
|
return Mn(o) ? o.source === "camera" : false;
|
|
916
916
|
};
|
|
917
|
-
var
|
|
917
|
+
var Ir = (e) => e.filter((t) => Pe(t) ? Object.values((t == null ? void 0 : t.properties) || {}).find((r) => (r == null ? void 0 : r.hidden) !== true) : (t == null ? void 0 : t.hidden) !== true);
|
|
918
918
|
var W = (e) => typeof e == "object" && e !== null && e.constructor === Object;
|
|
919
|
-
var
|
|
920
|
-
var
|
|
921
|
-
var
|
|
922
|
-
var
|
|
923
|
-
var In = (e) => E(e) ? true :
|
|
924
|
-
var
|
|
919
|
+
var Eo = (e) => E(e) || W(e);
|
|
920
|
+
var Io = (e) => Ae(e) || V(e) || I(e) || E(e);
|
|
921
|
+
var Dr = (e) => I(e) || E(e);
|
|
922
|
+
var Fo = (e) => q(e) ? e.length === 0 ? true : e.every((t) => typeof t == "string" || typeof t == "number" || typeof t == "boolean" || typeof t == "object") : false;
|
|
923
|
+
var In = (e) => E(e) ? true : Fo(e);
|
|
924
|
+
var Xt = (e) => I(e) || E(e);
|
|
925
925
|
var Dn = require("react");
|
|
926
926
|
function Ln(e, t) {
|
|
927
927
|
return (0, Dn.useCallback)(_e(e, t), [e, t]);
|
|
928
928
|
}
|
|
929
|
-
var
|
|
929
|
+
var Yt = require("react");
|
|
930
930
|
function Tn(e) {
|
|
931
|
-
let [t, r] = (0,
|
|
932
|
-
return (0,
|
|
931
|
+
let [t, r] = (0, Yt.useState)(null), [o, a] = (0, Yt.useState)(false), n = () => a(true);
|
|
932
|
+
return (0, Yt.useEffect)(() => {
|
|
933
933
|
e && (a(false), r(window.open(e, "_blank")));
|
|
934
934
|
}, [e]), { requiresManualTrigger: !!(e && !t && !o), dismissConfirmation: n };
|
|
935
935
|
}
|
|
936
|
-
var
|
|
936
|
+
var Zt = require("react");
|
|
937
937
|
function Nn(e, t) {
|
|
938
|
-
let r = te(), o = (0,
|
|
938
|
+
let r = te(), o = (0, Zt.useMemo)(() => {
|
|
939
939
|
if (e)
|
|
940
940
|
return () => r(e.url).then((n) => {
|
|
941
941
|
if (n.ok)
|
|
@@ -947,7 +947,7 @@ var require_main_min = __commonJS({
|
|
|
947
947
|
else
|
|
948
948
|
throw new Error("failed");
|
|
949
949
|
});
|
|
950
|
-
}, [e, r]), a = (0,
|
|
950
|
+
}, [e, r]), a = (0, Zt.useCallback)((n) => {
|
|
951
951
|
let l = ((e == null ? void 0 : e.responseHandlers) || []).find((u) => u.result === n.result);
|
|
952
952
|
if (l != null && l.action) {
|
|
953
953
|
let { action: u } = l;
|
|
@@ -962,30 +962,30 @@ var require_main_min = __commonJS({
|
|
|
962
962
|
}
|
|
963
963
|
return true;
|
|
964
964
|
}, [e == null ? void 0 : e.responseHandlers, t]);
|
|
965
|
-
|
|
965
|
+
Lr({ asyncFn: o, interval: (e == null ? void 0 : e.interval) || 0, maxAttempts: (e == null ? void 0 : e.maxAttempts) || 0, maxConsecutiveFails: (e == null ? void 0 : e.maxConsecutiveFails) || 0, onPollingResponse: a, onFailure: (0, Zt.useCallback)(() => {
|
|
966
966
|
e && t(e.onError.action);
|
|
967
967
|
}, [t, e]) });
|
|
968
968
|
}
|
|
969
|
-
var
|
|
970
|
-
var
|
|
969
|
+
var Js = require("react");
|
|
970
|
+
var Xs = require("react-intl");
|
|
971
971
|
var Rn = require("react-intl");
|
|
972
|
-
var
|
|
973
|
-
var
|
|
974
|
-
var
|
|
972
|
+
var Qt = (0, Rn.defineMessages)({ genericError: { id: "dynamicFlows.PersistAsyncSchema.genericError", defaultMessage: "Something went wrong, please try again later!", description: "Generic error message for persist async schema" } });
|
|
973
|
+
var St = require("react");
|
|
974
|
+
var Gs = require("react-intl");
|
|
975
975
|
var Bn = { DAY_MONTH_YEAR: "day-month-year", MONTH_YEAR: "month-year" };
|
|
976
976
|
var U = { RADIO: "radio", CHECKBOX: "checkbox", SELECT: "select", FILE: "file", DATE: "date", DATETIME: "date-time", DATELOOKUP: "date-lookup", TEL: "tel", NUMBER: "number", HIDDEN: "hidden", PASSWORD: "password", TEXT: "text", TEXTAREA: "textarea", UPLOAD: "upload", TAB: "tab" };
|
|
977
977
|
var jn = { SHORT: "short", LONG: "long" };
|
|
978
978
|
var Vn = { EXTRA_SMALL: "xs", SMALL: "sm", MEDIUM: "md", LARGE: "lg", EXTRA_LARGE: "xl" };
|
|
979
|
-
var
|
|
980
|
-
var
|
|
979
|
+
var Hs = qe(st());
|
|
980
|
+
var ce = require("react");
|
|
981
981
|
var Wn = require("@transferwise/components");
|
|
982
|
-
var
|
|
982
|
+
var kt = require("@transferwise/components");
|
|
983
983
|
var zn = require("react/jsx-runtime");
|
|
984
|
-
var
|
|
984
|
+
var Mt = (e) => xc(e) || vc(e);
|
|
985
985
|
var xc = (e) => Ac.some((t) => e === `flag-${t}`);
|
|
986
986
|
var vc = (e) => Oc.some((t) => e === `flag-${t}`);
|
|
987
987
|
var Un = ({ name: e }) => {
|
|
988
|
-
if (!
|
|
988
|
+
if (!Mt(e))
|
|
989
989
|
return null;
|
|
990
990
|
let t = e.substring(5);
|
|
991
991
|
return (0, zn.jsx)("img", { src: `https://wise.com/web-art/assets/flags/${t}.svg`, alt: "", "data-testid": `img-flag-${t}` });
|
|
@@ -994,12 +994,12 @@ var require_main_min = __commonJS({
|
|
|
994
994
|
var Oc = ["ad", "ae", "ar", "at", "au", "bd", "be", "bg", "bh", "bn", "br", "bw", "ca", "ch", "cl", "cn", "co", "cr", "cy", "cz", "de", "dk", "ee", "eg", "es", "eu", "fi", "fj", "fr", "gb", "ge", "gg", "gh", "gp", "gr", "gt", "hk", "hr", "hu", "id", "ie", "il", "im", "in", "is", "it", "je", "jm", "jp", "ke", "kr", "kw", "la", "li", "lk", "ls", "lt", "lu", "lv", "ma", "mc", "mt", "mu", "mx", "my", "mz", "na", "ng", "nl", "no", "np", "nz", "om", "pa", "pe", "ph", "pk", "pl", "pt", "qa", "ro", "ru", "sa", "se", "sg", "si", "sk", "sm", "th", "tm", "tr", "tw", "tz", "ua", "ug", "us", "uy", "va", "vn", "wi", "xo", "za", "zm"];
|
|
995
995
|
var Hn = qe(require("@transferwise/icons"));
|
|
996
996
|
var $n = require("react/jsx-runtime");
|
|
997
|
-
var
|
|
997
|
+
var Nr = (e) => {
|
|
998
998
|
let t = Gn(e);
|
|
999
999
|
return Object.keys(Hn).includes(t);
|
|
1000
1000
|
};
|
|
1001
1001
|
var qn = ({ name: e }) => {
|
|
1002
|
-
if (!
|
|
1002
|
+
if (!Nr(e))
|
|
1003
1003
|
return null;
|
|
1004
1004
|
let t = Gn(e), r = Hn[t];
|
|
1005
1005
|
return (0, $n.jsx)(r, { size: 24 });
|
|
@@ -1009,21 +1009,21 @@ var require_main_min = __commonJS({
|
|
|
1009
1009
|
var t;
|
|
1010
1010
|
return `${(t = e[0]) == null ? void 0 : t.toUpperCase()}${e.slice(1)}`;
|
|
1011
1011
|
};
|
|
1012
|
-
var
|
|
1013
|
-
var Mc = ({ type: e }) =>
|
|
1014
|
-
function
|
|
1015
|
-
return
|
|
1012
|
+
var Do = require("react/jsx-runtime");
|
|
1013
|
+
var Mc = ({ type: e }) => Mt(e) ? (0, Do.jsx)(Un, { name: e }) : Nr(e) ? (0, Do.jsx)(qn, { name: e }) : null;
|
|
1014
|
+
function Lo(e) {
|
|
1015
|
+
return Nr(e) || Mt(e);
|
|
1016
1016
|
}
|
|
1017
1017
|
var Je = Mc;
|
|
1018
|
-
var
|
|
1018
|
+
var er = require("react/jsx-runtime");
|
|
1019
1019
|
var mt = ({ icon: e, image: t }) => {
|
|
1020
1020
|
if (e != null && e.name)
|
|
1021
|
-
return (0,
|
|
1021
|
+
return (0, er.jsx)(kt.Avatar, { type: kt.AvatarType.ICON, children: (0, er.jsx)(Je, { type: e.name }) });
|
|
1022
1022
|
if (e != null && e.text)
|
|
1023
|
-
return (0,
|
|
1023
|
+
return (0, er.jsx)(kt.Avatar, { type: kt.AvatarType.INITIALS, children: e.text });
|
|
1024
1024
|
if (t != null && t.url) {
|
|
1025
1025
|
let { url: r, text: o } = t;
|
|
1026
|
-
return (0,
|
|
1026
|
+
return (0, er.jsx)("img", { src: r, alt: o });
|
|
1027
1027
|
}
|
|
1028
1028
|
return null;
|
|
1029
1029
|
};
|
|
@@ -1098,7 +1098,7 @@ var require_main_min = __commonJS({
|
|
|
1098
1098
|
return " col-xs-12";
|
|
1099
1099
|
}
|
|
1100
1100
|
};
|
|
1101
|
-
var
|
|
1101
|
+
var To = Lc;
|
|
1102
1102
|
var Zn = require("@transferwise/components");
|
|
1103
1103
|
var Nc = { primary: "primary", secondary: "secondary", link: "tertiary", positive: "primary", negative: "primary" };
|
|
1104
1104
|
var Jn = (e) => {
|
|
@@ -1128,42 +1128,42 @@ var require_main_min = __commonJS({
|
|
|
1128
1128
|
var Qn = require("react/jsx-runtime");
|
|
1129
1129
|
var Bc = (e) => {
|
|
1130
1130
|
var u;
|
|
1131
|
-
let { component: t, onAction: r } = e, o = t.action, a = Xn(t), n = Jn(t), { loading: s } =
|
|
1131
|
+
let { component: t, onAction: r } = e, o = t.action, a = Xn(t), n = Jn(t), { loading: s } = wr(), l = j(t.margin || "md");
|
|
1132
1132
|
return (0, Qn.jsx)(Zn.Button, { size: Yn(t.size), type: a, priority: n, block: true, className: l, disabled: t.disabled || o.disabled || s, onClick: () => r(o), children: (u = t.title) != null ? u : o.title });
|
|
1133
1133
|
};
|
|
1134
|
-
var
|
|
1134
|
+
var No = Bc;
|
|
1135
1135
|
var ct = require("react/jsx-runtime");
|
|
1136
1136
|
var jc = (e) => {
|
|
1137
1137
|
let t = e.component, { leftWidth: r, rightWidth: o } = Vc(t.bias);
|
|
1138
1138
|
return (0, ct.jsxs)("div", { className: `${j(t.margin || "xs")} row`, children: [(0, ct.jsx)("div", { className: `${r} m-b-0`, children: (0, ct.jsx)(me, { components: t.left, model: e.model, submitted: e.submitted, errors: e.errors, onModelChange: e.onModelChange, onAction: e.onAction, onPersistAsync: e.onPersistAsync }) }), (0, ct.jsx)("div", { className: `${o} m-b-0`, children: (0, ct.jsx)(me, { components: t.right, model: e.model, submitted: e.submitted, errors: e.errors, onModelChange: e.onModelChange, onAction: e.onAction, onPersistAsync: e.onPersistAsync }) })] });
|
|
1139
1139
|
};
|
|
1140
1140
|
var Vc = (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" };
|
|
1141
|
-
var
|
|
1142
|
-
var
|
|
1143
|
-
var
|
|
1144
|
-
var Uc = ({ component: e, onAction: t }) => (0,
|
|
1145
|
-
var
|
|
1141
|
+
var Ro = jc;
|
|
1142
|
+
var Br = require("@transferwise/components");
|
|
1143
|
+
var Rr = require("react/jsx-runtime");
|
|
1144
|
+
var Uc = ({ component: e, onAction: t }) => (0, Rr.jsx)("div", { className: j(e.margin), children: (0, Rr.jsx)(Br.NavigationOptionsList, { children: e.options.map((r) => (0, Rr.jsx)(Br.NavigationOption, { title: r.title, content: r.description, disabled: r.disabled, media: mt(r), showMediaCircle: false, showMediaAtAllSizes: true, onClick: () => t(r.action) }, JSON.stringify(r))) }) });
|
|
1145
|
+
var Bo = Uc;
|
|
1146
1146
|
var ei = require("react/jsx-runtime");
|
|
1147
1147
|
var zc = ({ component: e }) => {
|
|
1148
1148
|
let r = `m-t-0 ${j(e.margin)}`;
|
|
1149
1149
|
return (0, ei.jsx)("hr", { className: r });
|
|
1150
1150
|
};
|
|
1151
|
-
var
|
|
1152
|
-
var
|
|
1153
|
-
var
|
|
1151
|
+
var jo = zc;
|
|
1152
|
+
var Et = require("@transferwise/components");
|
|
1153
|
+
var jr = require("react");
|
|
1154
1154
|
var oi = require("react-intl");
|
|
1155
1155
|
var ti = require("react-intl");
|
|
1156
1156
|
var ri = (0, ti.defineMessages)({ retryTitle: { id: "dynamicFlows.DynamicExternal.retryTitle", defaultMessage: "Reopen window", description: "" } });
|
|
1157
1157
|
var Xe = require("react/jsx-runtime");
|
|
1158
1158
|
var Hc = ({ component: e, onAction: t }) => {
|
|
1159
|
-
let { requestUrl: r, responseHandlers: o, polling: a, retryTitle: n } = e, s = (0, oi.useIntl)(), l = (0,
|
|
1160
|
-
(0,
|
|
1159
|
+
let { requestUrl: r, responseHandlers: o, polling: a, retryTitle: n } = e, s = (0, oi.useIntl)(), l = (0, jr.useCallback)(() => window.open(r, "df-external-window"), [r]);
|
|
1160
|
+
(0, jr.useEffect)(() => {
|
|
1161
1161
|
l();
|
|
1162
1162
|
}, [l]);
|
|
1163
1163
|
let u = a && o ? b(i({}, a), { responseHandlers: o }) : void 0;
|
|
1164
|
-
return Nn(u, t), (0, Xe.jsxs)(Xe.Fragment, { children: [(0, Xe.jsx)(
|
|
1164
|
+
return Nn(u, t), (0, Xe.jsxs)(Xe.Fragment, { children: [(0, Xe.jsx)(Et.Loader, { size: Et.Size.LARGE, classNames: { "tw-loader": "tw-loader m-x-auto" } }), (0, Xe.jsx)("br", {}), (0, Xe.jsx)(Et.Button, { priority: "tertiary", block: true, onClick: l, children: n || s.formatMessage(ri.retryTitle) })] });
|
|
1165
1165
|
};
|
|
1166
|
-
var
|
|
1166
|
+
var Vo = Hc;
|
|
1167
1167
|
var Fs = require("react");
|
|
1168
1168
|
var ai = qe(st());
|
|
1169
1169
|
var ni = require("react");
|
|
@@ -1176,15 +1176,15 @@ var require_main_min = __commonJS({
|
|
|
1176
1176
|
let s = e.schema.allOf[a];
|
|
1177
1177
|
r[a] = ie(n.model, s) || {}, o(r), e.onChange(b(i({}, n), { model: Gc(r) }));
|
|
1178
1178
|
}, [r, o] = (0, ni.useState)(qc(e.model, e.schema.allOf));
|
|
1179
|
-
return (0, ke.jsxs)(ke.Fragment, { children: [e.schema.title && (0, ke.jsx)("h3", { className: "page-header", children: e.schema.title }), e.schema.description && (0, ke.jsx)("p", { children: e.schema.description }), (0, ke.jsx)("div", { className: "row", children: e.schema.allOf.map((a, n) => (0, ke.jsx)("div", { className: (0, ai.default)($c(a.width)), children: (0, ke.jsx)(
|
|
1179
|
+
return (0, ke.jsxs)(ke.Fragment, { children: [e.schema.title && (0, ke.jsx)("h3", { className: "page-header", children: e.schema.title }), e.schema.description && (0, ke.jsx)("p", { children: e.schema.description }), (0, ke.jsx)("div", { className: "row", children: e.schema.allOf.map((a, n) => (0, ke.jsx)("div", { className: (0, ai.default)($c(a.width)), children: (0, ke.jsx)(le, { schema: a, model: r[n], errors: e.errors, submitted: e.submitted, disabled: e.disabled, onChange: (s) => t(n, b(i({}, s), { model: s.model })), onPersistAsync: e.onPersistAsync }) }, n)) })] });
|
|
1180
1180
|
};
|
|
1181
1181
|
ii.defaultProps = { disabled: false };
|
|
1182
|
-
var
|
|
1183
|
-
var
|
|
1182
|
+
var Uo = ii;
|
|
1183
|
+
var Ur = require("@transferwise/components");
|
|
1184
1184
|
var wi = qe(st());
|
|
1185
|
-
var
|
|
1186
|
-
var
|
|
1187
|
-
var
|
|
1185
|
+
var tr = require("react");
|
|
1186
|
+
var Vr = require("@transferwise/components");
|
|
1187
|
+
var zo = require("@transferwise/formatting");
|
|
1188
1188
|
var mi = require("react-intl");
|
|
1189
1189
|
var si = require("react-intl");
|
|
1190
1190
|
var he = (0, si.defineMessages)({ type: { id: "dynamicFlows.ControlFeedback.type", defaultMessage: "Incorrect type", description: "" }, minimum: { id: "dynamicFlows.ControlFeedback.minimum", defaultMessage: "Please enter a number that's {minimum} or more.", description: "" }, maximum: { id: "dynamicFlows.ControlFeedback.maximum", defaultMessage: "Please enter a number that's {maximum} or less.", description: "" }, minLength: { id: "dynamicFlows.ControlFeedback.minLength", defaultMessage: "Please enter at least {minLength} characters.", description: "" }, maxLength: { id: "dynamicFlows.ControlFeedback.maxLength", defaultMessage: "Please enter {maxLength} or fewer characters.", description: "" }, minimumDate: { id: "dynamicFlows.ControlFeedback.minimumDate", defaultMessage: "Please enter a date that's on or after {minimum}.", description: "" }, maximumDate: { id: "dynamicFlows.ControlFeedback.maximumDate", defaultMessage: "Please enter a date that's on or before {maximum}.", description: "" }, pattern: { id: "dynamicFlows.ControlFeedback.pattern", defaultMessage: "Please enter this in the correct format.", description: "" }, patternDate: { id: "dynamicFlows.ControlFeedback.patternDate", defaultMessage: "Please enter a date in the corrrect format.", description: "" }, required: { id: "dynamicFlows.ControlFeedback.required", defaultMessage: "Please fill out this field.", description: "" } });
|
|
@@ -1192,13 +1192,13 @@ var require_main_min = __commonJS({
|
|
|
1192
1192
|
var li = (e) => {
|
|
1193
1193
|
var l;
|
|
1194
1194
|
let t = Wc(e.schema), r = i(i(i({}, t), e.validationMessages), e.schema.validationMessages), o = (e.submitted || !e.changed) && !!e.errors, a = !o && (e.submitted || e.changed && e.blurred) && !!((l = e.validations) != null && l.length), n = e.focused && e.schema.description && !a, s = !!e.infoMessage;
|
|
1195
|
-
return (0, Re.jsxs)("div", { id: e.id, children: [o ? (0, Re.jsx)(
|
|
1195
|
+
return (0, Re.jsxs)("div", { id: e.id, children: [o ? (0, Re.jsx)(Vr.InlineAlert, { type: "error", children: e.errors }) : null, a ? (0, Re.jsx)(Vr.InlineAlert, { type: "error", children: e.validations.map((u) => (0, Re.jsx)("div", { children: r[u] }, u)) }) : null, (n || s) && (0, Re.jsxs)(Vr.InlineAlert, { type: "info", children: [n && (0, Re.jsx)("div", { children: e.schema.description }), s && (0, Re.jsx)("div", { children: e.infoMessage })] })] });
|
|
1196
1196
|
};
|
|
1197
1197
|
li.defaultProps = { errors: "", validations: [], validationMessages: {}, validationAsyncSuccessMessage: null };
|
|
1198
1198
|
function Wc(e) {
|
|
1199
1199
|
let { formatMessage: t, locale: r } = (0, mi.useIntl)(), o = { type: t(he.type), minimum: t(he.minimum, { minimum: e.minimum }), maximum: t(he.maximum, { maximum: e.maximum }), minLength: t(he.minLength, { minLength: e.minLength }), maxLength: t(he.maxLength, { maxLength: e.maxLength }), pattern: t(he.pattern), required: t(he.required) };
|
|
1200
1200
|
if (e.format === "date") {
|
|
1201
|
-
let a = { pattern: t(he.patternDate), minimum: e.minimum ? t(he.minimumDate, { minimum: (0,
|
|
1201
|
+
let a = { pattern: t(he.patternDate), minimum: e.minimum ? t(he.minimumDate, { minimum: (0, zo.formatDate)(new Date(e.minimum), r, { timeZone: "UTC", dateStyle: "long" }) }) : void 0, maximum: e.maximum ? t(he.maximumDate, { maximum: (0, zo.formatDate)(new Date(e.maximum), r, { timeZone: "UTC", dateStyle: "long" }) }) : void 0 };
|
|
1202
1202
|
return i(i({}, o), a);
|
|
1203
1203
|
}
|
|
1204
1204
|
return o;
|
|
@@ -1237,7 +1237,7 @@ var require_main_min = __commonJS({
|
|
|
1237
1237
|
var dt = require("react/jsx-runtime");
|
|
1238
1238
|
var Fi = (e) => {
|
|
1239
1239
|
var M, R;
|
|
1240
|
-
let { onChange: t, schema: r } = e, o = Q(), a = Si(r), n = (0,
|
|
1240
|
+
let { onChange: t, schema: r } = e, o = Q(), a = Si(r), n = (0, tr.useMemo)(() => r.$id || Me(), [r.$id]), [s, l] = (0, tr.useState)(false), [u, d] = (0, tr.useState)(() => _c(e.model || [])), c = Ci(r.items.persistAsync), h = r.items.persistAsync.schema, f = Pt(h), m = async (v) => {
|
|
1241
1241
|
l(true);
|
|
1242
1242
|
try {
|
|
1243
1243
|
let T = await ci(v, f);
|
|
@@ -1255,16 +1255,16 @@ var require_main_min = __commonJS({
|
|
|
1255
1255
|
let H = bi(v).map((L) => L.id);
|
|
1256
1256
|
t({ model: H, triggerSchema: r, triggerModel: H });
|
|
1257
1257
|
}
|
|
1258
|
-
let S = bi(u).map((v) => v.id), g =
|
|
1259
|
-
return (0, dt.jsxs)("div", { className: (0, wi.default)("form-group", { "has-error": F }), children: [(0, dt.jsx)("label", { className: "d-block control-label", htmlFor: n, children: e.schema.title }), (0, dt.jsx)("div", { "aria-describedby": x, children: (0, dt.jsx)(
|
|
1258
|
+
let S = bi(u).map((v) => v.id), g = Ot(S, r, e.required), F = !!e.errors || (s || e.submitted) && !!g.length, w = "accepts" in h && h.accepts, A = "maxSize" in h && h.maxSize, O = b(i(i({ multiple: true, className: "form-control", files: u, fileInputName: n, id: n }, w ? { fileTypes: w } : void 0), A ? { sizeLimit: kr(A) } : void 0), { sizeLimitErrorMessage: ((M = h.validationMessages) == null ? void 0 : M.maxSize) || a.maxFileSizeErrorMessage, maxFiles: e.schema.maxItems, maxFilesErrorMessage: ((R = e.schema.validationMessages) == null ? void 0 : R.maxItems) || a.maxItemsErrorMessage, uploadButtonTitle: h.title, description: h.description, disabled: e.disabled, onUploadFile: (v) => m(v.get(n)), onFilesChange: p, onDeleteFile: () => Promise.resolve() }), x = `${n}-feedback`;
|
|
1259
|
+
return (0, dt.jsxs)("div", { className: (0, wi.default)("form-group", { "has-error": F }), children: [(0, dt.jsx)("label", { className: "d-block control-label", htmlFor: n, children: e.schema.title }), (0, dt.jsx)("div", { "aria-describedby": x, children: (0, dt.jsx)(Ur.UploadInput, i({}, O)) }), (0, dt.jsx)(Be, { id: x, changed: s, submitted: e.submitted, errors: e.errors, schema: e.schema, validations: g, validationMessages: Jc(r, !!e.required, a), infoMessage: null, focused: false, blurred: true })] });
|
|
1260
1260
|
};
|
|
1261
1261
|
Fi.defaultProps = { errors: null, required: false };
|
|
1262
|
-
var
|
|
1262
|
+
var Ho = Fi;
|
|
1263
1263
|
function bi(e) {
|
|
1264
1264
|
return e.filter((t) => !t.error && t.status === "succeeded");
|
|
1265
1265
|
}
|
|
1266
1266
|
function _c(e) {
|
|
1267
|
-
return e.map((t) => Kc(t) ? { id: t, status:
|
|
1267
|
+
return e.map((t) => Kc(t) ? { id: t, status: Ur.Status.SUCCEEDED } : null).filter((t) => t !== null);
|
|
1268
1268
|
}
|
|
1269
1269
|
function Kc(e) {
|
|
1270
1270
|
return V(e) || I(e);
|
|
@@ -1273,9 +1273,9 @@ var require_main_min = __commonJS({
|
|
|
1273
1273
|
let { minItems: o, maxItems: a } = e;
|
|
1274
1274
|
return i(i(i({}, t && { required: r.requiredMessage }), o && { minItems: r.minItemsErrorMessage }), a && { maxItems: r.maxItemsErrorMessage });
|
|
1275
1275
|
}
|
|
1276
|
-
var
|
|
1276
|
+
var Dt = require("@transferwise/components");
|
|
1277
1277
|
var Ii = require("@transferwise/icons");
|
|
1278
|
-
var
|
|
1278
|
+
var qr = require("react");
|
|
1279
1279
|
var Di = require("react-intl");
|
|
1280
1280
|
var xi = require("@transferwise/components");
|
|
1281
1281
|
var Ai = require("react/jsx-runtime");
|
|
@@ -1286,35 +1286,35 @@ var require_main_min = __commonJS({
|
|
|
1286
1286
|
var ki = require("react/jsx-runtime");
|
|
1287
1287
|
var Xc = ({ type: e, schema: t, model: r, errors: o, submitted: a, onModelChange: n, onAction: s }) => {
|
|
1288
1288
|
let { formatMessage: l } = (0, Pi.useIntl)(), u = { layout: [{ type: "form", schema: t.items }, { type: "button", control: "primary", action: { url: e, title: l(e === "add" ? ut.addItem : ut.editItem) } }, ...e === "edit" ? [{ type: "button", context: "negative", action: { url: "remove", title: l(ut.removeItem) } }] : []], title: "", actions: [], schemas: [] };
|
|
1289
|
-
return (0, ki.jsx)(
|
|
1289
|
+
return (0, ki.jsx)(zr, { step: u, model: r, stepLayoutOptions: { displayStepTitle: false }, submitted: a, formErrors: o, globalError: null, onAction: (d) => {
|
|
1290
1290
|
s(d.url);
|
|
1291
1291
|
}, onModelChange: n });
|
|
1292
1292
|
};
|
|
1293
1293
|
var Mi = Xc;
|
|
1294
|
-
var
|
|
1295
|
-
let r =
|
|
1294
|
+
var Hr = (e, t) => {
|
|
1295
|
+
let r = rr(e, t);
|
|
1296
1296
|
if (r >= 0)
|
|
1297
1297
|
return r;
|
|
1298
|
-
if (e.oneOf.length === 1 &&
|
|
1298
|
+
if (e.oneOf.length === 1 && Jt(e.oneOf[0]))
|
|
1299
1299
|
return 0;
|
|
1300
1300
|
if (ye(e.oneOf[0])) {
|
|
1301
|
-
let o =
|
|
1301
|
+
let o = rr(e, e.default);
|
|
1302
1302
|
if (o >= 0)
|
|
1303
1303
|
return o;
|
|
1304
1304
|
}
|
|
1305
|
-
return nt(e) && W(t) && Object.keys(t).length >= 1 ?
|
|
1305
|
+
return nt(e) && W(t) && Object.keys(t).length >= 1 ? It(e, t) : nt(e) && !X(e.default) && W(e.default) && Object.keys(e.default).length >= 1 ? It(e, e.default) : null;
|
|
1306
1306
|
};
|
|
1307
|
-
var
|
|
1308
|
-
function
|
|
1307
|
+
var rr = (e, t) => e.oneOf.findIndex((r) => !X(t) && $(t, r));
|
|
1308
|
+
function It(e, t) {
|
|
1309
1309
|
if (t == null)
|
|
1310
1310
|
return null;
|
|
1311
|
-
let r = e.oneOf.map((o) => Yc(o).reduce((a, [n, s]) => ye(s) && s.const === t[n] ? a + 2 :
|
|
1311
|
+
let r = e.oneOf.map((o) => Yc(o).reduce((a, [n, s]) => ye(s) && s.const === t[n] ? a + 2 : Jt(s) && typeof t[n] != "undefined" ? a + 1 : a, 0));
|
|
1312
1312
|
return r.every((o) => o === r[0]) ? null : r.indexOf(Math.max(...r));
|
|
1313
1313
|
}
|
|
1314
1314
|
function Yc(e) {
|
|
1315
1315
|
return e.properties !== null && typeof e.properties == "object" ? Object.entries(e.properties) : [];
|
|
1316
1316
|
}
|
|
1317
|
-
var
|
|
1317
|
+
var qo = (e, t, r = {}) => {
|
|
1318
1318
|
let { defaultTitle: o = "", defaultDescription: a = "", defaultIcon: n, defaultImage: s } = r, l = Ye({ schema: e, model: t, providesProp: "providesTitle", getValueFromSchema: Ei }), u = Ye({ schema: e, model: t, providesProp: "providesDescription", getValueFromSchema: Ei }), d = Ye({ schema: e, model: t, providesProp: "providesIcon", getValueFromSchema: (h) => {
|
|
1319
1319
|
var f;
|
|
1320
1320
|
return (f = h.icon) != null ? f : null;
|
|
@@ -1353,13 +1353,13 @@ var require_main_min = __commonJS({
|
|
|
1353
1353
|
if (nt(t)) {
|
|
1354
1354
|
if (!W(r))
|
|
1355
1355
|
return null;
|
|
1356
|
-
let n =
|
|
1356
|
+
let n = It(t, r);
|
|
1357
1357
|
if (n === null || n < 0)
|
|
1358
1358
|
return null;
|
|
1359
1359
|
let s = t.oneOf[n];
|
|
1360
1360
|
return Ye(b(i({}, e), { schema: s }));
|
|
1361
1361
|
}
|
|
1362
|
-
let o = t, a =
|
|
1362
|
+
let o = t, a = Hr(o, r);
|
|
1363
1363
|
return a === null || a < 0 ? null : Ye(b(i({}, e), { schema: o.oneOf[a] }));
|
|
1364
1364
|
};
|
|
1365
1365
|
var ed = (e) => {
|
|
@@ -1371,15 +1371,15 @@ var require_main_min = __commonJS({
|
|
|
1371
1371
|
}
|
|
1372
1372
|
return null;
|
|
1373
1373
|
};
|
|
1374
|
-
var Ei = (e, t) => ye(e) ? e.title ? e.title : I(e.const) ? e.const : null :
|
|
1374
|
+
var Ei = (e, t) => ye(e) ? e.title ? e.title : I(e.const) ? e.const : null : Dr(t) ? t : null;
|
|
1375
1375
|
var td = (e, t) => !!e && Object.hasOwnProperty.call(e, t) && !!e[t];
|
|
1376
1376
|
var ge = require("react/jsx-runtime");
|
|
1377
1377
|
var rd = ({ schema: e, model: t, errors: r, submitted: o, onChange: a }) => {
|
|
1378
|
-
let [n, s] = (0,
|
|
1378
|
+
let [n, s] = (0, qr.useState)(null), [l, u] = (0, qr.useState)(() => {
|
|
1379
1379
|
if (N(t) && !q(t))
|
|
1380
1380
|
throw new Error("RepeatableSchema does not support object models. Ensure your array schema is wrapped inside an object schema.");
|
|
1381
|
-
return t ? t.map((g) =>
|
|
1382
|
-
}), [d, c] = (0,
|
|
1381
|
+
return t ? t.map((g) => qo(e.items, g, e == null ? void 0 : e.summary)) : null;
|
|
1382
|
+
}), [d, c] = (0, qr.useState)({ item: null, model: null }), h = (g) => {
|
|
1383
1383
|
let F = g ? g.map(({ value: w }) => w) : null;
|
|
1384
1384
|
a({ model: F, triggerSchema: e.items, triggerModel: F });
|
|
1385
1385
|
}, f = () => {
|
|
@@ -1388,7 +1388,7 @@ var require_main_min = __commonJS({
|
|
|
1388
1388
|
c({ item: g, model: g.value }), s("edit");
|
|
1389
1389
|
}, p = (g) => {
|
|
1390
1390
|
var A;
|
|
1391
|
-
let F = g === "remove" ? null :
|
|
1391
|
+
let F = g === "remove" ? null : qo(e.items, d.model, e == null ? void 0 : e.summary);
|
|
1392
1392
|
if (g !== "remove" && !$((A = F == null ? void 0 : F.value) != null ? A : null, e.items))
|
|
1393
1393
|
return;
|
|
1394
1394
|
let w = od(g, { originalItem: d.item, updatedItem: F, itemSummaries: l });
|
|
@@ -1396,7 +1396,7 @@ var require_main_min = __commonJS({
|
|
|
1396
1396
|
}, y = () => {
|
|
1397
1397
|
c({ item: null, model: null }), s(null);
|
|
1398
1398
|
}, { formatMessage: S } = (0, Di.useIntl)();
|
|
1399
|
-
return (0, ge.jsxs)(ge.Fragment, { children: [e.title && (0, ge.jsx)(
|
|
1399
|
+
return (0, ge.jsxs)(ge.Fragment, { children: [e.title && (0, ge.jsx)(Dt.Header, { title: e.title }), l && l.map((g) => (0, ge.jsx)(vi, { item: g, onClick: () => m(g) }, JSON.stringify(g))), (0, ge.jsx)(Dt.NavigationOption, { onClick: f, media: (0, ge.jsx)(Ii.Plus, {}), title: e.addItemTitle || S(ut.addItemTitle) }), (0, ge.jsx)(Dt.Modal, { open: n !== null, onClose: y, title: (n === "add" ? e.addItemTitle : e.editItemTitle) || S(ut.addItemTitle), body: (0, ge.jsx)(Mi, { type: n != null ? n : "add", schema: e, model: d.model, errors: r, submitted: o, onAction: p, onModelChange: ({ model: g }) => c(b(i({}, d), { model: g })) }) })] });
|
|
1400
1400
|
};
|
|
1401
1401
|
var od = (e, { originalItem: t, updatedItem: r, itemSummaries: o }) => {
|
|
1402
1402
|
if (e === "remove")
|
|
@@ -1413,13 +1413,13 @@ var require_main_min = __commonJS({
|
|
|
1413
1413
|
}
|
|
1414
1414
|
};
|
|
1415
1415
|
var Li = rd;
|
|
1416
|
-
var
|
|
1416
|
+
var Go = require("react/jsx-runtime");
|
|
1417
1417
|
var Ti = (e) => {
|
|
1418
1418
|
let { schema: t } = e;
|
|
1419
1419
|
if (kn(t))
|
|
1420
|
-
return (0,
|
|
1420
|
+
return (0, Go.jsx)(Ho, b(i({}, e), { schema: t }));
|
|
1421
1421
|
if (Oe(t))
|
|
1422
|
-
return (0,
|
|
1422
|
+
return (0, Go.jsx)(Li, b(i({}, e), { schema: t }));
|
|
1423
1423
|
throw new Error("Invalid array list schema");
|
|
1424
1424
|
};
|
|
1425
1425
|
Ti.defaultProps = { errors: null, required: false };
|
|
@@ -1432,40 +1432,40 @@ var require_main_min = __commonJS({
|
|
|
1432
1432
|
throw new Error("Not implemented");
|
|
1433
1433
|
};
|
|
1434
1434
|
Ri.defaultProps = { required: false };
|
|
1435
|
-
var
|
|
1435
|
+
var $o = Ri;
|
|
1436
1436
|
var ji = qe(st());
|
|
1437
|
-
var
|
|
1437
|
+
var Gr = require("react");
|
|
1438
1438
|
var je = require("react/jsx-runtime");
|
|
1439
1439
|
var ad = (e) => ({ "col-xs-12": true, "col-sm-6": e === "md", "col-sm-4": e === "sm" });
|
|
1440
1440
|
var Vi = (e) => {
|
|
1441
|
-
let [t, r] = (0,
|
|
1441
|
+
let [t, r] = (0, Gr.useState)(() => i({}, ie(e.model, e.schema))), o = (d, c) => {
|
|
1442
1442
|
c.model !== null ? t[d] = c.model : delete t[d], r(t), e.onChange(b(i({}, c), { model: t }));
|
|
1443
1443
|
}, a = (d) => e.schema.required && e.schema.required.includes(d);
|
|
1444
|
-
(0,
|
|
1444
|
+
(0, Gr.useEffect)(() => {
|
|
1445
1445
|
let d = ie(t, e.schema) || {};
|
|
1446
1446
|
r(d), Ke(d, t) || e.onChange({ model: d, triggerSchema: e.schema, triggerModel: d });
|
|
1447
1447
|
}, [e.schema]);
|
|
1448
1448
|
let n = /* @__PURE__ */ new Set([...e.schema.displayOrder || [], ...Object.keys(e.schema.properties)]), s = (d) => typeof e.schema.properties[d] != "undefined", l = Array.from(n).filter(s), u = e.errors;
|
|
1449
|
-
return (0, je.jsxs)("fieldset", { children: [e.schema.title && !e.hideTitle && (0, je.jsxs)("legend", { children: [" ", e.schema.title, " "] }), e.schema.description && !e.hideTitle && (0, je.jsxs)("p", { children: [" ", e.schema.description, " "] }), e.schema.alert && (0, je.jsx)(se, { component: e.schema.alert }), (0, je.jsx)("div", { className: "row", children: l.map((d) => (0, je.jsx)("div", { className: (0, ji.default)(ad(e.schema.properties[d].width)), children: (0, je.jsx)(
|
|
1449
|
+
return (0, je.jsxs)("fieldset", { children: [e.schema.title && !e.hideTitle && (0, je.jsxs)("legend", { children: [" ", e.schema.title, " "] }), e.schema.description && !e.hideTitle && (0, je.jsxs)("p", { children: [" ", e.schema.description, " "] }), e.schema.alert && (0, je.jsx)(se, { component: e.schema.alert }), (0, je.jsx)("div", { className: "row", children: l.map((d) => (0, je.jsx)("div", { className: (0, ji.default)(ad(e.schema.properties[d].width)), children: (0, je.jsx)(le, { schema: e.schema.properties[d], model: e.model && e.model[d], errors: u && u[d], submitted: e.submitted, required: a(d), disabled: e.disabled, onChange: (c) => o(d, c), onPersistAsync: e.onPersistAsync }) }, d)) })] });
|
|
1450
1450
|
};
|
|
1451
1451
|
Vi.defaultProps = { hideTitle: false, disabled: false };
|
|
1452
|
-
var
|
|
1452
|
+
var or = Vi;
|
|
1453
1453
|
var Zi = qe(st());
|
|
1454
1454
|
var Ee = require("react");
|
|
1455
|
-
var
|
|
1455
|
+
var $r = require("@transferwise/components");
|
|
1456
1456
|
var Hi = require("react-intl");
|
|
1457
1457
|
var Ui = require("react-intl");
|
|
1458
1458
|
var zi = (0, Ui.defineMessages)({ helpAria: { id: "dynamicFlows.Help.ariaLabel", defaultMessage: "Click here for more info.", description: "Aria label for help." } });
|
|
1459
|
-
var
|
|
1459
|
+
var Wo = require("react/jsx-runtime");
|
|
1460
1460
|
var nd = (e) => {
|
|
1461
1461
|
let t = (0, Hi.useIntl)();
|
|
1462
|
-
return (0,
|
|
1462
|
+
return (0, Wo.jsx)($r.Info, { className: "m-l-1", content: (0, Wo.jsx)($r.Markdown, { children: e.help.markdown }), presentation: "POPOVER", size: "sm", "aria-label": t.formatMessage(zi.helpAria) });
|
|
1463
1463
|
};
|
|
1464
1464
|
var Ve = nd;
|
|
1465
1465
|
var Xi = require("react");
|
|
1466
1466
|
var K = require("@transferwise/components");
|
|
1467
1467
|
var Wi = require("react");
|
|
1468
|
-
var
|
|
1468
|
+
var Lt = (e, t = {}) => {
|
|
1469
1469
|
let { coerceValue: r = false } = t;
|
|
1470
1470
|
if (!E(e)) {
|
|
1471
1471
|
if (N(e)) {
|
|
@@ -1474,14 +1474,14 @@ var require_main_min = __commonJS({
|
|
|
1474
1474
|
}
|
|
1475
1475
|
if (!I(e)) {
|
|
1476
1476
|
if (r)
|
|
1477
|
-
return
|
|
1477
|
+
return Ko({ received: typeof e, expected: "string" }), String(e);
|
|
1478
1478
|
pt({ received: typeof e, expected: "string" });
|
|
1479
1479
|
return;
|
|
1480
1480
|
}
|
|
1481
1481
|
return e;
|
|
1482
1482
|
}
|
|
1483
1483
|
};
|
|
1484
|
-
var
|
|
1484
|
+
var _o = (e, t = {}) => {
|
|
1485
1485
|
let { coerceValue: r = false } = t;
|
|
1486
1486
|
if (E(e))
|
|
1487
1487
|
return;
|
|
@@ -1494,7 +1494,7 @@ var require_main_min = __commonJS({
|
|
|
1494
1494
|
}
|
|
1495
1495
|
if (!I(e)) {
|
|
1496
1496
|
if (r)
|
|
1497
|
-
return
|
|
1497
|
+
return Ko(o), String(e);
|
|
1498
1498
|
pt(o);
|
|
1499
1499
|
return;
|
|
1500
1500
|
}
|
|
@@ -1506,7 +1506,7 @@ var require_main_min = __commonJS({
|
|
|
1506
1506
|
return false;
|
|
1507
1507
|
if (!Ae(e)) {
|
|
1508
1508
|
if (r)
|
|
1509
|
-
return
|
|
1509
|
+
return Ko({ received: typeof e, expected: "boolean" }), !!e;
|
|
1510
1510
|
pt({ received: typeof e, expected: "boolean" });
|
|
1511
1511
|
return;
|
|
1512
1512
|
}
|
|
@@ -1529,7 +1529,7 @@ var require_main_min = __commonJS({
|
|
|
1529
1529
|
let t = xn(e);
|
|
1530
1530
|
return t === null && console.warn("Incorrectly formatted date string. Falling back to null."), t;
|
|
1531
1531
|
};
|
|
1532
|
-
var
|
|
1532
|
+
var Ko = ({ received: e, expected: t }) => {
|
|
1533
1533
|
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.`);
|
|
1534
1534
|
};
|
|
1535
1535
|
var pt = ({ received: e, expected: t, fallback: r = "undefined" }) => {
|
|
@@ -1574,7 +1574,7 @@ var require_main_min = __commonJS({
|
|
|
1574
1574
|
let { name: r, placeholder: o, step: a, countryCode: n, type: s, options: l, disabled: u, readOnly: d, required: c, minLength: h, maxLength: f, min: m, max: p, searchPlaceholder: y, searchValue: S, onSearchChange: g, size: F, uploadProps: w, label: A, monthFormat: O, id: x, minDate: M, maxDate: R, value: v, mode: T, describedBy: H } = this.props;
|
|
1575
1575
|
switch (s) {
|
|
1576
1576
|
case U.RADIO:
|
|
1577
|
-
return (0, Y.jsx)(K.RadioGroup, { radios: l.map(this.mapOption), name: r, selectedValue:
|
|
1577
|
+
return (0, Y.jsx)(K.RadioGroup, { radios: l.map(this.mapOption), name: r, selectedValue: _o(v, { coerceValue: true }), onChange: this.handleOnChange });
|
|
1578
1578
|
case U.CHECKBOX:
|
|
1579
1579
|
return (0, Y.jsx)(K.Checkbox, { checked: qi(v, { coerceValue: true }), disabled: u, label: A, required: c, readOnly: d, onChange: this.handleOnChange, onBlur: this.handleOnBlur, onFocus: this.handleOnFocus });
|
|
1580
1580
|
case U.SELECT: {
|
|
@@ -1590,15 +1590,15 @@ var require_main_min = __commonJS({
|
|
|
1590
1590
|
this.setState({ selectedOption: l.find((k) => k.value === P) }), this.props.onChange(P, B ? "user" : "init");
|
|
1591
1591
|
} });
|
|
1592
1592
|
case U.NUMBER:
|
|
1593
|
-
return (0, Y.jsx)("input", { autoComplete: this.getAutocompleteStatus(), className: "form-control", disabled: u, id: x, max: p, min: m, placeholder: o, readOnly: d, required: c, step: a, type: "number", value:
|
|
1593
|
+
return (0, Y.jsx)("input", { autoComplete: this.getAutocompleteStatus(), className: "form-control", disabled: u, id: x, max: p, min: m, placeholder: o, readOnly: d, required: c, step: a, type: "number", value: _o(v, { coerceValue: true }), onBlur: this.handleOnBlur, onChange: (P) => {
|
|
1594
1594
|
this.props.onChange(parseFloat(P.target.value));
|
|
1595
1595
|
}, onFocus: this.handleOnFocus, onWheel: (P) => {
|
|
1596
1596
|
P.target instanceof HTMLElement && P.target.blur();
|
|
1597
1597
|
}, "aria-describedby": H });
|
|
1598
1598
|
case U.HIDDEN:
|
|
1599
|
-
return (0, Y.jsx)("input", { type: "hidden", name: r, value:
|
|
1599
|
+
return (0, Y.jsx)("input", { type: "hidden", name: r, value: Lt(v, { coerceValue: true }), id: x });
|
|
1600
1600
|
case U.PASSWORD:
|
|
1601
|
-
return (0, Y.jsx)("input", { autoComplete: this.getAutocompleteStatus(), className: "form-control", disabled: u, id: x, placeholder: o, readOnly: d, required: c, type: "password", value:
|
|
1601
|
+
return (0, Y.jsx)("input", { autoComplete: this.getAutocompleteStatus(), className: "form-control", disabled: u, id: x, placeholder: o, readOnly: d, required: c, type: "password", value: Lt(v, { coerceValue: true }), onBlur: this.handleOnBlur, onChange: this.handleInputOnChange, onFocus: this.handleOnFocus, "aria-describedby": H });
|
|
1602
1602
|
case U.DATE:
|
|
1603
1603
|
case U.DATETIME:
|
|
1604
1604
|
return (0, Y.jsx)(K.DateInput, { disabled: u, size: F, value: Gi(v), mode: T, monthFormat: O, onBlur: this.handleOnBlur, onChange: this.handleOnChange, onFocus: this.handleOnFocus });
|
|
@@ -1607,9 +1607,9 @@ var require_main_min = __commonJS({
|
|
|
1607
1607
|
this.handleOnChange(vn(P));
|
|
1608
1608
|
}, onBlur: this.handleOnBlur, onFocus: this.handleOnFocus });
|
|
1609
1609
|
case U.TEL:
|
|
1610
|
-
return (0, Y.jsx)(K.PhoneNumberInput, { disabled: u, countryCode: n, placeholder: o, required: c, searchPlaceholder: y, size: F, initialValue:
|
|
1610
|
+
return (0, Y.jsx)(K.PhoneNumberInput, { disabled: u, countryCode: n, placeholder: o, required: c, searchPlaceholder: y, size: F, initialValue: Lt(v), onBlur: this.handleOnBlur, onChange: this.handleOnChange, onFocus: this.handleOnFocus });
|
|
1611
1611
|
case U.TEXTAREA: {
|
|
1612
|
-
let P = { className: "form-control tw-form-control", id: x, name: r, placeholder: o, value:
|
|
1612
|
+
let P = { className: "form-control tw-form-control", id: x, name: r, placeholder: o, value: Lt(v, { coerceValue: true }), readOnly: d, required: c, minLength: h, maxLength: f, onFocus: this.handleOnFocus, onBlur: this.handleOnBlur, disabled: u, autoComplete: this.getAutocompleteStatus() };
|
|
1613
1613
|
return this.props.displayPattern ? (0, Y.jsx)(K.TextareaWithDisplayFormat, b(i({ displayPattern: this.props.displayPattern }, P), { onChange: this.handleOnChange })) : (0, Y.jsx)("textarea", b(i({}, P), { onChange: this.handleInputOnChange, "aria-describedby": H }));
|
|
1614
1614
|
}
|
|
1615
1615
|
case U.FILE:
|
|
@@ -1623,14 +1623,14 @@ var require_main_min = __commonJS({
|
|
|
1623
1623
|
} }));
|
|
1624
1624
|
case U.TEXT:
|
|
1625
1625
|
default: {
|
|
1626
|
-
let P = { type: "text", className: "form-control", id: x, name: r, placeholder: o, value:
|
|
1626
|
+
let P = { type: "text", className: "form-control", id: x, name: r, placeholder: o, value: Lt(v, { coerceValue: true }), readOnly: d, required: c, minLength: h, maxLength: f, onFocus: this.handleOnFocus, onBlur: this.handleOnBlur, disabled: u, autoComplete: this.getAutocompleteStatus() };
|
|
1627
1627
|
return this.props.displayPattern ? (0, Y.jsx)(K.InputWithDisplayFormat, b(i({ displayPattern: this.props.displayPattern }, P), { onChange: this.handleOnChange })) : (0, Y.jsx)("input", b(i({}, P), { onChange: this.handleInputOnChange, "aria-describedby": H }));
|
|
1628
1628
|
}
|
|
1629
1629
|
}
|
|
1630
1630
|
}
|
|
1631
1631
|
};
|
|
1632
1632
|
Se.Type = U, Se.Size = Vn, Se.MonthFormat = jn, Se.DateMode = Bn, Se.defaultProps = { autoComplete: true, countryCode: null, disabled: false, displayPattern: null, id: null, label: "", max: null, maxDate: null, maxLength: null, min: null, minDate: null, minLength: null, mode: Se.DateMode.DAY_MONTH_YEAR, monthFormat: Se.MonthFormat.LONG, onBlur: null, onFocus: null, onSearchChange: null, options: [], placeholder: null, readOnly: false, required: false, searchPlaceholder: null, searchValue: "", selectedOption: null, size: Se.Size.MEDIUM, step: 1, type: Se.Type.TEXT, uploadProps: {}, value: null };
|
|
1633
|
-
var
|
|
1633
|
+
var Tt = Se;
|
|
1634
1634
|
var Ze = require("@transferwise/components");
|
|
1635
1635
|
var be = require("react/jsx-runtime");
|
|
1636
1636
|
var _i = (e, t) => {
|
|
@@ -1642,13 +1642,13 @@ var require_main_min = __commonJS({
|
|
|
1642
1642
|
return id(e);
|
|
1643
1643
|
}
|
|
1644
1644
|
};
|
|
1645
|
-
var id = (e) => i(i(i({ label: e.title, value: e.const }, Ki(e.title, e.description)),
|
|
1645
|
+
var id = (e) => i(i(i({ label: e.title, value: e.const }, Ki(e.title, e.description)), Nt(e)), Ji(e.disabled));
|
|
1646
1646
|
var sd = (e) => i(i(i(i(i({ label: e.title, value: e.const }, Ki(e.title, e.description)), cd(e.icon)), ld(e.image)), Ji(e.disabled)), md(e.keywords));
|
|
1647
1647
|
var md = (e) => q(e) ? { searchStrings: e } : {};
|
|
1648
1648
|
var ld = (e) => e != null && e.url ? { icon: (0, be.jsx)("div", { className: "media", children: (0, be.jsx)("div", { className: "np-option__no-media-circle", children: (0, be.jsx)("img", { src: e.url, alt: e.name || "" }) }) }) } : null;
|
|
1649
|
-
var cd = (e) => e != null && e.name &&
|
|
1650
|
-
var
|
|
1651
|
-
var
|
|
1649
|
+
var cd = (e) => e != null && e.name && Mt(e.name) ? { currency: e.name.substring(5) } : e != null && e.name && Lo(e.name) ? { icon: (0, be.jsx)(Je, { type: e.name }) } : e != null && e.text ? { icon: (0, be.jsx)("span", { children: e.text }) } : null;
|
|
1650
|
+
var Nt = ({ image: e, icon: t }) => e != null && e.url ? { avatar: (0, be.jsx)(Ze.Avatar, { type: Ze.AvatarType.THUMBNAIL, children: (0, be.jsx)("img", { src: e.url, alt: "" }) }) } : t != null && t.name && Lo(t.name) ? { avatar: (0, be.jsx)(Ze.Avatar, { type: Ze.AvatarType.ICON, children: (0, be.jsx)(Je, { type: t.name }) }) } : t != null && t.text ? { avatar: (0, be.jsx)(Ze.Avatar, { type: Ze.AvatarType.INITIALS, children: t.text }) } : null;
|
|
1651
|
+
var Wr = ({ accepts: e }) => i({}, q(e) && { usAccept: e.join(",") });
|
|
1652
1652
|
var Ki = (e, t) => {
|
|
1653
1653
|
if (e && t)
|
|
1654
1654
|
return { [(e + t).length > 50 ? "secondary" : "note"]: t };
|
|
@@ -1657,9 +1657,9 @@ var require_main_min = __commonJS({
|
|
|
1657
1657
|
if (!X(e) && !E(e))
|
|
1658
1658
|
return { disabled: e };
|
|
1659
1659
|
};
|
|
1660
|
-
var
|
|
1660
|
+
var Jo = require("react/jsx-runtime");
|
|
1661
1661
|
var dd = (e) => e === "string" || e === "number";
|
|
1662
|
-
var
|
|
1662
|
+
var Xo = (e) => {
|
|
1663
1663
|
if (fe(e))
|
|
1664
1664
|
return e.control === U.TAB && e.oneOf.length > 3 ? U.SELECT : e.oneOf.length === 2 && !e.control ? U.RADIO : e.control || U.SELECT;
|
|
1665
1665
|
if ("control" in e && e.control)
|
|
@@ -1681,27 +1681,27 @@ var require_main_min = __commonJS({
|
|
|
1681
1681
|
};
|
|
1682
1682
|
var ud = (e, t) => e.oneOf ? e.oneOf.map((r) => _i(r, t)) : null;
|
|
1683
1683
|
var Yi = (e) => {
|
|
1684
|
-
let { id: t, schema: r, value: o, disabled: a, onChange: n, onFocus: s, onBlur: l, onSearchChange: u, describedBy: d } = e, c =
|
|
1684
|
+
let { id: t, schema: r, value: o, disabled: a, onChange: n, onFocus: s, onBlur: l, onSearchChange: u, describedBy: d } = e, c = xt(), h = (F) => dd(r.type) && (E(F) || X(F)) ? "" : F, f = (F, w) => {
|
|
1685
1685
|
n($e(F, r), w);
|
|
1686
|
-
}, m =
|
|
1686
|
+
}, m = Xo(r);
|
|
1687
1687
|
(0, Xi.useEffect)(() => {
|
|
1688
1688
|
pd(r, c, m);
|
|
1689
1689
|
}, [JSON.stringify(r), c, m]);
|
|
1690
|
-
let p = r.values || ud(r, m), y = { onFocus: s, onBlur: l, onSearchChange: u, onChange: f }, S = h(o), g = { id: t, name: t, label: r.title, options: p || [], placeholder: r.placeholder, autoComplete: !r.help, disabled: a || r.disabled, displayPattern: r.displayFormat, uploadProps:
|
|
1691
|
-
return (0,
|
|
1690
|
+
let p = r.values || ud(r, m), y = { onFocus: s, onBlur: l, onSearchChange: u, onChange: f }, S = h(o), g = { id: t, name: t, label: r.title, options: p || [], placeholder: r.placeholder, autoComplete: !r.help, disabled: a || r.disabled, displayPattern: r.displayFormat, uploadProps: Wr(r), describedBy: d };
|
|
1691
|
+
return (0, Jo.jsx)("div", { "aria-describedby": d, children: (0, Jo.jsx)(Tt, i(i({ type: m, value: S }, y), g)) });
|
|
1692
1692
|
};
|
|
1693
1693
|
Yi.defaultProps = { value: null, onFocus: null, onBlur: null, onSearchChange: null, disabled: false };
|
|
1694
1694
|
var pd = (e, t, r) => {
|
|
1695
1695
|
fe(e) && e.oneOf.length === 2 && !e.control && t.warning("Deprecation warning", 'A oneOf schema with 2 options and no control type currently renders as a "radio" but will be changed to render as a "select". Please specify control radio to retain the existing behaviour.'), r === "file" && t.warning("Deprecation warning", "Please use a persist-async blob schema instead of string with base64url for file uploads. The base64url does not perform well on low end devices. Support for this schema will be removed in a later release."), e.values && t.warning("Deprecated schema", "Schema.values is a legacy approach. Please use oneOf.");
|
|
1696
1696
|
};
|
|
1697
|
-
var
|
|
1697
|
+
var ar = Yi;
|
|
1698
1698
|
var oe = require("react/jsx-runtime");
|
|
1699
1699
|
var Qi = (e) => {
|
|
1700
|
-
let t = Q(), [r, o] = (0, Ee.useState)(false), [a, n] = (0, Ee.useState)(false), [s, l] = (0, Ee.useState)(false), u = (0, Ee.useMemo)(() => e.schema.$id || Me(), [e.schema.$id]), [d, c] = (0, Ee.useState)(
|
|
1700
|
+
let t = Q(), [r, o] = (0, Ee.useState)(false), [a, n] = (0, Ee.useState)(false), [s, l] = (0, Ee.useState)(false), u = (0, Ee.useMemo)(() => e.schema.$id || Me(), [e.schema.$id]), [d, c] = (0, Ee.useState)(Hr(e.schema, e.model)), [h, f] = (0, Ee.useState)(gd(e.model, e.schema.oneOf)), m = Ln(t, 200), p = (M) => {
|
|
1701
1701
|
m("Dynamic Flow - OneOf Searched", { oneOfId: e.schema.analyticsId, searchValueLength: M.length });
|
|
1702
1702
|
};
|
|
1703
1703
|
if ((0, Ee.useEffect)(() => {
|
|
1704
|
-
let M =
|
|
1704
|
+
let M = rr(e.schema, e.model), R = rr(e.schema, e.schema.default);
|
|
1705
1705
|
M === -1 && R >= 0 && F(R, "init");
|
|
1706
1706
|
}, [e.schema]), !q(e.schema.oneOf))
|
|
1707
1707
|
return console.error("Incorrect format", e.schema), null;
|
|
@@ -1720,8 +1720,8 @@ var require_main_min = __commonJS({
|
|
|
1720
1720
|
} else
|
|
1721
1721
|
e.onChange({ model: h[M], triggerSchema: v, triggerModel: h[M], type: R });
|
|
1722
1722
|
R !== "init" && e.schema.analyticsId && t("Dynamic Flow - OneOf Selected", { oneOfId: e.schema.analyticsId, schemaId: v == null ? void 0 : v.analyticsId });
|
|
1723
|
-
}, w = Sd(e.schema), A = yd(e, d), O = { "form-group": true, "has-error": !r && e.errors && !
|
|
1724
|
-
return (0, oe.jsxs)(oe.Fragment, { children: [(e.schema.oneOf.length > 1 || ye(e.schema.oneOf[0])) && (0, oe.jsxs)(oe.Fragment, { children: [(0, oe.jsxs)("div", { className: (0, Zi.default)(O), children: [fd(e.schema, u), (0, oe.jsx)(
|
|
1723
|
+
}, w = Sd(e.schema), A = yd(e, d), O = { "form-group": true, "has-error": !r && e.errors && !vt(e.errors) || (e.submitted || r && s) && A.length }, x = `${u}-feedback`;
|
|
1724
|
+
return (0, oe.jsxs)(oe.Fragment, { children: [(e.schema.oneOf.length > 1 || ye(e.schema.oneOf[0])) && (0, oe.jsxs)(oe.Fragment, { children: [(0, oe.jsxs)("div", { className: (0, Zi.default)(O), children: [fd(e.schema, u), (0, oe.jsx)(ar, { id: u, schema: w, value: d, disabled: e.disabled, onChange: F, onFocus: S, onBlur: g, onSearchChange: p, describedBy: x }), (0, oe.jsx)(Be, { id: x, changed: r, focused: a, blurred: s, submitted: e.submitted, errors: hd(e.errors), schema: e.schema, validations: A, infoMessage: null })] }), e.schema.alert && (0, oe.jsx)(se, { component: e.schema.alert })] }), Jt(e.schema.oneOf[d]) && (0, oe.jsx)(le, { schema: e.schema.oneOf[d], model: h[d], errors: e.errors, submitted: e.submitted, hideTitle: true, disabled: e.disabled, onChange: (M) => y(d, M), onPersistAsync: e.onPersistAsync })] });
|
|
1725
1725
|
};
|
|
1726
1726
|
function fd(e, t) {
|
|
1727
1727
|
let r = e.help ? (0, oe.jsx)(Ve, { help: e.help }) : null, o = ye(e.oneOf[0]) ? (0, oe.jsxs)("label", { className: "control-label d-inline", htmlFor: t, children: [e.title, " ", r] }) : (0, oe.jsxs)("h4", { className: "m-b-2", children: [e.title, " ", r] });
|
|
@@ -1735,7 +1735,7 @@ var require_main_min = __commonJS({
|
|
|
1735
1735
|
return typeof e == "string" ? e : null;
|
|
1736
1736
|
}
|
|
1737
1737
|
function gd(e, t) {
|
|
1738
|
-
return t.map((r) =>
|
|
1738
|
+
return t.map((r) => At(e, r));
|
|
1739
1739
|
}
|
|
1740
1740
|
function Sd(e) {
|
|
1741
1741
|
return b(i({}, e), { oneOf: e.oneOf.map(bd) });
|
|
@@ -1745,27 +1745,27 @@ var require_main_min = __commonJS({
|
|
|
1745
1745
|
return { title: r, description: o, disabled: a, icon: n, image: s, const: t, keywords: l };
|
|
1746
1746
|
}
|
|
1747
1747
|
Qi.defaultProps = { required: false, disabled: false };
|
|
1748
|
-
var
|
|
1748
|
+
var Yo = Qi;
|
|
1749
1749
|
var os = qe(st());
|
|
1750
1750
|
var ft = require("react");
|
|
1751
|
-
var
|
|
1751
|
+
var _r = require("@transferwise/components");
|
|
1752
1752
|
var es = require("react");
|
|
1753
1753
|
var rs = require("react/jsx-runtime");
|
|
1754
1754
|
var ts = (e) => {
|
|
1755
|
-
let { id: t, httpClient: r = fetch, httpOptions: o, fileId: a, idProperty: n, usAccept: s, maxSize: l, usPlaceholder: u, onSuccess: d, onFailure: c, onCancel: h } = e, f = Q(), m = (0, es.useMemo)(() => a ? [{ id: a, status:
|
|
1756
|
-
return (0, rs.jsx)(
|
|
1755
|
+
let { id: t, httpClient: r = fetch, httpOptions: o, fileId: a, idProperty: n, usAccept: s, maxSize: l, usPlaceholder: u, onSuccess: d, onFailure: c, onCancel: h } = e, f = Q(), m = (0, es.useMemo)(() => a ? [{ id: a, status: _r.Status.SUCCEEDED }] : [], [a]), p = (y) => (f("Dynamic Flow - PersistAsync", { status: "pending", schemaId: t }), r(`${o.url}`, { method: o.method || "POST", body: y }).then((S) => S.ok ? (d && d(S.clone()), S.json().then((g) => ({ id: g[n] }))) : (c && c({ response: S }), Promise.reject())));
|
|
1756
|
+
return (0, rs.jsx)(_r.UploadInput, { id: t, fileInputName: o.fileInputName, files: m, uploadButtonTitle: e.usLabel, sizeLimit: l ? kr(l) : void 0, fileTypes: s, description: u, onUploadFile: p, onDeleteFile: (y) => (h && h(), Promise.resolve()) });
|
|
1757
1757
|
};
|
|
1758
|
-
var
|
|
1758
|
+
var Rt = require("react/jsx-runtime");
|
|
1759
1759
|
var as = (e) => {
|
|
1760
1760
|
let [t, r] = (0, ft.useState)({}), [o, a] = (0, ft.useState)(null), [n, s] = (0, ft.useState)([]), [l, u] = (0, ft.useState)(false), d = te(), c = Q();
|
|
1761
1761
|
(0, ft.useEffect)(() => {
|
|
1762
1762
|
e.submitted && s(We(e.model, e.schema, !!e.required));
|
|
1763
1763
|
}, [e.model, e.submitted]);
|
|
1764
1764
|
let f = async (O, x) => {
|
|
1765
|
-
let M = await O.json(), R =
|
|
1765
|
+
let M = await O.json(), R = ea(e.schema.persistAsync.idProperty, M);
|
|
1766
1766
|
e.onChange({ model: R, triggerSchema: e.schema, triggerModel: R }), u(true), c("Dynamic Flow - PersistAsync", { status: "success", schemaId: e.schema.$id });
|
|
1767
1767
|
}, m = async (O) => {
|
|
1768
|
-
if (O.response &&
|
|
1768
|
+
if (O.response && Cr(O.response.status)) {
|
|
1769
1769
|
let x = await O.response.json();
|
|
1770
1770
|
r(x.validation || {}), a([e.schema.persistAsync.param]);
|
|
1771
1771
|
}
|
|
@@ -1773,50 +1773,50 @@ var require_main_min = __commonJS({
|
|
|
1773
1773
|
}, p = () => {
|
|
1774
1774
|
a(null), e.onChange({ model: null, triggerSchema: e.schema, triggerModel: null }), u(true);
|
|
1775
1775
|
}, { url: y, method: S } = e.schema.persistAsync, g = o || n, F = { "form-group": true, "has-error": (e.submitted || l) && !!g.length }, w = e.schema.$id || e.schema.persistAsync.schema.$id || e.schema.persistAsync.idProperty, A = `${w}-feedback`;
|
|
1776
|
-
return (0,
|
|
1776
|
+
return (0, Rt.jsxs)("div", { className: (0, os.default)(F), children: [(0, Rt.jsx)("div", { "aria-describedby": A, children: (0, Rt.jsx)(ts, i({ id: w, fileId: e.model, idProperty: e.schema.persistAsync.idProperty, animationDelay: 0, maxSize: e.schema.persistAsync.schema.maxSize, usLabel: e.schema.title || e.schema.persistAsync.schema.title, usPlaceholder: e.schema.description || e.schema.persistAsync.schema.description, httpOptions: { url: y, method: S, fileInputName: e.schema.persistAsync.param }, httpClient: d, onSuccess: f, onFailure: m, onCancel: p }, Wr(e.schema.persistAsync.schema))) }), (0, Rt.jsx)(Be, { id: A, blurred: true, focused: false, changed: l, submitted: e.submitted, errors: e.errors, schema: e.schema, validations: g, validationMessages: i({ required: "Value is required..." }, t), infoMessage: null })] });
|
|
1777
1777
|
};
|
|
1778
1778
|
as.defaultProps = { required: false };
|
|
1779
|
-
var
|
|
1780
|
-
var
|
|
1779
|
+
var Qo = as;
|
|
1780
|
+
var ta = require("react/jsx-runtime");
|
|
1781
1781
|
var ns = (e) => {
|
|
1782
1782
|
let { schema: t } = e;
|
|
1783
|
-
return t.persistAsync.schema.type === "blob" ? (0,
|
|
1783
|
+
return t.persistAsync.schema.type === "blob" ? (0, ta.jsx)(Qo, i({}, e)) : (0, ta.jsx)(Zo, i({}, e));
|
|
1784
1784
|
};
|
|
1785
1785
|
ns.defaultProps = { required: false };
|
|
1786
|
-
var
|
|
1786
|
+
var ra = ns;
|
|
1787
1787
|
var ys = require("react");
|
|
1788
1788
|
var is = (e, t) => {
|
|
1789
|
-
let r =
|
|
1789
|
+
let r = It(e, t);
|
|
1790
1790
|
return r !== null ? e.oneOf[r].promoted ? "promoted" : "other" : null;
|
|
1791
1791
|
};
|
|
1792
1792
|
var ss = require("@transferwise/components");
|
|
1793
|
-
var
|
|
1793
|
+
var oa = require("react/jsx-runtime");
|
|
1794
1794
|
var ms = (e) => {
|
|
1795
1795
|
let { id: t, selection: r, setSelection: o } = e, { promoted: a, other: n, checkedMeans: s } = e.promotion, l = s === "other" ? n.title : (a == null ? void 0 : a.title) || e.promotedOneOf.title, u = s === "other" ? "other" : "promoted", d = s === "other" ? "promoted" : "other", c = r === u;
|
|
1796
|
-
return (0,
|
|
1796
|
+
return (0, oa.jsx)("div", { className: "form-group", children: (0, oa.jsx)(ss.Checkbox, { id: t, label: l, checked: c, onChange: () => {
|
|
1797
1797
|
o(c ? d : u);
|
|
1798
1798
|
} }) });
|
|
1799
1799
|
};
|
|
1800
1800
|
ms.defaultProps = {};
|
|
1801
1801
|
var ls = ms;
|
|
1802
1802
|
var cs = require("@transferwise/components");
|
|
1803
|
-
var
|
|
1803
|
+
var nr = require("react/jsx-runtime");
|
|
1804
1804
|
var ds = (e) => {
|
|
1805
1805
|
var u, d;
|
|
1806
|
-
let { id: t, selection: r, setSelection: o, promotion: a, promotedOneOf: n, title: s } = e, l = [i({ value: "promoted", label: ((u = a.promoted) == null ? void 0 : u.title) || n.title, secondary: ((d = a.promoted) == null ? void 0 : d.description) || n.description },
|
|
1807
|
-
return (0,
|
|
1806
|
+
let { id: t, selection: r, setSelection: o, promotion: a, promotedOneOf: n, title: s } = e, l = [i({ value: "promoted", label: ((u = a.promoted) == null ? void 0 : u.title) || n.title, secondary: ((d = a.promoted) == null ? void 0 : d.description) || n.description }, Nt(n)), i({ value: "other", label: a.other.title, secondary: a.other.description }, Nt(a.other))];
|
|
1807
|
+
return (0, nr.jsxs)("div", { className: "form-group", children: [s && (0, nr.jsx)("label", { className: "control-label", htmlFor: t, children: s }), (0, nr.jsx)(cs.RadioGroup, { name: "promoted-selection", selectedValue: r, radios: l, id: t, onChange: o })] });
|
|
1808
1808
|
};
|
|
1809
1809
|
ds.defaultProps = { title: void 0 };
|
|
1810
1810
|
var us = ds;
|
|
1811
|
-
var
|
|
1811
|
+
var Bt = require("react/jsx-runtime");
|
|
1812
1812
|
var ps = (e) => {
|
|
1813
1813
|
switch (e.promotion.control || "radio") {
|
|
1814
1814
|
case "radio":
|
|
1815
|
-
return (0,
|
|
1815
|
+
return (0, Bt.jsx)(us, i({}, e));
|
|
1816
1816
|
case "checkbox":
|
|
1817
|
-
return (0,
|
|
1817
|
+
return (0, Bt.jsx)(ls, i({}, e));
|
|
1818
1818
|
default:
|
|
1819
|
-
return (0,
|
|
1819
|
+
return (0, Bt.jsx)(Bt.Fragment, {});
|
|
1820
1820
|
}
|
|
1821
1821
|
};
|
|
1822
1822
|
ps.defaultProps = { id: Me(), title: void 0 };
|
|
@@ -1826,7 +1826,7 @@ var require_main_min = __commonJS({
|
|
|
1826
1826
|
var wd = (e) => {
|
|
1827
1827
|
var l;
|
|
1828
1828
|
let [t, r] = (0, ys.useState)(is(e.schema, e.model) || ((l = e.schema.promotion) == null ? void 0 : l.default) || "promoted"), o = e.schema.alert, a = e.schema.oneOf.find(hs), n = Fd(a), s = Cd(e.schema);
|
|
1829
|
-
return (0, Ue.jsxs)(Ue.Fragment, { children: [o && (0, Ue.jsx)(se, { component: o }), (0, Ue.jsx)(fs, { id: e.schema.$id, title: e.schema.title, promotedOneOf: a, promotion: e.schema.promotion, selection: t, setSelection: r }), t === "promoted" && (0, Ue.jsx)(
|
|
1829
|
+
return (0, Ue.jsxs)(Ue.Fragment, { children: [o && (0, Ue.jsx)(se, { component: o }), (0, Ue.jsx)(fs, { id: e.schema.$id, title: e.schema.title, promotedOneOf: a, promotion: e.schema.promotion, selection: t, setSelection: r }), t === "promoted" && (0, Ue.jsx)(or, b(i({}, e), { schema: n })), t === "other" && (0, Ue.jsx)(le, b(i({}, e), { schema: s }))] });
|
|
1830
1830
|
};
|
|
1831
1831
|
function Fd(e) {
|
|
1832
1832
|
return b(i({}, e), { title: void 0, description: void 0 });
|
|
@@ -1836,19 +1836,19 @@ var require_main_min = __commonJS({
|
|
|
1836
1836
|
let t = (o = e.promotion) != null && o.displayTwice ? [...e.oneOf] : e.oneOf.filter((s) => !hs(s)), r = (n = (a = e.promotion) == null ? void 0 : a.other.heading) == null ? void 0 : n.text;
|
|
1837
1837
|
return t.length === 1 ? b(i({}, t[0]), { title: r }) : t.length > 1 ? { title: r, oneOf: t, control: e.control } : null;
|
|
1838
1838
|
}
|
|
1839
|
-
var
|
|
1840
|
-
var
|
|
1839
|
+
var aa = wd;
|
|
1840
|
+
var Kr = require("@transferwise/components");
|
|
1841
1841
|
var Ss = require("react-intl");
|
|
1842
1842
|
var gs = require("react-intl");
|
|
1843
|
-
var
|
|
1844
|
-
var
|
|
1843
|
+
var na = (0, gs.defineMessages)({ yes: { id: "dynamicFlows.ReadOnlySchema.yes", defaultMessage: "Yes", description: "Yes, used for boolean schemas with a value of true." }, no: { id: "dynamicFlows.ReadOnlySchema.no", defaultMessage: "No", description: "No: used for boolean schemas with a value of false." } });
|
|
1844
|
+
var jt = require("react/jsx-runtime");
|
|
1845
1845
|
var xd = ({ schema: e, model: t }) => {
|
|
1846
1846
|
let { title: r = "" } = e, { formatMessage: o } = (0, Ss.useIntl)(), a = vd({ schema: e, model: t, formatMessage: o });
|
|
1847
|
-
return (0,
|
|
1847
|
+
return (0, jt.jsx)(Kr.DefinitionList, { layout: Kr.Layout.VERTICAL_ONE_COLUMN, definitions: [{ title: r, value: a, key: "" }] });
|
|
1848
1848
|
};
|
|
1849
|
-
var
|
|
1849
|
+
var ia = xd;
|
|
1850
1850
|
function vd({ schema: e, model: t, formatMessage: r }) {
|
|
1851
|
-
return Te(e) ? fe(e) ? Ad(e, t) : e.type === "boolean" && Ae(t) ? r(t ?
|
|
1851
|
+
return Te(e) ? fe(e) ? Ad(e, t) : e.type === "boolean" && Ae(t) ? r(t ? na.yes : na.no) : t && t.toString() || "" : "";
|
|
1852
1852
|
}
|
|
1853
1853
|
function Ad(e, t) {
|
|
1854
1854
|
let r = Od(e, t);
|
|
@@ -1858,13 +1858,13 @@ var require_main_min = __commonJS({
|
|
|
1858
1858
|
return e.oneOf.find((r) => "const" in r ? t === r.const : false);
|
|
1859
1859
|
}
|
|
1860
1860
|
function Pd(e) {
|
|
1861
|
-
let t = e.title && e.description ? `${e.title} - ${e.description}` : e.title || "", r =
|
|
1862
|
-
return r != null && r.avatar ? (0,
|
|
1861
|
+
let t = e.title && e.description ? `${e.title} - ${e.description}` : e.title || "", r = Nt({ icon: e.icon });
|
|
1862
|
+
return r != null && r.avatar ? (0, jt.jsxs)(jt.Fragment, { children: [r.avatar, " ", t] }) : t;
|
|
1863
1863
|
}
|
|
1864
1864
|
var Ie = require("react");
|
|
1865
1865
|
var ws = require("react/jsx-runtime");
|
|
1866
1866
|
var bs = (e) => {
|
|
1867
|
-
let { schema: t, model: r, required: o, submitted: a, errors: n, onChange: s } = e, [l, u] = (0, Ie.useState)(r), d = (0, Ie.useRef)(null), [c, h] = (0, Ie.useState)(null), [f, m] = (0, Ie.useState)(null), [p, y] = (0, Ie.useState)(false), [S, g] = (0, Ie.useState)(null), F = te(), w = Q(), A =
|
|
1867
|
+
let { schema: t, model: r, required: o, submitted: a, errors: n, onChange: s } = e, [l, u] = (0, Ie.useState)(r), d = (0, Ie.useRef)(null), [c, h] = (0, Ie.useState)(null), [f, m] = (0, Ie.useState)(null), [p, y] = (0, Ie.useState)(false), [S, g] = (0, Ie.useState)(null), F = te(), w = Q(), A = xt();
|
|
1868
1868
|
(0, Ie.useEffect)(() => {
|
|
1869
1869
|
t.validationAsync.method || A.warning("Invalid schema or model", 'ValidationAsyncSchema without a "method" property would have defaulted to "GET" in previous versions. Now defaults to "POST".', {});
|
|
1870
1870
|
}, [A, t.validationAsync.method]);
|
|
@@ -1892,262 +1892,253 @@ var require_main_min = __commonJS({
|
|
|
1892
1892
|
}, required: o, schema: t }));
|
|
1893
1893
|
};
|
|
1894
1894
|
bs.defaultProps = { required: false };
|
|
1895
|
-
var
|
|
1895
|
+
var sa = bs;
|
|
1896
1896
|
var pe = require("react/jsx-runtime");
|
|
1897
1897
|
var Cs = require("react");
|
|
1898
1898
|
var Md = (e) => {
|
|
1899
|
-
let { schema: t, model: r = null, errors: o = null, hideTitle: a = false, disabled: n = false } = e, s = b(i({}, e), { model: r, errors: o, hideTitle: a, disabled: n }), l = it(t), u =
|
|
1899
|
+
let { schema: t, model: r = null, errors: o = null, hideTitle: a = false, disabled: n = false } = e, s = b(i({}, e), { model: r, errors: o, hideTitle: a, disabled: n }), l = it(t), u = xt();
|
|
1900
1900
|
switch ((0, Fs.useEffect)(() => {
|
|
1901
1901
|
kd(t, r, o) || u.error("Invalid schema or model", `Schema of type ${l || "undefined"} requested, but schema did not pass validation.`);
|
|
1902
1902
|
}, [JSON.stringify(t), JSON.stringify(r), JSON.stringify(o), l, u]), l) {
|
|
1903
1903
|
case "readOnly":
|
|
1904
|
-
return (0, pe.jsx)(
|
|
1904
|
+
return (0, pe.jsx)(ia, i({}, s));
|
|
1905
1905
|
case "persistAsync":
|
|
1906
|
-
return (0, pe.jsx)(
|
|
1906
|
+
return (0, pe.jsx)(ra, i({}, s));
|
|
1907
1907
|
case "validationAsync":
|
|
1908
|
-
return (0, pe.jsx)(
|
|
1908
|
+
return (0, pe.jsx)(sa, i({}, s));
|
|
1909
1909
|
case "basic": {
|
|
1910
1910
|
let d = i({ infoMessage: null }, s);
|
|
1911
1911
|
return (0, pe.jsx)(yt, i({}, d));
|
|
1912
1912
|
}
|
|
1913
1913
|
case "object":
|
|
1914
|
-
return (0, Cs.createElement)(
|
|
1914
|
+
return (0, Cs.createElement)(or, b(i({}, s), { key: JSON.stringify(t) }));
|
|
1915
1915
|
case "array":
|
|
1916
|
-
return (0, pe.jsx)(
|
|
1916
|
+
return (0, pe.jsx)($o, i({}, s));
|
|
1917
1917
|
case "promotedOneOf":
|
|
1918
|
-
return (0, pe.jsx)(
|
|
1918
|
+
return (0, pe.jsx)(aa, i({}, s));
|
|
1919
1919
|
case "oneOf":
|
|
1920
|
-
return (0, pe.jsx)(
|
|
1920
|
+
return (0, pe.jsx)(Yo, i({}, s));
|
|
1921
1921
|
case "allOf":
|
|
1922
|
-
return (0, pe.jsx)(
|
|
1922
|
+
return (0, pe.jsx)(Uo, i({}, s));
|
|
1923
1923
|
}
|
|
1924
1924
|
return (0, pe.jsx)(pe.Fragment, {});
|
|
1925
1925
|
};
|
|
1926
|
-
var
|
|
1926
|
+
var le = Md;
|
|
1927
1927
|
var kd = (e, t, r) => {
|
|
1928
1928
|
switch (it(e)) {
|
|
1929
1929
|
case "persistAsync":
|
|
1930
|
-
return
|
|
1930
|
+
return Er(e) && Dr(t) && Xt(r);
|
|
1931
1931
|
case "validationAsync":
|
|
1932
|
-
return
|
|
1932
|
+
return ko(e) && Io(t) && Xt(r);
|
|
1933
1933
|
case "basic":
|
|
1934
|
-
return Te(e) &&
|
|
1934
|
+
return Te(e) && Io(t) && Xt(r);
|
|
1935
1935
|
case "object":
|
|
1936
|
-
return Pe(e) &&
|
|
1936
|
+
return Pe(e) && Eo(t);
|
|
1937
1937
|
case "array":
|
|
1938
|
-
return Le(e) && In(t) &&
|
|
1938
|
+
return Le(e) && In(t) && Xt(r);
|
|
1939
1939
|
case "promotedOneOf":
|
|
1940
|
-
return nt(e) &&
|
|
1940
|
+
return nt(e) && Eo(t);
|
|
1941
1941
|
case "oneOf":
|
|
1942
1942
|
return fe(e);
|
|
1943
1943
|
case "allOf":
|
|
1944
|
-
return
|
|
1944
|
+
return Mo(e) && W(t);
|
|
1945
1945
|
}
|
|
1946
1946
|
return false;
|
|
1947
1947
|
};
|
|
1948
|
-
var
|
|
1949
|
-
var Ed = (e) => {
|
|
1950
|
-
let
|
|
1951
|
-
return
|
|
1952
|
-
|
|
1953
|
-
|
|
1954
|
-
|
|
1955
|
-
var
|
|
1956
|
-
|
|
1957
|
-
var
|
|
1958
|
-
var Dd = (e) => {
|
|
1959
|
-
let t = e.component, r = t.schema;
|
|
1960
|
-
return (0, ca.jsx)("div", { className: j(t.margin || "md"), children: (0, ca.jsx)(sr, { schema: r, model: e.model, submitted: e.submitted, errors: e.errors, onChange: (o) => {
|
|
1961
|
-
e.onModelChange(i({ formSchema: r }, o));
|
|
1962
|
-
}, onPersistAsync: e.onPersistAsync }) });
|
|
1963
|
-
};
|
|
1964
|
-
var da = Dd;
|
|
1965
|
-
var Ut = require("react/jsx-runtime");
|
|
1966
|
-
var Ld = (e) => {
|
|
1948
|
+
var ma = require("react/jsx-runtime");
|
|
1949
|
+
var Ed = ({ component: e, model: t = null, errors: r = null, submitted: o, onModelChange: a, onPersistAsync: n }) => {
|
|
1950
|
+
let s = e.schema;
|
|
1951
|
+
return (0, ma.jsx)("div", { className: j(e.margin || "md"), children: (0, ma.jsx)(le, { schema: s, model: t, errors: r, submitted: o, onChange: (l) => {
|
|
1952
|
+
a(i({ formSchema: s }, l));
|
|
1953
|
+
}, onPersistAsync: n }) });
|
|
1954
|
+
};
|
|
1955
|
+
var la = Ed;
|
|
1956
|
+
var Vt = require("react/jsx-runtime");
|
|
1957
|
+
var Id = (e) => {
|
|
1967
1958
|
let { text: t, size: r = "md", align: o = "left", margin: a = "md" } = e.component, n = Ne({ align: o, margin: a });
|
|
1968
1959
|
switch (r) {
|
|
1969
1960
|
case "xs":
|
|
1970
|
-
return (0,
|
|
1961
|
+
return (0, Vt.jsx)("h5", { className: n, children: t });
|
|
1971
1962
|
case "sm":
|
|
1972
|
-
return (0,
|
|
1963
|
+
return (0, Vt.jsx)("h4", { className: n, children: t });
|
|
1973
1964
|
case "lg":
|
|
1974
|
-
return (0,
|
|
1965
|
+
return (0, Vt.jsx)("h2", { className: n, children: t });
|
|
1975
1966
|
case "xl":
|
|
1976
|
-
return (0,
|
|
1967
|
+
return (0, Vt.jsx)("h1", { className: n, children: t });
|
|
1977
1968
|
case "md":
|
|
1978
1969
|
default:
|
|
1979
|
-
return (0,
|
|
1970
|
+
return (0, Vt.jsx)("h3", { className: n, children: t });
|
|
1980
1971
|
}
|
|
1981
1972
|
};
|
|
1982
|
-
var
|
|
1983
|
-
var
|
|
1984
|
-
var
|
|
1985
|
-
var
|
|
1973
|
+
var ca = Id;
|
|
1974
|
+
var da = require("@transferwise/components");
|
|
1975
|
+
var ir = require("react/jsx-runtime");
|
|
1976
|
+
var ua = ({ component: e }) => {
|
|
1986
1977
|
let { content: t, align: r, margin: o } = e;
|
|
1987
|
-
return (0,
|
|
1988
|
-
};
|
|
1989
|
-
var
|
|
1990
|
-
var
|
|
1991
|
-
var
|
|
1992
|
-
var
|
|
1993
|
-
var
|
|
1994
|
-
let { url: t, size: r, text: o, margin: a, accessibilityDescription: n } = e, s = te(), [l, u] = (0,
|
|
1995
|
-
(0,
|
|
1996
|
-
|
|
1978
|
+
return (0, ir.jsx)("div", { className: Ne({ align: r, margin: o }), children: (0, ir.jsx)(da.Markdown, { config: { link: { target: "_blank" } }, children: t }) });
|
|
1979
|
+
};
|
|
1980
|
+
var pa = ({ component: e }) => (0, ir.jsx)("div", { className: Ne(e), children: (0, ir.jsx)(da.Markdown, { config: { link: { target: "_blank" } }, children: e.markdown }) });
|
|
1981
|
+
var xs = require("@transferwise/components");
|
|
1982
|
+
var Jr = require("react");
|
|
1983
|
+
var fa = require("react/jsx-runtime");
|
|
1984
|
+
var Dd = ({ component: e }) => {
|
|
1985
|
+
let { url: t, size: r, text: o, margin: a, accessibilityDescription: n } = e, s = te(), [l, u] = (0, Jr.useState)("");
|
|
1986
|
+
(0, Jr.useEffect)(() => {
|
|
1987
|
+
Td(s, t).then(u);
|
|
1997
1988
|
}, [t, s]);
|
|
1998
1989
|
let d = { alt: n || o || "", src: l, stretch: true, shrink: true };
|
|
1999
|
-
return l ? (0,
|
|
1990
|
+
return l ? (0, fa.jsx)("div", { className: `df-image ${r || "md"}`, children: (0, fa.jsx)(xs.Image, i({ className: `img-responsive ${j(a || "md")}` }, d)) }) : null;
|
|
2000
1991
|
};
|
|
2001
|
-
var
|
|
1992
|
+
var Ld = (e) => new Promise((t, r) => {
|
|
2002
1993
|
let o = new FileReader();
|
|
2003
1994
|
o.addEventListener("loadend", () => t(o.result)), o.addEventListener("error", (a) => r(a)), o.readAsDataURL(e);
|
|
2004
1995
|
});
|
|
2005
|
-
var
|
|
1996
|
+
var Td = async (e, t) => {
|
|
2006
1997
|
var r;
|
|
2007
1998
|
try {
|
|
2008
|
-
return
|
|
1999
|
+
return xr(t) || (t == null ? void 0 : t.indexOf(`${(r = window == null ? void 0 : window.location) == null ? void 0 : r.origin}/`)) === 0 ? e(t, { method: "GET", headers: { "Content-Type": "image/image" }, credentials: "same-origin" }).then((o) => {
|
|
2009
2000
|
if (o.ok)
|
|
2010
2001
|
return o.blob();
|
|
2011
2002
|
throw new Error("Image fetching failed");
|
|
2012
|
-
}).then(
|
|
2003
|
+
}).then(Ld).catch(() => t) : t;
|
|
2013
2004
|
} catch (o) {
|
|
2014
2005
|
return t;
|
|
2015
2006
|
}
|
|
2016
2007
|
};
|
|
2017
|
-
var
|
|
2018
|
-
var
|
|
2019
|
-
var
|
|
2020
|
-
var
|
|
2021
|
-
var
|
|
2022
|
-
var
|
|
2023
|
-
let { items: t } = e, r = t.filter((a) =>
|
|
2024
|
-
return (0,
|
|
2025
|
-
};
|
|
2026
|
-
var
|
|
2008
|
+
var ya = Dd;
|
|
2009
|
+
var Xr = require("@transferwise/components");
|
|
2010
|
+
var sr = require("react/jsx-runtime");
|
|
2011
|
+
var Nd = ["positive", "neutral"];
|
|
2012
|
+
var Rd = ["warning", "negative"];
|
|
2013
|
+
var Bd = ({ component: e }) => {
|
|
2014
|
+
let { items: t } = e, r = t.filter((a) => Nd.includes(a.context)).map(({ text: a }) => a), o = t.filter((a) => Rd.includes(a.context)).map(({ text: a }) => a);
|
|
2015
|
+
return (0, sr.jsxs)("div", { className: j(e.margin || "md"), children: [e.title ? (0, sr.jsx)(Xr.Header, { title: e.title }) : null, (0, sr.jsx)(Xr.InstructionsList, { dos: r, donts: o })] });
|
|
2016
|
+
};
|
|
2017
|
+
var ha = Bd;
|
|
2027
2018
|
var G = require("react/jsx-runtime");
|
|
2028
2019
|
var Z = (e) => JSON.stringify(e);
|
|
2029
|
-
var
|
|
2020
|
+
var jd = (e) => {
|
|
2030
2021
|
let { components: t, model: r, submitted: o, errors: a, onModelChange: n, onAction: s, onPersistAsync: l, baseUrl: u } = e, d = (c) => {
|
|
2031
2022
|
switch (c.type) {
|
|
2032
2023
|
case "heading":
|
|
2033
|
-
return (0, G.jsx)(
|
|
2024
|
+
return (0, G.jsx)(ca, { component: c }, Z(c));
|
|
2034
2025
|
case "paragraph":
|
|
2035
|
-
return (0, G.jsx)(
|
|
2026
|
+
return (0, G.jsx)(Sa, { component: c }, Z(c));
|
|
2036
2027
|
case "image":
|
|
2037
|
-
return (0, G.jsx)(
|
|
2028
|
+
return (0, G.jsx)(ya, { component: c }, Z(c));
|
|
2038
2029
|
case "alert":
|
|
2039
2030
|
return (0, G.jsx)(se, { component: c }, Z(c));
|
|
2040
2031
|
case "review":
|
|
2041
|
-
return (0, G.jsx)(
|
|
2032
|
+
return (0, G.jsx)(ba, { component: c, onAction: s }, Z(c));
|
|
2042
2033
|
case "divider":
|
|
2043
|
-
return (0, G.jsx)(
|
|
2034
|
+
return (0, G.jsx)(jo, { component: c }, Z(c));
|
|
2044
2035
|
case "info":
|
|
2045
|
-
return (0, G.jsx)(
|
|
2036
|
+
return (0, G.jsx)(pa, { component: c }, Z(c));
|
|
2046
2037
|
case "instructions":
|
|
2047
|
-
return (0, G.jsx)(
|
|
2038
|
+
return (0, G.jsx)(ha, { component: c }, Z(c));
|
|
2048
2039
|
case "markdown":
|
|
2049
|
-
return (0, G.jsx)(
|
|
2040
|
+
return (0, G.jsx)(ua, { component: c }, Z(c));
|
|
2050
2041
|
case "columns":
|
|
2051
|
-
return (0, G.jsx)(
|
|
2042
|
+
return (0, G.jsx)(Ro, { component: c, model: r, submitted: o, errors: a, onModelChange: n, onAction: s, onPersistAsync: l }, Z(c));
|
|
2052
2043
|
case "form":
|
|
2053
|
-
return (0, G.jsx)(
|
|
2044
|
+
return (0, G.jsx)(la, { component: c, model: r, submitted: o, errors: a, onModelChange: n, onPersistAsync: l }, Z(b(i({}, c), { errors: a != null ? a : null })));
|
|
2054
2045
|
case "button":
|
|
2055
|
-
return (0, G.jsx)(
|
|
2046
|
+
return (0, G.jsx)(No, { component: c, onAction: s }, Z(c));
|
|
2056
2047
|
case "box":
|
|
2057
|
-
return (0, G.jsx)(
|
|
2048
|
+
return (0, G.jsx)(To, { component: c, model: r, submitted: o, errors: a, onModelChange: n, onAction: s, onPersistAsync: l }, Z(c));
|
|
2058
2049
|
case "decision":
|
|
2059
|
-
return (0, G.jsx)(
|
|
2050
|
+
return (0, G.jsx)(Bo, { component: c, onAction: s }, Z(c));
|
|
2060
2051
|
case "external":
|
|
2061
|
-
return (0, G.jsx)(
|
|
2052
|
+
return (0, G.jsx)(Vo, { component: c, onAction: s }, Z(c));
|
|
2062
2053
|
case "list":
|
|
2063
2054
|
case "status-list":
|
|
2064
|
-
return (0, G.jsx)(
|
|
2055
|
+
return (0, G.jsx)(ga, { component: c, onAction: s }, Z(c));
|
|
2065
2056
|
case "loading-indicator":
|
|
2066
|
-
return (0, G.jsx)(
|
|
2057
|
+
return (0, G.jsx)(mr, { component: c }, Z(c));
|
|
2067
2058
|
case "search":
|
|
2068
|
-
return (0, G.jsx)(
|
|
2059
|
+
return (0, G.jsx)(wa, { component: c, onAction: s }, Z(c));
|
|
2069
2060
|
default:
|
|
2070
2061
|
return (0, G.jsx)("div", {}, Z(c));
|
|
2071
2062
|
}
|
|
2072
2063
|
};
|
|
2073
|
-
return
|
|
2064
|
+
return tn() || u == null ? (0, G.jsx)(G.Fragment, { children: t.map(d) }) : (0, G.jsx)(Or, { baseUrl: u, children: t.map(d) });
|
|
2074
2065
|
};
|
|
2075
|
-
var me =
|
|
2066
|
+
var me = jd;
|
|
2067
|
+
var vs = require("@transferwise/components");
|
|
2068
|
+
var Ut = require("react/jsx-runtime");
|
|
2069
|
+
var Vd = ({ component: e }) => (0, Ut.jsxs)("div", { className: j(e.margin || "md"), children: [e.title ? (0, Ut.jsxs)("h4", { className: "m-b-2", children: [" ", e.title, " "] }) : null, e.items.map(Ud)] });
|
|
2070
|
+
var Ud = ({ title: e, description: t, icon: r, status: o }) => {
|
|
2071
|
+
let a = i(i({ key: `${e}/${t || ""}`, title: e, description: t }, r != null && r.name ? { icon: (0, Ut.jsx)(Je, { type: r.name }) } : {}), o ? { status: qd[o] } : {});
|
|
2072
|
+
return (0, Ut.jsx)(vs.Summary, i({}, a));
|
|
2073
|
+
};
|
|
2074
|
+
var zd = { done: "done", pending: "pending", "not-done": "notDone" };
|
|
2075
|
+
var Hd = { positive: "done", warning: "pending", neutral: "notDone" };
|
|
2076
|
+
var qd = i(i({}, zd), Hd);
|
|
2077
|
+
var ga = Vd;
|
|
2076
2078
|
var As = require("@transferwise/components");
|
|
2077
|
-
var
|
|
2078
|
-
var
|
|
2079
|
-
var Hd = ({ title: e, description: t, icon: r, status: o }) => {
|
|
2080
|
-
let a = i(i({ key: `${e}/${t || ""}`, title: e, description: t }, r != null && r.name ? { icon: (0, zt.jsx)(Je, { type: r.name }) } : {}), o ? { status: $d[o] } : {});
|
|
2081
|
-
return (0, zt.jsx)(As.Summary, i({}, a));
|
|
2082
|
-
};
|
|
2083
|
-
var qd = { done: "done", pending: "pending", "not-done": "notDone" };
|
|
2084
|
-
var Gd = { positive: "done", warning: "pending", neutral: "notDone" };
|
|
2085
|
-
var $d = i(i({}, qd), Gd);
|
|
2086
|
-
var ba = zd;
|
|
2087
|
-
var Os = require("@transferwise/components");
|
|
2088
|
-
var Ps = require("react/jsx-runtime");
|
|
2089
|
-
var Wd = ({ component: e }) => {
|
|
2079
|
+
var Os = require("react/jsx-runtime");
|
|
2080
|
+
var Gd = ({ component: e }) => {
|
|
2090
2081
|
let { margin: t, size: r = "md" } = e;
|
|
2091
|
-
return (0,
|
|
2082
|
+
return (0, Os.jsx)(As.Loader, { size: r, classNames: { "tw-loader": `tw-loader m-x-auto ${j(t)}` }, "data-testid": "loading-indicator" });
|
|
2092
2083
|
};
|
|
2093
|
-
var
|
|
2094
|
-
var
|
|
2095
|
-
var
|
|
2096
|
-
var
|
|
2097
|
-
var
|
|
2098
|
-
var
|
|
2099
|
-
var
|
|
2100
|
-
function
|
|
2101
|
-
let e = (0,
|
|
2102
|
-
return e ? e.createSnackbar :
|
|
2084
|
+
var mr = Gd;
|
|
2085
|
+
var Is = require("@transferwise/components");
|
|
2086
|
+
var Ds = require("react-intl");
|
|
2087
|
+
var Ps = require("react-intl");
|
|
2088
|
+
var Fa = (0, Ps.defineMessages)({ copy: { id: "dynamicFlows.DynamicParagraph.copy", defaultMessage: "Copy", description: "Copy to clipboard button label." }, copied: { id: "dynamicFlows.DynamicParagraph.copied", defaultMessage: "Copied to clipboard", description: "Appears in a snackbar when the copy operation succeeds." } });
|
|
2089
|
+
var Ms = require("@transferwise/components");
|
|
2090
|
+
var ks = require("react");
|
|
2091
|
+
function Es() {
|
|
2092
|
+
let e = (0, ks.useContext)(Ms.SnackbarContext);
|
|
2093
|
+
return e ? e.createSnackbar : $d;
|
|
2103
2094
|
}
|
|
2104
|
-
function
|
|
2095
|
+
function $d() {
|
|
2105
2096
|
}
|
|
2106
2097
|
var Qe = require("react/jsx-runtime");
|
|
2107
|
-
var
|
|
2108
|
-
var
|
|
2109
|
-
var
|
|
2110
|
-
let { formatMessage: t } = (0,
|
|
2098
|
+
var Wd = ({ component: e }) => e.control === "copyable" ? (0, Qe.jsx)(Kd, { component: e }) : (0, Qe.jsx)(_d, { component: e });
|
|
2099
|
+
var _d = ({ component: e }) => (0, Qe.jsxs)("p", { className: Ne(e), children: [" ", e.text, " "] });
|
|
2100
|
+
var Kd = ({ component: e }) => {
|
|
2101
|
+
let { formatMessage: t } = (0, Ds.useIntl)(), r = Es(), { text: o } = e, a = () => {
|
|
2111
2102
|
var s;
|
|
2112
|
-
(s = navigator.clipboard) == null || s.writeText(o).then(() => r({ text: t(
|
|
2103
|
+
(s = navigator.clipboard) == null || s.writeText(o).then(() => r({ text: t(Fa.copied) })).catch(Jd);
|
|
2113
2104
|
}, n = Ne({ align: e.align }) + " form-control";
|
|
2114
|
-
return (0, Qe.jsxs)("div", { className: Ne(e), children: [(0, Qe.jsx)("input", { type: "text", className: n, value: o, readOnly: true, style: { textOverflow: "ellipsis" } }), (0, Qe.jsx)(
|
|
2105
|
+
return (0, Qe.jsxs)("div", { className: Ne(e), children: [(0, Qe.jsx)("input", { type: "text", className: n, value: o, readOnly: true, style: { textOverflow: "ellipsis" } }), (0, Qe.jsx)(Is.Button, { block: true, onClick: a, className: j("sm"), children: t(Fa.copy) })] });
|
|
2115
2106
|
};
|
|
2116
|
-
function
|
|
2107
|
+
function Jd() {
|
|
2117
2108
|
}
|
|
2118
|
-
var
|
|
2119
|
-
var
|
|
2109
|
+
var Sa = Wd;
|
|
2110
|
+
var Ls = require("@transferwise/components");
|
|
2120
2111
|
var ae = require("react/jsx-runtime");
|
|
2121
|
-
var
|
|
2122
|
-
var
|
|
2123
|
-
var
|
|
2124
|
-
var
|
|
2112
|
+
var Xd = (e, t) => t.fields.map(({ label: r, value: o, help: a }, n) => ({ key: String(n), title: r, value: Yd(o, a, e) }));
|
|
2113
|
+
var Yd = (e, t, r) => t ? r === "HORIZONTAL_RIGHT_ALIGNED" ? (0, ae.jsxs)(ae.Fragment, { children: [(0, ae.jsx)(Ve, { help: t }), " ", e] }) : (0, ae.jsxs)(ae.Fragment, { children: [e, " ", (0, ae.jsx)(Ve, { help: t })] }) : e;
|
|
2114
|
+
var Zd = (e) => (e.control || e.orientation) === "horizontal" ? "HORIZONTAL_RIGHT_ALIGNED" : "VERTICAL_ONE_COLUMN";
|
|
2115
|
+
var Qd = (e) => {
|
|
2125
2116
|
let t = e.component, r = j(t.margin || "xs"), o = (n) => (0, ae.jsx)("a", { href: n.url, className: "pull-right", role: "button", onClick: (s) => {
|
|
2126
2117
|
s.preventDefault(), e.onAction(n);
|
|
2127
|
-
}, children: n.title }), a =
|
|
2128
|
-
return (0, ae.jsxs)(ae.Fragment, { children: [t.title && (0, ae.jsxs)("h6", { className: `m-b-2 ${r}`, children: [t.title, t.action && o(t.action)] }), (0, ae.jsx)("div", { className: t.title ? "" : r, children: (0, ae.jsx)(
|
|
2129
|
-
};
|
|
2130
|
-
var
|
|
2131
|
-
var
|
|
2132
|
-
var
|
|
2133
|
-
var
|
|
2134
|
-
var
|
|
2135
|
-
var
|
|
2136
|
-
var js = require("react-intl");
|
|
2118
|
+
}, children: n.title }), a = Zd(t);
|
|
2119
|
+
return (0, ae.jsxs)(ae.Fragment, { children: [t.title && (0, ae.jsxs)("h6", { className: `m-b-2 ${r}`, children: [t.title, t.action && o(t.action)] }), (0, ae.jsx)("div", { className: t.title ? "" : r, children: (0, ae.jsx)(Ls.DefinitionList, { layout: a, definitions: Xd(a, t) }) })] });
|
|
2120
|
+
};
|
|
2121
|
+
var ba = Qd;
|
|
2122
|
+
var Qr = require("react");
|
|
2123
|
+
var Ts = require("@transferwise/components");
|
|
2124
|
+
var Yr = require("react/jsx-runtime");
|
|
2125
|
+
var Ns = ({ title: e, value: t, onFocus: r, onChange: o }) => (0, Yr.jsxs)("label", { className: "control-label d-inline", children: [e, (0, Yr.jsx)(Ts.Input, { type: "text", value: t, onFocus: r, onChange: (a) => o(a.currentTarget.value) })] });
|
|
2126
|
+
var Zr = require("@transferwise/components");
|
|
2137
2127
|
var Bs = require("react-intl");
|
|
2138
|
-
var
|
|
2139
|
-
var
|
|
2140
|
-
var
|
|
2141
|
-
var
|
|
2142
|
-
|
|
2143
|
-
|
|
2128
|
+
var Rs = require("react-intl");
|
|
2129
|
+
var zt = (0, Rs.defineMessages)({ errorAlert: { id: "dynamicFlows.ErrorBoundary.errorAlert", defaultMessage: "Oops. 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." } });
|
|
2130
|
+
var ht = require("react/jsx-runtime");
|
|
2131
|
+
var js = ({ results: e, emptyMessage: t, onSelect: r }) => e.length === 0 ? (0, ht.jsx)("p", { className: "m-t-2", children: t }) : (0, ht.jsx)(Zr.NavigationOptionsList, { children: e.map((o) => (0, ht.jsx)(Zr.NavigationOption, { title: o.title, content: o.description, media: mt(o), showMediaCircle: false, showMediaAtAllSizes: true, onClick: () => r(o) }, JSON.stringify(o))) });
|
|
2132
|
+
var Vs = ({ onRetrySearch: e }) => {
|
|
2133
|
+
let t = (0, Bs.useIntl)();
|
|
2134
|
+
return (0, ht.jsxs)("p", { className: "m-t-2", children: [t.formatMessage(zt.errorAlert), "\xA0", (0, ht.jsx)("a", { href: "/", onClick: (r) => {
|
|
2144
2135
|
r.preventDefault(), e();
|
|
2145
|
-
}, children: t.formatMessage(
|
|
2136
|
+
}, children: t.formatMessage(zt.retry) })] });
|
|
2146
2137
|
};
|
|
2147
|
-
var
|
|
2148
|
-
var
|
|
2149
|
-
var
|
|
2150
|
-
let [t, r] = (0,
|
|
2138
|
+
var Ht = require("react");
|
|
2139
|
+
var Us = { "Content-Type": "application/json" };
|
|
2140
|
+
var zs = (e) => {
|
|
2141
|
+
let [t, r] = (0, Ht.useState)({ status: "idle" }), o = (0, Ht.useRef)(null), a = te(), n = (0, Ht.useCallback)(async (d, { url: c, method: h, param: f } = e) => {
|
|
2151
2142
|
var p;
|
|
2152
2143
|
if ((p = o.current) == null || p.abort(), !d) {
|
|
2153
2144
|
r({ status: "idle" });
|
|
@@ -2157,7 +2148,7 @@ var require_main_min = __commonJS({
|
|
|
2157
2148
|
let m = o.current.signal;
|
|
2158
2149
|
r({ status: "loading" });
|
|
2159
2150
|
try {
|
|
2160
|
-
let S = await (h === "GET" ? a(
|
|
2151
|
+
let S = await (h === "GET" ? a(ru(c, f, d), { method: h, signal: m, headers: Us }) : a(c, { method: h, signal: m, headers: Us, body: JSON.stringify({ [f]: d }) }));
|
|
2161
2152
|
s(S, d);
|
|
2162
2153
|
} catch (y) {
|
|
2163
2154
|
l(y, d);
|
|
@@ -2165,27 +2156,27 @@ var require_main_min = __commonJS({
|
|
|
2165
2156
|
}, [a, JSON.stringify(e)]), s = async (d, c) => {
|
|
2166
2157
|
if (d.ok) {
|
|
2167
2158
|
let h = await d.json().catch(() => null);
|
|
2168
|
-
if (
|
|
2159
|
+
if (eu(h)) {
|
|
2169
2160
|
r({ status: "success", results: h.results });
|
|
2170
2161
|
return;
|
|
2171
2162
|
}
|
|
2172
2163
|
}
|
|
2173
2164
|
r({ status: "error" });
|
|
2174
2165
|
}, l = (d, c) => {
|
|
2175
|
-
|
|
2166
|
+
tu(d) === false && r({ status: "error" });
|
|
2176
2167
|
}, u = t.status === "success" ? t.results : [];
|
|
2177
2168
|
return { status: t.status, results: u, search: n };
|
|
2178
2169
|
};
|
|
2179
|
-
var
|
|
2180
|
-
var
|
|
2181
|
-
var
|
|
2170
|
+
var eu = (e) => N(e) && "results" in e && q(e.results) && e.results.every((t) => N(t) && "title" in t && "type" in t && "value" in t);
|
|
2171
|
+
var tu = (e) => e instanceof DOMException && e.name === "AbortError";
|
|
2172
|
+
var ru = (e, t, r) => {
|
|
2182
2173
|
let [o, a] = e.split("?"), n = new URLSearchParams(a);
|
|
2183
2174
|
return n.set(t, r), `${o}?${n.toString()}`;
|
|
2184
2175
|
};
|
|
2185
|
-
var
|
|
2186
|
-
var
|
|
2187
|
-
var
|
|
2188
|
-
let [r, o] = (0,
|
|
2176
|
+
var gt = require("react/jsx-runtime");
|
|
2177
|
+
var ou = 400;
|
|
2178
|
+
var au = ({ component: e, onAction: t }) => {
|
|
2179
|
+
let [r, o] = (0, Qr.useState)(""), { title: a, margin: n, url: s, method: l, param: u, emptyMessage: d } = e, { status: c, results: h, search: f } = zs({ url: s, method: l, param: u }), m = Q(), p = (0, Qr.useMemo)(() => _e(f, ou), [f]), y = () => {
|
|
2189
2180
|
m("Dynamic Flow - Search Started", {});
|
|
2190
2181
|
}, S = (w) => {
|
|
2191
2182
|
o(w), p(w);
|
|
@@ -2198,13 +2189,13 @@ var require_main_min = __commonJS({
|
|
|
2198
2189
|
}, F = () => {
|
|
2199
2190
|
o(r), f(r);
|
|
2200
2191
|
};
|
|
2201
|
-
return (0,
|
|
2192
|
+
return (0, gt.jsxs)("div", { className: j(n), children: [(0, gt.jsx)(Ns, { title: a, value: r, onChange: S, onFocus: y }), c === "loading" && (0, gt.jsx)(mr, { component: { type: "loading-indicator", size: "sm" } }), c === "error" && (0, gt.jsx)(Vs, { onRetrySearch: F }), c === "success" && (0, gt.jsx)(js, { results: h, emptyMessage: d, onSelect: g })] });
|
|
2202
2193
|
};
|
|
2203
|
-
var
|
|
2204
|
-
var
|
|
2205
|
-
var
|
|
2206
|
-
var
|
|
2207
|
-
var
|
|
2194
|
+
var wa = au;
|
|
2195
|
+
var de = require("react/jsx-runtime");
|
|
2196
|
+
var Ca = (e) => E(e) || X(e);
|
|
2197
|
+
var nu = (e) => e.type === "boolean" && Ca(e.default) ? false : e.default;
|
|
2198
|
+
var qs = (e) => {
|
|
2208
2199
|
var L, P, B;
|
|
2209
2200
|
let t = (k) => {
|
|
2210
2201
|
f(true), o(a(k), "user");
|
|
@@ -2216,35 +2207,35 @@ var require_main_min = __commonJS({
|
|
|
2216
2207
|
c(_), _ !== d && e.onChange({ model: _, triggerSchema: e.schema, triggerModel: _, lastTriggerModel: d, type: ne });
|
|
2217
2208
|
}, a = (k) => $e(k, e.schema), n = () => p(true), s = () => {
|
|
2218
2209
|
p(false), S(true), e.onBlur && e.onBlur();
|
|
2219
|
-
}, [l, u] = (0,
|
|
2220
|
-
let k =
|
|
2221
|
-
|
|
2210
|
+
}, [l, u] = (0, ce.useState)((L = e.model) != null ? L : null), [d, c] = (0, ce.useState)((P = e.model) != null ? P : null), [h, f] = (0, ce.useState)(false), [m, p] = (0, ce.useState)(false), [y, S] = (0, ce.useState)(false), [g, F] = (0, ce.useState)([]), w = (0, ce.useMemo)(() => e.schema.$id || Me(), [e.schema.$id]), A = () => {
|
|
2211
|
+
let k = nu(e.schema);
|
|
2212
|
+
Ca(l) && !Ca(k) && o(k, "init"), e.schema.const && o(e.schema.const, "init");
|
|
2222
2213
|
}, O = () => {
|
|
2223
2214
|
F(r(l));
|
|
2224
2215
|
}, x = e.schema.const, M = e.schema.hidden || x;
|
|
2225
|
-
(0,
|
|
2216
|
+
(0, ce.useEffect)(O, [e.model, e.submitted]), (0, ce.useEffect)(A, [e.schema]), (0, ce.useEffect)(() => {
|
|
2226
2217
|
var ne;
|
|
2227
2218
|
let k = (ne = e.model) != null ? ne : null;
|
|
2228
2219
|
k !== l && u(k);
|
|
2229
2220
|
}, [e.model]);
|
|
2230
2221
|
let R = { "form-group": true, "has-error": (e.submitted || !h) && !!e.errors || (e.submitted || h && y) && !!g.length, "has-info": m && !!e.schema.description || !!e.infoMessage }, v = e.schema.format !== "file" && e.schema.type !== "boolean", T = e.schema.help, H = `${w}-feedback`;
|
|
2231
|
-
return M ? null : (0,
|
|
2222
|
+
return M ? null : (0, de.jsxs)(de.Fragment, { children: [e.schema.alert && (0, de.jsx)(se, { component: e.schema.alert }), (0, de.jsxs)("div", { className: (0, Hs.default)(R), children: [v && (0, de.jsxs)("div", { className: "d-inline-block", children: [(0, de.jsx)("label", { className: "control-label d-inline", htmlFor: w, children: e.schema.title }), !!T && (0, de.jsx)(Ve, { help: T })] }), !v && !!T && (0, de.jsx)(Ve, { help: T }), (0, de.jsx)(ar, { id: w, schema: e.schema, value: l, disabled: !!e.disabled, onChange: t, onFocus: n, onBlur: s, describedBy: H }), (0, de.jsx)(Be, { id: H, changed: h, focused: m, blurred: y, submitted: e.submitted, errors: (B = e.errors) != null ? B : null, schema: e.schema, validations: g, infoMessage: e.infoMessage })] })] });
|
|
2232
2223
|
};
|
|
2233
|
-
|
|
2234
|
-
var yt =
|
|
2235
|
-
var
|
|
2236
|
-
var
|
|
2237
|
-
var
|
|
2224
|
+
qs.defaultProps = { required: false, disabled: false, onBlur: null };
|
|
2225
|
+
var yt = qs;
|
|
2226
|
+
var _s = require("react/jsx-runtime");
|
|
2227
|
+
var ea = (e, t) => t[e];
|
|
2228
|
+
var $s = (e, t) => {
|
|
2238
2229
|
var r;
|
|
2239
2230
|
return (r = t.validation) == null ? void 0 : r[e];
|
|
2240
2231
|
};
|
|
2241
|
-
var
|
|
2242
|
-
var
|
|
2243
|
-
let { schema: t, required: r, submitted: o, errors: a, onChange: n, onPersistAsync: s } = e, l = (0,
|
|
2244
|
-
(0,
|
|
2245
|
-
|
|
2232
|
+
var iu = /* @__PURE__ */ new Set([U.RADIO, U.SELECT, U.DATELOOKUP, U.FILE, U.UPLOAD]);
|
|
2233
|
+
var Ws = (e) => {
|
|
2234
|
+
let { schema: t, required: r, submitted: o, errors: a, onChange: n, onPersistAsync: s } = e, l = (0, Gs.useIntl)(), u = te(), d = Q(), [c, h] = (0, St.useState)(null), f = Ks(c), [m, p] = (0, St.useState)(null), [y, S] = (0, St.useState)(false), [g, F] = (0, St.useState)(null);
|
|
2235
|
+
(0, St.useEffect)(() => {
|
|
2236
|
+
iu.has(Xo(t.persistAsync.schema)) && x();
|
|
2246
2237
|
}, [c]);
|
|
2247
|
-
let w = () => p(l.formatMessage(
|
|
2238
|
+
let w = () => p(l.formatMessage(Qt.genericError)), A = async (v, T) => {
|
|
2248
2239
|
let H = O(), L = { [T.param]: v };
|
|
2249
2240
|
S(true);
|
|
2250
2241
|
try {
|
|
@@ -2255,12 +2246,12 @@ var require_main_min = __commonJS({
|
|
|
2255
2246
|
if (!N(k))
|
|
2256
2247
|
throw new Error("Response is not an object");
|
|
2257
2248
|
let { idProperty: ne, param: ve } = t.persistAsync;
|
|
2258
|
-
if (
|
|
2259
|
-
let _ =
|
|
2249
|
+
if (Qa(B.status)) {
|
|
2250
|
+
let _ = ea(ne, k);
|
|
2260
2251
|
n({ model: _, triggerSchema: t, triggerModel: _ });
|
|
2261
|
-
} else if (
|
|
2262
|
-
let { validation: _ } = k,
|
|
2263
|
-
p(
|
|
2252
|
+
} else if (Cr(B.status)) {
|
|
2253
|
+
let { validation: _ } = k, ue = N(_) && (_ == null ? void 0 : _[ve]) || null;
|
|
2254
|
+
p(ue), n({ model: null, triggerSchema: t, triggerModel: null });
|
|
2264
2255
|
} else
|
|
2265
2256
|
w();
|
|
2266
2257
|
d("Dynamic Flow - PersistAsync", { status: "success", schemaId: t.$id });
|
|
@@ -2278,14 +2269,14 @@ var require_main_min = __commonJS({
|
|
|
2278
2269
|
}, R = ({ model: v }) => {
|
|
2279
2270
|
p(null), $(v, t.persistAsync.schema) && h(v);
|
|
2280
2271
|
};
|
|
2281
|
-
return (0,
|
|
2272
|
+
return (0, _s.jsx)(yt, { required: r, submitted: o || y, schema: t.persistAsync.schema, errors: m || a, model: null, infoMessage: null, onChange: R, onBlur: M });
|
|
2282
2273
|
};
|
|
2283
|
-
|
|
2284
|
-
var
|
|
2274
|
+
Ws.defaultProps = { required: false };
|
|
2275
|
+
var Zo = Ws;
|
|
2285
2276
|
var Ci = (e) => {
|
|
2286
|
-
let [t, r] = (0,
|
|
2277
|
+
let [t, r] = (0, Js.useState)(null), o = te(), a = (0, Xs.useIntl)(), { schema: n } = e;
|
|
2287
2278
|
async function s(f) {
|
|
2288
|
-
let m = f instanceof Blob ? !
|
|
2279
|
+
let m = f instanceof Blob ? !Pt(n) : !$(f, n);
|
|
2289
2280
|
return (E(f) || m) && h(), await d(f);
|
|
2290
2281
|
}
|
|
2291
2282
|
let l = () => {
|
|
@@ -2294,7 +2285,7 @@ var require_main_min = __commonJS({
|
|
|
2294
2285
|
return r(f), f.signal;
|
|
2295
2286
|
};
|
|
2296
2287
|
function u(f) {
|
|
2297
|
-
let m =
|
|
2288
|
+
let m = Pt(n), p = l(), y = e.param, S = m ? su(y, f) : JSON.stringify({ [y]: f });
|
|
2298
2289
|
return { method: e.method, headers: i({}, !m && { "Content-Type": "application/json" }), body: S, signal: p };
|
|
2299
2290
|
}
|
|
2300
2291
|
async function d(f) {
|
|
@@ -2317,29 +2308,29 @@ var require_main_min = __commonJS({
|
|
|
2317
2308
|
if (f.status === 422) {
|
|
2318
2309
|
let m = await f.json();
|
|
2319
2310
|
if (N(m)) {
|
|
2320
|
-
let p =
|
|
2311
|
+
let p = $s(e.param, m);
|
|
2321
2312
|
if (I(p))
|
|
2322
2313
|
throw new Error(p);
|
|
2323
2314
|
}
|
|
2324
2315
|
}
|
|
2325
|
-
throw new Error(a.formatMessage(
|
|
2316
|
+
throw new Error(a.formatMessage(Qt.genericError));
|
|
2326
2317
|
}
|
|
2327
2318
|
let h = (f) => {
|
|
2328
|
-
let m =
|
|
2319
|
+
let m = mu(f) ? f.message : a.formatMessage(Qt.genericError);
|
|
2329
2320
|
throw new Error(m);
|
|
2330
2321
|
};
|
|
2331
2322
|
return s;
|
|
2332
2323
|
};
|
|
2333
|
-
function
|
|
2324
|
+
function su(e, t) {
|
|
2334
2325
|
let r = new FormData();
|
|
2335
2326
|
return t !== null && r.append(e, t), r;
|
|
2336
2327
|
}
|
|
2337
|
-
function
|
|
2328
|
+
function mu(e) {
|
|
2338
2329
|
return N(e) && "message" in e && typeof e.message == "string";
|
|
2339
2330
|
}
|
|
2340
2331
|
var et = require("react");
|
|
2341
|
-
function
|
|
2342
|
-
let s = (0, et.useRef)(a), l = (0, et.useRef)(n), u = (0, et.useMemo)(() =>
|
|
2332
|
+
function Lr({ asyncFn: e, interval: t, maxAttempts: r, maxConsecutiveFails: o, onPollingResponse: a, onFailure: n }) {
|
|
2333
|
+
let s = (0, et.useRef)(a), l = (0, et.useRef)(n), u = (0, et.useMemo)(() => lu(e, r, o, (d) => s.current(d), () => l.current()), [e, r, o]);
|
|
2343
2334
|
(0, et.useEffect)(() => {
|
|
2344
2335
|
if (t > 0) {
|
|
2345
2336
|
let d = setInterval(() => {
|
|
@@ -2351,7 +2342,7 @@ var require_main_min = __commonJS({
|
|
|
2351
2342
|
s.current = a, l.current = n;
|
|
2352
2343
|
}, [a, n]);
|
|
2353
2344
|
}
|
|
2354
|
-
function
|
|
2345
|
+
function lu(e, t, r, o, a) {
|
|
2355
2346
|
let n = true, s = 0, l = 0;
|
|
2356
2347
|
return e ? () => {
|
|
2357
2348
|
n && (l++, e().then((u) => {
|
|
@@ -2364,65 +2355,65 @@ var require_main_min = __commonJS({
|
|
|
2364
2355
|
} : () => {
|
|
2365
2356
|
};
|
|
2366
2357
|
}
|
|
2367
|
-
var
|
|
2368
|
-
var
|
|
2369
|
-
let t = (0,
|
|
2370
|
-
return (0,
|
|
2358
|
+
var eo = require("react");
|
|
2359
|
+
var Ks = (e) => {
|
|
2360
|
+
let t = (0, eo.useRef)();
|
|
2361
|
+
return (0, eo.useEffect)(() => {
|
|
2371
2362
|
t.current = e;
|
|
2372
2363
|
}, [e]), t.current;
|
|
2373
2364
|
};
|
|
2374
|
-
var
|
|
2375
|
-
function
|
|
2376
|
-
let r = te(), o = (0,
|
|
2365
|
+
var lr = require("react");
|
|
2366
|
+
function Ys(e, t) {
|
|
2367
|
+
let r = te(), o = (0, lr.useMemo)(() => {
|
|
2377
2368
|
if (e)
|
|
2378
2369
|
return () => r(e.url).then((n) => {
|
|
2379
2370
|
if (n.ok)
|
|
2380
2371
|
return n.json().then((s) => s).catch((s) => null);
|
|
2381
2372
|
throw new Error("failed");
|
|
2382
2373
|
});
|
|
2383
|
-
}, [e, r]), a = (0,
|
|
2384
|
-
|
|
2374
|
+
}, [e, r]), a = (0, lr.useCallback)((n) => n != null && n.action ? (t(n.action), false) : true, [t]);
|
|
2375
|
+
Lr({ asyncFn: o, interval: 1e3 * ((e == null ? void 0 : e.interval) || 0), maxAttempts: (e == null ? void 0 : e.maxAttempts) || 0, maxConsecutiveFails: 1, onPollingResponse: a, onFailure: (0, lr.useCallback)(() => {
|
|
2385
2376
|
e && t(e.onError.action);
|
|
2386
2377
|
}, [t, e]) });
|
|
2387
2378
|
}
|
|
2388
|
-
var
|
|
2389
|
-
var
|
|
2379
|
+
var Zs = require("react/jsx-runtime");
|
|
2380
|
+
var cu = (e, t) => {
|
|
2390
2381
|
var o;
|
|
2391
|
-
if (
|
|
2382
|
+
if (vt(e))
|
|
2392
2383
|
return [];
|
|
2393
|
-
let r =
|
|
2384
|
+
let r = _t(e, t);
|
|
2394
2385
|
return Ge({ layout: r, schemas: e.schemas || [], actions: e.actions || [], model: (o = e.model) != null ? o : null });
|
|
2395
2386
|
};
|
|
2396
|
-
var
|
|
2397
|
-
let { stepSpecification: t, stepLayoutOptions: r, submitted: o, model: a, formErrors: n, onModelChange: s } = e, l =
|
|
2387
|
+
var du = (e) => {
|
|
2388
|
+
let { stepSpecification: t, stepLayoutOptions: r, submitted: o, model: a, formErrors: n, onModelChange: s } = e, l = cu(t, r), { loading: u, registerPersistAsyncPromise: d } = wr(), c = Q(), h = u ? () => {
|
|
2398
2389
|
c("Dynamic Flow - onAction supressed", { reason: "LayoutStep - loading state" });
|
|
2399
2390
|
} : e.onAction;
|
|
2400
|
-
return
|
|
2391
|
+
return Ys(t.polling, h), (0, Zs.jsx)(me, { components: l, submitted: o, model: a, errors: n, onAction: h, onModelChange: s, onPersistAsync: d });
|
|
2401
2392
|
};
|
|
2402
|
-
var
|
|
2403
|
-
var
|
|
2393
|
+
var to = du;
|
|
2394
|
+
var io = require("react");
|
|
2404
2395
|
var Ce = require("react");
|
|
2405
|
-
var
|
|
2406
|
-
var
|
|
2407
|
-
var
|
|
2408
|
-
var
|
|
2396
|
+
var Fm = require("react-intl");
|
|
2397
|
+
var Cm = qe(Qs());
|
|
2398
|
+
var em = require("react-intl");
|
|
2399
|
+
var dr = (0, em.defineMessages)({ reviewSubmit: { id: "dynamicFlows.CameraCapture.reviewSubmit", defaultMessage: "Yes, submit", description: "Accept and submit the image taken with the camera" }, reviewRetry: { id: "dynamicFlows.CameraCapture.reviewRetry", defaultMessage: "No, try again", description: "Image taken with camera is not good, don't submit, and retake the image" }, reviewInstructions: { id: "dynamicFlows.CameraCapture.reviewInstructions", defaultMessage: "Is your picture clear, readable and complete?", description: "After taking an image with the camera, prompt user to review the image" } });
|
|
2409
2400
|
var Fe = require("@transferwise/components");
|
|
2410
|
-
var
|
|
2401
|
+
var tm = require("react-intl");
|
|
2411
2402
|
var we = require("react/jsx-runtime");
|
|
2412
|
-
var
|
|
2413
|
-
var
|
|
2414
|
-
let r = (0,
|
|
2415
|
-
return (0, we.jsx)("div", { className: "bottom-bar p-x-2", children: (0, we.jsx)("div", { className: "row", children: (0, we.jsxs)("div", { className: "col-xs-12 col-md-6 col-md-offset-3", children: [(0, we.jsx)(Fe.Button, { className: "m-b-1", block: true, size: Fe.Size.MEDIUM, type: Fe.ControlType.ACCENT, onClick: e, children: r.formatMessage(
|
|
2416
|
-
};
|
|
2417
|
-
var
|
|
2418
|
-
var
|
|
2419
|
-
var
|
|
2403
|
+
var rm = ({ onCapture: e }) => (0, we.jsx)("div", { className: "bottom-bar", children: (0, we.jsx)(uu, { onClick: e }) });
|
|
2404
|
+
var om = ({ onSubmit: e, onRetry: t }) => {
|
|
2405
|
+
let r = (0, tm.useIntl)();
|
|
2406
|
+
return (0, we.jsx)("div", { className: "bottom-bar p-x-2", children: (0, we.jsx)("div", { className: "row", children: (0, we.jsxs)("div", { className: "col-xs-12 col-md-6 col-md-offset-3", children: [(0, we.jsx)(Fe.Button, { className: "m-b-1", block: true, size: Fe.Size.MEDIUM, type: Fe.ControlType.ACCENT, onClick: e, children: r.formatMessage(dr.reviewSubmit) }), (0, we.jsx)(Fe.Button, { className: "m-b-2", block: true, size: Fe.Size.MEDIUM, type: Fe.ControlType.ACCENT, priority: Fe.Priority.SECONDARY, onClick: t, children: r.formatMessage(dr.reviewRetry) })] }) }) });
|
|
2407
|
+
};
|
|
2408
|
+
var uu = ({ onClick: e }) => (0, we.jsx)("button", { type: "button", className: "camera-capture-btn m-b-2", "data-testid": "camera-capture-button", onClick: e, children: (0, we.jsx)("span", { className: "camera-capture-btn-inner" }) });
|
|
2409
|
+
var oo = require("react");
|
|
2410
|
+
var am = (e) => {
|
|
2420
2411
|
var r;
|
|
2421
|
-
let { facingMode: t } = ((r =
|
|
2412
|
+
let { facingMode: t } = ((r = ro(e)) == null ? void 0 : r.getSettings()) || {};
|
|
2422
2413
|
return t === "user" || t === void 0;
|
|
2423
2414
|
};
|
|
2424
|
-
var
|
|
2425
|
-
var
|
|
2415
|
+
var nm = (e) => !!((e == null ? void 0 : e.label) || "").match(/camera2? 0/g);
|
|
2416
|
+
var im = async (e) => {
|
|
2426
2417
|
let t = document.createElement("canvas");
|
|
2427
2418
|
if (e) {
|
|
2428
2419
|
t.setAttribute("height", `${e.videoHeight}`), t.setAttribute("width", `${e.videoWidth}`);
|
|
@@ -2431,35 +2422,35 @@ var require_main_min = __commonJS({
|
|
|
2431
2422
|
}
|
|
2432
2423
|
return t;
|
|
2433
2424
|
};
|
|
2434
|
-
var
|
|
2425
|
+
var sm = async () => {
|
|
2435
2426
|
var e, t;
|
|
2436
2427
|
return (await ((t = (e = navigator == null ? void 0 : navigator.mediaDevices) == null ? void 0 : e.enumerateDevices) == null ? void 0 : t.call(e)) || []).filter((r) => r.kind === "videoinput");
|
|
2437
2428
|
};
|
|
2438
|
-
var
|
|
2429
|
+
var mm = async () => {
|
|
2439
2430
|
var e, t;
|
|
2440
2431
|
return (await ((t = (e = navigator == null ? void 0 : navigator.mediaDevices) == null ? void 0 : e.enumerateDevices) == null ? void 0 : t.call(e)) || []).filter((r) => r.kind === "videoinput").map((r) => r.label);
|
|
2441
2432
|
};
|
|
2442
|
-
var
|
|
2433
|
+
var lm = async (e) => {
|
|
2443
2434
|
var r, o, a;
|
|
2444
|
-
let t =
|
|
2435
|
+
let t = va(e);
|
|
2445
2436
|
return (a = (await ((o = (r = navigator == null ? void 0 : navigator.mediaDevices) == null ? void 0 : r.enumerateDevices) == null ? void 0 : o.call(r)) || []).filter((n) => n.kind === "videoinput").find((n) => n.deviceId === (t == null ? void 0 : t.deviceId))) == null ? void 0 : a.label;
|
|
2446
2437
|
};
|
|
2447
|
-
var
|
|
2438
|
+
var ro = (e) => {
|
|
2448
2439
|
var t;
|
|
2449
2440
|
return (((t = e == null ? void 0 : e.getVideoTracks) == null ? void 0 : t.call(e)) || [])[0];
|
|
2450
2441
|
};
|
|
2451
|
-
var
|
|
2442
|
+
var va = (e) => {
|
|
2452
2443
|
var t, r;
|
|
2453
|
-
return (r = (t =
|
|
2444
|
+
return (r = (t = ro(e)) == null ? void 0 : t.getCapabilities) == null ? void 0 : r.call(t);
|
|
2454
2445
|
};
|
|
2455
|
-
var
|
|
2456
|
-
let [t, r] = (0,
|
|
2457
|
-
(0,
|
|
2446
|
+
var cm = (e) => {
|
|
2447
|
+
let [t, r] = (0, oo.useState)(), o = { facingMode: e === "front" ? "user" : "environment", height: { min: 480, max: 1080, ideal: 720 }, width: { min: 640, max: 1920, ideal: 1280 }, frameRate: 30, aspectRatio: 16 / 9 };
|
|
2448
|
+
(0, oo.useEffect)(() => {
|
|
2458
2449
|
a(e).then(r);
|
|
2459
2450
|
}, [e]);
|
|
2460
2451
|
let a = async (n) => {
|
|
2461
2452
|
if (n === "back") {
|
|
2462
|
-
let s = (await
|
|
2453
|
+
let s = (await sm()).find(nm);
|
|
2463
2454
|
if (s != null && s.deviceId)
|
|
2464
2455
|
return b(i({}, o), { deviceId: { exact: s.deviceId } });
|
|
2465
2456
|
}
|
|
@@ -2467,18 +2458,18 @@ var require_main_min = __commonJS({
|
|
|
2467
2458
|
};
|
|
2468
2459
|
return { videoConstraints: t };
|
|
2469
2460
|
};
|
|
2470
|
-
var
|
|
2461
|
+
var ao = require("react");
|
|
2471
2462
|
var J = require("react/jsx-runtime");
|
|
2472
|
-
var
|
|
2473
|
-
var
|
|
2474
|
-
var
|
|
2475
|
-
var
|
|
2476
|
-
var
|
|
2477
|
-
var
|
|
2478
|
-
var
|
|
2479
|
-
var
|
|
2480
|
-
let s = (0,
|
|
2481
|
-
(0,
|
|
2463
|
+
var pu = 92;
|
|
2464
|
+
var dm = 120;
|
|
2465
|
+
var fu = 40;
|
|
2466
|
+
var yu = 32;
|
|
2467
|
+
var hu = 48;
|
|
2468
|
+
var gu = 40;
|
|
2469
|
+
var um = 800;
|
|
2470
|
+
var Su = ({ overlay: e, outline: t, imageUrl: r, title: o, instructions: a, reviewInstructions: n }) => {
|
|
2471
|
+
let s = (0, ao.useRef)(null);
|
|
2472
|
+
(0, ao.useEffect)(() => {
|
|
2482
2473
|
let f = _e(() => {
|
|
2483
2474
|
var m;
|
|
2484
2475
|
if ((m = s.current) != null && m.innerHTML) {
|
|
@@ -2488,230 +2479,230 @@ var require_main_min = __commonJS({
|
|
|
2488
2479
|
}, 100);
|
|
2489
2480
|
return window.addEventListener("resize", f), () => window.removeEventListener("resize", f);
|
|
2490
2481
|
});
|
|
2491
|
-
let l = (r ?
|
|
2482
|
+
let l = (r ? fu : 0) + (o ? yu : 0) + (a ? hu : 0), u = (0, J.jsxs)(J.Fragment, { children: [r && (0, J.jsx)("img", { className: "camera-capture-img", src: r, alt: "" }), o && (0, J.jsx)("h4", { className: "camera-capture-title", children: o }), a && (0, J.jsx)("small", { className: "camera-capture-instructions", children: a })] }), d = pu + l;
|
|
2492
2483
|
if (n) {
|
|
2493
|
-
l = d -
|
|
2494
|
-
let f =
|
|
2484
|
+
l = d - dm, u = (0, J.jsx)("small", { className: "camera-capture-instructions", children: n });
|
|
2485
|
+
let f = dm + gu;
|
|
2495
2486
|
d < f && (u = (0, J.jsx)(J.Fragment, {}));
|
|
2496
2487
|
}
|
|
2497
|
-
let c = { x: "50%", y: "5%", width: `min(90%, ${
|
|
2488
|
+
let c = { x: "50%", y: "5%", width: `min(90%, ${um}px)`, height: `calc(90% - ${d}px)`, style: { transform: `translateX(max(-45%, -${um / 2}px))` } }, h = { style: { left: "5%", top: `calc(100% - ${d}px - 5%)`, height: `calc(${l}px + 5%)`, width: "90%" } };
|
|
2498
2489
|
return (0, J.jsxs)("svg", { ref: s, xmlns: "http://www.w3.org/2000/svg", children: [(0, J.jsx)("defs", { children: (0, J.jsxs)("mask", { id: "mask", children: [(0, J.jsx)("rect", { width: "100%", height: "100%", fill: "#fff" }), (0, J.jsx)("image", i({ href: e }, c))] }) }), e && (0, J.jsx)("rect", { width: "100%", height: "100%", mask: "url(#mask)", fillOpacity: "0.72" }), t && (0, J.jsx)("image", i({ href: t }, c)), (0, J.jsx)("foreignObject", { width: "100%", height: "100%", children: (0, J.jsx)("div", b(i({ className: "camera-capture-text-and-image-container" }, h), { children: u })) })] });
|
|
2499
2490
|
};
|
|
2500
|
-
var
|
|
2501
|
-
var
|
|
2502
|
-
var
|
|
2503
|
-
var
|
|
2504
|
-
var
|
|
2491
|
+
var Aa = Su;
|
|
2492
|
+
var fm = require("@transferwise/components");
|
|
2493
|
+
var ym = require("react-intl");
|
|
2494
|
+
var pm = require("react-intl");
|
|
2495
|
+
var no = (0, pm.defineMessages)({ title: { id: "dynamicFlows.CameraCapture.NoCameraAccess.title", defaultMessage: "We can't access your camera", description: "Title of standalone page prompting missing camera permissions" }, paragraph: { id: "dynamicFlows.CameraCapture.NoCameraAccess.paragraph", defaultMessage: "Enable camera access in your browser's settings to get going again.", description: "Further text of standalone page prompting missing camera permissions" }, action: { id: "dynamicFlows.CameraCapture.NoCameraAccess.action", defaultMessage: "Enable camera access", description: "Action to ask for camera permissions again" } });
|
|
2505
2496
|
var ze = require("react/jsx-runtime");
|
|
2506
|
-
var
|
|
2507
|
-
let t = (0,
|
|
2508
|
-
return (0, ze.jsx)("div", { id: "no-camera-access", children: (0, ze.jsx)("div", { className: "container p-t-5", children: (0, ze.jsx)("div", { className: "row", children: (0, ze.jsxs)("div", { className: "col-md-6 col-md-offset-3", children: [(0, ze.jsx)("h2", { className: "text-xs-center m-b-3", children: t.formatMessage(
|
|
2497
|
+
var bu = ({ onAction: e }) => {
|
|
2498
|
+
let t = (0, ym.useIntl)();
|
|
2499
|
+
return (0, ze.jsx)("div", { id: "no-camera-access", children: (0, ze.jsx)("div", { className: "container p-t-5", children: (0, ze.jsx)("div", { className: "row", children: (0, ze.jsxs)("div", { className: "col-md-6 col-md-offset-3", children: [(0, ze.jsx)("h2", { className: "text-xs-center m-b-3", children: t.formatMessage(no.title) }), (0, ze.jsx)("p", { className: "text-xs-center m-b-5", children: t.formatMessage(no.paragraph) }), (0, ze.jsx)(fm.Button, { block: true, onClick: e, children: t.formatMessage(no.action) })] }) }) }) });
|
|
2509
2500
|
};
|
|
2510
|
-
var
|
|
2511
|
-
var Sm = require("react-intl");
|
|
2501
|
+
var Oa = bu;
|
|
2512
2502
|
var gm = require("react-intl");
|
|
2513
|
-
var
|
|
2503
|
+
var hm = require("react-intl");
|
|
2504
|
+
var Pa = (0, hm.defineMessages)({ title: { id: "dynamicFlows.CameraCapture.CameraNotSupported.title", defaultMessage: "Camera not supported", description: "Title of standalone page prompting that camera is not available on users browser" }, paragraph: { id: "dynamicFlows.CameraCapture.CameraNotSupported.paragraph", defaultMessage: "The browser you're using doesn't have support for a camera. Try a different browser, device, or download our mobile app.", description: "Further text of standalone page prompting that camera is not available on user's browser" } });
|
|
2514
2505
|
var tt = require("react/jsx-runtime");
|
|
2515
|
-
var
|
|
2516
|
-
let e = (0,
|
|
2517
|
-
return (0, tt.jsx)("div", { id: "camera-not-supported", children: (0, tt.jsx)("div", { className: "container p-t-5", children: (0, tt.jsx)("div", { className: "row", children: (0, tt.jsxs)("div", { className: "col-md-6 col-md-offset-3", children: [(0, tt.jsx)("h2", { className: "text-xs-center m-b-3", children: e.formatMessage(
|
|
2518
|
-
};
|
|
2519
|
-
var
|
|
2520
|
-
var
|
|
2521
|
-
var
|
|
2522
|
-
var
|
|
2523
|
-
var
|
|
2506
|
+
var wu = () => {
|
|
2507
|
+
let e = (0, gm.useIntl)();
|
|
2508
|
+
return (0, tt.jsx)("div", { id: "camera-not-supported", children: (0, tt.jsx)("div", { className: "container p-t-5", children: (0, tt.jsx)("div", { className: "row", children: (0, tt.jsxs)("div", { className: "col-md-6 col-md-offset-3", children: [(0, tt.jsx)("h2", { className: "text-xs-center m-b-3", children: e.formatMessage(Pa.title) }), (0, tt.jsx)("p", { className: "text-xs-center m-b-5", children: e.formatMessage(Pa.paragraph) })] }) }) }) });
|
|
2509
|
+
};
|
|
2510
|
+
var Ma = wu;
|
|
2511
|
+
var Sm = (e) => e == null ? void 0 : e("Dynamic Flow - Camera Permission Denied", {});
|
|
2512
|
+
var bm = async (e, t, r) => e == null ? void 0 : e("Dynamic Flow - Camera Feed Started", await Fu(t, r));
|
|
2513
|
+
var wm = (e, t) => e == null ? void 0 : e("Dynamic Flow - Camera Not Supported", { Error: t });
|
|
2514
|
+
var Fu = async (e, t) => {
|
|
2524
2515
|
var n;
|
|
2525
|
-
let r =
|
|
2526
|
-
return b(i({}, r && { "Available Video Devices (by label)": await
|
|
2516
|
+
let r = ro(t), o = va(t), a = (n = r == null ? void 0 : r.getSettings) == null ? void 0 : n.call(r);
|
|
2517
|
+
return b(i({}, r && { "Available Video Devices (by label)": await mm(), "Active Video Device (by label)": await lm(t), "Camera Capabilities": o, "Camera Settings": a }), { "Camera Direction (Asked)": e == null ? void 0 : e.direction });
|
|
2527
2518
|
};
|
|
2528
2519
|
var re = require("react/jsx-runtime");
|
|
2529
|
-
var
|
|
2530
|
-
let [d, c] = (0, Ce.useState)("CAPTURE"), [h, f] = (0, Ce.useState)(false), [m, p] = (0, Ce.useState)(false), [y, S] = (0, Ce.useState)(), g = (0, Ce.useRef)(null), { videoConstraints: F } =
|
|
2520
|
+
var Cu = ({ direction: e = "back", overlay: t = "", outline: r = "", imageUrl: o = "", title: a = "", instructions: n = "", showReview: s = false, onCapture: l, onEvent: u }) => {
|
|
2521
|
+
let [d, c] = (0, Ce.useState)("CAPTURE"), [h, f] = (0, Ce.useState)(false), [m, p] = (0, Ce.useState)(false), [y, S] = (0, Ce.useState)(), g = (0, Ce.useRef)(null), { videoConstraints: F } = cm(e), w = (0, Fm.useIntl)(), A = (0, Ce.useCallback)(async () => {
|
|
2531
2522
|
var L, P, B, k, ne, ve;
|
|
2532
2523
|
if ((L = g == null ? void 0 : g.current) != null && L.video && ((B = (P = g == null ? void 0 : g.current) == null ? void 0 : P.video) == null ? void 0 : B.readyState) >= 3) {
|
|
2533
2524
|
(ne = (k = g == null ? void 0 : g.current) == null ? void 0 : k.video) == null || ne.pause();
|
|
2534
|
-
let _ = await
|
|
2535
|
-
_ == null || _.toBlob((
|
|
2536
|
-
if (
|
|
2525
|
+
let _ = await im((ve = g == null ? void 0 : g.current) == null ? void 0 : ve.video);
|
|
2526
|
+
_ == null || _.toBlob((ue) => {
|
|
2527
|
+
if (ue)
|
|
2537
2528
|
if (s) {
|
|
2538
|
-
let
|
|
2539
|
-
S({ source:
|
|
2529
|
+
let yr = window.URL.createObjectURL(ue);
|
|
2530
|
+
S({ source: yr, blob: ue }), c("REVIEW");
|
|
2540
2531
|
} else
|
|
2541
|
-
l(
|
|
2532
|
+
l(ue);
|
|
2542
2533
|
}, "image/jpeg", 0.92);
|
|
2543
2534
|
}
|
|
2544
2535
|
}, [g, s, S, c, l, h]), O = (0, Ce.useCallback)((L) => {
|
|
2545
2536
|
if (L instanceof DOMException && (L == null ? void 0 : L.name) === "NotAllowedError") {
|
|
2546
|
-
c("NO_CAMERA_ACCESS"),
|
|
2537
|
+
c("NO_CAMERA_ACCESS"), Sm(u);
|
|
2547
2538
|
return;
|
|
2548
2539
|
}
|
|
2549
|
-
c("CAMERA_NOT_SUPPORTED"),
|
|
2540
|
+
c("CAMERA_NOT_SUPPORTED"), wm(u, L);
|
|
2550
2541
|
}, [c, u]), x = (0, Ce.useCallback)((L) => {
|
|
2551
|
-
p(true), f(
|
|
2542
|
+
p(true), f(am(L)), bm(u, { direction: e }, L);
|
|
2552
2543
|
}, [f, u, e]), M = () => {
|
|
2553
2544
|
l((y == null ? void 0 : y.blob) || null);
|
|
2554
2545
|
}, R = () => {
|
|
2555
2546
|
c("CAPTURE"), S(void 0);
|
|
2556
|
-
}, v = () => c("CAPTURE"), T = (0, re.jsxs)(re.Fragment, { children: [F && (0, re.jsx)(
|
|
2557
|
-
return (0, re.jsxs)("section", { className: "camera-capture", children: [d === "CAPTURE" && T, d === "REVIEW" && H, d === "NO_CAMERA_ACCESS" && (0, re.jsx)(
|
|
2547
|
+
}, v = () => c("CAPTURE"), T = (0, re.jsxs)(re.Fragment, { children: [F && (0, re.jsx)(Cm.default, { ref: g, audio: false, videoConstraints: F, mirrored: h, onUserMediaError: O, onUserMedia: x }), (0, re.jsx)(Aa, { overlay: t, outline: r, imageUrl: o, title: a, instructions: n }), m && (0, re.jsx)(rm, { onCapture: () => void A() })] }), H = (0, re.jsxs)(re.Fragment, { children: [(0, re.jsx)("img", { className: "review-image", src: y == null ? void 0 : y.source, alt: "" }), (0, re.jsx)(Aa, { overlay: t, imageUrl: o, title: a, instructions: n, reviewInstructions: w.formatMessage(dr.reviewInstructions) }), (0, re.jsx)(om, { onSubmit: M, onRetry: R })] });
|
|
2548
|
+
return (0, re.jsxs)("section", { className: "camera-capture", children: [d === "CAPTURE" && T, d === "REVIEW" && H, d === "NO_CAMERA_ACCESS" && (0, re.jsx)(Oa, { onAction: v }), d === "CAMERA_NOT_SUPPORTED" && (0, re.jsx)(Ma, {})] });
|
|
2558
2549
|
};
|
|
2559
|
-
var
|
|
2560
|
-
var
|
|
2561
|
-
function
|
|
2550
|
+
var ka = Cu;
|
|
2551
|
+
var vm = require("react/jsx-runtime");
|
|
2552
|
+
function xu(e) {
|
|
2562
2553
|
return new Promise((t, r) => {
|
|
2563
2554
|
let o = new FileReader();
|
|
2564
2555
|
o.onloadend = () => t(o.result), o.readAsDataURL(e);
|
|
2565
2556
|
});
|
|
2566
2557
|
}
|
|
2567
|
-
var
|
|
2568
|
-
let { step: t, model: r, onModelChange: o, onAction: a } = e, n = Q(), s =
|
|
2569
|
-
(0,
|
|
2558
|
+
var vu = (e) => {
|
|
2559
|
+
let { step: t, model: r, onModelChange: o, onAction: a } = e, n = Q(), s = xm(t), l = Au(t), u = Ou(t), { title: d, image: c, cameraConfig: h } = l, { assets: f, direction: m, instructions: p } = h || {}, { overlay: y, outline: S } = f || {}, { url: g } = c || {}, [F, w] = (0, io.useState)(false);
|
|
2560
|
+
(0, io.useEffect)(() => {
|
|
2570
2561
|
F && a(u);
|
|
2571
2562
|
}, [r]);
|
|
2572
2563
|
let A = async (O) => {
|
|
2573
2564
|
let { $id: x } = l;
|
|
2574
2565
|
if (O) {
|
|
2575
|
-
let M = await
|
|
2566
|
+
let M = await xu(O), R = { [x || ""]: M };
|
|
2576
2567
|
w(true), o({ model: R, formSchema: s, triggerModel: M, triggerSchema: l });
|
|
2577
2568
|
}
|
|
2578
2569
|
};
|
|
2579
|
-
return (0,
|
|
2570
|
+
return (0, vm.jsx)(ka, { overlay: y, outline: S, title: d, imageUrl: g, instructions: p, direction: m, onEvent: n, onCapture: (O) => {
|
|
2580
2571
|
A(O);
|
|
2581
2572
|
} });
|
|
2582
2573
|
};
|
|
2583
|
-
var
|
|
2584
|
-
function
|
|
2585
|
-
let r =
|
|
2574
|
+
var so = vu;
|
|
2575
|
+
function xm(e) {
|
|
2576
|
+
let r = Ir(e.schemas || [])[0];
|
|
2586
2577
|
if (!r || !Pe(r))
|
|
2587
2578
|
throw new Error("The first schema in a camera step is expected to be of type object and have at least one property with a schema...");
|
|
2588
2579
|
return r;
|
|
2589
2580
|
}
|
|
2590
|
-
function
|
|
2591
|
-
let t =
|
|
2581
|
+
function Au(e) {
|
|
2582
|
+
let t = xm(e), r = Object.values(t.properties)[0];
|
|
2592
2583
|
if (!r)
|
|
2593
2584
|
throw new Error("The first schema in a camera step is expected to be of type object and have at least one property with a schema...");
|
|
2594
2585
|
return r;
|
|
2595
2586
|
}
|
|
2596
|
-
function
|
|
2587
|
+
function Ou(e) {
|
|
2597
2588
|
var t, r;
|
|
2598
|
-
if (!e.schemas || ((t =
|
|
2589
|
+
if (!e.schemas || ((t = Ir(e.schemas)) == null ? void 0 : t.length) !== 1)
|
|
2599
2590
|
throw new Error("camera step expects 1 non-hidden object schema");
|
|
2600
2591
|
if (((r = e == null ? void 0 : e.actions) == null ? void 0 : r.length) !== 1)
|
|
2601
2592
|
throw new Error("camera step expects 1 action");
|
|
2602
2593
|
return e.actions[0];
|
|
2603
2594
|
}
|
|
2604
|
-
var
|
|
2605
|
-
var
|
|
2606
|
-
var
|
|
2607
|
-
var
|
|
2608
|
-
var
|
|
2595
|
+
var Pm = require("react-intl");
|
|
2596
|
+
var Am = require("react-intl");
|
|
2597
|
+
var ur = (0, Am.defineMessages)({ title: { id: "dynamicFlows.ExternalConfirmation.title", defaultMessage: "Please confirm", description: "Heading for the confirmation screen." }, description: { id: "dynamicFlows.ExternalConfirmation.description", defaultMessage: "Please confirm you want to open **{origin}** in a new browser tab.", description: "Description for the confirmation screen." }, open: { id: "dynamicFlows.ExternalConfirmation.open", defaultMessage: "Open in new tab", description: "Button text confirming opening a new browser tab." }, cancel: { id: "dynamicFlows.ExternalConfirmation.cancel", defaultMessage: "Cancel", description: "Button text rejecting opening a new browser tab." } });
|
|
2598
|
+
var Mm = require("react/jsx-runtime");
|
|
2599
|
+
var Om = () => {
|
|
2609
2600
|
};
|
|
2610
|
-
var
|
|
2611
|
-
let { formatMessage: r } = (0,
|
|
2612
|
-
return (0,
|
|
2601
|
+
var Pu = ({ url: e, onClose: t }) => {
|
|
2602
|
+
let { formatMessage: r } = (0, Pm.useIntl)();
|
|
2603
|
+
return (0, Mm.jsx)(me, { components: [{ type: "box", width: "lg", components: [{ type: "heading", text: r(ur.title), size: "lg", align: "center", margin: "xl" }, { type: "info", markdown: r(ur.description, { origin: Mu(e) }), align: "center", margin: "xl" }, { type: "box", width: "md", components: [{ type: "button", action: { title: r(ur.open), type: "primary", url: e, exit: true } }, { type: "button", action: { title: r(ur.cancel), type: "link", url: "", exit: true } }] }] }], submitted: false, onAction: (o) => {
|
|
2613
2604
|
o.url && window.open(o.url, "_blank"), t();
|
|
2614
|
-
}, onModelChange:
|
|
2605
|
+
}, onModelChange: Om, onPersistAsync: Om });
|
|
2615
2606
|
};
|
|
2616
|
-
var
|
|
2617
|
-
function
|
|
2607
|
+
var mo = Pu;
|
|
2608
|
+
function Mu(e) {
|
|
2618
2609
|
try {
|
|
2619
2610
|
return new URL(e).origin;
|
|
2620
2611
|
} catch (t) {
|
|
2621
2612
|
return e;
|
|
2622
2613
|
}
|
|
2623
2614
|
}
|
|
2624
|
-
var
|
|
2625
|
-
var
|
|
2626
|
-
var
|
|
2627
|
-
var
|
|
2615
|
+
var km = require("@transferwise/components");
|
|
2616
|
+
var Em = require("@transferwise/icons");
|
|
2617
|
+
var qt = require("react/jsx-runtime");
|
|
2618
|
+
var ku = ({ title: e, action: t, onAction: r }) => (0, qt.jsxs)("a", { onClick: (o) => {
|
|
2628
2619
|
o.preventDefault(), r(b(i({}, t), { skipValidation: true }));
|
|
2629
|
-
}, href: "/", className: "df-back-btn", "aria-label": e, children: [(0,
|
|
2630
|
-
var
|
|
2620
|
+
}, href: "/", className: "df-back-btn", "aria-label": e, children: [(0, qt.jsx)("span", { className: "sr-only", children: e }), (0, qt.jsx)(km.Avatar, { type: "icon", children: (0, qt.jsx)(Em.ArrowLeft, { size: "24" }) })] });
|
|
2621
|
+
var Im = ku;
|
|
2631
2622
|
var De = require("react/jsx-runtime");
|
|
2632
|
-
var
|
|
2623
|
+
var zr = (e) => {
|
|
2633
2624
|
var u, d, c;
|
|
2634
2625
|
let { step: t, globalError: r, onAction: o } = e, a = (u = t == null ? void 0 : t.external) == null ? void 0 : u.url, n = ((d = t == null ? void 0 : t.navigation) == null ? void 0 : d.back) || ((c = t == null ? void 0 : t.navigation) == null ? void 0 : c.backButton), { requiresManualTrigger: s, dismissConfirmation: l } = Tn(a);
|
|
2635
|
-
return t === void 0 ? null : a && s ? (0, De.jsx)(
|
|
2626
|
+
return t === void 0 ? null : a && s ? (0, De.jsx)(mo, { url: a, onClose: l }) : En(t) ? (0, De.jsx)(so, b(i({}, e), { step: t })) : (0, De.jsxs)(De.Fragment, { children: [n && (0, De.jsx)(Im, b(i({}, n), { onAction: o })), r ? (0, De.jsx)(se, { component: { context: "negative", markdown: r, margin: "lg" } }) : null, (0, De.jsx)(to, b(i({}, e), { stepSpecification: t }))] });
|
|
2636
2627
|
};
|
|
2637
|
-
var
|
|
2638
|
-
var
|
|
2639
|
-
function
|
|
2640
|
-
let t = (0,
|
|
2628
|
+
var Dm = require("react");
|
|
2629
|
+
var Eu = 1e3;
|
|
2630
|
+
function Lm(e) {
|
|
2631
|
+
let t = (0, Dm.useRef)(/* @__PURE__ */ new Map()), r = (o) => {
|
|
2641
2632
|
if (t.current.has(o))
|
|
2642
2633
|
return t.current.get(o);
|
|
2643
|
-
let a = _e((n, s, l) => e(n, s, l),
|
|
2634
|
+
let a = _e((n, s, l) => e(n, s, l), Eu);
|
|
2644
2635
|
return t.current.set(o, a), a;
|
|
2645
2636
|
};
|
|
2646
2637
|
return function(o, a, n, s) {
|
|
2647
2638
|
let l = r(o);
|
|
2648
|
-
l(o, a, n), (!s || !
|
|
2639
|
+
l(o, a, n), (!s || !Iu(s)) && l.flush();
|
|
2649
2640
|
};
|
|
2650
2641
|
}
|
|
2651
|
-
var
|
|
2652
|
-
var
|
|
2653
|
-
var
|
|
2642
|
+
var Iu = (e) => it(e) === "basic" && e.type !== "boolean" && e.format !== "base64url";
|
|
2643
|
+
var Gt = require("react");
|
|
2644
|
+
var Rm = (e) => {
|
|
2654
2645
|
var m, p;
|
|
2655
|
-
let [t, r] = (0,
|
|
2646
|
+
let [t, r] = (0, Gt.useState)((m = e == null ? void 0 : e.errors) == null ? void 0 : m.validation), [o, a] = (0, Gt.useState)((p = e == null ? void 0 : e.errors) == null ? void 0 : p.error), [n, s] = (0, Gt.useState)({ step: e || void 0, models: e != null && e.model ? Tm(e.model, Nm(e)) : {}, etag: void 0 }), { step: l, models: u, etag: d } = n, c = (y, S) => {
|
|
2656
2647
|
var g, F, w, A;
|
|
2657
|
-
s((O) => ({ step: y, models: y.model ?
|
|
2648
|
+
s((O) => ({ step: y, models: y.model ? Tm(y.model, Nm(y)) : O.models, etag: S })), r((F = (g = y == null ? void 0 : y.errors) == null ? void 0 : g.validation) != null ? F : null), a((A = (w = y == null ? void 0 : y.errors) == null ? void 0 : w.error) != null ? A : null);
|
|
2658
2649
|
}, h = (y, S, g) => {
|
|
2659
2650
|
s((F) => {
|
|
2660
2651
|
let w = b(i({}, F.models), { [y]: S }), A = { step: F.step, models: w, etag: F.etag };
|
|
2661
2652
|
return g(w), A;
|
|
2662
2653
|
});
|
|
2663
|
-
}, f = (0,
|
|
2654
|
+
}, f = (0, Gt.useMemo)(() => Lu(u, Du(l)), [u, l]);
|
|
2664
2655
|
return { formErrors: t, globalError: o, step: l, models: u, etag: d, modelIsValid: f, setFormErrors: r, setGlobalError: a, setStepAndEtag: c, setSchemaModel: h };
|
|
2665
2656
|
};
|
|
2666
|
-
var
|
|
2667
|
-
var
|
|
2668
|
-
var
|
|
2657
|
+
var Tm = (e, t = []) => t.reduce((r, o) => (o.$id || console.warn("Schema without $id property found."), b(i({}, r), { [o.$id || ""]: ie(e, o) || {} })), {});
|
|
2658
|
+
var Nm = (e) => [...lo((e == null ? void 0 : e.layout) || []), ...(e == null ? void 0 : e.schemas) || []];
|
|
2659
|
+
var lo = (e) => e.flatMap((t) => {
|
|
2669
2660
|
switch (t.type) {
|
|
2670
2661
|
case "columns":
|
|
2671
|
-
return [...
|
|
2662
|
+
return [...lo([...t.left, ...t.right])];
|
|
2672
2663
|
case "box":
|
|
2673
|
-
return
|
|
2664
|
+
return lo(t.components);
|
|
2674
2665
|
case "form":
|
|
2675
|
-
return
|
|
2666
|
+
return Bm(t.schema) ? [t.schema] : [];
|
|
2676
2667
|
default:
|
|
2677
2668
|
return [];
|
|
2678
2669
|
}
|
|
2679
2670
|
});
|
|
2680
|
-
var
|
|
2681
|
-
var
|
|
2671
|
+
var Du = (e) => [...Ea((e == null ? void 0 : e.layout) || []).map((t) => ((e == null ? void 0 : e.schemas) || []).find((r) => r.$id === t)).filter(Boolean), ...lo((e == null ? void 0 : e.layout) || [])];
|
|
2672
|
+
var Ea = (e) => e.flatMap((t) => {
|
|
2682
2673
|
switch (t.type) {
|
|
2683
2674
|
case "columns":
|
|
2684
|
-
return [...
|
|
2675
|
+
return [...Ea([...t.left, ...t.right])];
|
|
2685
2676
|
case "box":
|
|
2686
|
-
return
|
|
2677
|
+
return Ea(t.components);
|
|
2687
2678
|
case "form":
|
|
2688
|
-
return [
|
|
2679
|
+
return [Tu(t)];
|
|
2689
2680
|
default:
|
|
2690
2681
|
return [];
|
|
2691
2682
|
}
|
|
2692
2683
|
}).filter(Boolean);
|
|
2693
|
-
var
|
|
2694
|
-
var
|
|
2695
|
-
var
|
|
2696
|
-
var
|
|
2697
|
-
var
|
|
2698
|
-
var
|
|
2699
|
-
function
|
|
2700
|
-
let r = i({ size:
|
|
2684
|
+
var Lu = (e, t = []) => !(t != null && t.some((r) => (r.$id || console.warn("Schema without $id property found."), !$(e[r.$id || ""] || {}, r))));
|
|
2685
|
+
var Tu = (e) => e.schema && !Bm(e.schema) ? e.schema.$ref : e.schemaId;
|
|
2686
|
+
var Bm = (e) => e !== void 0 && typeof e == "object" && Object.prototype.hasOwnProperty.call(e, "$ref") === false;
|
|
2687
|
+
var co = require("@transferwise/components");
|
|
2688
|
+
var jm = require("react");
|
|
2689
|
+
var Um = require("react/jsx-runtime");
|
|
2690
|
+
function Vm(e, t) {
|
|
2691
|
+
let r = i({ size: co.Size.EXTRA_LARGE, initial: true, submission: false }, e), [o, a] = (0, jm.useState)(t), s = r.initial && o === "initial" || r.submission && o === "submission" ? (0, Um.jsx)(co.Loader, { size: r.size, classNames: { "tw-loader": "tw-loader m-x-auto" }, "data-testid": "loader" }) : null;
|
|
2701
2692
|
return { isLoading: o !== "idle", setLoadingState: a, loader: s };
|
|
2702
2693
|
}
|
|
2703
|
-
var
|
|
2704
|
-
var
|
|
2705
|
-
var
|
|
2706
|
-
var
|
|
2707
|
-
var
|
|
2708
|
-
let { formatMessage: t } = (0,
|
|
2709
|
-
return (0,
|
|
2694
|
+
var Gm = require("react");
|
|
2695
|
+
var uo = require("@transferwise/components");
|
|
2696
|
+
var zm = require("react-intl");
|
|
2697
|
+
var qm = require("react/jsx-runtime");
|
|
2698
|
+
var Hm = ({ onDismiss: e }) => {
|
|
2699
|
+
let { formatMessage: t } = (0, zm.useIntl)();
|
|
2700
|
+
return (0, qm.jsx)(uo.Alert, { action: { text: t(zt.retry), href: window.location.href }, message: t(zt.errorAlert), type: uo.Sentiment.NEGATIVE, className: "m-b-3", onDismiss: e });
|
|
2710
2701
|
};
|
|
2711
|
-
var
|
|
2712
|
-
var
|
|
2702
|
+
var $t = require("react/jsx-runtime");
|
|
2703
|
+
var Nu = () => {
|
|
2713
2704
|
};
|
|
2714
|
-
var
|
|
2705
|
+
var Ia = class extends Gm.Component {
|
|
2715
2706
|
constructor(r) {
|
|
2716
2707
|
super(r);
|
|
2717
2708
|
this.handleErrorReset = () => {
|
|
@@ -2723,36 +2714,36 @@ var require_main_min = __commonJS({
|
|
|
2723
2714
|
return { hasError: true, isFatalError: true };
|
|
2724
2715
|
}
|
|
2725
2716
|
componentDidCatch(r) {
|
|
2726
|
-
let { onError: o =
|
|
2717
|
+
let { onError: o = Nu } = this.props;
|
|
2727
2718
|
o(r);
|
|
2728
2719
|
}
|
|
2729
2720
|
render() {
|
|
2730
2721
|
let { children: r } = this.props, { hasError: o, isFatalError: a } = this.state;
|
|
2731
|
-
return (0,
|
|
2722
|
+
return (0, $t.jsxs)($t.Fragment, { children: [o && (0, $t.jsx)(Hm, { onDismiss: this.handleErrorReset }), !a && r] });
|
|
2732
2723
|
}
|
|
2733
2724
|
};
|
|
2734
|
-
var
|
|
2735
|
-
var
|
|
2725
|
+
var Da = Ia;
|
|
2726
|
+
var $m = async (e, t) => {
|
|
2736
2727
|
switch (t) {
|
|
2737
2728
|
case "step":
|
|
2738
|
-
return
|
|
2729
|
+
return Wm(e);
|
|
2739
2730
|
case "exit":
|
|
2740
|
-
return Jm(e);
|
|
2741
|
-
case "action":
|
|
2742
2731
|
return Km(e);
|
|
2732
|
+
case "action":
|
|
2733
|
+
return _m(e);
|
|
2743
2734
|
default:
|
|
2744
2735
|
throw new Error("Unsupported X-Df-Response-Type. Allowed values are 'step', 'action', 'exit'.");
|
|
2745
2736
|
}
|
|
2746
2737
|
};
|
|
2747
|
-
var
|
|
2748
|
-
let t = await
|
|
2738
|
+
var Wm = async (e) => {
|
|
2739
|
+
let t = await pr(e);
|
|
2749
2740
|
if (!N(t))
|
|
2750
2741
|
throw new Error("Incorrect response body in response. Expected an object.");
|
|
2751
2742
|
let r = e.headers.get("etag") || void 0;
|
|
2752
2743
|
return { type: "step", step: t, etag: r };
|
|
2753
2744
|
};
|
|
2754
|
-
var
|
|
2755
|
-
let t = await
|
|
2745
|
+
var _m = async (e) => {
|
|
2746
|
+
let t = await pr(e);
|
|
2756
2747
|
if (!N(t))
|
|
2757
2748
|
throw new Error("Incorrect response body in response. Expected an object.");
|
|
2758
2749
|
if (!N(t.action))
|
|
@@ -2760,75 +2751,75 @@ var require_main_min = __commonJS({
|
|
|
2760
2751
|
let r = t.action;
|
|
2761
2752
|
return r.exit === true && N(r.result) ? { type: "exit", result: r.result } : { type: "action", action: t.action };
|
|
2762
2753
|
};
|
|
2763
|
-
var
|
|
2764
|
-
var
|
|
2754
|
+
var Km = async (e) => ({ type: "exit", result: await La(e) });
|
|
2755
|
+
var Jm = async (e) => {
|
|
2765
2756
|
var r, o, a;
|
|
2766
|
-
if (
|
|
2757
|
+
if (Ta(e), (r = e.headers) != null && r.has("X-Df-Response-Type")) {
|
|
2767
2758
|
let n = e.headers.get("X-Df-Response-Type");
|
|
2768
|
-
return
|
|
2759
|
+
return $m(e, n);
|
|
2769
2760
|
}
|
|
2770
2761
|
if ((o = e.headers) != null && o.has("X-Df-ResponseType")) {
|
|
2771
2762
|
let n = e.headers.get("X-Df-ResponseType");
|
|
2772
|
-
return
|
|
2763
|
+
return $m(e, n);
|
|
2773
2764
|
}
|
|
2774
2765
|
if ((a = e.headers) != null && a.has("X-Df-Exit"))
|
|
2775
|
-
return
|
|
2776
|
-
let t = await
|
|
2777
|
-
return N(t) && t.action ?
|
|
2766
|
+
return Km(e);
|
|
2767
|
+
let t = await pr(e.clone());
|
|
2768
|
+
return N(t) && t.action ? _m(e) : Wm(e);
|
|
2778
2769
|
};
|
|
2779
|
-
var
|
|
2780
|
-
|
|
2781
|
-
let t = await
|
|
2770
|
+
var Xm = async (e) => {
|
|
2771
|
+
Ta(e);
|
|
2772
|
+
let t = await pr(e);
|
|
2782
2773
|
if (!N(t))
|
|
2783
2774
|
throw new Error("Incorrect response body in error response. Expected an object.");
|
|
2784
2775
|
if (!t.refreshFormUrl && !t.refreshUrl && !t.validation && !t.error)
|
|
2785
2776
|
throw t;
|
|
2786
2777
|
return t;
|
|
2787
2778
|
};
|
|
2788
|
-
var
|
|
2789
|
-
|
|
2790
|
-
let t = await
|
|
2779
|
+
var La = async (e) => {
|
|
2780
|
+
Ta(e);
|
|
2781
|
+
let t = await pr(e);
|
|
2791
2782
|
return N(t) ? t : null;
|
|
2792
2783
|
};
|
|
2793
|
-
var
|
|
2784
|
+
var pr = async (e) => {
|
|
2794
2785
|
try {
|
|
2795
2786
|
return await e.json();
|
|
2796
2787
|
} catch (t) {
|
|
2797
2788
|
return null;
|
|
2798
2789
|
}
|
|
2799
2790
|
};
|
|
2800
|
-
var
|
|
2801
|
-
if (!
|
|
2791
|
+
var Ta = (e) => {
|
|
2792
|
+
if (!Ru(e))
|
|
2802
2793
|
throw new Error("Incorrect type of response from fetch. Expected object of type Response.");
|
|
2803
2794
|
if (e.bodyUsed)
|
|
2804
2795
|
throw new Error("The body of the provided Response object has already been used. Every request must respond with a new Response object.");
|
|
2805
2796
|
};
|
|
2806
|
-
var
|
|
2797
|
+
var Ru = (e) => typeof e == "object" && e !== null && "clone" in e && "bodyUsed" in e;
|
|
2807
2798
|
var rt = require("react/jsx-runtime");
|
|
2808
|
-
var
|
|
2799
|
+
var Ym = () => {
|
|
2809
2800
|
};
|
|
2810
|
-
var
|
|
2811
|
-
let { locale: c } = (0,
|
|
2801
|
+
var Bu = ({ flowId: e, httpClient: t, initialAction: r, initialStep: o, loaderConfig: a, displayStepTitle: n = true, onCompletion: s, onError: l, onEvent: u = Ym, onLog: d = Ym }) => {
|
|
2802
|
+
let { locale: c } = (0, Zm.useIntl)(), { formErrors: h, globalError: f, step: m, models: p, etag: y, modelIsValid: S, setFormErrors: g, setGlobalError: F, setStepAndEtag: w, setSchemaModel: A } = Rm(o), [O, x] = (0, xe.useState)(false), { isLoading: M, loader: R, setLoadingState: v } = Vm(a, o ? "idle" : "initial"), T = at("critical", d, e, (m == null ? void 0 : m.id) || (m == null ? void 0 : m.key)), H = (0, xe.useMemo)(() => {
|
|
2812
2803
|
var C;
|
|
2813
2804
|
return i({ flowId: e, stepId: (m == null ? void 0 : m.id) || (m == null ? void 0 : m.key) }, (C = m == null ? void 0 : m.analytics) != null ? C : {});
|
|
2814
|
-
}, [e, m]), L = (0, xe.useMemo)(() =>
|
|
2805
|
+
}, [e, m]), L = (0, xe.useMemo)(() => So(u, H), [u, H]), P = (0, xe.useCallback)(({ action: C, data: z, etag: D }) => {
|
|
2815
2806
|
let { url: ee, method: He = "POST" } = C;
|
|
2816
2807
|
return t(ee != null ? ee : "", { method: He, headers: i({ "accept-language": c, "Content-Type": "application/json" }, D ? { "If-None-Match": D } : {}), credentials: "include", body: He === "GET" ? void 0 : JSON.stringify(z) });
|
|
2817
2808
|
}, [t, c]), B = async (C, z = {}) => {
|
|
2818
2809
|
v(m ? "submission" : "initial"), L("Dynamic Flow - Step Submitted", { actionId: C.id || C.$id });
|
|
2819
2810
|
try {
|
|
2820
2811
|
let D = await P({ action: C, data: z });
|
|
2821
|
-
await
|
|
2812
|
+
await yr(D, "submission");
|
|
2822
2813
|
} catch (D) {
|
|
2823
|
-
|
|
2814
|
+
hr(D, "Error fetching next step");
|
|
2824
2815
|
}
|
|
2825
2816
|
}, k = async (C, z, D) => {
|
|
2826
2817
|
v("refresh"), L("Dynamic Flow - Step Refreshed", { status: "pending" });
|
|
2827
2818
|
try {
|
|
2828
2819
|
let ee = await P({ action: { url: C, method: "POST" }, data: z, etag: D });
|
|
2829
|
-
await
|
|
2820
|
+
await yr(ee, "refresh");
|
|
2830
2821
|
} catch (ee) {
|
|
2831
|
-
|
|
2822
|
+
hr(ee, "Error fetching refresh step");
|
|
2832
2823
|
}
|
|
2833
2824
|
}, ne = async (C, z) => {
|
|
2834
2825
|
v("submission");
|
|
@@ -2836,12 +2827,12 @@ var require_main_min = __commonJS({
|
|
|
2836
2827
|
let D = await P({ action: C, data: z });
|
|
2837
2828
|
await ve(D, C.result);
|
|
2838
2829
|
} catch (D) {
|
|
2839
|
-
|
|
2830
|
+
hr(D, "Error fetching exit result");
|
|
2840
2831
|
}
|
|
2841
2832
|
}, ve = async (C, z) => {
|
|
2842
|
-
let D = await
|
|
2843
|
-
|
|
2844
|
-
}, _ =
|
|
2833
|
+
let D = await La(C);
|
|
2834
|
+
ue(i(i({}, D), z));
|
|
2835
|
+
}, _ = Lm(k), ue = (0, xe.useCallback)((C) => {
|
|
2845
2836
|
L("Dynamic Flow - Flow Finished", { result: "success" }), s(C);
|
|
2846
2837
|
}, [s, L]);
|
|
2847
2838
|
(0, xe.useEffect)(() => {
|
|
@@ -2852,62 +2843,70 @@ var require_main_min = __commonJS({
|
|
|
2852
2843
|
B(C, C.data);
|
|
2853
2844
|
}
|
|
2854
2845
|
}, [t, c, JSON.stringify(o), JSON.stringify(r)]);
|
|
2855
|
-
let
|
|
2846
|
+
let yr = async (C, z) => {
|
|
2856
2847
|
try {
|
|
2857
2848
|
if (C.status === 304) {
|
|
2858
2849
|
v("idle");
|
|
2859
2850
|
return;
|
|
2860
2851
|
}
|
|
2861
2852
|
if (!C.ok) {
|
|
2862
|
-
let ee = await
|
|
2853
|
+
let ee = await Xm(C);
|
|
2863
2854
|
gl(ee);
|
|
2864
2855
|
return;
|
|
2865
2856
|
}
|
|
2866
|
-
let D = await
|
|
2867
|
-
D.type === "action" ? B(D.action, D.action.data) : D.type === "exit" ?
|
|
2857
|
+
let D = await Jm(C);
|
|
2858
|
+
D.type === "action" ? B(D.action, D.action.data) : D.type === "exit" ? ue(D.result) : hl(D.step, D.etag, z);
|
|
2868
2859
|
} catch (D) {
|
|
2869
|
-
return
|
|
2860
|
+
return hr(D, "Error parsing fetch response", z, C.status);
|
|
2870
2861
|
}
|
|
2871
2862
|
}, hl = (C, z, D) => {
|
|
2872
2863
|
w(C, z), v("idle"), D === "submission" ? (x(false), L("Dynamic Flow - Step Started", i({ stepId: C.id || C.key }, C == null ? void 0 : C.analytics))) : L("Dynamic Flow - Step Refreshed", { status: "success" });
|
|
2873
2864
|
}, gl = async (C) => {
|
|
2874
2865
|
let z = C.refreshUrl || C.refreshFormUrl;
|
|
2875
|
-
z && await k(z,
|
|
2876
|
-
},
|
|
2866
|
+
z && await k(z, po(p), y), C.validation && g(C.validation), C.error && F(C.error), v("idle");
|
|
2867
|
+
}, hr = (C, z, D, ee) => {
|
|
2877
2868
|
T("Error fetching", z), D === "refresh" && L("Dynamic Flow - Step Refreshed", { status: "failure" }), L("Dynamic Flow - Flow Finished", { status: "failure" }), l(C, ee), v("idle");
|
|
2878
2869
|
}, Sl = (C) => {
|
|
2879
2870
|
let { model: z, formSchema: D } = C, { $id: ee = "" } = D;
|
|
2880
|
-
F(null), W(z) || T("Invalid model on change", "onModelChange was called but the model argument is not an object"), A(ee, z, (
|
|
2881
|
-
bl(C,
|
|
2871
|
+
F(null), W(z) || T("Invalid model on change", "onModelChange was called but the model argument is not an object"), A(ee, z, (bt) => {
|
|
2872
|
+
bl(C, bt);
|
|
2882
2873
|
});
|
|
2883
2874
|
}, bl = (C, z) => {
|
|
2884
2875
|
let { triggerSchema: D } = C;
|
|
2885
|
-
if (
|
|
2886
|
-
let ee = D.refreshUrl || D.refreshFormUrl, He = (m == null ? void 0 : m.refreshUrl) || (m == null ? void 0 : m.refreshFormUrl),
|
|
2887
|
-
|
|
2876
|
+
if (Uu(C)) {
|
|
2877
|
+
let ee = D.refreshUrl || D.refreshFormUrl, He = (m == null ? void 0 : m.refreshUrl) || (m == null ? void 0 : m.refreshFormUrl), bt = ee || He;
|
|
2878
|
+
bt && _(bt, po(z), y, D);
|
|
2888
2879
|
}
|
|
2889
2880
|
}, wl = async (C) => {
|
|
2890
2881
|
if (M || C.disabled)
|
|
2891
2882
|
return;
|
|
2892
2883
|
if (C.exit && !C.url) {
|
|
2893
|
-
|
|
2884
|
+
ue(C.result);
|
|
2894
2885
|
return;
|
|
2895
2886
|
}
|
|
2896
|
-
let z = C.exit ? ne : B, { data: D, method: ee, skipValidation: He } = C,
|
|
2897
|
-
|
|
2887
|
+
let z = C.exit ? ne : B, { data: D, method: ee, skipValidation: He } = C, bt = i(i({}, po(p)), D);
|
|
2888
|
+
Vu(ee) ? (g(null), He || x(true), (S || He) && await z(C, bt)) : await z(C);
|
|
2898
2889
|
};
|
|
2899
|
-
return (0, rt.jsx)(
|
|
2890
|
+
return (0, rt.jsx)(Pr, { flowId: e, stepId: (m == null ? void 0 : m.id) || (m == null ? void 0 : m.key), onLog: d, children: (0, rt.jsx)(Fr, { metadata: H, onEvent: u, children: (0, rt.jsx)(Ja, { loading: M, children: (0, rt.jsx)(en, { httpClient: t, children: R !== null ? R : (0, rt.jsx)(zr, { step: m, model: po(p), submitted: O, globalError: f, formErrors: h, stepLayoutOptions: { displayStepTitle: n }, onAction: (C) => {
|
|
2900
2891
|
wl(C);
|
|
2901
2892
|
}, onModelChange: Sl }) }) }) }) });
|
|
2902
2893
|
};
|
|
2903
|
-
var
|
|
2904
|
-
var
|
|
2905
|
-
var
|
|
2906
|
-
var
|
|
2907
|
-
var
|
|
2894
|
+
var ju = (e) => (0, rt.jsx)(Da, { onError: e.onError, children: (0, rt.jsx)(Bu, i({}, e)) });
|
|
2895
|
+
var Na = ju;
|
|
2896
|
+
var po = (e) => Object.values(e).reduce((t, r) => i(i({}, t), r), {});
|
|
2897
|
+
var Vu = (e = "POST") => ["POST", "PUT", "PATCH"].includes(e.toUpperCase());
|
|
2898
|
+
var Uu = (e) => {
|
|
2908
2899
|
let { type: t, triggerSchema: r, triggerModel: o, lastTriggerModel: a = null } = e, n = () => $(o, r), s = () => $(a, r), l = (r == null ? void 0 : r.refreshStepOnChange) || (r == null ? void 0 : r.refreshFormOnChange);
|
|
2909
2900
|
return t !== "init" && l && (n() || s());
|
|
2910
2901
|
};
|
|
2902
|
+
var fr = require("react/jsx-runtime");
|
|
2903
|
+
var zu = (e) => {
|
|
2904
|
+
let t = i({ model: null, errors: null }, e), { baseUrl: r = "", onEvent: o = Qm, onLog: a = Qm } = e;
|
|
2905
|
+
return (0, fr.jsx)(Pr, { flowId: "JsonSchemaForm", stepId: "JsonSchemaForm", onLog: a, children: (0, fr.jsx)(Fr, { metadata: { flowId: "JsonSchemaForm", stepId: "JsonSchemaForm" }, onEvent: o, children: (0, fr.jsx)(Or, { baseUrl: r, children: (0, fr.jsx)(le, i({}, t)) }) }) });
|
|
2906
|
+
};
|
|
2907
|
+
var Ra = zu;
|
|
2908
|
+
var Qm = () => {
|
|
2909
|
+
};
|
|
2911
2910
|
var el = { "dynamicFlows.ArraySchema.addItem": "Speichern", "dynamicFlows.ArraySchema.addItemTitle": "Artikel hinzuf\xFCgen", "dynamicFlows.ArraySchema.editItem": "Speichern", "dynamicFlows.ArraySchema.maxItemsError": "Bitte f\xFCge {maxItems} oder weniger hinzu.", "dynamicFlows.ArraySchema.minItemsError": "Bitte f\xFCge mindestens {minItems} hinzu.", "dynamicFlows.ArraySchema.removeItem": "Entfernen", "dynamicFlows.CameraCapture.CameraNotSupported.paragraph": "Der von dir verwendete Browser unterst\xFCtzt keine Kameras. Bitte verwende einen anderen Browser oder ein anderes Ger\xE4t, oder lade unsere App herunter", "dynamicFlows.CameraCapture.CameraNotSupported.title": "Kamera wird nicht unterst\xFCtzt", "dynamicFlows.CameraCapture.NoCameraAccess.action": "Kamerazugriff genehmigen", "dynamicFlows.CameraCapture.NoCameraAccess.paragraph": "Aktiviere den Kamerazugriff in den Einstellungen deines Browsers, um weitermachen zu k\xF6nnen.", "dynamicFlows.CameraCapture.NoCameraAccess.title": "Wir k\xF6nnen nicht auf deine Kamera zugreifen", "dynamicFlows.CameraCapture.reviewInstructions": "Ist das aufgenommene Bild deutlich erkennbar und vollst\xE4ndig?", "dynamicFlows.CameraCapture.reviewRetry": "Nein, erneut versuchen", "dynamicFlows.CameraCapture.reviewSubmit": "Ja, senden", "dynamicFlows.ControlFeedback.maxLength": "Bitte gib nicht mehr als {maxLength} Zeichen ein.", "dynamicFlows.ControlFeedback.maximum": "Bitte gib eine Zahl ein, die {maximum} oder weniger betr\xE4gt.", "dynamicFlows.ControlFeedback.maximumDate": "Bitte gib ein Datum ein, das am oder vor dem {maximum} liegt.", "dynamicFlows.ControlFeedback.minLength": "Bitte gib mindestens {minLength} Zeichen ein.", "dynamicFlows.ControlFeedback.minimum": "Bitte gib eine Zahl ein, die {minimum} oder mehr betr\xE4gt.", "dynamicFlows.ControlFeedback.minimumDate": "Bitte gib ein Datum ein, das am oder nach dem {minimum} liegt.", "dynamicFlows.ControlFeedback.pattern": "Bitte gib die Angabe im richtigen Format ein.", "dynamicFlows.ControlFeedback.patternDate": "Bitte gib ein Datum im richtigen Format ein.", "dynamicFlows.ControlFeedback.required": "Bitte f\xFClle dieses Feld aus.", "dynamicFlows.ControlFeedback.type": "Falscher Typ", "dynamicFlows.DynamicExternal.retryTitle": "Fenster erneut \xF6ffnen", "dynamicFlows.DynamicParagraph.copied": "In Zwischenablage kopiert", "dynamicFlows.DynamicParagraph.copy": "Kopieren", "dynamicFlows.ErrorBoundary.errorAlert": "Hoppla \u2013 da ist was schiefgelaufen...", "dynamicFlows.ErrorBoundary.retry": "Erneut versuchen", "dynamicFlows.ExternalConfirmation.cancel": "Abbrechen", "dynamicFlows.ExternalConfirmation.description": "Bitte best\xE4tige, dass du **{origin}** in einem neuen Browser-Tab \xF6ffnen m\xF6chtest.", "dynamicFlows.ExternalConfirmation.open": "In neuem Tab \xF6ffnen", "dynamicFlows.ExternalConfirmation.title": "Bitte best\xE4tigen", "dynamicFlows.Help.ariaLabel": "Klicke hier f\xFCr mehr Informationen.", "dynamicFlows.MultipleFileUploadSchema.maxFileSizeError": "Diese Datei ist leider zu gro\xDF. Bitte lade eine kleinere Datei hoch.", "dynamicFlows.MultipleFileUploadSchema.maxItemsError": "Bitte lade {maxItems} oder weniger Dateien hoch.", "dynamicFlows.MultipleFileUploadSchema.minItemsError": "Bitte lade mindestens {minItems} Datei(en) hoch.", "dynamicFlows.PersistAsyncSchema.genericError": "Da ist etwas schiefgelaufen. Probiere es bitte sp\xE4ter noch einmal.", "dynamicFlows.ReadOnlySchema.no": "Nein", "dynamicFlows.ReadOnlySchema.yes": "Ja" };
|
|
2912
2911
|
var tl = { "dynamicFlows.ArraySchema.addItem": "Save", "dynamicFlows.ArraySchema.addItemTitle": "Add Item", "dynamicFlows.ArraySchema.editItem": "Save", "dynamicFlows.ArraySchema.maxItemsError": "Please add {maxItems} or fewer.", "dynamicFlows.ArraySchema.minItemsError": "Please add at least {minItems}.", "dynamicFlows.ArraySchema.removeItem": "Remove", "dynamicFlows.CameraCapture.CameraNotSupported.paragraph": "The browser you're using doesn't have support for a camera. Try a different browser, device, or download our mobile app.", "dynamicFlows.CameraCapture.CameraNotSupported.title": "Camera not supported", "dynamicFlows.CameraCapture.NoCameraAccess.action": "Enable camera access", "dynamicFlows.CameraCapture.NoCameraAccess.paragraph": "Enable camera access in your browser's settings to get going again.", "dynamicFlows.CameraCapture.NoCameraAccess.title": "We can't access your camera", "dynamicFlows.CameraCapture.reviewInstructions": "Is your picture clear, readable and complete?", "dynamicFlows.CameraCapture.reviewRetry": "No, try again", "dynamicFlows.CameraCapture.reviewSubmit": "Yes, submit", "dynamicFlows.ControlFeedback.maxLength": "Please enter {maxLength} or fewer characters.", "dynamicFlows.ControlFeedback.maximum": "Please enter a number that's {maximum} or less.", "dynamicFlows.ControlFeedback.maximumDate": "Please enter a date that's on or before {maximum}.", "dynamicFlows.ControlFeedback.minLength": "Please enter at least {minLength} characters.", "dynamicFlows.ControlFeedback.minimum": "Please enter a number that's {minimum} or more.", "dynamicFlows.ControlFeedback.minimumDate": "Please enter a date that's on or after {minimum}.", "dynamicFlows.ControlFeedback.pattern": "Please enter this in the correct format.", "dynamicFlows.ControlFeedback.patternDate": "Please enter a date in the corrrect format.", "dynamicFlows.ControlFeedback.required": "Please fill out this field.", "dynamicFlows.ControlFeedback.type": "Incorrect type", "dynamicFlows.DynamicExternal.retryTitle": "Reopen window", "dynamicFlows.DynamicParagraph.copied": "Copied to clipboard", "dynamicFlows.DynamicParagraph.copy": "Copy", "dynamicFlows.ErrorBoundary.errorAlert": "Oops. Something went wrong...", "dynamicFlows.ErrorBoundary.retry": "Retry", "dynamicFlows.ExternalConfirmation.cancel": "Cancel", "dynamicFlows.ExternalConfirmation.description": "Please confirm you want to open **{origin}** in a new browser tab.", "dynamicFlows.ExternalConfirmation.open": "Open in new tab", "dynamicFlows.ExternalConfirmation.title": "Please confirm", "dynamicFlows.Help.ariaLabel": "Click here for more info.", "dynamicFlows.MultipleFileUploadSchema.maxFileSizeError": "Sorry, that file is too big. Please upload a smaller file.", "dynamicFlows.MultipleFileUploadSchema.maxItemsError": "Please upload {maxItems} or fewer files.", "dynamicFlows.MultipleFileUploadSchema.minItemsError": "Please upload at least {minItems} file(s).", "dynamicFlows.PersistAsyncSchema.genericError": "Something went wrong, please try again later!", "dynamicFlows.ReadOnlySchema.no": "No", "dynamicFlows.ReadOnlySchema.yes": "Yes" };
|
|
2913
2912
|
var rl = { "dynamicFlows.ArraySchema.addItem": "Guardar", "dynamicFlows.ArraySchema.addItemTitle": "A\xF1adir elemento", "dynamicFlows.ArraySchema.editItem": "Guardar", "dynamicFlows.ArraySchema.maxItemsError": "A\xF1ade {maxItems} o menos.", "dynamicFlows.ArraySchema.minItemsError": "A\xF1ade al menos {minItems}.", "dynamicFlows.ArraySchema.removeItem": "Eliminar", "dynamicFlows.CameraCapture.CameraNotSupported.paragraph": "El navegador que est\xE1s utilizando no es compatible con una c\xE1mara. Prueba con otro navegador, dispositivo o descarga nuestra app m\xF3vil.", "dynamicFlows.CameraCapture.CameraNotSupported.title": "C\xE1mara no compatible", "dynamicFlows.CameraCapture.NoCameraAccess.action": "Habilitar acceso a la c\xE1mara", "dynamicFlows.CameraCapture.NoCameraAccess.paragraph": "Habilita el acceso a la c\xE1mara en la configuraci\xF3n de tu navegador para volver a activarla.", "dynamicFlows.CameraCapture.NoCameraAccess.title": "No podemos acceder a tu c\xE1mara", "dynamicFlows.CameraCapture.reviewInstructions": "\xBFTu foto es clara, legible y completa?", "dynamicFlows.CameraCapture.reviewRetry": "No, intentar de nuevo", "dynamicFlows.CameraCapture.reviewSubmit": "S\xED, enviar", "dynamicFlows.ControlFeedback.maxLength": "Introduce {maxLength} caracteres o menos.", "dynamicFlows.ControlFeedback.maximum": "Introduce una cifra igual o inferior a {maximum}.", "dynamicFlows.ControlFeedback.maximumDate": "Introduce una fecha que sea igual o anterior al {maximum}.", "dynamicFlows.ControlFeedback.minLength": "Introduce al menos {minLength} caracteres.", "dynamicFlows.ControlFeedback.minimum": "Introduce una cifra igual o inferior a {minimum}.", "dynamicFlows.ControlFeedback.minimumDate": "Introduce una fecha que sea igual o posterior al {minimum}.", "dynamicFlows.ControlFeedback.pattern": "Utiliza el formato correcto.", "dynamicFlows.ControlFeedback.patternDate": "Introduce la fecha en un formato correcto.", "dynamicFlows.ControlFeedback.required": "Completa este campo.", "dynamicFlows.ControlFeedback.type": "Tipo incorrecto", "dynamicFlows.DynamicExternal.retryTitle": "Reabrir ventana", "dynamicFlows.DynamicParagraph.copied": "Copiado al portapapeles", "dynamicFlows.DynamicParagraph.copy": "Copiar", "dynamicFlows.ErrorBoundary.errorAlert": "Vaya. Algo ha salido mal...", "dynamicFlows.ErrorBoundary.retry": "Reintentar", "dynamicFlows.ExternalConfirmation.cancel": "Cancelar", "dynamicFlows.ExternalConfirmation.description": "Confirma que quieres abrir **{origin}** en una nueva pesta\xF1a del navegador.", "dynamicFlows.ExternalConfirmation.open": "Abrir en nueva pesta\xF1a", "dynamicFlows.ExternalConfirmation.title": "Por favor, confirma", "dynamicFlows.Help.ariaLabel": "Haz clic aqu\xED para obtener m\xE1s informaci\xF3n.", "dynamicFlows.MultipleFileUploadSchema.maxFileSizeError": "Lo sentimos, el archivo pesa demasiado. Sube uno m\xE1s peque\xF1o.", "dynamicFlows.MultipleFileUploadSchema.maxItemsError": "Sube {maxItems} o menos archivos.", "dynamicFlows.MultipleFileUploadSchema.minItemsError": "Sube al menos {minItems} archivo(s).", "dynamicFlows.PersistAsyncSchema.genericError": "Algo ha ido mal. Int\xE9ntalo de nuevo m\xE1s tarde.", "dynamicFlows.ReadOnlySchema.no": "No", "dynamicFlows.ReadOnlySchema.yes": "S\xED" };
|
|
@@ -2922,10 +2921,10 @@ var require_main_min = __commonJS({
|
|
|
2922
2921
|
var dl = { "dynamicFlows.ArraySchema.addItem": "\u0421\u043E\u0445\u0440\u0430\u043D\u0438\u0442\u044C", "dynamicFlows.ArraySchema.addItemTitle": "\u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C \u043F\u0443\u043D\u043A\u0442", "dynamicFlows.ArraySchema.editItem": "\u0421\u043E\u0445\u0440\u0430\u043D\u0438\u0442\u044C", "dynamicFlows.ArraySchema.maxItemsError": "\u041F\u043E\u0436\u0430\u043B\u0443\u0439\u0441\u0442\u0430, \u0434\u043E\u0431\u0430\u0432\u044C\u0442\u0435 {maxItems} \u0438\u043B\u0438 \u043C\u0435\u043D\u044C\u0448\u0435.", "dynamicFlows.ArraySchema.minItemsError": "\u041F\u043E\u0436\u0430\u043B\u0443\u0439\u0441\u0442\u0430, \u0434\u043E\u0431\u0430\u0432\u044C\u0442\u0435 \u043F\u043E \u043A\u0440\u0430\u0439\u043D\u0435\u0439 \u043C\u0435\u0440\u0435 {minItems}.", "dynamicFlows.ArraySchema.removeItem": "\u0423\u0434\u0430\u043B\u0438\u0442\u044C", "dynamicFlows.CameraCapture.CameraNotSupported.paragraph": "\u0418\u0441\u043F\u043E\u043B\u044C\u0437\u0443\u0435\u043C\u044B\u0439 \u0432\u0430\u043C\u0438 \u0431\u0440\u0430\u0443\u0437\u0435\u0440 \u043D\u0435 \u043F\u043E\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u0442 \u043A\u0430\u043C\u0435\u0440\u0443. \u041F\u043E\u043F\u0440\u043E\u0431\u0443\u0439\u0442\u0435 \u0434\u0440\u0443\u0433\u043E\u0439 \u0431\u0440\u0430\u0443\u0437\u0435\u0440 \u0438\u043B\u0438 \u0443\u0441\u0442\u0440\u043E\u0439\u0441\u0442\u0432\u043E, \u0438\u043B\u0438 \u0441\u043A\u0430\u0447\u0430\u0439\u0442\u0435 \u043D\u0430\u0448\u0435 \u043F\u0440\u0438\u043B\u043E\u0436\u0435\u043D\u0438\u0435.", "dynamicFlows.CameraCapture.CameraNotSupported.title": "\u041A\u0430\u043C\u0435\u0440\u0430 \u043D\u0435 \u043F\u043E\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u0442\u0441\u044F", "dynamicFlows.CameraCapture.NoCameraAccess.action": "\u0420\u0430\u0437\u0440\u0435\u0448\u0438\u0442\u044C \u0434\u043E\u0441\u0442\u0443\u043F \u043A \u043A\u0430\u043C\u0435\u0440\u0435", "dynamicFlows.CameraCapture.NoCameraAccess.paragraph": "\u0420\u0430\u0437\u0440\u0435\u0448\u0438\u0442\u0435 \u0434\u043E\u0441\u0442\u0443\u043F \u043A \u043A\u0430\u043C\u0435\u0440\u0435 \u0432 \u043D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0430\u0445 \u0432\u0430\u0448\u0435\u0433\u043E \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0430, \u0447\u0442\u043E\u0431\u044B \u043F\u043E\u043F\u0440\u043E\u0431\u043E\u0432\u0430\u0442\u044C \u0441\u043D\u043E\u0432\u0430.", "dynamicFlows.CameraCapture.NoCameraAccess.title": "\u041C\u044B \u043D\u0435 \u043C\u043E\u0436\u0435\u043C \u043F\u043E\u043B\u0443\u0447\u0438\u0442\u044C \u0434\u043E\u0441\u0442\u0443\u043F \u043A \u0432\u0430\u0448\u0435\u0439 \u043A\u0430\u043C\u0435\u0440\u0435", "dynamicFlows.CameraCapture.reviewInstructions": "\u0412\u0430\u0448\u0430 \u0444\u043E\u0442\u043E\u0433\u0440\u0430\u0444\u0438\u044F \u0447\u0435\u0442\u043A\u0430\u044F, \u043B\u0435\u0433\u043A\u043E \u0447\u0438\u0442\u0430\u0435\u043C\u0430\u044F \u0438 \u043D\u0435 \u043E\u0431\u0440\u0435\u0437\u0430\u043D\u0430?", "dynamicFlows.CameraCapture.reviewRetry": "\u041D\u0435\u0442, \u043F\u043E\u043F\u0440\u043E\u0431\u043E\u0432\u0430\u0442\u044C \u0435\u0449\u0435 \u0440\u0430\u0437", "dynamicFlows.CameraCapture.reviewSubmit": "\u0414\u0430, \u043E\u0442\u043F\u0440\u0430\u0432\u0438\u0442\u044C", "dynamicFlows.ControlFeedback.maxLength": "\u041F\u043E\u0436\u0430\u043B\u0443\u0439\u0441\u0442\u0430, \u0432\u0432\u0435\u0434\u0438\u0442\u0435 {maxLength} \u0441\u0438\u043C\u0432\u043E\u043B\u043E\u0432 \u0438\u043B\u0438 \u043C\u0435\u043D\u044C\u0448\u0435.", "dynamicFlows.ControlFeedback.maximum": "\u041F\u043E\u0436\u0430\u043B\u0443\u0439\u0441\u0442\u0430, \u0432\u0432\u0435\u0434\u0438\u0442\u0435 \u0447\u0438\u0441\u043B\u043E, \u0440\u0430\u0432\u043D\u043E\u0435 {maximum} \u0438\u043B\u0438 \u043C\u0435\u043D\u044C\u0448\u0435.", "dynamicFlows.ControlFeedback.maximumDate": "\u041F\u043E\u0436\u0430\u043B\u0443\u0439\u0441\u0442\u0430, \u0432\u0432\u0435\u0434\u0438\u0442\u0435 \u0434\u0430\u0442\u0443, \u0440\u0430\u0432\u043D\u0443\u044E {maximum} \u0438\u043B\u0438 \u0431\u043E\u043B\u0435\u0435 \u0440\u0430\u043D\u043D\u044E\u044E.", "dynamicFlows.ControlFeedback.minLength": "\u041F\u043E\u0436\u0430\u043B\u0443\u0439\u0441\u0442\u0430, \u0432\u0432\u0435\u0434\u0438\u0442\u0435 \u043F\u043E \u043A\u0440\u0430\u0439\u043D\u0435\u0439 \u043C\u0435\u0440\u0435 {minLength} \u0441\u0438\u043C\u0432\u043E\u043B\u0430(-\u043E\u0432).", "dynamicFlows.ControlFeedback.minimum": "\u041F\u043E\u0436\u0430\u043B\u0443\u0439\u0441\u0442\u0430, \u0432\u0432\u0435\u0434\u0438\u0442\u0435 \u0447\u0438\u0441\u043B\u043E, \u0440\u0430\u0432\u043D\u043E\u0435 {minimum} \u0438\u043B\u0438 \u0431\u043E\u043B\u044C\u0448\u0435.", "dynamicFlows.ControlFeedback.minimumDate": "\u041F\u043E\u0436\u0430\u043B\u0443\u0439\u0441\u0442\u0430, \u0432\u0432\u0435\u0434\u0438\u0442\u0435 \u0434\u0430\u0442\u0443, \u0440\u0430\u0432\u043D\u0443\u044E {minimum} \u0438\u043B\u0438 \u0431\u043E\u043B\u0435\u0435 \u043F\u043E\u0437\u0434\u043D\u044E\u044E.", "dynamicFlows.ControlFeedback.pattern": "\u041F\u043E\u0436\u0430\u043B\u0443\u0439\u0441\u0442\u0430, \u0432\u0432\u0435\u0434\u0438\u0442\u0435 \u044D\u0442\u043E \u0432 \u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u043E\u043C \u0444\u043E\u0440\u043C\u0430\u0442\u0435.", "dynamicFlows.ControlFeedback.patternDate": "\u041F\u043E\u0436\u0430\u043B\u0443\u0439\u0441\u0442\u0430, \u0432\u0432\u0435\u0434\u0438\u0442\u0435 \u0434\u0430\u0442\u0443 \u0432 \u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u043E\u043C \u0444\u043E\u0440\u043C\u0430\u0442\u0435.", "dynamicFlows.ControlFeedback.required": "\u041F\u043E\u0436\u0430\u043B\u0443\u0439\u0441\u0442\u0430, \u0437\u0430\u043F\u043E\u043B\u043D\u0438\u0442\u0435 \u0434\u0430\u043D\u043D\u043E\u0435 \u043F\u043E\u043B\u0435.", "dynamicFlows.ControlFeedback.type": "\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u0442\u0438\u043F", "dynamicFlows.DynamicExternal.retryTitle": "\u041F\u043E\u0432\u0442\u043E\u0440\u043D\u043E \u043E\u0442\u043A\u0440\u044B\u0442\u044C \u043E\u043A\u043D\u043E", "dynamicFlows.DynamicParagraph.copied": "\u0421\u043A\u043E\u043F\u0438\u0440\u043E\u0432\u0430\u043D\u043E \u0432 \u0431\u0443\u0444\u0435\u0440 \u043E\u0431\u043C\u0435\u043D\u0430", "dynamicFlows.DynamicParagraph.copy": "\u041A\u043E\u043F\u0438\u0440\u043E\u0432\u0430\u0442\u044C", "dynamicFlows.ErrorBoundary.errorAlert": "\u0427\u0442\u043E-\u0442\u043E \u043F\u043E\u0448\u043B\u043E \u043D\u0435 \u0442\u0430\u043A...", "dynamicFlows.ErrorBoundary.retry": "\u041F\u043E\u0432\u0442\u043E\u0440\u0438\u0442\u044C \u043F\u043E\u043F\u044B\u0442\u043A\u0443", "dynamicFlows.ExternalConfirmation.cancel": "\u041E\u0442\u043C\u0435\u043D\u0438\u0442\u044C", "dynamicFlows.ExternalConfirmation.description": "\u041F\u043E\u0436\u0430\u043B\u0443\u0439\u0441\u0442\u0430, \u043F\u043E\u0434\u0442\u0432\u0435\u0440\u0434\u0438\u0442\u0435, \u0447\u0442\u043E \u0432\u044B \u0445\u043E\u0442\u0438\u0442\u0435 \u043E\u0442\u043A\u0440\u044B\u0442\u044C **{origin}** \u0432 \u043D\u043E\u0432\u043E\u0439 \u0432\u043A\u043B\u0430\u0434\u043A\u0435 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0430.", "dynamicFlows.ExternalConfirmation.open": "\u041E\u0442\u043A\u0440\u044B\u0442\u044C \u0432 \u043D\u043E\u0432\u043E\u0439 \u0432\u043A\u043B\u0430\u0434\u043A\u0435", "dynamicFlows.ExternalConfirmation.title": "\u041F\u043E\u0436\u0430\u043B\u0443\u0439\u0441\u0442\u0430, \u043F\u043E\u0434\u0442\u0432\u0435\u0440\u0434\u0438\u0442\u0435", "dynamicFlows.Help.ariaLabel": "\u041D\u0430\u0436\u043C\u0438\u0442\u0435 \u0437\u0434\u0435\u0441\u044C \u0434\u043B\u044F \u043F\u043E\u043B\u0443\u0447\u0435\u043D\u0438\u044F \u0434\u043E\u043F\u043E\u043B\u043D\u0438\u0442\u0435\u043B\u044C\u043D\u043E\u0439 \u0438\u043D\u0444\u043E\u0440\u043C\u0430\u0446\u0438\u0438.", "dynamicFlows.MultipleFileUploadSchema.maxFileSizeError": "\u0418\u0437\u0432\u0438\u043D\u0438\u0442\u0435, \u0444\u0430\u0439\u043B \u0441\u043B\u0438\u0448\u043A\u043E\u043C \u0431\u043E\u043B\u044C\u0448\u043E\u0439. \u041F\u043E\u0436\u0430\u043B\u0443\u0439\u0441\u0442\u0430, \u0437\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u0435 \u0444\u0430\u0439\u043B \u043C\u0435\u043D\u044C\u0448\u0435\u0433\u043E \u0440\u0430\u0437\u043C\u0435\u0440\u0430.", "dynamicFlows.MultipleFileUploadSchema.maxItemsError": "\u041F\u043E\u0436\u0430\u043B\u0443\u0439\u0441\u0442\u0430, \u0437\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u0435 \u043D\u0435 \u0431\u043E\u043B\u0435\u0435 {maxItems} \u0444\u0430\u0439\u043B\u043E\u0432.", "dynamicFlows.MultipleFileUploadSchema.minItemsError": "\u041F\u043E\u0436\u0430\u043B\u0443\u0439\u0441\u0442\u0430, \u0437\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u0435 \u043F\u043E \u043A\u0440\u0430\u0439\u043D\u0435\u0439 \u043C\u0435\u0440\u0435 {minItems} \u0444\u0430\u0439\u043B(-\u0430/\u043E\u0432).", "dynamicFlows.PersistAsyncSchema.genericError": "\u0427\u0442\u043E-\u0442\u043E \u043F\u043E\u0448\u043B\u043E \u043D\u0435 \u0442\u0430\u043A, \u043F\u043E\u0436\u0430\u043B\u0443\u0439\u0441\u0442\u0430, \u043F\u043E\u0432\u0442\u043E\u0440\u0438\u0442\u0435 \u043F\u043E\u043F\u044B\u0442\u043A\u0443 \u043F\u043E\u0437\u0436\u0435!", "dynamicFlows.ReadOnlySchema.no": "\u041D\u0435\u0442", "dynamicFlows.ReadOnlySchema.yes": "\u0414\u0430" };
|
|
2923
2922
|
var ul = { "dynamicFlows.ArraySchema.addItem": "\u0E1A\u0E31\u0E19\u0E17\u0E36\u0E01", "dynamicFlows.ArraySchema.addItemTitle": "Add Item", "dynamicFlows.ArraySchema.editItem": "\u0E1A\u0E31\u0E19\u0E17\u0E36\u0E01", "dynamicFlows.ArraySchema.maxItemsError": "\u0E42\u0E1B\u0E23\u0E14\u0E40\u0E1E\u0E34\u0E48\u0E21 {maxItems} \u0E2B\u0E23\u0E37\u0E2D\u0E19\u0E49\u0E2D\u0E22\u0E01\u0E27\u0E48\u0E32", "dynamicFlows.ArraySchema.minItemsError": "\u0E42\u0E1B\u0E23\u0E14\u0E40\u0E1E\u0E34\u0E48\u0E21\u0E2D\u0E22\u0E48\u0E32\u0E07\u0E19\u0E49\u0E2D\u0E22 {minItems}", "dynamicFlows.ArraySchema.removeItem": "\u0E25\u0E1A", "dynamicFlows.CameraCapture.CameraNotSupported.paragraph": "\u0E40\u0E1A\u0E23\u0E32\u0E27\u0E4C\u0E40\u0E0B\u0E2D\u0E23\u0E4C\u0E17\u0E35\u0E48\u0E04\u0E38\u0E13\u0E43\u0E0A\u0E49\u0E44\u0E21\u0E48\u0E23\u0E2D\u0E07\u0E23\u0E31\u0E1A\u0E01\u0E25\u0E49\u0E2D\u0E07 \u0E43\u0E2B\u0E49\u0E25\u0E2D\u0E07\u0E43\u0E0A\u0E49\u0E40\u0E1A\u0E23\u0E32\u0E27\u0E4C\u0E40\u0E0B\u0E2D\u0E23\u0E4C\u0E41\u0E25\u0E30\u0E2D\u0E38\u0E1B\u0E01\u0E23\u0E13\u0E4C\u0E2D\u0E37\u0E48\u0E19 \u0E2B\u0E23\u0E37\u0E2D\u0E14\u0E32\u0E27\u0E19\u0E4C\u0E42\u0E2B\u0E25\u0E14\u0E41\u0E2D\u0E1B\u0E21\u0E37\u0E2D\u0E16\u0E37\u0E2D\u0E02\u0E2D\u0E07\u0E40\u0E23\u0E32\u0E14\u0E39", "dynamicFlows.CameraCapture.CameraNotSupported.title": "\u0E44\u0E21\u0E48\u0E23\u0E2D\u0E07\u0E23\u0E31\u0E1A\u0E01\u0E25\u0E49\u0E2D\u0E07", "dynamicFlows.CameraCapture.NoCameraAccess.action": "\u0E40\u0E1B\u0E34\u0E14\u0E43\u0E0A\u0E49\u0E01\u0E32\u0E23\u0E40\u0E02\u0E49\u0E32\u0E16\u0E36\u0E07\u0E01\u0E25\u0E49\u0E2D\u0E07", "dynamicFlows.CameraCapture.NoCameraAccess.paragraph": "\u0E40\u0E1B\u0E34\u0E14\u0E43\u0E0A\u0E49\u0E07\u0E32\u0E19\u0E01\u0E32\u0E23\u0E40\u0E02\u0E49\u0E32\u0E16\u0E36\u0E07\u0E01\u0E25\u0E49\u0E2D\u0E07\u0E43\u0E19\u0E01\u0E32\u0E23\u0E15\u0E31\u0E49\u0E07\u0E04\u0E48\u0E32\u0E40\u0E1A\u0E23\u0E32\u0E27\u0E4C\u0E40\u0E0B\u0E2D\u0E23\u0E4C\u0E40\u0E1E\u0E37\u0E48\u0E2D\u0E40\u0E23\u0E34\u0E48\u0E21\u0E15\u0E49\u0E19\u0E43\u0E2B\u0E21\u0E48\u0E2D\u0E35\u0E01\u0E04\u0E23\u0E31\u0E49\u0E07", "dynamicFlows.CameraCapture.NoCameraAccess.title": "\u0E40\u0E23\u0E32\u0E44\u0E21\u0E48\u0E2A\u0E32\u0E21\u0E32\u0E23\u0E16\u0E40\u0E02\u0E49\u0E32\u0E16\u0E36\u0E07\u0E01\u0E25\u0E49\u0E2D\u0E07\u0E02\u0E2D\u0E07\u0E04\u0E38\u0E13\u0E44\u0E14\u0E49", "dynamicFlows.CameraCapture.reviewInstructions": "\u0E23\u0E39\u0E1B\u0E20\u0E32\u0E1E\u0E02\u0E2D\u0E07\u0E04\u0E38\u0E13\u0E0A\u0E31\u0E14\u0E40\u0E08\u0E19 \u0E2D\u0E48\u0E32\u0E19\u0E44\u0E14\u0E49 \u0E41\u0E25\u0E30\u0E04\u0E23\u0E1A\u0E16\u0E49\u0E27\u0E19\u0E2B\u0E23\u0E37\u0E2D\u0E44\u0E21\u0E48", "dynamicFlows.CameraCapture.reviewRetry": "\u0E44\u0E21\u0E48 \u0E25\u0E2D\u0E07\u0E2D\u0E35\u0E01\u0E17\u0E31\u0E49\u0E07", "dynamicFlows.CameraCapture.reviewSubmit": "\u0E43\u0E0A\u0E48 \u0E2A\u0E48\u0E07\u0E40\u0E25\u0E22", "dynamicFlows.ControlFeedback.maxLength": "\u0E42\u0E1B\u0E23\u0E14\u0E1B\u0E49\u0E2D\u0E19 {maxLength} \u0E2D\u0E31\u0E01\u0E02\u0E23\u0E30\u0E2B\u0E23\u0E37\u0E2D\u0E19\u0E49\u0E2D\u0E22\u0E01\u0E27\u0E48\u0E32", "dynamicFlows.ControlFeedback.maximum": "\u0E42\u0E1B\u0E23\u0E14\u0E1B\u0E49\u0E2D\u0E19\u0E15\u0E31\u0E27\u0E40\u0E25\u0E02 {maximum} \u0E2B\u0E23\u0E37\u0E2D\u0E19\u0E49\u0E2D\u0E22\u0E01\u0E27\u0E48\u0E32", "dynamicFlows.ControlFeedback.maximumDate": "\u0E42\u0E1B\u0E23\u0E14\u0E1B\u0E49\u0E2D\u0E19\u0E27\u0E31\u0E19\u0E17\u0E35\u0E48\u0E17\u0E35\u0E48\u0E2D\u0E22\u0E39\u0E48\u0E15\u0E23\u0E07\u0E1E\u0E2D\u0E14\u0E35\u0E2B\u0E23\u0E37\u0E2D\u0E01\u0E48\u0E2D\u0E19 {maximum}", "dynamicFlows.ControlFeedback.minLength": "\u0E42\u0E1B\u0E23\u0E14\u0E1B\u0E49\u0E2D\u0E19\u0E2D\u0E31\u0E01\u0E02\u0E23\u0E30\u0E2D\u0E22\u0E48\u0E32\u0E07\u0E19\u0E49\u0E2D\u0E22 {minLength} \u0E15\u0E31\u0E27", "dynamicFlows.ControlFeedback.minimum": "\u0E42\u0E1B\u0E23\u0E14\u0E1B\u0E49\u0E2D\u0E19\u0E15\u0E31\u0E27\u0E40\u0E25\u0E02 {minimum} \u0E2B\u0E23\u0E37\u0E2D\u0E21\u0E32\u0E01\u0E01\u0E27\u0E48\u0E32", "dynamicFlows.ControlFeedback.minimumDate": "\u0E42\u0E1B\u0E23\u0E14\u0E1B\u0E49\u0E2D\u0E19\u0E27\u0E31\u0E19\u0E17\u0E35\u0E48\u0E17\u0E35\u0E48\u0E2D\u0E22\u0E39\u0E48\u0E15\u0E23\u0E07\u0E1E\u0E2D\u0E14\u0E35\u0E2B\u0E23\u0E37\u0E2D\u0E2B\u0E25\u0E31\u0E07 {minimum}", "dynamicFlows.ControlFeedback.pattern": "\u0E42\u0E1B\u0E23\u0E14\u0E43\u0E2A\u0E48\u0E43\u0E19\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E17\u0E35\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07", "dynamicFlows.ControlFeedback.patternDate": "\u0E42\u0E1B\u0E23\u0E14\u0E1B\u0E49\u0E2D\u0E19\u0E27\u0E31\u0E19\u0E17\u0E35\u0E48\u0E43\u0E19\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E17\u0E35\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07", "dynamicFlows.ControlFeedback.required": "\u0E42\u0E1B\u0E23\u0E14\u0E43\u0E2A\u0E48\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E43\u0E19\u0E0A\u0E48\u0E2D\u0E07\u0E19\u0E35\u0E49", "dynamicFlows.ControlFeedback.type": "\u0E1B\u0E23\u0E30\u0E40\u0E20\u0E17\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07", "dynamicFlows.DynamicExternal.retryTitle": "\u0E40\u0E1B\u0E34\u0E14\u0E2B\u0E19\u0E49\u0E32\u0E15\u0E48\u0E32\u0E07\u0E2D\u0E35\u0E01\u0E04\u0E23\u0E31\u0E49\u0E07", "dynamicFlows.DynamicParagraph.copied": "\u0E04\u0E31\u0E14\u0E25\u0E2D\u0E01\u0E44\u0E1B\u0E22\u0E31\u0E07\u0E04\u0E25\u0E34\u0E1B\u0E1A\u0E2D\u0E23\u0E4C\u0E14", "dynamicFlows.DynamicParagraph.copy": "\u0E04\u0E31\u0E14\u0E25\u0E2D\u0E01", "dynamicFlows.ErrorBoundary.errorAlert": "\u0E2D\u0E4A\u0E30 \u0E40\u0E01\u0E34\u0E14\u0E02\u0E49\u0E2D\u0E1C\u0E34\u0E14\u0E1E\u0E25\u0E32\u0E14\u0E1A\u0E32\u0E07\u0E2D\u0E22\u0E48\u0E32\u0E07...", "dynamicFlows.ErrorBoundary.retry": "\u0E25\u0E2D\u0E07\u0E2D\u0E35\u0E01\u0E04\u0E23\u0E31\u0E49\u0E07", "dynamicFlows.ExternalConfirmation.cancel": "\u0E22\u0E01\u0E40\u0E25\u0E34\u0E01", "dynamicFlows.ExternalConfirmation.description": "\u0E42\u0E1B\u0E23\u0E14\u0E22\u0E37\u0E19\u0E22\u0E31\u0E19\u0E27\u0E48\u0E32\u0E04\u0E38\u0E13\u0E15\u0E49\u0E2D\u0E07\u0E01\u0E32\u0E23\u0E40\u0E1B\u0E34\u0E14 **{origin}** \u0E40\u0E1B\u0E47\u0E19\u0E41\u0E17\u0E47\u0E1A\u0E43\u0E2B\u0E21\u0E48\u0E43\u0E19\u0E40\u0E1A\u0E23\u0E32\u0E27\u0E4C\u0E40\u0E0B\u0E2D\u0E23\u0E4C", "dynamicFlows.ExternalConfirmation.open": "\u0E40\u0E1B\u0E34\u0E14\u0E43\u0E19\u0E41\u0E17\u0E47\u0E1A\u0E43\u0E2B\u0E21\u0E48", "dynamicFlows.ExternalConfirmation.title": "\u0E42\u0E1B\u0E23\u0E14\u0E22\u0E37\u0E19\u0E22\u0E31\u0E19", "dynamicFlows.Help.ariaLabel": "\u0E04\u0E25\u0E34\u0E01\u0E17\u0E35\u0E48\u0E19\u0E35\u0E48\u0E40\u0E1E\u0E37\u0E48\u0E2D\u0E14\u0E39\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E40\u0E1E\u0E34\u0E48\u0E21\u0E40\u0E15\u0E34\u0E21", "dynamicFlows.MultipleFileUploadSchema.maxFileSizeError": "\u0E02\u0E2D\u0E2D\u0E20\u0E31\u0E22 \u0E44\u0E1F\u0E25\u0E4C\u0E19\u0E31\u0E49\u0E19\u0E43\u0E2B\u0E0D\u0E48\u0E40\u0E01\u0E34\u0E19\u0E44\u0E1B \u0E42\u0E1B\u0E23\u0E14\u0E2D\u0E31\u0E1B\u0E42\u0E2B\u0E25\u0E14\u0E44\u0E1F\u0E25\u0E4C\u0E17\u0E35\u0E48\u0E21\u0E35\u0E02\u0E19\u0E32\u0E14\u0E40\u0E25\u0E47\u0E01\u0E25\u0E07", "dynamicFlows.MultipleFileUploadSchema.maxItemsError": "\u0E42\u0E1B\u0E23\u0E14\u0E2D\u0E31\u0E1B\u0E42\u0E2B\u0E25\u0E14 {maxItems} \u0E44\u0E1F\u0E25\u0E4C\u0E2B\u0E23\u0E37\u0E2D\u0E19\u0E49\u0E2D\u0E22\u0E01\u0E27\u0E48\u0E32", "dynamicFlows.MultipleFileUploadSchema.minItemsError": "\u0E42\u0E1B\u0E23\u0E14\u0E2D\u0E31\u0E1B\u0E42\u0E2B\u0E25\u0E14\u0E2D\u0E22\u0E48\u0E32\u0E07\u0E19\u0E49\u0E2D\u0E22 {minItems} \u0E44\u0E1F\u0E25\u0E4C", "dynamicFlows.PersistAsyncSchema.genericError": "\u0E40\u0E01\u0E34\u0E14\u0E02\u0E49\u0E2D\u0E1C\u0E34\u0E14\u0E1E\u0E25\u0E32\u0E14 \u0E42\u0E1B\u0E23\u0E14\u0E25\u0E2D\u0E07\u0E2D\u0E35\u0E01\u0E04\u0E23\u0E31\u0E49\u0E07\u0E20\u0E32\u0E22\u0E2B\u0E25\u0E31\u0E07!", "dynamicFlows.ReadOnlySchema.no": "\u0E44\u0E21\u0E48\u0E43\u0E0A\u0E48", "dynamicFlows.ReadOnlySchema.yes": "\u0E43\u0E0A\u0E48" };
|
|
2924
2923
|
var pl = { "dynamicFlows.ArraySchema.addItem": "Kaydet", "dynamicFlows.ArraySchema.addItemTitle": "Add Item", "dynamicFlows.ArraySchema.editItem": "Kaydet", "dynamicFlows.ArraySchema.maxItemsError": "L\xFCtfen {maxItems} veya daha az ekleme yap\u0131n", "dynamicFlows.ArraySchema.minItemsError": "L\xFCtfen en az {minItems} ekleme yap\u0131n.", "dynamicFlows.ArraySchema.removeItem": "Kald\u0131r", "dynamicFlows.CameraCapture.CameraNotSupported.paragraph": "Kulland\u0131\u011F\u0131n\u0131z taray\u0131c\u0131da kamera deste\u011Fi yok. Farkl\u0131 bir taray\u0131c\u0131 / cihaz deneyin veya mobil uygulamam\u0131z\u0131 indirin.", "dynamicFlows.CameraCapture.CameraNotSupported.title": "Kamera desteklenmiyor", "dynamicFlows.CameraCapture.NoCameraAccess.action": "Kamera eri\u015Fimi verin", "dynamicFlows.CameraCapture.NoCameraAccess.paragraph": "Tekrar ba\u015Flamak i\xE7in taray\u0131c\u0131n\u0131z\u0131n ayarlar\u0131nda kamera eri\u015Fimini etkinle\u015Ftirin.", "dynamicFlows.CameraCapture.NoCameraAccess.title": "Kameran\u0131za eri\u015Femiyoruz", "dynamicFlows.CameraCapture.reviewInstructions": "Foto\u011Fraf\u0131n\u0131z net, okunakl\u0131 ve eksiksiz mi?", "dynamicFlows.CameraCapture.reviewRetry": "Hay\u0131r, tekrar dene", "dynamicFlows.CameraCapture.reviewSubmit": "Evet, g\xF6nder", "dynamicFlows.ControlFeedback.maxLength": "L\xFCtfen {maxLength} veya daha az karakter girin.", "dynamicFlows.ControlFeedback.maximum": "L\xFCtfen {maximum} veya daha d\xFC\u015F\xFCk bir say\u0131 girin.", "dynamicFlows.ControlFeedback.maximumDate": "L\xFCtfen {maximum} veya daha erken bir tarih girin.", "dynamicFlows.ControlFeedback.minLength": "En az {minLength} karakter girebilirsiniz.", "dynamicFlows.ControlFeedback.minimum": "L\xFCtfen {minimum} veya daha y\xFCksek bir say\u0131 girin.", "dynamicFlows.ControlFeedback.minimumDate": "L\xFCtfen {minimum} veya daha ge\xE7 bir tarih girin.", "dynamicFlows.ControlFeedback.pattern": "Yanl\u0131\u015F bi\xE7im", "dynamicFlows.ControlFeedback.patternDate": "L\xFCtfen tarihi do\u011Fru bi\xE7imde girin.", "dynamicFlows.ControlFeedback.required": "L\xFCtfen bu alan\u0131 doldurun.", "dynamicFlows.ControlFeedback.type": "Ge\xE7ersiz se\xE7im", "dynamicFlows.DynamicExternal.retryTitle": "Pencereyi yeniden a\xE7", "dynamicFlows.DynamicParagraph.copied": "Panoya kopyaland\u0131", "dynamicFlows.DynamicParagraph.copy": "Kopyala", "dynamicFlows.ErrorBoundary.errorAlert": "Aman\u0131n! Bir \u015Feyler ters gitti...", "dynamicFlows.ErrorBoundary.retry": "Tekrar dene", "dynamicFlows.ExternalConfirmation.cancel": "\u0130ptal edin", "dynamicFlows.ExternalConfirmation.description": "L\xFCtfen yeni bir taray\u0131c\u0131 sekmesinde **{origin}** a\xE7mak istedi\u011Finizi onaylay\u0131n.", "dynamicFlows.ExternalConfirmation.open": "Yeni sekmede a\xE7", "dynamicFlows.ExternalConfirmation.title": "L\xFCtfen onaylay\u0131n", "dynamicFlows.Help.ariaLabel": "Ayr\u0131nt\u0131lar i\xE7in t\u0131klay\u0131n.", "dynamicFlows.MultipleFileUploadSchema.maxFileSizeError": "\xDCzg\xFCn\xFCz, bu dosya \xE7ok b\xFCy\xFCk. L\xFCtfen daha k\xFC\xE7\xFCk bir dosya y\xFCkleyin.", "dynamicFlows.MultipleFileUploadSchema.maxItemsError": "L\xFCtfen {maxItems} veya daha az dosya y\xFCkleyin.", "dynamicFlows.MultipleFileUploadSchema.minItemsError": "L\xFCtfen en az {minItems} dosya y\xFCkleyin.", "dynamicFlows.PersistAsyncSchema.genericError": "Bir \u015Feyler ters gitti, l\xFCtfen tekrar deneyin", "dynamicFlows.ReadOnlySchema.no": "Hay\u0131r", "dynamicFlows.ReadOnlySchema.yes": "Evet" };
|
|
2925
|
-
var
|
|
2924
|
+
var Ba = { "dynamicFlows.ArraySchema.addItem": "\u4FDD\u5B58", "dynamicFlows.ArraySchema.addItemTitle": "Add Item", "dynamicFlows.ArraySchema.editItem": "\u4FDD\u5B58", "dynamicFlows.ArraySchema.maxItemsError": "\u8BF7\u6DFB\u52A0 {maxItems} \u4E2A\u6216\u66F4\u5C11\u3002", "dynamicFlows.ArraySchema.minItemsError": "\u8BF7\u81F3\u5C11\u6DFB\u52A0 {minItems}\u3002", "dynamicFlows.ArraySchema.removeItem": "\u5220\u9664", "dynamicFlows.CameraCapture.CameraNotSupported.paragraph": "The browser you're using doesn't have support for a camera. Try a different browser, device, or download our mobile app.", "dynamicFlows.CameraCapture.CameraNotSupported.title": "\u4E0D\u652F\u6301\u6444\u50CF\u5934", "dynamicFlows.CameraCapture.NoCameraAccess.action": "Enable camera access", "dynamicFlows.CameraCapture.NoCameraAccess.paragraph": "Enable camera access in your browser's settings to get going again.", "dynamicFlows.CameraCapture.NoCameraAccess.title": "We can't access your camera", "dynamicFlows.CameraCapture.reviewInstructions": "\u60A8\u7684\u56FE\u7247\u662F\u5426\u6E05\u6670\u3001\u53EF\u8BFB\u548C\u5B8C\u6574\uFF1F", "dynamicFlows.CameraCapture.reviewRetry": "\u5426\uFF0C\u91CD\u8BD5", "dynamicFlows.CameraCapture.reviewSubmit": "\u662F\uFF0C\u63D0\u4EA4", "dynamicFlows.ControlFeedback.maxLength": "\u8BF7\u8F93\u5165 {maxLength} \u4E2A\u6216\u66F4\u5C11\u5B57\u7B26", "dynamicFlows.ControlFeedback.maximum": "\u8BF7\u8F93\u5165\u4E00\u4E2A\u5C0F\u4E8E\u6216\u7B49\u4E8E {maximum} \u7684\u6570\u5B57", "dynamicFlows.ControlFeedback.maximumDate": "\u8BF7\u8F93\u5165 {maximum} \u6216\u4E4B\u524D\u7684\u65E5\u671F", "dynamicFlows.ControlFeedback.minLength": "\u8BF7\u81F3\u5C11\u8F93\u5165 {minLength} \u4E2A\u5B57\u7B26", "dynamicFlows.ControlFeedback.minimum": "\u8BF7\u8F93\u5165\u4E00\u4E2A\u5927\u4E8E\u6216\u7B49\u4E8E {minimum} \u7684\u6570\u5B57", "dynamicFlows.ControlFeedback.minimumDate": "\u8BF7\u8F93\u5165 {minimum} \u6216\u4E4B\u540E\u7684\u65E5\u671F", "dynamicFlows.ControlFeedback.pattern": "\u8BF7\u4EE5\u6B63\u786E\u7684\u683C\u5F0F\u8F93\u5165", "dynamicFlows.ControlFeedback.patternDate": "\u8BF7\u4EE5\u6B63\u786E\u7684\u683C\u5F0F\u8F93\u5165\u65E5\u671F", "dynamicFlows.ControlFeedback.required": "\u8BF7\u586B\u5199\u6B64\u5B57\u6BB5\u3002", "dynamicFlows.ControlFeedback.type": "\u7C7B\u578B\u4E0D\u6B63\u786E", "dynamicFlows.DynamicExternal.retryTitle": "\u91CD\u65B0\u6253\u5F00\u7A97\u53E3", "dynamicFlows.DynamicParagraph.copied": "\u5DF2\u590D\u5236\u5230\u526A\u8D34\u677F", "dynamicFlows.DynamicParagraph.copy": "\u590D\u5236", "dynamicFlows.ErrorBoundary.errorAlert": "\u7CDF\u7CD5\u3002\u51FA\u95EE\u9898\u4E86\u2026", "dynamicFlows.ErrorBoundary.retry": "\u91CD\u8BD5", "dynamicFlows.ExternalConfirmation.cancel": "\u53D6\u6D88", "dynamicFlows.ExternalConfirmation.description": "Please confirm you want to open **{origin}** in a new browser tab.", "dynamicFlows.ExternalConfirmation.open": "Open in new tab", "dynamicFlows.ExternalConfirmation.title": "Please confirm", "dynamicFlows.Help.ariaLabel": "\u70B9\u51FB\u6B64\u5904\u83B7\u53D6\u66F4\u591A\u4FE1\u606F\u3002", "dynamicFlows.MultipleFileUploadSchema.maxFileSizeError": "\u62B1\u6B49\uFF0C\u8BE5\u6587\u4EF6\u592A\u5927\u3002\u8BF7\u4E0A\u4F20\u4E00\u4E2A\u66F4\u5C0F\u7684\u6587\u4EF6\u3002", "dynamicFlows.MultipleFileUploadSchema.maxItemsError": "\u8BF7\u4E0A\u4F20 {maxItems} \u4E2A\u6216\u66F4\u5C11\u7684\u6587\u4EF6\u3002", "dynamicFlows.MultipleFileUploadSchema.minItemsError": "\u8BF7\u81F3\u5C11\u4E0A\u4F20 {minItems} \u4E2A\u6587\u4EF6\u3002", "dynamicFlows.PersistAsyncSchema.genericError": "\u51FA\u73B0\u4E00\u4E9B\u95EE\u9898\uFF0C\u8BF7\u7A0D\u540E\u91CD\u8BD5\uFF01", "dynamicFlows.ReadOnlySchema.no": "\u5426", "dynamicFlows.ReadOnlySchema.yes": "\u662F" };
|
|
2926
2925
|
var fl = { "dynamicFlows.ArraySchema.addItem": "\u5132\u5B58", "dynamicFlows.ArraySchema.addItemTitle": "\u6DFB\u52A0\u9805\u76EE", "dynamicFlows.ArraySchema.editItem": "\u5132\u5B58", "dynamicFlows.ArraySchema.maxItemsError": "\u8ACB\u6DFB\u52A0\u4E0D\u8D85\u904E{maxItems}\u9805\u3002", "dynamicFlows.ArraySchema.minItemsError": "\u8ACB\u81F3\u5C11\u6DFB\u52A0{minItems}\u9805\u3002", "dynamicFlows.ArraySchema.removeItem": "\u79FB\u9664", "dynamicFlows.CameraCapture.CameraNotSupported.paragraph": "\u4F60\u76EE\u524D\u4F7F\u7528\u7684\u700F\u89BD\u5668\u4E0D\u652F\u6301\u76F8\u6A5F\u3002\u8ACB\u5617\u8A66\u4F7F\u7528\u5176\u4ED6\u700F\u89BD\u5668\u6216\u5176\u4ED6\u88DD\u7F6E\uFF0C\u6216\u8005\u4F60\u53EF\u4EE5\u4E0B\u8F09\u6211\u5011\u7684\u61C9\u7528\u7A0B\u5F0F\u3002", "dynamicFlows.CameraCapture.CameraNotSupported.title": "\u4E0D\u652F\u6301\u76F8\u6A5F", "dynamicFlows.CameraCapture.NoCameraAccess.action": "\u5141\u8A31\u53D6\u7528\u76F8\u6A5F", "dynamicFlows.CameraCapture.NoCameraAccess.paragraph": "\u4F60\u53EF\u4EE5\u5728\u700F\u89BD\u5668\u7684\u8A2D\u5B9A\u4E2D\u958B\u555F\u76F8\u6A5F\u5B58\u53D6\u6B0A\u9650\u3002", "dynamicFlows.CameraCapture.NoCameraAccess.title": "\u6211\u5011\u7121\u6CD5\u53D6\u7528\u4F60\u7684\u76F8\u6A5F", "dynamicFlows.CameraCapture.reviewInstructions": "\u4F60\u7684\u7167\u7247\u662F\u5426\u5B8C\u6574\u3001\u6E05\u6670\u53CA\u53EF\u8B80\uFF1F", "dynamicFlows.CameraCapture.reviewRetry": "\u5426\uFF0C\u518D\u8A66\u4E00\u6B21", "dynamicFlows.CameraCapture.reviewSubmit": "\u662F\uFF0C\u63D0\u4EA4", "dynamicFlows.ControlFeedback.maxLength": "\u8ACB\u8F38\u5165\u6700\u591A{maxLength}\u500B\u5B57\u5143\u3002", "dynamicFlows.ControlFeedback.maximum": "\u8ACB\u8F38\u5165\u4E00\u500B\u5C0F\u65BC\u6216\u7B49\u65BC{maximum}\u7684\u6578\u5B57\u3002", "dynamicFlows.ControlFeedback.maximumDate": "\u8ACB\u8F38\u5165{maximum}\u6216\u4E4B\u524D\u7684\u65E5\u671F\u3002", "dynamicFlows.ControlFeedback.minLength": "\u8ACB\u8F38\u5165\u81F3\u5C11{minLength}\u500B\u5B57\u5143\u3002", "dynamicFlows.ControlFeedback.minimum": "\u8ACB\u8F38\u5165\u4E00\u500B\u5927\u65BC\u6216\u7B49\u65BC{minimum}\u7684\u6578\u5B57\u3002", "dynamicFlows.ControlFeedback.minimumDate": "\u8ACB\u8F38\u5165{minimum}\u6216\u4E4B\u5F8C\u7684\u65E5\u671F\u3002", "dynamicFlows.ControlFeedback.pattern": "\u8ACB\u4EE5\u6B63\u78BA\u683C\u5F0F\u8F38\u5165\u5185\u5BB9\u3002", "dynamicFlows.ControlFeedback.patternDate": "\u8ACB\u4EE5\u6B63\u78BA\u683C\u5F0F\u8F38\u5165\u65E5\u671F\u3002", "dynamicFlows.ControlFeedback.required": "\u8ACB\u586B\u5BEB\u6B64\u6B04\u4F4D\u3002", "dynamicFlows.ControlFeedback.type": "\u932F\u8AA4\u7684\u985E\u578B", "dynamicFlows.DynamicExternal.retryTitle": "\u91CD\u65B0\u6253\u958B\u8996\u7A97", "dynamicFlows.DynamicParagraph.copied": "\u8907\u88FD\u5230\u526A\u8CBC\u677F", "dynamicFlows.DynamicParagraph.copy": "\u8907\u88FD", "dynamicFlows.ErrorBoundary.errorAlert": "\u5662\uFF01\u51FA\u4E86\u4E9B\u554F\u984C...", "dynamicFlows.ErrorBoundary.retry": "\u91CD\u8A66", "dynamicFlows.ExternalConfirmation.cancel": "\u53D6\u6D88", "dynamicFlows.ExternalConfirmation.description": "\u8ACB\u78BA\u8A8D\u4F60\u662F\u5426\u8981\u5728\u700F\u89BD\u5668\u7684\u65B0\u5206\u9801\u6253\u958B**{origin}**\u3002", "dynamicFlows.ExternalConfirmation.open": "\u5728\u65B0\u5206\u9801\u4E2D\u958B\u555F", "dynamicFlows.ExternalConfirmation.title": "\u8ACB\u78BA\u8A8D", "dynamicFlows.Help.ariaLabel": "\u6309\u6B64\u67E5\u770B\u8A73\u60C5\u3002", "dynamicFlows.MultipleFileUploadSchema.maxFileSizeError": "\u62B1\u6B49\uFF0C\u8A72\u6A94\u6848\u592A\u5927\u3002\u8ACB\u4E0A\u8F09\u4E00\u500B\u8F03\u5C0F\u7684\u6A94\u6848\u3002", "dynamicFlows.MultipleFileUploadSchema.maxItemsError": "\u8ACB\u4E0D\u8981\u4E0A\u8F09\u8D85\u904E{maxItems}\u500B\u6A94\u6848\u3002", "dynamicFlows.MultipleFileUploadSchema.minItemsError": "\u8ACB\u4E0A\u8F09\u81F3\u5C11{minItems}\u500B\u6A94\u6848\u3002", "dynamicFlows.PersistAsyncSchema.genericError": "\u51FA\u4E86\u4E9B\u554F\u984C\uFF0C\u8ACB\u7A0D\u5F8C\u518D\u8A66\u3002", "dynamicFlows.ReadOnlySchema.no": "\u5426", "dynamicFlows.ReadOnlySchema.yes": "\u662F" };
|
|
2927
|
-
var
|
|
2928
|
-
var yl =
|
|
2926
|
+
var ap = { en: tl, de: el, es: rl, fr: ol, hu: al, id: nl, it: il, ja: sl, pl: ml, pt: ll, ro: cl, ru: dl, th: ul, tr: pl, zh: Ba, "zh-CN": Ba, "zh-HK": fl };
|
|
2927
|
+
var yl = ap;
|
|
2929
2928
|
}
|
|
2930
2929
|
});
|
|
2931
2930
|
|