react-luminus-components 1.2.101 → 1.2.103
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/components/common/AppSearch/AppSearch.d.ts +2 -1
- package/dist/main.cjs.js +1 -1
- package/dist/main.es.js +324 -325
- package/package.json +1 -1
package/dist/main.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { j as o, c as
|
|
1
|
+
import { j as o, c as w, t as J, a as oe, g as hr, T as mr, b as fr, s as kt, E as pr, d as gr, e as xr, f as wr, h as vr, u as V, i as me, k as Xt, F as Nt, l as yr, m as br, n as _r, o as jr, p as kr, q as Nr, r as Cr, v as Ir, w as ut, x as Jt, y as $r, z as Sr, A as be, B as Tr, C as Er, P as Xe, D as dt, S as Ct, G as Me, H as Ae, I as ht, J as Dr, K as Zt, L as $e, M as Le, O as It, N as Or, Q as ae, R as Pr, U as Mr, V as en, W as mt, X as ft, Y as G, Z as Ar, _ as tn, $ as Fr, a0 as nn, a1 as pt, a2 as Wr, a3 as Rr, a4 as Yr, a5 as rn, a6 as ce, a7 as Lr, a8 as qr, a9 as Hr, aa as Br, ab as sn, ac as Vr, ad as Gr, ae as Je, af as ke, ag as on, ah as fe } from "./NoInputContainer-0WkO5fEr.js";
|
|
2
2
|
import { aj as Fl, ai as Wl } from "./NoInputContainer-0WkO5fEr.js";
|
|
3
3
|
import * as W from "react";
|
|
4
4
|
import ne, { useCallback as S, useMemo as K, useEffect as O, useRef as q, useState as P, useReducer as an, useContext as Y, Component as zr, isValidElement as Ur, Suspense as Kr, createElement as Qr } from "react";
|
|
@@ -18,10 +18,10 @@ const tl = ({ fileLoader: n, fileName: e, children: t }) => {
|
|
|
18
18
|
i.href = a, i.setAttribute("download", e), (l = document.body) == null || l.appendChild(i), i.click(), (c = document.body) == null || c.removeChild(i);
|
|
19
19
|
}, [n, e]);
|
|
20
20
|
return /* @__PURE__ */ o.jsx("div", { role: "button", onClick: r, children: t });
|
|
21
|
-
}, ss = ({ className: n, ...e }) => /* @__PURE__ */ o.jsxs("div", { className:
|
|
22
|
-
/* @__PURE__ */ o.jsx("div", { className:
|
|
23
|
-
/* @__PURE__ */ o.jsx("div", { className:
|
|
24
|
-
/* @__PURE__ */ o.jsx("div", { className:
|
|
21
|
+
}, ss = ({ className: n, ...e }) => /* @__PURE__ */ o.jsxs("div", { className: w("luminus-loading", de.loading, de.loadingBlock, de.loadingBlock), ...e, children: [
|
|
22
|
+
/* @__PURE__ */ o.jsx("div", { className: w("spinner-grow", de.spinnerGrow, "text-primary"), role: "status" }),
|
|
23
|
+
/* @__PURE__ */ o.jsx("div", { className: w("spinner-grow", de.spinnerGrow, "text-primary", de.second), role: "status" }),
|
|
24
|
+
/* @__PURE__ */ o.jsx("div", { className: w("spinner-grow", de.spinnerGrow, "text-primary", de.third), role: "status" })
|
|
25
25
|
] });
|
|
26
26
|
function pn(n, e) {
|
|
27
27
|
const t = J(n);
|
|
@@ -546,8 +546,8 @@ function zs(n) {
|
|
|
546
546
|
return Math.round(t / un) + 1;
|
|
547
547
|
}
|
|
548
548
|
function xn(n, e) {
|
|
549
|
-
var d, h,
|
|
550
|
-
const t = J(n), r = t.getFullYear(), s = Ge(), a = (e == null ? void 0 : e.firstWeekContainsDate) ?? ((h = (d = e == null ? void 0 : e.locale) == null ? void 0 : d.options) == null ? void 0 : h.firstWeekContainsDate) ?? s.firstWeekContainsDate ?? ((g = (
|
|
549
|
+
var d, h, p, g;
|
|
550
|
+
const t = J(n), r = t.getFullYear(), s = Ge(), a = (e == null ? void 0 : e.firstWeekContainsDate) ?? ((h = (d = e == null ? void 0 : e.locale) == null ? void 0 : d.options) == null ? void 0 : h.firstWeekContainsDate) ?? s.firstWeekContainsDate ?? ((g = (p = s.locale) == null ? void 0 : p.options) == null ? void 0 : g.firstWeekContainsDate) ?? 1, i = oe(n, 0);
|
|
551
551
|
i.setFullYear(r + 1, 0, a), i.setHours(0, 0, 0, 0);
|
|
552
552
|
const l = Te(i, e), c = oe(n, 0);
|
|
553
553
|
c.setFullYear(r, 0, a), c.setHours(0, 0, 0, 0);
|
|
@@ -1195,8 +1195,8 @@ function so(n, e, t) {
|
|
|
1195
1195
|
}
|
|
1196
1196
|
const oo = /[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g, ao = /P+p+|P+|p+|''|'(''|[^'])+('|$)|./g, io = /^'([^]*?)'?$/, co = /''/g, lo = /[a-zA-Z]/;
|
|
1197
1197
|
function ot(n, e, t) {
|
|
1198
|
-
var d, h,
|
|
1199
|
-
const r = Ge(), s = (t == null ? void 0 : t.locale) ?? r.locale ?? Vs, a = (t == null ? void 0 : t.firstWeekContainsDate) ?? ((h = (d = t == null ? void 0 : t.locale) == null ? void 0 : d.options) == null ? void 0 : h.firstWeekContainsDate) ?? r.firstWeekContainsDate ?? ((g = (
|
|
1198
|
+
var d, h, p, g, b, x, f, _;
|
|
1199
|
+
const r = Ge(), s = (t == null ? void 0 : t.locale) ?? r.locale ?? Vs, a = (t == null ? void 0 : t.firstWeekContainsDate) ?? ((h = (d = t == null ? void 0 : t.locale) == null ? void 0 : d.options) == null ? void 0 : h.firstWeekContainsDate) ?? r.firstWeekContainsDate ?? ((g = (p = r.locale) == null ? void 0 : p.options) == null ? void 0 : g.firstWeekContainsDate) ?? 1, i = (t == null ? void 0 : t.weekStartsOn) ?? ((x = (b = t == null ? void 0 : t.locale) == null ? void 0 : b.options) == null ? void 0 : x.weekStartsOn) ?? r.weekStartsOn ?? ((_ = (f = r.locale) == null ? void 0 : f.options) == null ? void 0 : _.weekStartsOn) ?? 0, l = J(n);
|
|
1200
1200
|
if (!ds(l))
|
|
1201
1201
|
throw new RangeError("Invalid time value");
|
|
1202
1202
|
let c = e.match(ao).map((k) => {
|
|
@@ -1311,24 +1311,24 @@ const wo = {
|
|
|
1311
1311
|
timeout: u = 300,
|
|
1312
1312
|
mountOnEnter: d = !1,
|
|
1313
1313
|
unmountOnExit: h = !1,
|
|
1314
|
-
appear:
|
|
1314
|
+
appear: p = !1,
|
|
1315
1315
|
getDimensionValue: g = xo,
|
|
1316
1316
|
...b
|
|
1317
|
-
},
|
|
1318
|
-
const
|
|
1319
|
-
v.style[
|
|
1320
|
-
}, n), [
|
|
1321
|
-
const $ = `scroll${
|
|
1322
|
-
v.style[
|
|
1323
|
-
}, e), [
|
|
1324
|
-
v.style[
|
|
1325
|
-
}, t), [
|
|
1326
|
-
v.style[
|
|
1327
|
-
}, r), [r, g,
|
|
1328
|
-
v.style[
|
|
1329
|
-
}, s), [
|
|
1317
|
+
}, x) => {
|
|
1318
|
+
const f = typeof l == "function" ? l() : l, _ = K(() => Ie((v) => {
|
|
1319
|
+
v.style[f] = "0";
|
|
1320
|
+
}, n), [f, n]), k = K(() => Ie((v) => {
|
|
1321
|
+
const $ = `scroll${f[0].toUpperCase()}${f.slice(1)}`;
|
|
1322
|
+
v.style[f] = `${v[$]}px`;
|
|
1323
|
+
}, e), [f, e]), m = K(() => Ie((v) => {
|
|
1324
|
+
v.style[f] = null;
|
|
1325
|
+
}, t), [f, t]), N = K(() => Ie((v) => {
|
|
1326
|
+
v.style[f] = `${g(f, v)}px`, vr(v);
|
|
1327
|
+
}, r), [r, g, f]), j = K(() => Ie((v) => {
|
|
1328
|
+
v.style[f] = null;
|
|
1329
|
+
}, s), [f, s]);
|
|
1330
1330
|
return /* @__PURE__ */ o.jsx(mr, {
|
|
1331
|
-
ref:
|
|
1331
|
+
ref: x,
|
|
1332
1332
|
addEndListener: fr,
|
|
1333
1333
|
...b,
|
|
1334
1334
|
"aria-expanded": b.role ? c : null,
|
|
@@ -1342,10 +1342,10 @@ const wo = {
|
|
|
1342
1342
|
timeout: u,
|
|
1343
1343
|
mountOnEnter: d,
|
|
1344
1344
|
unmountOnExit: h,
|
|
1345
|
-
appear:
|
|
1345
|
+
appear: p,
|
|
1346
1346
|
children: (v, $) => /* @__PURE__ */ ne.cloneElement(i, {
|
|
1347
1347
|
...$,
|
|
1348
|
-
className:
|
|
1348
|
+
className: w(a, i.props.className, wo[v], f === "width" && "collapse-horizontal")
|
|
1349
1349
|
})
|
|
1350
1350
|
});
|
|
1351
1351
|
}), bn = Xr("h4");
|
|
@@ -1357,7 +1357,7 @@ const _n = /* @__PURE__ */ W.forwardRef(({
|
|
|
1357
1357
|
...r
|
|
1358
1358
|
}, s) => (e = V(e, "alert-heading"), /* @__PURE__ */ o.jsx(t, {
|
|
1359
1359
|
ref: s,
|
|
1360
|
-
className:
|
|
1360
|
+
className: w(n, e),
|
|
1361
1361
|
...r
|
|
1362
1362
|
})));
|
|
1363
1363
|
_n.displayName = "AlertHeading";
|
|
@@ -1400,14 +1400,14 @@ function gt({
|
|
|
1400
1400
|
type: c || "button",
|
|
1401
1401
|
disabled: e
|
|
1402
1402
|
}, u];
|
|
1403
|
-
const d = (
|
|
1404
|
-
if ((e || n === "a" && _o(t)) &&
|
|
1405
|
-
|
|
1403
|
+
const d = (p) => {
|
|
1404
|
+
if ((e || n === "a" && _o(t)) && p.preventDefault(), e) {
|
|
1405
|
+
p.stopPropagation();
|
|
1406
1406
|
return;
|
|
1407
1407
|
}
|
|
1408
|
-
i == null || i(
|
|
1409
|
-
}, h = (
|
|
1410
|
-
|
|
1408
|
+
i == null || i(p);
|
|
1409
|
+
}, h = (p) => {
|
|
1410
|
+
p.key === " " && (p.preventDefault(), d(p));
|
|
1411
1411
|
};
|
|
1412
1412
|
return n === "a" && (t || (t = "#"), e && (t = void 0)), [{
|
|
1413
1413
|
role: a ?? "button",
|
|
@@ -1478,7 +1478,7 @@ const kn = /* @__PURE__ */ W.forwardRef(({
|
|
|
1478
1478
|
...r
|
|
1479
1479
|
}, s) => (e = V(e, "alert-link"), /* @__PURE__ */ o.jsx(t, {
|
|
1480
1480
|
ref: s,
|
|
1481
|
-
className:
|
|
1481
|
+
className: w(n, e),
|
|
1482
1482
|
...r
|
|
1483
1483
|
})));
|
|
1484
1484
|
kn.displayName = "AlertLink";
|
|
@@ -1494,29 +1494,29 @@ const Nn = /* @__PURE__ */ W.forwardRef((n, e) => {
|
|
|
1494
1494
|
onClose: u,
|
|
1495
1495
|
dismissible: d,
|
|
1496
1496
|
transition: h = Nt,
|
|
1497
|
-
...
|
|
1497
|
+
...p
|
|
1498
1498
|
} = Xt(n, {
|
|
1499
1499
|
show: "onClose"
|
|
1500
1500
|
}), g = V(t, "alert"), b = me((_) => {
|
|
1501
1501
|
u && u(!1, _);
|
|
1502
|
-
}),
|
|
1502
|
+
}), x = h === !0 ? Nt : h, f = /* @__PURE__ */ o.jsxs("div", {
|
|
1503
1503
|
role: "alert",
|
|
1504
|
-
...
|
|
1504
|
+
...x ? void 0 : p,
|
|
1505
1505
|
ref: e,
|
|
1506
|
-
className:
|
|
1506
|
+
className: w(i, g, c && `${g}-${c}`, d && `${g}-dismissible`),
|
|
1507
1507
|
children: [d && /* @__PURE__ */ o.jsx(Jr, {
|
|
1508
1508
|
onClick: b,
|
|
1509
1509
|
"aria-label": s,
|
|
1510
1510
|
variant: a
|
|
1511
1511
|
}), l]
|
|
1512
1512
|
});
|
|
1513
|
-
return
|
|
1513
|
+
return x ? /* @__PURE__ */ o.jsx(x, {
|
|
1514
1514
|
unmountOnExit: !0,
|
|
1515
|
-
...
|
|
1515
|
+
...p,
|
|
1516
1516
|
ref: void 0,
|
|
1517
1517
|
in: r,
|
|
1518
|
-
children:
|
|
1519
|
-
}) : r ?
|
|
1518
|
+
children: f
|
|
1519
|
+
}) : r ? f : null;
|
|
1520
1520
|
});
|
|
1521
1521
|
Nn.displayName = "Alert";
|
|
1522
1522
|
const Co = Object.assign(Nn, {
|
|
@@ -1538,13 +1538,13 @@ const Co = Object.assign(Nn, {
|
|
|
1538
1538
|
tagName: n,
|
|
1539
1539
|
disabled: a,
|
|
1540
1540
|
...l
|
|
1541
|
-
}),
|
|
1542
|
-
return /* @__PURE__ */ o.jsx(
|
|
1541
|
+
}), p = h;
|
|
1542
|
+
return /* @__PURE__ */ o.jsx(p, {
|
|
1543
1543
|
...d,
|
|
1544
1544
|
...l,
|
|
1545
1545
|
ref: c,
|
|
1546
1546
|
disabled: a,
|
|
1547
|
-
className:
|
|
1547
|
+
className: w(i, u, s && "active", t && `${u}-${t}`, r && `${u}-${r}`, l.href && a && "disabled")
|
|
1548
1548
|
});
|
|
1549
1549
|
});
|
|
1550
1550
|
Cn.displayName = "Button";
|
|
@@ -1562,17 +1562,17 @@ function $o({
|
|
|
1562
1562
|
return s.forEach((c) => {
|
|
1563
1563
|
const u = r[c];
|
|
1564
1564
|
delete r[c];
|
|
1565
|
-
let d, h,
|
|
1565
|
+
let d, h, p;
|
|
1566
1566
|
typeof u == "object" && u != null ? {
|
|
1567
1567
|
span: d,
|
|
1568
1568
|
offset: h,
|
|
1569
|
-
order:
|
|
1569
|
+
order: p
|
|
1570
1570
|
} = u : d = u;
|
|
1571
1571
|
const g = c !== a ? `-${c}` : "";
|
|
1572
|
-
d && i.push(d === !0 ? `${e}${g}` : `${e}${g}-${d}`),
|
|
1572
|
+
d && i.push(d === !0 ? `${e}${g}` : `${e}${g}-${d}`), p != null && l.push(`order${g}-${p}`), h != null && l.push(`offset${g}-${h}`);
|
|
1573
1573
|
}), [{
|
|
1574
1574
|
...r,
|
|
1575
|
-
className:
|
|
1575
|
+
className: w(t, ...i, ...l)
|
|
1576
1576
|
}, {
|
|
1577
1577
|
as: n,
|
|
1578
1578
|
bsPrefix: e,
|
|
@@ -1593,7 +1593,7 @@ const In = /* @__PURE__ */ W.forwardRef(
|
|
|
1593
1593
|
return /* @__PURE__ */ o.jsx(s, {
|
|
1594
1594
|
...r,
|
|
1595
1595
|
ref: e,
|
|
1596
|
-
className:
|
|
1596
|
+
className: w(t, !i.length && a)
|
|
1597
1597
|
});
|
|
1598
1598
|
}
|
|
1599
1599
|
);
|
|
@@ -1630,19 +1630,19 @@ function $n(n = {}) {
|
|
|
1630
1630
|
placement: u,
|
|
1631
1631
|
popperConfig: d = {},
|
|
1632
1632
|
enableEventListeners: h = !0,
|
|
1633
|
-
usePopper:
|
|
1633
|
+
usePopper: p = !!e
|
|
1634
1634
|
} = n, g = (e == null ? void 0 : e.show) == null ? !!n.show : e.show;
|
|
1635
1635
|
g && !s.current && (s.current = !0);
|
|
1636
1636
|
const b = (v) => {
|
|
1637
1637
|
e == null || e.toggle(!1, v);
|
|
1638
1638
|
}, {
|
|
1639
|
-
placement:
|
|
1640
|
-
setMenu:
|
|
1639
|
+
placement: x,
|
|
1640
|
+
setMenu: f,
|
|
1641
1641
|
menuElement: _,
|
|
1642
1642
|
toggleElement: k
|
|
1643
1643
|
} = e || {}, m = jr(k, _, kr({
|
|
1644
|
-
placement: u ||
|
|
1645
|
-
enabled:
|
|
1644
|
+
placement: u || x || "bottom-start",
|
|
1645
|
+
enabled: p,
|
|
1646
1646
|
enableEvents: h ?? g,
|
|
1647
1647
|
offset: i,
|
|
1648
1648
|
flip: a,
|
|
@@ -1650,17 +1650,17 @@ function $n(n = {}) {
|
|
|
1650
1650
|
arrowElement: t,
|
|
1651
1651
|
popperConfig: d
|
|
1652
1652
|
})), N = Object.assign({
|
|
1653
|
-
ref:
|
|
1653
|
+
ref: f || Oo,
|
|
1654
1654
|
"aria-labelledby": k == null ? void 0 : k.id
|
|
1655
1655
|
}, m.attributes.popper, {
|
|
1656
1656
|
style: m.styles.popper
|
|
1657
1657
|
}), j = {
|
|
1658
1658
|
show: g,
|
|
1659
|
-
placement:
|
|
1659
|
+
placement: x,
|
|
1660
1660
|
hasShown: s.current,
|
|
1661
1661
|
toggle: e == null ? void 0 : e.toggle,
|
|
1662
|
-
popper:
|
|
1663
|
-
arrowProps:
|
|
1662
|
+
popper: p ? m : null,
|
|
1663
|
+
arrowProps: p ? Object.assign({
|
|
1664
1664
|
ref: r
|
|
1665
1665
|
}, m.attributes.arrow, {
|
|
1666
1666
|
style: m.styles.arrow
|
|
@@ -1830,7 +1830,7 @@ function De({
|
|
|
1830
1830
|
placement: i = "bottom-start",
|
|
1831
1831
|
children: l
|
|
1832
1832
|
}) {
|
|
1833
|
-
const c = Cr(), [u, d] = So(e, n, r), [h,
|
|
1833
|
+
const c = Cr(), [u, d] = So(e, n, r), [h, p] = Rt(), g = h.current, [b, x] = Rt(), f = b.current, _ = Zr(u), k = q(null), m = q(!1), N = Y(at), j = S((y, C, F = C == null ? void 0 : C.type) => {
|
|
1834
1834
|
d(y, {
|
|
1835
1835
|
originalEvent: C,
|
|
1836
1836
|
source: F
|
|
@@ -1842,13 +1842,13 @@ function De({
|
|
|
1842
1842
|
placement: i,
|
|
1843
1843
|
show: u,
|
|
1844
1844
|
menuElement: g,
|
|
1845
|
-
toggleElement:
|
|
1846
|
-
setMenu:
|
|
1847
|
-
setToggle:
|
|
1848
|
-
}), [j, i, u, g,
|
|
1845
|
+
toggleElement: f,
|
|
1846
|
+
setMenu: p,
|
|
1847
|
+
setToggle: x
|
|
1848
|
+
}), [j, i, u, g, f, p, x]);
|
|
1849
1849
|
g && _ && !u && (m.current = g.contains(g.ownerDocument.activeElement));
|
|
1850
1850
|
const D = me(() => {
|
|
1851
|
-
|
|
1851
|
+
f && f.focus && f.focus();
|
|
1852
1852
|
}), I = me(() => {
|
|
1853
1853
|
const y = k.current;
|
|
1854
1854
|
let C = a;
|
|
@@ -1929,7 +1929,7 @@ const Fn = /* @__PURE__ */ W.forwardRef(({
|
|
|
1929
1929
|
...s
|
|
1930
1930
|
}, a) => (e = V(e, "dropdown-divider"), /* @__PURE__ */ o.jsx(t, {
|
|
1931
1931
|
ref: a,
|
|
1932
|
-
className:
|
|
1932
|
+
className: w(n, e),
|
|
1933
1933
|
role: r,
|
|
1934
1934
|
...s
|
|
1935
1935
|
})));
|
|
@@ -1942,7 +1942,7 @@ const Wn = /* @__PURE__ */ W.forwardRef(({
|
|
|
1942
1942
|
...s
|
|
1943
1943
|
}, a) => (e = V(e, "dropdown-header"), /* @__PURE__ */ o.jsx(t, {
|
|
1944
1944
|
ref: a,
|
|
1945
|
-
className:
|
|
1945
|
+
className: w(n, e),
|
|
1946
1946
|
role: r,
|
|
1947
1947
|
...s
|
|
1948
1948
|
})));
|
|
@@ -1968,7 +1968,7 @@ const Rn = /* @__PURE__ */ W.forwardRef(({
|
|
|
1968
1968
|
...l,
|
|
1969
1969
|
...d,
|
|
1970
1970
|
ref: c,
|
|
1971
|
-
className:
|
|
1971
|
+
className: w(e, u, h.isActive && "active", r && "disabled")
|
|
1972
1972
|
});
|
|
1973
1973
|
});
|
|
1974
1974
|
Rn.displayName = "DropdownItem";
|
|
@@ -1979,7 +1979,7 @@ const Yn = /* @__PURE__ */ W.forwardRef(({
|
|
|
1979
1979
|
...r
|
|
1980
1980
|
}, s) => (e = V(e, "dropdown-item-text"), /* @__PURE__ */ o.jsx(t, {
|
|
1981
1981
|
ref: s,
|
|
1982
|
-
className:
|
|
1982
|
+
className: w(n, e),
|
|
1983
1983
|
...r
|
|
1984
1984
|
})));
|
|
1985
1985
|
Yn.displayName = "DropdownItemText";
|
|
@@ -2014,24 +2014,24 @@ const Bn = /* @__PURE__ */ W.forwardRef(({
|
|
|
2014
2014
|
variant: u,
|
|
2015
2015
|
...d
|
|
2016
2016
|
}, h) => {
|
|
2017
|
-
let
|
|
2017
|
+
let p = !1;
|
|
2018
2018
|
const g = Y(Ln), b = V(n, "dropdown-menu"), {
|
|
2019
|
-
align:
|
|
2020
|
-
drop:
|
|
2019
|
+
align: x,
|
|
2020
|
+
drop: f,
|
|
2021
2021
|
isRTL: _
|
|
2022
2022
|
} = Y(wt);
|
|
2023
|
-
t = t ||
|
|
2023
|
+
t = t || x;
|
|
2024
2024
|
const k = Y(Ue), m = [];
|
|
2025
2025
|
if (t)
|
|
2026
2026
|
if (typeof t == "object") {
|
|
2027
2027
|
const y = Object.keys(t);
|
|
2028
2028
|
if (process.env.NODE_ENV !== "production" && Jt(y.length === 1, "There should only be 1 breakpoint when passing an object to `align`"), y.length) {
|
|
2029
2029
|
const C = y[0], F = t[C];
|
|
2030
|
-
|
|
2030
|
+
p = F === "start", m.push(`${b}-${C}-${F}`);
|
|
2031
2031
|
}
|
|
2032
2032
|
} else
|
|
2033
|
-
t === "end" && (
|
|
2034
|
-
const N = Hn(
|
|
2033
|
+
t === "end" && (p = !0);
|
|
2034
|
+
const N = Hn(p, f, _), [j, {
|
|
2035
2035
|
hasShown: v,
|
|
2036
2036
|
popper: $,
|
|
2037
2037
|
show: D,
|
|
@@ -2061,7 +2061,7 @@ const Bn = /* @__PURE__ */ W.forwardRef(({
|
|
|
2061
2061
|
...(m.length || g) && {
|
|
2062
2062
|
"data-bs-popper": "static"
|
|
2063
2063
|
},
|
|
2064
|
-
className:
|
|
2064
|
+
className: w(e, b, D && "show", p && `${b}-end`, u && `${b}-${u}`, ...m)
|
|
2065
2065
|
});
|
|
2066
2066
|
});
|
|
2067
2067
|
Bn.displayName = "DropdownMenu";
|
|
@@ -2078,7 +2078,7 @@ const Vn = /* @__PURE__ */ W.forwardRef(({
|
|
|
2078
2078
|
r !== void 0 && (a.bsPrefix = r);
|
|
2079
2079
|
const [u] = Dn();
|
|
2080
2080
|
return u.ref = ut(u.ref, qn(i, "DropdownToggle")), /* @__PURE__ */ o.jsx(s, {
|
|
2081
|
-
className:
|
|
2081
|
+
className: w(t, l, e && `${l}-split`, (c == null ? void 0 : c.show) && "show"),
|
|
2082
2082
|
...u,
|
|
2083
2083
|
...a
|
|
2084
2084
|
});
|
|
@@ -2097,20 +2097,20 @@ const Gn = /* @__PURE__ */ W.forwardRef((n, e) => {
|
|
|
2097
2097
|
// Need to define the default "as" during prop destructuring to be compatible with styled-components github.com/react-bootstrap/react-bootstrap/issues/3595
|
|
2098
2098
|
as: d = "div",
|
|
2099
2099
|
navbar: h,
|
|
2100
|
-
autoClose:
|
|
2100
|
+
autoClose: p = !0,
|
|
2101
2101
|
...g
|
|
2102
2102
|
} = Xt(n, {
|
|
2103
2103
|
show: "onToggle"
|
|
2104
|
-
}), b = Y(Ue),
|
|
2104
|
+
}), b = Y(Ue), x = V(t, "dropdown"), f = Sr(), _ = ($) => p === !1 ? $ === "click" : p === "inside" ? $ !== "rootClose" : p === "outside" ? $ !== "select" : !0, k = me(($, D) => {
|
|
2105
2105
|
var I, T;
|
|
2106
2106
|
!((I = D.originalEvent) == null || (T = I.target) == null) && T.classList.contains("dropdown-toggle") && D.source === "mousedown" || (D.originalEvent.currentTarget === document && (D.source !== "keydown" || D.originalEvent.key === "Escape") && (D.source = "rootClose"), _(D.source) && (c == null || c($, D)));
|
|
2107
|
-
}), N = Hn(i === "end", r,
|
|
2107
|
+
}), N = Hn(i === "end", r, f), j = K(() => ({
|
|
2108
2108
|
align: i,
|
|
2109
2109
|
drop: r,
|
|
2110
|
-
isRTL:
|
|
2111
|
-
}), [i, r,
|
|
2112
|
-
down:
|
|
2113
|
-
"down-centered": `${
|
|
2110
|
+
isRTL: f
|
|
2111
|
+
}), [i, r, f]), v = {
|
|
2112
|
+
down: x,
|
|
2113
|
+
"down-centered": `${x}-center`,
|
|
2114
2114
|
up: "dropup",
|
|
2115
2115
|
"up-centered": "dropup-center dropup",
|
|
2116
2116
|
end: "dropend",
|
|
@@ -2124,11 +2124,11 @@ const Gn = /* @__PURE__ */ W.forwardRef((n, e) => {
|
|
|
2124
2124
|
onSelect: l,
|
|
2125
2125
|
onToggle: k,
|
|
2126
2126
|
focusFirstItemOnShow: u,
|
|
2127
|
-
itemSelector: `.${
|
|
2127
|
+
itemSelector: `.${x}-item:not(.disabled):not(:disabled)`,
|
|
2128
2128
|
children: b ? g.children : /* @__PURE__ */ o.jsx(d, {
|
|
2129
2129
|
...g,
|
|
2130
2130
|
ref: e,
|
|
2131
|
-
className:
|
|
2131
|
+
className: w(a, s && "show", v[r])
|
|
2132
2132
|
})
|
|
2133
2133
|
})
|
|
2134
2134
|
});
|
|
@@ -2160,7 +2160,7 @@ const Ee = Object.assign(Gn, {
|
|
|
2160
2160
|
ref: c,
|
|
2161
2161
|
type: r,
|
|
2162
2162
|
id: n || u,
|
|
2163
|
-
className:
|
|
2163
|
+
className: w(t, e, s && "is-valid", a && "is-invalid")
|
|
2164
2164
|
});
|
|
2165
2165
|
});
|
|
2166
2166
|
Oe.displayName = "FormCheckInput";
|
|
@@ -2177,7 +2177,7 @@ const Be = /* @__PURE__ */ W.forwardRef(({
|
|
|
2177
2177
|
...r,
|
|
2178
2178
|
ref: s,
|
|
2179
2179
|
htmlFor: t || a,
|
|
2180
|
-
className:
|
|
2180
|
+
className: w(e, n)
|
|
2181
2181
|
});
|
|
2182
2182
|
});
|
|
2183
2183
|
Be.displayName = "FormCheckLabel";
|
|
@@ -2194,11 +2194,11 @@ const zn = /* @__PURE__ */ W.forwardRef(({
|
|
|
2194
2194
|
feedback: u,
|
|
2195
2195
|
feedbackType: d,
|
|
2196
2196
|
className: h,
|
|
2197
|
-
style:
|
|
2197
|
+
style: p,
|
|
2198
2198
|
title: g = "",
|
|
2199
2199
|
type: b = "checkbox",
|
|
2200
|
-
label:
|
|
2201
|
-
children:
|
|
2200
|
+
label: x,
|
|
2201
|
+
children: f,
|
|
2202
2202
|
// Need to define the default "as" during prop destructuring to be compatible with styled-components github.com/react-bootstrap/react-bootstrap/issues/3595
|
|
2203
2203
|
as: _ = "input",
|
|
2204
2204
|
...k
|
|
@@ -2208,7 +2208,7 @@ const zn = /* @__PURE__ */ W.forwardRef(({
|
|
|
2208
2208
|
controlId: N
|
|
2209
2209
|
} = Y(be), j = K(() => ({
|
|
2210
2210
|
controlId: n || N
|
|
2211
|
-
}), [N, n]), v = !
|
|
2211
|
+
}), [N, n]), v = !f && x != null && x !== !1 || Io(f, Be), $ = /* @__PURE__ */ o.jsx(Oe, {
|
|
2212
2212
|
...k,
|
|
2213
2213
|
type: b === "switch" ? "checkbox" : b,
|
|
2214
2214
|
ref: m,
|
|
@@ -2220,12 +2220,12 @@ const zn = /* @__PURE__ */ W.forwardRef(({
|
|
|
2220
2220
|
return /* @__PURE__ */ o.jsx(be.Provider, {
|
|
2221
2221
|
value: j,
|
|
2222
2222
|
children: /* @__PURE__ */ o.jsx("div", {
|
|
2223
|
-
style:
|
|
2224
|
-
className:
|
|
2225
|
-
children:
|
|
2223
|
+
style: p,
|
|
2224
|
+
className: w(h, v && e, r && `${e}-inline`, s && `${e}-reverse`, b === "switch" && t),
|
|
2225
|
+
children: f || /* @__PURE__ */ o.jsxs(o.Fragment, {
|
|
2226
2226
|
children: [$, v && /* @__PURE__ */ o.jsx(Be, {
|
|
2227
2227
|
title: g,
|
|
2228
|
-
children:
|
|
2228
|
+
children: x
|
|
2229
2229
|
}), u && /* @__PURE__ */ o.jsx(es, {
|
|
2230
2230
|
type: d,
|
|
2231
2231
|
tooltip: c,
|
|
@@ -2246,7 +2246,7 @@ const Ve = Object.assign(zn, {
|
|
|
2246
2246
|
...r
|
|
2247
2247
|
}, s) => (e = V(e, "form-floating"), /* @__PURE__ */ o.jsx(t, {
|
|
2248
2248
|
ref: s,
|
|
2249
|
-
className:
|
|
2249
|
+
className: w(n, e),
|
|
2250
2250
|
...r
|
|
2251
2251
|
})));
|
|
2252
2252
|
Un.displayName = "FormFloating";
|
|
@@ -2266,7 +2266,7 @@ const Kn = /* @__PURE__ */ W.forwardRef(({
|
|
|
2266
2266
|
e = V(e, "form-label");
|
|
2267
2267
|
let u = "col-form-label";
|
|
2268
2268
|
typeof t == "string" && (u = `${u} ${u}-${t}`);
|
|
2269
|
-
const d =
|
|
2269
|
+
const d = w(s, e, r && "visually-hidden", t && u);
|
|
2270
2270
|
return process.env.NODE_ENV !== "production" && Jt(c == null || !a, "`controlId` is ignored on `<FormLabel>` when `htmlFor` is specified."), a = a || c, t ? /* @__PURE__ */ o.jsx(In, {
|
|
2271
2271
|
ref: l,
|
|
2272
2272
|
as: "label",
|
|
@@ -2297,7 +2297,7 @@ const Qn = /* @__PURE__ */ W.forwardRef(({
|
|
|
2297
2297
|
...r,
|
|
2298
2298
|
type: "range",
|
|
2299
2299
|
ref: s,
|
|
2300
|
-
className:
|
|
2300
|
+
className: w(e, n),
|
|
2301
2301
|
id: t || a
|
|
2302
2302
|
});
|
|
2303
2303
|
});
|
|
@@ -2319,7 +2319,7 @@ const Xn = /* @__PURE__ */ W.forwardRef(({
|
|
|
2319
2319
|
...l,
|
|
2320
2320
|
size: t,
|
|
2321
2321
|
ref: c,
|
|
2322
|
-
className:
|
|
2322
|
+
className: w(r, n, e && `${n}-${e}`, s && "is-valid", a && "is-invalid"),
|
|
2323
2323
|
id: i || u
|
|
2324
2324
|
});
|
|
2325
2325
|
});
|
|
@@ -2335,7 +2335,7 @@ const Jn = /* @__PURE__ */ W.forwardRef(
|
|
|
2335
2335
|
}, a) => (n = V(n, "form-text"), /* @__PURE__ */ o.jsx(t, {
|
|
2336
2336
|
...s,
|
|
2337
2337
|
ref: a,
|
|
2338
|
-
className:
|
|
2338
|
+
className: w(e, n, r && "text-muted")
|
|
2339
2339
|
}))
|
|
2340
2340
|
);
|
|
2341
2341
|
Jn.displayName = "FormText";
|
|
@@ -2373,7 +2373,7 @@ const Go = Object.assign(Zn, {
|
|
|
2373
2373
|
}, s) => /* @__PURE__ */ o.jsx(t, {
|
|
2374
2374
|
...r,
|
|
2375
2375
|
ref: s,
|
|
2376
|
-
className:
|
|
2376
|
+
className: w(n, e && "was-validated")
|
|
2377
2377
|
}));
|
|
2378
2378
|
vt.displayName = "Form";
|
|
2379
2379
|
vt.propTypes = zo;
|
|
@@ -2395,7 +2395,7 @@ const Q = Object.assign(vt, {
|
|
|
2395
2395
|
...r
|
|
2396
2396
|
}, s) => (e = V(e, "input-group-text"), /* @__PURE__ */ o.jsx(t, {
|
|
2397
2397
|
ref: s,
|
|
2398
|
-
className:
|
|
2398
|
+
className: w(n, e),
|
|
2399
2399
|
...r
|
|
2400
2400
|
})));
|
|
2401
2401
|
Ke.displayName = "InputGroupText";
|
|
@@ -2425,7 +2425,7 @@ const Uo = (n) => /* @__PURE__ */ o.jsx(Ke, {
|
|
|
2425
2425
|
children: /* @__PURE__ */ o.jsx(s, {
|
|
2426
2426
|
ref: i,
|
|
2427
2427
|
...a,
|
|
2428
|
-
className:
|
|
2428
|
+
className: w(r, n, e && `${n}-${e}`, t && "has-validation")
|
|
2429
2429
|
})
|
|
2430
2430
|
});
|
|
2431
2431
|
});
|
|
@@ -2449,7 +2449,7 @@ const tt = Object.assign(er, {
|
|
|
2449
2449
|
return /* @__PURE__ */ o.jsx(s, {
|
|
2450
2450
|
ref: l,
|
|
2451
2451
|
...i,
|
|
2452
|
-
className:
|
|
2452
|
+
className: w(a, c, r && `${c}-${r}`, e && `text-${e}`)
|
|
2453
2453
|
});
|
|
2454
2454
|
});
|
|
2455
2455
|
yt.displayName = "Spinner";
|
|
@@ -2732,9 +2732,9 @@ function qa(n, e, t) {
|
|
|
2732
2732
|
O(() => () => {
|
|
2733
2733
|
h.current = !1;
|
|
2734
2734
|
}, []);
|
|
2735
|
-
const
|
|
2735
|
+
const p = q(s !== $e.None);
|
|
2736
2736
|
O(() => {
|
|
2737
|
-
|
|
2737
|
+
p.current = s !== $e.None;
|
|
2738
2738
|
}, [s]);
|
|
2739
2739
|
const g = q(!0);
|
|
2740
2740
|
O(() => {
|
|
@@ -2747,8 +2747,8 @@ function qa(n, e, t) {
|
|
|
2747
2747
|
return;
|
|
2748
2748
|
}
|
|
2749
2749
|
}, [u, c]);
|
|
2750
|
-
const b = S(async (
|
|
2751
|
-
const k =
|
|
2750
|
+
const b = S(async (f, _) => {
|
|
2751
|
+
const k = f || n, m = _ || e;
|
|
2752
2752
|
switch (k) {
|
|
2753
2753
|
case Le.Popup:
|
|
2754
2754
|
return a.verbose("useMsalAuthentication - Calling loginPopup"), r.loginPopup(m);
|
|
@@ -2759,8 +2759,8 @@ function qa(n, e, t) {
|
|
|
2759
2759
|
default:
|
|
2760
2760
|
throw je.createInvalidInteractionTypeError();
|
|
2761
2761
|
}
|
|
2762
|
-
}, [r, n, e, a]),
|
|
2763
|
-
const k =
|
|
2762
|
+
}, [r, n, e, a]), x = S(async (f, _) => {
|
|
2763
|
+
const k = f || n;
|
|
2764
2764
|
let m;
|
|
2765
2765
|
return _ ? (a.trace("useMsalAuthentication - acquireToken - Using request provided in the callback"), m = {
|
|
2766
2766
|
..._
|
|
@@ -2771,7 +2771,7 @@ function qa(n, e, t) {
|
|
|
2771
2771
|
scopes: It
|
|
2772
2772
|
}), !m.account && l && (a.trace("useMsalAuthentication - acquireToken - Attaching account to request"), m.account = l), (async () => (a.verbose("useMsalAuthentication - Calling acquireTokenSilent"), r.acquireTokenSilent(m).catch(async (j) => {
|
|
2773
2773
|
if (j instanceof _t) {
|
|
2774
|
-
if (
|
|
2774
|
+
if (p.current)
|
|
2775
2775
|
throw a.error("useMsalAuthentication - Interaction required but is already in progress. Please try again, if needed, after interaction completes."), je.createUnableToFallbackToInteractionError();
|
|
2776
2776
|
return a.error("useMsalAuthentication - Interaction required, falling back to interaction"), b(k, m);
|
|
2777
2777
|
}
|
|
@@ -2788,7 +2788,7 @@ function qa(n, e, t) {
|
|
|
2788
2788
|
b
|
|
2789
2789
|
]);
|
|
2790
2790
|
return O(() => {
|
|
2791
|
-
const
|
|
2791
|
+
const f = r.addEventCallback((_) => {
|
|
2792
2792
|
switch (_.eventType) {
|
|
2793
2793
|
case Fe.LOGIN_SUCCESS:
|
|
2794
2794
|
case Fe.SSO_SILENT_SUCCESS:
|
|
@@ -2803,16 +2803,16 @@ function qa(n, e, t) {
|
|
|
2803
2803
|
break;
|
|
2804
2804
|
}
|
|
2805
2805
|
});
|
|
2806
|
-
return a.verbose(`useMsalAuthentication - Registered event callback with id: ${
|
|
2807
|
-
|
|
2806
|
+
return a.verbose(`useMsalAuthentication - Registered event callback with id: ${f}`), () => {
|
|
2807
|
+
f && (a.verbose(`useMsalAuthentication - Removing event callback ${f}`), r.removeEventCallback(f));
|
|
2808
2808
|
};
|
|
2809
2809
|
}, [r, a]), O(() => {
|
|
2810
|
-
g.current && s === $e.None && (g.current = !1, i ? l && (a.info("useMsalAuthentication - User is authenticated, attempting to acquire token"),
|
|
2810
|
+
g.current && s === $e.None && (g.current = !1, i ? l && (a.info("useMsalAuthentication - User is authenticated, attempting to acquire token"), x().catch(() => {
|
|
2811
2811
|
})) : (a.info("useMsalAuthentication - No user is authenticated, attempting to login"), b().catch(() => {
|
|
2812
2812
|
})));
|
|
2813
|
-
}, [i, l, s, b,
|
|
2813
|
+
}, [i, l, s, b, x, a]), {
|
|
2814
2814
|
login: b,
|
|
2815
|
-
acquireToken:
|
|
2815
|
+
acquireToken: x,
|
|
2816
2816
|
result: c,
|
|
2817
2817
|
error: u
|
|
2818
2818
|
};
|
|
@@ -2854,10 +2854,10 @@ const Ba = ({ children: n, onStorno: e }) => {
|
|
|
2854
2854
|
...s
|
|
2855
2855
|
}) => {
|
|
2856
2856
|
const { LinkComponent: a } = Y(ae);
|
|
2857
|
-
return s.as === "link" ? /* @__PURE__ */ o.jsxs(a, { to: s.href ?? "/", className:
|
|
2857
|
+
return s.as === "link" ? /* @__PURE__ */ o.jsxs(a, { to: s.href ?? "/", className: w(`luminus-context-button btn text-${n} ${t ?? ""}`, ct.button), ...s, children: [
|
|
2858
2858
|
e,
|
|
2859
2859
|
r
|
|
2860
|
-
] }) : s.as === "button" || s.as === void 0 ? /* @__PURE__ */ o.jsxs("button", { type: "button", className:
|
|
2860
|
+
] }) : s.as === "button" || s.as === void 0 ? /* @__PURE__ */ o.jsxs("button", { type: "button", className: w(`luminus-context-button btn text-${n} ${t ?? ""}`, ct.button), ...s, children: [
|
|
2861
2861
|
e,
|
|
2862
2862
|
r
|
|
2863
2863
|
] }) : null;
|
|
@@ -2866,7 +2866,7 @@ const Ba = ({ children: n, onStorno: e }) => {
|
|
|
2866
2866
|
d.target.files && (s(d.target.files), d.target.value = "");
|
|
2867
2867
|
};
|
|
2868
2868
|
return /* @__PURE__ */ o.jsxs(o.Fragment, { children: [
|
|
2869
|
-
/* @__PURE__ */ o.jsxs("label", { htmlFor: t, className:
|
|
2869
|
+
/* @__PURE__ */ o.jsxs("label", { htmlFor: t, className: w(`luminus-context-button btn text-${n} ${a ?? ""}`, ct.button), ...c, children: [
|
|
2870
2870
|
e,
|
|
2871
2871
|
i
|
|
2872
2872
|
] }),
|
|
@@ -2880,11 +2880,11 @@ const Ba = ({ children: n, onStorno: e }) => {
|
|
|
2880
2880
|
lg: Ka
|
|
2881
2881
|
}, z = ({ type: n = "button", color: e = "primary", size: t = "md", children: r, className: s, ...a }) => {
|
|
2882
2882
|
const { LinkComponent: i } = Y(ae);
|
|
2883
|
-
return a.as === "link" ? /* @__PURE__ */ o.jsx(i, { to: a.href ?? "/", className:
|
|
2883
|
+
return a.as === "link" ? /* @__PURE__ */ o.jsx(i, { to: a.href ?? "/", className: w(`luminus-icon-button btn text-${e} ${s ?? ""}`, Ye.iconButton, Ye[t]), ...a, children: r }) : a.as === "button" || a.as === void 0 ? /* @__PURE__ */ o.jsx(
|
|
2884
2884
|
"button",
|
|
2885
2885
|
{
|
|
2886
2886
|
type: n,
|
|
2887
|
-
className:
|
|
2887
|
+
className: w(`luminus-icon-button btn text-${e} ${s ?? ""}`, Ye.iconButton, Ye[t]),
|
|
2888
2888
|
...a,
|
|
2889
2889
|
children: r
|
|
2890
2890
|
}
|
|
@@ -2914,11 +2914,11 @@ const Ba = ({ children: n, onStorno: e }) => {
|
|
|
2914
2914
|
/* @__PURE__ */ o.jsx(Q.Select, { value: n.getMonth(), onChange: (c) => {
|
|
2915
2915
|
var u;
|
|
2916
2916
|
return ((u = c.target) == null ? void 0 : u.value) && e(mo(n, Number(c.target.value)));
|
|
2917
|
-
}, className:
|
|
2917
|
+
}, className: w(rt.select, rt.month), children: l.map((c) => /* @__PURE__ */ o.jsx("option", { value: c.id, children: c.name }, c.id)) }),
|
|
2918
2918
|
/* @__PURE__ */ o.jsx(Q.Select, { value: n.getFullYear(), onChange: (c) => {
|
|
2919
2919
|
var u;
|
|
2920
2920
|
return ((u = c.target) == null ? void 0 : u.value) && e(vn(n, Number(c.target.value)));
|
|
2921
|
-
}, className:
|
|
2921
|
+
}, className: w(rt.select), children: i.map((c) => /* @__PURE__ */ o.jsx("option", { value: c, children: c }, c)) }),
|
|
2922
2922
|
/* @__PURE__ */ o.jsx(z, { onClick: () => a(1), disabled: n.getFullYear() > s || n.getFullYear() === s && n.getMonth() >= 11, children: /* @__PURE__ */ o.jsx(ft, {}) })
|
|
2923
2923
|
] });
|
|
2924
2924
|
}, Xa = "_select_pywmr_1", Ja = {
|
|
@@ -2933,7 +2933,7 @@ const Ba = ({ children: n, onStorno: e }) => {
|
|
|
2933
2933
|
l.push(c);
|
|
2934
2934
|
return l;
|
|
2935
2935
|
}, [t, r]);
|
|
2936
|
-
return /* @__PURE__ */ o.jsxs("div", { className:
|
|
2936
|
+
return /* @__PURE__ */ o.jsxs("div", { className: w("card d-flex flex-row align-items-center m-0 p-1 gap-2", s ?? ""), children: [
|
|
2937
2937
|
/* @__PURE__ */ o.jsx(z, { onClick: () => a(-1), disabled: n.getFullYear() <= t, children: /* @__PURE__ */ o.jsx(mt, {}) }),
|
|
2938
2938
|
/* @__PURE__ */ o.jsx(Q.Select, { value: n.getFullYear(), onChange: (l) => {
|
|
2939
2939
|
var c;
|
|
@@ -2949,7 +2949,7 @@ const Ba = ({ children: n, onStorno: e }) => {
|
|
|
2949
2949
|
] }), Ht = ({ availableWidgets: n, onAdd: e, texts: t }) => {
|
|
2950
2950
|
const [r, s] = P(!1);
|
|
2951
2951
|
return /* @__PURE__ */ o.jsxs(o.Fragment, { children: [
|
|
2952
|
-
/* @__PURE__ */ o.jsx("div", { className:
|
|
2952
|
+
/* @__PURE__ */ o.jsx("div", { className: w("luminus-empty-widget", ei.widget), children: /* @__PURE__ */ o.jsx(z, { onClick: () => s(!0), children: /* @__PURE__ */ o.jsx(Ar, {}) }) }),
|
|
2953
2953
|
/* @__PURE__ */ o.jsx(ti, { show: r, widgets: n, handleClose: () => s(!1), onWidgetPicked: (a) => {
|
|
2954
2954
|
s(!1), e(a);
|
|
2955
2955
|
}, texts: t })
|
|
@@ -2989,9 +2989,6 @@ class di extends zr {
|
|
|
2989
2989
|
static getDerivedStateFromError(e) {
|
|
2990
2990
|
return { hasError: !0 };
|
|
2991
2991
|
}
|
|
2992
|
-
componentDidUpdate(e) {
|
|
2993
|
-
e.children !== this.props.children && this.setState({ hasError: !1 });
|
|
2994
|
-
}
|
|
2995
2992
|
componentDidCatch(e, t) {
|
|
2996
2993
|
console.error("Error:", e, t);
|
|
2997
2994
|
}
|
|
@@ -3017,42 +3014,42 @@ const hi = (n) => (t) => {
|
|
|
3017
3014
|
}, mi = hi(di), fi = "_widget-card_e9tsb_1", pi = {
|
|
3018
3015
|
"widget-card": "_widget-card_e9tsb_1",
|
|
3019
3016
|
widgetCard: fi
|
|
3020
|
-
}, Bt = ({ children: n, title: e, headerContent: t }) => /* @__PURE__ */ o.jsx(vc, { className:
|
|
3017
|
+
}, Bt = ({ children: n, title: e, headerContent: t }) => /* @__PURE__ */ o.jsx(vc, { className: w(pi.widgetCard, "luminus-widget"), title: e, headerContent: t, contentClassName: "h-100 overflow-auto", children: n }), gi = ({ children: n, title: e }) => {
|
|
3021
3018
|
const { widgetTexts: t } = Y(ae);
|
|
3022
3019
|
return /* @__PURE__ */ o.jsx(mi, { fallback: /* @__PURE__ */ o.jsx(Bt, { title: e, children: t.fallbackError }), reloadButtonDisplay: "inject-to-child", children: /* @__PURE__ */ o.jsx(Kr, { fallback: /* @__PURE__ */ o.jsx(Bt, { title: e, children: /* @__PURE__ */ o.jsx(ss, {}) }), children: n }) });
|
|
3023
3020
|
}, sl = ({ availableWidgets: n, editMode: e, defaultDashboardConfig: t }) => {
|
|
3024
3021
|
var d;
|
|
3025
|
-
const { homeDashboardTexts: r } = Y(ae), { dashboardConfig: s, onChangeDashboardConfig: a } = ni(t), i = S((h,
|
|
3022
|
+
const { homeDashboardTexts: r } = Y(ae), { dashboardConfig: s, onChangeDashboardConfig: a } = ni(t), i = S((h, p) => {
|
|
3026
3023
|
var g, b;
|
|
3027
3024
|
h === ((g = s.widgets) == null ? void 0 : g.length) ? a({
|
|
3028
3025
|
...s,
|
|
3029
|
-
widgets: [...s.widgets, { widgetId:
|
|
3026
|
+
widgets: [...s.widgets, { widgetId: p, fullWidth: !1 }]
|
|
3030
3027
|
}) : a({
|
|
3031
3028
|
...s,
|
|
3032
|
-
widgets: ((b = s.widgets) == null ? void 0 : b.map((
|
|
3029
|
+
widgets: ((b = s.widgets) == null ? void 0 : b.map((x, f) => f === h ? { widgetId: p, fullWidth: !1 } : x)) ?? []
|
|
3033
3030
|
});
|
|
3034
3031
|
}, [s, a]), l = S((h) => {
|
|
3035
|
-
var
|
|
3036
|
-
((
|
|
3032
|
+
var p, g;
|
|
3033
|
+
((p = s.widgets[h]) == null ? void 0 : p.widgetId) === -1 ? a({
|
|
3037
3034
|
...s,
|
|
3038
|
-
widgets: ((g = s.widgets) == null ? void 0 : g.filter((b,
|
|
3035
|
+
widgets: ((g = s.widgets) == null ? void 0 : g.filter((b, x) => x !== h)) ?? []
|
|
3039
3036
|
}) : i(h, -1);
|
|
3040
3037
|
}, [s, a, i]), c = S((h) => {
|
|
3041
|
-
var
|
|
3038
|
+
var p;
|
|
3042
3039
|
a({
|
|
3043
3040
|
...s,
|
|
3044
|
-
widgets: ((
|
|
3041
|
+
widgets: ((p = s.widgets) == null ? void 0 : p.map((g, b) => b === h ? { ...g, fullWidth: !g.fullWidth } : g)) ?? []
|
|
3045
3042
|
});
|
|
3046
|
-
}, [s, a]), u = S((h,
|
|
3043
|
+
}, [s, a]), u = S((h, p, g) => h ? /* @__PURE__ */ o.jsxs("div", { className: w(ie.widgetWrapper, {
|
|
3047
3044
|
[ie.widgetEdit]: e && h.id !== -1
|
|
3048
3045
|
}, { [ie.fullWidth]: g }), children: [
|
|
3049
3046
|
e && /* @__PURE__ */ o.jsxs(o.Fragment, { children: [
|
|
3050
|
-
/* @__PURE__ */ o.jsx(z, { color: "danger", onClick: () => l(
|
|
3051
|
-
/* @__PURE__ */ o.jsx(z, { color: g ? "danger" : "primary", onClick: () => c(
|
|
3047
|
+
/* @__PURE__ */ o.jsx(z, { color: "danger", onClick: () => l(p), className: w(ie.removeIcon), children: /* @__PURE__ */ o.jsx(tn, {}) }),
|
|
3048
|
+
/* @__PURE__ */ o.jsx(z, { color: g ? "danger" : "primary", onClick: () => c(p), className: w(ie.fullWidthIcon), children: /* @__PURE__ */ o.jsx(Fr, {}) })
|
|
3052
3049
|
] }),
|
|
3053
|
-
h.id === -1 ? e && /* @__PURE__ */ o.jsx("div", { className: ie.widgetWrapper, children: /* @__PURE__ */ o.jsx(Ht, { availableWidgets: n, onAdd: (b) => i(
|
|
3050
|
+
h.id === -1 ? e && /* @__PURE__ */ o.jsx("div", { className: ie.widgetWrapper, children: /* @__PURE__ */ o.jsx(Ht, { availableWidgets: n, onAdd: (b) => i(p, b), texts: r }) }) : /* @__PURE__ */ o.jsx(gi, { title: h.title, children: /* @__PURE__ */ o.jsx(h.WidgetElement, { title: h.title }) }),
|
|
3054
3051
|
h.id > -1 && e && /* @__PURE__ */ o.jsx("div", { className: ie.widgetEditOverlay })
|
|
3055
|
-
] },
|
|
3052
|
+
] }, p) : /* @__PURE__ */ o.jsx(o.Fragment, {}), [
|
|
3056
3053
|
e,
|
|
3057
3054
|
i,
|
|
3058
3055
|
l,
|
|
@@ -3061,10 +3058,10 @@ const hi = (n) => (t) => {
|
|
|
3061
3058
|
r
|
|
3062
3059
|
]);
|
|
3063
3060
|
return /* @__PURE__ */ o.jsx("div", { className: ie.dashboard, children: /* @__PURE__ */ o.jsxs("div", { className: ie.widgetsGrid, children: [
|
|
3064
|
-
(d = s.widgets) == null ? void 0 : d.map((h,
|
|
3061
|
+
(d = s.widgets) == null ? void 0 : d.map((h, p) => u(n.find((g) => g.id === h.widgetId), p, h.fullWidth)),
|
|
3065
3062
|
e && /* @__PURE__ */ o.jsx(Ht, { availableWidgets: n, onAdd: (h) => {
|
|
3066
|
-
var
|
|
3067
|
-
return i((
|
|
3063
|
+
var p;
|
|
3064
|
+
return i((p = s.widgets) == null ? void 0 : p.length, h);
|
|
3068
3065
|
}, texts: r })
|
|
3069
3066
|
] }) });
|
|
3070
3067
|
}, xi = "_badge_nhser_1", wi = "_sm_nhser_1", vi = "_md_nhser_4", yi = "_lg_nhser_7", Vt = {
|
|
@@ -3072,7 +3069,7 @@ const hi = (n) => (t) => {
|
|
|
3072
3069
|
sm: wi,
|
|
3073
3070
|
md: vi,
|
|
3074
3071
|
lg: yi
|
|
3075
|
-
}, ol = ({ children: n, color: e = "primary", size: t = "md", className: r }) => /* @__PURE__ */ o.jsx("span", { className:
|
|
3072
|
+
}, ol = ({ children: n, color: e = "primary", size: t = "md", className: r }) => /* @__PURE__ */ o.jsx("span", { className: w(`luminus-badge badge bg-${e} ${r ?? ""}`, Vt.badge, Vt[t]), children: n }), bi = "_collapse-icon_1ahhn_1", _i = "_collapsed_1ahhn_6", Gt = {
|
|
3076
3073
|
"collapse-icon": "_collapse-icon_1ahhn_1",
|
|
3077
3074
|
collapseIcon: bi,
|
|
3078
3075
|
collapsed: _i
|
|
@@ -3083,7 +3080,7 @@ const hi = (n) => (t) => {
|
|
|
3083
3080
|
}, [s]), /* @__PURE__ */ o.jsxs("div", { className: t ?? "", children: [
|
|
3084
3081
|
/* @__PURE__ */ o.jsxs("div", { role: "button", className: "d-flex align-items-center justify-content-between pb-3 pt-2", onClick: () => r.controlled ? r.onToggle(!r.isOpen) : i(!a), children: [
|
|
3085
3082
|
/* @__PURE__ */ o.jsx(G, { variant: "h6", children: n }),
|
|
3086
|
-
/* @__PURE__ */ o.jsx(nn, { className:
|
|
3083
|
+
/* @__PURE__ */ o.jsx(nn, { className: w(Gt.collapseIcon, {
|
|
3087
3084
|
[Gt.collapsed]: l
|
|
3088
3085
|
}) })
|
|
3089
3086
|
] }),
|
|
@@ -3095,17 +3092,17 @@ const hi = (n) => (t) => {
|
|
|
3095
3092
|
"feedback-spacer": "_feedback-spacer_esh1j_8",
|
|
3096
3093
|
feedbackSpacer: ki
|
|
3097
3094
|
}, pe = ({ message: n }) => /* @__PURE__ */ o.jsxs(o.Fragment, { children: [
|
|
3098
|
-
/* @__PURE__ */ o.jsx("div", { className:
|
|
3099
|
-
/* @__PURE__ */ o.jsx("div", { className:
|
|
3095
|
+
/* @__PURE__ */ o.jsx("div", { className: w("invalid-feedback luminus-invalid-feedback", zt.feedback), children: n }),
|
|
3096
|
+
/* @__PURE__ */ o.jsx("div", { className: w("invalid-feedback-spacer", zt.feedbackSpacer), children: n })
|
|
3100
3097
|
] });
|
|
3101
3098
|
function Ni(n, e, t) {
|
|
3102
3099
|
var r = this, s = q(null), a = q(0), i = q(null), l = q([]), c = q(), u = q(), d = q(n), h = q(!0);
|
|
3103
3100
|
d.current = n;
|
|
3104
|
-
var
|
|
3101
|
+
var p = typeof window < "u", g = !e && e !== 0 && p;
|
|
3105
3102
|
if (typeof n != "function")
|
|
3106
3103
|
throw new TypeError("Expected a function");
|
|
3107
3104
|
e = +e || 0;
|
|
3108
|
-
var b = !!(t = t || {}).leading,
|
|
3105
|
+
var b = !!(t = t || {}).leading, x = !("trailing" in t) || !!t.trailing, f = "maxWait" in t, _ = "debounceOnServer" in t && !!t.debounceOnServer, k = f ? Math.max(+t.maxWait || 0, e) : null;
|
|
3109
3106
|
O(function() {
|
|
3110
3107
|
return h.current = !0, function() {
|
|
3111
3108
|
h.current = !1;
|
|
@@ -3121,24 +3118,24 @@ function Ni(n, e, t) {
|
|
|
3121
3118
|
if (!h.current)
|
|
3122
3119
|
return !1;
|
|
3123
3120
|
var y = T - s.current;
|
|
3124
|
-
return !s.current || y >= e || y < 0 ||
|
|
3121
|
+
return !s.current || y >= e || y < 0 || f && T - a.current >= k;
|
|
3125
3122
|
}, $ = function(T) {
|
|
3126
|
-
return i.current = null,
|
|
3123
|
+
return i.current = null, x && l.current ? N(T) : (l.current = c.current = null, u.current);
|
|
3127
3124
|
}, D = function T() {
|
|
3128
3125
|
var y = Date.now();
|
|
3129
3126
|
if (v(y))
|
|
3130
3127
|
return $(y);
|
|
3131
3128
|
if (h.current) {
|
|
3132
|
-
var C = e - (y - s.current), F =
|
|
3129
|
+
var C = e - (y - s.current), F = f ? Math.min(C, k - (y - a.current)) : C;
|
|
3133
3130
|
j(T, F);
|
|
3134
3131
|
}
|
|
3135
3132
|
}, I = function() {
|
|
3136
|
-
if (
|
|
3133
|
+
if (p || _) {
|
|
3137
3134
|
var T = Date.now(), y = v(T);
|
|
3138
3135
|
if (l.current = [].slice.call(arguments), c.current = r, s.current = T, y) {
|
|
3139
3136
|
if (!i.current && h.current)
|
|
3140
3137
|
return a.current = s.current, j(D, e), b ? N(s.current) : u.current;
|
|
3141
|
-
if (
|
|
3138
|
+
if (f)
|
|
3142
3139
|
return j(D, e), N(s.current);
|
|
3143
3140
|
}
|
|
3144
3141
|
return i.current || j(D, e), u.current;
|
|
@@ -3151,7 +3148,7 @@ function Ni(n, e, t) {
|
|
|
3151
3148
|
}, I.flush = function() {
|
|
3152
3149
|
return i.current ? $(Date.now()) : u.current;
|
|
3153
3150
|
}, I;
|
|
3154
|
-
}, [b,
|
|
3151
|
+
}, [b, f, e, k, x, g, p, _]);
|
|
3155
3152
|
return m;
|
|
3156
3153
|
}
|
|
3157
3154
|
function Ci(n, e) {
|
|
@@ -3187,9 +3184,9 @@ const $i = "_wrapper_uccrb_1", Si = "_open_uccrb_9", Ti = "_dropdown_uccrb_13",
|
|
|
3187
3184
|
icon: Ri,
|
|
3188
3185
|
"clear-button": "_clear-button_uccrb_74",
|
|
3189
3186
|
clearButton: Yi
|
|
3190
|
-
}, jt = ({ show: n, onCancel: e, items: t, currentSelection: r, onSelectionChange: s, onSearchQueryChange: a, texts: i, itemsNameWidth: l, additionalColumns: c, displayIdAsName: u = !1, autoHideSearch: d = !1, allItemsLength: h, disabled:
|
|
3187
|
+
}, jt = ({ show: n, onCancel: e, items: t, currentSelection: r, onSelectionChange: s, onSearchQueryChange: a, texts: i, itemsNameWidth: l, additionalColumns: c, displayIdAsName: u = !1, autoHideSearch: d = !1, allItemsLength: h, disabled: p, isLoading: g = !1, inputRef: b }) => {
|
|
3191
3188
|
var E;
|
|
3192
|
-
const
|
|
3189
|
+
const x = q(null), f = q(null), _ = q(null), [k, m] = P(""), [N] = or(k, 500), [, j] = P(!1), v = (E = b.current) == null ? void 0 : E.getBoundingClientRect(), $ = (v == null ? void 0 : v.x) ?? 0, D = ((v == null ? void 0 : v.x) ?? 0) + ((v == null ? void 0 : v.width) ?? 0), I = (v == null ? void 0 : v.y) ?? 0, T = ((v == null ? void 0 : v.y) ?? 0) + ((v == null ? void 0 : v.height) ?? 0), y = (v == null ? void 0 : v.width) ?? 0, C = (v == null ? void 0 : v.height) ?? 0, F = 5, R = K(() => $ ? $ > window.innerWidth / 2 : !1, [$]), H = K(() => I ? I > window.innerHeight / 2 : !1, [I]);
|
|
3193
3190
|
O(() => {
|
|
3194
3191
|
var M;
|
|
3195
3192
|
n && ((M = _.current) == null || M.focus());
|
|
@@ -3211,15 +3208,15 @@ const $i = "_wrapper_uccrb_1", Si = "_open_uccrb_9", Ti = "_dropdown_uccrb_13",
|
|
|
3211
3208
|
window.removeEventListener("scroll", A);
|
|
3212
3209
|
}), [A]), O(() => (window.addEventListener("resize", A), () => {
|
|
3213
3210
|
window.removeEventListener("resize", A);
|
|
3214
|
-
}), [A]), hn(Z), mn([
|
|
3211
|
+
}), [A]), hn(Z), mn([x, f], e);
|
|
3215
3212
|
const re = l ?? (c && c.length > 0 ? 250 : 0), ee = (c == null ? void 0 : c.reduce((M, X) => M + (X.width ?? 100), 0)) ?? 0, U = `calc(max(${y}px, ${re}px + ${ee}px))`;
|
|
3216
3213
|
return /* @__PURE__ */ o.jsxs(o.Fragment, { children: [
|
|
3217
3214
|
/* @__PURE__ */ o.jsx(lr, { show: n, onClick: e }),
|
|
3218
|
-
r && n && !
|
|
3215
|
+
r && n && !p && /* @__PURE__ */ o.jsx("button", { ref: f, type: "button", className: w("luminus-dropdown-picker-clear-button", te.clearButton), onClick: () => !p && s(null), style: {
|
|
3219
3216
|
top: `calc(${I}px + ${C / 2}px - 12px)`,
|
|
3220
3217
|
left: `calc(${$}px - 24px - 8px)`
|
|
3221
3218
|
}, children: /* @__PURE__ */ o.jsx(G, { variant: "caption", className: "text-danger", children: /* @__PURE__ */ o.jsx(tn, { size: 16 }) }) }),
|
|
3222
|
-
/* @__PURE__ */ o.jsx("div", { className:
|
|
3219
|
+
/* @__PURE__ */ o.jsx("div", { className: w("luminus-dropdown-picker", te.wrapper, {
|
|
3223
3220
|
[te.open]: n
|
|
3224
3221
|
}), style: {
|
|
3225
3222
|
top: H ? `calc(${I}px - 50vh - 8px)` : `calc(${T}px + 8px)`,
|
|
@@ -3227,13 +3224,13 @@ const $i = "_wrapper_uccrb_1", Si = "_open_uccrb_9", Ti = "_dropdown_uccrb_13",
|
|
|
3227
3224
|
right: R ? `${D}px` : `calc(${$}px + ${U})`,
|
|
3228
3225
|
width: U,
|
|
3229
3226
|
justifyContent: H ? "flex-end" : "flex-start"
|
|
3230
|
-
}, children: /* @__PURE__ */ o.jsx("div", { ref:
|
|
3231
|
-
d && (h ?? t.length) <= F ? null : /* @__PURE__ */ o.jsx("div", { className:
|
|
3227
|
+
}, children: /* @__PURE__ */ o.jsx("div", { ref: x, className: w("shadow rounded", te.dropdown), children: !p && /* @__PURE__ */ o.jsxs(o.Fragment, { children: [
|
|
3228
|
+
d && (h ?? t.length) <= F ? null : /* @__PURE__ */ o.jsx("div", { className: w("search-input-container border-bottom", te.searchInputContainer), children: /* @__PURE__ */ o.jsx(Q.Control, { ref: _, type: "search", size: "sm", className: te.searchInput, placeholder: i.searchPlaceholder, value: k, onChange: (M) => {
|
|
3232
3229
|
var X;
|
|
3233
3230
|
return m(((X = M.target) == null ? void 0 : X.value) ?? "");
|
|
3234
3231
|
} }) }),
|
|
3235
|
-
g ? /* @__PURE__ */ o.jsx("div", { className: te.loadingContainer, children: /* @__PURE__ */ o.jsx(yt, { animation: "border", variant: "primary" }) }) : t.length > 0 && /* @__PURE__ */ o.jsxs("div", { className:
|
|
3236
|
-
c && c.length > 0 && /* @__PURE__ */ o.jsxs("div", { className:
|
|
3232
|
+
g ? /* @__PURE__ */ o.jsx("div", { className: te.loadingContainer, children: /* @__PURE__ */ o.jsx(yt, { animation: "border", variant: "primary" }) }) : t.length > 0 && /* @__PURE__ */ o.jsxs("div", { className: w("items", te.itemsContainer), children: [
|
|
3233
|
+
c && c.length > 0 && /* @__PURE__ */ o.jsxs("div", { className: w("header-row border-bottom", te.headerRow), children: [
|
|
3237
3234
|
/* @__PURE__ */ o.jsx("div", { className: te.name }),
|
|
3238
3235
|
c == null ? void 0 : c.map((M) => /* @__PURE__ */ o.jsx("div", { className: te.columnItem, style: {
|
|
3239
3236
|
width: `${M.width ?? 100}px`,
|
|
@@ -3241,13 +3238,13 @@ const $i = "_wrapper_uccrb_1", Si = "_open_uccrb_9", Ti = "_dropdown_uccrb_13",
|
|
|
3241
3238
|
maxWidth: `${M.width ?? 100}px`
|
|
3242
3239
|
}, children: /* @__PURE__ */ o.jsx(G, { variant: "caption", children: M.name }) }, M.key))
|
|
3243
3240
|
] }),
|
|
3244
|
-
t == null ? void 0 : t.map((M) => /* @__PURE__ */ o.jsxs("button", { type: "button", className:
|
|
3241
|
+
t == null ? void 0 : t.map((M) => /* @__PURE__ */ o.jsxs("button", { type: "button", className: w("item cursor-pointer", te.item), onClick: () => !p && s(M), children: [
|
|
3245
3242
|
/* @__PURE__ */ o.jsx("div", { className: te.name, children: /* @__PURE__ */ o.jsx(G, { variant: "body2", children: u ? M.id : M.name }) }),
|
|
3246
3243
|
c == null ? void 0 : c.map((X) => /* @__PURE__ */ o.jsx("div", { className: te.columnItem, style: {
|
|
3247
3244
|
width: `${X.width ?? 100}px`,
|
|
3248
3245
|
minWidth: `${X.width ?? 100}px`,
|
|
3249
3246
|
maxWidth: `${X.width ?? 100}px`
|
|
3250
|
-
}, children: /* @__PURE__ */ o.jsx(G, { variant: "caption", className:
|
|
3247
|
+
}, children: /* @__PURE__ */ o.jsx(G, { variant: "caption", className: w("text-muted"), children: M.additionalColumns && M.additionalColumns[X.key] }) }, X.key))
|
|
3251
3248
|
] }, M.id))
|
|
3252
3249
|
] })
|
|
3253
3250
|
] }) }) })
|
|
@@ -3271,7 +3268,7 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3271
3268
|
className: t,
|
|
3272
3269
|
children: r,
|
|
3273
3270
|
...s
|
|
3274
|
-
}) => /* @__PURE__ */ o.jsxs(Ee.Item, { className:
|
|
3271
|
+
}) => /* @__PURE__ */ o.jsxs(Ee.Item, { className: w(`btn luminus-dropdown-item text-nowrap rounded text-${n} ${t ?? ""}`, cr.item), ...s, children: [
|
|
3275
3272
|
e,
|
|
3276
3273
|
r
|
|
3277
3274
|
] }), Bi = (n) => /* @__PURE__ */ o.jsx(Ee.Toggle, { ...n }), il = ({ color: n = "primary", icon: e = /* @__PURE__ */ o.jsx(en, { size: 12 }), inputId: t = "context-file-input", accept: r = "*", onUpload: s, multiple: a, className: i, children: l, ...c }) => {
|
|
@@ -3279,7 +3276,7 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3279
3276
|
d.target.files && (s(d.target.files), d.target.value = "");
|
|
3280
3277
|
};
|
|
3281
3278
|
return /* @__PURE__ */ o.jsxs(o.Fragment, { children: [
|
|
3282
|
-
/* @__PURE__ */ o.jsxs("label", { htmlFor: t, className:
|
|
3279
|
+
/* @__PURE__ */ o.jsxs("label", { htmlFor: t, className: w(`btn luminus-dropdown-item text-nowrap rounded text-${n} ${i ?? ""}`, cr.item), ...c, children: [
|
|
3283
3280
|
e,
|
|
3284
3281
|
l
|
|
3285
3282
|
] }),
|
|
@@ -3287,11 +3284,11 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3287
3284
|
] });
|
|
3288
3285
|
}, Vi = "_divider_1e6rk_1", Gi = {
|
|
3289
3286
|
divider: Vi
|
|
3290
|
-
}, cl = ({ className: n }) => /* @__PURE__ */ o.jsx(Ee.Divider, { className:
|
|
3287
|
+
}, cl = ({ className: n }) => /* @__PURE__ */ o.jsx(Ee.Divider, { className: w("luminus-dropdown-divider", n, Gi.divider) }), zi = "_dropdown_1lk66_1", Ui = {
|
|
3291
3288
|
dropdown: zi
|
|
3292
3289
|
}, Ki = ({ toggle: n, children: e, ...t }) => /* @__PURE__ */ o.jsxs(Ee, { ...t, children: [
|
|
3293
3290
|
n,
|
|
3294
|
-
/* @__PURE__ */ o.jsx(Ee.Menu, { className:
|
|
3291
|
+
/* @__PURE__ */ o.jsx(Ee.Menu, { className: w("luminus-dropdown rounded shadow", Ui.dropdown), children: e })
|
|
3295
3292
|
] }), Qi = ({ searchTypes: n, selectedType: e, setSelectedType: t }) => /* @__PURE__ */ o.jsx(Ki, { toggle: /* @__PURE__ */ o.jsx(Bi, { as: Wr, icon: null, text: e == null ? void 0 : e.text }), children: n.map((r) => /* @__PURE__ */ o.jsx(Hi, { icon: null, onClick: () => t(r), children: r.text }, r.key)) }), Xi = "_dropdown_1ddrg_1", Ji = "_open_1ddrg_12", Zi = "_loading-container_1ddrg_15", ec = "_groups-container_1ddrg_22", tc = "_group_1ddrg_22", nc = "_header_1ddrg_26", rc = "_item_1ddrg_33", ge = {
|
|
3296
3293
|
dropdown: Xi,
|
|
3297
3294
|
open: Ji,
|
|
@@ -3304,16 +3301,16 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3304
3301
|
item: rc
|
|
3305
3302
|
}, sc = ({ show: n, query: e, onCancel: t, groups: r, isLoading: s, searchTypes: a }) => {
|
|
3306
3303
|
const { LinkComponent: i, appSearchTexts: l } = Y(ae), c = q(null), u = S((d) => {
|
|
3307
|
-
var
|
|
3308
|
-
const h = (
|
|
3304
|
+
var p;
|
|
3305
|
+
const h = (p = a.find((g) => g.key === d.type)) == null ? void 0 : p.toPath;
|
|
3309
3306
|
return h ? `${h}/${d.searchKey}` : "/not-found";
|
|
3310
3307
|
}, [a]);
|
|
3311
|
-
return mn([c], t), /* @__PURE__ */ o.jsx("div", { ref: c, className:
|
|
3308
|
+
return mn([c], t), /* @__PURE__ */ o.jsx("div", { ref: c, className: w("luminus-app-search-dropdown shadow rounded", ge.dropdown, {
|
|
3312
3309
|
[ge.open]: n
|
|
3313
3310
|
}), children: s ? /* @__PURE__ */ o.jsx("div", { className: ge.loadingContainer, children: /* @__PURE__ */ o.jsx(yt, { animation: "border", variant: "primary" }) }) : /* @__PURE__ */ o.jsx("div", { className: ge.groupsContainer, children: r == null ? void 0 : r.map((d) => {
|
|
3314
3311
|
var h;
|
|
3315
|
-
return /* @__PURE__ */ o.jsxs("div", { className:
|
|
3316
|
-
/* @__PURE__ */ o.jsxs(i, { to: `/search?query=${e}&type=${d.key.category}`, className:
|
|
3312
|
+
return /* @__PURE__ */ o.jsxs("div", { className: w(ge.group), children: [
|
|
3313
|
+
/* @__PURE__ */ o.jsxs(i, { to: `/search?query=${e}&type=${d.key.category}`, className: w("group-header", ge.header), onClick: t, children: [
|
|
3317
3314
|
/* @__PURE__ */ o.jsx(G, { variant: "body", className: "text-primary", children: d.key.categoryName }),
|
|
3318
3315
|
/* @__PURE__ */ o.jsxs(G, { variant: "caption", children: [
|
|
3319
3316
|
d.items.length,
|
|
@@ -3323,14 +3320,14 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3323
3320
|
d.key.totalCount
|
|
3324
3321
|
] })
|
|
3325
3322
|
] }),
|
|
3326
|
-
(h = d.items) == null ? void 0 : h.map((
|
|
3323
|
+
(h = d.items) == null ? void 0 : h.map((p, g) => /* @__PURE__ */ o.jsxs(
|
|
3327
3324
|
i,
|
|
3328
3325
|
{
|
|
3329
|
-
to: u(
|
|
3330
|
-
className:
|
|
3326
|
+
to: u(p),
|
|
3327
|
+
className: w("search-item d-flex gap-3 align-items-center justify-content-between", ge.item),
|
|
3331
3328
|
onClick: t,
|
|
3332
3329
|
children: [
|
|
3333
|
-
/* @__PURE__ */ o.jsx(G, { variant: "body2", className: "text-nowrap text-truncate", children:
|
|
3330
|
+
/* @__PURE__ */ o.jsx(G, { variant: "body2", className: "text-nowrap text-truncate", children: p.name }),
|
|
3334
3331
|
/* @__PURE__ */ o.jsx(G, { variant: "caption", className: "text-primary", children: /* @__PURE__ */ o.jsx(Rr, {}) })
|
|
3335
3332
|
]
|
|
3336
3333
|
},
|
|
@@ -3363,20 +3360,22 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3363
3360
|
return O(() => {
|
|
3364
3361
|
c();
|
|
3365
3362
|
}, [c]), { isLoading: r, searchItems: a };
|
|
3366
|
-
}, ll = ({ searchTypes: n, navigateFunction: e }) => {
|
|
3367
|
-
const { appSearchTexts:
|
|
3363
|
+
}, ll = ({ searchTypes: n, navigateFunction: e, currentPath: t }) => {
|
|
3364
|
+
const { appSearchTexts: r } = Y(ae), [s, a] = P(n.length > 0 ? n[0] : null), [i, l] = P(""), [c, u] = or(i, 500), { isLoading: d, searchItems: h } = dc(s, c), [p, g] = P(!1);
|
|
3368
3365
|
return O(() => {
|
|
3369
|
-
(
|
|
3370
|
-
}, [
|
|
3371
|
-
|
|
3366
|
+
(h.length > 0 || d) && g(!0);
|
|
3367
|
+
}, [h, d]), O(() => {
|
|
3368
|
+
l("");
|
|
3369
|
+
}, [t]), /* @__PURE__ */ o.jsx(Q, { onSubmit: (b) => {
|
|
3370
|
+
b.preventDefault(), b.stopPropagation(), u.flush(), g(!1), i.length > 2 && e(`/search?query=${i}${s && s.key && `&type=${s == null ? void 0 : s.key}`}`);
|
|
3372
3371
|
}, children: /* @__PURE__ */ o.jsxs(tt, { className: xe.inputGroup, children: [
|
|
3373
|
-
/* @__PURE__ */ o.jsx(tt.Text, { className:
|
|
3374
|
-
/* @__PURE__ */ o.jsx(Q.Control, { placeholder:
|
|
3375
|
-
var
|
|
3376
|
-
return
|
|
3377
|
-
}, onFocus: () =>
|
|
3378
|
-
/* @__PURE__ */ o.jsx(tt.Text, { className:
|
|
3379
|
-
/* @__PURE__ */ o.jsx(sc, { query:
|
|
3372
|
+
/* @__PURE__ */ o.jsx(tt.Text, { className: w("p-1 rounded", xe.inputGroupText, xe.left), children: /* @__PURE__ */ o.jsx(Qi, { searchTypes: n, selectedType: s, setSelectedType: a }) }),
|
|
3373
|
+
/* @__PURE__ */ o.jsx(Q.Control, { placeholder: r.searchPlaceholder, type: "text", size: "sm", className: w("luminus-app-search-input", xe.input), value: i, onChange: (b) => {
|
|
3374
|
+
var x;
|
|
3375
|
+
return l(((x = b.target) == null ? void 0 : x.value) ?? "");
|
|
3376
|
+
}, onFocus: () => h.length > 0 && g(!0) }),
|
|
3377
|
+
/* @__PURE__ */ o.jsx(tt.Text, { className: w("p-0 rounded", xe.inputGroupText, xe.right), children: /* @__PURE__ */ o.jsx("button", { type: "submit", className: w("text-primary", xe.submitButton), children: /* @__PURE__ */ o.jsx(Li, {}) }) }),
|
|
3378
|
+
/* @__PURE__ */ o.jsx(sc, { query: c, searchTypes: n, show: p, onCancel: () => g(!1), groups: h, isLoading: d })
|
|
3380
3379
|
] }) });
|
|
3381
3380
|
}, hc = "_card_19733_1", mc = "_header_19733_6", fc = "_header-content_19733_13", pc = "_title_19733_19", gc = "_collapse-icon_19733_22", xc = "_collapsed_19733_27", wc = "_content_19733_30", we = {
|
|
3382
3381
|
card: hc,
|
|
@@ -3392,23 +3391,23 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3392
3391
|
const l = i.collapsible ? i.controlled ? !1 : i.defaultOpen ?? !1 : !0, [c, u] = P(l), d = i.collapsible ? i.controlled ? i.isOpen : c : !0;
|
|
3393
3392
|
return O(() => {
|
|
3394
3393
|
u(l);
|
|
3395
|
-
}, [l]), /* @__PURE__ */ o.jsxs("div", { className:
|
|
3394
|
+
}, [l]), /* @__PURE__ */ o.jsxs("div", { className: w("luminus-card rounded shadow-sm", we.card, {
|
|
3396
3395
|
[r ?? ""]: r
|
|
3397
3396
|
}), children: [
|
|
3398
|
-
/* @__PURE__ */ o.jsxs("div", { role: i.collapsible ? "button" : void 0, className:
|
|
3397
|
+
/* @__PURE__ */ o.jsxs("div", { role: i.collapsible ? "button" : void 0, className: w("header", we.header, {
|
|
3399
3398
|
[s ?? ""]: s
|
|
3400
3399
|
}), onClick: () => {
|
|
3401
3400
|
i.collapsible && (i.controlled ? i.onToggle(!i.isOpen) : u(!c));
|
|
3402
3401
|
}, children: [
|
|
3403
|
-
/* @__PURE__ */ o.jsxs("div", { className:
|
|
3404
|
-
/* @__PURE__ */ o.jsx(G, { variant: "h6", className:
|
|
3402
|
+
/* @__PURE__ */ o.jsxs("div", { className: w("header-content", we.headerContent), children: [
|
|
3403
|
+
/* @__PURE__ */ o.jsx(G, { variant: "h6", className: w("text-primary", we.title), children: n }),
|
|
3405
3404
|
e ?? null
|
|
3406
3405
|
] }),
|
|
3407
|
-
i.collapsible && /* @__PURE__ */ o.jsx(nn, { className:
|
|
3406
|
+
i.collapsible && /* @__PURE__ */ o.jsx(nn, { className: w(we.collapseIcon, {
|
|
3408
3407
|
[we.collapsed]: d
|
|
3409
3408
|
}) })
|
|
3410
3409
|
] }),
|
|
3411
|
-
/* @__PURE__ */ o.jsx(yn, { in: d, children: /* @__PURE__ */ o.jsx("div", { className:
|
|
3410
|
+
/* @__PURE__ */ o.jsx(yn, { in: d, children: /* @__PURE__ */ o.jsx("div", { className: w("card-content border-top border-primary", we.content, {
|
|
3412
3411
|
[a ?? ""]: a
|
|
3413
3412
|
}), children: t }) })
|
|
3414
3413
|
] });
|
|
@@ -3431,44 +3430,44 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3431
3430
|
}, Tc = "_backdrop_3huvf_1", Ec = "_show_3huvf_11", Ut = {
|
|
3432
3431
|
backdrop: Tc,
|
|
3433
3432
|
show: Ec
|
|
3434
|
-
}, lr = ({ show: n, onClick: e }) => /* @__PURE__ */ o.jsx("div", { className:
|
|
3433
|
+
}, lr = ({ show: n, onClick: e }) => /* @__PURE__ */ o.jsx("div", { className: w("luminus-backdrop", Ut.backdrop, {
|
|
3435
3434
|
[Ut.show]: n
|
|
3436
3435
|
}), onClick: () => e && e() }), Dc = ({ show: n, onClose: e, photos: t, defaultIndex: r, uploadPhotosText: s, noPhotosText: a, onUploadPhotos: i, photoActions: l }) => {
|
|
3437
|
-
const c = q(null), [u, d] = P(r), h = t.at(u),
|
|
3436
|
+
const c = q(null), [u, d] = P(r), h = t.at(u), p = u > 0, g = u < t.length - 1;
|
|
3438
3437
|
O(() => {
|
|
3439
3438
|
n && d(r);
|
|
3440
3439
|
}, [r, n]), O(() => {
|
|
3441
3440
|
u >= t.length && d(t.length - 1);
|
|
3442
3441
|
}, [t, u]);
|
|
3443
|
-
const b = S((
|
|
3444
|
-
switch (
|
|
3442
|
+
const b = S((x) => {
|
|
3443
|
+
switch (x.key) {
|
|
3445
3444
|
case "ArrowLeft":
|
|
3446
|
-
|
|
3445
|
+
x.stopPropagation(), p && d((f) => f - 1);
|
|
3447
3446
|
break;
|
|
3448
3447
|
case "ArrowRight":
|
|
3449
|
-
|
|
3448
|
+
x.stopPropagation(), g && d((f) => f + 1);
|
|
3450
3449
|
break;
|
|
3451
3450
|
case "Escape":
|
|
3452
|
-
|
|
3451
|
+
x.stopPropagation(), e();
|
|
3453
3452
|
break;
|
|
3454
3453
|
}
|
|
3455
|
-
}, [g,
|
|
3454
|
+
}, [g, p, e]);
|
|
3456
3455
|
return hn(b), /* @__PURE__ */ o.jsxs(o.Fragment, { children: [
|
|
3457
3456
|
/* @__PURE__ */ o.jsx(lr, { show: n, onClick: e }),
|
|
3458
|
-
/* @__PURE__ */ o.jsxs("div", { ref: c, className:
|
|
3457
|
+
/* @__PURE__ */ o.jsxs("div", { ref: c, className: w("luminus-lightbox rounded shadow", se.lightbox, {
|
|
3459
3458
|
[se.show]: n
|
|
3460
3459
|
}), children: [
|
|
3461
3460
|
/* @__PURE__ */ o.jsxs("div", { className: se.header, children: [
|
|
3462
|
-
/* @__PURE__ */ o.jsxs("div", { className:
|
|
3463
|
-
i && /* @__PURE__ */ o.jsx(sr, { accept: ".jpg,.jpeg,.png", onUpload: (
|
|
3464
|
-
|
|
3461
|
+
/* @__PURE__ */ o.jsxs("div", { className: w("rounded", se.photoActions), children: [
|
|
3462
|
+
i && /* @__PURE__ */ o.jsx(sr, { accept: ".jpg,.jpeg,.png", onUpload: (x) => {
|
|
3463
|
+
x.length > 0 && i(Array.from(x));
|
|
3465
3464
|
}, icon: /* @__PURE__ */ o.jsx(rn, { style: { fontSize: 18 } }), multiple: !0, className: "me-3", children: s ?? null }),
|
|
3466
|
-
h && (l == null ? void 0 : l.map(({ label:
|
|
3465
|
+
h && (l == null ? void 0 : l.map(({ label: x, onClick: f, ..._ }, k) => /* @__PURE__ */ o.jsx(
|
|
3467
3466
|
lt,
|
|
3468
3467
|
{
|
|
3469
|
-
onClick: () =>
|
|
3468
|
+
onClick: () => f(h.id),
|
|
3470
3469
|
..._,
|
|
3471
|
-
children:
|
|
3470
|
+
children: x
|
|
3472
3471
|
},
|
|
3473
3472
|
`action-${k}`
|
|
3474
3473
|
)))
|
|
@@ -3477,15 +3476,15 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3477
3476
|
] }),
|
|
3478
3477
|
t.length === 0 && /* @__PURE__ */ o.jsx("div", { className: "w-100 h-100 d-flex align-items-center justify-content-center", children: /* @__PURE__ */ o.jsx(G, { variant: "body", children: a ?? "No photos available" }) }),
|
|
3479
3478
|
h && /* @__PURE__ */ o.jsxs("div", { className: se.photoContainer, children: [
|
|
3480
|
-
/* @__PURE__ */ o.jsx("div", { role:
|
|
3481
|
-
/* @__PURE__ */ o.jsx("img", { src: h.lgSrc, alt: h.alt, className:
|
|
3482
|
-
/* @__PURE__ */ o.jsx("div", { role: g ? "button" : void 0, className:
|
|
3479
|
+
/* @__PURE__ */ o.jsx("div", { role: p ? "button" : void 0, className: w("align-items-start", se.navButton), onClick: () => p && d((x) => x - 1), children: p && /* @__PURE__ */ o.jsx(mt, { style: { fontSize: "40px" } }) }),
|
|
3480
|
+
/* @__PURE__ */ o.jsx("img", { src: h.lgSrc, alt: h.alt, className: w("rounded", se.photo) }),
|
|
3481
|
+
/* @__PURE__ */ o.jsx("div", { role: g ? "button" : void 0, className: w("align-items-end", se.navButton), onClick: () => g && d((x) => x + 1), children: g && /* @__PURE__ */ o.jsx(ft, { style: { fontSize: "40px" } }) })
|
|
3483
3482
|
] }),
|
|
3484
|
-
/* @__PURE__ */ o.jsx("div", { className: se.photosPreview, children: t.map((
|
|
3485
|
-
/* @__PURE__ */ o.jsx("img", { role:
|
|
3486
|
-
[se.selected]:
|
|
3487
|
-
}) },
|
|
3488
|
-
|
|
3483
|
+
/* @__PURE__ */ o.jsx("div", { className: se.photosPreview, children: t.map((x, f) => /* @__PURE__ */ o.jsxs("div", { role: "button", onClick: () => d(f), className: "position-relative", children: [
|
|
3484
|
+
/* @__PURE__ */ o.jsx("img", { role: f !== u ? "button" : void 0, src: x.smSrc, alt: x.alt, className: w("rounded", se.photo, {
|
|
3485
|
+
[se.selected]: f === u
|
|
3486
|
+
}) }, x.id),
|
|
3487
|
+
x.isDefault && /* @__PURE__ */ o.jsx("div", { className: w("text-primary", se.defaultIndicator), children: /* @__PURE__ */ o.jsx(Lr, {}) })
|
|
3489
3488
|
] })) })
|
|
3490
3489
|
] })
|
|
3491
3490
|
] });
|
|
@@ -3539,7 +3538,7 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3539
3538
|
spacer: Pc
|
|
3540
3539
|
}, Mc = ({ children: n }) => /* @__PURE__ */ o.jsxs(o.Fragment, { children: [
|
|
3541
3540
|
/* @__PURE__ */ o.jsx("div", { className: Kt.spacer }),
|
|
3542
|
-
/* @__PURE__ */ o.jsx("div", { className:
|
|
3541
|
+
/* @__PURE__ */ o.jsx("div", { className: w("luminus-floating-action-container shadow", Kt.submitContainer), children: n })
|
|
3543
3542
|
] }), Ac = "_timeline_g1754_1", Fc = "_step-container_g1754_1", Wc = "_step-date_g1754_1", Rc = "_step-content_g1754_4", Yc = "_content-header_g1754_8", Lc = "_content-text_g1754_11", qc = "_step-icon_g1754_14", ve = {
|
|
3544
3543
|
timeline: Ac,
|
|
3545
3544
|
"step-container": "_step-container_g1754_1",
|
|
@@ -3554,18 +3553,18 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3554
3553
|
contentText: Lc,
|
|
3555
3554
|
"step-icon": "_step-icon_g1754_14",
|
|
3556
3555
|
stepIcon: qc
|
|
3557
|
-
}, fl = ({ steps: n }) => /* @__PURE__ */ o.jsx("div", { className: ve.timeline, children: n.sort((e, t) => ls(e.date ?? /* @__PURE__ */ new Date(), t.date ?? /* @__PURE__ */ new Date())).map((e, t) => /* @__PURE__ */ o.jsxs("div", { className:
|
|
3558
|
-
/* @__PURE__ */ o.jsx("div", { className: "col-3", children: e.date && /* @__PURE__ */ o.jsxs(G, { variant: "caption", className:
|
|
3556
|
+
}, fl = ({ steps: n }) => /* @__PURE__ */ o.jsx("div", { className: ve.timeline, children: n.sort((e, t) => ls(e.date ?? /* @__PURE__ */ new Date(), t.date ?? /* @__PURE__ */ new Date())).map((e, t) => /* @__PURE__ */ o.jsxs("div", { className: w("row g-0 gx-3", ve.stepContainer), children: [
|
|
3557
|
+
/* @__PURE__ */ o.jsx("div", { className: "col-3", children: e.date && /* @__PURE__ */ o.jsxs(G, { variant: "caption", className: w("h-100 d-flex flex-column align-items-end justify-content-center gap-0", ve.stepDate), children: [
|
|
3559
3558
|
/* @__PURE__ */ o.jsx("div", { children: ot(e.date, "dd.MM.yyyy") }),
|
|
3560
3559
|
/* @__PURE__ */ o.jsx("div", { children: ot(e.date, "HH:mm") })
|
|
3561
3560
|
] }) }),
|
|
3562
|
-
/* @__PURE__ */ o.jsx("div", { className: "col-9", children: /* @__PURE__ */ o.jsxs("div", { className:
|
|
3563
|
-
/* @__PURE__ */ o.jsxs("div", { className:
|
|
3561
|
+
/* @__PURE__ */ o.jsx("div", { className: "col-9", children: /* @__PURE__ */ o.jsxs("div", { className: w("h-100 d-flex flex-column gap-1 border-start border-2 p-3", ve.stepContent), children: [
|
|
3562
|
+
/* @__PURE__ */ o.jsxs("div", { className: w("d-flex gap-2 align-items-center", ve.contentHeader), children: [
|
|
3564
3563
|
e.person && /* @__PURE__ */ o.jsx(sn, { name: e.person.name ?? "", size: 22, fontSize: 12 }),
|
|
3565
3564
|
typeof e.title == "string" ? /* @__PURE__ */ o.jsx(G, { variant: "body", className: "fw-bold", children: e.title }) : e.title
|
|
3566
3565
|
] }),
|
|
3567
3566
|
e.text && /* @__PURE__ */ o.jsx(G, { variant: "body2", className: ve.contentText, children: e.text }),
|
|
3568
|
-
/* @__PURE__ */ o.jsx("div", { className:
|
|
3567
|
+
/* @__PURE__ */ o.jsx("div", { className: w("text-primary", ve.stepIcon), children: e.icon ?? /* @__PURE__ */ o.jsx(Vr, {}) })
|
|
3569
3568
|
] }) })
|
|
3570
3569
|
] }, t)) }), pl = ({ heading: n, content: e, placement: t, children: r, trigger: s }) => /* @__PURE__ */ o.jsx(Gr, { placement: t, overlay: /* @__PURE__ */ o.jsxs(Je, { className: "luminus-popover", children: [
|
|
3571
3570
|
/* @__PURE__ */ o.jsx(Je.Header, { children: typeof n == "string" ? /* @__PURE__ */ o.jsx(G, { variant: "h6", className: "text-primary", children: n }) : n }),
|
|
@@ -3579,13 +3578,13 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3579
3578
|
}, gl = ({ InputContainer: n = ke, label: e, value: t, onChange: r, hidden: s, disabled: a, className: i, type: l, withoutLabel: c }) => /* @__PURE__ */ o.jsx(n, { isForCheckInput: !0, hidden: s, label: e ?? "", withoutLabel: c, className: i, children: /* @__PURE__ */ o.jsx(Q.Check, { id: `check-${e}`, type: l ?? "checkbox", label: e ?? "", checked: t, onChange: (u) => {
|
|
3580
3579
|
var d;
|
|
3581
3580
|
r && r(((d = u.target) == null ? void 0 : d.checked) ?? !1);
|
|
3582
|
-
}, className: i ?? "", hidden: s ?? !1, disabled: a ?? !1 }) }), xl = ({ InputContainer: n = ke, type: e, value: t, onChange: r, debounceMs: s, label: a, withoutLabel: i, placeholder: l, size: c, hidden: u, disabled: d, showClearIcon: h, clearValue:
|
|
3581
|
+
}, className: i ?? "", hidden: s ?? !1, disabled: a ?? !1 }) }), xl = ({ InputContainer: n = ke, type: e, value: t, onChange: r, debounceMs: s, label: a, withoutLabel: i, placeholder: l, size: c, hidden: u, disabled: d, showClearIcon: h, clearValue: p, list: g, className: b, step: x, noSelectOnFocus: f }) => {
|
|
3583
3582
|
const _ = e === "number", k = S(() => {
|
|
3584
3583
|
if (!r)
|
|
3585
3584
|
return;
|
|
3586
|
-
const y =
|
|
3585
|
+
const y = p ?? null;
|
|
3587
3586
|
r(_ ? y ? Number(y) : null : (y == null ? void 0 : y.toString()) ?? "");
|
|
3588
|
-
}, [
|
|
3587
|
+
}, [p, _, r]), m = q(null), [N, j] = P((t == null ? void 0 : t.toString()) ?? ""), v = S((y) => {
|
|
3589
3588
|
const C = y;
|
|
3590
3589
|
r && (_ && r(C == null || C === "" ? null : Number(C)), r(C || null));
|
|
3591
3590
|
}, [_, r]), $ = S((y) => {
|
|
@@ -3605,8 +3604,8 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3605
3604
|
const [D, I] = P(!1), T = fn(e, t ? t.toString() ?? null : null, D);
|
|
3606
3605
|
return /* @__PURE__ */ o.jsxs(n, { withoutLabel: i, label: a ?? "", hidden: u, className: b, children: [
|
|
3607
3606
|
/* @__PURE__ */ o.jsx(Q.Control, { type: T, placeholder: l ?? a, size: c, value: s ? N : t ?? "", onChange: $, className: b ?? "", hidden: u, disabled: d ?? !1, list: g, onFocus: (y) => {
|
|
3608
|
-
I(!0), !
|
|
3609
|
-
}, onBlur: () => I(!1), step:
|
|
3607
|
+
I(!0), !f && y.target.select();
|
|
3608
|
+
}, onBlur: () => I(!1), step: x }),
|
|
3610
3609
|
h && t && r && !d && /* @__PURE__ */ o.jsx("div", { className: `luminus-input-remove-icon ${e !== "text" ? "inset" : ""}`, children: /* @__PURE__ */ o.jsx(z, { color: "secondary", size: "sm", onClick: k, children: /* @__PURE__ */ o.jsx(ce, {}) }) })
|
|
3611
3610
|
] });
|
|
3612
3611
|
}, wl = ({
|
|
@@ -3622,31 +3621,31 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3622
3621
|
disabled: u,
|
|
3623
3622
|
showClearIcon: d,
|
|
3624
3623
|
clearValue: h,
|
|
3625
|
-
noSortOptions:
|
|
3624
|
+
noSortOptions: p,
|
|
3626
3625
|
className: g,
|
|
3627
3626
|
noEmptyOption: b
|
|
3628
3627
|
// it will still add the empty option if there is no value provided or value is empty string or null
|
|
3629
3628
|
}) => {
|
|
3630
|
-
const
|
|
3629
|
+
const x = S(() => {
|
|
3631
3630
|
if (!r)
|
|
3632
3631
|
return;
|
|
3633
|
-
const
|
|
3634
|
-
r(i ?
|
|
3632
|
+
const f = h ?? null;
|
|
3633
|
+
r(i ? f ? Number(f) : null : (f == null ? void 0 : f.toString()) ?? "");
|
|
3635
3634
|
}, [h, i, r]);
|
|
3636
3635
|
return /* @__PURE__ */ o.jsxs(n, { withoutLabel: a, label: s ?? "", hidden: c, className: g, children: [
|
|
3637
|
-
/* @__PURE__ */ o.jsxs(Q.Select, { size: l, value: e ?? "", onChange: (
|
|
3636
|
+
/* @__PURE__ */ o.jsxs(Q.Select, { size: l, value: e ?? "", onChange: (f) => {
|
|
3638
3637
|
var k;
|
|
3639
3638
|
if (!r)
|
|
3640
3639
|
return;
|
|
3641
|
-
const _ = (k =
|
|
3640
|
+
const _ = (k = f.target) == null ? void 0 : k.value;
|
|
3642
3641
|
i && r(_ ? parseInt(_, 10) : null), r(_ || null);
|
|
3643
3642
|
}, className: g ?? "", hidden: c, disabled: u ?? !1, children: [
|
|
3644
3643
|
b && !(e == null || e === "") ? void 0 : /* @__PURE__ */ o.jsx("option", { value: "" }),
|
|
3645
|
-
t == null ? void 0 : t.sort((
|
|
3644
|
+
t == null ? void 0 : t.sort((f, _) => p ? 0 : (f.name ?? "").localeCompare(_.name ?? "")).map((f) => /* @__PURE__ */ o.jsx("option", { value: f.id ?? "", children: f.name }, f.id))
|
|
3646
3645
|
] }),
|
|
3647
|
-
d && e && r && !u && /* @__PURE__ */ o.jsx("div", { className: "luminus-input-remove-icon inset", children: /* @__PURE__ */ o.jsx(z, { color: "secondary", size: "sm", onClick:
|
|
3646
|
+
d && e && r && !u && /* @__PURE__ */ o.jsx("div", { className: "luminus-input-remove-icon inset", children: /* @__PURE__ */ o.jsx(z, { color: "secondary", size: "sm", onClick: x, children: /* @__PURE__ */ o.jsx(ce, {}) }) })
|
|
3648
3647
|
] });
|
|
3649
|
-
}, vl = ({ InputContainer: n = ke, items: e, defaultSelection: t, selectedItemNavigateTo: r, onSearchQueryChange: s, texts: a, isLoading: i, isNumber: l, onSelect: c, label: u, withoutLabel: d, size: h, dropdownItemsNameWidth:
|
|
3648
|
+
}, vl = ({ InputContainer: n = ke, items: e, defaultSelection: t, selectedItemNavigateTo: r, onSearchQueryChange: s, texts: a, isLoading: i, isNumber: l, onSelect: c, label: u, withoutLabel: d, size: h, dropdownItemsNameWidth: p, additionalColumns: g, hidden: b, disabled: x, displayIdAsName: f, CustomOnChangeComponent: _, className: k }) => {
|
|
3650
3649
|
var C, F;
|
|
3651
3650
|
const [m, N] = P(t), [j, v] = P(!1);
|
|
3652
3651
|
O(() => {
|
|
@@ -3661,40 +3660,40 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3661
3660
|
c && c(m);
|
|
3662
3661
|
}, [m, c]);
|
|
3663
3662
|
const I = q(null), T = r !== void 0, y = T && m !== null;
|
|
3664
|
-
return /* @__PURE__ */ o.jsx(o.Fragment, { children: /* @__PURE__ */ o.jsxs(n, { withoutLabel: d, label: u ?? "", hidden: b, inputContainerClassName:
|
|
3663
|
+
return /* @__PURE__ */ o.jsx(o.Fragment, { children: /* @__PURE__ */ o.jsxs(n, { withoutLabel: d, label: u ?? "", hidden: b, inputContainerClassName: w({ "luminus-dropdown-select-open": j }), className: k, children: [
|
|
3665
3664
|
/* @__PURE__ */ o.jsxs(ur, { currentSelection: m, selectedItemNavigateTo: r, children: [
|
|
3666
|
-
|
|
3665
|
+
f && (m == null ? void 0 : m.name) && /* @__PURE__ */ o.jsx(G, { variant: "caption", className: "d-flex justify-content-end mt-2 luminus-dropdown-selection-name", children: m.name }),
|
|
3667
3666
|
/* @__PURE__ */ o.jsxs(Q.Select, { ref: I, size: h, value: (m == null ? void 0 : m.id) ?? "", onChange: (R) => N({
|
|
3668
3667
|
id: l ? Number(R.target.value) ?? null : R.target.value,
|
|
3669
3668
|
name: ""
|
|
3670
3669
|
}), onMouseDown: (R) => {
|
|
3671
3670
|
R.currentTarget.focus(), R.preventDefault();
|
|
3672
3671
|
}, onClick: () => {
|
|
3673
|
-
!T && !
|
|
3674
|
-
}, className:
|
|
3675
|
-
"luminus-dropdown-picker-disabled":
|
|
3672
|
+
!T && !x && v(!0);
|
|
3673
|
+
}, className: w("w-100", {
|
|
3674
|
+
"luminus-dropdown-picker-disabled": x,
|
|
3676
3675
|
"luminus-dropdown-picker-link": y
|
|
3677
3676
|
}), hidden: b, children: [
|
|
3678
3677
|
/* @__PURE__ */ o.jsx("option", { value: "" }),
|
|
3679
3678
|
t && /* @__PURE__ */ o.jsx("option", { value: t.id ?? void 0, children: t.name && ((C = t.name) == null ? void 0 : C.length) > 0 ? t.name : t.id }),
|
|
3680
3679
|
m && /* @__PURE__ */ o.jsx("option", { value: m.id ?? void 0, children: m.name && ((F = m.name) == null ? void 0 : F.length) > 0 ? m.name : m.id })
|
|
3681
3680
|
] }),
|
|
3682
|
-
_ || !
|
|
3683
|
-
!_ && !
|
|
3681
|
+
_ || !x && T ? /* @__PURE__ */ o.jsxs("div", { className: "custom-picker-button", children: [
|
|
3682
|
+
!_ && !x && T && /* @__PURE__ */ o.jsx(z, { size: "sm", color: "secondary", onClick: (R) => {
|
|
3684
3683
|
R.preventDefault(), R.stopPropagation(), v(!0);
|
|
3685
3684
|
}, children: /* @__PURE__ */ o.jsx(on, {}) }),
|
|
3686
3685
|
_ ?? null
|
|
3687
3686
|
] }) : null
|
|
3688
3687
|
] }),
|
|
3689
|
-
I.current && /* @__PURE__ */ o.jsx(jt, { show: j, onCancel: () => v(!1), items: e, currentSelection: m, onSelectionChange: D, onSearchQueryChange: s, texts: a, itemsNameWidth:
|
|
3688
|
+
I.current && /* @__PURE__ */ o.jsx(jt, { show: j, onCancel: () => v(!1), items: e, currentSelection: m, onSelectionChange: D, onSearchQueryChange: s, texts: a, itemsNameWidth: p, additionalColumns: g, isLoading: i, disabled: x, inputRef: I })
|
|
3690
3689
|
] }) });
|
|
3691
|
-
}, yl = ({ InputContainer: n = ke, value: e, onChange: t, label: r, size: s, showClearIcon: a, clearValue: i, hidden: l, disabled: c, rows: u, withoutLabel: d, debounceMs: h, className:
|
|
3690
|
+
}, yl = ({ InputContainer: n = ke, value: e, onChange: t, label: r, size: s, showClearIcon: a, clearValue: i, hidden: l, disabled: c, rows: u, withoutLabel: d, debounceMs: h, className: p }) => {
|
|
3692
3691
|
const g = S(() => {
|
|
3693
3692
|
if (!t)
|
|
3694
3693
|
return;
|
|
3695
3694
|
const m = i ?? null;
|
|
3696
3695
|
t((m == null ? void 0 : m.toString()) ?? "");
|
|
3697
|
-
}, [i, t]), b = q(null), [
|
|
3696
|
+
}, [i, t]), b = q(null), [x, f] = P((e == null ? void 0 : e.toString()) ?? ""), _ = S((m) => {
|
|
3698
3697
|
const N = m;
|
|
3699
3698
|
t && t(N || null);
|
|
3700
3699
|
}, [t]), k = S((m) => {
|
|
@@ -3704,23 +3703,23 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3704
3703
|
_(N);
|
|
3705
3704
|
return;
|
|
3706
3705
|
}
|
|
3707
|
-
|
|
3706
|
+
f(N), b.current !== null && window.clearTimeout(b.current), b.current = window.setTimeout(() => {
|
|
3708
3707
|
_(N);
|
|
3709
3708
|
}, h);
|
|
3710
3709
|
}, [h, _]);
|
|
3711
3710
|
return O(() => {
|
|
3712
|
-
|
|
3713
|
-
}, [e]), /* @__PURE__ */ o.jsxs(n, { label: r ?? "", hidden: l, withoutLabel: d, className:
|
|
3714
|
-
/* @__PURE__ */ o.jsx(Q.Control, { as: "textarea", size: s, value: h ?
|
|
3711
|
+
f(e === null ? "" : e.toString());
|
|
3712
|
+
}, [e]), /* @__PURE__ */ o.jsxs(n, { label: r ?? "", hidden: l, withoutLabel: d, className: p, isForTextAreaInput: !0, children: [
|
|
3713
|
+
/* @__PURE__ */ o.jsx(Q.Control, { as: "textarea", size: s, value: h ? x : e ?? "", onChange: k, hidden: l, disabled: c, rows: u ?? 2, className: "w-100" }),
|
|
3715
3714
|
a && e && t && !c && /* @__PURE__ */ o.jsx("div", { className: "luminus-input-remove-icon", children: /* @__PURE__ */ o.jsx(z, { color: "secondary", size: "sm", onClick: g, children: /* @__PURE__ */ o.jsx(ce, {}) }) })
|
|
3716
3715
|
] });
|
|
3717
|
-
}, bl = ({ InputContainer: n = ke, value: e, onChange: t, debounceMs: r, label: s, withoutLabel: a, placeholder: i, size: l, hidden: c, disabled: u, showClearIcon: d, clearValue: h, className:
|
|
3718
|
-
const
|
|
3716
|
+
}, bl = ({ InputContainer: n = ke, value: e, onChange: t, debounceMs: r, label: s, withoutLabel: a, placeholder: i, size: l, hidden: c, disabled: u, showClearIcon: d, clearValue: h, className: p, step: g, stepperStep: b = 1 }) => {
|
|
3717
|
+
const x = S(() => {
|
|
3719
3718
|
if (!t)
|
|
3720
3719
|
return;
|
|
3721
3720
|
const j = h ?? null;
|
|
3722
3721
|
t(j ? Number(j) : null);
|
|
3723
|
-
}, [h, t]),
|
|
3722
|
+
}, [h, t]), f = q(null), [_, k] = P((e == null ? void 0 : e.toString()) ?? ""), m = S((j) => {
|
|
3724
3723
|
const v = j;
|
|
3725
3724
|
t && t(v == null || v === "" ? null : Number(v));
|
|
3726
3725
|
}, [t]), N = S((j) => {
|
|
@@ -3730,24 +3729,24 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3730
3729
|
m(v);
|
|
3731
3730
|
return;
|
|
3732
3731
|
}
|
|
3733
|
-
k(v),
|
|
3732
|
+
k(v), f.current !== null && window.clearTimeout(f.current), f.current = window.setTimeout(() => {
|
|
3734
3733
|
m(v);
|
|
3735
3734
|
}, r);
|
|
3736
3735
|
}, [r, m]);
|
|
3737
3736
|
return O(() => {
|
|
3738
3737
|
k(e === null ? "" : e.toString());
|
|
3739
|
-
}, [e]), /* @__PURE__ */ o.jsx(n, { withoutLabel: a, label: s ?? "", hidden: c, className:
|
|
3740
|
-
/* @__PURE__ */ o.jsx(Q.Control, { type: "number", placeholder: i ?? s, size: l, value: r ? _ : e ?? "", onChange: N, className: `luminus-numeric-stepper ${
|
|
3738
|
+
}, [e]), /* @__PURE__ */ o.jsx(n, { withoutLabel: a, label: s ?? "", hidden: c, className: p, children: /* @__PURE__ */ o.jsxs("div", { className: "luminus-input-container position-relative w-100", children: [
|
|
3739
|
+
/* @__PURE__ */ o.jsx(Q.Control, { type: "number", placeholder: i ?? s, size: l, value: r ? _ : e ?? "", onChange: N, className: `luminus-numeric-stepper ${p ?? ""}`, hidden: c, disabled: u ?? !1, step: g }),
|
|
3741
3740
|
/* @__PURE__ */ o.jsx("div", { className: "stepper-icon left", children: !u && /* @__PURE__ */ o.jsx(z, { size: "sm", onClick: (j) => {
|
|
3742
3741
|
j.preventDefault(), j.stopPropagation(), m(((e ?? 0) - b).toString());
|
|
3743
3742
|
}, children: /* @__PURE__ */ o.jsx(ar, {}) }) }),
|
|
3744
3743
|
/* @__PURE__ */ o.jsx("div", { className: "stepper-icon right", children: !u && /* @__PURE__ */ o.jsx(z, { size: "sm", onClick: (j) => {
|
|
3745
3744
|
j.preventDefault(), j.stopPropagation(), m(((e ?? 0) + b).toString());
|
|
3746
3745
|
}, children: /* @__PURE__ */ o.jsx(ir, {}) }) }),
|
|
3747
|
-
d && e && t && !u && /* @__PURE__ */ o.jsx("div", { className: "luminus-input-remove-icon", children: /* @__PURE__ */ o.jsx(z, { color: "secondary", size: "sm", onClick:
|
|
3746
|
+
d && e && t && !u && /* @__PURE__ */ o.jsx("div", { className: "luminus-input-remove-icon", children: /* @__PURE__ */ o.jsx(z, { color: "secondary", size: "sm", onClick: x, children: /* @__PURE__ */ o.jsx(ce, {}) }) })
|
|
3748
3747
|
] }) });
|
|
3749
3748
|
}, _l = ({ InputContainer: n = fe, formField: e, label: t, resetsFields: r, type: s, required: a, hidden: i, disabled: l, withoutLabel: c, className: u }) => {
|
|
3750
|
-
const { register: d, formState: h, setValue:
|
|
3749
|
+
const { register: d, formState: h, setValue: p } = le(), [g, b] = P(void 0), [x, f] = P(!1);
|
|
3751
3750
|
O(() => {
|
|
3752
3751
|
const k = e.split(".");
|
|
3753
3752
|
let m = h.errors;
|
|
@@ -3755,19 +3754,19 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3755
3754
|
m !== void 0 && (m = m[N]);
|
|
3756
3755
|
}), b(m);
|
|
3757
3756
|
}, [h, e]), O(() => {
|
|
3758
|
-
h.isSubmitted &&
|
|
3757
|
+
h.isSubmitted && f(!0);
|
|
3759
3758
|
}, [h]);
|
|
3760
3759
|
const _ = g !== void 0;
|
|
3761
3760
|
return /* @__PURE__ */ o.jsxs(n, { isForCheckInput: !0, hidden: i, label: `${t}${a ? " *" : ""}`, isInvalid: _, withoutLabel: c, className: u, children: [
|
|
3762
3761
|
/* @__PURE__ */ o.jsx(Q.Check, { id: `check-${e}`, type: s ?? "checkbox", label: `${t}${a ? " *" : ""}`, ...d(e, {
|
|
3763
3762
|
onChange: () => {
|
|
3764
|
-
r && r.forEach((k) =>
|
|
3763
|
+
r && r.forEach((k) => p(k, null, { shouldDirty: !0, shouldValidate: x }));
|
|
3765
3764
|
}
|
|
3766
3765
|
}), isInvalid: _, hidden: i, disabled: l, className: "w-100" }),
|
|
3767
3766
|
g && /* @__PURE__ */ o.jsx(pe, { message: g.message })
|
|
3768
3767
|
] });
|
|
3769
3768
|
}, jl = ({ InputContainer: n = fe, label: e, formField: t, options: r, resetsFields: s, required: a, disabled: i, hidden: l, className: c }) => {
|
|
3770
|
-
const { register: u, formState: d, setValue: h, watch:
|
|
3769
|
+
const { register: u, formState: d, setValue: h, watch: p } = le(), [g, b] = P(void 0), [x, f] = P(!1), _ = K(() => r, [r]);
|
|
3771
3770
|
O(() => {
|
|
3772
3771
|
const m = t.split(".");
|
|
3773
3772
|
let N = d.errors;
|
|
@@ -3775,45 +3774,45 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3775
3774
|
N !== void 0 && (N = N[j]);
|
|
3776
3775
|
}), b(N);
|
|
3777
3776
|
}, [d, t]), O(() => {
|
|
3778
|
-
d.isSubmitted &&
|
|
3777
|
+
d.isSubmitted && f(!0);
|
|
3779
3778
|
}, [d]);
|
|
3780
3779
|
const k = g !== void 0;
|
|
3781
3780
|
return /* @__PURE__ */ o.jsxs(n, { isForRadioInput: !0, hidden: l, withoutLabel: !e, label: `${e}${a ? " *" : ""}`, isInvalid: k, className: c, children: [
|
|
3782
|
-
_.map((m) => /* @__PURE__ */ o.jsx(Q.Check, { id: `radio-${m.id}`, label: m.name, type: "radio", value: m.id ?? "", checked:
|
|
3781
|
+
_.map((m) => /* @__PURE__ */ o.jsx(Q.Check, { id: `radio-${m.id}`, label: m.name, type: "radio", value: m.id ?? "", checked: p(t) === m.id, ...u(t, {
|
|
3783
3782
|
onChange: () => {
|
|
3784
|
-
s && s.forEach((N) => h(N, null, { shouldDirty: !0, shouldValidate:
|
|
3783
|
+
s && s.forEach((N) => h(N, null, { shouldDirty: !0, shouldValidate: x }));
|
|
3785
3784
|
}
|
|
3786
3785
|
}), isInvalid: k, hidden: l, disabled: i, className: "w-100" }, m.id)),
|
|
3787
3786
|
g && /* @__PURE__ */ o.jsx(pe, { message: g.message })
|
|
3788
3787
|
] });
|
|
3789
|
-
}, kl = ({ InputContainer: n = fe, formField: e, label: t, resetsFields: r, size: s, showClearIcon: a, clearValue: i, required: l, hidden: c, disabled: u, rows: d, withoutLabel: h, customFormControlProps:
|
|
3790
|
-
const { register: b, formState:
|
|
3788
|
+
}, kl = ({ InputContainer: n = fe, formField: e, label: t, resetsFields: r, size: s, showClearIcon: a, clearValue: i, required: l, hidden: c, disabled: u, rows: d, withoutLabel: h, customFormControlProps: p, className: g }) => {
|
|
3789
|
+
const { register: b, formState: x, setValue: f, watch: _ } = le(), [k, m] = P(void 0), [N, j] = P(!1), v = S(() => {
|
|
3791
3790
|
const I = i ?? null;
|
|
3792
|
-
|
|
3793
|
-
}, [i,
|
|
3791
|
+
f(e, (I == null ? void 0 : I.toString()) ?? "", { shouldDirty: !0, shouldValidate: N });
|
|
3792
|
+
}, [i, f, e, N]), $ = S(() => {
|
|
3794
3793
|
const I = e.split(".");
|
|
3795
|
-
let T =
|
|
3794
|
+
let T = x.errors;
|
|
3796
3795
|
I.forEach((y) => {
|
|
3797
3796
|
T !== void 0 && (T = T[y]);
|
|
3798
3797
|
}), m(T);
|
|
3799
|
-
}, [
|
|
3798
|
+
}, [x, e]);
|
|
3800
3799
|
O(() => {
|
|
3801
3800
|
$();
|
|
3802
3801
|
}, [$]), O(() => {
|
|
3803
|
-
|
|
3804
|
-
}, [
|
|
3802
|
+
x.isSubmitted && j(!0);
|
|
3803
|
+
}, [x]);
|
|
3805
3804
|
const D = k !== void 0;
|
|
3806
3805
|
return /* @__PURE__ */ o.jsxs(n, { label: `${t}${l ? " *" : ""}`, hidden: c, withoutLabel: h, isInvalid: D, className: g, isForTextAreaInput: !0, children: [
|
|
3807
3806
|
/* @__PURE__ */ o.jsx(Q.Control, { as: "textarea", size: s, ...b(e, {
|
|
3808
3807
|
setValueAs: (I) => I == null || I === "" ? null : I,
|
|
3809
3808
|
onChange: () => {
|
|
3810
|
-
r && r.forEach((I) =>
|
|
3809
|
+
r && r.forEach((I) => f(I, null, { shouldDirty: !0, shouldValidate: N }));
|
|
3811
3810
|
}
|
|
3812
|
-
}), isInvalid: D, hidden: c, disabled: u, rows: d ?? 2, className: "w-100", ...
|
|
3811
|
+
}), isInvalid: D, hidden: c, disabled: u, rows: d ?? 2, className: "w-100", ...p }),
|
|
3813
3812
|
a && _(e) && /* @__PURE__ */ o.jsx("div", { className: "luminus-input-remove-icon", children: /* @__PURE__ */ o.jsx(z, { color: "secondary", size: "sm", onClick: v, children: /* @__PURE__ */ o.jsx(ce, {}) }) }),
|
|
3814
3813
|
k && /* @__PURE__ */ o.jsx(pe, { message: k.message })
|
|
3815
3814
|
] });
|
|
3816
|
-
}, Nl = ({ InputContainer: n = fe, type: e, formField: t, label: r, placeholder: s, size: a, resetsFields: i, showClearIcon: l, clearValue: c, required: u, hidden: d, disabled: h, withoutLabel:
|
|
3815
|
+
}, Nl = ({ InputContainer: n = fe, type: e, formField: t, label: r, placeholder: s, size: a, resetsFields: i, showClearIcon: l, clearValue: c, required: u, hidden: d, disabled: h, withoutLabel: p, list: g, step: b, CustomOnChangeComponent: x, noSelectOnFocus: f, className: _ }) => {
|
|
3817
3816
|
const { register: k, formState: m, setValue: N, watch: j } = le(), [v, $] = P(void 0), [D, I] = P(!1), T = S(() => {
|
|
3818
3817
|
const A = c ?? null;
|
|
3819
3818
|
e === "number" ? N(t, A !== null ? Number(A) : null, {
|
|
@@ -3833,10 +3832,10 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3833
3832
|
m.isSubmitted && I(!0);
|
|
3834
3833
|
}, [m]);
|
|
3835
3834
|
const C = v !== void 0, [F, R] = P(!1), H = j(t), Z = fn(e, H ?? null, F);
|
|
3836
|
-
return /* @__PURE__ */ o.jsxs(n, { label: `${r}${u ? " *" : ""}`, hidden: d, withoutLabel:
|
|
3835
|
+
return /* @__PURE__ */ o.jsxs(n, { label: `${r}${u ? " *" : ""}`, hidden: d, withoutLabel: p, isInvalid: C, className: _, children: [
|
|
3837
3836
|
/* @__PURE__ */ o.jsxs("div", { className: "luminus-input-container position-relative w-100", children: [
|
|
3838
3837
|
/* @__PURE__ */ o.jsx(Q.Control, { type: Z, placeholder: s ?? r, size: a, onFocus: (A) => {
|
|
3839
|
-
R(!0), !
|
|
3838
|
+
R(!0), !f && A.target.select();
|
|
3840
3839
|
}, ...k(t, {
|
|
3841
3840
|
setValueAs: (A) => e === "number" ? A == null || A === "" ? null : Number(A) : A == null || A === "" ? null : A,
|
|
3842
3841
|
onChange: () => {
|
|
@@ -3844,12 +3843,12 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3844
3843
|
},
|
|
3845
3844
|
onBlur: () => R(!1)
|
|
3846
3845
|
}), isInvalid: C, hidden: d, disabled: h, list: g, className: "w-100", step: b }),
|
|
3847
|
-
|
|
3846
|
+
x && /* @__PURE__ */ o.jsx("div", { className: "custom-picker-button", children: x })
|
|
3848
3847
|
] }),
|
|
3849
3848
|
l && j(t) && /* @__PURE__ */ o.jsx("div", { className: `luminus-input-remove-icon ${e !== "text" ? "inset" : ""}`, children: /* @__PURE__ */ o.jsx(z, { color: "secondary", size: "sm", onClick: T, children: /* @__PURE__ */ o.jsx(ce, {}) }) }),
|
|
3850
3849
|
v && /* @__PURE__ */ o.jsx(pe, { message: v.message })
|
|
3851
3850
|
] });
|
|
3852
|
-
}, Cl = ({ InputContainer: n = fe, formField: e, label: t, size: r, defaultSelection: s, resetsFields: a, isNumber: i, required: l, hidden: c, disabled: u, items: d, onSearchQueryChange: h, selectedItemNavigateTo:
|
|
3851
|
+
}, Cl = ({ InputContainer: n = fe, formField: e, label: t, size: r, defaultSelection: s, resetsFields: a, isNumber: i, required: l, hidden: c, disabled: u, items: d, onSearchQueryChange: h, selectedItemNavigateTo: p, texts: g, dropdownItemsNameWidth: b, isLoading: x, withoutLabel: f, additionalColumns: _, CustomOnChangeComponent: k, displayIdAsName: m, className: N }) => {
|
|
3853
3852
|
const { formState: j, setValue: v, watch: $, control: D } = le(), [I, T] = P(void 0), [y, C] = P(!1), [F, R] = P(!1), H = $(e) ?? null, Z = H === (s == null ? void 0 : s.id) ? s == null ? void 0 : s.name : $(`${e}-DropdownName`), A = K(() => H == null ? null : { id: H ?? null, name: Z ?? "" }, [H, Z]), re = S(() => {
|
|
3854
3853
|
const B = e.split(".");
|
|
3855
3854
|
let ue = j.errors;
|
|
@@ -3881,16 +3880,16 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3881
3880
|
}, [re]), O(() => {
|
|
3882
3881
|
j.isSubmitted && R(!0);
|
|
3883
3882
|
}, [j]);
|
|
3884
|
-
const M = q(null), X = I !== void 0, Pe =
|
|
3885
|
-
return /* @__PURE__ */ o.jsx(o.Fragment, { children: /* @__PURE__ */ o.jsxs(n, { label: `${t}${l ? " *" : ""}`, hidden: c, withoutLabel:
|
|
3886
|
-
/* @__PURE__ */ o.jsxs(ur, { currentSelection: A, selectedItemNavigateTo:
|
|
3883
|
+
const M = q(null), X = I !== void 0, Pe = p !== void 0, dr = Pe && A !== null;
|
|
3884
|
+
return /* @__PURE__ */ o.jsx(o.Fragment, { children: /* @__PURE__ */ o.jsxs(n, { label: `${t}${l ? " *" : ""}`, hidden: c, withoutLabel: f, isInvalid: X, inputContainerClassName: w({ "luminus-dropdown-select-open": y }), className: N, children: [
|
|
3885
|
+
/* @__PURE__ */ o.jsxs(ur, { currentSelection: A, selectedItemNavigateTo: p, children: [
|
|
3887
3886
|
m && (A == null ? void 0 : A.name) && /* @__PURE__ */ o.jsx(G, { variant: "caption", className: "d-flex justify-content-end mt-2 luminus-dropdown-selection-name", children: A.name }),
|
|
3888
3887
|
/* @__PURE__ */ o.jsx(dn, { control: D, name: e, render: () => /* @__PURE__ */ o.jsx(Q.Select, { size: r, onMouseDown: (B) => {
|
|
3889
3888
|
B.currentTarget.focus(), B.preventDefault();
|
|
3890
3889
|
}, onClick: () => {
|
|
3891
3890
|
!Pe && !u && C(!0);
|
|
3892
3891
|
}, ref: M, value: H ?? "", onChange: () => {
|
|
3893
|
-
}, isInvalid: X, hidden: c, className:
|
|
3892
|
+
}, isInvalid: X, hidden: c, className: w("w-100", {
|
|
3894
3893
|
"luminus-dropdown-picker-disabled": u,
|
|
3895
3894
|
"luminus-dropdown-picker-link": dr
|
|
3896
3895
|
}), children: /* @__PURE__ */ o.jsx("option", { value: H, children: m ? H : (Z == null ? void 0 : Z.length) > 0 ? Z : H }) }) }),
|
|
@@ -3902,24 +3901,24 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3902
3901
|
] }) : null
|
|
3903
3902
|
] }),
|
|
3904
3903
|
I && /* @__PURE__ */ o.jsx(pe, { message: I.message }),
|
|
3905
|
-
M.current && /* @__PURE__ */ o.jsx(jt, { show: y, onCancel: E, items: d, currentSelection: A, onSelectionChange: U, onSearchQueryChange: h, texts: g, itemsNameWidth: b, additionalColumns: _, displayIdAsName: m, isLoading:
|
|
3904
|
+
M.current && /* @__PURE__ */ o.jsx(jt, { show: y, onCancel: E, items: d, currentSelection: A, onSelectionChange: U, onSearchQueryChange: h, texts: g, itemsNameWidth: b, additionalColumns: _, displayIdAsName: m, isLoading: x, disabled: u, inputRef: M })
|
|
3906
3905
|
] }) });
|
|
3907
|
-
}, Il = ({ InputContainer: n = fe, label: e, formField: t, hidden: r, required: s, placeholder: a, disabled: i, showClearIcon: l, resetsFields: c, multiple: u, accept: d, withoutLabel: h, className:
|
|
3908
|
-
const { watch: g, setValue: b, register:
|
|
3906
|
+
}, Il = ({ InputContainer: n = fe, label: e, formField: t, hidden: r, required: s, placeholder: a, disabled: i, showClearIcon: l, resetsFields: c, multiple: u, accept: d, withoutLabel: h, className: p }) => {
|
|
3907
|
+
const { watch: g, setValue: b, register: x, formState: f } = le(), [_, k] = P(!1), [m, N] = P(void 0), j = S(() => {
|
|
3909
3908
|
b(t, "");
|
|
3910
3909
|
}, [b, t]), v = S(() => {
|
|
3911
3910
|
const D = t.split(".");
|
|
3912
|
-
let I =
|
|
3911
|
+
let I = f.errors;
|
|
3913
3912
|
D.forEach((T) => {
|
|
3914
3913
|
I !== void 0 && (I = I[T]);
|
|
3915
3914
|
}), N(I);
|
|
3916
|
-
}, [
|
|
3915
|
+
}, [f, t]);
|
|
3917
3916
|
O(v, [v]), O(() => {
|
|
3918
|
-
|
|
3919
|
-
}, [
|
|
3917
|
+
f.isSubmitted && k(!0);
|
|
3918
|
+
}, [f]);
|
|
3920
3919
|
const $ = m !== void 0;
|
|
3921
|
-
return /* @__PURE__ */ o.jsxs(n, { label: `${e}${s ? "*" : ""}`, hidden: r, withoutLabel: h, isInvalid: $, className:
|
|
3922
|
-
/* @__PURE__ */ o.jsx(ln, { type: "file", multiple: u, accept: d.join(", "), placeholder: a ?? e, isInvalid: $, hidden: r, disabled: i, className: "w-100", ...
|
|
3920
|
+
return /* @__PURE__ */ o.jsxs(n, { label: `${e}${s ? "*" : ""}`, hidden: r, withoutLabel: h, isInvalid: $, className: p, children: [
|
|
3921
|
+
/* @__PURE__ */ o.jsx(ln, { type: "file", multiple: u, accept: d.join(", "), placeholder: a ?? e, isInvalid: $, hidden: r, disabled: i, className: "w-100", ...x(t, {
|
|
3923
3922
|
onChange: () => {
|
|
3924
3923
|
c && c.forEach((D) => b(D, null, { shouldDirty: !0, shouldValidate: _ }));
|
|
3925
3924
|
}
|
|
@@ -3932,29 +3931,29 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3932
3931
|
return O(() => {
|
|
3933
3932
|
s(Object.keys(t.dirtyFields).length > 0);
|
|
3934
3933
|
}, [t]), r ? /* @__PURE__ */ o.jsx(Ba, { onStorno: e, children: n }) : null;
|
|
3935
|
-
}, Sl = ({ InputContainer: n = fe, options: e, formField: t, label: r, size: s, resetsFields: a, isNumber: i, required: l, hidden: c, disabled: u, withoutLabel: d, noSortOptions: h, suffixIdToName:
|
|
3936
|
-
const { customSelectTexts: b } = Y(ae), { formState:
|
|
3934
|
+
}, Sl = ({ InputContainer: n = fe, options: e, formField: t, label: r, size: s, resetsFields: a, isNumber: i, required: l, hidden: c, disabled: u, withoutLabel: d, noSortOptions: h, suffixIdToName: p, className: g }) => {
|
|
3935
|
+
const { customSelectTexts: b } = Y(ae), { formState: x, setValue: f, watch: _, control: k } = le(), [m, N] = P(void 0), [j, v] = P(!1), [$, D] = P(!1), [I, T] = P(""), y = _(t), C = K(() => e.find((E) => E.id === y) ?? null, [e, y]), F = S(() => {
|
|
3937
3936
|
const E = t.split(".");
|
|
3938
|
-
let M =
|
|
3937
|
+
let M = x.errors;
|
|
3939
3938
|
E.forEach((X) => {
|
|
3940
3939
|
M !== void 0 && (M = M[X]);
|
|
3941
3940
|
}), N(M);
|
|
3942
|
-
}, [
|
|
3941
|
+
}, [x, t]), R = S((E) => {
|
|
3943
3942
|
if ((E == null ? void 0 : E.id) === y)
|
|
3944
3943
|
return;
|
|
3945
|
-
if (a && a.forEach((X) =>
|
|
3946
|
-
|
|
3944
|
+
if (a && a.forEach((X) => f(X, null, { shouldDirty: !0, shouldValidate: $ })), E === null) {
|
|
3945
|
+
f(t, null, {
|
|
3947
3946
|
shouldDirty: !0,
|
|
3948
3947
|
shouldValidate: $
|
|
3949
3948
|
});
|
|
3950
3949
|
return;
|
|
3951
3950
|
}
|
|
3952
3951
|
let M = null;
|
|
3953
|
-
i ? M = (E == null ? void 0 : E.id) !== null && (E == null ? void 0 : E.id) !== "" ? parseInt(E.id.toString(), 10) : null : M = E.id === null || E.id === void 0 || E.id === "" ? null : E.id,
|
|
3952
|
+
i ? M = (E == null ? void 0 : E.id) !== null && (E == null ? void 0 : E.id) !== "" ? parseInt(E.id.toString(), 10) : null : M = E.id === null || E.id === void 0 || E.id === "" ? null : E.id, f(t, M, {
|
|
3954
3953
|
shouldDirty: !0,
|
|
3955
3954
|
shouldValidate: $
|
|
3956
3955
|
});
|
|
3957
|
-
}, [
|
|
3956
|
+
}, [f, t, i, a, y, $]), H = S((E) => {
|
|
3958
3957
|
v(!1), R(E);
|
|
3959
3958
|
}, [R]), Z = S((E) => {
|
|
3960
3959
|
T(E);
|
|
@@ -3962,16 +3961,16 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3962
3961
|
O(() => {
|
|
3963
3962
|
F();
|
|
3964
3963
|
}, [F]), O(() => {
|
|
3965
|
-
|
|
3966
|
-
}, [
|
|
3964
|
+
x.isSubmitted && D(!0);
|
|
3965
|
+
}, [x]);
|
|
3967
3966
|
const A = S((E) => {
|
|
3968
3967
|
var M;
|
|
3969
|
-
return E === null ? "" : !E.name || E.name.length === 0 ? ((M = E.id) == null ? void 0 : M.toString()) ?? "" :
|
|
3970
|
-
}, [
|
|
3968
|
+
return E === null ? "" : !E.name || E.name.length === 0 ? ((M = E.id) == null ? void 0 : M.toString()) ?? "" : p ? `${E.name} (${E.id})` : E.name;
|
|
3969
|
+
}, [p]), re = K(() => e.map((E) => ({
|
|
3971
3970
|
id: E.id,
|
|
3972
3971
|
name: A(E)
|
|
3973
3972
|
})).filter((E) => rs(E.name, I)).sort((E, M) => h ? 0 : (E.name ?? "").localeCompare(M.name ?? "")), [e, h, I, A]), ee = q(null), U = m !== void 0;
|
|
3974
|
-
return /* @__PURE__ */ o.jsx(o.Fragment, { children: /* @__PURE__ */ o.jsxs(n, { label: `${r}${l ? " *" : ""}`, hidden: c, withoutLabel: d, isInvalid: U, inputContainerClassName:
|
|
3973
|
+
return /* @__PURE__ */ o.jsx(o.Fragment, { children: /* @__PURE__ */ o.jsxs(n, { label: `${r}${l ? " *" : ""}`, hidden: c, withoutLabel: d, isInvalid: U, inputContainerClassName: w({ "luminus-dropdown-select-open": j }), className: g, children: [
|
|
3975
3974
|
/* @__PURE__ */ o.jsx(dn, { control: k, name: t, render: () => /* @__PURE__ */ o.jsx(Q.Select, { size: s, onMouseDown: (E) => {
|
|
3976
3975
|
E.currentTarget.focus(), E.preventDefault();
|
|
3977
3976
|
}, onClick: () => {
|
|
@@ -3981,8 +3980,8 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3981
3980
|
m && /* @__PURE__ */ o.jsx(pe, { message: m.message }),
|
|
3982
3981
|
ee.current && /* @__PURE__ */ o.jsx(jt, { show: j, onCancel: () => v(!1), items: re, currentSelection: C ?? null, onSelectionChange: H, onSearchQueryChange: Z, texts: b, disabled: u, inputRef: ee, autoHideSearch: !0, allItemsLength: e.length })
|
|
3983
3982
|
] }) });
|
|
3984
|
-
}, Tl = ({ InputContainer: n = fe, formField: e, label: t, placeholder: r, size: s, resetsFields: a, showClearIcon: i, clearValue: l, required: c, hidden: u, disabled: d, withoutLabel: h, step:
|
|
3985
|
-
const { register:
|
|
3983
|
+
}, Tl = ({ InputContainer: n = fe, formField: e, label: t, placeholder: r, size: s, resetsFields: a, showClearIcon: i, clearValue: l, required: c, hidden: u, disabled: d, withoutLabel: h, step: p, stepperStep: g = 1, className: b }) => {
|
|
3984
|
+
const { register: x, formState: f, setValue: _, watch: k } = le(), [m, N] = P(void 0), [j, v] = P(!1), $ = S(() => {
|
|
3986
3985
|
const y = l ?? null;
|
|
3987
3986
|
_(e, y !== null ? Number(y) : null, {
|
|
3988
3987
|
shouldDirty: !0,
|
|
@@ -3990,25 +3989,25 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
3990
3989
|
});
|
|
3991
3990
|
}, [l, _, e, j]), D = S(() => {
|
|
3992
3991
|
const y = e.split(".");
|
|
3993
|
-
let C =
|
|
3992
|
+
let C = f.errors;
|
|
3994
3993
|
y.forEach((F) => {
|
|
3995
3994
|
C !== void 0 && (C = C[F]);
|
|
3996
3995
|
}), N(C);
|
|
3997
|
-
}, [
|
|
3996
|
+
}, [f, e]);
|
|
3998
3997
|
O(() => {
|
|
3999
3998
|
D();
|
|
4000
3999
|
}, [D]), O(() => {
|
|
4001
|
-
|
|
4002
|
-
}, [
|
|
4000
|
+
f.isSubmitted && v(!0);
|
|
4001
|
+
}, [f]);
|
|
4003
4002
|
const I = m !== void 0, T = k(e);
|
|
4004
4003
|
return /* @__PURE__ */ o.jsxs(n, { label: `${t}${c ? " *" : ""}`, hidden: u, withoutLabel: h, isInvalid: I, className: b, children: [
|
|
4005
4004
|
/* @__PURE__ */ o.jsxs("div", { className: "luminus-input-container position-relative w-100", children: [
|
|
4006
|
-
/* @__PURE__ */ o.jsx(Q.Control, { type: "number", placeholder: r ?? t, size: s, ...
|
|
4005
|
+
/* @__PURE__ */ o.jsx(Q.Control, { type: "number", placeholder: r ?? t, size: s, ...x(e, {
|
|
4007
4006
|
setValueAs: (y) => y == null || y === "" ? null : Number(y),
|
|
4008
4007
|
onChange: () => {
|
|
4009
4008
|
a && a.forEach((y) => _(y, null, { shouldDirty: !0, shouldValidate: j }));
|
|
4010
4009
|
}
|
|
4011
|
-
}), isInvalid: I, hidden: u, disabled: d, className: "w-100 luminus-numeric-stepper", step:
|
|
4010
|
+
}), isInvalid: I, hidden: u, disabled: d, className: "w-100 luminus-numeric-stepper", step: p }),
|
|
4012
4011
|
/* @__PURE__ */ o.jsx("div", { className: "stepper-icon left", children: !d && /* @__PURE__ */ o.jsx(z, { size: "sm", onClick: (y) => {
|
|
4013
4012
|
y.preventDefault(), y.stopPropagation(), _(e, ((T ? Number(T) : 0) - g).toString(), { shouldDirty: !0, shouldValidate: j });
|
|
4014
4013
|
}, children: /* @__PURE__ */ o.jsx(ar, {}) }) }),
|
|
@@ -4025,18 +4024,18 @@ const qi = "_item_1dy8x_1", cr = {
|
|
|
4025
4024
|
"full-height-no-overflow": "_full-height-no-overflow_d8l8q_5",
|
|
4026
4025
|
fullHeightNoOverflow: Bc,
|
|
4027
4026
|
disabled: Vc
|
|
4028
|
-
}, Dl = ({ eventKey: n, activeTab: e, fullHeightNoOverflow: t, disabled: r, className: s, children: a }) => n !== e ? null : /* @__PURE__ */ o.jsx("div", { className:
|
|
4027
|
+
}, Dl = ({ eventKey: n, activeTab: e, fullHeightNoOverflow: t, disabled: r, className: s, children: a }) => n !== e ? null : /* @__PURE__ */ o.jsx("div", { className: w("luminus-tab-panel", st.tabPanel, { [st.fullHeightNoOverflow]: t }, { disabled: r }, { [st.disabled]: r }, s), children: a }), Ol = ({ activeTab: n, onSelect: e, children: t }) => /* @__PURE__ */ o.jsx("div", { className: w("luminus-tabs d-flex gap-1 mb-2"), children: t.map((r) => {
|
|
4029
4028
|
const s = r.type, a = r.props;
|
|
4030
4029
|
if (!a)
|
|
4031
4030
|
return null;
|
|
4032
4031
|
const i = a.eventKey, l = a.children, c = a.className, u = a.onClick;
|
|
4033
|
-
return /* @__PURE__ */ Qr(s, { ...a, key: a.eventKey, className:
|
|
4032
|
+
return /* @__PURE__ */ Qr(s, { ...a, key: a.eventKey, className: w({ active: n === i }, c), onClick: () => {
|
|
4034
4033
|
e(i), u && u(i);
|
|
4035
4034
|
} }, l);
|
|
4036
4035
|
}) }), Gc = "_tab_1hdhk_1", zc = "_disabled_1hdhk_8", Qt = {
|
|
4037
4036
|
tab: Gc,
|
|
4038
4037
|
disabled: zc
|
|
4039
|
-
}, Pl = ({ eventKey: n, className: e, onClick: t, disabled: r, children: s }) => /* @__PURE__ */ o.jsx("div", { role: "button", className:
|
|
4038
|
+
}, Pl = ({ eventKey: n, className: e, onClick: t, disabled: r, children: s }) => /* @__PURE__ */ o.jsx("div", { role: "button", className: w("luminus-tab text-primary rounded", Qt.tab, e, {
|
|
4040
4039
|
disabled: r
|
|
4041
4040
|
}, { [Qt.disabled]: r }), onClick: () => t && !r && t(n), children: typeof s == "string" ? /* @__PURE__ */ o.jsx(G, { variant: "h6", className: "text-primary", children: s }) : s });
|
|
4042
4041
|
export {
|