react-ecosistema-unp 0.9.0 → 0.9.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{NotificacionUsuario-WGsdHnu2.js → NotificacionUsuario-xD2pyELE.js} +2 -4
- package/dist/assets/IconosSistema.css +1 -0
- package/dist/assets/NotificacionUsuario.css +1 -1
- package/dist/lib/shared/breadcrumb/Breadcrumb.d.ts +1 -2
- package/dist/lib/shared/iconos-sistema/IconosSistema.d.ts +11 -0
- package/dist/lib/shared/notificacion-usuario/NotificacionUsuario.d.ts +1 -1
- package/dist/lib/shared/ventana-lienzo/VentanaLienzo.d.ts +2 -1
- package/dist/lib/shared/ventana-tabs/VentanaTabs.d.ts +2 -0
- package/dist/shared/breadcrumb/Breadcrumb.js +48 -51
- package/dist/shared/iconos-sistema/IconosSistema.js +16 -0
- package/dist/shared/notificacion-usuario/NotificacionUsuario.js +2 -2
- package/dist/shared/ventana-lienzo/VentanaLienzo.js +13 -13
- package/dist/shared/ventana-tabs/VentanaTabs.js +66 -65
- package/package.json +3 -3
|
@@ -1872,9 +1872,7 @@ const Co = Object.assign(pn, {
|
|
|
1872
1872
|
function Po(e) {
|
|
1873
1873
|
return xn({ tag: "svg", attr: { viewBox: "0 0 448 512" }, child: [{ tag: "path", attr: { d: "M224 512c35.32 0 63.97-28.65 63.97-64H160.03c0 35.35 28.65 64 63.97 64zm215.39-149.71c-19.32-20.76-55.47-51.99-55.47-154.29 0-77.7-54.48-139.9-127.94-155.16V32c0-17.67-14.32-32-31.98-32s-31.98 14.33-31.98 32v20.84C118.56 68.1 64.08 130.3 64.08 208c0 102.3-36.15 133.53-55.47 154.29-6 6.45-8.66 14.16-8.61 21.71.11 16.4 12.98 32 32.1 32h383.8c19.12 0 32-15.6 32.1-32 .05-7.55-2.61-15.27-8.61-21.71z" }, child: [] }] })(e);
|
|
1874
1874
|
}
|
|
1875
|
-
const Lo = () => /* @__PURE__ */ j(
|
|
1876
|
-
marginTop: "6px"
|
|
1877
|
-
}, children: /* @__PURE__ */ j(
|
|
1875
|
+
const Lo = () => /* @__PURE__ */ j(
|
|
1878
1876
|
Co,
|
|
1879
1877
|
{
|
|
1880
1878
|
title: /* @__PURE__ */ j(Po, { className: "icono-notificaciones" }),
|
|
@@ -1884,7 +1882,7 @@ const Lo = () => /* @__PURE__ */ j("div", { className: "position-absolute top-0
|
|
|
1884
1882
|
padding: "1rem"
|
|
1885
1883
|
}, children: "Notificaciones" })
|
|
1886
1884
|
}
|
|
1887
|
-
)
|
|
1885
|
+
);
|
|
1888
1886
|
export {
|
|
1889
1887
|
Lo as N,
|
|
1890
1888
|
Do as a,
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.iconos-sistema-container{position:absolute;top:0;right:0;margin-top:6px;display:flex;justify-content:end;gap:1rem}.iconos-sistema-icon{margin-top:.5rem;font-size:25px;color:#303d50;cursor:pointer}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
.dropdown-toggle{margin-top:.5rem;margin-right:.75rem}.dropdown-toggle:after{display:none!important}.dropdown-toggle.nav-link{padding:0}.dropdown-menu.show{margin-top:.75rem;border-radius:10px;border:0;box-shadow:0 6px 12px #0000002d}.icono-notificaciones{
|
|
1
|
+
.dropdown-toggle{margin-top:.5rem;margin-right:.75rem}.dropdown-toggle:after{display:none!important}.dropdown-toggle.nav-link{padding:0}.dropdown-menu.show{margin-top:.75rem;border-radius:10px;border:0;box-shadow:0 6px 12px #0000002d}.icono-notificaciones{font-size:25px;color:#303d50;transform-origin:top center;transition:transform .3s}.icono-notificaciones:hover{animation:balanceoCampana .425s ease-in-out}@keyframes balanceoCampana{0%{transform:rotate(0)}20%{transform:rotate(10deg)}40%{transform:rotate(-10deg)}60%{transform:rotate(6deg)}80%{transform:rotate(-6deg)}to{transform:rotate(0)}}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { IconType } from 'react-icons';
|
|
3
|
+
export interface IconoSistema {
|
|
4
|
+
icon: IconType;
|
|
5
|
+
action: (...args: any[]) => any;
|
|
6
|
+
}
|
|
7
|
+
interface IconosSistemaProps {
|
|
8
|
+
elements?: IconoSistema[];
|
|
9
|
+
}
|
|
10
|
+
declare const IconosSistema: React.FC<IconosSistemaProps>;
|
|
11
|
+
export { IconosSistema };
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
|
+
import { IconoSistema } from '../iconos-sistema/IconosSistema.js';
|
|
2
3
|
import { BreadcrumbItem } from '../breadcrumb/Breadcrumb.js';
|
|
3
4
|
interface VentanaLienzoProps {
|
|
4
5
|
children?: React.ReactNode;
|
|
5
6
|
items?: BreadcrumbItem[];
|
|
6
|
-
extraInput?:
|
|
7
|
+
extraInput?: IconoSistema[];
|
|
7
8
|
}
|
|
8
9
|
declare const VentanaLienzo: React.FC<VentanaLienzoProps>;
|
|
9
10
|
export { VentanaLienzo };
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
|
+
import { IconoSistema } from '../iconos-sistema/IconosSistema.js';
|
|
2
3
|
interface VentanaUsuarioProps {
|
|
3
4
|
children?: React.ReactNode;
|
|
5
|
+
extraInput?: IconoSistema[];
|
|
4
6
|
}
|
|
5
7
|
declare const VentanaTabs: React.FC<VentanaUsuarioProps>;
|
|
6
8
|
export { VentanaTabs };
|
|
@@ -1,66 +1,66 @@
|
|
|
1
|
-
import { jsx as a
|
|
2
|
-
import { u as
|
|
3
|
-
import * as
|
|
4
|
-
import { A as
|
|
5
|
-
import '../../assets/Breadcrumb.css';const
|
|
1
|
+
import { jsx as a } from "react/jsx-runtime";
|
|
2
|
+
import { u as o, c as u } from "../../ThemeProvider-CFCmmLJC.js";
|
|
3
|
+
import * as b from "react";
|
|
4
|
+
import { A as x } from "../../Anchor-D8f6vg0T.js";
|
|
5
|
+
import '../../assets/Breadcrumb.css';const i = /* @__PURE__ */ b.forwardRef(({
|
|
6
6
|
bsPrefix: c,
|
|
7
|
-
active:
|
|
8
|
-
children:
|
|
9
|
-
className:
|
|
7
|
+
active: r = !1,
|
|
8
|
+
children: e,
|
|
9
|
+
className: n,
|
|
10
10
|
// Need to define the default "as" during prop destructuring to be compatible with styled-components github.com/react-bootstrap/react-bootstrap/issues/3595
|
|
11
|
-
as:
|
|
12
|
-
linkAs: d =
|
|
13
|
-
linkProps:
|
|
14
|
-
href:
|
|
15
|
-
title:
|
|
16
|
-
target:
|
|
17
|
-
...
|
|
11
|
+
as: s = "li",
|
|
12
|
+
linkAs: d = x,
|
|
13
|
+
linkProps: m = {},
|
|
14
|
+
href: l,
|
|
15
|
+
title: t,
|
|
16
|
+
target: p,
|
|
17
|
+
...h
|
|
18
18
|
}, N) => {
|
|
19
|
-
const B =
|
|
20
|
-
return /* @__PURE__ */ a(
|
|
19
|
+
const B = o(c, "breadcrumb-item");
|
|
20
|
+
return /* @__PURE__ */ a(s, {
|
|
21
21
|
ref: N,
|
|
22
|
-
...
|
|
23
|
-
className: u(B,
|
|
24
|
-
active:
|
|
22
|
+
...h,
|
|
23
|
+
className: u(B, n, {
|
|
24
|
+
active: r
|
|
25
25
|
}),
|
|
26
|
-
"aria-current":
|
|
27
|
-
children:
|
|
28
|
-
...
|
|
29
|
-
href:
|
|
30
|
-
title:
|
|
31
|
-
target:
|
|
32
|
-
children:
|
|
26
|
+
"aria-current": r ? "page" : void 0,
|
|
27
|
+
children: r ? e : /* @__PURE__ */ a(d, {
|
|
28
|
+
...m,
|
|
29
|
+
href: l,
|
|
30
|
+
title: t,
|
|
31
|
+
target: p,
|
|
32
|
+
children: e
|
|
33
33
|
})
|
|
34
34
|
});
|
|
35
35
|
});
|
|
36
|
-
|
|
37
|
-
const f = /* @__PURE__ */
|
|
36
|
+
i.displayName = "BreadcrumbItem";
|
|
37
|
+
const f = /* @__PURE__ */ b.forwardRef(({
|
|
38
38
|
bsPrefix: c,
|
|
39
|
-
className:
|
|
40
|
-
listProps:
|
|
41
|
-
children:
|
|
42
|
-
label:
|
|
39
|
+
className: r,
|
|
40
|
+
listProps: e = {},
|
|
41
|
+
children: n,
|
|
42
|
+
label: s = "breadcrumb",
|
|
43
43
|
// Need to define the default "as" during prop destructuring to be compatible with styled-components github.com/react-bootstrap/react-bootstrap/issues/3595
|
|
44
44
|
as: d = "nav",
|
|
45
|
-
...
|
|
46
|
-
},
|
|
47
|
-
const
|
|
45
|
+
...m
|
|
46
|
+
}, l) => {
|
|
47
|
+
const t = o(c, "breadcrumb");
|
|
48
48
|
return /* @__PURE__ */ a(d, {
|
|
49
|
-
"aria-label":
|
|
50
|
-
className:
|
|
51
|
-
ref:
|
|
52
|
-
...
|
|
49
|
+
"aria-label": s,
|
|
50
|
+
className: r,
|
|
51
|
+
ref: l,
|
|
52
|
+
...m,
|
|
53
53
|
children: /* @__PURE__ */ a("ol", {
|
|
54
|
-
...
|
|
55
|
-
className: u(
|
|
56
|
-
children:
|
|
54
|
+
...e,
|
|
55
|
+
className: u(t, e == null ? void 0 : e.className),
|
|
56
|
+
children: n
|
|
57
57
|
})
|
|
58
58
|
});
|
|
59
59
|
});
|
|
60
60
|
f.displayName = "Breadcrumb";
|
|
61
|
-
const
|
|
62
|
-
Item:
|
|
63
|
-
}), k = ({ items: c
|
|
61
|
+
const w = Object.assign(f, {
|
|
62
|
+
Item: i
|
|
63
|
+
}), k = ({ items: c }) => /* @__PURE__ */ a("div", { className: "breadcrumb-container", children: /* @__PURE__ */ a(
|
|
64
64
|
"div",
|
|
65
65
|
{
|
|
66
66
|
className: "breadcrumb-wrapper",
|
|
@@ -68,12 +68,9 @@ const j = Object.assign(f, {
|
|
|
68
68
|
// Ajusta la posición de los elementos si se proporcionan links y hay un input extra
|
|
69
69
|
justifyContent: c ? "space-between" : "end"
|
|
70
70
|
},
|
|
71
|
-
children:
|
|
72
|
-
c && /* @__PURE__ */ a(j, { children: c.map((r, s) => /* @__PURE__ */ a(t, { href: r.link, active: !r.link, children: r.label }, s)) }),
|
|
73
|
-
e && /* @__PURE__ */ a("div", { className: "breadcrumb-right", children: e })
|
|
74
|
-
]
|
|
71
|
+
children: c && /* @__PURE__ */ a(w, { children: c.map((r, e) => /* @__PURE__ */ a(i, { href: r.link, active: !r.link, children: r.label }, e)) })
|
|
75
72
|
}
|
|
76
73
|
) });
|
|
77
74
|
export {
|
|
78
|
-
k as
|
|
75
|
+
k as BreadcrumbNav
|
|
79
76
|
};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { jsxs as a, jsx as i } from "react/jsx-runtime";
|
|
2
|
+
import { N as n } from "../../NotificacionUsuario-xD2pyELE.js";
|
|
3
|
+
import '../../assets/IconosSistema.css';const m = ({ elements: o }) => /* @__PURE__ */ a("div", { className: "iconos-sistema-container", children: [
|
|
4
|
+
o && o.slice(0, 5).map((s, c) => /* @__PURE__ */ i(
|
|
5
|
+
s.icon,
|
|
6
|
+
{
|
|
7
|
+
className: "iconos-sistema-icon",
|
|
8
|
+
onClick: s.action
|
|
9
|
+
},
|
|
10
|
+
c
|
|
11
|
+
)),
|
|
12
|
+
/* @__PURE__ */ i("div", { style: { marginLeft: "1rem" }, children: /* @__PURE__ */ i(n, {}) })
|
|
13
|
+
] });
|
|
14
|
+
export {
|
|
15
|
+
m as IconosSistema
|
|
16
|
+
};
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import { jsxs as o, jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import m from "react";
|
|
3
|
+
import { IconosSistema as i } from "../iconos-sistema/IconosSistema.js";
|
|
4
|
+
import { BreadcrumbNav as l } from "../breadcrumb/Breadcrumb.js";
|
|
4
5
|
import { MenuLateral as c } from "../menu-lateral/MenuLateral.js";
|
|
5
|
-
import { N as l } from "../../NotificacionUsuario-WGsdHnu2.js";
|
|
6
6
|
import { B as p } from "../../chunk-IR6S3I6Y-Dvzk3EbC.js";
|
|
7
|
-
import '../../assets/VentanaLienzo.css';const x = ({ children:
|
|
8
|
-
const [
|
|
9
|
-
return /* @__PURE__ */
|
|
10
|
-
/* @__PURE__ */ e(
|
|
7
|
+
import '../../assets/VentanaLienzo.css';const x = ({ children: r, items: a, extraInput: t }) => {
|
|
8
|
+
const [n, s] = m.useState(!1);
|
|
9
|
+
return /* @__PURE__ */ o(p, { children: [
|
|
10
|
+
/* @__PURE__ */ e(i, { elements: t }),
|
|
11
11
|
/* @__PURE__ */ e(c, { onToggle: () => {
|
|
12
|
-
|
|
13
|
-
}, isOpen:
|
|
14
|
-
/* @__PURE__ */ e("div", { className: `${
|
|
15
|
-
/* @__PURE__ */ e(
|
|
16
|
-
/* @__PURE__ */ e("div", { className: "ventana-lienzo-container", children:
|
|
12
|
+
s(!n);
|
|
13
|
+
}, isOpen: n }),
|
|
14
|
+
/* @__PURE__ */ e("div", { className: `${n ? "menu-open" : ""}`, children: /* @__PURE__ */ o("div", { className: "main-section", children: [
|
|
15
|
+
/* @__PURE__ */ e(l, { items: a }),
|
|
16
|
+
/* @__PURE__ */ e("div", { className: "ventana-lienzo-container", children: r })
|
|
17
17
|
] }) })
|
|
18
18
|
] });
|
|
19
19
|
};
|
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
import { jsx as r, jsxs as j } from "react/jsx-runtime";
|
|
2
2
|
import * as b from "react";
|
|
3
|
-
import T, { useRef as O, useContext as
|
|
3
|
+
import T, { useRef as O, useContext as S, useEffect as M } from "react";
|
|
4
4
|
import { MenuLateral as H } from "../menu-lateral/MenuLateral.js";
|
|
5
|
-
import {
|
|
6
|
-
import { u as
|
|
5
|
+
import { IconosSistema as F } from "../iconos-sistema/IconosSistema.js";
|
|
6
|
+
import { u as W, T as Y, g as z, a as G, b as J } from "../../Bootstrap-yLMFDuQq.js";
|
|
7
|
+
import { a as Q, u as X, b as Z, d as ee, c as te, q as ne, e as B, f as D, g as ae } from "../../NotificacionUsuario-xD2pyELE.js";
|
|
7
8
|
import { u as L, c as k } from "../../ThemeProvider-CFCmmLJC.js";
|
|
8
|
-
import { S as
|
|
9
|
+
import { S as I, T as re, m as se } from "../../TabContext-CdjYJzMB.js";
|
|
9
10
|
import { c as oe } from "../../CardHeaderContext-DVw0yHuy.js";
|
|
10
11
|
import { B as le } from "../../chunk-IR6S3I6Y-Dvzk3EbC.js";
|
|
11
|
-
function
|
|
12
|
+
function P(n, e) {
|
|
12
13
|
let a = 0;
|
|
13
14
|
return b.Children.map(n, (t) => /* @__PURE__ */ b.isValidElement(t) ? e(t, a++) : t);
|
|
14
15
|
}
|
|
@@ -28,32 +29,32 @@ function de(n, e) {
|
|
|
28
29
|
}
|
|
29
30
|
return a;
|
|
30
31
|
}
|
|
31
|
-
const
|
|
32
|
-
},
|
|
32
|
+
const R = () => {
|
|
33
|
+
}, A = ee("event-key"), V = /* @__PURE__ */ b.forwardRef((n, e) => {
|
|
33
34
|
let {
|
|
34
35
|
// Need to define the default "as" during prop destructuring to be compatible with styled-components github.com/react-bootstrap/react-bootstrap/issues/3595
|
|
35
36
|
as: a = "div",
|
|
36
37
|
onSelect: t,
|
|
37
38
|
activeKey: s,
|
|
38
39
|
role: c,
|
|
39
|
-
onKeyDown:
|
|
40
|
-
} = n,
|
|
41
|
-
const
|
|
42
|
-
let v,
|
|
43
|
-
l && (c = c || "tablist", s = l.activeKey, v = l.getControlledId,
|
|
40
|
+
onKeyDown: u
|
|
41
|
+
} = n, o = de(n, ce);
|
|
42
|
+
const N = X(), m = O(!1), y = S(I), l = S(re);
|
|
43
|
+
let v, x;
|
|
44
|
+
l && (c = c || "tablist", s = l.activeKey, v = l.getControlledId, x = l.getControllerId);
|
|
44
45
|
const f = O(null), p = (i) => {
|
|
45
46
|
const d = f.current;
|
|
46
47
|
if (!d) return null;
|
|
47
|
-
const K =
|
|
48
|
-
if (!
|
|
49
|
-
const w = K.indexOf(
|
|
48
|
+
const K = ne(d, `[${A}]:not([aria-disabled=true])`), E = d.querySelector("[aria-selected=true]");
|
|
49
|
+
if (!E || E !== document.activeElement) return null;
|
|
50
|
+
const w = K.indexOf(E);
|
|
50
51
|
if (w === -1) return null;
|
|
51
52
|
let g = w + i;
|
|
52
53
|
return g >= K.length && (g = 0), g < 0 && (g = K.length - 1), K[g];
|
|
53
54
|
}, h = (i, d) => {
|
|
54
55
|
i != null && (t == null || t(i, d), y == null || y(i, d));
|
|
55
56
|
}, C = (i) => {
|
|
56
|
-
if (
|
|
57
|
+
if (u == null || u(i), !l)
|
|
57
58
|
return;
|
|
58
59
|
let d;
|
|
59
60
|
switch (i.key) {
|
|
@@ -68,37 +69,37 @@ const A = () => {
|
|
|
68
69
|
default:
|
|
69
70
|
return;
|
|
70
71
|
}
|
|
71
|
-
d && (i.preventDefault(), h(d.dataset[
|
|
72
|
+
d && (i.preventDefault(), h(d.dataset[te("EventKey")] || null, i), m.current = !0, N());
|
|
72
73
|
};
|
|
73
74
|
M(() => {
|
|
74
75
|
if (f.current && m.current) {
|
|
75
|
-
const i = f.current.querySelector(`[${
|
|
76
|
+
const i = f.current.querySelector(`[${A}][aria-selected=true]`);
|
|
76
77
|
i == null || i.focus();
|
|
77
78
|
}
|
|
78
79
|
m.current = !1;
|
|
79
80
|
});
|
|
80
|
-
const
|
|
81
|
-
return /* @__PURE__ */ r(
|
|
81
|
+
const U = W(e, f);
|
|
82
|
+
return /* @__PURE__ */ r(I.Provider, {
|
|
82
83
|
value: h,
|
|
83
|
-
children: /* @__PURE__ */ r(
|
|
84
|
+
children: /* @__PURE__ */ r(Z.Provider, {
|
|
84
85
|
value: {
|
|
85
86
|
role: c,
|
|
86
87
|
// used by NavLink to determine it's role
|
|
87
88
|
activeKey: se(s),
|
|
88
|
-
getControlledId: v ||
|
|
89
|
-
getControllerId:
|
|
89
|
+
getControlledId: v || R,
|
|
90
|
+
getControllerId: x || R
|
|
90
91
|
},
|
|
91
|
-
children: /* @__PURE__ */ r(a, Object.assign({},
|
|
92
|
+
children: /* @__PURE__ */ r(a, Object.assign({}, o, {
|
|
92
93
|
onKeyDown: C,
|
|
93
|
-
ref:
|
|
94
|
+
ref: U,
|
|
94
95
|
role: c
|
|
95
96
|
}))
|
|
96
97
|
})
|
|
97
98
|
});
|
|
98
99
|
});
|
|
99
|
-
|
|
100
|
-
const ue = Object.assign(
|
|
101
|
-
Item:
|
|
100
|
+
V.displayName = "Nav";
|
|
101
|
+
const ue = Object.assign(V, {
|
|
102
|
+
Item: Q
|
|
102
103
|
}), $ = /* @__PURE__ */ b.forwardRef(({
|
|
103
104
|
className: n,
|
|
104
105
|
bsPrefix: e,
|
|
@@ -110,24 +111,24 @@ const ue = Object.assign(U, {
|
|
|
110
111
|
...t
|
|
111
112
|
})));
|
|
112
113
|
$.displayName = "NavItem";
|
|
113
|
-
const
|
|
114
|
+
const _ = /* @__PURE__ */ b.forwardRef((n, e) => {
|
|
114
115
|
const {
|
|
115
116
|
as: a = "div",
|
|
116
117
|
bsPrefix: t,
|
|
117
118
|
variant: s,
|
|
118
119
|
fill: c = !1,
|
|
119
|
-
justify:
|
|
120
|
-
navbar:
|
|
121
|
-
navbarScroll:
|
|
120
|
+
justify: u = !1,
|
|
121
|
+
navbar: o,
|
|
122
|
+
navbarScroll: N,
|
|
122
123
|
className: m,
|
|
123
124
|
activeKey: y,
|
|
124
125
|
...l
|
|
125
126
|
} = D(n, {
|
|
126
127
|
activeKey: "onSelect"
|
|
127
128
|
}), v = L(t, "nav");
|
|
128
|
-
let
|
|
129
|
-
const h =
|
|
130
|
-
return h ? (
|
|
129
|
+
let x, f, p = !1;
|
|
130
|
+
const h = S(ae), C = S(oe);
|
|
131
|
+
return h ? (x = h.bsPrefix, p = o ?? !0) : C && ({
|
|
131
132
|
cardHeaderBsPrefix: f
|
|
132
133
|
} = C), /* @__PURE__ */ r(ue, {
|
|
133
134
|
as: a,
|
|
@@ -135,18 +136,18 @@ const V = /* @__PURE__ */ b.forwardRef((n, e) => {
|
|
|
135
136
|
activeKey: y,
|
|
136
137
|
className: k(m, {
|
|
137
138
|
[v]: !p,
|
|
138
|
-
[`${
|
|
139
|
-
[`${
|
|
139
|
+
[`${x}-nav`]: p,
|
|
140
|
+
[`${x}-nav-scroll`]: p && N,
|
|
140
141
|
[`${f}-${s}`]: !!f,
|
|
141
142
|
[`${v}-${s}`]: !!s,
|
|
142
143
|
[`${v}-fill`]: c,
|
|
143
|
-
[`${v}-justified`]:
|
|
144
|
+
[`${v}-justified`]: u
|
|
144
145
|
}),
|
|
145
146
|
...l
|
|
146
147
|
});
|
|
147
148
|
});
|
|
148
|
-
|
|
149
|
-
const fe = Object.assign(
|
|
149
|
+
_.displayName = "Nav";
|
|
150
|
+
const fe = Object.assign(_, {
|
|
150
151
|
Item: $,
|
|
151
152
|
Link: B
|
|
152
153
|
});
|
|
@@ -163,7 +164,7 @@ function ve(n) {
|
|
|
163
164
|
disabled: t,
|
|
164
165
|
tabClassName: s,
|
|
165
166
|
tabAttrs: c,
|
|
166
|
-
id:
|
|
167
|
+
id: u
|
|
167
168
|
} = n.props;
|
|
168
169
|
return e == null ? null : /* @__PURE__ */ r($, {
|
|
169
170
|
as: "li",
|
|
@@ -173,32 +174,32 @@ function ve(n) {
|
|
|
173
174
|
type: "button",
|
|
174
175
|
eventKey: a,
|
|
175
176
|
disabled: t,
|
|
176
|
-
id:
|
|
177
|
+
id: u,
|
|
177
178
|
className: s,
|
|
178
179
|
...c,
|
|
179
180
|
children: e
|
|
180
181
|
})
|
|
181
182
|
});
|
|
182
183
|
}
|
|
183
|
-
const
|
|
184
|
+
const q = (n) => {
|
|
184
185
|
const {
|
|
185
186
|
id: e,
|
|
186
187
|
onSelect: a,
|
|
187
188
|
transition: t,
|
|
188
189
|
mountOnEnter: s = !1,
|
|
189
190
|
unmountOnExit: c = !1,
|
|
190
|
-
variant:
|
|
191
|
-
children:
|
|
192
|
-
activeKey:
|
|
191
|
+
variant: u = "tabs",
|
|
192
|
+
children: o,
|
|
193
|
+
activeKey: N = me(o),
|
|
193
194
|
...m
|
|
194
195
|
} = D(n, {
|
|
195
196
|
activeKey: "onSelect"
|
|
196
197
|
});
|
|
197
|
-
return /* @__PURE__ */ j(
|
|
198
|
+
return /* @__PURE__ */ j(Y, {
|
|
198
199
|
id: e,
|
|
199
|
-
activeKey:
|
|
200
|
+
activeKey: N,
|
|
200
201
|
onSelect: a,
|
|
201
|
-
transition:
|
|
202
|
+
transition: z(t),
|
|
202
203
|
mountOnEnter: s,
|
|
203
204
|
unmountOnExit: c,
|
|
204
205
|
children: [/* @__PURE__ */ r(fe, {
|
|
@@ -206,39 +207,39 @@ const _ = (n) => {
|
|
|
206
207
|
...m,
|
|
207
208
|
role: "tablist",
|
|
208
209
|
as: "ul",
|
|
209
|
-
variant:
|
|
210
|
-
children:
|
|
211
|
-
}), /* @__PURE__ */ r(
|
|
212
|
-
children:
|
|
210
|
+
variant: u,
|
|
211
|
+
children: P(o, ve)
|
|
212
|
+
}), /* @__PURE__ */ r(G, {
|
|
213
|
+
children: P(o, (y) => {
|
|
213
214
|
const l = {
|
|
214
215
|
...y.props
|
|
215
216
|
};
|
|
216
|
-
return delete l.title, delete l.disabled, delete l.tabClassName, delete l.tabAttrs, /* @__PURE__ */ r(
|
|
217
|
+
return delete l.title, delete l.disabled, delete l.tabClassName, delete l.tabAttrs, /* @__PURE__ */ r(J, {
|
|
217
218
|
...l
|
|
218
219
|
});
|
|
219
220
|
})
|
|
220
221
|
})]
|
|
221
222
|
});
|
|
222
223
|
};
|
|
223
|
-
|
|
224
|
-
const
|
|
225
|
-
const [
|
|
224
|
+
q.displayName = "Tabs";
|
|
225
|
+
const Se = ({ children: n, extraInput: e }) => {
|
|
226
|
+
const [a, t] = T.useState(!1), [s, c] = T.useState(void 0);
|
|
226
227
|
return /* @__PURE__ */ j(le, { children: [
|
|
227
|
-
/* @__PURE__ */ r(
|
|
228
|
+
/* @__PURE__ */ r(F, { elements: e }),
|
|
228
229
|
/* @__PURE__ */ r(H, { onToggle: () => {
|
|
229
|
-
|
|
230
|
-
}, isOpen:
|
|
231
|
-
/* @__PURE__ */ r("div", { className: `${
|
|
232
|
-
|
|
230
|
+
t(!a);
|
|
231
|
+
}, isOpen: a }),
|
|
232
|
+
/* @__PURE__ */ r("div", { className: `${a ? "menu-open" : ""}`, children: /* @__PURE__ */ r("div", { className: "main-section", children: /* @__PURE__ */ r(
|
|
233
|
+
q,
|
|
233
234
|
{
|
|
234
235
|
id: "controlled-tab",
|
|
235
|
-
activeKey:
|
|
236
|
-
onSelect: (o) =>
|
|
236
|
+
activeKey: s,
|
|
237
|
+
onSelect: (o) => c(o !== null ? o : void 0),
|
|
237
238
|
children: T.Children.map(n, (o) => T.isValidElement(o) ? o : null)
|
|
238
239
|
}
|
|
239
240
|
) }) })
|
|
240
241
|
] });
|
|
241
242
|
};
|
|
242
243
|
export {
|
|
243
|
-
|
|
244
|
+
Se as VentanaTabs
|
|
244
245
|
};
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "react-ecosistema-unp",
|
|
3
3
|
"author": "Ecosistema de Información - Unidad Nacional de Protección",
|
|
4
4
|
"private": false,
|
|
5
|
-
"version": "0.9.
|
|
5
|
+
"version": "0.9.2",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"exports": {
|
|
8
8
|
".": {
|
|
@@ -52,8 +52,8 @@
|
|
|
52
52
|
"deploy:storybook": "gh-pages -d .storybook-build -b gh-pages -t"
|
|
53
53
|
},
|
|
54
54
|
"peerDependencies": {
|
|
55
|
-
"react": "
|
|
56
|
-
"react-dom": "
|
|
55
|
+
"react": ">=18.0.0 <=20.0.0",
|
|
56
|
+
"react-dom": ">=18.0.0 <=20.0.0"
|
|
57
57
|
},
|
|
58
58
|
"dependencies": {
|
|
59
59
|
"bootstrap": "^5.3.3",
|