react-ecosistema-unp 1.7.9 → 1.7.11
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 +61 -61
- package/dist/assets/EcoModalStyles.css +1 -1
- package/dist/lib/assets/animations/noData.json.d.ts +5866 -5866
- package/dist/lib/assets/animations/noInfo.json.d.ts +2981 -2981
- package/dist/lib/tables/tabla-registros/TablaRegistros.d.ts +2 -0
- package/dist/lib/tables/tabla-registros/modal-v2/EcoModal.d.ts +1 -0
- package/dist/shared/menu-lateral/MenuLateral.js +9 -9
- package/dist/tables/tabla-registros/TablaRegistros.js +1 -1
- package/dist/tables/tabla-registros/modal-v2/EcoModal.js +27 -26
- package/dist/ui/logo/Logo.js +6 -6
- package/package.json +113 -113
|
@@ -6,6 +6,8 @@ interface Column {
|
|
|
6
6
|
truncateText?: boolean;
|
|
7
7
|
sorter?: boolean;
|
|
8
8
|
renderComponent?: (row: Record<string, any>) => React.ReactNode;
|
|
9
|
+
redirectTo?: (row: Record<string, any>) => string;
|
|
10
|
+
state?: Record<string, any>;
|
|
9
11
|
}
|
|
10
12
|
interface TableProps {
|
|
11
13
|
title?: string;
|
|
@@ -270,15 +270,15 @@ const z1 = ({ onToggle: t, isOpen: c, showConnectionStatus: x }) => {
|
|
|
270
270
|
{
|
|
271
271
|
className: "gear__path",
|
|
272
272
|
fill: "none",
|
|
273
|
-
d: `M12 15.5a3.5 3.5 0 1 0 0-7 3.5 3.5 0 0 0 0 7z
|
|
274
|
-
M19.4 15a1.65 1.65 0 0 0 .33 1.82l.06.06a2 2 0 1 1-2.83 2.83l-.06-.06a1.65
|
|
275
|
-
1.65 0 0 0-1.82-.33 1.65 1.65 0 0 0-1 1.51V21a2 2 0 1 1-4 0v-.09a1.65 1.65
|
|
276
|
-
0 0 0-1-1.51 1.65 1.65 0 0 0-1.82.33l-.06.06a2 2 0 1 1-2.83-2.83l.06-.06a1.65
|
|
277
|
-
1.65 0 0 0 .33-1.82 1.65 1.65 0 0 0-1.51-1H3a2 2 0 1 1 0-4h.09a1.65 1.65 0 0 0
|
|
278
|
-
1.51-1 1.65 1.65 0 0 0-.33-1.82l-.06-.06a2 2 0 1 1 2.83-2.83l.06.06a1.65 1.65
|
|
279
|
-
0 0 0 1.82.33h.09a1.65 1.65 0 0 0 1-1.51V3a2 2 0 1 1 4 0v.09a1.65 1.65 0 0 0
|
|
280
|
-
1 1.51 1.65 1.65 0 0 0 1.82-.33l.06-.06a2 2 0 1 1 2.83 2.83l-.06.06a1.65 1.65
|
|
281
|
-
0 0 0-.33 1.82v.09a1.65 1.65 0 0 0 1.51 1H21a2 2 0 1 1 0 4h-.09a1.65 1.65 0 0
|
|
273
|
+
d: `M12 15.5a3.5 3.5 0 1 0 0-7 3.5 3.5 0 0 0 0 7z
|
|
274
|
+
M19.4 15a1.65 1.65 0 0 0 .33 1.82l.06.06a2 2 0 1 1-2.83 2.83l-.06-.06a1.65
|
|
275
|
+
1.65 0 0 0-1.82-.33 1.65 1.65 0 0 0-1 1.51V21a2 2 0 1 1-4 0v-.09a1.65 1.65
|
|
276
|
+
0 0 0-1-1.51 1.65 1.65 0 0 0-1.82.33l-.06.06a2 2 0 1 1-2.83-2.83l.06-.06a1.65
|
|
277
|
+
1.65 0 0 0 .33-1.82 1.65 1.65 0 0 0-1.51-1H3a2 2 0 1 1 0-4h.09a1.65 1.65 0 0 0
|
|
278
|
+
1.51-1 1.65 1.65 0 0 0-.33-1.82l-.06-.06a2 2 0 1 1 2.83-2.83l.06.06a1.65 1.65
|
|
279
|
+
0 0 0 1.82.33h.09a1.65 1.65 0 0 0 1-1.51V3a2 2 0 1 1 4 0v.09a1.65 1.65 0 0 0
|
|
280
|
+
1 1.51 1.65 1.65 0 0 0 1.82-.33l.06-.06a2 2 0 1 1 2.83 2.83l-.06.06a1.65 1.65
|
|
281
|
+
0 0 0-.33 1.82v.09a1.65 1.65 0 0 0 1.51 1H21a2 2 0 1 1 0 4h-.09a1.65 1.65 0 0
|
|
282
282
|
0-1.51 1z`
|
|
283
283
|
}
|
|
284
284
|
)
|
|
@@ -1648,7 +1648,7 @@ const pi = () => (/* @__PURE__ */ new Date()).getFullYear(), ct = (e) => e.norma
|
|
|
1648
1648
|
), ae = Ke ? pn : bn, yn = (p, b) => {
|
|
1649
1649
|
if (p.redirectTo) {
|
|
1650
1650
|
const J = p.redirectTo(b);
|
|
1651
|
-
hn(J);
|
|
1651
|
+
hn(J, { state: p.state });
|
|
1652
1652
|
return;
|
|
1653
1653
|
}
|
|
1654
1654
|
p.hasModal ? b.estadoRegistro === "por_gestionar" && T && o ? be.fire({
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { jsx as t, jsxs as i } from "react/jsx-runtime";
|
|
2
|
-
import { useState as m, useRef as
|
|
3
|
-
import { R as
|
|
4
|
-
import { q as
|
|
2
|
+
import { useState as m, useRef as I, useEffect as u } from "react";
|
|
3
|
+
import { R as M } from "../../../index-BrykDZgK.js";
|
|
4
|
+
import { q as A, r as B } from "../../../index-069JzHFQ.js";
|
|
5
5
|
import '../../../assets/EcoModalStyles.css';/* empty css */
|
|
6
|
-
const
|
|
6
|
+
const X = ({
|
|
7
7
|
show: r,
|
|
8
8
|
onHide: f,
|
|
9
9
|
title: N,
|
|
@@ -16,18 +16,19 @@ const V = ({
|
|
|
16
16
|
primaryPosition: s = "right",
|
|
17
17
|
disableClose: h = !1,
|
|
18
18
|
hasSecondaryModalOpen: R = !1,
|
|
19
|
-
otherModalOpen:
|
|
19
|
+
otherModalOpen: n = !1,
|
|
20
20
|
widthPercent: y,
|
|
21
21
|
headerBgColor: j = "#303D50",
|
|
22
|
-
hasBody: D = !0
|
|
22
|
+
hasBody: D = !0,
|
|
23
|
+
showOverlay: $ = !0
|
|
23
24
|
}) => {
|
|
24
|
-
const [b, v] = m(!1), [c,
|
|
25
|
+
const [b, v] = m(!1), [c, _] = m(!1), [g, w] = m(!1), a = I(null);
|
|
25
26
|
u(() => (w(!0), o === "secondary" && !a.current && (a.current = document.createElement("div"), a.current.className = "modal_portal_container", document.body.appendChild(a.current)), () => {
|
|
26
27
|
w(!1), a.current && (document.body.removeChild(a.current), a.current = null);
|
|
27
28
|
}), [o]), u(() => {
|
|
28
29
|
const e = document.body;
|
|
29
|
-
return r ? (v(!0), e.classList.add("eco_modal_open")) : (
|
|
30
|
-
g && (v(!1),
|
|
30
|
+
return r ? (v(!0), e.classList.add("eco_modal_open")) : (_(!0), setTimeout(() => {
|
|
31
|
+
g && (v(!1), _(!1)), e.classList.remove("eco_modal_open");
|
|
31
32
|
}, 200)), () => {
|
|
32
33
|
e.classList.remove("eco_modal_open");
|
|
33
34
|
};
|
|
@@ -37,7 +38,7 @@ const V = ({
|
|
|
37
38
|
s === "left" ? "eco_modal_primary_left" : "eco_modal_primary_right"
|
|
38
39
|
));
|
|
39
40
|
const d = () => {
|
|
40
|
-
if (!(r &&
|
|
41
|
+
if (!(r && n && !l)) {
|
|
41
42
|
e.classList.remove("eco_modal_two_modals_50", "eco_modal_two_modals_large");
|
|
42
43
|
return;
|
|
43
44
|
}
|
|
@@ -46,25 +47,25 @@ const V = ({
|
|
|
46
47
|
return d(), window.addEventListener("resize", d), () => {
|
|
47
48
|
o === "primary" && e.classList.remove("eco_modal_primary_right", "eco_modal_primary_left"), e.classList.remove("eco_modal_two_modals_50", "eco_modal_two_modals_large"), window.removeEventListener("resize", d);
|
|
48
49
|
};
|
|
49
|
-
}, [o, s, r,
|
|
50
|
-
const
|
|
50
|
+
}, [o, s, r, n, l]);
|
|
51
|
+
const x = () => o === "primary" ? s === "center" ? "eco_modal_primary_center" : `eco_modal_primary_${s}` : `eco_modal_secondary_${s === "left" ? "right" : "left"}`, W = () => {
|
|
51
52
|
const e = ["eco_modal_overlay"];
|
|
52
|
-
return o === "primary" ? e.push(`eco_modal_primary_${s}`) : e.push("eco_modal_secondary_overlay"), b && !c && e.push("eco_modal_show"), c && e.push("eco_modal_hide"), e.join(" ");
|
|
53
|
-
},
|
|
54
|
-
const e = ["eco_modal_container", o,
|
|
53
|
+
return $ && e.push("eco_modal_overlay_bg"), o === "primary" ? e.push(`eco_modal_primary_${s}`) : e.push("eco_modal_secondary_overlay"), b && !c && e.push("eco_modal_show"), c && e.push("eco_modal_hide"), e.join(" ");
|
|
54
|
+
}, z = () => {
|
|
55
|
+
const e = ["eco_modal_container", o, x()];
|
|
55
56
|
return b && !c && e.push("eco_modal_show"), c && e.push("eco_modal_hide"), l && e.push("eco_modal_maximized"), s === "center" && e.push("eco_modal_centered"), e.join(" ");
|
|
56
|
-
}, C = o === "primary" ? h || R : h,
|
|
57
|
-
!C && o === "primary" && k && (
|
|
58
|
-
f(),
|
|
57
|
+
}, C = o === "primary" ? h || R : h, F = o === "primary" && r && n, O = () => {
|
|
58
|
+
!C && o === "primary" && k && (_(!0), setTimeout(() => {
|
|
59
|
+
f(), _(!1);
|
|
59
60
|
}, 200));
|
|
60
|
-
},
|
|
61
|
+
}, q = () => {
|
|
61
62
|
const e = {};
|
|
62
63
|
return o === "primary" && !l && y && (e["--modal-primary-width"] = `${y}%`), e;
|
|
63
|
-
}, L = /* @__PURE__ */ t("div", { className:
|
|
64
|
+
}, L = /* @__PURE__ */ t("div", { className: W(), onClick: O, children: /* @__PURE__ */ i(
|
|
64
65
|
"div",
|
|
65
66
|
{
|
|
66
|
-
className:
|
|
67
|
-
style:
|
|
67
|
+
className: z(),
|
|
68
|
+
style: q(),
|
|
68
69
|
onClick: (e) => e.stopPropagation(),
|
|
69
70
|
children: [
|
|
70
71
|
/* @__PURE__ */ i(
|
|
@@ -81,8 +82,8 @@ const V = ({
|
|
|
81
82
|
className: "eco_modal_max_button",
|
|
82
83
|
onClick: p,
|
|
83
84
|
type: "button",
|
|
84
|
-
disabled:
|
|
85
|
-
children: l ? /* @__PURE__ */ t(
|
|
85
|
+
disabled: F,
|
|
86
|
+
children: l ? /* @__PURE__ */ t(A, { size: 14, className: "eco_modal_icon_header" }) : /* @__PURE__ */ t(B, { size: 14, className: "eco_modal_icon_header" })
|
|
86
87
|
}
|
|
87
88
|
),
|
|
88
89
|
/* @__PURE__ */ t(
|
|
@@ -110,8 +111,8 @@ const V = ({
|
|
|
110
111
|
]
|
|
111
112
|
}
|
|
112
113
|
) });
|
|
113
|
-
return o === "secondary" && a.current ?
|
|
114
|
+
return o === "secondary" && a.current ? M.createPortal(L, a.current) : L;
|
|
114
115
|
};
|
|
115
116
|
export {
|
|
116
|
-
|
|
117
|
+
X as EcoModal
|
|
117
118
|
};
|