react-luminus-components 1.3.135 → 1.3.137
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/README.md +349 -349
- package/dist/.vite/manifest.json +71 -71
- package/dist/{FullScreenContainer-BtUbOHHR.js → FullScreenContainer-Cc46PVe2.js} +1 -1
- package/dist/FullScreenContainer-QZL25nwN.cjs +1 -0
- package/dist/{Loading-BS_MQVUj.js → Loading-CA7u4kBy.js} +1 -1
- package/dist/Loading-CMt3VG4t.cjs +1 -0
- package/dist/SimpleTooltip--ds7sp_S.cjs +1 -0
- package/dist/{SimpleTooltip-Bo1bUDYT.js → SimpleTooltip-Bs5BLZ5t.js} +1 -1
- package/dist/components/Dropdown/Dropdown.d.ts +1 -1
- package/dist/components/common/ColumnResizer/ColumnResizer.d.ts +6 -0
- package/dist/components/common/DynamicForm/comps/DynamicFormTable/comps/TableColumnHead/TableColumnHead.d.ts +10 -0
- package/dist/components/common/DynamicForm/comps/DynamicFormTable/comps/index.d.ts +1 -0
- package/dist/components/common/index.d.ts +1 -0
- package/dist/contexts.cjs.js +1 -1
- package/dist/contexts.es.js +44 -44
- package/dist/hooks.cjs.js +1 -1
- package/dist/hooks.es.js +13 -13
- package/dist/layout.cjs.js +1 -1
- package/dist/layout.es.js +5 -5
- package/dist/main.cjs.js +2 -2
- package/dist/main.d.ts +1 -0
- package/dist/main.es.js +3241 -3216
- package/dist/models/types/dynamicForms/types/DynamicFormColumnDef.d.ts +0 -1
- package/dist/{ResponsiveContextDropdown-CpA-ddz3.cjs → nivo-bar.es-DBTZjPsB.cjs} +5 -5
- package/dist/{ResponsiveContextDropdown-CMGnzZXE.js → nivo-bar.es-Dum3I77T.js} +9963 -9964
- package/dist/{searchUtils-CKTOvaAv.js → searchUtils-B5DzQW59.js} +1 -1
- package/dist/searchUtils-NVr-jBP1.cjs +1 -0
- package/dist/style.css +1 -1
- package/dist/{useClipboard-CyEMs4Ro.js → useClipboard-BotlCgQ1.js} +1 -1
- package/dist/useClipboard-CMfba8aV.cjs +1 -0
- package/dist/useGetApiData-DP6fnE--.cjs +1 -0
- package/dist/{useGetApiData-DBqvsfTD.js → useGetApiData-DzpRmCDp.js} +6 -6
- package/dist/usePermissions-DAmFUO7q.cjs +1 -0
- package/dist/{usePermissions-CrpSQvbM.js → usePermissions-DLkjF3C2.js} +1 -1
- package/dist/utils.cjs.js +1 -1
- package/dist/utils.es.js +18 -18
- package/dist/variables.scss +165 -171
- package/package.json +116 -116
- package/dist/FullScreenContainer-C9CIob1-.cjs +0 -1
- package/dist/Loading-lqPUxoZo.cjs +0 -1
- package/dist/SimpleTooltip-oMF7ZO-a.cjs +0 -1
- package/dist/searchUtils-DjoM0pgn.cjs +0 -1
- package/dist/useClipboard-bBn2Cnmi.cjs +0 -1
- package/dist/useGetApiData-BfcsijhI.cjs +0 -1
- package/dist/usePermissions-h3eoc7k1.cjs +0 -1
package/dist/contexts.es.js
CHANGED
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
var be = Object.defineProperty;
|
|
2
2
|
var Se = (e, t, r) => t in e ? be(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r;
|
|
3
3
|
var b = (e, t, r) => Se(e, typeof t != "symbol" ? t + "" : t, r);
|
|
4
|
-
import { t as N, bf as Oe, j as f, bg as Ee, a2 as z,
|
|
4
|
+
import { t as N, bf as Oe, j as f, bg as Ee, a2 as z, ao as we, bh as ue, au as S, al as Ie, a3 as G, bi as je, as as Pe, aq as De, aQ as fe, bj as de, aR as ke, aS as D, ar as Le, bk as He, aE as se, bl as _e, bm as me, bn as oe, bb as $e, ap as Me } from "./nivo-bar.es-Dum3I77T.js";
|
|
5
5
|
import E, { useState as C, useCallback as p, useMemo as A, useContext as _, useEffect as P, useRef as pe, Component as te } from "react";
|
|
6
|
-
import { EventType as
|
|
6
|
+
import { EventType as Q } from "@azure/msal-browser";
|
|
7
7
|
import { MsalProvider as Re } from "@azure/msal-react";
|
|
8
8
|
import "react-router-dom";
|
|
9
9
|
import "react-hook-form";
|
|
10
10
|
import "react-flexmonster";
|
|
11
|
-
import { L as Ue } from "./Loading-
|
|
12
|
-
import { u as Ne } from "./useGetApiData-
|
|
11
|
+
import { L as Ue } from "./Loading-CA7u4kBy.js";
|
|
12
|
+
import { u as Ne } from "./useGetApiData-DzpRmCDp.js";
|
|
13
13
|
import { u as Fe } from "./useLocalStorageState-Bt99kkCr.js";
|
|
14
|
-
function
|
|
14
|
+
function qe(e) {
|
|
15
15
|
const t = N(e);
|
|
16
16
|
return t.setHours(23, 59, 59, 999), t;
|
|
17
17
|
}
|
|
18
|
-
function
|
|
19
|
-
return
|
|
18
|
+
function Ge() {
|
|
19
|
+
return qe(Date.now());
|
|
20
20
|
}
|
|
21
21
|
function ze(e, t) {
|
|
22
22
|
const r = +N(e), [n, s] = [
|
|
@@ -28,7 +28,7 @@ function ze(e, t) {
|
|
|
28
28
|
function Ke() {
|
|
29
29
|
return Oe(Date.now());
|
|
30
30
|
}
|
|
31
|
-
const
|
|
31
|
+
const Ve = ({ children: e }) => {
|
|
32
32
|
const [t, r] = C(!1), [n, s] = C(""), o = p((i) => {
|
|
33
33
|
r(!0), s(i);
|
|
34
34
|
}, []), c = p(() => {
|
|
@@ -38,7 +38,7 @@ const Be = ({ children: e }) => {
|
|
|
38
38
|
/* @__PURE__ */ f.jsx(At, {}),
|
|
39
39
|
e
|
|
40
40
|
] });
|
|
41
|
-
},
|
|
41
|
+
}, Be = () => {
|
|
42
42
|
const { texts: { confirm: e } } = _(z), { isShown: t, text: r, onFinish: n } = we(), { options: s } = _(ue), [o, c] = C(s.defaultValue ?? ""), a = p(() => {
|
|
43
43
|
n(null);
|
|
44
44
|
}, [n]), i = p((u) => {
|
|
@@ -62,8 +62,8 @@ const Be = ({ children: e }) => {
|
|
|
62
62
|
s.input === "input" ? /* @__PURE__ */ f.jsx(Ie, { ...l, type: s.type }) : void 0
|
|
63
63
|
] }),
|
|
64
64
|
/* @__PURE__ */ f.jsxs(S.Footer, { className: "w-100 d-flex gap-5", children: [
|
|
65
|
-
/* @__PURE__ */ f.jsx(
|
|
66
|
-
/* @__PURE__ */ f.jsx(
|
|
65
|
+
/* @__PURE__ */ f.jsx(G, { variant: "outlined", color: "secondary", onClick: a, className: "flex-grow-1", children: e.cancel }),
|
|
66
|
+
/* @__PURE__ */ f.jsx(G, { color: "primary", disabled: s.required && !o, type: "submit", className: "flex-grow-1", children: e.confirm })
|
|
67
67
|
] })
|
|
68
68
|
] })
|
|
69
69
|
] });
|
|
@@ -84,7 +84,7 @@ const Be = ({ children: e }) => {
|
|
|
84
84
|
}), [t, n, i, l, o]);
|
|
85
85
|
return /* @__PURE__ */ f.jsxs(ue.Provider, { value: u, children: [
|
|
86
86
|
e,
|
|
87
|
-
/* @__PURE__ */ f.jsx(
|
|
87
|
+
/* @__PURE__ */ f.jsx(Be, {})
|
|
88
88
|
] });
|
|
89
89
|
}, Ht = ({ cookieDomain: e, axiosOptions: t, language: r, texts: n, ProjectIconComponent: s, localizationContext: o, chartColorPalette: c, children: a }) => {
|
|
90
90
|
const i = A(() => ({
|
|
@@ -104,7 +104,7 @@ const Be = ({ children: e }) => {
|
|
|
104
104
|
n,
|
|
105
105
|
c
|
|
106
106
|
]);
|
|
107
|
-
return /* @__PURE__ */ f.jsx(z.Provider, { value: i, children: /* @__PURE__ */ f.jsx(
|
|
107
|
+
return /* @__PURE__ */ f.jsx(z.Provider, { value: i, children: /* @__PURE__ */ f.jsx(Ve, { children: /* @__PURE__ */ f.jsxs(Ye, { children: [
|
|
108
108
|
/* @__PURE__ */ f.jsx(je, {}),
|
|
109
109
|
a
|
|
110
110
|
] }) }) });
|
|
@@ -163,7 +163,7 @@ const Be = ({ children: e }) => {
|
|
|
163
163
|
P(() => {
|
|
164
164
|
if (r) {
|
|
165
165
|
const y = r.addEventCallback((v) => {
|
|
166
|
-
if (v.eventType ===
|
|
166
|
+
if (v.eventType === Q.LOGIN_SUCCESS && v.payload) {
|
|
167
167
|
const K = v.payload;
|
|
168
168
|
l(K.accessToken);
|
|
169
169
|
}
|
|
@@ -199,7 +199,7 @@ const Be = ({ children: e }) => {
|
|
|
199
199
|
return P(() => {
|
|
200
200
|
if (e.useMsal) {
|
|
201
201
|
const s = e.msalInstance.addEventCallback((o) => {
|
|
202
|
-
if (o.eventType ===
|
|
202
|
+
if (o.eventType === Q.LOGIN_SUCCESS || o.eventType === Q.ACQUIRE_TOKEN_SUCCESS && o.payload) {
|
|
203
203
|
const c = o.payload, a = c.account;
|
|
204
204
|
e.msalInstance.setActiveAccount(a);
|
|
205
205
|
const i = c.accessToken, l = c.expiresOn;
|
|
@@ -224,7 +224,7 @@ const Be = ({ children: e }) => {
|
|
|
224
224
|
const [r, n, s] = Fe("user-delegation", null), o = A(() => {
|
|
225
225
|
if (!r)
|
|
226
226
|
return null;
|
|
227
|
-
const d = r.from ? se(r.from) : Ke(), h = r.to ? se(r.to) :
|
|
227
|
+
const d = r.from ? se(r.from) : Ke(), h = r.to ? se(r.to) : Ge();
|
|
228
228
|
return ze(new Date(Date.now()), { start: d, end: h }) ? r : (n(null), null);
|
|
229
229
|
}, [r, n]), { data: c, setData: a, reloadData: i } = Ne(t, {
|
|
230
230
|
nullStateBeforeLoad: !1,
|
|
@@ -260,7 +260,7 @@ const Be = ({ children: e }) => {
|
|
|
260
260
|
]);
|
|
261
261
|
return /* @__PURE__ */ f.jsx(de.Provider, { value: u, children: e });
|
|
262
262
|
};
|
|
263
|
-
var
|
|
263
|
+
var Je = typeof Element < "u", Qe = typeof Map == "function", We = typeof Set == "function", Ze = typeof ArrayBuffer == "function" && !!ArrayBuffer.isView;
|
|
264
264
|
function F(e, t) {
|
|
265
265
|
if (e === t) return !0;
|
|
266
266
|
if (e && t && typeof e == "object" && typeof t == "object") {
|
|
@@ -273,7 +273,7 @@ function F(e, t) {
|
|
|
273
273
|
return !0;
|
|
274
274
|
}
|
|
275
275
|
var o;
|
|
276
|
-
if (
|
|
276
|
+
if (Qe && e instanceof Map && t instanceof Map) {
|
|
277
277
|
if (e.size !== t.size) return !1;
|
|
278
278
|
for (o = e.entries(); !(n = o.next()).done; )
|
|
279
279
|
if (!t.has(n.value[0])) return !1;
|
|
@@ -281,13 +281,13 @@ function F(e, t) {
|
|
|
281
281
|
if (!F(n.value[1], t.get(n.value[0]))) return !1;
|
|
282
282
|
return !0;
|
|
283
283
|
}
|
|
284
|
-
if (
|
|
284
|
+
if (We && e instanceof Set && t instanceof Set) {
|
|
285
285
|
if (e.size !== t.size) return !1;
|
|
286
286
|
for (o = e.entries(); !(n = o.next()).done; )
|
|
287
287
|
if (!t.has(n.value[0])) return !1;
|
|
288
288
|
return !0;
|
|
289
289
|
}
|
|
290
|
-
if (
|
|
290
|
+
if (Ze && ArrayBuffer.isView(e) && ArrayBuffer.isView(t)) {
|
|
291
291
|
if (r = e.length, r != t.length) return !1;
|
|
292
292
|
for (n = r; n-- !== 0; )
|
|
293
293
|
if (e[n] !== t[n]) return !1;
|
|
@@ -299,7 +299,7 @@ function F(e, t) {
|
|
|
299
299
|
if (s = Object.keys(e), r = s.length, r !== Object.keys(t).length) return !1;
|
|
300
300
|
for (n = r; n-- !== 0; )
|
|
301
301
|
if (!Object.prototype.hasOwnProperty.call(t, s[n])) return !1;
|
|
302
|
-
if (
|
|
302
|
+
if (Je && e instanceof Element) return !1;
|
|
303
303
|
for (n = r; n-- !== 0; )
|
|
304
304
|
if (!((s[n] === "_owner" || s[n] === "__v" || s[n] === "__o") && e.$$typeof) && !F(e[s[n]], t[s[n]]))
|
|
305
305
|
return !1;
|
|
@@ -339,7 +339,7 @@ var tt = function(t, r, n, s) {
|
|
|
339
339
|
return !0;
|
|
340
340
|
};
|
|
341
341
|
const rt = /* @__PURE__ */ me(tt);
|
|
342
|
-
var he = /* @__PURE__ */ ((e) => (e.BASE = "base", e.BODY = "body", e.HEAD = "head", e.HTML = "html", e.LINK = "link", e.META = "meta", e.NOSCRIPT = "noscript", e.SCRIPT = "script", e.STYLE = "style", e.TITLE = "title", e.FRAGMENT = "Symbol(react.fragment)", e))(he || {}),
|
|
342
|
+
var he = /* @__PURE__ */ ((e) => (e.BASE = "base", e.BODY = "body", e.HEAD = "head", e.HTML = "html", e.LINK = "link", e.META = "meta", e.NOSCRIPT = "noscript", e.SCRIPT = "script", e.STYLE = "style", e.TITLE = "title", e.FRAGMENT = "Symbol(react.fragment)", e))(he || {}), V = {
|
|
343
343
|
link: { rel: ["amphtml", "canonical", "alternate"] },
|
|
344
344
|
script: { type: ["application/ld+json"] },
|
|
345
345
|
meta: {
|
|
@@ -399,7 +399,7 @@ var he = /* @__PURE__ */ ((e) => (e.BASE = "base", e.BODY = "body", e.HEAD = "he
|
|
|
399
399
|
const n = H(e, L.DEFAULT_TITLE);
|
|
400
400
|
return t || n || void 0;
|
|
401
401
|
}, ot = (e) => H(e, L.ON_CHANGE_CLIENT_STATE) || (() => {
|
|
402
|
-
}),
|
|
402
|
+
}), B = (e, t) => t.filter((r) => typeof r[e] < "u").map((r) => r[e]).reduce((r, n) => ({ ...r, ...n }), {}), at = (e, t) => t.filter((r) => typeof r.base < "u").map((r) => r.base).reverse().reduce((r, n) => {
|
|
403
403
|
if (!r.length) {
|
|
404
404
|
const s = Object.keys(n);
|
|
405
405
|
for (let o = 0; o < s.length; o += 1) {
|
|
@@ -449,10 +449,10 @@ var he = /* @__PURE__ */ ((e) => (e.BASE = "base", e.BODY = "body", e.HEAD = "he
|
|
|
449
449
|
"href"
|
|
450
450
|
/* HREF */
|
|
451
451
|
], e),
|
|
452
|
-
bodyAttributes:
|
|
452
|
+
bodyAttributes: B("bodyAttributes", e),
|
|
453
453
|
defer: H(e, L.DEFER),
|
|
454
454
|
encode: H(e, L.ENCODE_SPECIAL_CHARACTERS),
|
|
455
|
-
htmlAttributes:
|
|
455
|
+
htmlAttributes: B("htmlAttributes", e),
|
|
456
456
|
linkTags: M(
|
|
457
457
|
"link",
|
|
458
458
|
[
|
|
@@ -493,7 +493,7 @@ var he = /* @__PURE__ */ ((e) => (e.BASE = "base", e.BODY = "body", e.HEAD = "he
|
|
|
493
493
|
/* CSS_TEXT */
|
|
494
494
|
], e),
|
|
495
495
|
title: st(e),
|
|
496
|
-
titleAttributes:
|
|
496
|
+
titleAttributes: B("titleAttributes", e),
|
|
497
497
|
prioritizeSeoTags: lt(e, L.PRIORITIZE_SEO_TAGS)
|
|
498
498
|
}), ye = (e) => Array.isArray(e) ? e.join("") : e, ut = (e, t) => {
|
|
499
499
|
const r = Object.keys(e);
|
|
@@ -512,15 +512,15 @@ var he = /* @__PURE__ */ ((e) => (e.BASE = "base", e.BODY = "body", e.HEAD = "he
|
|
|
512
512
|
"script",
|
|
513
513
|
"style"
|
|
514
514
|
/* STYLE */
|
|
515
|
-
],
|
|
515
|
+
], W = (e, t = !0) => t === !1 ? String(e) : String(e).replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """).replace(/'/g, "'"), ge = (e) => Object.keys(e).reduce((t, r) => {
|
|
516
516
|
const n = typeof e[r] < "u" ? `${r}="${e[r]}"` : `${r}`;
|
|
517
517
|
return t ? `${t} ${n}` : n;
|
|
518
518
|
}, ""), dt = (e, t, r, n) => {
|
|
519
519
|
const s = ge(r), o = ye(t);
|
|
520
|
-
return s ? `<${e} ${x}="true" ${s}>${
|
|
520
|
+
return s ? `<${e} ${x}="true" ${s}>${W(
|
|
521
521
|
o,
|
|
522
522
|
n
|
|
523
|
-
)}</${e}>` : `<${e} ${x}="true">${
|
|
523
|
+
)}</${e}>` : `<${e} ${x}="true">${W(
|
|
524
524
|
o,
|
|
525
525
|
n
|
|
526
526
|
)}</${e}>`;
|
|
@@ -528,7 +528,7 @@ var he = /* @__PURE__ */ ((e) => (e.BASE = "base", e.BODY = "body", e.HEAD = "he
|
|
|
528
528
|
const o = s, c = Object.keys(o).filter(
|
|
529
529
|
(l) => !(l === "innerHTML" || l === "cssText")
|
|
530
530
|
).reduce((l, u) => {
|
|
531
|
-
const d = typeof o[u] > "u" ? u : `${u}="${
|
|
531
|
+
const d = typeof o[u] > "u" ? u : `${u}="${W(o[u], r)}"`;
|
|
532
532
|
return l ? `${l} ${d}` : d;
|
|
533
533
|
}, ""), a = o.innerHTML || o.cssText || "", i = ft.indexOf(e) === -1;
|
|
534
534
|
return `${n}<${e} ${x}="true" ${c}${i ? "/>" : `>${a}</${e}>`}`;
|
|
@@ -541,7 +541,7 @@ var he = /* @__PURE__ */ ((e) => (e.BASE = "base", e.BODY = "body", e.HEAD = "he
|
|
|
541
541
|
[x]: !0
|
|
542
542
|
}, s = Te(r, n);
|
|
543
543
|
return [E.createElement("title", s, t)];
|
|
544
|
-
},
|
|
544
|
+
}, q = (e, t) => t.map((r, n) => {
|
|
545
545
|
const s = {
|
|
546
546
|
key: n,
|
|
547
547
|
[x]: !0
|
|
@@ -569,18 +569,18 @@ var he = /* @__PURE__ */ ((e) => (e.BASE = "base", e.BODY = "body", e.HEAD = "he
|
|
|
569
569
|
};
|
|
570
570
|
default:
|
|
571
571
|
return {
|
|
572
|
-
toComponent: () =>
|
|
572
|
+
toComponent: () => q(e, t),
|
|
573
573
|
toString: () => mt(e, t, r)
|
|
574
574
|
};
|
|
575
575
|
}
|
|
576
576
|
}, ht = ({ metaTags: e, linkTags: t, scriptTags: r, encode: n }) => {
|
|
577
|
-
const s = Y(e,
|
|
577
|
+
const s = Y(e, V.meta), o = Y(t, V.link), c = Y(r, V.script);
|
|
578
578
|
return {
|
|
579
579
|
priorityMethods: {
|
|
580
580
|
toComponent: () => [
|
|
581
|
-
...
|
|
582
|
-
...
|
|
583
|
-
...
|
|
581
|
+
...q("meta", s.priority),
|
|
582
|
+
...q("link", o.priority),
|
|
583
|
+
...q("script", c.priority)
|
|
584
584
|
],
|
|
585
585
|
toString: () => (
|
|
586
586
|
// generate all the tags as strings and concatenate them
|
|
@@ -624,7 +624,7 @@ var he = /* @__PURE__ */ ((e) => (e.BASE = "base", e.BODY = "body", e.HEAD = "he
|
|
|
624
624
|
style: T("style", c, n),
|
|
625
625
|
title: T("title", { title: a, titleAttributes: i }, n)
|
|
626
626
|
};
|
|
627
|
-
},
|
|
627
|
+
}, Z = yt, U = [], ve = !!(typeof window < "u" && window.document && window.document.createElement), X = class {
|
|
628
628
|
constructor(e, t) {
|
|
629
629
|
b(this, "instances", []);
|
|
630
630
|
b(this, "canUseDOM", ve);
|
|
@@ -644,7 +644,7 @@ var he = /* @__PURE__ */ ((e) => (e.BASE = "base", e.BODY = "body", e.HEAD = "he
|
|
|
644
644
|
}
|
|
645
645
|
}
|
|
646
646
|
});
|
|
647
|
-
this.context = e, this.canUseDOM = t || !1, t || (e.helmet =
|
|
647
|
+
this.context = e, this.canUseDOM = t || !1, t || (e.helmet = Z({
|
|
648
648
|
baseTag: [],
|
|
649
649
|
bodyAttributes: {},
|
|
650
650
|
encodeSpecialCharacters: !0,
|
|
@@ -766,7 +766,7 @@ var he = /* @__PURE__ */ ((e) => (e.BASE = "base", e.BODY = "body", e.HEAD = "he
|
|
|
766
766
|
return delete c.context, c;
|
|
767
767
|
})
|
|
768
768
|
);
|
|
769
|
-
Ce.canUseDOM ? xt(s) :
|
|
769
|
+
Ce.canUseDOM ? xt(s) : Z && (n = Z(s)), r(n);
|
|
770
770
|
}
|
|
771
771
|
// componentWillMount will be deprecated
|
|
772
772
|
// for SSR, initialize on first render
|
|
@@ -781,7 +781,7 @@ var he = /* @__PURE__ */ ((e) => (e.BASE = "base", e.BODY = "body", e.HEAD = "he
|
|
|
781
781
|
render() {
|
|
782
782
|
return this.init(), null;
|
|
783
783
|
}
|
|
784
|
-
},
|
|
784
|
+
}, J, Ct = (J = class extends te {
|
|
785
785
|
shouldComponentUpdate(e) {
|
|
786
786
|
return !et(ie(this.props, "helmetData"), ie(e, "helmetData"));
|
|
787
787
|
}
|
|
@@ -899,11 +899,11 @@ var he = /* @__PURE__ */ ((e) => (e.BASE = "base", e.BODY = "body", e.HEAD = "he
|
|
|
899
899
|
}
|
|
900
900
|
return n ? /* @__PURE__ */ E.createElement(ce, { ...r, context: n.value }) : /* @__PURE__ */ E.createElement(xe.Consumer, null, (s) => /* @__PURE__ */ E.createElement(ce, { ...r, context: s }));
|
|
901
901
|
}
|
|
902
|
-
}, b(
|
|
902
|
+
}, b(J, "defaultProps", {
|
|
903
903
|
defer: !0,
|
|
904
904
|
encodeSpecialCharacters: !0,
|
|
905
905
|
prioritizeSeoTags: !1
|
|
906
|
-
}),
|
|
906
|
+
}), J);
|
|
907
907
|
const Ut = ({ defaultHelmet: e, children: t }) => {
|
|
908
908
|
const [r, n] = C([e]), s = p((i) => {
|
|
909
909
|
n((l) => [...l, i]);
|
|
@@ -919,8 +919,8 @@ const Ut = ({ defaultHelmet: e, children: t }) => {
|
|
|
919
919
|
return /* @__PURE__ */ f.jsxs(S, { show: s, size: "sm", centered: !0, onHide: r, children: [
|
|
920
920
|
/* @__PURE__ */ f.jsx(S.Header, { className: "justify-content-center", children: /* @__PURE__ */ f.jsx(S.Title, { children: n }) }),
|
|
921
921
|
/* @__PURE__ */ f.jsx(S.Body, { children: /* @__PURE__ */ f.jsxs("div", { className: "w-100 d-flex gap-5", children: [
|
|
922
|
-
/* @__PURE__ */ f.jsx(
|
|
923
|
-
/* @__PURE__ */ f.jsx(
|
|
922
|
+
/* @__PURE__ */ f.jsx(G, { type: "button", variant: "outlined", color: "secondary", className: "w-100", onClick: r, children: e.no }),
|
|
923
|
+
/* @__PURE__ */ f.jsx(G, { type: "button", color: "primary", onClick: t, className: "w-100 ml", children: e.yes })
|
|
924
924
|
] }) })
|
|
925
925
|
] });
|
|
926
926
|
};
|
package/dist/hooks.cjs.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const u=require("./
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const u=require("./nivo-bar.es-DBTZjPsB.cjs"),b=require("./useClickOutside-D0505nsm.cjs"),T=require("./usePermissions-DAmFUO7q.cjs"),d=require("./useClipboard-CMfba8aV.cjs"),x=require("./useGetApiData-DP6fnE--.cjs"),c=require("react"),B=require("./useLocalStorageState-BFc8Gc8H.cjs");require("react-router-dom");require("react-hook-form");require("react-flexmonster");require("@azure/msal-browser");require("@azure/msal-react");const G=r=>{let e="pending",a;const t=r.then(s=>{e="success",a=s},s=>{e="error",a=s});return()=>{switch(e){case"pending":throw t;case"success":return a;case"error":throw a;default:throw new Error("Unknown status")}}};function L(r,e){const a=u.useAxios({silent:!0,differentBaseUrl:e==null?void 0:e.customBaseUrl,customToken:e==null?void 0:e.customToken}),[t,s]=c.useState(null);return c.useEffect(()=>{(async()=>{const n=a.get(r).then(o=>o.data);s(G(n))})()},[a,r]),t}const O=(r,e,a)=>{let t="pending",s;const l=r.then(n=>{t="success",s=n},n=>{const o=n==null?void 0:n.response;(o==null?void 0:o.status)===404&&a?(t="error-404",s=n):(t="error",s=n)});return()=>{switch(t){case"pending":throw l;case"success":return s;case"error":return null;case"error-404":throw new Error("404");default:throw new Error("Unknown status")}}},i={loadOnInit:!0,silent:!1,enabled:!0,nullStateBeforeLoad:!0,nullStateOnFail:!1},E=(r,{loadOnInit:e=i.loadOnInit,enabled:a=i.enabled,silent:t=i.silent,nullStateBeforeLoad:s=i.nullStateBeforeLoad,nullStateOnFail:l=i.nullStateOnFail,customApiUrl:n,customBearerToken:o,dataTransformer:h,errorBoundaryOn404:m}=i)=>{const g=u.useAxios({silent:t,customToken:o,differentBaseUrl:n,noToastOnStatus:m?[404]:void 0}),{startLoading:D,stopLoading:C}=c.useContext(u.LoadingContext),q=c.useRef(0),{isAuthenticated:w}=u.useAuth(),[P,S]=c.useState(null),p=c.useCallback(async(f,y)=>{if(!w()||a===!1)return;!t&&D(`loadData-${r}-${y}`),s&&S(null);const k=g.get(r,{signal:f}).then(A=>h?h(A.data):A.data).finally(()=>!t&&C(`loadData-${r}-${y}`));S(O(k,l??!1,m??!1))},[w,a,t,D,r,s,g,h,C,l,m]);return c.useEffect(()=>{if(e===!1)return;const f=new AbortController;return p(f.signal,++q.current),()=>{f.abort()}},[p,e]),{data:P,setData:S,reloadData:p}};exports.cancelToken=u.cancelToken;exports.useAuth=u.useAuth;exports.useAxios=u.useAxios;exports.useConfirm=u.useConfirm;exports.useFormControlType=u.useFormControlType;exports.useNotifications=u.useNotifications;exports.usePrompt=u.usePrompt;exports.useZodSchemaTypes=u.useZodSchemaTypes;exports.useClickOutside=b.useClickOutside;exports.usePermissions=T.usePermissions;exports.useClipboard=d.useClipboard;exports.useEmployeePhotoPath=d.useEmployeePhotoPath;exports.useKeyPress=d.useKeyPress;exports.useSearchQuery=d.useSearchQuery;exports.useSearchQueryState=d.useSearchQueryState;exports.useGetApiData=x.useGetApiData;exports.useLocalStorageState=B.useLocalStorageState;exports.useGetApiDataBound=E;exports.useGetDataBound=L;
|
package/dist/hooks.es.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { bo as
|
|
3
|
-
import { u as
|
|
4
|
-
import { u as tt } from "./usePermissions-
|
|
5
|
-
import { u as st, d as at, a as ot, b as rt, c as nt } from "./useClipboard-
|
|
6
|
-
import { u as ct } from "./useGetApiData-
|
|
1
|
+
import { aq as S, as as L, aR as P } from "./nivo-bar.es-Dum3I77T.js";
|
|
2
|
+
import { bo as j, ap as z, ae as H, at as J, ao as M, bp as V } from "./nivo-bar.es-Dum3I77T.js";
|
|
3
|
+
import { u as Y } from "./useClickOutside-BmlXg38T.js";
|
|
4
|
+
import { u as tt } from "./usePermissions-DLkjF3C2.js";
|
|
5
|
+
import { u as st, d as at, a as ot, b as rt, c as nt } from "./useClipboard-BotlCgQ1.js";
|
|
6
|
+
import { u as ct } from "./useGetApiData-DzpRmCDp.js";
|
|
7
7
|
import { useState as b, useEffect as C, useContext as T, useRef as U, useCallback as $ } from "react";
|
|
8
8
|
import { u as it } from "./useLocalStorageState-Bt99kkCr.js";
|
|
9
9
|
import "react-router-dom";
|
|
@@ -109,23 +109,23 @@ const E = (o, t, a) => {
|
|
|
109
109
|
}, [m, t]), { data: y, setData: d, reloadData: m };
|
|
110
110
|
};
|
|
111
111
|
export {
|
|
112
|
-
|
|
112
|
+
j as cancelToken,
|
|
113
113
|
P as useAuth,
|
|
114
114
|
S as useAxios,
|
|
115
|
-
|
|
115
|
+
Y as useClickOutside,
|
|
116
116
|
st as useClipboard,
|
|
117
|
-
|
|
117
|
+
z as useConfirm,
|
|
118
118
|
at as useEmployeePhotoPath,
|
|
119
|
-
|
|
119
|
+
H as useFormControlType,
|
|
120
120
|
ct as useGetApiData,
|
|
121
121
|
K as useGetApiDataBound,
|
|
122
122
|
I as useGetDataBound,
|
|
123
123
|
ot as useKeyPress,
|
|
124
124
|
it as useLocalStorageState,
|
|
125
|
-
|
|
125
|
+
J as useNotifications,
|
|
126
126
|
tt as usePermissions,
|
|
127
|
-
|
|
127
|
+
M as usePrompt,
|
|
128
128
|
rt as useSearchQuery,
|
|
129
129
|
nt as useSearchQueryState,
|
|
130
|
-
|
|
130
|
+
V as useZodSchemaTypes
|
|
131
131
|
};
|
package/dist/layout.cjs.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./nivo-bar.es-DBTZjPsB.cjs"),d=require("react"),q=require("react-router-dom");require("react-hook-form");require("react-flexmonster");const C=require("./SimpleTooltip--ds7sp_S.cjs");require("@azure/msal-browser");require("@azure/msal-react");const y=require("./useClickOutside-D0505nsm.cjs"),g=require("./usePermissions-DAmFUO7q.cjs"),k=require("./FullScreenContainer-QZL25nwN.cjs"),B="_side-menu-item_ql22m_1",P="_disabled_ql22m_6",f="_nav-button_ql22m_10",I="_child_ql22m_18",S="_text_ql22m_23",w="_icon_ql22m_30",T="_collapse-icon_ql22m_36",L="_collapsed_ql22m_46",O="_collapse-icon-mini_ql22m_49",F="_expanded_ql22m_80",$="_children-container_ql22m_86",A="_visible_ql22m_94",K="_children_ql22m_86",o={"side-menu-item":"_side-menu-item_ql22m_1",sideMenuItem:B,disabled:P,"nav-button":"_nav-button_ql22m_10",navButton:f,child:I,text:S,icon:w,"collapse-icon":"_collapse-icon_ql22m_36",collapseIcon:T,collapsed:L,"collapse-icon-mini":"_collapse-icon-mini_ql22m_49",collapseIconMini:O,expanded:F,"children-container":"_children-container_ql22m_86",childrenContainer:$,visible:A,children:K},D=({item:s,menuExpanded:l,useTooltips:r,children:t})=>s.tooltip&&!l&&r?e.jsxRuntimeExports.jsx(C.SimpleTooltip,{text:s.tooltip,placement:"top",delay:{show:1e3,hide:0},children:e.jsxRuntimeExports.jsx("div",{children:t})}):t,E=({item:s,menuExpanded:l,collapsed:r,onCollapse:t,currentPath:u,useHover:_,useTooltips:a})=>{var N,h,R,i;const[m,c]=d.useState(!1),[p]=u.split("?"),x=s.linkTo===p||((N=s.children)==null?void 0:N.some(n=>n.linkTo===p)),v=d.useRef(null);return y.useClickOutside([v],()=>r&&t()),e.jsxRuntimeExports.jsxs("li",{ref:v,className:e.classNames("luminus-side-menu-item",o.sideMenuItem,{[o.expanded]:l},{active:m||x},{open:r&&s.children},{[o.disabled]:s.disabled||s.notPermitted||((h=s.children)==null?void 0:h.every(n=>n.notPermitted||n.disabled))},{disabled:s.disabled||s.notPermitted||((R=s.children)==null?void 0:R.every(n=>n.notPermitted||n.disabled))}),onMouseEnter:()=>c(!0),onMouseLeave:()=>c(!1),children:[e.jsxRuntimeExports.jsx(D,{item:s,menuExpanded:l,useTooltips:a,children:s.children?e.jsxRuntimeExports.jsx(e.jsxRuntimeExports.Fragment,{children:e.jsxRuntimeExports.jsxs("button",{type:"button",className:e.classNames("nav-link",o.navButton),onClick:()=>{t()},children:[e.jsxRuntimeExports.jsx("div",{className:e.classNames("icon",o.icon),children:s.icon}),!_&&!l&&e.jsxRuntimeExports.jsx("div",{className:e.classNames("collapse-icon-mini rounded",o.collapseIconMini,{[o.collapsed]:r}),children:e.jsxRuntimeExports.jsx(e.MdOutlineKeyboardArrowRight,{})}),l&&e.jsxRuntimeExports.jsx("div",{className:e.classNames("text",o.text,"text-nowrap"),children:s.title}),l&&e.jsxRuntimeExports.jsx("div",{className:e.classNames("collapse-icon",o.collapseIcon,{[o.collapsed]:r}),children:e.jsxRuntimeExports.jsx(e.MdOutlineKeyboardArrowRight,{})})]})}):e.jsxRuntimeExports.jsxs(q.Link,{to:s.disabled||s.notPermitted?"/":s.linkTo??"/",className:e.classNames("nav-link",o.navButton),children:[e.jsxRuntimeExports.jsx("div",{className:e.classNames("icon",o.icon),children:s.icon}),l&&e.jsxRuntimeExports.jsx("div",{className:e.classNames("text",o.text,"text-nowrap"),children:s.title})]})}),e.jsxRuntimeExports.jsx("div",{className:e.classNames("children-container",o.childrenContainer,{[o.visible]:r}),children:e.jsxRuntimeExports.jsx("div",{className:e.classNames("shadow rounded children",o.children),children:(i=s.children)==null?void 0:i.map(n=>e.jsxRuntimeExports.jsx(q.Link,{to:n.disabled||n.notPermitted?"/":n.linkTo??"/",className:e.classNames("nav-link child rounded",o.navButton,o.child,{[o.disabled]:n.disabled||n.notPermitted},{disabled:n.disabled||n.notPermitted}),onClick:t,children:e.jsxRuntimeExports.jsx("div",{className:e.classNames("text",o.text,"text-nowrap"),children:n.title})},n.linkTo))})})]})},H="_side-menu_1deqc_1",U="_sidebar-header_1deqc_13",z="_side-menu-content_1deqc_20",G="_expand_1deqc_24",J="_only-logo_1deqc_28",Q="_divider_1deqc_31",b={"side-menu":"_side-menu_1deqc_1",sideMenu:H,"sidebar-header":"_sidebar-header_1deqc_13",sidebarHeader:U,"side-menu-content":"_side-menu-content_1deqc_20",sideMenuContent:z,expand:G,"only-logo":"_only-logo_1deqc_28",onlyLogo:J,divider:Q},V=({headerItem:s,mainItems:l,secondaryItems:r,expanded:t,setExpanded:u,currentPath:_,useHover:a,useTooltips:m})=>{const[c,p]=d.useState(-1),{checkUserHasPermissions:x}=g.usePermissions(),v=d.useMemo(()=>l.map(i=>{var n;return{...i,notPermitted:!x(i.permissions??[],"any"),children:(n=i.children)==null?void 0:n.map(j=>({...j,notPermitted:!x(j.permissions??[],"any"),disabled:i.disabled||j.disabled}))}}),[l,x]),N=d.useMemo(()=>r.map(i=>{var n;return{...i,notPermitted:!x(i.permissions??[],"any"),children:(n=i.children)==null?void 0:n.map(j=>({...j,notPermitted:!x(j.permissions??[],"any")}))}}),[r,x]),h=i=>{p(i===c?-1:i)};d.useEffect(()=>{t||p(-1)},[t]);const R=d.useRef(null);return y.useClickOutside([R],()=>u(!1)),e.jsxRuntimeExports.jsxs("section",{ref:R,className:e.classNames("luminus-side-menu shadow",b.sideMenu,{[b.expand]:t},{expand:t}),onMouseEnter:()=>a&&u(!0),onMouseLeave:()=>a&&u(!1),children:[e.jsxRuntimeExports.jsx("div",{className:e.classNames("sidebar-header",b.sidebarHeader,{[b.onlyLogo]:a}),role:a?void 0:"button",onClick:a?void 0:()=>u(!t),children:a?s:t?e.jsxRuntimeExports.jsxs(e.jsxRuntimeExports.Fragment,{children:[e.jsxRuntimeExports.jsx(e.MdOutlineKeyboardDoubleArrowLeft,{}),s]}):e.jsxRuntimeExports.jsx(e.MdOutlineMenu,{})}),e.jsxRuntimeExports.jsxs("ul",{className:b.sideMenuContent,children:[v.map((i,n)=>e.jsxRuntimeExports.jsx(E,{item:i,menuExpanded:t,collapsed:n===c,onCollapse:()=>h(n),currentPath:_,useHover:a,useTooltips:m},i.title)),e.jsxRuntimeExports.jsx("hr",{className:e.classNames("divider",b.divider)}),N.map((i,n)=>e.jsxRuntimeExports.jsx(E,{item:i,menuExpanded:t,collapsed:n===c,onCollapse:()=>h(n),currentPath:_,useHover:a,useTooltips:m},i.title))]})]})},X="_top-bar_1lk80_1",Y="_top-bar-brand_1lk80_14",M={"top-bar":"_top-bar_1lk80_1",topBar:X,"top-bar-brand":"_top-bar-brand_1lk80_14",topBarBrand:Y},Z=({appName:s,leftOffset:l,centerContent:r,rightContent:t})=>e.jsxRuntimeExports.jsxs("nav",{className:e.classNames("luminus-top-bar shadow",M.topBar),style:{width:l?`calc(100% - ${l}px)`:void 0,left:l?`${l}px`:void 0},children:[e.jsxRuntimeExports.jsx(q.Link,{to:"/",className:e.classNames("luminus-top-bar-brand",M.topBarBrand),children:s}),r&&e.jsxRuntimeExports.jsx("div",{children:r}),e.jsxRuntimeExports.jsx("div",{className:"d-flex justify-content-end align-items-center gap-2",children:t??null})]}),W=({title:s,children:l,sideContent:r,sideContentWidth:t=250,noPadding:u,className:_,helmet:a})=>{const{addHelmet:m,removeHelmet:c}=d.useContext(e.HelmetContext);return d.useEffect(()=>(a?m(a):typeof s=="string"&&s&&m(s),()=>c()),[a,m,c,s]),e.jsxRuntimeExports.jsxs("div",{className:e.classNames("container-fluid",u?"p-0":"p-3",_),children:[e.jsxRuntimeExports.jsxs("div",{style:{paddingRight:r?`${t}px`:void 0},children:[s?e.jsxRuntimeExports.jsx(e.PageTitle,{title:s}):null,l]}),r&&e.jsxRuntimeExports.jsx(e.SideContentBar,{width:t,children:r})]})};exports.PageContainer=e.PageContainer;exports.SideContentBar=e.SideContentBar;exports.FullScreenContainer=k.FullScreenContainer;exports.MainContainer=W;exports.SideMenu=V;exports.TopBar=Z;
|
package/dist/layout.es.js
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { j as e, c as t, ac as f, b9 as w, ba as S, bb as L, bc as T, bd as R } from "./
|
|
2
|
-
import { be as Ne } from "./
|
|
1
|
+
import { j as e, c as t, ac as f, b9 as w, ba as S, bb as L, bc as T, bd as R } from "./nivo-bar.es-Dum3I77T.js";
|
|
2
|
+
import { be as Ne } from "./nivo-bar.es-Dum3I77T.js";
|
|
3
3
|
import { useState as B, useRef as I, useMemo as y, useEffect as C, useContext as $ } from "react";
|
|
4
4
|
import { Link as N } from "react-router-dom";
|
|
5
5
|
import "react-hook-form";
|
|
6
6
|
import "react-flexmonster";
|
|
7
|
-
import { S as F } from "./SimpleTooltip-
|
|
7
|
+
import { S as F } from "./SimpleTooltip-Bs5BLZ5t.js";
|
|
8
8
|
import "@azure/msal-browser";
|
|
9
9
|
import "@azure/msal-react";
|
|
10
10
|
import { u as P } from "./useClickOutside-BmlXg38T.js";
|
|
11
|
-
import { u as A } from "./usePermissions-
|
|
12
|
-
import { F as ye } from "./FullScreenContainer-
|
|
11
|
+
import { u as A } from "./usePermissions-DLkjF3C2.js";
|
|
12
|
+
import { F as ye } from "./FullScreenContainer-Cc46PVe2.js";
|
|
13
13
|
const H = "_side-menu-item_ql22m_1", K = "_disabled_ql22m_6", O = "_nav-button_ql22m_10", D = "_child_ql22m_18", U = "_text_ql22m_23", z = "_icon_ql22m_30", E = "_collapse-icon_ql22m_36", G = "_collapsed_ql22m_46", J = "_collapse-icon-mini_ql22m_49", Q = "_expanded_ql22m_80", V = "_children-container_ql22m_86", X = "_visible_ql22m_94", Y = "_children_ql22m_86", l = {
|
|
14
14
|
"side-menu-item": "_side-menu-item_ql22m_1",
|
|
15
15
|
sideMenuItem: H,
|