@sme.up/ketchup2 2.0.0-SNAPSHOT-20250707103334 → 2.0.0-SNAPSHOT-20250707143641
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/dist/ketchup2.cjs.js +9 -9
- package/dist/ketchup2.es.js +679 -677
- package/dist/utils/date.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/ketchup2.es.js
CHANGED
|
@@ -58,7 +58,7 @@ function Bn() {
|
|
|
58
58
|
return "Profiler";
|
|
59
59
|
case S:
|
|
60
60
|
return "StrictMode";
|
|
61
|
-
case
|
|
61
|
+
case y:
|
|
62
62
|
return "Suspense";
|
|
63
63
|
case k:
|
|
64
64
|
return "SuspenseList";
|
|
@@ -154,7 +154,7 @@ function Bn() {
|
|
|
154
154
|
}
|
|
155
155
|
function c(h, x, $, _, j, I, U, W) {
|
|
156
156
|
return $ = I.ref, h = {
|
|
157
|
-
$$typeof:
|
|
157
|
+
$$typeof: g,
|
|
158
158
|
type: h,
|
|
159
159
|
key: x,
|
|
160
160
|
props: I,
|
|
@@ -184,7 +184,7 @@ function Bn() {
|
|
|
184
184
|
value: W
|
|
185
185
|
}), Object.freeze && (Object.freeze(h.props), Object.freeze(h)), h;
|
|
186
186
|
}
|
|
187
|
-
function
|
|
187
|
+
function f(h, x, $, _, j, I, U, W) {
|
|
188
188
|
var V = x.children;
|
|
189
189
|
if (V !== void 0)
|
|
190
190
|
if (_)
|
|
@@ -235,23 +235,23 @@ React keys must be passed directly to JSX without using spread:
|
|
|
235
235
|
);
|
|
236
236
|
}
|
|
237
237
|
function u(h) {
|
|
238
|
-
typeof h == "object" && h !== null && h.$$typeof ===
|
|
238
|
+
typeof h == "object" && h !== null && h.$$typeof === g && h._store && (h._store.validated = 1);
|
|
239
239
|
}
|
|
240
|
-
var
|
|
240
|
+
var d = rt, g = Symbol.for("react.transitional.element"), p = Symbol.for("react.portal"), w = Symbol.for("react.fragment"), S = Symbol.for("react.strict_mode"), E = Symbol.for("react.profiler"), b = Symbol.for("react.consumer"), T = Symbol.for("react.context"), v = Symbol.for("react.forward_ref"), y = Symbol.for("react.suspense"), k = Symbol.for("react.suspense_list"), A = Symbol.for("react.memo"), O = Symbol.for("react.lazy"), L = Symbol.for("react.activity"), R = Symbol.for("react.client.reference"), D = d.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, C = Object.prototype.hasOwnProperty, P = Array.isArray, N = console.createTask ? console.createTask : function() {
|
|
241
241
|
return null;
|
|
242
242
|
};
|
|
243
|
-
|
|
243
|
+
d = {
|
|
244
244
|
"react-stack-bottom-frame": function(h) {
|
|
245
245
|
return h();
|
|
246
246
|
}
|
|
247
247
|
};
|
|
248
|
-
var B, H = {}, z =
|
|
249
|
-
|
|
248
|
+
var B, H = {}, z = d["react-stack-bottom-frame"].bind(
|
|
249
|
+
d,
|
|
250
250
|
a
|
|
251
251
|
)(), X = N(r(a)), F = {};
|
|
252
252
|
Ve.Fragment = w, Ve.jsx = function(h, x, $, _, j) {
|
|
253
253
|
var I = 1e4 > D.recentlyCreatedOwnerStacks++;
|
|
254
|
-
return
|
|
254
|
+
return f(
|
|
255
255
|
h,
|
|
256
256
|
x,
|
|
257
257
|
$,
|
|
@@ -263,7 +263,7 @@ React keys must be passed directly to JSX without using spread:
|
|
|
263
263
|
);
|
|
264
264
|
}, Ve.jsxs = function(h, x, $, _, j) {
|
|
265
265
|
var I = 1e4 > D.recentlyCreatedOwnerStacks++;
|
|
266
|
-
return
|
|
266
|
+
return f(
|
|
267
267
|
h,
|
|
268
268
|
x,
|
|
269
269
|
$,
|
|
@@ -383,55 +383,55 @@ function zn() {
|
|
|
383
383
|
function o(u) {
|
|
384
384
|
if (!u || typeof u != "object")
|
|
385
385
|
throw new TypeError("argument obj is required");
|
|
386
|
-
var
|
|
387
|
-
if (!
|
|
386
|
+
var d = u.parameters, g = u.type;
|
|
387
|
+
if (!g || !a.test(g))
|
|
388
388
|
throw new TypeError("invalid type");
|
|
389
|
-
var p =
|
|
390
|
-
if (
|
|
391
|
-
for (var w, S = Object.keys(
|
|
389
|
+
var p = g;
|
|
390
|
+
if (d && typeof d == "object")
|
|
391
|
+
for (var w, S = Object.keys(d).sort(), E = 0; E < S.length; E++) {
|
|
392
392
|
if (w = S[E], !t.test(w))
|
|
393
393
|
throw new TypeError("invalid parameter name");
|
|
394
|
-
p += "; " + w + "=" + c(
|
|
394
|
+
p += "; " + w + "=" + c(d[w]);
|
|
395
395
|
}
|
|
396
396
|
return p;
|
|
397
397
|
}
|
|
398
398
|
function i(u) {
|
|
399
399
|
if (!u)
|
|
400
400
|
throw new TypeError("argument string is required");
|
|
401
|
-
var
|
|
402
|
-
if (typeof
|
|
401
|
+
var d = typeof u == "object" ? l(u) : u;
|
|
402
|
+
if (typeof d != "string")
|
|
403
403
|
throw new TypeError("argument string is required to be a string");
|
|
404
|
-
var
|
|
404
|
+
var g = d.indexOf(";"), p = g !== -1 ? d.slice(0, g).trim() : d.trim();
|
|
405
405
|
if (!a.test(p))
|
|
406
406
|
throw new TypeError("invalid media type");
|
|
407
|
-
var w = new
|
|
408
|
-
if (
|
|
407
|
+
var w = new f(p.toLowerCase());
|
|
408
|
+
if (g !== -1) {
|
|
409
409
|
var S, E, b;
|
|
410
|
-
for (n.lastIndex =
|
|
411
|
-
if (E.index !==
|
|
410
|
+
for (n.lastIndex = g; E = n.exec(d); ) {
|
|
411
|
+
if (E.index !== g)
|
|
412
412
|
throw new TypeError("invalid parameter format");
|
|
413
|
-
|
|
413
|
+
g += E[0].length, S = E[1].toLowerCase(), b = E[2], b.charCodeAt(0) === 34 && (b = b.slice(1, -1), b.indexOf("\\") !== -1 && (b = b.replace(r, "$1"))), w.parameters[S] = b;
|
|
414
414
|
}
|
|
415
|
-
if (
|
|
415
|
+
if (g !== d.length)
|
|
416
416
|
throw new TypeError("invalid parameter format");
|
|
417
417
|
}
|
|
418
418
|
return w;
|
|
419
419
|
}
|
|
420
420
|
function l(u) {
|
|
421
|
-
var
|
|
422
|
-
if (typeof u.getHeader == "function" ?
|
|
421
|
+
var d;
|
|
422
|
+
if (typeof u.getHeader == "function" ? d = u.getHeader("content-type") : typeof u.headers == "object" && (d = u.headers && u.headers["content-type"]), typeof d != "string")
|
|
423
423
|
throw new TypeError("content-type header is missing from object");
|
|
424
|
-
return
|
|
424
|
+
return d;
|
|
425
425
|
}
|
|
426
426
|
function c(u) {
|
|
427
|
-
var
|
|
428
|
-
if (t.test(
|
|
429
|
-
return
|
|
430
|
-
if (
|
|
427
|
+
var d = String(u);
|
|
428
|
+
if (t.test(d))
|
|
429
|
+
return d;
|
|
430
|
+
if (d.length > 0 && !e.test(d))
|
|
431
431
|
throw new TypeError("invalid parameter value");
|
|
432
|
-
return '"' +
|
|
432
|
+
return '"' + d.replace(s, "\\$1") + '"';
|
|
433
433
|
}
|
|
434
|
-
function
|
|
434
|
+
function f(u) {
|
|
435
435
|
this.parameters = /* @__PURE__ */ Object.create(null), this.type = u;
|
|
436
436
|
}
|
|
437
437
|
return Ke;
|
|
@@ -514,15 +514,15 @@ var Jn = zn(), Ie = /* @__PURE__ */ new Map(), _n = function(e) {
|
|
|
514
514
|
}
|
|
515
515
|
ye.push(e), e.setAttribute("src", "");
|
|
516
516
|
var c = s ? Zn : Qn;
|
|
517
|
-
c(l, a, function(
|
|
517
|
+
c(l, a, function(f, u) {
|
|
518
518
|
if (!u) {
|
|
519
|
-
ye.splice(ye.indexOf(e), 1), e = null, i(
|
|
519
|
+
ye.splice(ye.indexOf(e), 1), e = null, i(f);
|
|
520
520
|
return;
|
|
521
521
|
}
|
|
522
|
-
var
|
|
523
|
-
|
|
524
|
-
var
|
|
525
|
-
|
|
522
|
+
var d = e.getAttribute("id");
|
|
523
|
+
d && u.setAttribute("id", d);
|
|
524
|
+
var g = e.getAttribute("title");
|
|
525
|
+
g && u.setAttribute("title", g);
|
|
526
526
|
var p = e.getAttribute("width");
|
|
527
527
|
p && u.setAttribute("width", p);
|
|
528
528
|
var w = e.getAttribute("height");
|
|
@@ -548,11 +548,11 @@ var Jn = zn(), Ie = /* @__PURE__ */ new Map(), _n = function(e) {
|
|
|
548
548
|
path: [],
|
|
549
549
|
pattern: ["fill", "stroke"],
|
|
550
550
|
radialGradient: ["fill", "stroke"]
|
|
551
|
-
}, v,
|
|
551
|
+
}, v, y, k, A, O;
|
|
552
552
|
Object.keys(T).forEach(function(X) {
|
|
553
|
-
v = X, k = T[X],
|
|
553
|
+
v = X, k = T[X], y = u.querySelectorAll(v + "[id]");
|
|
554
554
|
for (var F = function(_, j) {
|
|
555
|
-
A =
|
|
555
|
+
A = y[_].id, O = A + "-" + tr();
|
|
556
556
|
var I;
|
|
557
557
|
Array.prototype.forEach.call(k, function(Y) {
|
|
558
558
|
I = u.querySelectorAll("[" + Y + '*="' + A + '"]');
|
|
@@ -563,12 +563,12 @@ var Jn = zn(), Ie = /* @__PURE__ */ new Map(), _n = function(e) {
|
|
|
563
563
|
});
|
|
564
564
|
for (var U = u.querySelectorAll("[*|href]"), W = [], V = 0, J = U.length; V < J; V++) {
|
|
565
565
|
var q = U[V].getAttributeNS(yt, "href");
|
|
566
|
-
q && q.toString() === "#" +
|
|
566
|
+
q && q.toString() === "#" + y[_].id && W.push(U[V]);
|
|
567
567
|
}
|
|
568
568
|
for (var se = 0, M = W.length; se < M; se++)
|
|
569
569
|
W[se].setAttributeNS(yt, "href", "#" + O);
|
|
570
|
-
|
|
571
|
-
}, h = 0, x =
|
|
570
|
+
y[_].id = O;
|
|
571
|
+
}, h = 0, x = y.length; h < x; h++)
|
|
572
572
|
F(h);
|
|
573
573
|
});
|
|
574
574
|
}
|
|
@@ -593,14 +593,14 @@ var Jn = zn(), Ie = /* @__PURE__ */ new Map(), _n = function(e) {
|
|
|
593
593
|
var r = t === void 0 ? {} : t, s = r.afterAll, a = s === void 0 ? function() {
|
|
594
594
|
} : s, o = r.afterEach, i = o === void 0 ? function() {
|
|
595
595
|
} : o, l = r.beforeEach, c = l === void 0 ? function() {
|
|
596
|
-
} : l,
|
|
596
|
+
} : l, f = r.cacheRequests, u = f === void 0 ? !0 : f, d = r.evalScripts, g = d === void 0 ? "never" : d, p = r.httpRequestWithCredentials, w = p === void 0 ? !1 : p, S = r.renumerateIRIElements, E = S === void 0 ? !0 : S;
|
|
597
597
|
if (e && "length" in e)
|
|
598
598
|
for (var b = 0, T = 0, v = e.length; T < v; T++)
|
|
599
|
-
Ht(e[T],
|
|
600
|
-
i(
|
|
599
|
+
Ht(e[T], g, E, u, w, c, function(y, k) {
|
|
600
|
+
i(y, k), e && "length" in e && e.length === ++b && a(b);
|
|
601
601
|
});
|
|
602
|
-
else e ? Ht(e,
|
|
603
|
-
i(
|
|
602
|
+
else e ? Ht(e, g, E, u, w, c, function(y, k) {
|
|
603
|
+
i(y, k), a(1), e = null;
|
|
604
604
|
}) : a(0);
|
|
605
605
|
}, ze = { exports: {} }, Je = { exports: {} }, Q = {};
|
|
606
606
|
/** @license React v16.13.1
|
|
@@ -615,28 +615,28 @@ var qt;
|
|
|
615
615
|
function sr() {
|
|
616
616
|
if (qt) return Q;
|
|
617
617
|
qt = 1;
|
|
618
|
-
var n = typeof Symbol == "function" && Symbol.for, e = n ? Symbol.for("react.element") : 60103, t = n ? Symbol.for("react.portal") : 60106, r = n ? Symbol.for("react.fragment") : 60107, s = n ? Symbol.for("react.strict_mode") : 60108, a = n ? Symbol.for("react.profiler") : 60114, o = n ? Symbol.for("react.provider") : 60109, i = n ? Symbol.for("react.context") : 60110, l = n ? Symbol.for("react.async_mode") : 60111, c = n ? Symbol.for("react.concurrent_mode") : 60111,
|
|
619
|
-
function T(
|
|
620
|
-
if (typeof
|
|
621
|
-
var k =
|
|
618
|
+
var n = typeof Symbol == "function" && Symbol.for, e = n ? Symbol.for("react.element") : 60103, t = n ? Symbol.for("react.portal") : 60106, r = n ? Symbol.for("react.fragment") : 60107, s = n ? Symbol.for("react.strict_mode") : 60108, a = n ? Symbol.for("react.profiler") : 60114, o = n ? Symbol.for("react.provider") : 60109, i = n ? Symbol.for("react.context") : 60110, l = n ? Symbol.for("react.async_mode") : 60111, c = n ? Symbol.for("react.concurrent_mode") : 60111, f = n ? Symbol.for("react.forward_ref") : 60112, u = n ? Symbol.for("react.suspense") : 60113, d = n ? Symbol.for("react.suspense_list") : 60120, g = n ? Symbol.for("react.memo") : 60115, p = n ? Symbol.for("react.lazy") : 60116, w = n ? Symbol.for("react.block") : 60121, S = n ? Symbol.for("react.fundamental") : 60117, E = n ? Symbol.for("react.responder") : 60118, b = n ? Symbol.for("react.scope") : 60119;
|
|
619
|
+
function T(y) {
|
|
620
|
+
if (typeof y == "object" && y !== null) {
|
|
621
|
+
var k = y.$$typeof;
|
|
622
622
|
switch (k) {
|
|
623
623
|
case e:
|
|
624
|
-
switch (
|
|
624
|
+
switch (y = y.type, y) {
|
|
625
625
|
case l:
|
|
626
626
|
case c:
|
|
627
627
|
case r:
|
|
628
628
|
case a:
|
|
629
629
|
case s:
|
|
630
630
|
case u:
|
|
631
|
-
return
|
|
631
|
+
return y;
|
|
632
632
|
default:
|
|
633
|
-
switch (
|
|
633
|
+
switch (y = y && y.$$typeof, y) {
|
|
634
634
|
case i:
|
|
635
|
-
case
|
|
635
|
+
case f:
|
|
636
636
|
case p:
|
|
637
|
-
case
|
|
637
|
+
case g:
|
|
638
638
|
case o:
|
|
639
|
-
return
|
|
639
|
+
return y;
|
|
640
640
|
default:
|
|
641
641
|
return k;
|
|
642
642
|
}
|
|
@@ -646,35 +646,35 @@ function sr() {
|
|
|
646
646
|
}
|
|
647
647
|
}
|
|
648
648
|
}
|
|
649
|
-
function v(
|
|
650
|
-
return T(
|
|
651
|
-
}
|
|
652
|
-
return Q.AsyncMode = l, Q.ConcurrentMode = c, Q.ContextConsumer = i, Q.ContextProvider = o, Q.Element = e, Q.ForwardRef =
|
|
653
|
-
return v(
|
|
654
|
-
}, Q.isConcurrentMode = v, Q.isContextConsumer = function(
|
|
655
|
-
return T(
|
|
656
|
-
}, Q.isContextProvider = function(
|
|
657
|
-
return T(
|
|
658
|
-
}, Q.isElement = function(
|
|
659
|
-
return typeof
|
|
660
|
-
}, Q.isForwardRef = function(
|
|
661
|
-
return T(
|
|
662
|
-
}, Q.isFragment = function(
|
|
663
|
-
return T(
|
|
664
|
-
}, Q.isLazy = function(
|
|
665
|
-
return T(
|
|
666
|
-
}, Q.isMemo = function(
|
|
667
|
-
return T(
|
|
668
|
-
}, Q.isPortal = function(
|
|
669
|
-
return T(
|
|
670
|
-
}, Q.isProfiler = function(
|
|
671
|
-
return T(
|
|
672
|
-
}, Q.isStrictMode = function(
|
|
673
|
-
return T(
|
|
674
|
-
}, Q.isSuspense = function(
|
|
675
|
-
return T(
|
|
676
|
-
}, Q.isValidElementType = function(
|
|
677
|
-
return typeof
|
|
649
|
+
function v(y) {
|
|
650
|
+
return T(y) === c;
|
|
651
|
+
}
|
|
652
|
+
return Q.AsyncMode = l, Q.ConcurrentMode = c, Q.ContextConsumer = i, Q.ContextProvider = o, Q.Element = e, Q.ForwardRef = f, Q.Fragment = r, Q.Lazy = p, Q.Memo = g, Q.Portal = t, Q.Profiler = a, Q.StrictMode = s, Q.Suspense = u, Q.isAsyncMode = function(y) {
|
|
653
|
+
return v(y) || T(y) === l;
|
|
654
|
+
}, Q.isConcurrentMode = v, Q.isContextConsumer = function(y) {
|
|
655
|
+
return T(y) === i;
|
|
656
|
+
}, Q.isContextProvider = function(y) {
|
|
657
|
+
return T(y) === o;
|
|
658
|
+
}, Q.isElement = function(y) {
|
|
659
|
+
return typeof y == "object" && y !== null && y.$$typeof === e;
|
|
660
|
+
}, Q.isForwardRef = function(y) {
|
|
661
|
+
return T(y) === f;
|
|
662
|
+
}, Q.isFragment = function(y) {
|
|
663
|
+
return T(y) === r;
|
|
664
|
+
}, Q.isLazy = function(y) {
|
|
665
|
+
return T(y) === p;
|
|
666
|
+
}, Q.isMemo = function(y) {
|
|
667
|
+
return T(y) === g;
|
|
668
|
+
}, Q.isPortal = function(y) {
|
|
669
|
+
return T(y) === t;
|
|
670
|
+
}, Q.isProfiler = function(y) {
|
|
671
|
+
return T(y) === a;
|
|
672
|
+
}, Q.isStrictMode = function(y) {
|
|
673
|
+
return T(y) === s;
|
|
674
|
+
}, Q.isSuspense = function(y) {
|
|
675
|
+
return T(y) === u;
|
|
676
|
+
}, Q.isValidElementType = function(y) {
|
|
677
|
+
return typeof y == "string" || typeof y == "function" || y === r || y === c || y === a || y === s || y === u || y === d || typeof y == "object" && y !== null && (y.$$typeof === p || y.$$typeof === g || y.$$typeof === o || y.$$typeof === i || y.$$typeof === f || y.$$typeof === S || y.$$typeof === E || y.$$typeof === b || y.$$typeof === w);
|
|
678
678
|
}, Q.typeOf = T, Q;
|
|
679
679
|
}
|
|
680
680
|
var ee = {};
|
|
@@ -689,10 +689,10 @@ var ee = {};
|
|
|
689
689
|
var Kt;
|
|
690
690
|
function ar() {
|
|
691
691
|
return Kt || (Kt = 1, process.env.NODE_ENV !== "production" && function() {
|
|
692
|
-
var n = typeof Symbol == "function" && Symbol.for, e = n ? Symbol.for("react.element") : 60103, t = n ? Symbol.for("react.portal") : 60106, r = n ? Symbol.for("react.fragment") : 60107, s = n ? Symbol.for("react.strict_mode") : 60108, a = n ? Symbol.for("react.profiler") : 60114, o = n ? Symbol.for("react.provider") : 60109, i = n ? Symbol.for("react.context") : 60110, l = n ? Symbol.for("react.async_mode") : 60111, c = n ? Symbol.for("react.concurrent_mode") : 60111,
|
|
692
|
+
var n = typeof Symbol == "function" && Symbol.for, e = n ? Symbol.for("react.element") : 60103, t = n ? Symbol.for("react.portal") : 60106, r = n ? Symbol.for("react.fragment") : 60107, s = n ? Symbol.for("react.strict_mode") : 60108, a = n ? Symbol.for("react.profiler") : 60114, o = n ? Symbol.for("react.provider") : 60109, i = n ? Symbol.for("react.context") : 60110, l = n ? Symbol.for("react.async_mode") : 60111, c = n ? Symbol.for("react.concurrent_mode") : 60111, f = n ? Symbol.for("react.forward_ref") : 60112, u = n ? Symbol.for("react.suspense") : 60113, d = n ? Symbol.for("react.suspense_list") : 60120, g = n ? Symbol.for("react.memo") : 60115, p = n ? Symbol.for("react.lazy") : 60116, w = n ? Symbol.for("react.block") : 60121, S = n ? Symbol.for("react.fundamental") : 60117, E = n ? Symbol.for("react.responder") : 60118, b = n ? Symbol.for("react.scope") : 60119;
|
|
693
693
|
function T(M) {
|
|
694
694
|
return typeof M == "string" || typeof M == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.
|
|
695
|
-
M === r || M === c || M === a || M === s || M === u || M ===
|
|
695
|
+
M === r || M === c || M === a || M === s || M === u || M === d || typeof M == "object" && M !== null && (M.$$typeof === p || M.$$typeof === g || M.$$typeof === o || M.$$typeof === i || M.$$typeof === f || M.$$typeof === S || M.$$typeof === E || M.$$typeof === b || M.$$typeof === w);
|
|
696
696
|
}
|
|
697
697
|
function v(M) {
|
|
698
698
|
if (typeof M == "object" && M !== null) {
|
|
@@ -712,9 +712,9 @@ function ar() {
|
|
|
712
712
|
var re = Z && Z.$$typeof;
|
|
713
713
|
switch (re) {
|
|
714
714
|
case i:
|
|
715
|
-
case
|
|
715
|
+
case f:
|
|
716
716
|
case p:
|
|
717
|
-
case
|
|
717
|
+
case g:
|
|
718
718
|
case o:
|
|
719
719
|
return re;
|
|
720
720
|
default:
|
|
@@ -726,7 +726,7 @@ function ar() {
|
|
|
726
726
|
}
|
|
727
727
|
}
|
|
728
728
|
}
|
|
729
|
-
var
|
|
729
|
+
var y = l, k = c, A = i, O = o, L = e, R = f, D = r, C = p, P = g, N = t, B = a, H = s, z = u, X = !1;
|
|
730
730
|
function F(M) {
|
|
731
731
|
return X || (X = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), h(M) || v(M) === l;
|
|
732
732
|
}
|
|
@@ -743,7 +743,7 @@ function ar() {
|
|
|
743
743
|
return typeof M == "object" && M !== null && M.$$typeof === e;
|
|
744
744
|
}
|
|
745
745
|
function j(M) {
|
|
746
|
-
return v(M) ===
|
|
746
|
+
return v(M) === f;
|
|
747
747
|
}
|
|
748
748
|
function I(M) {
|
|
749
749
|
return v(M) === r;
|
|
@@ -752,7 +752,7 @@ function ar() {
|
|
|
752
752
|
return v(M) === p;
|
|
753
753
|
}
|
|
754
754
|
function W(M) {
|
|
755
|
-
return v(M) ===
|
|
755
|
+
return v(M) === g;
|
|
756
756
|
}
|
|
757
757
|
function V(M) {
|
|
758
758
|
return v(M) === t;
|
|
@@ -766,7 +766,7 @@ function ar() {
|
|
|
766
766
|
function se(M) {
|
|
767
767
|
return v(M) === u;
|
|
768
768
|
}
|
|
769
|
-
ee.AsyncMode =
|
|
769
|
+
ee.AsyncMode = y, ee.ConcurrentMode = k, ee.ContextConsumer = A, ee.ContextProvider = O, ee.Element = L, ee.ForwardRef = R, ee.Fragment = D, ee.Lazy = C, ee.Memo = P, ee.Portal = N, ee.Profiler = B, ee.StrictMode = H, ee.Suspense = z, ee.isAsyncMode = F, ee.isConcurrentMode = h, ee.isContextConsumer = x, ee.isContextProvider = $, ee.isElement = _, ee.isForwardRef = j, ee.isFragment = I, ee.isLazy = U, ee.isMemo = W, ee.isPortal = V, ee.isProfiler = J, ee.isStrictMode = q, ee.isSuspense = se, ee.isValidElementType = T, ee.typeOf = v;
|
|
770
770
|
}()), ee;
|
|
771
771
|
}
|
|
772
772
|
var zt;
|
|
@@ -797,28 +797,28 @@ function or() {
|
|
|
797
797
|
return !1;
|
|
798
798
|
for (var o = {}, i = 0; i < 10; i++)
|
|
799
799
|
o["_" + String.fromCharCode(i)] = i;
|
|
800
|
-
var l = Object.getOwnPropertyNames(o).map(function(
|
|
801
|
-
return o[
|
|
800
|
+
var l = Object.getOwnPropertyNames(o).map(function(f) {
|
|
801
|
+
return o[f];
|
|
802
802
|
});
|
|
803
803
|
if (l.join("") !== "0123456789")
|
|
804
804
|
return !1;
|
|
805
805
|
var c = {};
|
|
806
|
-
return "abcdefghijklmnopqrst".split("").forEach(function(
|
|
807
|
-
c[
|
|
806
|
+
return "abcdefghijklmnopqrst".split("").forEach(function(f) {
|
|
807
|
+
c[f] = f;
|
|
808
808
|
}), Object.keys(Object.assign({}, c)).join("") === "abcdefghijklmnopqrst";
|
|
809
809
|
} catch {
|
|
810
810
|
return !1;
|
|
811
811
|
}
|
|
812
812
|
}
|
|
813
813
|
return bt = s() ? Object.assign : function(a, o) {
|
|
814
|
-
for (var i, l = r(a), c,
|
|
815
|
-
i = Object(arguments[
|
|
814
|
+
for (var i, l = r(a), c, f = 1; f < arguments.length; f++) {
|
|
815
|
+
i = Object(arguments[f]);
|
|
816
816
|
for (var u in i)
|
|
817
817
|
e.call(i, u) && (l[u] = i[u]);
|
|
818
818
|
if (n) {
|
|
819
819
|
c = n(i);
|
|
820
|
-
for (var
|
|
821
|
-
t.call(i, c[
|
|
820
|
+
for (var d = 0; d < c.length; d++)
|
|
821
|
+
t.call(i, c[d]) && (l[c[d]] = i[c[d]]);
|
|
822
822
|
}
|
|
823
823
|
}
|
|
824
824
|
return l;
|
|
@@ -854,27 +854,27 @@ function ir() {
|
|
|
854
854
|
}
|
|
855
855
|
function s(a, o, i, l, c) {
|
|
856
856
|
if (process.env.NODE_ENV !== "production") {
|
|
857
|
-
for (var
|
|
858
|
-
if (r(a,
|
|
857
|
+
for (var f in a)
|
|
858
|
+
if (r(a, f)) {
|
|
859
859
|
var u;
|
|
860
860
|
try {
|
|
861
|
-
if (typeof a[
|
|
862
|
-
var
|
|
863
|
-
(l || "React class") + ": " + i + " type `" +
|
|
861
|
+
if (typeof a[f] != "function") {
|
|
862
|
+
var d = Error(
|
|
863
|
+
(l || "React class") + ": " + i + " type `" + f + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof a[f] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`."
|
|
864
864
|
);
|
|
865
|
-
throw
|
|
865
|
+
throw d.name = "Invariant Violation", d;
|
|
866
866
|
}
|
|
867
|
-
u = a[
|
|
867
|
+
u = a[f](o, f, l, i, null, e);
|
|
868
868
|
} catch (p) {
|
|
869
869
|
u = p;
|
|
870
870
|
}
|
|
871
871
|
if (u && !(u instanceof Error) && n(
|
|
872
|
-
(l || "React class") + ": type specification of " + i + " `" +
|
|
872
|
+
(l || "React class") + ": type specification of " + i + " `" + f + "` is invalid; the type checker function must return `null` or an `Error` but returned a " + typeof u + ". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."
|
|
873
873
|
), u instanceof Error && !(u.message in t)) {
|
|
874
874
|
t[u.message] = !0;
|
|
875
|
-
var
|
|
875
|
+
var g = c ? c() : "";
|
|
876
876
|
n(
|
|
877
|
-
"Failed " + i + " type: " + u.message + (
|
|
877
|
+
"Failed " + i + " type: " + u.message + (g ?? "")
|
|
878
878
|
);
|
|
879
879
|
}
|
|
880
880
|
}
|
|
@@ -902,13 +902,13 @@ function lr() {
|
|
|
902
902
|
return null;
|
|
903
903
|
}
|
|
904
904
|
return St = function(i, l) {
|
|
905
|
-
var c = typeof Symbol == "function" && Symbol.iterator,
|
|
905
|
+
var c = typeof Symbol == "function" && Symbol.iterator, f = "@@iterator";
|
|
906
906
|
function u(h) {
|
|
907
|
-
var x = h && (c && h[c] || h[
|
|
907
|
+
var x = h && (c && h[c] || h[f]);
|
|
908
908
|
if (typeof x == "function")
|
|
909
909
|
return x;
|
|
910
910
|
}
|
|
911
|
-
var
|
|
911
|
+
var d = "<<anonymous>>", g = {
|
|
912
912
|
array: E("array"),
|
|
913
913
|
bigint: E("bigint"),
|
|
914
914
|
bool: E("boolean"),
|
|
@@ -920,7 +920,7 @@ function lr() {
|
|
|
920
920
|
any: b(),
|
|
921
921
|
arrayOf: T,
|
|
922
922
|
element: v(),
|
|
923
|
-
elementType:
|
|
923
|
+
elementType: y(),
|
|
924
924
|
instanceOf: k,
|
|
925
925
|
node: R(),
|
|
926
926
|
objectOf: O,
|
|
@@ -940,7 +940,7 @@ function lr() {
|
|
|
940
940
|
if (process.env.NODE_ENV !== "production")
|
|
941
941
|
var x = {}, $ = 0;
|
|
942
942
|
function _(I, U, W, V, J, q, se) {
|
|
943
|
-
if (V = V ||
|
|
943
|
+
if (V = V || d, q = q || W, se !== t) {
|
|
944
944
|
if (l) {
|
|
945
945
|
var M = new Error(
|
|
946
946
|
"Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types"
|
|
@@ -1005,7 +1005,7 @@ function lr() {
|
|
|
1005
1005
|
}
|
|
1006
1006
|
return S(h);
|
|
1007
1007
|
}
|
|
1008
|
-
function
|
|
1008
|
+
function y() {
|
|
1009
1009
|
function h(x, $, _, j, I) {
|
|
1010
1010
|
var U = x[$];
|
|
1011
1011
|
if (!n.isValidElementType(U)) {
|
|
@@ -1019,7 +1019,7 @@ function lr() {
|
|
|
1019
1019
|
function k(h) {
|
|
1020
1020
|
function x($, _, j, I, U) {
|
|
1021
1021
|
if (!($[_] instanceof h)) {
|
|
1022
|
-
var W = h.name ||
|
|
1022
|
+
var W = h.name || d, V = F($[_]);
|
|
1023
1023
|
return new w("Invalid " + I + " `" + U + "` of type " + ("`" + V + "` supplied to `" + j + "`, expected ") + ("instance of `" + W + "`."));
|
|
1024
1024
|
}
|
|
1025
1025
|
return null;
|
|
@@ -1200,9 +1200,9 @@ Valid keys: ` + JSON.stringify(Object.keys(h), null, " ")
|
|
|
1200
1200
|
}
|
|
1201
1201
|
}
|
|
1202
1202
|
function F(h) {
|
|
1203
|
-
return !h.constructor || !h.constructor.name ?
|
|
1203
|
+
return !h.constructor || !h.constructor.name ? d : h.constructor.name;
|
|
1204
1204
|
}
|
|
1205
|
-
return
|
|
1205
|
+
return g.checkPropTypes = s, g.resetWarningCache = s.resetWarningCache, g.PropTypes = g, g;
|
|
1206
1206
|
}, St;
|
|
1207
1207
|
}
|
|
1208
1208
|
var Et, tn;
|
|
@@ -1215,12 +1215,12 @@ function cr() {
|
|
|
1215
1215
|
function t() {
|
|
1216
1216
|
}
|
|
1217
1217
|
return t.resetWarningCache = e, Et = function() {
|
|
1218
|
-
function r(o, i, l, c,
|
|
1218
|
+
function r(o, i, l, c, f, u) {
|
|
1219
1219
|
if (u !== n) {
|
|
1220
|
-
var
|
|
1220
|
+
var d = new Error(
|
|
1221
1221
|
"Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types"
|
|
1222
1222
|
);
|
|
1223
|
-
throw
|
|
1223
|
+
throw d.name = "Invariant Violation", d;
|
|
1224
1224
|
}
|
|
1225
1225
|
}
|
|
1226
1226
|
r.isRequired = r;
|
|
@@ -1263,10 +1263,10 @@ function ur() {
|
|
|
1263
1263
|
ze.exports = /* @__PURE__ */ cr()();
|
|
1264
1264
|
return ze.exports;
|
|
1265
1265
|
}
|
|
1266
|
-
var ie = /* @__PURE__ */ ur(),
|
|
1266
|
+
var ie = /* @__PURE__ */ ur(), fr = function(e) {
|
|
1267
1267
|
var t = e?.ownerDocument || document;
|
|
1268
1268
|
return t.defaultView || window;
|
|
1269
|
-
},
|
|
1269
|
+
}, dr = function(e, t) {
|
|
1270
1270
|
for (var r in e)
|
|
1271
1271
|
if (!(r in t))
|
|
1272
1272
|
return !0;
|
|
@@ -1289,12 +1289,12 @@ var ie = /* @__PURE__ */ ur(), dr = function(e) {
|
|
|
1289
1289
|
var t = e.prototype;
|
|
1290
1290
|
return t.renderSVG = function() {
|
|
1291
1291
|
var s = this;
|
|
1292
|
-
if (this.reactWrapper instanceof
|
|
1293
|
-
var a = this.props, o = a.desc, i = a.evalScripts, l = a.httpRequestWithCredentials, c = a.renumerateIRIElements,
|
|
1294
|
-
S === "svg" ? (E = document.createElementNS(Xe, S), E.setAttribute("xmlns", Xe), E.setAttribute("xmlns:xlink", rn), b = document.createElementNS(Xe, S)) : (E = document.createElement(S), b = document.createElement(S)), E.appendChild(b), b.dataset.src =
|
|
1292
|
+
if (this.reactWrapper instanceof fr(this.reactWrapper).Node) {
|
|
1293
|
+
var a = this.props, o = a.desc, i = a.evalScripts, l = a.httpRequestWithCredentials, c = a.renumerateIRIElements, f = a.src, u = a.title, d = a.useRequestCache, g = this.props.onError, p = this.props.beforeInjection, w = this.props.afterInjection, S = this.props.wrapper, E, b;
|
|
1294
|
+
S === "svg" ? (E = document.createElementNS(Xe, S), E.setAttribute("xmlns", Xe), E.setAttribute("xmlns:xlink", rn), b = document.createElementNS(Xe, S)) : (E = document.createElement(S), b = document.createElement(S)), E.appendChild(b), b.dataset.src = f, this.nonReactWrapper = this.reactWrapper.appendChild(E);
|
|
1295
1295
|
var T = function(A) {
|
|
1296
1296
|
if (s.removeSVG(), !s._isMounted) {
|
|
1297
|
-
|
|
1297
|
+
g(A);
|
|
1298
1298
|
return;
|
|
1299
1299
|
}
|
|
1300
1300
|
s.setState(function() {
|
|
@@ -1303,7 +1303,7 @@ var ie = /* @__PURE__ */ ur(), dr = function(e) {
|
|
|
1303
1303
|
isLoading: !1
|
|
1304
1304
|
};
|
|
1305
1305
|
}, function() {
|
|
1306
|
-
|
|
1306
|
+
g(A);
|
|
1307
1307
|
});
|
|
1308
1308
|
}, v = function(A, O) {
|
|
1309
1309
|
if (A) {
|
|
@@ -1321,7 +1321,7 @@ var ie = /* @__PURE__ */ ur(), dr = function(e) {
|
|
|
1321
1321
|
T(L);
|
|
1322
1322
|
}
|
|
1323
1323
|
});
|
|
1324
|
-
},
|
|
1324
|
+
}, y = function(A) {
|
|
1325
1325
|
if (A.setAttribute("role", "img"), o) {
|
|
1326
1326
|
var O = A.querySelector(":scope > desc");
|
|
1327
1327
|
O && A.removeChild(O);
|
|
@@ -1342,8 +1342,8 @@ var ie = /* @__PURE__ */ ur(), dr = function(e) {
|
|
|
1342
1342
|
};
|
|
1343
1343
|
rr(b, {
|
|
1344
1344
|
afterEach: v,
|
|
1345
|
-
beforeEach:
|
|
1346
|
-
cacheRequests:
|
|
1345
|
+
beforeEach: y,
|
|
1346
|
+
cacheRequests: d,
|
|
1347
1347
|
evalScripts: i,
|
|
1348
1348
|
httpRequestWithCredentials: l,
|
|
1349
1349
|
renumerateIRIElements: c
|
|
@@ -1356,7 +1356,7 @@ var ie = /* @__PURE__ */ ur(), dr = function(e) {
|
|
|
1356
1356
|
this._isMounted = !0, this.renderSVG();
|
|
1357
1357
|
}, t.componentDidUpdate = function(s) {
|
|
1358
1358
|
var a = this;
|
|
1359
|
-
|
|
1359
|
+
dr(st({}, s), this.props) && this.setState(function() {
|
|
1360
1360
|
return a.initialState;
|
|
1361
1361
|
}, function() {
|
|
1362
1362
|
a.removeSVG(), a.renderSVG();
|
|
@@ -1420,7 +1420,7 @@ const ta = (n) => {
|
|
|
1420
1420
|
}, hr = (n) => {
|
|
1421
1421
|
const e = `${Ot.assets}/${n}`.replace(/\/+/g, "/");
|
|
1422
1422
|
return e.endsWith(".svg") ? e : e + ".svg";
|
|
1423
|
-
},
|
|
1423
|
+
}, fe = rt.memo(
|
|
1424
1424
|
({
|
|
1425
1425
|
icon: n,
|
|
1426
1426
|
width: e,
|
|
@@ -1432,19 +1432,19 @@ const ta = (n) => {
|
|
|
1432
1432
|
rotated: i = !1,
|
|
1433
1433
|
onClick: l,
|
|
1434
1434
|
isInteractable: c = !1,
|
|
1435
|
-
spin:
|
|
1435
|
+
spin: f = !1,
|
|
1436
1436
|
title: u,
|
|
1437
|
-
tabIndex:
|
|
1437
|
+
tabIndex: d
|
|
1438
1438
|
}) => {
|
|
1439
|
-
const [
|
|
1439
|
+
const [g, p] = G(!1), w = (R) => R?.toLowerCase().endsWith(".svg") || !R?.includes("/"), S = (R) => R?.startsWith("http") || R?.startsWith("/"), E = {
|
|
1440
1440
|
img: `${c ? "smp-image-interactable" : ""}`,
|
|
1441
|
-
svg: `smp-icon ${o ? `smp-icon-${o}` : ""} ${i ? "smp-icon-rotated" : ""} ${c ? "smp-icon-interactable" : ""} ${
|
|
1441
|
+
svg: `smp-icon ${o ? `smp-icon-${o}` : ""} ${i ? "smp-icon-rotated" : ""} ${c ? "smp-icon-interactable" : ""} ${f ? "smp-icon-spin" : ""}`
|
|
1442
1442
|
}, b = (R) => {
|
|
1443
1443
|
!a && c && l && l(R);
|
|
1444
1444
|
}, T = (R) => {
|
|
1445
1445
|
!a && c && (R.key === "Enter" || R.key === " ") && (R.preventDefault(), b(R));
|
|
1446
|
-
}, v =
|
|
1447
|
-
return
|
|
1446
|
+
}, v = g ? r : n, y = w(v), A = S(v) ? v : hr(`assets/svg/${v}`);
|
|
1447
|
+
return y ? /* @__PURE__ */ m.jsx(
|
|
1448
1448
|
kt,
|
|
1449
1449
|
{
|
|
1450
1450
|
src: A,
|
|
@@ -1459,7 +1459,7 @@ const ta = (n) => {
|
|
|
1459
1459
|
className: E.svg,
|
|
1460
1460
|
onClick: b,
|
|
1461
1461
|
onKeyDown: T,
|
|
1462
|
-
tabIndex:
|
|
1462
|
+
tabIndex: d
|
|
1463
1463
|
}
|
|
1464
1464
|
) : /* eslint-disable-next-line jsx-a11y/no-noninteractive-element-interactions */ /* @__PURE__ */ m.jsx(
|
|
1465
1465
|
"img",
|
|
@@ -1499,10 +1499,10 @@ const ta = (n) => {
|
|
|
1499
1499
|
variant: i = "primary",
|
|
1500
1500
|
appearance: l = "raised",
|
|
1501
1501
|
showIcon: c = !0,
|
|
1502
|
-
showText:
|
|
1502
|
+
showText: f = !0,
|
|
1503
1503
|
fullWidth: u = !1,
|
|
1504
|
-
loading:
|
|
1505
|
-
justify:
|
|
1504
|
+
loading: d = !1,
|
|
1505
|
+
justify: g = "center",
|
|
1506
1506
|
title: p,
|
|
1507
1507
|
optionalDisplayValue: w,
|
|
1508
1508
|
squared: S = !1,
|
|
@@ -1511,7 +1511,7 @@ const ta = (n) => {
|
|
|
1511
1511
|
buttonExt: T
|
|
1512
1512
|
}) => {
|
|
1513
1513
|
const v = {
|
|
1514
|
-
container: `smp-button smp-button-container ${o ? `smp-button-${o}` : ""} ${i ? `smp-buttonVariant-${i}` : ""} ${l ? `smp-buttonType-${l}` : ""} ${u ? "smp-button-fullWidth" : ""} smp-justifyContent-${
|
|
1514
|
+
container: `smp-button smp-button-container ${o ? `smp-button-${o}` : ""} ${i ? `smp-buttonVariant-${i}` : ""} ${l ? `smp-buttonType-${l}` : ""} ${u ? "smp-button-fullWidth" : ""} smp-justifyContent-${g} ${S && !f ? "smp-button-squared" : ""} ${b ? "smp-buttonActive" : ""} ${T ? `smp-buttonExt-${T}` : ""}`
|
|
1515
1515
|
};
|
|
1516
1516
|
return /* @__PURE__ */ m.jsx(
|
|
1517
1517
|
"button",
|
|
@@ -1522,11 +1522,11 @@ const ta = (n) => {
|
|
|
1522
1522
|
onClick: e,
|
|
1523
1523
|
"aria-label": t,
|
|
1524
1524
|
disabled: a,
|
|
1525
|
-
"aria-busy":
|
|
1525
|
+
"aria-busy": d,
|
|
1526
1526
|
title: p || w,
|
|
1527
|
-
children:
|
|
1527
|
+
children: d ? /* @__PURE__ */ m.jsx(fe, { icon: "spinner", state: an(i), spin: !0 }) : /* @__PURE__ */ m.jsxs(m.Fragment, { children: [
|
|
1528
1528
|
r && c && /* @__PURE__ */ m.jsx(
|
|
1529
|
-
|
|
1529
|
+
fe,
|
|
1530
1530
|
{
|
|
1531
1531
|
icon: r,
|
|
1532
1532
|
placeholderIcon: s,
|
|
@@ -1536,7 +1536,7 @@ const ta = (n) => {
|
|
|
1536
1536
|
height: sn(o)
|
|
1537
1537
|
}
|
|
1538
1538
|
),
|
|
1539
|
-
|
|
1539
|
+
f && /* @__PURE__ */ m.jsx("span", { children: w || n })
|
|
1540
1540
|
] })
|
|
1541
1541
|
}
|
|
1542
1542
|
);
|
|
@@ -1586,7 +1586,7 @@ const ta = (n) => {
|
|
|
1586
1586
|
selectedIndex: r,
|
|
1587
1587
|
onTabChange: s
|
|
1588
1588
|
}) => {
|
|
1589
|
-
const [a, o] = G(r ?? 0), [i, l] = G(!1), [c,
|
|
1589
|
+
const [a, o] = G(r ?? 0), [i, l] = G(!1), [c, f] = G(!1), u = le(null);
|
|
1590
1590
|
if (ne(() => {
|
|
1591
1591
|
const b = u.current;
|
|
1592
1592
|
if (!b) return;
|
|
@@ -1599,7 +1599,7 @@ const ta = (n) => {
|
|
|
1599
1599
|
r !== void 0 && o(r);
|
|
1600
1600
|
}, [r]), !n.children || n.children.length === 0)
|
|
1601
1601
|
return /* @__PURE__ */ m.jsx("div", { className: "tab-bar-empty", children: "No tabs available" });
|
|
1602
|
-
const
|
|
1602
|
+
const d = {
|
|
1603
1603
|
container: be["smp-tabbar-container"],
|
|
1604
1604
|
listWrapper: be["smp-tabbar-list-wrapper"],
|
|
1605
1605
|
list: be["smp-tabbar-list"],
|
|
@@ -1607,24 +1607,24 @@ const ta = (n) => {
|
|
|
1607
1607
|
scrollButtonRight: `${be["smp-tabbar-scroll-button"]} ${be["smp-tabbar-scroll-buttonRight"]}`,
|
|
1608
1608
|
scrollButtonLeft: `${be["smp-tabbar-scroll-button"]} ${be["smp-tabbar-scroll-buttonLeft"]}`,
|
|
1609
1609
|
active: be["smp-active"]
|
|
1610
|
-
},
|
|
1610
|
+
}, g = 100, p = 2, w = () => {
|
|
1611
1611
|
const b = u.current;
|
|
1612
|
-
b && (l(b.scrollLeft > 0),
|
|
1612
|
+
b && (l(b.scrollLeft > 0), f(
|
|
1613
1613
|
b.scrollLeft + b.clientWidth < b.scrollWidth - p
|
|
1614
1614
|
));
|
|
1615
1615
|
}, S = () => {
|
|
1616
|
-
u.current?.scrollBy({ left: -
|
|
1616
|
+
u.current?.scrollBy({ left: -g, behavior: "smooth" });
|
|
1617
1617
|
}, E = () => {
|
|
1618
|
-
u.current?.scrollBy({ left:
|
|
1618
|
+
u.current?.scrollBy({ left: g, behavior: "smooth" });
|
|
1619
1619
|
};
|
|
1620
1620
|
return /* @__PURE__ */ m.jsxs(
|
|
1621
1621
|
"div",
|
|
1622
1622
|
{
|
|
1623
|
-
className:
|
|
1623
|
+
className: d.container,
|
|
1624
1624
|
role: "tabpanel",
|
|
1625
1625
|
"data-component": "tab-bar",
|
|
1626
1626
|
children: [
|
|
1627
|
-
i && /* @__PURE__ */ m.jsx("div", { className:
|
|
1627
|
+
i && /* @__PURE__ */ m.jsx("div", { className: d.scrollButtonLeft, children: /* @__PURE__ */ m.jsx(
|
|
1628
1628
|
we,
|
|
1629
1629
|
{
|
|
1630
1630
|
bindValue: "",
|
|
@@ -1634,11 +1634,11 @@ const ta = (n) => {
|
|
|
1634
1634
|
sizing: e
|
|
1635
1635
|
}
|
|
1636
1636
|
) }),
|
|
1637
|
-
/* @__PURE__ */ m.jsx("div", { className:
|
|
1637
|
+
/* @__PURE__ */ m.jsx("div", { className: d.listWrapper, children: /* @__PURE__ */ m.jsx("div", { className: d.list, ref: u, role: "tablist", children: n.children.map((b, T) => /* @__PURE__ */ m.jsxs(
|
|
1638
1638
|
"button",
|
|
1639
1639
|
{
|
|
1640
1640
|
type: "button",
|
|
1641
|
-
className: `${T === a ?
|
|
1641
|
+
className: `${T === a ? d.active : ""} ${d.tab} `,
|
|
1642
1642
|
role: "tab",
|
|
1643
1643
|
"aria-selected": T === a,
|
|
1644
1644
|
tabIndex: T === a ? 0 : -1,
|
|
@@ -1647,7 +1647,7 @@ const ta = (n) => {
|
|
|
1647
1647
|
},
|
|
1648
1648
|
children: [
|
|
1649
1649
|
b.icon && /* @__PURE__ */ m.jsx(
|
|
1650
|
-
|
|
1650
|
+
fe,
|
|
1651
1651
|
{
|
|
1652
1652
|
icon: b.icon,
|
|
1653
1653
|
placeholderIcon: b.placeholderIcon
|
|
@@ -1661,7 +1661,7 @@ const ta = (n) => {
|
|
|
1661
1661
|
}
|
|
1662
1662
|
),
|
|
1663
1663
|
t && (a === T ? /* @__PURE__ */ m.jsx(
|
|
1664
|
-
|
|
1664
|
+
fe,
|
|
1665
1665
|
{
|
|
1666
1666
|
icon: "more_vert",
|
|
1667
1667
|
isInteractable: !0,
|
|
@@ -1674,7 +1674,7 @@ const ta = (n) => {
|
|
|
1674
1674
|
},
|
|
1675
1675
|
T
|
|
1676
1676
|
)) }) }),
|
|
1677
|
-
c && /* @__PURE__ */ m.jsx("div", { className:
|
|
1677
|
+
c && /* @__PURE__ */ m.jsx("div", { className: d.scrollButtonRight, children: /* @__PURE__ */ m.jsx(
|
|
1678
1678
|
we,
|
|
1679
1679
|
{
|
|
1680
1680
|
bindValue: "",
|
|
@@ -1731,21 +1731,21 @@ const ta = (n) => {
|
|
|
1731
1731
|
styles: T
|
|
1732
1732
|
}
|
|
1733
1733
|
};
|
|
1734
|
-
}, {}), c = l(i),
|
|
1734
|
+
}, {}), c = l(i), f = `${pe["smp-layout"]} ${e.horizontal ? pe["smp-layout-horizontal"] : pe["smp-layout-vertical"]} ${e.inline ? pe["smp-layout-inline"] : ""}`;
|
|
1735
1735
|
let u = {};
|
|
1736
1736
|
(e.horizontal || Ut(e.sections || [])) && (u = Vt(
|
|
1737
1737
|
i,
|
|
1738
1738
|
e.horizontal ? a : o
|
|
1739
1739
|
));
|
|
1740
|
-
const
|
|
1740
|
+
const d = (p, w) => {
|
|
1741
1741
|
const S = /* @__PURE__ */ m.jsx(
|
|
1742
1742
|
"div",
|
|
1743
1743
|
{
|
|
1744
1744
|
"smp-id": `section-${p.id}`,
|
|
1745
1745
|
className: c[p.id].classes,
|
|
1746
1746
|
style: c[p.id].styles,
|
|
1747
|
-
children: p.sections?.length ? p.sections.map((E) =>
|
|
1748
|
-
(E) =>
|
|
1747
|
+
children: p.sections?.length ? p.sections.map((E) => d(E)) : p.content?.map(
|
|
1748
|
+
(E) => g(E, p.justify, p.align)
|
|
1749
1749
|
)
|
|
1750
1750
|
},
|
|
1751
1751
|
`section-${p.id}`
|
|
@@ -1767,7 +1767,7 @@ const ta = (n) => {
|
|
|
1767
1767
|
},
|
|
1768
1768
|
`title-section-${p.id}`
|
|
1769
1769
|
) : S;
|
|
1770
|
-
},
|
|
1770
|
+
}, g = (p, w, S) => {
|
|
1771
1771
|
const E = s[p.id];
|
|
1772
1772
|
if (!E) return null;
|
|
1773
1773
|
const T = {
|
|
@@ -1785,7 +1785,7 @@ const ta = (n) => {
|
|
|
1785
1785
|
p.id
|
|
1786
1786
|
);
|
|
1787
1787
|
};
|
|
1788
|
-
return /* @__PURE__ */ m.jsxs("div", { className:
|
|
1788
|
+
return /* @__PURE__ */ m.jsxs("div", { className: f, style: u, "smp-id": "layout", children: [
|
|
1789
1789
|
e.sectionsType === "tab" && e.sections && e?.sections.length > 1 && /* @__PURE__ */ m.jsx(
|
|
1790
1790
|
gr,
|
|
1791
1791
|
{
|
|
@@ -1805,7 +1805,7 @@ const ta = (n) => {
|
|
|
1805
1805
|
toolbar: !1
|
|
1806
1806
|
}
|
|
1807
1807
|
),
|
|
1808
|
-
e.sectionsType ?
|
|
1808
|
+
e.sectionsType ? d(i[t], !0) : i.map((p) => d(p))
|
|
1809
1809
|
] });
|
|
1810
1810
|
}, te = {
|
|
1811
1811
|
AUTOCOMPLETE: "ACP",
|
|
@@ -1868,11 +1868,13 @@ class ot {
|
|
|
1868
1868
|
}
|
|
1869
1869
|
function xr(n, e) {
|
|
1870
1870
|
if (Lt(n)) {
|
|
1871
|
-
const
|
|
1872
|
-
if (!isNaN(
|
|
1873
|
-
return
|
|
1871
|
+
const f = new Date(n);
|
|
1872
|
+
if (!isNaN(f.getTime()))
|
|
1873
|
+
return f;
|
|
1874
1874
|
}
|
|
1875
|
-
const t = /* @__PURE__ */ new Date()
|
|
1875
|
+
const t = /* @__PURE__ */ new Date();
|
|
1876
|
+
let r;
|
|
1877
|
+
/[/-]/.test(n) ? r = n.split(/[/-]/).map((u, d) => d < 2 && u.length === 1 ? "0" + u : u).join("") : r = n.replaceAll("/", "").replaceAll("-", "");
|
|
1876
1878
|
let s = "DDMMYYYY";
|
|
1877
1879
|
e === "en" && (s = "MMDDYYYY");
|
|
1878
1880
|
const a = s.indexOf("DD"), o = s.indexOf("MM");
|
|
@@ -1886,15 +1888,15 @@ function xr(n, e) {
|
|
|
1886
1888
|
return i = parseInt(r.substring(0, 2)), l = parseInt(r.substring(2, 4)), o === 0 ? (t.setMonth(i - 1), t.setDate(l)) : a === 0 && (t.setMonth(l - 1), t.setDate(i)), Ze(t) ? t : n;
|
|
1887
1889
|
case 5:
|
|
1888
1890
|
case 6: {
|
|
1889
|
-
i = parseInt(r.substring(0, 2)), l = parseInt(r.substring(2, 4)), Number(r.substring(4))
|
|
1890
|
-
let
|
|
1891
|
-
return o === 0 ? (
|
|
1891
|
+
i = parseInt(r.substring(0, 2)), l = parseInt(r.substring(2, 4)), Number(r.substring(4)) >= 50 ? c = "19" + r.substring(4) : c = "20" + r.substring(4);
|
|
1892
|
+
let f = 0, u = 0;
|
|
1893
|
+
return o === 0 ? (f = l, u = i - 1, t.setFullYear(parseInt(c), u, f)) : a === 0 && (f = i, u = l - 1, t.setFullYear(parseInt(c), u, f)), _t(i, u, parseInt(c)) && Ze(t) ? t : n;
|
|
1892
1894
|
}
|
|
1893
1895
|
case 7:
|
|
1894
1896
|
case 8: {
|
|
1895
1897
|
i = parseInt(r.substring(0, 2)), l = parseInt(r.substring(2, 4)), c = r.substring(4);
|
|
1896
|
-
let
|
|
1897
|
-
return o === 0 ? (
|
|
1898
|
+
let f = 0, u = 0;
|
|
1899
|
+
return o === 0 ? (f = l, u = i - 1, t.setFullYear(parseInt(c), u, f)) : a === 0 && (f = i, u = l - 1, t.setFullYear(parseInt(c), u, f)), _t(f, u, parseInt(c)) && Ze(t) ? t : n;
|
|
1898
1900
|
}
|
|
1899
1901
|
}
|
|
1900
1902
|
return n;
|
|
@@ -1983,59 +1985,59 @@ const on = /* @__PURE__ */ new Map([
|
|
|
1983
1985
|
}
|
|
1984
1986
|
]
|
|
1985
1987
|
]);
|
|
1986
|
-
function
|
|
1988
|
+
function dt({
|
|
1987
1989
|
position: n = "bottom",
|
|
1988
1990
|
enabled: e = !0
|
|
1989
1991
|
}) {
|
|
1990
1992
|
const t = le(null), r = le(null), [s, a] = G(0), o = ue(() => {
|
|
1991
1993
|
const i = t.current, l = r.current;
|
|
1992
1994
|
if (!i || !l) return;
|
|
1993
|
-
const { top: c, left:
|
|
1995
|
+
const { top: c, left: f, width: u, height: d } = i.getBoundingClientRect();
|
|
1994
1996
|
a(u);
|
|
1995
|
-
const
|
|
1996
|
-
if (p === 0 ||
|
|
1997
|
+
const g = l.offsetHeight, p = l.offsetWidth;
|
|
1998
|
+
if (p === 0 || g === 0) {
|
|
1997
1999
|
requestAnimationFrame(o);
|
|
1998
2000
|
return;
|
|
1999
2001
|
}
|
|
2000
2002
|
const w = window.scrollY, S = window.scrollX, E = window.innerWidth, b = window.innerHeight;
|
|
2001
|
-
let T = c + w, v =
|
|
2003
|
+
let T = c + w, v = f + S, y = n;
|
|
2002
2004
|
const k = {
|
|
2003
|
-
top: c -
|
|
2004
|
-
bottom: c +
|
|
2005
|
-
left:
|
|
2006
|
-
right:
|
|
2005
|
+
top: c - g < 0,
|
|
2006
|
+
bottom: c + d + g > b,
|
|
2007
|
+
left: f - p < 0,
|
|
2008
|
+
right: f + u + p > E
|
|
2007
2009
|
};
|
|
2008
2010
|
switch (n) {
|
|
2009
2011
|
case "top":
|
|
2010
|
-
k.top && !k.bottom && (
|
|
2012
|
+
k.top && !k.bottom && (y = "bottom");
|
|
2011
2013
|
break;
|
|
2012
2014
|
case "bottom":
|
|
2013
|
-
k.bottom && !k.top && (
|
|
2015
|
+
k.bottom && !k.top && (y = "top");
|
|
2014
2016
|
break;
|
|
2015
2017
|
case "left":
|
|
2016
|
-
k.left && !k.right && (
|
|
2018
|
+
k.left && !k.right && (y = "right");
|
|
2017
2019
|
break;
|
|
2018
2020
|
case "right":
|
|
2019
|
-
k.right && !k.left && (
|
|
2021
|
+
k.right && !k.left && (y = "left");
|
|
2020
2022
|
break;
|
|
2021
2023
|
}
|
|
2022
|
-
switch (
|
|
2024
|
+
switch (y) {
|
|
2023
2025
|
case "top":
|
|
2024
|
-
T = c + w -
|
|
2026
|
+
T = c + w - g;
|
|
2025
2027
|
break;
|
|
2026
2028
|
case "bottom":
|
|
2027
|
-
T = c + w +
|
|
2029
|
+
T = c + w + d;
|
|
2028
2030
|
break;
|
|
2029
2031
|
case "left":
|
|
2030
|
-
v =
|
|
2032
|
+
v = f + S - p;
|
|
2031
2033
|
break;
|
|
2032
2034
|
case "right":
|
|
2033
|
-
v =
|
|
2035
|
+
v = f + S + u;
|
|
2034
2036
|
break;
|
|
2035
2037
|
}
|
|
2036
2038
|
T = Math.max(
|
|
2037
2039
|
w,
|
|
2038
|
-
Math.min(T, w + b -
|
|
2040
|
+
Math.min(T, w + b - g)
|
|
2039
2041
|
), v = Math.max(
|
|
2040
2042
|
S,
|
|
2041
2043
|
Math.min(v, S + E - p)
|
|
@@ -2047,8 +2049,8 @@ function ft({
|
|
|
2047
2049
|
if (!e) return;
|
|
2048
2050
|
let i;
|
|
2049
2051
|
const l = () => {
|
|
2050
|
-
const
|
|
2051
|
-
|
|
2052
|
+
const f = t.current, u = r.current;
|
|
2053
|
+
f && u ? o() : i = requestAnimationFrame(l);
|
|
2052
2054
|
};
|
|
2053
2055
|
i = requestAnimationFrame(l);
|
|
2054
2056
|
const c = new MutationObserver(() => {
|
|
@@ -2109,10 +2111,10 @@ const _e = (n, e, t) => {
|
|
|
2109
2111
|
state: i,
|
|
2110
2112
|
variant: l,
|
|
2111
2113
|
tooltip: c = !1,
|
|
2112
|
-
rotatedShapeIcon:
|
|
2114
|
+
rotatedShapeIcon: f = !1,
|
|
2113
2115
|
ref: u,
|
|
2114
|
-
inputRef:
|
|
2115
|
-
inputType:
|
|
2116
|
+
inputRef: d,
|
|
2117
|
+
inputType: g = "text",
|
|
2116
2118
|
ariaLabel: p = "input field",
|
|
2117
2119
|
label: w,
|
|
2118
2120
|
helperText: S = !1,
|
|
@@ -2120,7 +2122,7 @@ const _e = (n, e, t) => {
|
|
|
2120
2122
|
appearance: b = "base",
|
|
2121
2123
|
fullWidth: T = !1,
|
|
2122
2124
|
_dataComponent: v = "textfield",
|
|
2123
|
-
min:
|
|
2125
|
+
min: y,
|
|
2124
2126
|
max: k,
|
|
2125
2127
|
step: A,
|
|
2126
2128
|
inputMode: O = "text",
|
|
@@ -2155,12 +2157,12 @@ const _e = (n, e, t) => {
|
|
|
2155
2157
|
ref: u,
|
|
2156
2158
|
style: j,
|
|
2157
2159
|
children: [
|
|
2158
|
-
t && /* @__PURE__ */ m.jsx(
|
|
2160
|
+
t && /* @__PURE__ */ m.jsx(fe, { icon: t, disabled: n }),
|
|
2159
2161
|
/* @__PURE__ */ m.jsx(
|
|
2160
2162
|
"input",
|
|
2161
2163
|
{
|
|
2162
2164
|
id: X,
|
|
2163
|
-
type:
|
|
2165
|
+
type: g,
|
|
2164
2166
|
value: e,
|
|
2165
2167
|
placeholder: r,
|
|
2166
2168
|
onChange: $,
|
|
@@ -2170,9 +2172,9 @@ const _e = (n, e, t) => {
|
|
|
2170
2172
|
readOnly: !s,
|
|
2171
2173
|
onKeyDown: B,
|
|
2172
2174
|
"aria-label": p,
|
|
2173
|
-
ref:
|
|
2175
|
+
ref: d,
|
|
2174
2176
|
"aria-describedby": x ? F : void 0,
|
|
2175
|
-
min:
|
|
2177
|
+
min: y,
|
|
2176
2178
|
max: k,
|
|
2177
2179
|
step: A,
|
|
2178
2180
|
inputMode: O,
|
|
@@ -2183,12 +2185,12 @@ const _e = (n, e, t) => {
|
|
|
2183
2185
|
}
|
|
2184
2186
|
),
|
|
2185
2187
|
a && /* @__PURE__ */ m.jsx(
|
|
2186
|
-
|
|
2188
|
+
fe,
|
|
2187
2189
|
{
|
|
2188
2190
|
icon: a,
|
|
2189
2191
|
disabled: n,
|
|
2190
2192
|
onClick: H,
|
|
2191
|
-
rotated:
|
|
2193
|
+
rotated: f,
|
|
2192
2194
|
isInteractable: s,
|
|
2193
2195
|
tabIndex: 0
|
|
2194
2196
|
}
|
|
@@ -2216,23 +2218,23 @@ function kn({
|
|
|
2216
2218
|
const [s, a] = G(0), o = le(null), i = n.length * e, l = Math.max(0, Math.floor(s / e) - r), c = Math.min(
|
|
2217
2219
|
n.length - 1,
|
|
2218
2220
|
Math.floor((s + t) / e) + r
|
|
2219
|
-
),
|
|
2220
|
-
for (let
|
|
2221
|
-
|
|
2222
|
-
item: n[
|
|
2223
|
-
index:
|
|
2224
|
-
offsetTop:
|
|
2221
|
+
), f = [];
|
|
2222
|
+
for (let g = l; g <= c; g++)
|
|
2223
|
+
f.push({
|
|
2224
|
+
item: n[g],
|
|
2225
|
+
index: g,
|
|
2226
|
+
offsetTop: g * e
|
|
2225
2227
|
});
|
|
2226
|
-
const u = ue((
|
|
2227
|
-
const p =
|
|
2228
|
+
const u = ue((g) => {
|
|
2229
|
+
const p = g.target.scrollTop;
|
|
2228
2230
|
a(p);
|
|
2229
|
-
}, []),
|
|
2231
|
+
}, []), d = (g) => {
|
|
2230
2232
|
if (!o.current) return;
|
|
2231
|
-
const p =
|
|
2233
|
+
const p = g * e, w = p + e, S = o.current, E = S.scrollTop, b = E + t;
|
|
2232
2234
|
p < E ? S.scrollTop = p : w > b && (S.scrollTop = w - t);
|
|
2233
2235
|
};
|
|
2234
2236
|
return {
|
|
2235
|
-
virtualItems:
|
|
2237
|
+
virtualItems: f,
|
|
2236
2238
|
containerProps: {
|
|
2237
2239
|
ref: o,
|
|
2238
2240
|
style: {
|
|
@@ -2257,7 +2259,7 @@ function kn({
|
|
|
2257
2259
|
startIndex: l,
|
|
2258
2260
|
endIndex: c
|
|
2259
2261
|
},
|
|
2260
|
-
scrollToIndex:
|
|
2262
|
+
scrollToIndex: d
|
|
2261
2263
|
};
|
|
2262
2264
|
}
|
|
2263
2265
|
const Qe = {
|
|
@@ -2289,17 +2291,17 @@ const Cr = 10, Ln = ({
|
|
|
2289
2291
|
width: i,
|
|
2290
2292
|
onClick: l,
|
|
2291
2293
|
onKeyDown: c,
|
|
2292
|
-
isOpen:
|
|
2294
|
+
isOpen: f
|
|
2293
2295
|
}) => {
|
|
2294
|
-
const [u,
|
|
2296
|
+
const [u, d] = G(""), g = 40, [p, w] = G(
|
|
2295
2297
|
a !== null ? a : -1
|
|
2296
2298
|
), [S, E] = G(i || 200), b = le(null), T = s !== void 0 ? s : e.length > Cr, v = u ? e.filter(
|
|
2297
2299
|
(N) => N.label.toLowerCase().includes(u.toLowerCase())
|
|
2298
|
-
) : e,
|
|
2299
|
-
|
|
2300
|
+
) : e, y = (N) => {
|
|
2301
|
+
d(N);
|
|
2300
2302
|
}, { virtualItems: k, containerProps: A, innerProps: O, scrollToIndex: L } = kn({
|
|
2301
2303
|
items: v,
|
|
2302
|
-
itemHeight:
|
|
2304
|
+
itemHeight: g,
|
|
2303
2305
|
containerHeight: 200,
|
|
2304
2306
|
overscan: 5
|
|
2305
2307
|
});
|
|
@@ -2308,8 +2310,8 @@ const Cr = 10, Ln = ({
|
|
|
2308
2310
|
}, [a]), ne(() => {
|
|
2309
2311
|
p >= 0 && p < v.length && L(p);
|
|
2310
2312
|
}, [p, v]), ne(() => {
|
|
2311
|
-
|
|
2312
|
-
}, [
|
|
2313
|
+
f && b?.current && b.current.focus();
|
|
2314
|
+
}, [f, b]), ne(() => {
|
|
2313
2315
|
const N = Tr(e, t);
|
|
2314
2316
|
E(N);
|
|
2315
2317
|
}, [e, t]);
|
|
@@ -2348,7 +2350,7 @@ const Cr = 10, Ln = ({
|
|
|
2348
2350
|
bindValue: u,
|
|
2349
2351
|
placeholder: "Search...",
|
|
2350
2352
|
fullWidth: !0,
|
|
2351
|
-
onChange:
|
|
2353
|
+
onChange: y,
|
|
2352
2354
|
onKeyDown: D,
|
|
2353
2355
|
inputRef: b
|
|
2354
2356
|
}
|
|
@@ -2377,8 +2379,8 @@ const Cr = 10, Ln = ({
|
|
|
2377
2379
|
className: `${P.listItem} ${p === B ? "selected-item" : ""}`,
|
|
2378
2380
|
"aria-label": N.id + "-" + N.label,
|
|
2379
2381
|
style: {
|
|
2380
|
-
height: `${
|
|
2381
|
-
lineHeight: `calc(${
|
|
2382
|
+
height: `${g}px`,
|
|
2383
|
+
lineHeight: `calc(${g}px - 2*2px)`,
|
|
2382
2384
|
// lineHeight - 2*padding
|
|
2383
2385
|
transform: `translateY(${H}px)`
|
|
2384
2386
|
},
|
|
@@ -2387,7 +2389,7 @@ const Cr = 10, Ln = ({
|
|
|
2387
2389
|
},
|
|
2388
2390
|
children: [
|
|
2389
2391
|
_e(N.id, N.label, t),
|
|
2390
|
-
z && /* @__PURE__ */ m.jsx(
|
|
2392
|
+
z && /* @__PURE__ */ m.jsx(fe, { icon: "check", width: 16 })
|
|
2391
2393
|
]
|
|
2392
2394
|
},
|
|
2393
2395
|
N.id
|
|
@@ -2470,7 +2472,7 @@ const ht = (n, e, t) => {
|
|
|
2470
2472
|
obj: n,
|
|
2471
2473
|
k: cn(r[s])
|
|
2472
2474
|
};
|
|
2473
|
-
},
|
|
2475
|
+
}, fn = (n, e, t) => {
|
|
2474
2476
|
const {
|
|
2475
2477
|
obj: r,
|
|
2476
2478
|
k: s
|
|
@@ -2634,7 +2636,7 @@ class mt {
|
|
|
2634
2636
|
});
|
|
2635
2637
|
}
|
|
2636
2638
|
}
|
|
2637
|
-
class
|
|
2639
|
+
class dn extends mt {
|
|
2638
2640
|
constructor(e, t = {
|
|
2639
2641
|
ns: ["translation"],
|
|
2640
2642
|
defaultNS: "translation"
|
|
@@ -2660,7 +2662,7 @@ class fn extends mt {
|
|
|
2660
2662
|
}) {
|
|
2661
2663
|
const o = a.keySeparator !== void 0 ? a.keySeparator : this.options.keySeparator;
|
|
2662
2664
|
let i = [e, t];
|
|
2663
|
-
r && (i = i.concat(o ? r.split(o) : r)), e.indexOf(".") > -1 && (i = e.split("."), s = t, t = i[1]), this.addNamespaces(t),
|
|
2665
|
+
r && (i = i.concat(o ? r.split(o) : r)), e.indexOf(".") > -1 && (i = e.split("."), s = t, t = i[1]), this.addNamespaces(t), fn(this.data, i, s), a.silent || this.emit("added", e, t, r, s);
|
|
2664
2666
|
}
|
|
2665
2667
|
addResources(e, t, r, s = {
|
|
2666
2668
|
silent: !1
|
|
@@ -2681,7 +2683,7 @@ class fn extends mt {
|
|
|
2681
2683
|
o.skipCopy || (r = JSON.parse(JSON.stringify(r))), s ? An(l, r, a) : l = {
|
|
2682
2684
|
...l,
|
|
2683
2685
|
...r
|
|
2684
|
-
},
|
|
2686
|
+
}, fn(this.data, i, l), o.silent || this.emit("added", e, t, r);
|
|
2685
2687
|
}
|
|
2686
2688
|
removeResourceBundle(e, t) {
|
|
2687
2689
|
this.hasResourceBundle(e, t) && delete this.data[e][t], this.removeNamespaces(t), this.emit("removed", e, t);
|
|
@@ -2763,18 +2765,18 @@ class ut extends mt {
|
|
|
2763
2765
|
key: i,
|
|
2764
2766
|
namespaces: l
|
|
2765
2767
|
} = this.extractFromKey(e[e.length - 1], s), c = l[l.length - 1];
|
|
2766
|
-
let
|
|
2767
|
-
|
|
2768
|
-
const u = s.lng || this.language,
|
|
2768
|
+
let f = s.nsSeparator !== void 0 ? s.nsSeparator : this.options.nsSeparator;
|
|
2769
|
+
f === void 0 && (f = ":");
|
|
2770
|
+
const u = s.lng || this.language, d = s.appendNamespaceToCIMode || this.options.appendNamespaceToCIMode;
|
|
2769
2771
|
if (u?.toLowerCase() === "cimode")
|
|
2770
|
-
return
|
|
2771
|
-
res: `${c}${
|
|
2772
|
+
return d ? a ? {
|
|
2773
|
+
res: `${c}${f}${i}`,
|
|
2772
2774
|
usedKey: i,
|
|
2773
2775
|
exactUsedKey: i,
|
|
2774
2776
|
usedLng: u,
|
|
2775
2777
|
usedNS: c,
|
|
2776
2778
|
usedParams: this.getUsedParamsDetails(s)
|
|
2777
|
-
} : `${c}${
|
|
2779
|
+
} : `${c}${f}${i}` : a ? {
|
|
2778
2780
|
res: i,
|
|
2779
2781
|
usedKey: i,
|
|
2780
2782
|
exactUsedKey: i,
|
|
@@ -2782,13 +2784,13 @@ class ut extends mt {
|
|
|
2782
2784
|
usedNS: c,
|
|
2783
2785
|
usedParams: this.getUsedParamsDetails(s)
|
|
2784
2786
|
} : i;
|
|
2785
|
-
const
|
|
2786
|
-
let p =
|
|
2787
|
-
const w =
|
|
2787
|
+
const g = this.resolve(e, s);
|
|
2788
|
+
let p = g?.res;
|
|
2789
|
+
const w = g?.usedKey || i, S = g?.exactUsedKey || i, E = ["[object Number]", "[object Function]", "[object RegExp]"], b = s.joinArrays !== void 0 ? s.joinArrays : this.options.joinArrays, T = !this.i18nFormat || this.i18nFormat.handleAsObject, v = s.count !== void 0 && !K(s.count), y = ut.hasDefaultValue(s), k = v ? this.pluralResolver.getSuffix(u, s.count, s) : "", A = s.ordinal && v ? this.pluralResolver.getSuffix(u, s.count, {
|
|
2788
2790
|
ordinal: !1
|
|
2789
2791
|
}) : "", O = v && !s.ordinal && s.count === 0, L = O && s[`defaultValue${this.options.pluralSeparator}zero`] || s[`defaultValue${k}`] || s[`defaultValue${A}`] || s.defaultValue;
|
|
2790
2792
|
let R = p;
|
|
2791
|
-
T && !p &&
|
|
2793
|
+
T && !p && y && (R = L);
|
|
2792
2794
|
const D = hn(R), C = Object.prototype.toString.apply(R);
|
|
2793
2795
|
if (T && R && D && E.indexOf(C) < 0 && !(K(b) && Array.isArray(R))) {
|
|
2794
2796
|
if (!s.returnObjects && !this.options.returnObjects) {
|
|
@@ -2797,14 +2799,14 @@ class ut extends mt {
|
|
|
2797
2799
|
...s,
|
|
2798
2800
|
ns: l
|
|
2799
2801
|
}) : `key '${i} (${this.language})' returned an object instead of string.`;
|
|
2800
|
-
return a ? (
|
|
2802
|
+
return a ? (g.res = P, g.usedParams = this.getUsedParamsDetails(s), g) : P;
|
|
2801
2803
|
}
|
|
2802
2804
|
if (o) {
|
|
2803
2805
|
const P = Array.isArray(R), N = P ? [] : {}, B = P ? S : w;
|
|
2804
2806
|
for (const H in R)
|
|
2805
2807
|
if (Object.prototype.hasOwnProperty.call(R, H)) {
|
|
2806
2808
|
const z = `${B}${o}${H}`;
|
|
2807
|
-
|
|
2809
|
+
y && !p ? N[H] = this.translate(z, {
|
|
2808
2810
|
...s,
|
|
2809
2811
|
defaultValue: hn(L) ? L[H] : void 0,
|
|
2810
2812
|
joinArrays: !1,
|
|
@@ -2821,8 +2823,8 @@ class ut extends mt {
|
|
|
2821
2823
|
p = p.join(b), p && (p = this.extendTranslation(p, e, s, r));
|
|
2822
2824
|
else {
|
|
2823
2825
|
let P = !1, N = !1;
|
|
2824
|
-
!this.isValidLookup(p) &&
|
|
2825
|
-
const H = (s.missingKeyNoValueFallbackToKey || this.options.missingKeyNoValueFallbackToKey) && N ? void 0 : p, z =
|
|
2826
|
+
!this.isValidLookup(p) && y && (P = !0, p = L), this.isValidLookup(p) || (N = !0, p = i);
|
|
2827
|
+
const H = (s.missingKeyNoValueFallbackToKey || this.options.missingKeyNoValueFallbackToKey) && N ? void 0 : p, z = y && L !== p && this.options.updateMissing;
|
|
2826
2828
|
if (N || P || z) {
|
|
2827
2829
|
if (this.logger.log(z ? "updateKey" : "missingKey", u, c, i, z ? L : p), o) {
|
|
2828
2830
|
const x = this.resolve(i, {
|
|
@@ -2838,7 +2840,7 @@ class ut extends mt {
|
|
|
2838
2840
|
X.push(F[x]);
|
|
2839
2841
|
else this.options.saveMissingTo === "all" ? X = this.languageUtils.toResolveHierarchy(s.lng || this.language) : X.push(s.lng || this.language);
|
|
2840
2842
|
const h = (x, $, _) => {
|
|
2841
|
-
const j =
|
|
2843
|
+
const j = y && _ !== p ? _ : H;
|
|
2842
2844
|
this.options.missingKeyHandler ? this.options.missingKeyHandler(x, c, $, j, z, s) : this.backendConnector?.saveMissing && this.backendConnector.saveMissing(x, c, $, j, z, s), this.emit("missingKey", x, c, $, p);
|
|
2843
2845
|
};
|
|
2844
2846
|
this.options.saveMissing && (this.options.saveMissingPlurals && v ? X.forEach((x) => {
|
|
@@ -2848,9 +2850,9 @@ class ut extends mt {
|
|
|
2848
2850
|
});
|
|
2849
2851
|
}) : h(X, i, L));
|
|
2850
2852
|
}
|
|
2851
|
-
p = this.extendTranslation(p, e, s,
|
|
2853
|
+
p = this.extendTranslation(p, e, s, g, r), N && p === i && this.options.appendNamespaceToMissingKey && (p = `${c}${f}${i}`), (N || P) && this.options.parseMissingKeyHandler && (p = this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey ? `${c}${f}${i}` : i, P ? p : void 0, s));
|
|
2852
2854
|
}
|
|
2853
|
-
return a ? (
|
|
2855
|
+
return a ? (g.res = p, g.usedParams = this.getUsedParamsDetails(s), g) : p;
|
|
2854
2856
|
}
|
|
2855
2857
|
extendTranslation(e, t, r, s, a) {
|
|
2856
2858
|
if (this.i18nFormat?.parse)
|
|
@@ -2874,13 +2876,13 @@ class ut extends mt {
|
|
|
2874
2876
|
const u = e.match(this.interpolator.nestingRegexp);
|
|
2875
2877
|
c = u && u.length;
|
|
2876
2878
|
}
|
|
2877
|
-
let
|
|
2878
|
-
if (this.options.interpolation.defaultVariables && (
|
|
2879
|
+
let f = r.replace && !K(r.replace) ? r.replace : r;
|
|
2880
|
+
if (this.options.interpolation.defaultVariables && (f = {
|
|
2879
2881
|
...this.options.interpolation.defaultVariables,
|
|
2880
|
-
...
|
|
2881
|
-
}), e = this.interpolator.interpolate(e,
|
|
2882
|
-
const u = e.match(this.interpolator.nestingRegexp),
|
|
2883
|
-
c <
|
|
2882
|
+
...f
|
|
2883
|
+
}), e = this.interpolator.interpolate(e, f, r.lng || this.language || s.usedLng, r), l) {
|
|
2884
|
+
const u = e.match(this.interpolator.nestingRegexp), d = u && u.length;
|
|
2885
|
+
c < d && (r.nest = !1);
|
|
2884
2886
|
}
|
|
2885
2887
|
!r.lng && s && s.res && (r.lng = this.language || s.usedLng), r.nest !== !1 && (e = this.interpolator.nest(e, (...u) => a?.[0] === u[0] && !r.context ? (this.logger.warn(`It seems you are nesting recursively key: ${u[0]} in key: ${t[0]}`), null) : this.translate(...u, t), r)), r.interpolation && this.interpolator.reset();
|
|
2886
2888
|
}
|
|
@@ -2897,25 +2899,25 @@ class ut extends mt {
|
|
|
2897
2899
|
let r, s, a, o, i;
|
|
2898
2900
|
return K(e) && (e = [e]), e.forEach((l) => {
|
|
2899
2901
|
if (this.isValidLookup(r)) return;
|
|
2900
|
-
const c = this.extractFromKey(l, t),
|
|
2901
|
-
s =
|
|
2902
|
+
const c = this.extractFromKey(l, t), f = c.key;
|
|
2903
|
+
s = f;
|
|
2902
2904
|
let u = c.namespaces;
|
|
2903
2905
|
this.options.fallbackNS && (u = u.concat(this.options.fallbackNS));
|
|
2904
|
-
const
|
|
2906
|
+
const d = t.count !== void 0 && !K(t.count), g = d && !t.ordinal && t.count === 0, p = t.context !== void 0 && (K(t.context) || typeof t.context == "number") && t.context !== "", w = t.lngs ? t.lngs : this.languageUtils.toResolveHierarchy(t.lng || this.language, t.fallbackLng);
|
|
2905
2907
|
u.forEach((S) => {
|
|
2906
2908
|
this.isValidLookup(r) || (i = S, !pn[`${w[0]}-${S}`] && this.utils?.hasLoadedNamespace && !this.utils?.hasLoadedNamespace(i) && (pn[`${w[0]}-${S}`] = !0, this.logger.warn(`key "${s}" for languages "${w.join(", ")}" won't get resolved as namespace "${i}" was not yet loaded`, "This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")), w.forEach((E) => {
|
|
2907
2909
|
if (this.isValidLookup(r)) return;
|
|
2908
2910
|
o = E;
|
|
2909
|
-
const b = [
|
|
2911
|
+
const b = [f];
|
|
2910
2912
|
if (this.i18nFormat?.addLookupKeys)
|
|
2911
|
-
this.i18nFormat.addLookupKeys(b,
|
|
2913
|
+
this.i18nFormat.addLookupKeys(b, f, E, S, t);
|
|
2912
2914
|
else {
|
|
2913
2915
|
let v;
|
|
2914
|
-
|
|
2915
|
-
const
|
|
2916
|
-
if (
|
|
2917
|
-
const A = `${
|
|
2918
|
-
b.push(A),
|
|
2916
|
+
d && (v = this.pluralResolver.getSuffix(E, t.count, t));
|
|
2917
|
+
const y = `${this.options.pluralSeparator}zero`, k = `${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;
|
|
2918
|
+
if (d && (b.push(f + v), t.ordinal && v.indexOf(k) === 0 && b.push(f + v.replace(k, this.options.pluralSeparator)), g && b.push(f + y)), p) {
|
|
2919
|
+
const A = `${f}${this.options.contextSeparator}${t.context}`;
|
|
2920
|
+
b.push(A), d && (b.push(A + v), t.ordinal && v.indexOf(k) === 0 && b.push(A + v.replace(k, this.options.pluralSeparator)), g && b.push(A + y));
|
|
2919
2921
|
}
|
|
2920
2922
|
}
|
|
2921
2923
|
let T;
|
|
@@ -3105,17 +3107,17 @@ class Fr {
|
|
|
3105
3107
|
suffix: i,
|
|
3106
3108
|
suffixEscaped: l,
|
|
3107
3109
|
formatSeparator: c,
|
|
3108
|
-
unescapeSuffix:
|
|
3110
|
+
unescapeSuffix: f,
|
|
3109
3111
|
unescapePrefix: u,
|
|
3110
|
-
nestingPrefix:
|
|
3111
|
-
nestingPrefixEscaped:
|
|
3112
|
+
nestingPrefix: d,
|
|
3113
|
+
nestingPrefixEscaped: g,
|
|
3112
3114
|
nestingSuffix: p,
|
|
3113
3115
|
nestingSuffixEscaped: w,
|
|
3114
3116
|
nestingOptionsSeparator: S,
|
|
3115
3117
|
maxReplaces: E,
|
|
3116
3118
|
alwaysFormat: b
|
|
3117
3119
|
} = e.interpolation;
|
|
3118
|
-
this.escape = t !== void 0 ? t : kr, this.escapeValue = r !== void 0 ? r : !0, this.useRawValueToEscape = s !== void 0 ? s : !1, this.prefix = a ? Ae(a) : o || "{{", this.suffix = i ? Ae(i) : l || "}}", this.formatSeparator = c || ",", this.unescapePrefix =
|
|
3120
|
+
this.escape = t !== void 0 ? t : kr, this.escapeValue = r !== void 0 ? r : !0, this.useRawValueToEscape = s !== void 0 ? s : !1, this.prefix = a ? Ae(a) : o || "{{", this.suffix = i ? Ae(i) : l || "}}", this.formatSeparator = c || ",", this.unescapePrefix = f ? "" : u || "-", this.unescapeSuffix = this.unescapePrefix ? "" : f || "", this.nestingPrefix = d ? Ae(d) : g || Ae("$t("), this.nestingSuffix = p ? Ae(p) : w || Ae(")"), this.nestingOptionsSeparator = S || ",", this.maxReplaces = E || 1e3, this.alwaysFormat = b !== void 0 ? b : !1, this.resetRegExp();
|
|
3119
3121
|
}
|
|
3120
3122
|
reset() {
|
|
3121
3123
|
this.options && this.init(this.options);
|
|
@@ -3126,16 +3128,16 @@ class Fr {
|
|
|
3126
3128
|
}
|
|
3127
3129
|
interpolate(e, t, r, s) {
|
|
3128
3130
|
let a, o, i;
|
|
3129
|
-
const l = this.options && this.options.interpolation && this.options.interpolation.defaultVariables || {}, c = (
|
|
3130
|
-
if (
|
|
3131
|
-
const E = bn(t, l,
|
|
3131
|
+
const l = this.options && this.options.interpolation && this.options.interpolation.defaultVariables || {}, c = (g) => {
|
|
3132
|
+
if (g.indexOf(this.formatSeparator) < 0) {
|
|
3133
|
+
const E = bn(t, l, g, this.options.keySeparator, this.options.ignoreJSONStructure);
|
|
3132
3134
|
return this.alwaysFormat ? this.format(E, void 0, r, {
|
|
3133
3135
|
...s,
|
|
3134
3136
|
...t,
|
|
3135
|
-
interpolationkey:
|
|
3137
|
+
interpolationkey: g
|
|
3136
3138
|
}) : E;
|
|
3137
3139
|
}
|
|
3138
|
-
const p =
|
|
3140
|
+
const p = g.split(this.formatSeparator), w = p.shift().trim(), S = p.join(this.formatSeparator).trim();
|
|
3139
3141
|
return this.format(bn(t, l, w, this.options.keySeparator, this.options.ignoreJSONStructure), S, r, {
|
|
3140
3142
|
...s,
|
|
3141
3143
|
...t,
|
|
@@ -3143,19 +3145,19 @@ class Fr {
|
|
|
3143
3145
|
});
|
|
3144
3146
|
};
|
|
3145
3147
|
this.resetRegExp();
|
|
3146
|
-
const
|
|
3148
|
+
const f = s?.missingInterpolationHandler || this.options.missingInterpolationHandler, u = s?.interpolation?.skipOnVariables !== void 0 ? s.interpolation.skipOnVariables : this.options.interpolation.skipOnVariables;
|
|
3147
3149
|
return [{
|
|
3148
3150
|
regex: this.regexpUnescape,
|
|
3149
|
-
safeValue: (
|
|
3151
|
+
safeValue: (g) => Tt(g)
|
|
3150
3152
|
}, {
|
|
3151
3153
|
regex: this.regexp,
|
|
3152
|
-
safeValue: (
|
|
3153
|
-
}].forEach((
|
|
3154
|
-
for (i = 0; a =
|
|
3154
|
+
safeValue: (g) => this.escapeValue ? Tt(this.escape(g)) : Tt(g)
|
|
3155
|
+
}].forEach((g) => {
|
|
3156
|
+
for (i = 0; a = g.regex.exec(e); ) {
|
|
3155
3157
|
const p = a[1].trim();
|
|
3156
3158
|
if (o = c(p), o === void 0)
|
|
3157
|
-
if (typeof
|
|
3158
|
-
const S =
|
|
3159
|
+
if (typeof f == "function") {
|
|
3160
|
+
const S = f(e, a, s);
|
|
3159
3161
|
o = K(S) ? S : "";
|
|
3160
3162
|
} else if (s && Object.prototype.hasOwnProperty.call(s, p))
|
|
3161
3163
|
o = "";
|
|
@@ -3165,8 +3167,8 @@ class Fr {
|
|
|
3165
3167
|
} else
|
|
3166
3168
|
this.logger.warn(`missed to pass in variable ${p} for interpolating ${e}`), o = "";
|
|
3167
3169
|
else !K(o) && !this.useRawValueToEscape && (o = ln(o));
|
|
3168
|
-
const w =
|
|
3169
|
-
if (e = e.replace(a[0], w), u ? (
|
|
3170
|
+
const w = g.safeValue(o);
|
|
3171
|
+
if (e = e.replace(a[0], w), u ? (g.regex.lastIndex += o.length, g.regex.lastIndex -= a[0].length) : g.regex.lastIndex = 0, i++, i >= this.maxReplaces)
|
|
3170
3172
|
break;
|
|
3171
3173
|
}
|
|
3172
3174
|
}), e;
|
|
@@ -3174,20 +3176,20 @@ class Fr {
|
|
|
3174
3176
|
nest(e, t, r = {}) {
|
|
3175
3177
|
let s, a, o;
|
|
3176
3178
|
const i = (l, c) => {
|
|
3177
|
-
const
|
|
3178
|
-
if (l.indexOf(
|
|
3179
|
-
const u = l.split(new RegExp(`${
|
|
3180
|
-
let
|
|
3181
|
-
l = u[0],
|
|
3182
|
-
const
|
|
3183
|
-
((
|
|
3179
|
+
const f = this.nestingOptionsSeparator;
|
|
3180
|
+
if (l.indexOf(f) < 0) return l;
|
|
3181
|
+
const u = l.split(new RegExp(`${f}[ ]*{`));
|
|
3182
|
+
let d = `{${u[1]}`;
|
|
3183
|
+
l = u[0], d = this.interpolate(d, o);
|
|
3184
|
+
const g = d.match(/'/g), p = d.match(/"/g);
|
|
3185
|
+
((g?.length ?? 0) % 2 === 0 && !p || p.length % 2 !== 0) && (d = d.replace(/'/g, '"'));
|
|
3184
3186
|
try {
|
|
3185
|
-
o = JSON.parse(
|
|
3187
|
+
o = JSON.parse(d), c && (o = {
|
|
3186
3188
|
...c,
|
|
3187
3189
|
...o
|
|
3188
3190
|
});
|
|
3189
3191
|
} catch (w) {
|
|
3190
|
-
return this.logger.warn(`failed parsing options string in nesting for key ${l}`, w), `${l}${
|
|
3192
|
+
return this.logger.warn(`failed parsing options string in nesting for key ${l}`, w), `${l}${f}${d}`;
|
|
3191
3193
|
}
|
|
3192
3194
|
return o.defaultValue && o.defaultValue.indexOf(this.prefix) > -1 && delete o.defaultValue, l;
|
|
3193
3195
|
};
|
|
@@ -3197,8 +3199,8 @@ class Fr {
|
|
|
3197
3199
|
...r
|
|
3198
3200
|
}, o = o.replace && !K(o.replace) ? o.replace : o, o.applyPostProcessor = !1, delete o.defaultValue;
|
|
3199
3201
|
const c = /{.*}/.test(s[1]) ? s[1].lastIndexOf("}") + 1 : s[1].indexOf(this.formatSeparator);
|
|
3200
|
-
if (c !== -1 && (l = s[1].slice(c).split(this.formatSeparator).map((
|
|
3201
|
-
K(a) || (a = ln(a)), a || (this.logger.warn(`missed to resolve ${s[1]} for nesting ${e}`), a = ""), l.length && (a = l.reduce((
|
|
3202
|
+
if (c !== -1 && (l = s[1].slice(c).split(this.formatSeparator).map((f) => f.trim()).filter(Boolean), s[1] = s[1].slice(0, c)), a = t(i.call(this, s[1].trim(), o), o), a && s[0] === e && !K(a)) return a;
|
|
3203
|
+
K(a) || (a = ln(a)), a || (this.logger.warn(`missed to resolve ${s[1]} for nesting ${e}`), a = ""), l.length && (a = l.reduce((f, u) => this.format(f, u, r.lng, {
|
|
3202
3204
|
...r,
|
|
3203
3205
|
interpolationkey: s[1].trim()
|
|
3204
3206
|
}), a.trim())), e = e.replace(s[0], a), this.regexp.lastIndex = 0;
|
|
@@ -3215,8 +3217,8 @@ const Vr = (n) => {
|
|
|
3215
3217
|
const s = r[1].substring(0, r[1].length - 1);
|
|
3216
3218
|
e === "currency" && s.indexOf(":") < 0 ? t.currency || (t.currency = s.trim()) : e === "relativetime" && s.indexOf(":") < 0 ? t.range || (t.range = s.trim()) : s.split(";").forEach((o) => {
|
|
3217
3219
|
if (o) {
|
|
3218
|
-
const [i, ...l] = o.split(":"), c = l.join(":").trim().replace(/^'+|'+$/g, ""),
|
|
3219
|
-
t[
|
|
3220
|
+
const [i, ...l] = o.split(":"), c = l.join(":").trim().replace(/^'+|'+$/g, ""), f = i.trim();
|
|
3221
|
+
t[f] || (t[f] = c), c === "false" && (t[f] = !1), c === "true" && (t[f] = !0), isNaN(c) || (t[f] = parseInt(c, 10));
|
|
3220
3222
|
}
|
|
3221
3223
|
});
|
|
3222
3224
|
}
|
|
@@ -3295,19 +3297,19 @@ class Wr {
|
|
|
3295
3297
|
return a.reduce((i, l) => {
|
|
3296
3298
|
const {
|
|
3297
3299
|
formatName: c,
|
|
3298
|
-
formatOptions:
|
|
3300
|
+
formatOptions: f
|
|
3299
3301
|
} = Vr(l);
|
|
3300
3302
|
if (this.formats[c]) {
|
|
3301
3303
|
let u = i;
|
|
3302
3304
|
try {
|
|
3303
|
-
const
|
|
3304
|
-
u = this.formats[c](i,
|
|
3305
|
-
...
|
|
3305
|
+
const d = s?.formatParams?.[s.interpolationkey] || {}, g = d.locale || d.lng || s.locale || s.lng || r;
|
|
3306
|
+
u = this.formats[c](i, g, {
|
|
3307
|
+
...f,
|
|
3306
3308
|
...s,
|
|
3307
|
-
...
|
|
3309
|
+
...d
|
|
3308
3310
|
});
|
|
3309
|
-
} catch (
|
|
3310
|
-
this.logger.warn(
|
|
3311
|
+
} catch (d) {
|
|
3312
|
+
this.logger.warn(d);
|
|
3311
3313
|
}
|
|
3312
3314
|
return u;
|
|
3313
3315
|
} else
|
|
@@ -3326,11 +3328,11 @@ class Br extends mt {
|
|
|
3326
3328
|
queueLoad(e, t, r, s) {
|
|
3327
3329
|
const a = {}, o = {}, i = {}, l = {};
|
|
3328
3330
|
return e.forEach((c) => {
|
|
3329
|
-
let
|
|
3331
|
+
let f = !0;
|
|
3330
3332
|
t.forEach((u) => {
|
|
3331
|
-
const
|
|
3332
|
-
!r.reload && this.store.hasResourceBundle(c, u) ? this.state[
|
|
3333
|
-
}),
|
|
3333
|
+
const d = `${c}|${u}`;
|
|
3334
|
+
!r.reload && this.store.hasResourceBundle(c, u) ? this.state[d] = 2 : this.state[d] < 0 || (this.state[d] === 1 ? o[d] === void 0 && (o[d] = !0) : (this.state[d] = 1, f = !1, o[d] === void 0 && (o[d] = !0), a[d] === void 0 && (a[d] = !0), l[u] === void 0 && (l[u] = !0)));
|
|
3335
|
+
}), f || (i[c] = !0);
|
|
3334
3336
|
}), (Object.keys(a).length || Object.keys(o).length) && this.queue.push({
|
|
3335
3337
|
pending: o,
|
|
3336
3338
|
pendingCount: Object.keys(o).length,
|
|
@@ -3353,8 +3355,8 @@ class Br extends mt {
|
|
|
3353
3355
|
this.queue.forEach((l) => {
|
|
3354
3356
|
Dr(l.loaded, [a], o), Yr(l, e), t && l.errors.push(t), l.pendingCount === 0 && !l.done && (Object.keys(l.loaded).forEach((c) => {
|
|
3355
3357
|
i[c] || (i[c] = {});
|
|
3356
|
-
const
|
|
3357
|
-
|
|
3358
|
+
const f = l.loaded[c];
|
|
3359
|
+
f.length && f.forEach((u) => {
|
|
3358
3360
|
i[c][u] === void 0 && (i[c][u] = !0);
|
|
3359
3361
|
});
|
|
3360
3362
|
}), l.done = !0, l.errors.length ? l.callback(l.errors) : l.callback());
|
|
@@ -3374,23 +3376,23 @@ class Br extends mt {
|
|
|
3374
3376
|
return;
|
|
3375
3377
|
}
|
|
3376
3378
|
this.readingCalls++;
|
|
3377
|
-
const i = (c,
|
|
3379
|
+
const i = (c, f) => {
|
|
3378
3380
|
if (this.readingCalls--, this.waitingReads.length > 0) {
|
|
3379
3381
|
const u = this.waitingReads.shift();
|
|
3380
3382
|
this.read(u.lng, u.ns, u.fcName, u.tried, u.wait, u.callback);
|
|
3381
3383
|
}
|
|
3382
|
-
if (c &&
|
|
3384
|
+
if (c && f && s < this.maxRetries) {
|
|
3383
3385
|
setTimeout(() => {
|
|
3384
3386
|
this.read.call(this, e, t, r, s + 1, a * 2, o);
|
|
3385
3387
|
}, a);
|
|
3386
3388
|
return;
|
|
3387
3389
|
}
|
|
3388
|
-
o(c,
|
|
3390
|
+
o(c, f);
|
|
3389
3391
|
}, l = this.backend[r].bind(this.backend);
|
|
3390
3392
|
if (l.length === 2) {
|
|
3391
3393
|
try {
|
|
3392
3394
|
const c = l(e, t);
|
|
3393
|
-
c && typeof c.then == "function" ? c.then((
|
|
3395
|
+
c && typeof c.then == "function" ? c.then((f) => i(null, f)).catch(i) : i(null, c);
|
|
3394
3396
|
} catch (c) {
|
|
3395
3397
|
i(c);
|
|
3396
3398
|
}
|
|
@@ -3437,10 +3439,10 @@ class Br extends mt {
|
|
|
3437
3439
|
}, c = this.backend.create.bind(this.backend);
|
|
3438
3440
|
if (c.length < 6)
|
|
3439
3441
|
try {
|
|
3440
|
-
let
|
|
3441
|
-
c.length === 5 ?
|
|
3442
|
-
} catch (
|
|
3443
|
-
i(
|
|
3442
|
+
let f;
|
|
3443
|
+
c.length === 5 ? f = c(e, t, r, s, l) : f = c(e, t, r, s), f && typeof f.then == "function" ? f.then((u) => i(null, u)).catch(i) : i(null, f);
|
|
3444
|
+
} catch (f) {
|
|
3445
|
+
i(f);
|
|
3444
3446
|
}
|
|
3445
3447
|
else
|
|
3446
3448
|
c(e, t, r, s, i, l);
|
|
@@ -3540,20 +3542,20 @@ class Be extends mt {
|
|
|
3540
3542
|
this.modules.logger ? ve.init(s(this.modules.logger), this.options) : ve.init(null, this.options);
|
|
3541
3543
|
let c;
|
|
3542
3544
|
this.modules.formatter ? c = this.modules.formatter : c = Wr;
|
|
3543
|
-
const
|
|
3544
|
-
this.store = new
|
|
3545
|
+
const f = new mn(this.options);
|
|
3546
|
+
this.store = new dn(this.options.resources, this.options);
|
|
3545
3547
|
const u = this.services;
|
|
3546
|
-
u.logger = ve, u.resourceStore = this.store, u.languageUtils =
|
|
3548
|
+
u.logger = ve, u.resourceStore = this.store, u.languageUtils = f, u.pluralResolver = new Mr(f, {
|
|
3547
3549
|
prepend: this.options.pluralSeparator,
|
|
3548
3550
|
simplifyPluralSuffix: this.options.simplifyPluralSuffix
|
|
3549
|
-
}), c && (!this.options.interpolation.format || this.options.interpolation.format === r.interpolation.format) && (u.formatter = s(c), u.formatter.init(u, this.options), this.options.interpolation.format = u.formatter.format.bind(u.formatter)), u.interpolator = new Fr(this.options), u.utils = {
|
|
3551
|
+
}), this.options.interpolation.format && this.options.interpolation.format !== r.interpolation.format && this.logger.warn("init: you are still using the legacy format function, please use the new approach: https://www.i18next.com/translation-function/formatting"), c && (!this.options.interpolation.format || this.options.interpolation.format === r.interpolation.format) && (u.formatter = s(c), u.formatter.init && u.formatter.init(u, this.options), this.options.interpolation.format = u.formatter.format.bind(u.formatter)), u.interpolator = new Fr(this.options), u.utils = {
|
|
3550
3552
|
hasLoadedNamespace: this.hasLoadedNamespace.bind(this)
|
|
3551
|
-
}, u.backendConnector = new Br(s(this.modules.backend), u.resourceStore, u, this.options), u.backendConnector.on("*", (
|
|
3552
|
-
this.emit(
|
|
3553
|
-
}), this.modules.languageDetector && (u.languageDetector = s(this.modules.languageDetector), u.languageDetector.init && u.languageDetector.init(u, this.options.detection, this.options)), this.modules.i18nFormat && (u.i18nFormat = s(this.modules.i18nFormat), u.i18nFormat.init && u.i18nFormat.init(this)), this.translator = new ut(this.services, this.options), this.translator.on("*", (
|
|
3554
|
-
this.emit(
|
|
3555
|
-
}), this.modules.external.forEach((
|
|
3556
|
-
|
|
3553
|
+
}, u.backendConnector = new Br(s(this.modules.backend), u.resourceStore, u, this.options), u.backendConnector.on("*", (g, ...p) => {
|
|
3554
|
+
this.emit(g, ...p);
|
|
3555
|
+
}), this.modules.languageDetector && (u.languageDetector = s(this.modules.languageDetector), u.languageDetector.init && u.languageDetector.init(u, this.options.detection, this.options)), this.modules.i18nFormat && (u.i18nFormat = s(this.modules.i18nFormat), u.i18nFormat.init && u.i18nFormat.init(this)), this.translator = new ut(this.services, this.options), this.translator.on("*", (g, ...p) => {
|
|
3556
|
+
this.emit(g, ...p);
|
|
3557
|
+
}), this.modules.external.forEach((g) => {
|
|
3558
|
+
g.init && g.init(this);
|
|
3557
3559
|
});
|
|
3558
3560
|
}
|
|
3559
3561
|
if (this.format = this.options.interpolation.format, t || (t = et), this.options.fallbackLng && !this.services.languageDetector && !this.options.lng) {
|
|
@@ -3561,13 +3563,13 @@ class Be extends mt {
|
|
|
3561
3563
|
c.length > 0 && c[0] !== "dev" && (this.options.lng = c[0]);
|
|
3562
3564
|
}
|
|
3563
3565
|
!this.services.languageDetector && !this.options.lng && this.logger.warn("init: no languageDetector is used and no lng is defined"), ["getResource", "hasResourceBundle", "getResourceBundle", "getDataByLanguage"].forEach((c) => {
|
|
3564
|
-
this[c] = (...
|
|
3566
|
+
this[c] = (...f) => this.store[c](...f);
|
|
3565
3567
|
}), ["addResource", "addResources", "addResourceBundle", "removeResourceBundle"].forEach((c) => {
|
|
3566
|
-
this[c] = (...
|
|
3568
|
+
this[c] = (...f) => (this.store[c](...f), this);
|
|
3567
3569
|
});
|
|
3568
3570
|
const i = Ue(), l = () => {
|
|
3569
|
-
const c = (
|
|
3570
|
-
this.isInitializing = !1, this.isInitialized && !this.initializedStoreOnce && this.logger.warn("init: i18next is already initialized. You should call init just once!"), this.isInitialized = !0, this.options.isClone || this.logger.log("initialized", this.options), this.emit("initialized", this.options), i.resolve(u), t(
|
|
3571
|
+
const c = (f, u) => {
|
|
3572
|
+
this.isInitializing = !1, this.isInitialized && !this.initializedStoreOnce && this.logger.warn("init: i18next is already initialized. You should call init just once!"), this.isInitialized = !0, this.options.isClone || this.logger.log("initialized", this.options), this.emit("initialized", this.options), i.resolve(u), t(f, u);
|
|
3571
3573
|
};
|
|
3572
3574
|
if (this.languages && !this.isInitialized) return c(null, this.t.bind(this));
|
|
3573
3575
|
this.changeLanguage(this.options.lng, c);
|
|
@@ -3625,8 +3627,8 @@ class Be extends mt {
|
|
|
3625
3627
|
}, o = (i) => {
|
|
3626
3628
|
!e && !i && this.services.languageDetector && (i = []);
|
|
3627
3629
|
const l = K(i) ? i : i && i[0], c = this.store.hasLanguageSomeTranslations(l) ? l : this.services.languageUtils.getBestMatchFromCodes(K(i) ? [i] : i);
|
|
3628
|
-
c && (this.language || s(c), this.translator.language || this.translator.changeLanguage(c), this.services.languageDetector?.cacheUserLanguage?.(c)), this.loadResources(c, (
|
|
3629
|
-
a(
|
|
3630
|
+
c && (this.language || s(c), this.translator.language || this.translator.changeLanguage(c), this.services.languageDetector?.cacheUserLanguage?.(c)), this.loadResources(c, (f) => {
|
|
3631
|
+
a(f, c);
|
|
3630
3632
|
});
|
|
3631
3633
|
};
|
|
3632
3634
|
return !e && this.services.languageDetector && !this.services.languageDetector.async ? o(this.services.languageDetector.detect()) : !e && this.services.languageDetector && this.services.languageDetector.async ? this.services.languageDetector.detect.length === 0 ? this.services.languageDetector.detect().then(o) : this.services.languageDetector.detect(o) : o(e), r;
|
|
@@ -3638,8 +3640,8 @@ class Be extends mt {
|
|
|
3638
3640
|
...o
|
|
3639
3641
|
}, l.lng = l.lng || s.lng, l.lngs = l.lngs || s.lngs, l.ns = l.ns || s.ns, l.keyPrefix !== "" && (l.keyPrefix = l.keyPrefix || r || s.keyPrefix);
|
|
3640
3642
|
const c = this.options.keySeparator || ".";
|
|
3641
|
-
let
|
|
3642
|
-
return l.keyPrefix && Array.isArray(a) ?
|
|
3643
|
+
let f;
|
|
3644
|
+
return l.keyPrefix && Array.isArray(a) ? f = a.map((u) => `${l.keyPrefix}${c}${u}`) : f = l.keyPrefix ? `${l.keyPrefix}${c}${a}` : a, this.t(f, l);
|
|
3643
3645
|
};
|
|
3644
3646
|
return K(e) ? s.lng = e : s.lngs = e, s.ns = t, s.keyPrefix = r, s;
|
|
3645
3647
|
}
|
|
@@ -3717,10 +3719,10 @@ class Be extends mt {
|
|
|
3717
3719
|
}, r) {
|
|
3718
3720
|
const i = Object.keys(this.store.data).reduce((l, c) => (l[c] = {
|
|
3719
3721
|
...this.store.data[c]
|
|
3720
|
-
}, l[c] = Object.keys(l[c]).reduce((
|
|
3722
|
+
}, l[c] = Object.keys(l[c]).reduce((f, u) => (f[u] = {
|
|
3721
3723
|
...l[c][u]
|
|
3722
|
-
},
|
|
3723
|
-
a.store = new
|
|
3724
|
+
}, f), l[c]), l), {});
|
|
3725
|
+
a.store = new dn(i, s), a.services.resourceStore = a.store;
|
|
3724
3726
|
}
|
|
3725
3727
|
return a.translator = new ut(a.services, s), a.translator.on("*", (i, ...l) => {
|
|
3726
3728
|
a.emit(i, ...l);
|
|
@@ -3875,7 +3877,7 @@ function $e() {
|
|
|
3875
3877
|
);
|
|
3876
3878
|
return { format: n, getCurrentLanguage: e, translate: t };
|
|
3877
3879
|
}
|
|
3878
|
-
var Ee = /* @__PURE__ */ ((n) => (n.CALENDAR_FOR = "Date.CalendarFor", n.CLOSE = "Generic.Close", n.SPOTLIGHT_DEFAULT_PLACEHOLDER = "Generic.SpotlightDefaultPlaceholder", n.CHECK_OBJECT_WRONG_VALIDATION = "Generic.CheckObjectWrongValidation", n.CONFIRM_BUTTON = "Generic.ConfirmButton", n.AUTOCOMPLETE_DEFAULT_PLACEHOLDER = "Generic.AutocompleteDefaultPlaceholder", n))(Ee || {}),
|
|
3880
|
+
var Ee = /* @__PURE__ */ ((n) => (n.CALENDAR_FOR = "Date.CalendarFor", n.CLOSE = "Generic.Close", n.SPOTLIGHT_DEFAULT_PLACEHOLDER = "Generic.SpotlightDefaultPlaceholder", n.CHECK_OBJECT_WRONG_VALIDATION = "Generic.CheckObjectWrongValidation", n.CONFIRM_BUTTON = "Generic.ConfirmButton", n.AUTOCOMPLETE_DEFAULT_PLACEHOLDER = "Generic.AutocompleteDefaultPlaceholder", n))(Ee || {}), de = /* @__PURE__ */ ((n) => (n.MONDAY = "Day.Monday", n.MONDAY_SHORT = "Day.MondayShort", n.TUESDAY = "Day.Tuesday", n.TUESDAY_SHORT = "Day.TuesdayShort", n.WEDNESDAY = "Day.Wednesday", n.WEDNESDAY_SHORT = "Day.WednesdayShort", n.THURSDAY = "Day.Thursday", n.THURSDAY_SHORT = "Day.ThursdayShort", n.FRIDAY = "Day.Friday", n.FRIDAY_SHORT = "Day.FridayShort", n.SATURDAY = "Day.Saturday", n.SATURDAY_SHORT = "Day.SaturdayShort", n.SUNDAY = "Day.Sunday", n.SUNDAY_SHORT = "Day.SundayShort", n))(de || {}), he = /* @__PURE__ */ ((n) => (n.JANUARY = "Month.January", n.FEBRUARY = "Month.February", n.MARCH = "Month.March", n.APRIL = "Month.April", n.MAY = "Month.May", n.JUNE = "Month.June", n.JULY = "Month.July", n.AUGUST = "Month.August", n.SEPTEMBER = "Month.September", n.OCTOBER = "Month.October", n.NOVEMBER = "Month.November", n.DECEMBER = "Month.December", n))(he || {}), Dt = /* @__PURE__ */ ((n) => (n.PREVIOUS_DAY = "Date.PreviousDay", n.PREVIOUS_WEEK = "Date.PreviousWeek", n.PREVIOUS_MONTH = "Date.PreviousMonth", n.PREVIOUS_YEAR = "Date.PreviousYear", n.NEXT_DAY = "Date.NextDay", n.NEXT_WEEK = "Date.NextWeek", n.NEXT_MONTH = "Date.NextMonth", n.NEXT_YEAR = "Date.NextYear", n.YESTERDAY = "Date.Yesterday", n.TODAY = "Date.Today", n.TOMORROW = "Date.Tomorrow", n))(Dt || {});
|
|
3879
3881
|
const In = ({
|
|
3880
3882
|
bindValue: n,
|
|
3881
3883
|
optionalDisplayValue: e,
|
|
@@ -3887,25 +3889,25 @@ const In = ({
|
|
|
3887
3889
|
fun: i,
|
|
3888
3890
|
_changeOnEnter: l = !1,
|
|
3889
3891
|
onChange: c,
|
|
3890
|
-
onOptionsRequest:
|
|
3892
|
+
onOptionsRequest: f,
|
|
3891
3893
|
onBlur: u,
|
|
3892
|
-
_multiActiveIndex:
|
|
3893
|
-
...
|
|
3894
|
+
_multiActiveIndex: d,
|
|
3895
|
+
...g
|
|
3894
3896
|
}) => {
|
|
3895
|
-
const p = le(null), [w, S] = G(n), [E, b] = G(e), { translate: T } = $e(), [v,
|
|
3897
|
+
const p = le(null), [w, S] = G(n), [E, b] = G(e), { translate: T } = $e(), [v, y] = G(!1), [k, A] = G(t || []), [O, L] = G(0), [R, D] = G([n]), { anchorRef: C, targetRef: P, anchorWidth: N } = dt({
|
|
3896
3898
|
position: "bottom",
|
|
3897
3899
|
enabled: v
|
|
3898
3900
|
}), B = ue(() => {
|
|
3899
|
-
|
|
3901
|
+
y(!1), p?.current?.focus();
|
|
3900
3902
|
}, []);
|
|
3901
3903
|
ht([P], v, () => B());
|
|
3902
3904
|
const H = Or(400), z = (_) => {
|
|
3903
3905
|
_.length >= a ? X(_) : B(), S(_), b(e), l || c?.(_, e);
|
|
3904
3906
|
}, X = (_) => {
|
|
3905
3907
|
H(async () => {
|
|
3906
|
-
if (i &&
|
|
3907
|
-
const j = await
|
|
3908
|
-
A(j), L(j.length > 0 ? 0 : -1),
|
|
3908
|
+
if (i && f) {
|
|
3909
|
+
const j = await f(i, _);
|
|
3910
|
+
A(j), L(j.length > 0 ? 0 : -1), y(!0);
|
|
3909
3911
|
}
|
|
3910
3912
|
});
|
|
3911
3913
|
}, F = () => {
|
|
@@ -3934,7 +3936,7 @@ const In = ({
|
|
|
3934
3936
|
/* @__PURE__ */ m.jsx(
|
|
3935
3937
|
At,
|
|
3936
3938
|
{
|
|
3937
|
-
...
|
|
3939
|
+
...g,
|
|
3938
3940
|
bindValue: w,
|
|
3939
3941
|
optionalDisplayValue: E,
|
|
3940
3942
|
displayMode: r,
|
|
@@ -3960,7 +3962,7 @@ const In = ({
|
|
|
3960
3962
|
onClick: h,
|
|
3961
3963
|
ref: P,
|
|
3962
3964
|
selectedIndex: O,
|
|
3963
|
-
activeIndex:
|
|
3965
|
+
activeIndex: d || R,
|
|
3964
3966
|
width: N,
|
|
3965
3967
|
showFilter: !1,
|
|
3966
3968
|
onKeyDown: x,
|
|
@@ -3979,10 +3981,10 @@ const In = ({
|
|
|
3979
3981
|
showText: i,
|
|
3980
3982
|
showIcon: l,
|
|
3981
3983
|
fullWidth: c,
|
|
3982
|
-
disabled:
|
|
3984
|
+
disabled: f,
|
|
3983
3985
|
justify: u,
|
|
3984
|
-
squared:
|
|
3985
|
-
onClick:
|
|
3986
|
+
squared: d,
|
|
3987
|
+
onClick: g,
|
|
3986
3988
|
onOptionsRequest: p
|
|
3987
3989
|
}) => {
|
|
3988
3990
|
const [w, S] = G(n);
|
|
@@ -3997,7 +3999,7 @@ const In = ({
|
|
|
3997
3999
|
const E = {
|
|
3998
4000
|
container: `smp-button-list smp-button-list-${t} smp-justifyContent-${r}`
|
|
3999
4001
|
}, b = w?.map((T, v) => {
|
|
4000
|
-
const
|
|
4002
|
+
const y = {
|
|
4001
4003
|
bindValue: T.id,
|
|
4002
4004
|
optionalDisplayValue: T.label,
|
|
4003
4005
|
fun: T.fun,
|
|
@@ -4007,20 +4009,20 @@ const In = ({
|
|
|
4007
4009
|
showText: i,
|
|
4008
4010
|
showIcon: l,
|
|
4009
4011
|
fullWidth: c,
|
|
4010
|
-
disabled:
|
|
4012
|
+
disabled: f,
|
|
4011
4013
|
sizing: s,
|
|
4012
4014
|
justify: u,
|
|
4013
|
-
squared:
|
|
4015
|
+
squared: d,
|
|
4014
4016
|
onClick: () => {
|
|
4015
|
-
|
|
4017
|
+
g?.(T.id, T.fun);
|
|
4016
4018
|
}
|
|
4017
4019
|
};
|
|
4018
|
-
return /* @__PURE__ */ m.jsx(we, { ...
|
|
4020
|
+
return /* @__PURE__ */ m.jsx(we, { ...y }, `button-${v}`);
|
|
4019
4021
|
});
|
|
4020
4022
|
return /* @__PURE__ */ m.jsx("div", { role: "list", "data-component": "button-list", className: E.container, children: b });
|
|
4021
|
-
},
|
|
4023
|
+
}, fs = {
|
|
4022
4024
|
"smp-checkbox-wrapper": "_smp-checkbox-wrapper_z14lq_2"
|
|
4023
|
-
},
|
|
4025
|
+
}, ds = ({
|
|
4024
4026
|
bindValue: n,
|
|
4025
4027
|
_dataComponent: e = "checkbox",
|
|
4026
4028
|
disabled: t,
|
|
@@ -4032,10 +4034,10 @@ const In = ({
|
|
|
4032
4034
|
}) => {
|
|
4033
4035
|
const l = Ce(), c = (u) => {
|
|
4034
4036
|
s && a && a(u.target.checked);
|
|
4035
|
-
},
|
|
4036
|
-
wrapper: `${
|
|
4037
|
+
}, f = {
|
|
4038
|
+
wrapper: `${fs["smp-checkbox-wrapper"]}`
|
|
4037
4039
|
};
|
|
4038
|
-
return /* @__PURE__ */ m.jsxs("div", { className:
|
|
4040
|
+
return /* @__PURE__ */ m.jsxs("div", { className: f.wrapper, "data-component": e, children: [
|
|
4039
4041
|
r && /* @__PURE__ */ m.jsx(De, { label: r, disabled: t, htmlFor: l }),
|
|
4040
4042
|
/* @__PURE__ */ m.jsx(
|
|
4041
4043
|
"input",
|
|
@@ -4062,19 +4064,19 @@ const In = ({
|
|
|
4062
4064
|
const [i, l] = G(null), c = {
|
|
4063
4065
|
container: `${["smp-chips-container"]}`,
|
|
4064
4066
|
element: "smp-chips-element"
|
|
4065
|
-
},
|
|
4066
|
-
r?.(n.filter((p, w) => w !==
|
|
4067
|
-
}, u = (
|
|
4068
|
-
l(
|
|
4069
|
-
},
|
|
4070
|
-
if (i === null || i ===
|
|
4067
|
+
}, f = (g) => {
|
|
4068
|
+
r?.(n.filter((p, w) => w !== g));
|
|
4069
|
+
}, u = (g) => {
|
|
4070
|
+
l(g);
|
|
4071
|
+
}, d = (g) => {
|
|
4072
|
+
if (i === null || i === g) return;
|
|
4071
4073
|
const p = [...n], [w] = p.splice(i, 1);
|
|
4072
|
-
p.splice(
|
|
4074
|
+
p.splice(g, 0, w), r?.(p), l(null);
|
|
4073
4075
|
};
|
|
4074
|
-
return /* @__PURE__ */ m.jsx("div", { className: c.container, role: "list", "data-component": "chip", children: n.flatMap((
|
|
4076
|
+
return /* @__PURE__ */ m.jsx("div", { className: c.container, role: "list", "data-component": "chip", children: n.flatMap((g, p) => {
|
|
4075
4077
|
const w = _e(
|
|
4076
|
-
|
|
4077
|
-
|
|
4078
|
+
g.bindValue,
|
|
4079
|
+
g.optionalDisplayValue,
|
|
4078
4080
|
t
|
|
4079
4081
|
), S = /* @__PURE__ */ m.jsxs(
|
|
4080
4082
|
"div",
|
|
@@ -4084,19 +4086,19 @@ const In = ({
|
|
|
4084
4086
|
draggable: o,
|
|
4085
4087
|
onDragStart: () => u(p),
|
|
4086
4088
|
onDragOver: (b) => o && b.preventDefault(),
|
|
4087
|
-
onDrop: () => o &&
|
|
4089
|
+
onDrop: () => o && d(p),
|
|
4088
4090
|
style: {
|
|
4089
4091
|
"--smp-chips-backgroundColor-base": a
|
|
4090
4092
|
},
|
|
4091
4093
|
children: [
|
|
4092
|
-
o && /* @__PURE__ */ m.jsx(
|
|
4094
|
+
o && /* @__PURE__ */ m.jsx(fe, { icon: "drag_indicator_horizontal", isInteractable: !0 }),
|
|
4093
4095
|
/* @__PURE__ */ m.jsx(Oe, { variant: "label", bindValue: w, color: s }),
|
|
4094
4096
|
e && /* @__PURE__ */ m.jsx(
|
|
4095
|
-
|
|
4097
|
+
fe,
|
|
4096
4098
|
{
|
|
4097
4099
|
icon: "close",
|
|
4098
4100
|
isInteractable: !0,
|
|
4099
|
-
onClick: () =>
|
|
4101
|
+
onClick: () => f(p),
|
|
4100
4102
|
color: s
|
|
4101
4103
|
}
|
|
4102
4104
|
)
|
|
@@ -4104,7 +4106,7 @@ const In = ({
|
|
|
4104
4106
|
},
|
|
4105
4107
|
`chip-${p}`
|
|
4106
4108
|
), E = o && p < n.length - 1 ? /* @__PURE__ */ m.jsx(
|
|
4107
|
-
|
|
4109
|
+
fe,
|
|
4108
4110
|
{
|
|
4109
4111
|
icon: "chevron-right",
|
|
4110
4112
|
color: s
|
|
@@ -4132,15 +4134,15 @@ function It(n, e) {
|
|
|
4132
4134
|
})();
|
|
4133
4135
|
const o = (c) => {
|
|
4134
4136
|
if (c.key === "Escape" || c.key !== "Tab") return;
|
|
4135
|
-
const
|
|
4136
|
-
if (
|
|
4137
|
-
const u =
|
|
4138
|
-
c.shiftKey && document.activeElement === u ? (c.preventDefault(),
|
|
4137
|
+
const f = s();
|
|
4138
|
+
if (f.length === 0) return;
|
|
4139
|
+
const u = f[0], d = f[f.length - 1];
|
|
4140
|
+
c.shiftKey && document.activeElement === u ? (c.preventDefault(), d.focus()) : !c.shiftKey && document.activeElement === d && (c.preventDefault(), u.focus());
|
|
4139
4141
|
}, i = (c) => {
|
|
4140
4142
|
if (r && !r.contains(c.target)) {
|
|
4141
4143
|
c.preventDefault();
|
|
4142
|
-
const
|
|
4143
|
-
|
|
4144
|
+
const f = s();
|
|
4145
|
+
f.length > 0 && f[0].focus();
|
|
4144
4146
|
}
|
|
4145
4147
|
};
|
|
4146
4148
|
document.addEventListener("keydown", o), document.addEventListener("mousedown", i);
|
|
@@ -4163,15 +4165,15 @@ const ps = ({
|
|
|
4163
4165
|
fun: i,
|
|
4164
4166
|
onOptionsRequest: l,
|
|
4165
4167
|
multiActiveIndex: c,
|
|
4166
|
-
...
|
|
4168
|
+
...f
|
|
4167
4169
|
}) => {
|
|
4168
|
-
const u = le(null), [
|
|
4170
|
+
const u = le(null), [d, g] = G(!1), [p, w] = G(t), [S, E] = G(-1), [b, T] = G([n]), v = Ce(), { anchorRef: y, targetRef: k, anchorWidth: A } = dt({
|
|
4169
4171
|
position: "bottom",
|
|
4170
|
-
enabled:
|
|
4172
|
+
enabled: d
|
|
4171
4173
|
}), O = ue(() => {
|
|
4172
|
-
|
|
4174
|
+
g(!1), u?.current?.focus();
|
|
4173
4175
|
}, []);
|
|
4174
|
-
ht([k,
|
|
4176
|
+
ht([k, y], d, () => O()), It(d, k);
|
|
4175
4177
|
const L = (P) => {
|
|
4176
4178
|
e?.(P.id, P.label);
|
|
4177
4179
|
const N = p.findIndex((B) => B.id === P.id);
|
|
@@ -4181,15 +4183,15 @@ const ps = ({
|
|
|
4181
4183
|
}, D = (P) => {
|
|
4182
4184
|
(P.key === "ArrowDown" || P.key === "ArrowUp") && (P.preventDefault(), C());
|
|
4183
4185
|
}, C = () => {
|
|
4184
|
-
s && (i && l ?
|
|
4185
|
-
w(P), E(P.length > 0 ? 0 : -1),
|
|
4186
|
-
}) :
|
|
4186
|
+
s && (i && l ? d ? g(!1) : l(i, void 0).then((P) => {
|
|
4187
|
+
w(P), E(P.length > 0 ? 0 : -1), g(!0);
|
|
4188
|
+
}) : g((P) => !P));
|
|
4187
4189
|
};
|
|
4188
4190
|
return /* @__PURE__ */ m.jsxs(
|
|
4189
4191
|
"div",
|
|
4190
4192
|
{
|
|
4191
4193
|
role: "combobox",
|
|
4192
|
-
"aria-expanded":
|
|
4194
|
+
"aria-expanded": d,
|
|
4193
4195
|
"aria-controls": v,
|
|
4194
4196
|
"aria-owns": v,
|
|
4195
4197
|
"data-component": "combobox",
|
|
@@ -4197,7 +4199,7 @@ const ps = ({
|
|
|
4197
4199
|
/* @__PURE__ */ m.jsx(
|
|
4198
4200
|
At,
|
|
4199
4201
|
{
|
|
4200
|
-
...
|
|
4202
|
+
...f,
|
|
4201
4203
|
bindValue: n,
|
|
4202
4204
|
optionalDisplayValue: r,
|
|
4203
4205
|
displayMode: a,
|
|
@@ -4205,22 +4207,22 @@ const ps = ({
|
|
|
4205
4207
|
onKeyDown: D,
|
|
4206
4208
|
onClick: C,
|
|
4207
4209
|
shapeIcon: "arrow_drop_down",
|
|
4208
|
-
rotatedShapeIcon:
|
|
4210
|
+
rotatedShapeIcon: d,
|
|
4209
4211
|
isEditable: s,
|
|
4210
|
-
ref:
|
|
4212
|
+
ref: y,
|
|
4211
4213
|
inputRef: u,
|
|
4212
4214
|
"aria-autocomplete": "list",
|
|
4213
4215
|
variant: "notSelectable"
|
|
4214
4216
|
}
|
|
4215
4217
|
),
|
|
4216
|
-
|
|
4218
|
+
d && /* @__PURE__ */ m.jsx(pt, { children: /* @__PURE__ */ m.jsx(
|
|
4217
4219
|
Ln,
|
|
4218
4220
|
{
|
|
4219
4221
|
id: v,
|
|
4220
4222
|
options: p,
|
|
4221
4223
|
displayMode: o,
|
|
4222
4224
|
ref: k,
|
|
4223
|
-
isOpen:
|
|
4225
|
+
isOpen: d,
|
|
4224
4226
|
selectedIndex: S,
|
|
4225
4227
|
activeIndex: c || b,
|
|
4226
4228
|
width: A,
|
|
@@ -4247,9 +4249,9 @@ function ms({
|
|
|
4247
4249
|
return isNaN(F.getTime()) ? void 0 : F;
|
|
4248
4250
|
}, [i] = G(/* @__PURE__ */ new Date()), [l, c] = G(
|
|
4249
4251
|
n || o() || /* @__PURE__ */ new Date()
|
|
4250
|
-
), [
|
|
4252
|
+
), [f, u] = G(
|
|
4251
4253
|
l ? l.getMonth() : (/* @__PURE__ */ new Date()).getMonth()
|
|
4252
|
-
), [
|
|
4254
|
+
), [d, g] = G(
|
|
4253
4255
|
l ? l.getFullYear() : (/* @__PURE__ */ new Date()).getFullYear()
|
|
4254
4256
|
), [p, w] = G(
|
|
4255
4257
|
l ? l.getDate() : null
|
|
@@ -4268,42 +4270,42 @@ function ms({
|
|
|
4268
4270
|
a(he.DECEMBER)
|
|
4269
4271
|
], T = [
|
|
4270
4272
|
{
|
|
4271
|
-
value: a(
|
|
4272
|
-
full: a(
|
|
4273
|
+
value: a(de.SUNDAY_SHORT),
|
|
4274
|
+
full: a(de.SUNDAY)
|
|
4273
4275
|
},
|
|
4274
4276
|
{
|
|
4275
|
-
value: a(
|
|
4276
|
-
full: a(
|
|
4277
|
+
value: a(de.MONDAY_SHORT),
|
|
4278
|
+
full: a(de.MONDAY)
|
|
4277
4279
|
},
|
|
4278
4280
|
{
|
|
4279
|
-
value: a(
|
|
4280
|
-
full: a(
|
|
4281
|
+
value: a(de.TUESDAY_SHORT),
|
|
4282
|
+
full: a(de.TUESDAY)
|
|
4281
4283
|
},
|
|
4282
4284
|
{
|
|
4283
|
-
value: a(
|
|
4284
|
-
full: a(
|
|
4285
|
+
value: a(de.WEDNESDAY_SHORT),
|
|
4286
|
+
full: a(de.WEDNESDAY)
|
|
4285
4287
|
},
|
|
4286
4288
|
{
|
|
4287
|
-
value: a(
|
|
4288
|
-
full: a(
|
|
4289
|
+
value: a(de.THURSDAY_SHORT),
|
|
4290
|
+
full: a(de.THURSDAY)
|
|
4289
4291
|
},
|
|
4290
4292
|
{
|
|
4291
|
-
value: a(
|
|
4292
|
-
full: a(
|
|
4293
|
+
value: a(de.FRIDAY_SHORT),
|
|
4294
|
+
full: a(de.FRIDAY)
|
|
4293
4295
|
},
|
|
4294
4296
|
{
|
|
4295
|
-
value: a(
|
|
4296
|
-
full: a(
|
|
4297
|
+
value: a(de.SATURDAY_SHORT),
|
|
4298
|
+
full: a(de.SATURDAY)
|
|
4297
4299
|
}
|
|
4298
4300
|
], v = (F) => t.some((h) => {
|
|
4299
4301
|
const x = h.start.getTime(), $ = h.end.getTime(), _ = F.getTime();
|
|
4300
4302
|
return _ >= x && _ <= $;
|
|
4301
|
-
}),
|
|
4303
|
+
}), y = (F) => {
|
|
4302
4304
|
v(F) || (c(F), w(F.getDate()), e && e(Er(F)));
|
|
4303
4305
|
}, k = () => {
|
|
4304
|
-
|
|
4306
|
+
f === 0 ? (u(11), g(d - 1)) : u(f - 1), w(1);
|
|
4305
4307
|
}, A = () => {
|
|
4306
|
-
|
|
4308
|
+
f === 11 ? (u(0), g(d + 1)) : u(f + 1), w(1);
|
|
4307
4309
|
}, O = (F, h) => new Date(F, h + 1, 0).getDate(), L = (F, h) => new Date(F, h, 1).getDay(), R = (F) => {
|
|
4308
4310
|
const h = N.findIndex(
|
|
4309
4311
|
(x) => x !== null && x.getDate() === F
|
|
@@ -4312,14 +4314,14 @@ function ms({
|
|
|
4312
4314
|
}, D = (F, h) => {
|
|
4313
4315
|
const x = N[h];
|
|
4314
4316
|
if (!x) return;
|
|
4315
|
-
const $ = O(
|
|
4317
|
+
const $ = O(d, f), _ = x.getDate();
|
|
4316
4318
|
switch (F.key) {
|
|
4317
4319
|
case "ArrowRight":
|
|
4318
4320
|
F.preventDefault();
|
|
4319
4321
|
{
|
|
4320
|
-
let j = _ + 1, I = new Date(
|
|
4322
|
+
let j = _ + 1, I = new Date(d, f, j);
|
|
4321
4323
|
if (j > $) {
|
|
4322
|
-
const U =
|
|
4324
|
+
const U = f === 11 ? d + 1 : d, W = f === 11 ? 0 : f + 1;
|
|
4323
4325
|
j = 1, I = new Date(U, W, j), A(), setTimeout(() => {
|
|
4324
4326
|
C(1, "forward");
|
|
4325
4327
|
}, 0);
|
|
@@ -4333,9 +4335,9 @@ function ms({
|
|
|
4333
4335
|
case "ArrowLeft":
|
|
4334
4336
|
F.preventDefault();
|
|
4335
4337
|
{
|
|
4336
|
-
let j = _ - 1, I = new Date(
|
|
4338
|
+
let j = _ - 1, I = new Date(d, f, j);
|
|
4337
4339
|
if (j < 1) {
|
|
4338
|
-
const U =
|
|
4340
|
+
const U = f === 0 ? d - 1 : d, W = f === 0 ? 11 : f - 1, V = O(U, W);
|
|
4339
4341
|
j = V, I = new Date(U, W, j), k(), setTimeout(() => {
|
|
4340
4342
|
C(V, "backward");
|
|
4341
4343
|
}, 0);
|
|
@@ -4347,9 +4349,9 @@ function ms({
|
|
|
4347
4349
|
case "ArrowUp":
|
|
4348
4350
|
F.preventDefault();
|
|
4349
4351
|
{
|
|
4350
|
-
let j = _ - 7, I = new Date(
|
|
4352
|
+
let j = _ - 7, I = new Date(d, f, j);
|
|
4351
4353
|
if (j < 1) {
|
|
4352
|
-
const U =
|
|
4354
|
+
const U = f === 0 ? d - 1 : d, W = f === 0 ? 11 : f - 1;
|
|
4353
4355
|
j = O(U, W) + j, I = new Date(U, W, j), k(), setTimeout(() => {
|
|
4354
4356
|
C(j, "backward");
|
|
4355
4357
|
}, 0);
|
|
@@ -4361,9 +4363,9 @@ function ms({
|
|
|
4361
4363
|
case "ArrowDown":
|
|
4362
4364
|
F.preventDefault();
|
|
4363
4365
|
{
|
|
4364
|
-
let j = _ + 7, I = new Date(
|
|
4366
|
+
let j = _ + 7, I = new Date(d, f, j);
|
|
4365
4367
|
if (j > $) {
|
|
4366
|
-
const U =
|
|
4368
|
+
const U = f === 11 ? d + 1 : d, W = f === 11 ? 0 : f + 1;
|
|
4367
4369
|
j = j - $, I = new Date(U, W, j), A(), setTimeout(() => {
|
|
4368
4370
|
C(j, "forward");
|
|
4369
4371
|
}, 0);
|
|
@@ -4381,8 +4383,8 @@ function ms({
|
|
|
4381
4383
|
case "PageUp":
|
|
4382
4384
|
F.preventDefault(), k(), setTimeout(() => {
|
|
4383
4385
|
const j = O(
|
|
4384
|
-
|
|
4385
|
-
|
|
4386
|
+
f === 0 ? d - 1 : d,
|
|
4387
|
+
f === 0 ? 11 : f - 1
|
|
4386
4388
|
), I = Math.min(_, j);
|
|
4387
4389
|
C(I, "forward");
|
|
4388
4390
|
}, 0);
|
|
@@ -4390,8 +4392,8 @@ function ms({
|
|
|
4390
4392
|
case "PageDown":
|
|
4391
4393
|
F.preventDefault(), A(), setTimeout(() => {
|
|
4392
4394
|
const j = O(
|
|
4393
|
-
|
|
4394
|
-
|
|
4395
|
+
f === 11 ? d + 1 : d,
|
|
4396
|
+
f === 11 ? 0 : f + 1
|
|
4395
4397
|
), I = Math.min(_, j);
|
|
4396
4398
|
C(I, "forward");
|
|
4397
4399
|
}, 0);
|
|
@@ -4402,14 +4404,14 @@ function ms({
|
|
|
4402
4404
|
w(x.getDate()), c(x);
|
|
4403
4405
|
break;
|
|
4404
4406
|
case "Enter":
|
|
4405
|
-
F.preventDefault(),
|
|
4407
|
+
F.preventDefault(), y(x);
|
|
4406
4408
|
break;
|
|
4407
4409
|
}
|
|
4408
4410
|
}, C = (F, h) => {
|
|
4409
|
-
const x = O(
|
|
4411
|
+
const x = O(d, f);
|
|
4410
4412
|
if (h === "forward") {
|
|
4411
4413
|
for (let $ = F; $ <= x; $++) {
|
|
4412
|
-
const _ = new Date(
|
|
4414
|
+
const _ = new Date(d, f, $);
|
|
4413
4415
|
if (!v(_)) {
|
|
4414
4416
|
R($);
|
|
4415
4417
|
return;
|
|
@@ -4420,23 +4422,23 @@ function ms({
|
|
|
4420
4422
|
}, 0);
|
|
4421
4423
|
} else {
|
|
4422
4424
|
for (let I = F; I >= 1; I--) {
|
|
4423
|
-
const U = new Date(
|
|
4425
|
+
const U = new Date(d, f, I);
|
|
4424
4426
|
if (!v(U)) {
|
|
4425
4427
|
R(I);
|
|
4426
4428
|
return;
|
|
4427
4429
|
}
|
|
4428
4430
|
}
|
|
4429
|
-
const $ =
|
|
4431
|
+
const $ = f === 0 ? d - 1 : d, _ = f === 0 ? 11 : f - 1, j = O($, _);
|
|
4430
4432
|
k(), setTimeout(() => {
|
|
4431
4433
|
C(j, "backward");
|
|
4432
4434
|
}, 0);
|
|
4433
4435
|
}
|
|
4434
4436
|
}, N = (() => {
|
|
4435
|
-
const F = O(
|
|
4437
|
+
const F = O(d, f), h = L(d, f), x = [];
|
|
4436
4438
|
for (let $ = 0; $ < h; $++)
|
|
4437
4439
|
x.push(null);
|
|
4438
4440
|
for (let $ = 1; $ <= F; $++) {
|
|
4439
|
-
const _ = new Date(
|
|
4441
|
+
const _ = new Date(d, f, $);
|
|
4440
4442
|
x.push(_);
|
|
4441
4443
|
}
|
|
4442
4444
|
return x;
|
|
@@ -4455,7 +4457,7 @@ function ms({
|
|
|
4455
4457
|
);
|
|
4456
4458
|
F !== -1 && E.current[F] && E.current[F]?.focus();
|
|
4457
4459
|
}
|
|
4458
|
-
}, [
|
|
4460
|
+
}, [f, d, p, N]);
|
|
4459
4461
|
const z = {
|
|
4460
4462
|
label: "smp-datepickercalendar-label",
|
|
4461
4463
|
wrapper: `smp-datepickercalendar ${hs["smp-datepickercalendar-position"]}`,
|
|
@@ -4467,7 +4469,7 @@ function ms({
|
|
|
4467
4469
|
${h ? "smp-datepickercalendar-td-selected" : ""}
|
|
4468
4470
|
${x ? "smp-datepickercalendar-td-focused" : ""}
|
|
4469
4471
|
${$ ? "smp-datepickercalendar-td-disabled" : ""}`
|
|
4470
|
-
}, X = () => `${b[
|
|
4472
|
+
}, X = () => `${b[f]} ${d.toString()}`;
|
|
4471
4473
|
return /* @__PURE__ */ m.jsxs(
|
|
4472
4474
|
"div",
|
|
4473
4475
|
{
|
|
@@ -4526,7 +4528,7 @@ function ms({
|
|
|
4526
4528
|
{
|
|
4527
4529
|
ref: S,
|
|
4528
4530
|
role: "grid",
|
|
4529
|
-
"aria-label": `${a(Ee.CALENDAR_FOR)} ${b[
|
|
4531
|
+
"aria-label": `${a(Ee.CALENDAR_FOR)} ${b[f]} ${d}`,
|
|
4530
4532
|
className: z.table,
|
|
4531
4533
|
children: [
|
|
4532
4534
|
/* @__PURE__ */ m.jsx("thead", { children: /* @__PURE__ */ m.jsx("tr", { children: T.map((F) => /* @__PURE__ */ m.jsx(
|
|
@@ -4561,7 +4563,7 @@ function ms({
|
|
|
4561
4563
|
role: "gridcell",
|
|
4562
4564
|
"aria-selected": I,
|
|
4563
4565
|
tabIndex: U ? 0 : -1,
|
|
4564
|
-
onClick: () =>
|
|
4566
|
+
onClick: () => y(x),
|
|
4565
4567
|
onKeyDown: (V) => D(V, _),
|
|
4566
4568
|
"aria-label": `${x.getDate()} ${b[x.getMonth()]} ${x.getFullYear()}`,
|
|
4567
4569
|
"data-selected": I,
|
|
@@ -4595,13 +4597,13 @@ const gs = ({
|
|
|
4595
4597
|
isEditable: s = !0,
|
|
4596
4598
|
...a
|
|
4597
4599
|
}) => {
|
|
4598
|
-
const o = le(null), [i, l] = G(!1), [c,
|
|
4600
|
+
const o = le(null), [i, l] = G(!1), [c, f] = G(n || ""), [u, d] = G(""), { anchorRef: g, targetRef: p } = dt({
|
|
4599
4601
|
position: "bottom",
|
|
4600
4602
|
enabled: i
|
|
4601
4603
|
}), w = ue(() => {
|
|
4602
4604
|
l(!1), o?.current?.focus();
|
|
4603
4605
|
}, []);
|
|
4604
|
-
ht([p,
|
|
4606
|
+
ht([p, g], i, () => {
|
|
4605
4607
|
w();
|
|
4606
4608
|
}), It(i, p);
|
|
4607
4609
|
const { format: S, getCurrentLanguage: E } = $e(), b = ue(
|
|
@@ -4620,17 +4622,17 @@ const gs = ({
|
|
|
4620
4622
|
);
|
|
4621
4623
|
ne(() => {
|
|
4622
4624
|
const { formattedDate: L, isoDate: R, isValid: D } = b(n);
|
|
4623
|
-
|
|
4625
|
+
f(D && R || n), d(D && L || n);
|
|
4624
4626
|
}, [n, S, b]);
|
|
4625
4627
|
const T = () => l((L) => !L), v = () => {
|
|
4626
4628
|
k(u);
|
|
4627
|
-
},
|
|
4629
|
+
}, y = (L) => {
|
|
4628
4630
|
k(L), w();
|
|
4629
4631
|
}, k = (L) => {
|
|
4630
4632
|
const { isoDate: R, isValid: D } = b(L);
|
|
4631
4633
|
t && t(D && R || L);
|
|
4632
4634
|
}, A = (L) => {
|
|
4633
|
-
|
|
4635
|
+
d(L);
|
|
4634
4636
|
}, O = (L) => {
|
|
4635
4637
|
L.key === "Enter" && (L.preventDefault(), k(u));
|
|
4636
4638
|
};
|
|
@@ -4646,7 +4648,7 @@ const gs = ({
|
|
|
4646
4648
|
onKeyDown: O,
|
|
4647
4649
|
shapeIcon: "calendar",
|
|
4648
4650
|
onShapeIconClick: T,
|
|
4649
|
-
ref:
|
|
4651
|
+
ref: g,
|
|
4650
4652
|
inputRef: o,
|
|
4651
4653
|
isEditable: s,
|
|
4652
4654
|
size: 10,
|
|
@@ -4657,7 +4659,7 @@ const gs = ({
|
|
|
4657
4659
|
ms,
|
|
4658
4660
|
{
|
|
4659
4661
|
disabledDateRanges: r,
|
|
4660
|
-
onDateChange:
|
|
4662
|
+
onDateChange: y,
|
|
4661
4663
|
initialValue: Lt(c) && c || "",
|
|
4662
4664
|
targetRef: p
|
|
4663
4665
|
}
|
|
@@ -4674,10 +4676,10 @@ const gs = ({
|
|
|
4674
4676
|
disabled: i,
|
|
4675
4677
|
fun: l,
|
|
4676
4678
|
error: c,
|
|
4677
|
-
onOptionsRequest:
|
|
4679
|
+
onOptionsRequest: f,
|
|
4678
4680
|
onChange: u,
|
|
4679
|
-
onBlur:
|
|
4680
|
-
...
|
|
4681
|
+
onBlur: d,
|
|
4682
|
+
...g
|
|
4681
4683
|
}) => {
|
|
4682
4684
|
const p = n.map((E) => E.bindValue), w = (E, b) => {
|
|
4683
4685
|
const T = [...n];
|
|
@@ -4685,7 +4687,7 @@ const gs = ({
|
|
|
4685
4687
|
T.pop();
|
|
4686
4688
|
else {
|
|
4687
4689
|
const v = T.findIndex(
|
|
4688
|
-
(
|
|
4690
|
+
(y) => y.bindValue === E && y.optionalDisplayValue === b
|
|
4689
4691
|
);
|
|
4690
4692
|
v >= 0 ? T.splice(v, 1) : T.push({
|
|
4691
4693
|
bindValue: E,
|
|
@@ -4717,7 +4719,7 @@ const gs = ({
|
|
|
4717
4719
|
/* @__PURE__ */ m.jsx(
|
|
4718
4720
|
In,
|
|
4719
4721
|
{
|
|
4720
|
-
...
|
|
4722
|
+
...g,
|
|
4721
4723
|
bindValue: "",
|
|
4722
4724
|
fun: l,
|
|
4723
4725
|
isEditable: s,
|
|
@@ -4726,10 +4728,10 @@ const gs = ({
|
|
|
4726
4728
|
listDisplayMode: r,
|
|
4727
4729
|
minimumChars: t,
|
|
4728
4730
|
placeholder: a,
|
|
4729
|
-
onOptionsRequest:
|
|
4731
|
+
onOptionsRequest: f,
|
|
4730
4732
|
_multiActiveIndex: p,
|
|
4731
4733
|
error: c,
|
|
4732
|
-
onBlur:
|
|
4734
|
+
onBlur: d
|
|
4733
4735
|
}
|
|
4734
4736
|
)
|
|
4735
4737
|
]
|
|
@@ -4863,7 +4865,7 @@ const Ne = (n, e, t) => ({
|
|
|
4863
4865
|
onEnter: i,
|
|
4864
4866
|
...l
|
|
4865
4867
|
}) => {
|
|
4866
|
-
const { getCurrentLanguage: c } = $e(),
|
|
4868
|
+
const { getCurrentLanguage: c } = $e(), f = le(null), u = c(), { groupingChar: d, decimalChar: g } = Vn(
|
|
4867
4869
|
() => ns(u, s),
|
|
4868
4870
|
[u, s]
|
|
4869
4871
|
), p = ue(
|
|
@@ -4873,45 +4875,45 @@ const Ne = (n, e, t) => ({
|
|
|
4873
4875
|
useGrouping: !0
|
|
4874
4876
|
}).format(C),
|
|
4875
4877
|
[u]
|
|
4876
|
-
), w = ue(as, [
|
|
4878
|
+
), w = ue(as, [d, g]), S = ue(ts, [n, e]), E = a != null && a.toString().includes(".") ? a.toString().split(".")[1].length : 0, [b, T] = G(E), [v, y] = G(
|
|
4877
4879
|
a != null ? p(a, b) : ""
|
|
4878
4880
|
), k = le(a ?? null);
|
|
4879
4881
|
ne(() => {
|
|
4880
4882
|
if (a == null) {
|
|
4881
|
-
|
|
4883
|
+
y(""), k.current = null;
|
|
4882
4884
|
return;
|
|
4883
4885
|
}
|
|
4884
4886
|
const C = a.toString().includes(".") ? a.toString().split(".")[1].length : 0, P = C === 0 ? b : C;
|
|
4885
|
-
P !== b && T(P),
|
|
4887
|
+
P !== b && T(P), y(p(a, P)), k.current = a;
|
|
4886
4888
|
}, [a, p]);
|
|
4887
4889
|
const A = ue(
|
|
4888
4890
|
(C, P = !1) => {
|
|
4889
4891
|
if (C.trim() === "") {
|
|
4890
|
-
|
|
4892
|
+
y(""), k.current = null, o?.(void 0, ""), P && i?.(void 0);
|
|
4891
4893
|
return;
|
|
4892
4894
|
}
|
|
4893
|
-
const N = w(C,
|
|
4895
|
+
const N = w(C, d, g);
|
|
4894
4896
|
if (isNaN(N))
|
|
4895
4897
|
if (k.current != null) {
|
|
4896
4898
|
const B = p(k.current, b);
|
|
4897
|
-
|
|
4899
|
+
y(B);
|
|
4898
4900
|
} else
|
|
4899
|
-
|
|
4901
|
+
y("");
|
|
4900
4902
|
else {
|
|
4901
4903
|
const B = S(N, n, e), H = ss(
|
|
4902
4904
|
C,
|
|
4903
|
-
|
|
4904
|
-
|
|
4905
|
+
d,
|
|
4906
|
+
g
|
|
4905
4907
|
);
|
|
4906
4908
|
T(H);
|
|
4907
4909
|
const z = p(B, H);
|
|
4908
|
-
|
|
4910
|
+
y(z), k.current = B, o?.(B, z), P && i?.(B);
|
|
4909
4911
|
}
|
|
4910
4912
|
},
|
|
4911
4913
|
[
|
|
4912
4914
|
w,
|
|
4913
|
-
|
|
4914
|
-
|
|
4915
|
+
d,
|
|
4916
|
+
g,
|
|
4915
4917
|
S,
|
|
4916
4918
|
n,
|
|
4917
4919
|
e,
|
|
@@ -4920,7 +4922,7 @@ const Ne = (n, e, t) => ({
|
|
|
4920
4922
|
i,
|
|
4921
4923
|
b
|
|
4922
4924
|
]
|
|
4923
|
-
), O = (C) =>
|
|
4925
|
+
), O = (C) => y(C), L = () => A(v), R = (C) => {
|
|
4924
4926
|
if (C.key === "Enter") {
|
|
4925
4927
|
C.preventDefault(), A(v, !0);
|
|
4926
4928
|
return;
|
|
@@ -4936,7 +4938,7 @@ const Ne = (n, e, t) => ({
|
|
|
4936
4938
|
const P = C.deltaY < 0 ? 1 : -1, N = k.current ?? 0, B = S(N + P * t, n, e);
|
|
4937
4939
|
A(p(B, b));
|
|
4938
4940
|
};
|
|
4939
|
-
return /* @__PURE__ */ m.jsx("div", { ref:
|
|
4941
|
+
return /* @__PURE__ */ m.jsx("div", { ref: f, "data-component": "input-number", onWheel: D, children: /* @__PURE__ */ m.jsx(
|
|
4940
4942
|
je,
|
|
4941
4943
|
{
|
|
4942
4944
|
...l,
|
|
@@ -5009,14 +5011,14 @@ const Ts = ({
|
|
|
5009
5011
|
label: i,
|
|
5010
5012
|
ariaLabel: l,
|
|
5011
5013
|
helperText: c,
|
|
5012
|
-
error:
|
|
5014
|
+
error: f,
|
|
5013
5015
|
onBlur: u,
|
|
5014
|
-
onKeyDown:
|
|
5015
|
-
rows:
|
|
5016
|
+
onKeyDown: d,
|
|
5017
|
+
rows: g = 10,
|
|
5016
5018
|
cols: p = 35
|
|
5017
5019
|
}) => {
|
|
5018
|
-
const w = Ce(), S = `${w}-helper`, E =
|
|
5019
|
-
t?.(
|
|
5020
|
+
const w = Ce(), S = `${w}-helper`, E = f ? "danger" : s, b = c || !!f, T = (y) => {
|
|
5021
|
+
t?.(y.target.value);
|
|
5020
5022
|
}, v = {
|
|
5021
5023
|
wrapper: "smp-textarea-wrapper",
|
|
5022
5024
|
container: `smp-textarea ${n ? "smp-textarea-disabled" : ""} ${r ? "smp-textarea-placeholder" : ""} ${E ? `smp-textarea-${E}` : ""} ${a ? `smp-textarea-${a}` : ""} ${o ? "" : "smp-textarea-readOnly"}`
|
|
@@ -5034,11 +5036,11 @@ const Ts = ({
|
|
|
5034
5036
|
className: v.container,
|
|
5035
5037
|
disabled: n,
|
|
5036
5038
|
readOnly: !o,
|
|
5037
|
-
onKeyDown:
|
|
5039
|
+
onKeyDown: d,
|
|
5038
5040
|
"aria-label": i ? void 0 : l,
|
|
5039
5041
|
"aria-labelledby": i ? w : void 0,
|
|
5040
5042
|
"aria-describedby": b ? S : void 0,
|
|
5041
|
-
rows:
|
|
5043
|
+
rows: g,
|
|
5042
5044
|
cols: p
|
|
5043
5045
|
}
|
|
5044
5046
|
),
|
|
@@ -5046,7 +5048,7 @@ const Ts = ({
|
|
|
5046
5048
|
$n,
|
|
5047
5049
|
{
|
|
5048
5050
|
id: S,
|
|
5049
|
-
helperText:
|
|
5051
|
+
helperText: f,
|
|
5050
5052
|
disabled: n,
|
|
5051
5053
|
state: E
|
|
5052
5054
|
}
|
|
@@ -5072,33 +5074,33 @@ const Pe = {
|
|
|
5072
5074
|
label: i,
|
|
5073
5075
|
...l
|
|
5074
5076
|
}) => {
|
|
5075
|
-
const [c,
|
|
5077
|
+
const [c, f] = G(s), u = Ce();
|
|
5076
5078
|
ne(() => {
|
|
5077
|
-
!c && a && o && a(o, void 0).then((
|
|
5078
|
-
console.error("Error during loading options (radio)",
|
|
5079
|
+
!c && a && o && a(o, void 0).then((y) => f(y)).catch((y) => {
|
|
5080
|
+
console.error("Error during loading options (radio)", y);
|
|
5079
5081
|
});
|
|
5080
5082
|
}, [c, a, o]);
|
|
5081
|
-
const
|
|
5083
|
+
const d = parseInt(r ?? "", 10), g = t === jt.LINE_DIRECTION, p = g && !isNaN(d), w = p ? Pe["smp-radio-horizontal-grid"] : g ? Pe["smp-radio-horizontal"] : "", S = p ? { gridTemplateColumns: `repeat(${d}, 1fr)` } : void 0, E = {
|
|
5082
5084
|
container: Pe["smp-radio"],
|
|
5083
5085
|
optionsContainer: `${Pe["smp-radio-options-container"]} ${w}`,
|
|
5084
5086
|
option: `${Pe["smp-radio-element"]} ${n ? Pe["smp-radio-disabled"] : ""}`
|
|
5085
5087
|
}, b = () => {
|
|
5086
5088
|
n || l.onBlur?.();
|
|
5087
|
-
}, T = (
|
|
5088
|
-
n || l.onChange?.(
|
|
5089
|
+
}, T = (y) => {
|
|
5090
|
+
n || l.onChange?.(y.id, y.label);
|
|
5089
5091
|
}, v = Ce();
|
|
5090
5092
|
return /* @__PURE__ */ m.jsxs("div", { "smp-id": "radio-container", className: E.container, id: u, children: [
|
|
5091
5093
|
i && /* @__PURE__ */ m.jsx(De, { label: i, disabled: n, htmlFor: u }),
|
|
5092
|
-
/* @__PURE__ */ m.jsx("div", { className: E.optionsContainer, style: S, children: c?.map((
|
|
5094
|
+
/* @__PURE__ */ m.jsx("div", { className: E.optionsContainer, style: S, children: c?.map((y, k) => /* @__PURE__ */ m.jsxs("label", { className: E.option, children: [
|
|
5093
5095
|
/* @__PURE__ */ m.jsx(
|
|
5094
5096
|
"input",
|
|
5095
5097
|
{
|
|
5096
5098
|
type: "radio",
|
|
5097
5099
|
name: v,
|
|
5098
|
-
value:
|
|
5100
|
+
value: y.id,
|
|
5099
5101
|
disabled: n,
|
|
5100
|
-
checked:
|
|
5101
|
-
onChange: () => T(
|
|
5102
|
+
checked: y.id === l.bindValue,
|
|
5103
|
+
onChange: () => T(y),
|
|
5102
5104
|
onBlur: b
|
|
5103
5105
|
}
|
|
5104
5106
|
),
|
|
@@ -5107,8 +5109,8 @@ const Pe = {
|
|
|
5107
5109
|
{
|
|
5108
5110
|
variant: "body",
|
|
5109
5111
|
bindValue: _e(
|
|
5110
|
-
|
|
5111
|
-
|
|
5112
|
+
y.id,
|
|
5113
|
+
y.label,
|
|
5112
5114
|
e
|
|
5113
5115
|
)
|
|
5114
5116
|
}
|
|
@@ -5125,7 +5127,7 @@ const Pe = {
|
|
|
5125
5127
|
ne(() => {
|
|
5126
5128
|
r && s?.current && s.current.focus();
|
|
5127
5129
|
}, [r, s]);
|
|
5128
|
-
const [a, o, i] = n, l = (c) => Array.from({ length: c }, (
|
|
5130
|
+
const [a, o, i] = n, l = (c) => Array.from({ length: c }, (f, u) => /* @__PURE__ */ m.jsx("option", { value: u, children: u.toString().padStart(2, "0") }, u));
|
|
5129
5131
|
return /* @__PURE__ */ m.jsxs(
|
|
5130
5132
|
"div",
|
|
5131
5133
|
{
|
|
@@ -5183,47 +5185,47 @@ const Pe = {
|
|
|
5183
5185
|
isEditable: r = !0,
|
|
5184
5186
|
...s
|
|
5185
5187
|
}) => {
|
|
5186
|
-
const a = le(null), [o, i] = G(!1), [l, c] = G(n || ""), [
|
|
5188
|
+
const a = le(null), [o, i] = G(!1), [l, c] = G(n || ""), [f, u] = G(""), { anchorRef: d, targetRef: g } = dt({
|
|
5187
5189
|
position: "bottom",
|
|
5188
5190
|
enabled: o
|
|
5189
5191
|
}), p = ue(() => {
|
|
5190
5192
|
i(!1), a?.current?.focus();
|
|
5191
5193
|
}, []);
|
|
5192
|
-
ht([
|
|
5193
|
-
const
|
|
5194
|
-
c(
|
|
5194
|
+
ht([g, d], o, () => i(!1)), It(o, g), ne(() => {
|
|
5195
|
+
const y = n || "", k = Tn(y) ? y : n || "";
|
|
5196
|
+
c(y), u(k);
|
|
5195
5197
|
}, [n]), ne(() => {
|
|
5196
|
-
const
|
|
5198
|
+
const y = (k) => {
|
|
5197
5199
|
k.key === "Escape" && i(!1);
|
|
5198
5200
|
};
|
|
5199
|
-
return o && document.addEventListener("keydown",
|
|
5200
|
-
document.removeEventListener("keydown",
|
|
5201
|
+
return o && document.addEventListener("keydown", y), () => {
|
|
5202
|
+
document.removeEventListener("keydown", y);
|
|
5201
5203
|
};
|
|
5202
5204
|
}, [o]);
|
|
5203
5205
|
const w = () => {
|
|
5204
|
-
r && i((
|
|
5205
|
-
}, S = (
|
|
5206
|
-
u(
|
|
5207
|
-
}, E = (
|
|
5208
|
-
const O = Rs(
|
|
5206
|
+
r && i((y) => !y);
|
|
5207
|
+
}, S = (y) => {
|
|
5208
|
+
u(y);
|
|
5209
|
+
}, E = (y, k, A) => {
|
|
5210
|
+
const O = Rs(y, k, A);
|
|
5209
5211
|
c(O), u(O), t?.(O), p();
|
|
5210
5212
|
}, b = () => {
|
|
5211
|
-
v(
|
|
5212
|
-
}, T = (
|
|
5213
|
-
|
|
5214
|
-
}, v = (
|
|
5215
|
-
if (
|
|
5213
|
+
v(f);
|
|
5214
|
+
}, T = (y) => {
|
|
5215
|
+
y.key === "Enter" && (y.preventDefault(), v(f));
|
|
5216
|
+
}, v = (y) => {
|
|
5217
|
+
if (y.trim() === "") {
|
|
5216
5218
|
c(""), u(""), t?.("");
|
|
5217
5219
|
return;
|
|
5218
5220
|
}
|
|
5219
|
-
Tn(
|
|
5221
|
+
Tn(y) ? (c(y), u(y), t?.(y)) : u(y);
|
|
5220
5222
|
};
|
|
5221
5223
|
return /* @__PURE__ */ m.jsxs("div", { "data-component": "time-picker", children: [
|
|
5222
5224
|
/* @__PURE__ */ m.jsx(
|
|
5223
5225
|
At,
|
|
5224
5226
|
{
|
|
5225
5227
|
...s,
|
|
5226
|
-
bindValue:
|
|
5228
|
+
bindValue: f,
|
|
5227
5229
|
placeholder: e,
|
|
5228
5230
|
onChange: S,
|
|
5229
5231
|
onBlur: b,
|
|
@@ -5231,7 +5233,7 @@ const Pe = {
|
|
|
5231
5233
|
shapeIcon: "clock",
|
|
5232
5234
|
onShapeIconClick: w,
|
|
5233
5235
|
isEditable: r,
|
|
5234
|
-
ref:
|
|
5236
|
+
ref: d,
|
|
5235
5237
|
inputRef: a
|
|
5236
5238
|
}
|
|
5237
5239
|
),
|
|
@@ -5240,7 +5242,7 @@ const Pe = {
|
|
|
5240
5242
|
{
|
|
5241
5243
|
value: _s(l),
|
|
5242
5244
|
onChange: E,
|
|
5243
|
-
targetRef:
|
|
5245
|
+
targetRef: g,
|
|
5244
5246
|
isOpen: o
|
|
5245
5247
|
}
|
|
5246
5248
|
) })
|
|
@@ -5249,7 +5251,7 @@ const Pe = {
|
|
|
5249
5251
|
function js(n) {
|
|
5250
5252
|
return typeof n == "string" && /^\d{6}$/.test(n);
|
|
5251
5253
|
}
|
|
5252
|
-
class
|
|
5254
|
+
class ft {
|
|
5253
5255
|
class;
|
|
5254
5256
|
time;
|
|
5255
5257
|
constructor(e, t) {
|
|
@@ -5258,7 +5260,7 @@ class dt {
|
|
|
5258
5260
|
static fromDataObj(e) {
|
|
5259
5261
|
const t = Cn.get(`${e.t}${e.p}`);
|
|
5260
5262
|
if (t)
|
|
5261
|
-
return new
|
|
5263
|
+
return new ft(e, t.legacyToIso(e.k));
|
|
5262
5264
|
throw new Error(`time creation from ${e.t}${e.p} not implemented yet`);
|
|
5263
5265
|
}
|
|
5264
5266
|
getLegacyValue() {
|
|
@@ -5297,36 +5299,36 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5297
5299
|
fun: o,
|
|
5298
5300
|
...i
|
|
5299
5301
|
}) => {
|
|
5300
|
-
const [l, c] = G(s),
|
|
5301
|
-
e || i.onChange?.(
|
|
5302
|
+
const [l, c] = G(s), f = (d) => {
|
|
5303
|
+
e || i.onChange?.(d.id, d.label);
|
|
5302
5304
|
};
|
|
5303
5305
|
ne(() => {
|
|
5304
|
-
!l && a && o && a(o, void 0).then((
|
|
5305
|
-
console.error("Error during loading options (button group)",
|
|
5306
|
+
!l && a && o && a(o, void 0).then((d) => c(d)).catch((d) => {
|
|
5307
|
+
console.error("Error during loading options (button group)", d);
|
|
5306
5308
|
});
|
|
5307
5309
|
}, [l, a, o]);
|
|
5308
5310
|
const u = {
|
|
5309
5311
|
container: `smp-button-group-container ${ce(r) ? "smp-button-group-vertical" : ""}`
|
|
5310
5312
|
};
|
|
5311
|
-
return /* @__PURE__ */ m.jsx("div", { "smp-id": "buttonGroup-container", className: u.container, children: l?.map((
|
|
5313
|
+
return /* @__PURE__ */ m.jsx("div", { "smp-id": "buttonGroup-container", className: u.container, children: l?.map((d) => /* @__PURE__ */ m.jsx(
|
|
5312
5314
|
we,
|
|
5313
5315
|
{
|
|
5314
5316
|
appearance: "raised",
|
|
5315
5317
|
variant: "base",
|
|
5316
|
-
active: n ===
|
|
5317
|
-
onClick: () => d
|
|
5318
|
-
bindValue:
|
|
5318
|
+
active: n === d.id,
|
|
5319
|
+
onClick: () => f(d),
|
|
5320
|
+
bindValue: d.id,
|
|
5319
5321
|
optionalDisplayValue: _e(
|
|
5320
|
-
|
|
5321
|
-
|
|
5322
|
+
d.id,
|
|
5323
|
+
d.label,
|
|
5322
5324
|
t
|
|
5323
5325
|
),
|
|
5324
5326
|
disabled: e,
|
|
5325
5327
|
justify: ce(r) ? "start" : "center",
|
|
5326
|
-
icon:
|
|
5328
|
+
icon: d.icon,
|
|
5327
5329
|
buttonExt: `oneButton-${ce(r) ? "vertical" : "horizontal"}`
|
|
5328
5330
|
},
|
|
5329
|
-
|
|
5331
|
+
d.id
|
|
5330
5332
|
)) });
|
|
5331
5333
|
}, Te = ({
|
|
5332
5334
|
decode: n,
|
|
@@ -5339,10 +5341,10 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5339
5341
|
label: i,
|
|
5340
5342
|
tooltip: l,
|
|
5341
5343
|
options: c,
|
|
5342
|
-
onChange:
|
|
5344
|
+
onChange: f,
|
|
5343
5345
|
onClick: u,
|
|
5344
|
-
onEnter:
|
|
5345
|
-
onBlur:
|
|
5346
|
+
onEnter: d,
|
|
5347
|
+
onBlur: g,
|
|
5346
5348
|
onOptionsRequest: p,
|
|
5347
5349
|
onContextMenu: w,
|
|
5348
5350
|
isEditable: S,
|
|
@@ -5356,7 +5358,7 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5356
5358
|
fun: a,
|
|
5357
5359
|
data: r
|
|
5358
5360
|
}, T = b.data && b.data.size && b.data.size >= 256 && (e === "ITX" || !e) ? "MEM" : e, v = {
|
|
5359
|
-
onBlur:
|
|
5361
|
+
onBlur: g,
|
|
5360
5362
|
onOptionsRequest: p,
|
|
5361
5363
|
fun: a,
|
|
5362
5364
|
icon: s,
|
|
@@ -5366,7 +5368,7 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5366
5368
|
isEditable: S,
|
|
5367
5369
|
size: b.data && b.data.size ? b.data.size : b.data?.displayMode && Ss(b.data.displayMode || "CodeOnly"),
|
|
5368
5370
|
...r
|
|
5369
|
-
},
|
|
5371
|
+
}, y = (D, C, P) => yr(t) ? Ne(D, new it(t, C).getLegacyValue()) : br(t) ? Ne(D, new ft(t, C).getLegacyValue()) : Ne(D, C, P), k = (D, C) => Ne(
|
|
5370
5372
|
D,
|
|
5371
5373
|
new Ge(t, C, E).getLegacyValue()
|
|
5372
5374
|
), A = (D) => Ne(b, new ot(t, D).getLegacyValue()), O = (D) => ws(b, D), L = () => {
|
|
@@ -5377,7 +5379,7 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5377
5379
|
bindValue: t.k,
|
|
5378
5380
|
optionalDisplayValue: n,
|
|
5379
5381
|
onChange: (C, P) => {
|
|
5380
|
-
|
|
5382
|
+
f?.(y(b, C, P));
|
|
5381
5383
|
}
|
|
5382
5384
|
};
|
|
5383
5385
|
return /* @__PURE__ */ m.jsx(In, { ...D });
|
|
@@ -5389,7 +5391,7 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5389
5391
|
showText: !!D,
|
|
5390
5392
|
title: n,
|
|
5391
5393
|
onClick: () => {
|
|
5392
|
-
u?.(
|
|
5394
|
+
u?.(y(b, t.k));
|
|
5393
5395
|
}
|
|
5394
5396
|
};
|
|
5395
5397
|
return /* @__PURE__ */ m.jsx(we, { ...C });
|
|
@@ -5400,7 +5402,7 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5400
5402
|
options: c,
|
|
5401
5403
|
onClick: (C, P) => {
|
|
5402
5404
|
const N = { ...b, fun: P };
|
|
5403
|
-
u?.(
|
|
5405
|
+
u?.(y(N, C));
|
|
5404
5406
|
}
|
|
5405
5407
|
};
|
|
5406
5408
|
return /* @__PURE__ */ m.jsx(us, { ...D });
|
|
@@ -5419,11 +5421,11 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5419
5421
|
bindValue: ot.fromDataObj(t).getValue(),
|
|
5420
5422
|
optionalDisplayValue: n,
|
|
5421
5423
|
onChange: (P) => {
|
|
5422
|
-
|
|
5424
|
+
f?.(A(P));
|
|
5423
5425
|
},
|
|
5424
5426
|
...D && { variant: "switch" }
|
|
5425
5427
|
};
|
|
5426
|
-
return /* @__PURE__ */ m.jsx(
|
|
5428
|
+
return /* @__PURE__ */ m.jsx(ds, { ...C });
|
|
5427
5429
|
}
|
|
5428
5430
|
case te.COMBOBOX: {
|
|
5429
5431
|
const D = {
|
|
@@ -5431,7 +5433,7 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5431
5433
|
bindValue: t.k,
|
|
5432
5434
|
optionalDisplayValue: n,
|
|
5433
5435
|
onChange: (C, P) => {
|
|
5434
|
-
|
|
5436
|
+
f?.(y(b, C, P));
|
|
5435
5437
|
}
|
|
5436
5438
|
};
|
|
5437
5439
|
return /* @__PURE__ */ m.jsx(ps, { ...D });
|
|
@@ -5441,7 +5443,7 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5441
5443
|
...v,
|
|
5442
5444
|
bindValue: it.fromDataObj(t).getValue(),
|
|
5443
5445
|
onChange: (C) => {
|
|
5444
|
-
|
|
5446
|
+
f?.(y(b, C));
|
|
5445
5447
|
}
|
|
5446
5448
|
};
|
|
5447
5449
|
return /* @__PURE__ */ m.jsx(gs, { ...D });
|
|
@@ -5453,17 +5455,17 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5453
5455
|
icon: s,
|
|
5454
5456
|
isInteractable: !!v.fun,
|
|
5455
5457
|
onClick: () => {
|
|
5456
|
-
u?.(
|
|
5458
|
+
u?.(y(b, t.k));
|
|
5457
5459
|
}
|
|
5458
5460
|
};
|
|
5459
|
-
return /* @__PURE__ */ m.jsx(
|
|
5461
|
+
return /* @__PURE__ */ m.jsx(fe, { ...D });
|
|
5460
5462
|
}
|
|
5461
5463
|
case te.INPUT_NUMBER: {
|
|
5462
5464
|
const D = {
|
|
5463
5465
|
...v,
|
|
5464
5466
|
bindValue: Ge.fromDataObj(t, E).getValue(),
|
|
5465
5467
|
onChange: (C) => {
|
|
5466
|
-
|
|
5468
|
+
f?.(k(b, C));
|
|
5467
5469
|
}
|
|
5468
5470
|
};
|
|
5469
5471
|
return /* @__PURE__ */ m.jsx(Es, { ...D });
|
|
@@ -5475,7 +5477,7 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5475
5477
|
bindValue: t.k,
|
|
5476
5478
|
optionalDisplayValue: n,
|
|
5477
5479
|
onChange: (C) => {
|
|
5478
|
-
|
|
5480
|
+
f?.(y(b, C));
|
|
5479
5481
|
}
|
|
5480
5482
|
};
|
|
5481
5483
|
return /* @__PURE__ */ m.jsx(Ts, { ...D });
|
|
@@ -5485,7 +5487,7 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5485
5487
|
...v,
|
|
5486
5488
|
elements: En(b),
|
|
5487
5489
|
onChange: (C) => {
|
|
5488
|
-
|
|
5490
|
+
f?.(O(C));
|
|
5489
5491
|
}
|
|
5490
5492
|
};
|
|
5491
5493
|
return /* @__PURE__ */ m.jsx(ys, { ...D });
|
|
@@ -5495,7 +5497,7 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5495
5497
|
...v,
|
|
5496
5498
|
bindValue: t.k,
|
|
5497
5499
|
onChange: (C) => {
|
|
5498
|
-
|
|
5500
|
+
f?.(y(b, C));
|
|
5499
5501
|
}
|
|
5500
5502
|
};
|
|
5501
5503
|
return /* @__PURE__ */ m.jsx(bs, { ...D });
|
|
@@ -5505,7 +5507,7 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5505
5507
|
...v,
|
|
5506
5508
|
bindValue: t.k,
|
|
5507
5509
|
onChange: (C, P) => {
|
|
5508
|
-
|
|
5510
|
+
f?.(y(b, C, P));
|
|
5509
5511
|
}
|
|
5510
5512
|
};
|
|
5511
5513
|
return /* @__PURE__ */ m.jsx(Cs, { ...D });
|
|
@@ -5515,7 +5517,7 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5515
5517
|
...v,
|
|
5516
5518
|
bindValue: t.k,
|
|
5517
5519
|
onEnter: (C) => {
|
|
5518
|
-
|
|
5520
|
+
d?.(y(b, C));
|
|
5519
5521
|
}
|
|
5520
5522
|
};
|
|
5521
5523
|
return /* @__PURE__ */ m.jsx(vs, { ...D });
|
|
@@ -5526,7 +5528,7 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5526
5528
|
bindValue: t.k,
|
|
5527
5529
|
optionalDisplayValue: n,
|
|
5528
5530
|
onChange: (C) => {
|
|
5529
|
-
|
|
5531
|
+
f?.(y(b, C));
|
|
5530
5532
|
}
|
|
5531
5533
|
};
|
|
5532
5534
|
return /* @__PURE__ */ m.jsx(je, { ...D });
|
|
@@ -5536,7 +5538,7 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5536
5538
|
...v,
|
|
5537
5539
|
bindValue: t.k,
|
|
5538
5540
|
onChange: (C, P) => {
|
|
5539
|
-
|
|
5541
|
+
f?.(y(b, C, P));
|
|
5540
5542
|
}
|
|
5541
5543
|
};
|
|
5542
5544
|
return /* @__PURE__ */ m.jsx(ks, { ...D });
|
|
@@ -5544,9 +5546,9 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5544
5546
|
case te.TIME: {
|
|
5545
5547
|
const D = {
|
|
5546
5548
|
...v,
|
|
5547
|
-
bindValue:
|
|
5549
|
+
bindValue: ft.fromDataObj(t).getValue(),
|
|
5548
5550
|
onChange: (C) => {
|
|
5549
|
-
|
|
5551
|
+
f?.(y(b, C));
|
|
5550
5552
|
}
|
|
5551
5553
|
};
|
|
5552
5554
|
return /* @__PURE__ */ m.jsx(Ds, { ...D });
|
|
@@ -5584,18 +5586,18 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5584
5586
|
if (!i.rows?.length || !i.columns?.length)
|
|
5585
5587
|
return {};
|
|
5586
5588
|
const l = i.rows[0];
|
|
5587
|
-
return i.columns.filter((c) => c.visible).reduce((c,
|
|
5588
|
-
const u = l.cells[
|
|
5589
|
+
return i.columns.filter((c) => c.visible).reduce((c, f) => {
|
|
5590
|
+
const u = l.cells[f.name], d = {
|
|
5589
5591
|
...u,
|
|
5590
|
-
id:
|
|
5591
|
-
onChange: (
|
|
5592
|
+
id: f.name,
|
|
5593
|
+
onChange: (g) => {
|
|
5592
5594
|
a((p) => p && {
|
|
5593
5595
|
...p,
|
|
5594
|
-
[
|
|
5595
|
-
...p[
|
|
5596
|
+
[f.name]: {
|
|
5597
|
+
...p[f.name],
|
|
5596
5598
|
obj: {
|
|
5597
|
-
...p[
|
|
5598
|
-
k:
|
|
5599
|
+
...p[f.name].obj,
|
|
5600
|
+
k: g.obj.k
|
|
5599
5601
|
}
|
|
5600
5602
|
}
|
|
5601
5603
|
});
|
|
@@ -5605,16 +5607,16 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5605
5607
|
...u
|
|
5606
5608
|
});
|
|
5607
5609
|
},
|
|
5608
|
-
onEnter: (
|
|
5609
|
-
t && t(
|
|
5610
|
+
onEnter: (g) => {
|
|
5611
|
+
t && t(g);
|
|
5610
5612
|
},
|
|
5611
|
-
onContextMenu: (
|
|
5612
|
-
r && r(
|
|
5613
|
+
onContextMenu: (g, p) => {
|
|
5614
|
+
r && r(g, p);
|
|
5613
5615
|
}
|
|
5614
5616
|
};
|
|
5615
5617
|
return {
|
|
5616
5618
|
...c,
|
|
5617
|
-
[
|
|
5619
|
+
[f.name]: d
|
|
5618
5620
|
};
|
|
5619
5621
|
}, {});
|
|
5620
5622
|
},
|
|
@@ -5640,14 +5642,14 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5640
5642
|
loadOptions: l,
|
|
5641
5643
|
onContextMenu: c
|
|
5642
5644
|
}) => {
|
|
5643
|
-
const [
|
|
5645
|
+
const [f, u] = G(), [d, g] = G(t ?? !0), p = le(null), w = s.trim() ? s : "100vh", S = ue(
|
|
5644
5646
|
(v) => {
|
|
5645
5647
|
if (!v?.rows?.length || !v?.columns?.length)
|
|
5646
5648
|
return {};
|
|
5647
|
-
const
|
|
5649
|
+
const y = v.rows[0];
|
|
5648
5650
|
return v.columns.filter((k) => k.visible ?? !0).reduce((k, A) => {
|
|
5649
|
-
const O =
|
|
5650
|
-
if (!O || !
|
|
5651
|
+
const O = y.cells[A.name];
|
|
5652
|
+
if (!O || !d && ce(r) && O.shape !== te.BUTTON && O.shape !== te.BUTTON_LIST)
|
|
5651
5653
|
return k;
|
|
5652
5654
|
const L = {
|
|
5653
5655
|
...O,
|
|
@@ -5670,7 +5672,7 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5670
5672
|
};
|
|
5671
5673
|
return l && O.shape == te.BUTTON_LIST && (L.onOptionsRequest = (R, D) => l(R, D).then(
|
|
5672
5674
|
(C) => Ls(C)
|
|
5673
|
-
)), !
|
|
5675
|
+
)), !d && ce(r) && (L.data = {
|
|
5674
5676
|
...L.data,
|
|
5675
5677
|
showText: !1,
|
|
5676
5678
|
justify: "center",
|
|
@@ -5681,11 +5683,11 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5681
5683
|
};
|
|
5682
5684
|
}, {});
|
|
5683
5685
|
},
|
|
5684
|
-
[
|
|
5686
|
+
[d, r, a, o, l, c]
|
|
5685
5687
|
), E = ue(() => {
|
|
5686
5688
|
i?.();
|
|
5687
5689
|
}, [i]), b = () => {
|
|
5688
|
-
ce(r) ?
|
|
5690
|
+
ce(r) ? g((v) => !v) : (g(!1), i?.());
|
|
5689
5691
|
};
|
|
5690
5692
|
if (ne(() => {
|
|
5691
5693
|
u(S(n));
|
|
@@ -5699,24 +5701,24 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5699
5701
|
const v = getComputedStyle(p.current).getPropertyValue(
|
|
5700
5702
|
"--smp-drawer-slide-transition"
|
|
5701
5703
|
);
|
|
5702
|
-
let
|
|
5703
|
-
v.endsWith("ms") ?
|
|
5704
|
+
let y = Number(v);
|
|
5705
|
+
v.endsWith("ms") ? y = parseFloat(v) : v.endsWith("s") && (y = parseFloat(v) * 1e3), setTimeout(() => {
|
|
5704
5706
|
u(S(n));
|
|
5705
|
-
},
|
|
5706
|
-
}, [
|
|
5707
|
-
t !== void 0 && !ce(r) &&
|
|
5707
|
+
}, y / 2);
|
|
5708
|
+
}, [d, r]), ne(() => {
|
|
5709
|
+
t !== void 0 && !ce(r) && g(t);
|
|
5708
5710
|
}, [r, t]), !n?.rows?.length || !n.columns?.length)
|
|
5709
5711
|
return null;
|
|
5710
5712
|
const T = {
|
|
5711
|
-
drawer: `smp-drawer ${ce(r) ? "smp-drawer-minified" : "smp-drawer-fixed"} ${
|
|
5713
|
+
drawer: `smp-drawer ${ce(r) ? "smp-drawer-minified" : "smp-drawer-fixed"} ${d ? "smp-drawer-open" : ""} ${!ce(r) && !d ? "smp-drawer-no-border" : ""}`,
|
|
5712
5714
|
container: "smp-drawer-container",
|
|
5713
5715
|
containerHeader: "smp-drawer-container-header",
|
|
5714
|
-
containerIcon: `${
|
|
5716
|
+
containerIcon: `${d ? "" : "smp-drawer-container-icon-close"} smp-drawer-container-icon`,
|
|
5715
5717
|
containerLayout: "smp-drawer-container-layout",
|
|
5716
5718
|
containerLogo: "smp-drawer-container-logo",
|
|
5717
|
-
backdrop: `smp-drawer-backdrop ${
|
|
5719
|
+
backdrop: `smp-drawer-backdrop ${d ? "smp-drawer-backdrop-open" : ""}`
|
|
5718
5720
|
};
|
|
5719
|
-
return
|
|
5721
|
+
return f && /* @__PURE__ */ m.jsxs(m.Fragment, { children: [
|
|
5720
5722
|
!ce(r) && /* @__PURE__ */ m.jsx(
|
|
5721
5723
|
"div",
|
|
5722
5724
|
{
|
|
@@ -5737,7 +5739,7 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5737
5739
|
children: /* @__PURE__ */ m.jsxs("div", { className: T.container, children: [
|
|
5738
5740
|
/* @__PURE__ */ m.jsxs("div", { className: T.containerHeader, children: [
|
|
5739
5741
|
e && /* @__PURE__ */ m.jsx("div", { className: T.containerLogo, children: /* @__PURE__ */ m.jsx(
|
|
5740
|
-
|
|
5742
|
+
fe,
|
|
5741
5743
|
{
|
|
5742
5744
|
icon: e,
|
|
5743
5745
|
title: "drawer_logo",
|
|
@@ -5746,11 +5748,11 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5746
5748
|
}
|
|
5747
5749
|
) }),
|
|
5748
5750
|
/* @__PURE__ */ m.jsx("div", { className: T.containerIcon, children: /* @__PURE__ */ m.jsx(
|
|
5749
|
-
|
|
5751
|
+
fe,
|
|
5750
5752
|
{
|
|
5751
5753
|
icon: ce(r) ? "menu_close" : "close",
|
|
5752
5754
|
title: "drawer_icon",
|
|
5753
|
-
rotated: !
|
|
5755
|
+
rotated: !d,
|
|
5754
5756
|
isInteractable: !0,
|
|
5755
5757
|
onClick: b,
|
|
5756
5758
|
width: 20,
|
|
@@ -5758,7 +5760,7 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5758
5760
|
}
|
|
5759
5761
|
) })
|
|
5760
5762
|
] }),
|
|
5761
|
-
/* @__PURE__ */ m.jsx("div", { className: T.containerLayout, children: /* @__PURE__ */ m.jsx(at, { layout: n.rows[0].layout, children: Object.values(
|
|
5763
|
+
/* @__PURE__ */ m.jsx("div", { className: T.containerLayout, children: /* @__PURE__ */ m.jsx(at, { layout: n.rows[0].layout, children: Object.values(f).map((v) => /* @__PURE__ */ m.jsx(Te, { ...v })) }) })
|
|
5762
5764
|
] })
|
|
5763
5765
|
}
|
|
5764
5766
|
)
|
|
@@ -5774,10 +5776,10 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5774
5776
|
Horizontal: i,
|
|
5775
5777
|
ForceIcon: l,
|
|
5776
5778
|
IconColName: c,
|
|
5777
|
-
IconColor:
|
|
5779
|
+
IconColor: f = "var(--smp-dashList-color-base)",
|
|
5778
5780
|
NumberFormat: u,
|
|
5779
|
-
ForceUM:
|
|
5780
|
-
UmColName:
|
|
5781
|
+
ForceUM: d,
|
|
5782
|
+
UmColName: g,
|
|
5781
5783
|
UmColor: p = "var(--smp-dashList-color-base)",
|
|
5782
5784
|
ForceValue: w,
|
|
5783
5785
|
ValueColName: S,
|
|
@@ -5785,7 +5787,7 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5785
5787
|
SelectLayout: b = "1",
|
|
5786
5788
|
onClick: T
|
|
5787
5789
|
}) => {
|
|
5788
|
-
const v = "N/A",
|
|
5790
|
+
const v = "N/A", y = e?.columns || [], k = e?.rows || [], A = k.length > 0, O = "--smp-dashList-color", L = "smp-layout", R = "descr", D = "icon", C = "um", P = "value", N = o || "1em", B = "18px", H = "--smp-dashList-columns", z = "--smp-dashList-fontSize", X = {
|
|
5789
5791
|
dash: (Y = "1") => {
|
|
5790
5792
|
const Z = h(Y), re = Z, ae = x(Z, R), ke = x(Z, D), Me = x(Z, C), ge = x(Z, P);
|
|
5791
5793
|
return {
|
|
@@ -5819,13 +5821,13 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5819
5821
|
if (ae)
|
|
5820
5822
|
return Y?.cells[ae]?.obj.k;
|
|
5821
5823
|
}, re = (ae) => {
|
|
5822
|
-
if (!(
|
|
5823
|
-
return Y?.cells[
|
|
5824
|
+
if (!(y.length <= ae))
|
|
5825
|
+
return Y?.cells[y[ae].name]?.obj?.k;
|
|
5824
5826
|
};
|
|
5825
5827
|
return {
|
|
5826
5828
|
descr: t || Z(r) || re(2) || "",
|
|
5827
5829
|
icon: l || Z(c) || re(3) || "",
|
|
5828
|
-
um:
|
|
5830
|
+
um: d || Z(g) || re(1) || "",
|
|
5829
5831
|
value: w || Z(S) || re(0) || ""
|
|
5830
5832
|
};
|
|
5831
5833
|
}, W = (Y) => {
|
|
@@ -5838,9 +5840,9 @@ const Cn = /* @__PURE__ */ new Map([
|
|
|
5838
5840
|
className: Z,
|
|
5839
5841
|
descr: (re) => /* @__PURE__ */ m.jsx("div", { className: Z.descr, children: re }, `${Y}-${R}`),
|
|
5840
5842
|
icon: (re) => /* @__PURE__ */ m.jsx("div", { className: Z.icon, children: /* @__PURE__ */ m.jsx(
|
|
5841
|
-
|
|
5843
|
+
fe,
|
|
5842
5844
|
{
|
|
5843
|
-
color:
|
|
5845
|
+
color: f,
|
|
5844
5846
|
height: B,
|
|
5845
5847
|
icon: re,
|
|
5846
5848
|
width: B
|
|
@@ -5918,15 +5920,15 @@ const Nn = ({
|
|
|
5918
5920
|
rowHeight: r = 26,
|
|
5919
5921
|
offsetTop: s
|
|
5920
5922
|
}) => {
|
|
5921
|
-
const [a, o] = G(!1), i = nt(n) && !!n.children?.length, l = n.cells && Object.keys(n.cells).length > 0, c = i,
|
|
5923
|
+
const [a, o] = G(!1), i = nt(n) && !!n.children?.length, l = n.cells && Object.keys(n.cells).length > 0, c = i, f = t * 20, u = () => {
|
|
5922
5924
|
i && o(!a);
|
|
5923
|
-
},
|
|
5925
|
+
}, d = {
|
|
5924
5926
|
content: `${Se.rowContent} ${i ? Se.clickable : ""}`,
|
|
5925
5927
|
toggle: `${Se.toggle}`,
|
|
5926
5928
|
indent: `${Se.indent}`,
|
|
5927
5929
|
cell: `${Se.cell}`
|
|
5928
|
-
},
|
|
5929
|
-
|
|
5930
|
+
}, g = (b) => /* @__PURE__ */ m.jsx(Te, { ...b }), p = () => /* @__PURE__ */ m.jsx("span", { className: d.toggle, children: c && /* @__PURE__ */ m.jsx(
|
|
5931
|
+
fe,
|
|
5930
5932
|
{
|
|
5931
5933
|
icon: a ? "arrow_drop_right" : "arrow_drop_down",
|
|
5932
5934
|
width: 16
|
|
@@ -5934,8 +5936,8 @@ const Nn = ({
|
|
|
5934
5936
|
) }), w = () => /* @__PURE__ */ m.jsx(
|
|
5935
5937
|
"span",
|
|
5936
5938
|
{
|
|
5937
|
-
className:
|
|
5938
|
-
style: { width: `${
|
|
5939
|
+
className: d.indent,
|
|
5940
|
+
style: { width: `${f}px` },
|
|
5939
5941
|
"aria-hidden": "true"
|
|
5940
5942
|
}
|
|
5941
5943
|
), S = () => {
|
|
@@ -5943,7 +5945,7 @@ const Nn = ({
|
|
|
5943
5945
|
return /* @__PURE__ */ m.jsxs(
|
|
5944
5946
|
"tr",
|
|
5945
5947
|
{
|
|
5946
|
-
className:
|
|
5948
|
+
className: d.content,
|
|
5947
5949
|
onClick: u,
|
|
5948
5950
|
role: i ? "button" : "row",
|
|
5949
5951
|
"aria-expanded": i ? !a : void 0,
|
|
@@ -5967,21 +5969,21 @@ const Nn = ({
|
|
|
5967
5969
|
]
|
|
5968
5970
|
}
|
|
5969
5971
|
),
|
|
5970
|
-
n.cells && Object.keys(n.cells).length > 0 && Object.entries(n.cells).map(([v,
|
|
5972
|
+
n.cells && Object.keys(n.cells).length > 0 && Object.entries(n.cells).map(([v, y]) => /* @__PURE__ */ m.jsx(
|
|
5971
5973
|
"td",
|
|
5972
5974
|
{
|
|
5973
|
-
className:
|
|
5975
|
+
className: d.cell,
|
|
5974
5976
|
style: {
|
|
5975
5977
|
width: e[v],
|
|
5976
5978
|
minWidth: e[v],
|
|
5977
5979
|
height: `${r}px`
|
|
5978
5980
|
},
|
|
5979
|
-
children:
|
|
5980
|
-
...
|
|
5981
|
+
children: g({
|
|
5982
|
+
...y,
|
|
5981
5983
|
id: v
|
|
5982
5984
|
})
|
|
5983
5985
|
},
|
|
5984
|
-
Us(
|
|
5986
|
+
Us(y) || v
|
|
5985
5987
|
))
|
|
5986
5988
|
]
|
|
5987
5989
|
}
|
|
@@ -6022,7 +6024,7 @@ const Nn = ({
|
|
|
6022
6024
|
},
|
|
6023
6025
|
children: [
|
|
6024
6026
|
/* @__PURE__ */ m.jsx(
|
|
6025
|
-
|
|
6027
|
+
fe,
|
|
6026
6028
|
{
|
|
6027
6029
|
icon: a ? "arrow_drop_down" : "arrow_drop_right",
|
|
6028
6030
|
width: 16
|
|
@@ -6052,41 +6054,41 @@ function Gs(n, e, t, r) {
|
|
|
6052
6054
|
const s = [];
|
|
6053
6055
|
let a = 0;
|
|
6054
6056
|
return o(n, 0, []), { flatRows: s, offset: a };
|
|
6055
|
-
function o(u,
|
|
6056
|
-
if (
|
|
6057
|
-
|
|
6057
|
+
function o(u, d, g) {
|
|
6058
|
+
if (d >= e.length) {
|
|
6059
|
+
f(u);
|
|
6058
6060
|
return;
|
|
6059
6061
|
}
|
|
6060
|
-
const p = e[
|
|
6062
|
+
const p = e[d].column, w = i(u, p);
|
|
6061
6063
|
for (const [S, E] of w) {
|
|
6062
|
-
const b = [...
|
|
6063
|
-
s.push(c(S, T,
|
|
6064
|
+
const b = [...g, S], T = l(b, d), v = r.has(T);
|
|
6065
|
+
s.push(c(S, T, d, v)), a += t, v && o(E, d + 1, b);
|
|
6064
6066
|
}
|
|
6065
6067
|
}
|
|
6066
|
-
function i(u,
|
|
6067
|
-
const
|
|
6068
|
+
function i(u, d) {
|
|
6069
|
+
const g = /* @__PURE__ */ new Map();
|
|
6068
6070
|
for (const p of u) {
|
|
6069
|
-
const w = p.cells[
|
|
6070
|
-
|
|
6071
|
+
const w = p.cells[d]?.decode ?? "N/D";
|
|
6072
|
+
g.has(w) || g.set(w, []), g.get(w).push(p);
|
|
6071
6073
|
}
|
|
6072
|
-
return
|
|
6074
|
+
return g;
|
|
6073
6075
|
}
|
|
6074
|
-
function l(u,
|
|
6075
|
-
return `group-${u.join("-")}-${
|
|
6076
|
+
function l(u, d) {
|
|
6077
|
+
return `group-${u.join("-")}-${d}`;
|
|
6076
6078
|
}
|
|
6077
|
-
function c(u,
|
|
6079
|
+
function c(u, d, g, p) {
|
|
6078
6080
|
return {
|
|
6079
6081
|
isGroup: !0,
|
|
6080
6082
|
value: u,
|
|
6081
6083
|
cells: {},
|
|
6082
|
-
rowId:
|
|
6083
|
-
level:
|
|
6084
|
+
rowId: d,
|
|
6085
|
+
level: g,
|
|
6084
6086
|
isExpanded: p
|
|
6085
6087
|
};
|
|
6086
6088
|
}
|
|
6087
|
-
function
|
|
6088
|
-
for (const
|
|
6089
|
-
s.push(
|
|
6089
|
+
function f(u) {
|
|
6090
|
+
for (const d of u)
|
|
6091
|
+
s.push(d), a += t;
|
|
6090
6092
|
}
|
|
6091
6093
|
}
|
|
6092
6094
|
const Hs = ({
|
|
@@ -6109,7 +6111,7 @@ const Hs = ({
|
|
|
6109
6111
|
onDragOver: a,
|
|
6110
6112
|
onDrop: s,
|
|
6111
6113
|
children: [
|
|
6112
|
-
/* @__PURE__ */ m.jsx("td", { children: /* @__PURE__ */ m.jsx(
|
|
6114
|
+
/* @__PURE__ */ m.jsx("td", { children: /* @__PURE__ */ m.jsx(fe, { icon: "groups" }) }),
|
|
6113
6115
|
/* @__PURE__ */ m.jsx("td", { children: /* @__PURE__ */ m.jsx(
|
|
6114
6116
|
Pt,
|
|
6115
6117
|
{
|
|
@@ -6151,8 +6153,8 @@ const Hs = ({
|
|
|
6151
6153
|
);
|
|
6152
6154
|
a(i);
|
|
6153
6155
|
} else if (r === "fit-grid") {
|
|
6154
|
-
const o = t.current?.offsetWidth || 800, i = n.filter((
|
|
6155
|
-
i.map((
|
|
6156
|
+
const o = t.current?.offsetWidth || 800, i = n.filter((f) => f.visible !== !1), l = o / i.length, c = Object.fromEntries(
|
|
6157
|
+
i.map((f) => [f.name, l])
|
|
6156
6158
|
);
|
|
6157
6159
|
a(c);
|
|
6158
6160
|
} else if (r === "fit-content") {
|
|
@@ -6160,7 +6162,7 @@ const Hs = ({
|
|
|
6160
6162
|
for (const i of n) {
|
|
6161
6163
|
if (!i.visible) continue;
|
|
6162
6164
|
const l = i.title?.length || 0, c = Math.max(
|
|
6163
|
-
...e.map((
|
|
6165
|
+
...e.map((f) => `${f.cells?.[i.name]?.decode || f.cells?.[i.name]?.value || ""}`.length),
|
|
6164
6166
|
l
|
|
6165
6167
|
);
|
|
6166
6168
|
o[i.name] = c * 8 + 24;
|
|
@@ -6180,10 +6182,10 @@ const Hs = ({
|
|
|
6180
6182
|
}) => {
|
|
6181
6183
|
const [o, i] = G(
|
|
6182
6184
|
n ?? { columns: [], rows: [] }
|
|
6183
|
-
), [l, c] = G(r || []), [
|
|
6185
|
+
), [l, c] = G(r || []), [f, u] = G(/* @__PURE__ */ new Set()), d = le(null), [g, p] = Ks({
|
|
6184
6186
|
columns: o?.columns ?? [],
|
|
6185
6187
|
rows: o?.rows ?? [],
|
|
6186
|
-
containerRef:
|
|
6188
|
+
containerRef: d,
|
|
6187
6189
|
sizingMode: s
|
|
6188
6190
|
});
|
|
6189
6191
|
ne(() => {
|
|
@@ -6192,12 +6194,12 @@ const Hs = ({
|
|
|
6192
6194
|
n.rows,
|
|
6193
6195
|
l,
|
|
6194
6196
|
e,
|
|
6195
|
-
|
|
6197
|
+
f
|
|
6196
6198
|
);
|
|
6197
6199
|
i({ ...n, rows: A });
|
|
6198
6200
|
} else
|
|
6199
6201
|
i(n);
|
|
6200
|
-
}, [n, l,
|
|
6202
|
+
}, [n, l, f, e]);
|
|
6201
6203
|
const w = (A) => {
|
|
6202
6204
|
c(Bs(A, l));
|
|
6203
6205
|
}, S = (A) => {
|
|
@@ -6214,8 +6216,8 @@ const Hs = ({
|
|
|
6214
6216
|
itemHeight: e,
|
|
6215
6217
|
containerHeight: t,
|
|
6216
6218
|
overscan: 5
|
|
6217
|
-
}),
|
|
6218
|
-
const L = A.clientX, R =
|
|
6219
|
+
}), y = (A, O) => {
|
|
6220
|
+
const L = A.clientX, R = g[O], D = (P) => {
|
|
6219
6221
|
const N = P.clientX - L, B = Math.max(50, R + N);
|
|
6220
6222
|
p((H) => ({
|
|
6221
6223
|
...H,
|
|
@@ -6235,7 +6237,7 @@ const Hs = ({
|
|
|
6235
6237
|
{
|
|
6236
6238
|
className: k.smpTable,
|
|
6237
6239
|
...T,
|
|
6238
|
-
ref:
|
|
6240
|
+
ref: d,
|
|
6239
6241
|
children: /* @__PURE__ */ m.jsxs("table", { children: [
|
|
6240
6242
|
/* @__PURE__ */ m.jsxs("thead", { children: [
|
|
6241
6243
|
(r || a) && /* @__PURE__ */ m.jsx(
|
|
@@ -6257,9 +6259,9 @@ const Hs = ({
|
|
|
6257
6259
|
O.dataTransfer.setData("text/plain", A.name);
|
|
6258
6260
|
},
|
|
6259
6261
|
style: {
|
|
6260
|
-
width:
|
|
6261
|
-
minWidth:
|
|
6262
|
-
maxWidth:
|
|
6262
|
+
width: g[A.name],
|
|
6263
|
+
minWidth: g[A.name],
|
|
6264
|
+
maxWidth: g[A.name]
|
|
6263
6265
|
},
|
|
6264
6266
|
children: [
|
|
6265
6267
|
/* @__PURE__ */ m.jsx(
|
|
@@ -6273,7 +6275,7 @@ const Hs = ({
|
|
|
6273
6275
|
"div",
|
|
6274
6276
|
{
|
|
6275
6277
|
className: k.resizer,
|
|
6276
|
-
onMouseDown: (O) =>
|
|
6278
|
+
onMouseDown: (O) => y(O, A.name),
|
|
6277
6279
|
role: "region"
|
|
6278
6280
|
}
|
|
6279
6281
|
)
|
|
@@ -6303,7 +6305,7 @@ const Hs = ({
|
|
|
6303
6305
|
Nn,
|
|
6304
6306
|
{
|
|
6305
6307
|
row: A,
|
|
6306
|
-
columnWidths:
|
|
6308
|
+
columnWidths: g,
|
|
6307
6309
|
rowHeight: e,
|
|
6308
6310
|
offsetTop: L,
|
|
6309
6311
|
isGroup: !1
|
|
@@ -6311,7 +6313,7 @@ const Hs = ({
|
|
|
6311
6313
|
`row-${R}`
|
|
6312
6314
|
);
|
|
6313
6315
|
}) }),
|
|
6314
|
-
/* @__PURE__ */ m.jsx(qs, { columns: o.columns, columnWidths:
|
|
6316
|
+
/* @__PURE__ */ m.jsx(qs, { columns: o.columns, columnWidths: g })
|
|
6315
6317
|
] })
|
|
6316
6318
|
}
|
|
6317
6319
|
);
|
|
@@ -6327,7 +6329,7 @@ const Hs = ({
|
|
|
6327
6329
|
onClick: l,
|
|
6328
6330
|
onOptionsRequest: c
|
|
6329
6331
|
}) => {
|
|
6330
|
-
const [
|
|
6332
|
+
const [f, u] = G();
|
|
6331
6333
|
ne(() => {
|
|
6332
6334
|
u(() => {
|
|
6333
6335
|
if (!n)
|
|
@@ -6336,13 +6338,13 @@ const Hs = ({
|
|
|
6336
6338
|
return e && (w.shape = e), w.shape == null && (w.shape = te.TEXT_FIELD), s && (w.obj = vr(s)), w;
|
|
6337
6339
|
});
|
|
6338
6340
|
}, [n, s, e]);
|
|
6339
|
-
const
|
|
6341
|
+
const g = {
|
|
6340
6342
|
container: `smp-field-container ${ce(t) ? `smp-field-position-${r}` : ""}`
|
|
6341
6343
|
}, p = () => {
|
|
6342
|
-
ce(t) || i?.(
|
|
6344
|
+
ce(t) || i?.(f);
|
|
6343
6345
|
};
|
|
6344
|
-
if (
|
|
6345
|
-
return /* @__PURE__ */ m.jsxs("div", { className:
|
|
6346
|
+
if (f)
|
|
6347
|
+
return /* @__PURE__ */ m.jsxs("div", { className: g.container, children: [
|
|
6346
6348
|
/* @__PURE__ */ m.jsx(
|
|
6347
6349
|
"div",
|
|
6348
6350
|
{
|
|
@@ -6355,7 +6357,7 @@ const Hs = ({
|
|
|
6355
6357
|
children: /* @__PURE__ */ m.jsx(
|
|
6356
6358
|
Te,
|
|
6357
6359
|
{
|
|
6358
|
-
...
|
|
6360
|
+
...f,
|
|
6359
6361
|
id: "FLD",
|
|
6360
6362
|
onChange: u,
|
|
6361
6363
|
onOptionsRequest: c,
|
|
@@ -6372,7 +6374,7 @@ const Hs = ({
|
|
|
6372
6374
|
we,
|
|
6373
6375
|
{
|
|
6374
6376
|
optionalDisplayValue: "Confirm",
|
|
6375
|
-
onClick: () => l?.(
|
|
6377
|
+
onClick: () => l?.(f),
|
|
6376
6378
|
bindValue: "Confirm"
|
|
6377
6379
|
}
|
|
6378
6380
|
)
|
|
@@ -6401,15 +6403,15 @@ const Hs = ({
|
|
|
6401
6403
|
onSubmit: i,
|
|
6402
6404
|
onCheck: l,
|
|
6403
6405
|
onCheckObj: c,
|
|
6404
|
-
onContextMenu:
|
|
6406
|
+
onContextMenu: f,
|
|
6405
6407
|
onButtonClick: u
|
|
6406
6408
|
}) => {
|
|
6407
|
-
const [
|
|
6409
|
+
const [d, g] = G({}), { translate: p } = $e(), w = Ce();
|
|
6408
6410
|
ne(() => {
|
|
6409
|
-
|
|
6411
|
+
g(v(n));
|
|
6410
6412
|
}, [n]);
|
|
6411
6413
|
const S = (O, L) => {
|
|
6412
|
-
if (
|
|
6414
|
+
if (g((R) => ({
|
|
6413
6415
|
...R,
|
|
6414
6416
|
[O]: {
|
|
6415
6417
|
...R[O],
|
|
@@ -6426,14 +6428,14 @@ const Hs = ({
|
|
|
6426
6428
|
value: L.obj.k
|
|
6427
6429
|
}
|
|
6428
6430
|
})), s && (L.shape == te.CHECKBOX || L.shape == te.SWITCH)) {
|
|
6429
|
-
const R = structuredClone(
|
|
6431
|
+
const R = structuredClone(d);
|
|
6430
6432
|
R[O].obj.k = L.obj.k, R[O].value = L.obj.k, i({
|
|
6431
|
-
value:
|
|
6433
|
+
value: y(R),
|
|
6432
6434
|
cell: O
|
|
6433
6435
|
});
|
|
6434
6436
|
}
|
|
6435
6437
|
}, E = (O) => {
|
|
6436
|
-
const L =
|
|
6438
|
+
const L = y(d);
|
|
6437
6439
|
i({
|
|
6438
6440
|
value: L,
|
|
6439
6441
|
cell: O
|
|
@@ -6446,18 +6448,18 @@ const Hs = ({
|
|
|
6446
6448
|
columns: n.columns,
|
|
6447
6449
|
rows: [
|
|
6448
6450
|
{
|
|
6449
|
-
cells:
|
|
6451
|
+
cells: d
|
|
6450
6452
|
}
|
|
6451
6453
|
]
|
|
6452
6454
|
},
|
|
6453
6455
|
fun: L || ""
|
|
6454
6456
|
});
|
|
6455
6457
|
}, T = async (O) => {
|
|
6456
|
-
if (
|
|
6457
|
-
obj:
|
|
6458
|
-
fun:
|
|
6458
|
+
if (d[O].obj.k != n.rows[0].cells[O].obj.k && (d[O].inputSettings?.checkObject && c && ((await c({
|
|
6459
|
+
obj: d[O].obj,
|
|
6460
|
+
fun: d[O].fun,
|
|
6459
6461
|
cellId: O
|
|
6460
|
-
})).valid ||
|
|
6462
|
+
})).valid || g((R) => ({
|
|
6461
6463
|
...R,
|
|
6462
6464
|
[O]: {
|
|
6463
6465
|
...R[O],
|
|
@@ -6466,8 +6468,8 @@ const Hs = ({
|
|
|
6466
6468
|
error: p(Ee.CHECK_OBJECT_WRONG_VALIDATION)
|
|
6467
6469
|
}
|
|
6468
6470
|
}
|
|
6469
|
-
}))),
|
|
6470
|
-
const L =
|
|
6471
|
+
}))), d[O].inputSettings?.checkValueOnExit)) {
|
|
6472
|
+
const L = y(d);
|
|
6471
6473
|
l?.({
|
|
6472
6474
|
value: L,
|
|
6473
6475
|
cell: O
|
|
@@ -6493,7 +6495,7 @@ const Hs = ({
|
|
|
6493
6495
|
[D.name]: C
|
|
6494
6496
|
};
|
|
6495
6497
|
}, {});
|
|
6496
|
-
},
|
|
6498
|
+
}, y = (O) => ({
|
|
6497
6499
|
before: n,
|
|
6498
6500
|
after: {
|
|
6499
6501
|
type: "SmeupDataTable",
|
|
@@ -6541,7 +6543,7 @@ const Hs = ({
|
|
|
6541
6543
|
const A = {
|
|
6542
6544
|
smpForm: `${Zs["smp-form"]}`
|
|
6543
6545
|
};
|
|
6544
|
-
return
|
|
6546
|
+
return d && /* @__PURE__ */ m.jsxs(
|
|
6545
6547
|
"form",
|
|
6546
6548
|
{
|
|
6547
6549
|
"data-component": "input-panel",
|
|
@@ -6551,7 +6553,7 @@ const Hs = ({
|
|
|
6551
6553
|
O.preventDefault(), E();
|
|
6552
6554
|
},
|
|
6553
6555
|
children: [
|
|
6554
|
-
/* @__PURE__ */ m.jsx(at, { layout: n.rows[0].layout, children: Object.values(
|
|
6556
|
+
/* @__PURE__ */ m.jsx(at, { layout: n.rows[0].layout, children: Object.values(d).map((O) => /* @__PURE__ */ m.jsx(
|
|
6555
6557
|
Te,
|
|
6556
6558
|
{
|
|
6557
6559
|
...O,
|
|
@@ -6560,7 +6562,7 @@ const Hs = ({
|
|
|
6560
6562
|
) : void 0,
|
|
6561
6563
|
onChange: (L) => S(O.id, L),
|
|
6562
6564
|
onBlur: () => T(O.id),
|
|
6563
|
-
onContextMenu:
|
|
6565
|
+
onContextMenu: f,
|
|
6564
6566
|
onClick: () => {
|
|
6565
6567
|
O.shape == "BTN" && b(O.id, O.fun);
|
|
6566
6568
|
},
|
|
@@ -6597,14 +6599,14 @@ export {
|
|
|
6597
6599
|
In as Autocomplete,
|
|
6598
6600
|
we as Button,
|
|
6599
6601
|
us as ButtonList,
|
|
6600
|
-
|
|
6602
|
+
ds as Checkbox,
|
|
6601
6603
|
ps as Combobox,
|
|
6602
6604
|
sa as DashList,
|
|
6603
6605
|
aa as DataTableComponent,
|
|
6604
6606
|
gs as DatePicker,
|
|
6605
6607
|
ra as Drawer,
|
|
6606
6608
|
oa as Field,
|
|
6607
|
-
|
|
6609
|
+
fe as Icon,
|
|
6608
6610
|
ia as InputPanel,
|
|
6609
6611
|
bs as Password,
|
|
6610
6612
|
gr as TabBar,
|