react-ecosistema-unp 1.3.0-pre-release.8 → 1.3.0

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.
@@ -1,21 +1,132 @@
1
- import { useNavigate as i } from "react-router-dom";
2
- import { useAuthId as a } from "./AuthHook.js";
3
- import { FinSesionService as c } from "../services/FinSesionService.js";
4
- import { y as l } from "../../index-Cs6Q8pv4.js";
5
- const k = () => {
6
- const o = i(), { setAuthToken: n, setUserToken: r } = a();
1
+ import { useNavigate as O } from "react-router-dom";
2
+ import { useAuthId as C } from "./AuthHook.js";
3
+ import { FinSesionService as S } from "../services/FinSesionService.js";
4
+ import { isValidElement as E } from "react";
5
+ function L(t) {
6
+ if (typeof document > "u") return;
7
+ let o = document.head || document.getElementsByTagName("head")[0], a = document.createElement("style");
8
+ a.type = "text/css", o.firstChild ? o.insertBefore(a, o.firstChild) : o.appendChild(a), a.styleSheet ? a.styleSheet.cssText = t : a.appendChild(document.createTextNode(t));
9
+ }
10
+ L(`:root{--toastify-color-light: #fff;--toastify-color-dark: #121212;--toastify-color-info: #3498db;--toastify-color-success: #07bc0c;--toastify-color-warning: #f1c40f;--toastify-color-error: hsl(6, 78%, 57%);--toastify-color-transparent: rgba(255, 255, 255, .7);--toastify-icon-color-info: var(--toastify-color-info);--toastify-icon-color-success: var(--toastify-color-success);--toastify-icon-color-warning: var(--toastify-color-warning);--toastify-icon-color-error: var(--toastify-color-error);--toastify-container-width: fit-content;--toastify-toast-width: 320px;--toastify-toast-offset: 16px;--toastify-toast-top: max(var(--toastify-toast-offset), env(safe-area-inset-top));--toastify-toast-right: max(var(--toastify-toast-offset), env(safe-area-inset-right));--toastify-toast-left: max(var(--toastify-toast-offset), env(safe-area-inset-left));--toastify-toast-bottom: max(var(--toastify-toast-offset), env(safe-area-inset-bottom));--toastify-toast-background: #fff;--toastify-toast-padding: 14px;--toastify-toast-min-height: 64px;--toastify-toast-max-height: 800px;--toastify-toast-bd-radius: 6px;--toastify-toast-shadow: 0px 4px 12px rgba(0, 0, 0, .1);--toastify-font-family: sans-serif;--toastify-z-index: 9999;--toastify-text-color-light: #757575;--toastify-text-color-dark: #fff;--toastify-text-color-info: #fff;--toastify-text-color-success: #fff;--toastify-text-color-warning: #fff;--toastify-text-color-error: #fff;--toastify-spinner-color: #616161;--toastify-spinner-color-empty-area: #e0e0e0;--toastify-color-progress-light: linear-gradient(to right, #4cd964, #5ac8fa, #007aff, #34aadc, #5856d6, #ff2d55);--toastify-color-progress-dark: #bb86fc;--toastify-color-progress-info: var(--toastify-color-info);--toastify-color-progress-success: var(--toastify-color-success);--toastify-color-progress-warning: var(--toastify-color-warning);--toastify-color-progress-error: var(--toastify-color-error);--toastify-color-progress-bgo: .2}.Toastify__toast-container{z-index:var(--toastify-z-index);-webkit-transform:translate3d(0,0,var(--toastify-z-index));position:fixed;width:var(--toastify-container-width);box-sizing:border-box;color:#fff;display:flex;flex-direction:column}.Toastify__toast-container--top-left{top:var(--toastify-toast-top);left:var(--toastify-toast-left)}.Toastify__toast-container--top-center{top:var(--toastify-toast-top);left:50%;transform:translate(-50%);align-items:center}.Toastify__toast-container--top-right{top:var(--toastify-toast-top);right:var(--toastify-toast-right);align-items:end}.Toastify__toast-container--bottom-left{bottom:var(--toastify-toast-bottom);left:var(--toastify-toast-left)}.Toastify__toast-container--bottom-center{bottom:var(--toastify-toast-bottom);left:50%;transform:translate(-50%);align-items:center}.Toastify__toast-container--bottom-right{bottom:var(--toastify-toast-bottom);right:var(--toastify-toast-right);align-items:end}.Toastify__toast{--y: 0;position:relative;touch-action:none;width:var(--toastify-toast-width);min-height:var(--toastify-toast-min-height);box-sizing:border-box;margin-bottom:1rem;padding:var(--toastify-toast-padding);border-radius:var(--toastify-toast-bd-radius);box-shadow:var(--toastify-toast-shadow);max-height:var(--toastify-toast-max-height);font-family:var(--toastify-font-family);z-index:0;display:flex;flex:1 auto;align-items:center;word-break:break-word}@media only screen and (max-width: 480px){.Toastify__toast-container{width:100vw;left:env(safe-area-inset-left);margin:0}.Toastify__toast-container--top-left,.Toastify__toast-container--top-center,.Toastify__toast-container--top-right{top:env(safe-area-inset-top);transform:translate(0)}.Toastify__toast-container--bottom-left,.Toastify__toast-container--bottom-center,.Toastify__toast-container--bottom-right{bottom:env(safe-area-inset-bottom);transform:translate(0)}.Toastify__toast-container--rtl{right:env(safe-area-inset-right);left:initial}.Toastify__toast{--toastify-toast-width: 100%;margin-bottom:0;border-radius:0}}.Toastify__toast-container[data-stacked=true]{width:var(--toastify-toast-width)}.Toastify__toast--stacked{position:absolute;width:100%;transform:translate3d(0,var(--y),0) scale(var(--s));transition:transform .3s}.Toastify__toast--stacked[data-collapsed] .Toastify__toast-body,.Toastify__toast--stacked[data-collapsed] .Toastify__close-button{transition:opacity .1s}.Toastify__toast--stacked[data-collapsed=false]{overflow:visible}.Toastify__toast--stacked[data-collapsed=true]:not(:last-child)>*{opacity:0}.Toastify__toast--stacked:after{content:"";position:absolute;left:0;right:0;height:calc(var(--g) * 1px);bottom:100%}.Toastify__toast--stacked[data-pos=top]{top:0}.Toastify__toast--stacked[data-pos=bot]{bottom:0}.Toastify__toast--stacked[data-pos=bot].Toastify__toast--stacked:before{transform-origin:top}.Toastify__toast--stacked[data-pos=top].Toastify__toast--stacked:before{transform-origin:bottom}.Toastify__toast--stacked:before{content:"";position:absolute;left:0;right:0;bottom:0;height:100%;transform:scaleY(3);z-index:-1}.Toastify__toast--rtl{direction:rtl}.Toastify__toast--close-on-click{cursor:pointer}.Toastify__toast-icon{margin-inline-end:10px;width:22px;flex-shrink:0;display:flex}.Toastify--animate{animation-fill-mode:both;animation-duration:.5s}.Toastify--animate-icon{animation-fill-mode:both;animation-duration:.3s}.Toastify__toast-theme--dark{background:var(--toastify-color-dark);color:var(--toastify-text-color-dark)}.Toastify__toast-theme--light,.Toastify__toast-theme--colored.Toastify__toast--default{background:var(--toastify-color-light);color:var(--toastify-text-color-light)}.Toastify__toast-theme--colored.Toastify__toast--info{color:var(--toastify-text-color-info);background:var(--toastify-color-info)}.Toastify__toast-theme--colored.Toastify__toast--success{color:var(--toastify-text-color-success);background:var(--toastify-color-success)}.Toastify__toast-theme--colored.Toastify__toast--warning{color:var(--toastify-text-color-warning);background:var(--toastify-color-warning)}.Toastify__toast-theme--colored.Toastify__toast--error{color:var(--toastify-text-color-error);background:var(--toastify-color-error)}.Toastify__progress-bar-theme--light{background:var(--toastify-color-progress-light)}.Toastify__progress-bar-theme--dark{background:var(--toastify-color-progress-dark)}.Toastify__progress-bar--info{background:var(--toastify-color-progress-info)}.Toastify__progress-bar--success{background:var(--toastify-color-progress-success)}.Toastify__progress-bar--warning{background:var(--toastify-color-progress-warning)}.Toastify__progress-bar--error{background:var(--toastify-color-progress-error)}.Toastify__progress-bar-theme--colored.Toastify__progress-bar--info,.Toastify__progress-bar-theme--colored.Toastify__progress-bar--success,.Toastify__progress-bar-theme--colored.Toastify__progress-bar--warning,.Toastify__progress-bar-theme--colored.Toastify__progress-bar--error{background:var(--toastify-color-transparent)}.Toastify__close-button{color:#fff;position:absolute;top:6px;right:6px;background:transparent;outline:none;border:none;padding:0;cursor:pointer;opacity:.7;transition:.3s ease;z-index:1}.Toastify__toast--rtl .Toastify__close-button{left:6px;right:unset}.Toastify__close-button--light{color:#000;opacity:.3}.Toastify__close-button>svg{fill:currentColor;height:16px;width:14px}.Toastify__close-button:hover,.Toastify__close-button:focus{opacity:1}@keyframes Toastify__trackProgress{0%{transform:scaleX(1)}to{transform:scaleX(0)}}.Toastify__progress-bar{position:absolute;bottom:0;left:0;width:100%;height:100%;z-index:1;opacity:.7;transform-origin:left}.Toastify__progress-bar--animated{animation:Toastify__trackProgress linear 1 forwards}.Toastify__progress-bar--controlled{transition:transform .2s}.Toastify__progress-bar--rtl{right:0;left:initial;transform-origin:right;border-bottom-left-radius:initial}.Toastify__progress-bar--wrp{position:absolute;overflow:hidden;bottom:0;left:0;width:100%;height:5px;border-bottom-left-radius:var(--toastify-toast-bd-radius);border-bottom-right-radius:var(--toastify-toast-bd-radius)}.Toastify__progress-bar--wrp[data-hidden=true]{opacity:0}.Toastify__progress-bar--bg{opacity:var(--toastify-color-progress-bgo);width:100%;height:100%}.Toastify__spinner{width:20px;height:20px;box-sizing:border-box;border:2px solid;border-radius:100%;border-color:var(--toastify-spinner-color-empty-area);border-right-color:var(--toastify-spinner-color);animation:Toastify__spin .65s linear infinite}@keyframes Toastify__bounceInRight{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(3000px,0,0)}60%{opacity:1;transform:translate3d(-25px,0,0)}75%{transform:translate3d(10px,0,0)}90%{transform:translate3d(-5px,0,0)}to{transform:none}}@keyframes Toastify__bounceOutRight{20%{opacity:1;transform:translate3d(-20px,var(--y),0)}to{opacity:0;transform:translate3d(2000px,var(--y),0)}}@keyframes Toastify__bounceInLeft{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(-3000px,0,0)}60%{opacity:1;transform:translate3d(25px,0,0)}75%{transform:translate3d(-10px,0,0)}90%{transform:translate3d(5px,0,0)}to{transform:none}}@keyframes Toastify__bounceOutLeft{20%{opacity:1;transform:translate3d(20px,var(--y),0)}to{opacity:0;transform:translate3d(-2000px,var(--y),0)}}@keyframes Toastify__bounceInUp{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(0,3000px,0)}60%{opacity:1;transform:translate3d(0,-20px,0)}75%{transform:translate3d(0,10px,0)}90%{transform:translate3d(0,-5px,0)}to{transform:translateZ(0)}}@keyframes Toastify__bounceOutUp{20%{transform:translate3d(0,calc(var(--y) - 10px),0)}40%,45%{opacity:1;transform:translate3d(0,calc(var(--y) + 20px),0)}to{opacity:0;transform:translate3d(0,-2000px,0)}}@keyframes Toastify__bounceInDown{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(0,-3000px,0)}60%{opacity:1;transform:translate3d(0,25px,0)}75%{transform:translate3d(0,-10px,0)}90%{transform:translate3d(0,5px,0)}to{transform:none}}@keyframes Toastify__bounceOutDown{20%{transform:translate3d(0,calc(var(--y) - 10px),0)}40%,45%{opacity:1;transform:translate3d(0,calc(var(--y) + 20px),0)}to{opacity:0;transform:translate3d(0,2000px,0)}}.Toastify__bounce-enter--top-left,.Toastify__bounce-enter--bottom-left{animation-name:Toastify__bounceInLeft}.Toastify__bounce-enter--top-right,.Toastify__bounce-enter--bottom-right{animation-name:Toastify__bounceInRight}.Toastify__bounce-enter--top-center{animation-name:Toastify__bounceInDown}.Toastify__bounce-enter--bottom-center{animation-name:Toastify__bounceInUp}.Toastify__bounce-exit--top-left,.Toastify__bounce-exit--bottom-left{animation-name:Toastify__bounceOutLeft}.Toastify__bounce-exit--top-right,.Toastify__bounce-exit--bottom-right{animation-name:Toastify__bounceOutRight}.Toastify__bounce-exit--top-center{animation-name:Toastify__bounceOutUp}.Toastify__bounce-exit--bottom-center{animation-name:Toastify__bounceOutDown}@keyframes Toastify__zoomIn{0%{opacity:0;transform:scale3d(.3,.3,.3)}50%{opacity:1}}@keyframes Toastify__zoomOut{0%{opacity:1}50%{opacity:0;transform:translate3d(0,var(--y),0) scale3d(.3,.3,.3)}to{opacity:0}}.Toastify__zoom-enter{animation-name:Toastify__zoomIn}.Toastify__zoom-exit{animation-name:Toastify__zoomOut}@keyframes Toastify__flipIn{0%{transform:perspective(400px) rotateX(90deg);animation-timing-function:ease-in;opacity:0}40%{transform:perspective(400px) rotateX(-20deg);animation-timing-function:ease-in}60%{transform:perspective(400px) rotateX(10deg);opacity:1}80%{transform:perspective(400px) rotateX(-5deg)}to{transform:perspective(400px)}}@keyframes Toastify__flipOut{0%{transform:translate3d(0,var(--y),0) perspective(400px)}30%{transform:translate3d(0,var(--y),0) perspective(400px) rotateX(-20deg);opacity:1}to{transform:translate3d(0,var(--y),0) perspective(400px) rotateX(90deg);opacity:0}}.Toastify__flip-enter{animation-name:Toastify__flipIn}.Toastify__flip-exit{animation-name:Toastify__flipOut}@keyframes Toastify__slideInRight{0%{transform:translate3d(110%,0,0);visibility:visible}to{transform:translate3d(0,var(--y),0)}}@keyframes Toastify__slideInLeft{0%{transform:translate3d(-110%,0,0);visibility:visible}to{transform:translate3d(0,var(--y),0)}}@keyframes Toastify__slideInUp{0%{transform:translate3d(0,110%,0);visibility:visible}to{transform:translate3d(0,var(--y),0)}}@keyframes Toastify__slideInDown{0%{transform:translate3d(0,-110%,0);visibility:visible}to{transform:translate3d(0,var(--y),0)}}@keyframes Toastify__slideOutRight{0%{transform:translate3d(0,var(--y),0)}to{visibility:hidden;transform:translate3d(110%,var(--y),0)}}@keyframes Toastify__slideOutLeft{0%{transform:translate3d(0,var(--y),0)}to{visibility:hidden;transform:translate3d(-110%,var(--y),0)}}@keyframes Toastify__slideOutDown{0%{transform:translate3d(0,var(--y),0)}to{visibility:hidden;transform:translate3d(0,500px,0)}}@keyframes Toastify__slideOutUp{0%{transform:translate3d(0,var(--y),0)}to{visibility:hidden;transform:translate3d(0,-500px,0)}}.Toastify__slide-enter--top-left,.Toastify__slide-enter--bottom-left{animation-name:Toastify__slideInLeft}.Toastify__slide-enter--top-right,.Toastify__slide-enter--bottom-right{animation-name:Toastify__slideInRight}.Toastify__slide-enter--top-center{animation-name:Toastify__slideInDown}.Toastify__slide-enter--bottom-center{animation-name:Toastify__slideInUp}.Toastify__slide-exit--top-left,.Toastify__slide-exit--bottom-left{animation-name:Toastify__slideOutLeft;animation-timing-function:ease-in;animation-duration:.3s}.Toastify__slide-exit--top-right,.Toastify__slide-exit--bottom-right{animation-name:Toastify__slideOutRight;animation-timing-function:ease-in;animation-duration:.3s}.Toastify__slide-exit--top-center{animation-name:Toastify__slideOutUp;animation-timing-function:ease-in;animation-duration:.3s}.Toastify__slide-exit--bottom-center{animation-name:Toastify__slideOutDown;animation-timing-function:ease-in;animation-duration:.3s}@keyframes Toastify__spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}
11
+ `);
12
+ var g = (t) => typeof t == "number" && !isNaN(t), c = (t) => typeof t == "string", k = (t) => typeof t == "function", U = (t) => c(t) || g(t), X = (t) => E(t) || c(t) || k(t) || g(t), D = 1, w = () => `${D++}`, i = /* @__PURE__ */ new Map(), u = [], x = /* @__PURE__ */ new Set(), I = () => i.size > 0, R = (t, { containerId: o }) => {
13
+ var a;
14
+ return (a = i.get(o || 1)) == null ? void 0 : a.toasts.get(t);
15
+ };
16
+ function N(t, o) {
17
+ var a;
18
+ if (o) return !!((a = i.get(o)) != null && a.isToastActive(t));
19
+ let f = !1;
20
+ return i.forEach((s) => {
21
+ s.isToastActive(t) && (f = !0);
22
+ }), f;
23
+ }
24
+ function F(t) {
25
+ if (!I()) {
26
+ u = u.filter((o) => t != null && o.options.toastId !== t);
27
+ return;
28
+ }
29
+ if (t == null || U(t)) i.forEach((o) => {
30
+ o.removeToast(t);
31
+ });
32
+ else if (t && ("containerId" in t || "id" in t)) {
33
+ let o = i.get(t.containerId);
34
+ o ? o.removeToast(t.id) : i.forEach((a) => {
35
+ a.removeToast(t.id);
36
+ });
37
+ }
38
+ }
39
+ var A = (t = {}) => {
40
+ i.forEach((o) => {
41
+ o.props.limit && (!t.containerId || o.id === t.containerId) && o.clearQueue();
42
+ });
43
+ };
44
+ function P(t, o) {
45
+ X(t) && (I() || u.push({ content: t, options: o }), i.forEach((a) => {
46
+ a.buildToast(t, o);
47
+ }));
48
+ }
49
+ function z(t, o) {
50
+ i.forEach((a) => {
51
+ (o == null || !(o != null && o.containerId) || (o == null ? void 0 : o.containerId) === a.id) && a.toggle(t, o == null ? void 0 : o.id);
52
+ });
53
+ }
54
+ function B(t) {
55
+ return x.add(t), () => {
56
+ x.delete(t);
57
+ };
58
+ }
59
+ function Q(t) {
60
+ return t && (c(t.toastId) || g(t.toastId)) ? t.toastId : w();
61
+ }
62
+ function y(t, o) {
63
+ return P(t, o), o.toastId;
64
+ }
65
+ function _(t, o) {
66
+ return { ...o, type: o && o.type || t, toastId: Q(o) };
67
+ }
68
+ function m(t) {
69
+ return (o, a) => y(o, _(t, a));
70
+ }
71
+ function r(t, o) {
72
+ return y(t, _("default", o));
73
+ }
74
+ r.loading = (t, o) => y(t, _("default", { isLoading: !0, autoClose: !1, closeOnClick: !1, closeButton: !1, draggable: !1, ...o }));
75
+ function M(t, { pending: o, error: a, success: f }, s) {
76
+ let e;
77
+ o && (e = c(o) ? r.loading(o, s) : r.loading(o.render, { ...s, ...o }));
78
+ let n = { isLoading: null, autoClose: null, closeOnClick: null, closeButton: null, draggable: null }, b = (l, d, h) => {
79
+ if (d == null) {
80
+ r.dismiss(e);
81
+ return;
82
+ }
83
+ let v = { type: l, ...n, ...s, data: h }, p = c(d) ? { render: d } : d;
84
+ return e ? r.update(e, { ...v, ...p }) : r(p.render, { ...v, ...p }), h;
85
+ }, T = k(t) ? t() : t;
86
+ return T.then((l) => b("success", f, l)).catch((l) => b("error", a, l)), T;
87
+ }
88
+ r.promise = M;
89
+ r.success = m("success");
90
+ r.info = m("info");
91
+ r.error = m("error");
92
+ r.warning = m("warning");
93
+ r.warn = r.warning;
94
+ r.dark = (t, o) => y(t, _("default", { theme: "dark", ...o }));
95
+ function V(t) {
96
+ F(t);
97
+ }
98
+ r.dismiss = V;
99
+ r.clearWaitingQueue = A;
100
+ r.isActive = N;
101
+ r.update = (t, o = {}) => {
102
+ let a = R(t, o);
103
+ if (a) {
104
+ let { props: f, content: s } = a, e = { delay: 100, ...f, ...o, toastId: o.toastId || t, updateId: w() };
105
+ e.toastId !== t && (e.staleId = t);
106
+ let n = e.render || s;
107
+ delete e.render, y(n, e);
108
+ }
109
+ };
110
+ r.done = (t) => {
111
+ r.update(t, { progress: 1 });
112
+ };
113
+ r.onChange = B;
114
+ r.play = (t) => z(!0, t);
115
+ r.pause = (t) => z(!1, t);
116
+ const Z = () => {
117
+ const t = O(), { setAuthToken: o, setUserToken: a } = C();
7
118
  return { FinSesion: () => {
8
- l.promise(
9
- new Promise(async (t, s) => {
119
+ r.promise(
120
+ new Promise(async (s, e) => {
10
121
  try {
11
- const e = localStorage.getItem("access_token");
12
- if (!e)
122
+ const n = localStorage.getItem("access_token");
123
+ if (!n)
13
124
  throw new Error("No se encontró el token de acceso.");
14
- await c(e), localStorage.removeItem("access_token"), localStorage.removeItem("user_token"), n(null), r(null), setTimeout(() => {
15
- t(!0), o("/");
125
+ await S(n), localStorage.removeItem("access_token"), localStorage.removeItem("user_token"), o(null), a(null), setTimeout(() => {
126
+ s(!0), t("/");
16
127
  }, 1e3);
17
- } catch (e) {
18
- s(e);
128
+ } catch (n) {
129
+ e(n);
19
130
  }
20
131
  }),
21
132
  {
@@ -27,5 +138,5 @@ const k = () => {
27
138
  } };
28
139
  };
29
140
  export {
30
- k as useFinalizarSesion
141
+ Z as useFinalizarSesion
31
142
  };
@@ -2,6 +2,3 @@ export { AuthProvider } from './auth/contexts/AuthContex.js';
2
2
  export { ProtectedRoute } from './utils/components/ProtectedRoute.js';
3
3
  export { UserRoute } from './utils/components/UserRoute.js';
4
4
  export { UnpHistorico } from './utils/unp-historico/UnpHistorico.js';
5
- export { WebSocketProvider } from './utils/websocket-manager/WebSocketProvider.js';
6
- export { useWebSocket } from './utils/websocket-manager/useWebSocket.js';
7
- export { WebSocketManager } from './utils/websocket-manager/WebSocketManager.js';
@@ -1,202 +1,201 @@
1
- import { jsx as a, Fragment as x, jsxs as e } from "react/jsx-runtime";
2
- import { useState as o, useEffect as d } from "react";
1
+ import { jsx as a, Fragment as x, jsxs as t } from "react/jsx-runtime";
2
+ import { useState as o, useEffect as h } from "react";
3
3
  import { useNavigate as z } from "react-router-dom";
4
- import { j as h } from "../../index-CuHybtft.js";
5
- import { useFinalizarSesion as f } from "../../auth/hooks/useFinalizarSesion.js";
6
- import { urlBase as I, urlCertificadoLaboral as M } from "../../utils/Url.js";
7
- import { l as k } from "../../logo_escudo_blanco-DaOI8SGq.js";
8
- import { G as t } from "../../iconBase-LROS5hdG.js";
9
- import '../../assets/MenuLateral.css';function w(i) {
10
- return t({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M2 12h2a7.986 7.986 0 0 1 2.337-5.663 7.91 7.91 0 0 1 2.542-1.71 8.12 8.12 0 0 1 6.13-.041A2.488 2.488 0 0 0 17.5 7C18.886 7 20 5.886 20 4.5S18.886 2 17.5 2c-.689 0-1.312.276-1.763.725-2.431-.973-5.223-.958-7.635.059a9.928 9.928 0 0 0-3.18 2.139 9.92 9.92 0 0 0-2.14 3.179A10.005 10.005 0 0 0 2 12zm17.373 3.122c-.401.952-.977 1.808-1.71 2.541s-1.589 1.309-2.542 1.71a8.12 8.12 0 0 1-6.13.041A2.488 2.488 0 0 0 6.5 17C5.114 17 4 18.114 4 19.5S5.114 22 6.5 22c.689 0 1.312-.276 1.763-.725A9.965 9.965 0 0 0 12 22a9.983 9.983 0 0 0 9.217-6.102A9.992 9.992 0 0 0 22 12h-2a7.993 7.993 0 0 1-.627 3.122z" }, child: [] }, { tag: "path", attr: { d: "M12 7.462c-2.502 0-4.538 2.036-4.538 4.538S9.498 16.538 12 16.538s4.538-2.036 4.538-4.538S14.502 7.462 12 7.462zm0 7.076c-1.399 0-2.538-1.139-2.538-2.538S10.601 9.462 12 9.462s2.538 1.139 2.538 2.538-1.139 2.538-2.538 2.538z" }, child: [] }] })(i);
4
+ import { j as d } from "../../index-CuHybtft.js";
5
+ import { useFinalizarSesion as b } from "../../auth/hooks/useFinalizarSesion.js";
6
+ import { urlBase as M, urlCertificadoLaboral as k } from "../../utils/Url.js";
7
+ import { l as B } from "../../logo_escudo_blanco-DaOI8SGq.js";
8
+ import { G as i } from "../../iconBase-LROS5hdG.js";
9
+ import '../../assets/MenuLateral.css';function H(e) {
10
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M2 12h2a7.986 7.986 0 0 1 2.337-5.663 7.91 7.91 0 0 1 2.542-1.71 8.12 8.12 0 0 1 6.13-.041A2.488 2.488 0 0 0 17.5 7C18.886 7 20 5.886 20 4.5S18.886 2 17.5 2c-.689 0-1.312.276-1.763.725-2.431-.973-5.223-.958-7.635.059a9.928 9.928 0 0 0-3.18 2.139 9.92 9.92 0 0 0-2.14 3.179A10.005 10.005 0 0 0 2 12zm17.373 3.122c-.401.952-.977 1.808-1.71 2.541s-1.589 1.309-2.542 1.71a8.12 8.12 0 0 1-6.13.041A2.488 2.488 0 0 0 6.5 17C5.114 17 4 18.114 4 19.5S5.114 22 6.5 22c.689 0 1.312-.276 1.763-.725A9.965 9.965 0 0 0 12 22a9.983 9.983 0 0 0 9.217-6.102A9.992 9.992 0 0 0 22 12h-2a7.993 7.993 0 0 1-.627 3.122z" }, child: [] }, { tag: "path", attr: { d: "M12 7.462c-2.502 0-4.538 2.036-4.538 4.538S9.498 16.538 12 16.538s4.538-2.036 4.538-4.538S14.502 7.462 12 7.462zm0 7.076c-1.399 0-2.538-1.139-2.538-2.538S10.601 9.462 12 9.462s2.538 1.139 2.538 2.538-1.139 2.538-2.538 2.538z" }, child: [] }] })(e);
11
11
  }
12
- function B(i) {
13
- return t({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M19 2H6c-1.206 0-3 .799-3 3v14c0 2.201 1.794 3 3 3h15v-2H6.012C5.55 19.988 5 19.806 5 19s.55-.988 1.012-1H21V4c0-1.103-.897-2-2-2zm0 14H5V5c0-.806.55-.988 1-1h13v12z" }, child: [] }] })(i);
12
+ function C(e) {
13
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M19 2H6c-1.206 0-3 .799-3 3v14c0 2.201 1.794 3 3 3h15v-2H6.012C5.55 19.988 5 19.806 5 19s.55-.988 1.012-1H21V4c0-1.103-.897-2-2-2zm0 14H5V5c0-.806.55-.988 1-1h13v12z" }, child: [] }] })(e);
14
14
  }
15
- function H(i) {
16
- return t({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M20 4H4c-1.103 0-2 .897-2 2v12c0 1.103.897 2 2 2h16c1.103 0 2-.897 2-2V6c0-1.103-.897-2-2-2zm0 2v.511l-8 6.223-8-6.222V6h16zM4 18V9.044l7.386 5.745a.994.994 0 0 0 1.228 0L20 9.044 20.002 18H4z" }, child: [] }] })(i);
15
+ function w(e) {
16
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M20 4H4c-1.103 0-2 .897-2 2v12c0 1.103.897 2 2 2h16c1.103 0 2-.897 2-2V6c0-1.103-.897-2-2-2zm0 2v.511l-8 6.223-8-6.222V6h16zM4 18V9.044l7.386 5.745a.994.994 0 0 0 1.228 0L20 9.044 20.002 18H4z" }, child: [] }] })(e);
17
17
  }
18
- function V(i) {
19
- return t({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M11.953 2C6.465 2 2 6.486 2 12s4.486 10 10 10 10-4.486 10-10S17.493 2 11.953 2zM12 20c-4.411 0-8-3.589-8-8s3.567-8 7.953-8C16.391 4 20 7.589 20 12s-3.589 8-8 8z" }, child: [] }, { tag: "path", attr: { d: "M11 7h2v7h-2zm0 8h2v2h-2z" }, child: [] }] })(i);
18
+ function _(e) {
19
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M11.953 2C6.465 2 2 6.486 2 12s4.486 10 10 10 10-4.486 10-10S17.493 2 11.953 2zM12 20c-4.411 0-8-3.589-8-8s3.567-8 7.953-8C16.391 4 20 7.589 20 12s-3.589 8-8 8z" }, child: [] }, { tag: "path", attr: { d: "M11 7h2v7h-2zm0 8h2v2h-2z" }, child: [] }] })(e);
20
20
  }
21
- function Z(i) {
22
- return t({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M19.903 8.586a.997.997 0 0 0-.196-.293l-6-6a.997.997 0 0 0-.293-.196c-.03-.014-.062-.022-.094-.033a.991.991 0 0 0-.259-.051C13.04 2.011 13.021 2 13 2H6c-1.103 0-2 .897-2 2v16c0 1.103.897 2 2 2h12c1.103 0 2-.897 2-2V9c0-.021-.011-.04-.013-.062a.952.952 0 0 0-.051-.259c-.01-.032-.019-.063-.033-.093zM16.586 8H14V5.414L16.586 8zM6 20V4h6v5a1 1 0 0 0 1 1h5l.002 10H6z" }, child: [] }, { tag: "path", attr: { d: "M8 12h8v2H8zm0 4h8v2H8zm0-8h2v2H8z" }, child: [] }] })(i);
21
+ function A(e) {
22
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M19.903 8.586a.997.997 0 0 0-.196-.293l-6-6a.997.997 0 0 0-.293-.196c-.03-.014-.062-.022-.094-.033a.991.991 0 0 0-.259-.051C13.04 2.011 13.021 2 13 2H6c-1.103 0-2 .897-2 2v16c0 1.103.897 2 2 2h12c1.103 0 2-.897 2-2V9c0-.021-.011-.04-.013-.062a.952.952 0 0 0-.051-.259c-.01-.032-.019-.063-.033-.093zM16.586 8H14V5.414L16.586 8zM6 20V4h6v5a1 1 0 0 0 1 1h5l.002 10H6z" }, child: [] }, { tag: "path", attr: { d: "M8 12h8v2H8zm0 4h8v2H8zm0-8h2v2H8z" }, child: [] }] })(e);
23
23
  }
24
- function j(i) {
25
- return t({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M3 13h1v7c0 1.103.897 2 2 2h12c1.103 0 2-.897 2-2v-7h1a1 1 0 0 0 .707-1.707l-9-9a.999.999 0 0 0-1.414 0l-9 9A1 1 0 0 0 3 13zm7 7v-5h4v5h-4zm2-15.586 6 6V15l.001 5H16v-5c0-1.103-.897-2-2-2h-4c-1.103 0-2 .897-2 2v5H6v-9.586l6-6z" }, child: [] }] })(i);
24
+ function S(e) {
25
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M3 13h1v7c0 1.103.897 2 2 2h12c1.103 0 2-.897 2-2v-7h1a1 1 0 0 0 .707-1.707l-9-9a.999.999 0 0 0-1.414 0l-9 9A1 1 0 0 0 3 13zm7 7v-5h4v5h-4zm2-15.586 6 6V15l.001 5H16v-5c0-1.103-.897-2-2-2h-4c-1.103 0-2 .897-2 2v5H6v-9.586l6-6z" }, child: [] }] })(e);
26
26
  }
27
- function C(i) {
28
- return t({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M4.222 19.778a4.983 4.983 0 0 0 3.535 1.462 4.986 4.986 0 0 0 3.536-1.462l2.828-2.829-1.414-1.414-2.828 2.829a3.007 3.007 0 0 1-4.243 0 3.005 3.005 0 0 1 0-4.243l2.829-2.828-1.414-1.414-2.829 2.828a5.006 5.006 0 0 0 0 7.071zm15.556-8.485a5.008 5.008 0 0 0 0-7.071 5.006 5.006 0 0 0-7.071 0L9.879 7.051l1.414 1.414 2.828-2.829a3.007 3.007 0 0 1 4.243 0 3.005 3.005 0 0 1 0 4.243l-2.829 2.828 1.414 1.414 2.829-2.828z" }, child: [] }, { tag: "path", attr: { d: "m8.464 16.95-1.415-1.414 8.487-8.486 1.414 1.415z" }, child: [] }] })(i);
27
+ function V(e) {
28
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M4.222 19.778a4.983 4.983 0 0 0 3.535 1.462 4.986 4.986 0 0 0 3.536-1.462l2.828-2.829-1.414-1.414-2.828 2.829a3.007 3.007 0 0 1-4.243 0 3.005 3.005 0 0 1 0-4.243l2.829-2.828-1.414-1.414-2.829 2.828a5.006 5.006 0 0 0 0 7.071zm15.556-8.485a5.008 5.008 0 0 0 0-7.071 5.006 5.006 0 0 0-7.071 0L9.879 7.051l1.414 1.414 2.828-2.829a3.007 3.007 0 0 1 4.243 0 3.005 3.005 0 0 1 0 4.243l-2.829 2.828 1.414 1.414 2.829-2.828z" }, child: [] }, { tag: "path", attr: { d: "m8.464 16.95-1.415-1.414 8.487-8.486 1.414 1.415z" }, child: [] }] })(e);
29
29
  }
30
- function S(i) {
31
- return t({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M16 13v-2H7V8l-5 4 5 4v-3z" }, child: [] }, { tag: "path", attr: { d: "M20 3h-9c-1.103 0-2 .897-2 2v4h2V5h9v14h-9v-4H9v4c0 1.103.897 2 2 2h9c1.103 0 2-.897 2-2V5c0-1.103-.897-2-2-2z" }, child: [] }] })(i);
30
+ function L(e) {
31
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M16 13v-2H7V8l-5 4 5 4v-3z" }, child: [] }, { tag: "path", attr: { d: "M20 3h-9c-1.103 0-2 .897-2 2v4h2V5h9v14h-9v-4H9v4c0 1.103.897 2 2 2h9c1.103 0 2-.897 2-2V5c0-1.103-.897-2-2-2z" }, child: [] }] })(e);
32
32
  }
33
- function Y(i) {
34
- return t({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "m12 17 1-2V9.858c1.721-.447 3-2 3-3.858 0-2.206-1.794-4-4-4S8 3.794 8 6c0 1.858 1.279 3.411 3 3.858V15l1 2zM10 6c0-1.103.897-2 2-2s2 .897 2 2-.897 2-2 2-2-.897-2-2z" }, child: [] }, { tag: "path", attr: { d: "m16.267 10.563-.533 1.928C18.325 13.207 20 14.584 20 16c0 1.892-3.285 4-8 4s-8-2.108-8-4c0-1.416 1.675-2.793 4.267-3.51l-.533-1.928C4.197 11.54 2 13.623 2 16c0 3.364 4.393 6 10 6s10-2.636 10-6c0-2.377-2.197-4.46-5.733-5.437z" }, child: [] }] })(i);
33
+ function P(e) {
34
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "m12 17 1-2V9.858c1.721-.447 3-2 3-3.858 0-2.206-1.794-4-4-4S8 3.794 8 6c0 1.858 1.279 3.411 3 3.858V15l1 2zM10 6c0-1.103.897-2 2-2s2 .897 2 2-.897 2-2 2-2-.897-2-2z" }, child: [] }, { tag: "path", attr: { d: "m16.267 10.563-.533 1.928C18.325 13.207 20 14.584 20 16c0 1.892-3.285 4-8 4s-8-2.108-8-4c0-1.416 1.675-2.793 4.267-3.51l-.533-1.928C4.197 11.54 2 13.623 2 16c0 3.364 4.393 6 10 6s10-2.636 10-6c0-2.377-2.197-4.46-5.733-5.437z" }, child: [] }] })(e);
35
35
  }
36
- function A(i) {
37
- return t({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M4 6h16v2H4zm4 5h12v2H8zm5 5h7v2h-7z" }, child: [] }] })(i);
36
+ function T(e) {
37
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M4 6h16v2H4zm4 5h12v2H8zm5 5h7v2h-7z" }, child: [] }] })(e);
38
38
  }
39
- function J(i) {
40
- return t({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M4 6h16v2H4zm0 5h16v2H4zm0 5h16v2H4z" }, child: [] }] })(i);
39
+ function y(e) {
40
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M4 6h16v2H4zm0 5h16v2H4zm0 5h16v2H4z" }, child: [] }] })(e);
41
41
  }
42
- function L(i) {
43
- return t({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M11.63 21.91A.9.9 0 0 0 12 22a1 1 0 0 0 .41-.09C22 17.67 21 7 21 6.9a1 1 0 0 0-.55-.79l-8-4a1 1 0 0 0-.9 0l-8 4A1 1 0 0 0 3 6.9c0 .1-.92 10.77 8.63 15.01zM5 7.63l7-3.51 7 3.51c.05 2-.27 9-7 12.27C5.26 16.63 4.94 9.64 5 7.63z" }, child: [] }, { tag: "path", attr: { d: "M11.06 16h2v-3h3.01v-2h-3.01V8h-2v3h-3v2h3v3z" }, child: [] }] })(i);
42
+ function I(e) {
43
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M11.63 21.91A.9.9 0 0 0 12 22a1 1 0 0 0 .41-.09C22 17.67 21 7 21 6.9a1 1 0 0 0-.55-.79l-8-4a1 1 0 0 0-.9 0l-8 4A1 1 0 0 0 3 6.9c0 .1-.92 10.77 8.63 15.01zM5 7.63l7-3.51 7 3.51c.05 2-.27 9-7 12.27C5.26 16.63 4.94 9.64 5 7.63z" }, child: [] }, { tag: "path", attr: { d: "M11.06 16h2v-3h3.01v-2h-3.01V8h-2v3h-3v2h3v3z" }, child: [] }] })(e);
44
44
  }
45
- function y(i) {
46
- return t({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M3.414 13.778 2 15.192l4.949 2.121 2.122 4.95 1.414-1.414-.707-3.536L13.091 14l3.61 7.704 1.339-1.339-1.19-10.123 2.828-2.829a2 2 0 1 0-2.828-2.828l-2.903 2.903L3.824 6.297 2.559 7.563l7.644 3.67-3.253 3.253-3.536-.708z" }, child: [] }] })(i);
45
+ function j(e) {
46
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M3.414 13.778 2 15.192l4.949 2.121 2.122 4.95 1.414-1.414-.707-3.536L13.091 14l3.61 7.704 1.339-1.339-1.19-10.123 2.828-2.829a2 2 0 1 0-2.828-2.828l-2.903 2.903L3.824 6.297 2.559 7.563l7.644 3.67-3.253 3.253-3.536-.708z" }, child: [] }] })(e);
47
47
  }
48
- function _(i) {
49
- return t({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M15.661 15.549a1.315 1.315 0 0 0 1.185-1.386 1.363 1.363 0 0 0-1.35-1.302h-.048a1.352 1.352 0 0 0-1.303 1.397c.024.379.179.687.391.911-.827 1.609-2.07 2.794-3.954 3.788-1.266.663-2.604.912-3.905.734-1.089-.153-1.94-.64-2.463-1.421-.78-1.185-.852-2.462-.201-3.74a5.597 5.597 0 0 1 1.658-1.931 7.88 7.88 0 0 1-.331-1.218c-3.506 2.51-3.148 5.942-2.084 7.564.794 1.184 2.415 1.941 4.19 1.941.474 0 .972-.035 1.457-.154 3.077-.592 5.409-2.438 6.747-5.16l.011-.023z" }, child: [] }, { tag: "path", attr: { d: "M19.887 12.589c-1.834-2.154-4.533-3.337-7.611-3.337h-.403c-.2-.438-.661-.711-1.183-.711h-.036c-.744 0-1.325.64-1.301 1.385.023.71.627 1.302 1.35 1.302h.059a1.332 1.332 0 0 0 1.183-.828h.439c1.824 0 3.551.532 5.126 1.574 1.206.792 2.072 1.834 2.557 3.077.425 1.019.402 2.013-.035 2.843-.675 1.302-1.812 1.988-3.314 1.988-.947 0-1.871-.296-2.345-.509-.283.235-.758.626-1.102.863 1.042.473 2.096.746 3.113.746 2.309 0 4.023-1.302 4.676-2.557.709-1.422.651-3.813-1.161-5.859l-.012.023z" }, child: [] }, { tag: "path", attr: { d: "M7.647 15.975c.023.71.626 1.302 1.35 1.302h.048a1.334 1.334 0 0 0 1.302-1.397c0-.71-.616-1.301-1.338-1.301h-.048c-.048 0-.118 0-.178.022-.982-1.657-1.397-3.434-1.242-5.349.094-1.445.567-2.7 1.42-3.742.71-.888 2.048-1.326 2.96-1.35 2.556-.048 3.622 3.138 3.704 4.404l1.184.354C16.536 5.036 14.122 3 11.813 3 9.647 3 7.647 4.574 6.842 6.884c-1.102 3.077-.379 6.036.971 8.404-.118.154-.189.426-.166.687z" }, child: [] }] })(i);
48
+ function E(e) {
49
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M15.661 15.549a1.315 1.315 0 0 0 1.185-1.386 1.363 1.363 0 0 0-1.35-1.302h-.048a1.352 1.352 0 0 0-1.303 1.397c.024.379.179.687.391.911-.827 1.609-2.07 2.794-3.954 3.788-1.266.663-2.604.912-3.905.734-1.089-.153-1.94-.64-2.463-1.421-.78-1.185-.852-2.462-.201-3.74a5.597 5.597 0 0 1 1.658-1.931 7.88 7.88 0 0 1-.331-1.218c-3.506 2.51-3.148 5.942-2.084 7.564.794 1.184 2.415 1.941 4.19 1.941.474 0 .972-.035 1.457-.154 3.077-.592 5.409-2.438 6.747-5.16l.011-.023z" }, child: [] }, { tag: "path", attr: { d: "M19.887 12.589c-1.834-2.154-4.533-3.337-7.611-3.337h-.403c-.2-.438-.661-.711-1.183-.711h-.036c-.744 0-1.325.64-1.301 1.385.023.71.627 1.302 1.35 1.302h.059a1.332 1.332 0 0 0 1.183-.828h.439c1.824 0 3.551.532 5.126 1.574 1.206.792 2.072 1.834 2.557 3.077.425 1.019.402 2.013-.035 2.843-.675 1.302-1.812 1.988-3.314 1.988-.947 0-1.871-.296-2.345-.509-.283.235-.758.626-1.102.863 1.042.473 2.096.746 3.113.746 2.309 0 4.023-1.302 4.676-2.557.709-1.422.651-3.813-1.161-5.859l-.012.023z" }, child: [] }, { tag: "path", attr: { d: "M7.647 15.975c.023.71.626 1.302 1.35 1.302h.048a1.334 1.334 0 0 0 1.302-1.397c0-.71-.616-1.301-1.338-1.301h-.048c-.048 0-.118 0-.178.022-.982-1.657-1.397-3.434-1.242-5.349.094-1.445.567-2.7 1.42-3.742.71-.888 2.048-1.326 2.96-1.35 2.556-.048 3.622 3.138 3.704 4.404l1.184.354C16.536 5.036 14.122 3 11.813 3 9.647 3 7.647 4.574 6.842 6.884c-1.102 3.077-.379 6.036.971 8.404-.118.154-.189.426-.166.687z" }, child: [] }] })(e);
50
50
  }
51
- const O = ({ onToggle: i, isOpen: n }) => {
52
- const [m, p] = o(!0), [s, r] = o(null), g = n ? "sidebar-bar-panel open" : "sidebar-bar-panel", v = z(), { FinSesion: u } = f();
53
- if (d(() => {
54
- sessionStorage.setItem("user_token", '"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJkYXRvc19iYXNpY29zIjp7InVzZXJuYW1lIjoiZGFuaWVsLm1vbnRpZWwiLCJub21icmUiOiJEYW5pZWwgQWxlamFuZHJvIE1vbnRpZWwgUm9kcmlndWV6IiwiaWRfYnVzdWFyaW8iOiIyNjQxYjg1YS1lYmE1LTRhMjEtYmFkOS03NWY0NDVjNTAxYjkiLCJkZXBlbmRlbmNpYSI6IlN1YmRpcmVjY2lcdTAwZjNuIEVzcGVjaWFsaXphZGEgZGUgU2VndXJpZGFkIHkgUHJvdGVjY2lcdTAwZjNuIiwiZ3J1cG8iOiJHcnVwbyBkZSBSZWNlcGNpXHUwMGYzbiwgQW5cdTAwZTFsaXNpcywgZXZhbHVhY2lcdTAwZjNuIGRlIHJpZXNnb3MgeSByZWNvbWVuZGFjaW9uZXMiLCJyb2xlcyI6WyJSZXBhcnRpZG9yIHBvYmxhY2lvbmFsIl0sInJ1dGFzIjpbInNlc3AvZ3JhZXJyL3JlcGFydGlkb3IiXX0sImFkZHJlc3MiOiIxMjcuMC4wLjEiLCJ0eXBlIjoiZGF0YSIsInVzZXJfdHlwZSI6ImludGVybiIsInRva2VuX2lkIjoiMDg5NWE1MzgtNjU4NS00MjlkLTg3YTktY2ViZDY2Y2I0YzJmIiwiaWF0IjoxNzQ1ODYyOTIzLCJleHAiOjE3NDU4NjY1MjN9.uY4otFv-rYIndo6fSKFbD0gXIIGe0xNxtZi-RA6tFnk"');
51
+ const J = ({ onToggle: e, isOpen: n }) => {
52
+ const [m, p] = o(!0), [r, s] = o(null), v = n ? "sidebar-bar-panel open" : "sidebar-bar-panel", g = z(), { FinSesion: u } = b();
53
+ if (h(() => {
55
54
  const l = sessionStorage.getItem("user_token");
56
55
  if (l) {
57
- const c = h(l);
58
- r(c);
56
+ const c = d(l);
57
+ s(c);
59
58
  }
60
59
  p(!1);
61
- }, []), d(() => {
60
+ }, []), h(() => {
62
61
  const l = setTimeout(() => {
63
62
  const c = sessionStorage.getItem("user_token");
64
63
  if (c) {
65
- const b = h(c);
66
- r(b);
64
+ const f = d(c);
65
+ s(f);
67
66
  }
68
67
  }, 2e3);
69
68
  return () => clearTimeout(l);
70
69
  }, []), m)
71
70
  return /* @__PURE__ */ a(x, {});
72
71
  const N = () => {
73
- v("/unp/ecosistema/usuario");
72
+ g("/unp/ecosistema/usuario");
74
73
  };
75
- return /* @__PURE__ */ a("div", { className: `container-fluid ${n ? "menu-open" : ""}`, children: /* @__PURE__ */ e("div", { className: g, children: [
76
- /* @__PURE__ */ e("div", { className: "logo_details", children: [
74
+ return /* @__PURE__ */ a("div", { className: `container-fluid ${n ? "menu-open" : ""}`, children: /* @__PURE__ */ t("div", { className: v, children: [
75
+ /* @__PURE__ */ t("div", { className: "logo_details", children: [
77
76
  /* @__PURE__ */ a(
78
77
  "img",
79
78
  {
80
- src: k,
79
+ src: B,
81
80
  alt: "Logo",
82
81
  className: "icon logo-image"
83
82
  }
84
83
  ),
85
84
  /* @__PURE__ */ a("div", { className: "logo-name", children: "EI - UNP" }),
86
85
  n ? /* @__PURE__ */ a(
87
- A,
86
+ T,
88
87
  {
89
88
  className: "bx bx-menu i",
90
89
  id: "btn",
91
- onClick: i
90
+ onClick: e
92
91
  }
93
- ) : /* @__PURE__ */ a(J, { className: "bx bx-menu i", id: "btn", onClick: i })
92
+ ) : /* @__PURE__ */ a(y, { className: "bx bx-menu i", id: "btn", onClick: e })
94
93
  ] }),
95
- /* @__PURE__ */ e("ul", { className: "nav-list-panel", children: [
96
- /* @__PURE__ */ e("li", { children: [
97
- /* @__PURE__ */ e("a", { href: "", children: [
98
- /* @__PURE__ */ a(j, { className: "bx bx-home i2" }),
94
+ /* @__PURE__ */ t("ul", { className: "nav-list-panel", children: [
95
+ /* @__PURE__ */ t("li", { children: [
96
+ /* @__PURE__ */ t("a", { href: "", children: [
97
+ /* @__PURE__ */ a(S, { className: "bx bx-home i2" }),
99
98
  /* @__PURE__ */ a("span", { className: "link_name", children: "Inicio" })
100
99
  ] }),
101
100
  /* @__PURE__ */ a("span", { className: "tooltip", children: "Inicio" })
102
101
  ] }),
103
- /* @__PURE__ */ e("li", { children: [
104
- /* @__PURE__ */ e("a", { href: "", children: [
105
- /* @__PURE__ */ a(Y, { className: "bx bx-map-pin i2" }),
102
+ /* @__PURE__ */ t("li", { children: [
103
+ /* @__PURE__ */ t("a", { href: "", children: [
104
+ /* @__PURE__ */ a(P, { className: "bx bx-map-pin i2" }),
106
105
  /* @__PURE__ */ a("span", { className: "link_name", children: "Mapa del proceso" })
107
106
  ] }),
108
107
  /* @__PURE__ */ a("span", { className: "tooltip", children: "Mapa del proceso" })
109
108
  ] }),
110
- /* @__PURE__ */ e("li", { children: [
111
- /* @__PURE__ */ e("a", { href: "", children: [
112
- /* @__PURE__ */ a(B, { className: "bx bx-book-alt i2" }),
109
+ /* @__PURE__ */ t("li", { children: [
110
+ /* @__PURE__ */ t("a", { href: "", children: [
111
+ /* @__PURE__ */ a(C, { className: "bx bx-book-alt i2" }),
113
112
  /* @__PURE__ */ a("span", { className: "link_name", children: "Manuales de usuario" })
114
113
  ] }),
115
114
  /* @__PURE__ */ a("span", { className: "tooltip", children: "Manual de usuario" })
116
115
  ] }),
117
116
  /* @__PURE__ */ a("div", { style: { paddingLeft: "15px", paddingRight: "15px" }, children: /* @__PURE__ */ a("hr", { style: { borderTop: "1px solid white" } }) }),
118
- /* @__PURE__ */ e("li", { children: [
119
- /* @__PURE__ */ e("a", { href: "https://www.unp.gov.co/", target: "_blank", children: [
120
- /* @__PURE__ */ a(C, { className: "bx bx-link-alt i2" }),
117
+ /* @__PURE__ */ t("li", { children: [
118
+ /* @__PURE__ */ t("a", { href: "https://www.unp.gov.co/", target: "_blank", children: [
119
+ /* @__PURE__ */ a(V, { className: "bx bx-link-alt i2" }),
121
120
  /* @__PURE__ */ a("span", { className: "link_name", children: "Portal UNP" })
122
121
  ] }),
123
122
  /* @__PURE__ */ a("span", { className: "tooltip", children: "Portal UNP" })
124
123
  ] }),
125
- /* @__PURE__ */ e("li", { children: [
126
- /* @__PURE__ */ e(
124
+ /* @__PURE__ */ t("li", { children: [
125
+ /* @__PURE__ */ t(
127
126
  "a",
128
127
  {
129
128
  href: "https://login.microsoftonline.com/common/oauth2/authorize?client_id=00000002-0000-0ff1-ce00-000000000000",
130
129
  target: "_blank",
131
130
  children: [
132
- /* @__PURE__ */ a(H, { className: "bx bx-envelope i2" }),
131
+ /* @__PURE__ */ a(w, { className: "bx bx-envelope i2" }),
133
132
  /* @__PURE__ */ a("span", { className: "link_name", children: "Correo institucional" })
134
133
  ]
135
134
  }
136
135
  ),
137
136
  /* @__PURE__ */ a("span", { className: "tooltip", children: "Correo institucional" })
138
137
  ] }),
139
- /* @__PURE__ */ e("li", { children: [
140
- /* @__PURE__ */ e("a", { href: "http://intranet.unp.gov.co/", target: "_blank", children: [
141
- /* @__PURE__ */ a(_, { className: "bx bxl-redux i2" }),
138
+ /* @__PURE__ */ t("li", { children: [
139
+ /* @__PURE__ */ t("a", { href: "http://intranet.unp.gov.co/", target: "_blank", children: [
140
+ /* @__PURE__ */ a(E, { className: "bx bxl-redux i2" }),
142
141
  /* @__PURE__ */ a("span", { className: "link_name", children: "Acceso directo a Intranet" })
143
142
  ] }),
144
143
  /* @__PURE__ */ a("span", { className: "tooltip", children: "Acceso directo a Intranet" })
145
144
  ] }),
146
- /* @__PURE__ */ e("li", { children: [
147
- /* @__PURE__ */ e("a", { href: "https://mesadeservicios.unp.gov.co/HEAT/", target: "_blank", children: [
148
- /* @__PURE__ */ a(V, { className: "bx bx-error-circle i2" }),
145
+ /* @__PURE__ */ t("li", { children: [
146
+ /* @__PURE__ */ t("a", { href: "https://mesadeservicios.unp.gov.co/HEAT/", target: "_blank", children: [
147
+ /* @__PURE__ */ a(_, { className: "bx bx-error-circle i2" }),
149
148
  /* @__PURE__ */ a("span", { className: "link_name", children: "Mesa de servicios" })
150
149
  ] }),
151
150
  /* @__PURE__ */ a("span", { className: "tooltip", children: "Mesa de servicios" })
152
151
  ] }),
153
152
  /* @__PURE__ */ a("div", { style: { paddingLeft: "15px", paddingRight: "15px" }, children: /* @__PURE__ */ a("hr", { style: { borderTop: "1px solid white" } }) }),
154
- /* @__PURE__ */ e("li", { children: [
155
- /* @__PURE__ */ e("a", { href: "", children: [
156
- /* @__PURE__ */ a(L, { className: "bx i2" }),
153
+ /* @__PURE__ */ t("li", { children: [
154
+ /* @__PURE__ */ t("a", { href: "", children: [
155
+ /* @__PURE__ */ a(I, { className: "bx i2" }),
157
156
  /* @__PURE__ */ a("span", { className: "link_name", children: "Medida de emergencia" })
158
157
  ] }),
159
158
  /* @__PURE__ */ a("span", { className: "tooltip", children: "Medida de emergencia" })
160
159
  ] }),
161
- /* @__PURE__ */ e("li", { children: [
162
- /* @__PURE__ */ e("a", { href: "", children: [
163
- /* @__PURE__ */ a(w, { className: "bx i2" }),
160
+ /* @__PURE__ */ t("li", { children: [
161
+ /* @__PURE__ */ t("a", { href: "", children: [
162
+ /* @__PURE__ */ a(H, { className: "bx i2" }),
164
163
  /* @__PURE__ */ a("span", { className: "link_name", children: "Acta de reunión" })
165
164
  ] }),
166
165
  /* @__PURE__ */ a("span", { className: "tooltip", children: "Acta de reunión" })
167
166
  ] }),
168
- /* @__PURE__ */ e("li", { children: [
169
- /* @__PURE__ */ e("a", { href: "", children: [
170
- /* @__PURE__ */ a(y, { className: "bx i2" }),
167
+ /* @__PURE__ */ t("li", { children: [
168
+ /* @__PURE__ */ t("a", { href: "", children: [
169
+ /* @__PURE__ */ a(j, { className: "bx i2" }),
171
170
  /* @__PURE__ */ a("span", { className: "link_name", children: "Solicitud de viáticos" })
172
171
  ] }),
173
172
  /* @__PURE__ */ a("span", { className: "tooltip", children: "Solicitud de viáticos" })
174
173
  ] }),
175
- /* @__PURE__ */ e("li", { children: [
176
- /* @__PURE__ */ e("a", { href: `${I}${M}`, target: "_blank", children: [
177
- /* @__PURE__ */ a(Z, { className: "bx i2" }),
174
+ /* @__PURE__ */ t("li", { children: [
175
+ /* @__PURE__ */ t("a", { href: `${M}${k}`, target: "_blank", children: [
176
+ /* @__PURE__ */ a(A, { className: "bx i2" }),
178
177
  /* @__PURE__ */ a("span", { className: "link_name", children: "Certificados laborales (OPS)" })
179
178
  ] }),
180
179
  /* @__PURE__ */ a("span", { className: "tooltip", children: "Certificados laborales (OPS)" })
181
180
  ] })
182
181
  ] }),
183
- /* @__PURE__ */ a("div", { className: "profile-content", children: /* @__PURE__ */ e("div", { className: "profile", children: [
182
+ /* @__PURE__ */ a("div", { className: "profile-content", children: /* @__PURE__ */ t("div", { className: "profile", children: [
184
183
  /* @__PURE__ */ a(
185
184
  "div",
186
185
  {
187
186
  className: "profile-detail",
188
187
  onClick: N,
189
188
  style: { cursor: "pointer" },
190
- children: s && /* @__PURE__ */ e("div", { className: "name-job", style: { marginTop: "3px" }, children: [
191
- /* @__PURE__ */ a("div", { className: "name text-truncate", style: { width: "200px" }, children: s.datos_basicos.nombre }),
189
+ children: r && /* @__PURE__ */ t("div", { className: "name-job", style: { marginTop: "3px" }, children: [
190
+ /* @__PURE__ */ a("div", { className: "name text-truncate", style: { width: "200px" }, children: r.datos_basicos.nombre }),
192
191
  /* @__PURE__ */ a("div", { className: "job" })
193
192
  ] })
194
193
  }
195
194
  ),
196
- /* @__PURE__ */ a(S, { className: "icon", onClick: u })
195
+ /* @__PURE__ */ a(L, { className: "icon", onClick: u })
197
196
  ] }) })
198
197
  ] }) });
199
198
  };
200
199
  export {
201
- O as MenuLateral
200
+ J as MenuLateral
202
201
  };
package/dist/utils.js CHANGED
@@ -1,16 +1,10 @@
1
- import { AuthProvider as r } from "./auth/contexts/AuthContex.js";
1
+ import { AuthProvider as e } from "./auth/contexts/AuthContex.js";
2
2
  import { ProtectedRoute as p } from "./utils/components/ProtectedRoute.js";
3
3
  import { UserRoute as m } from "./utils/components/UserRoute.js";
4
- import { UnpHistorico as c } from "./utils/unp-historico/UnpHistorico.js";
5
- import { WebSocketProvider as u } from "./utils/websocket-manager/WebSocketProvider.js";
6
- import { useWebSocket as d } from "./utils/websocket-manager/useWebSocket.js";
7
- import { WebSocketManager as s } from "./utils/websocket-manager/WebSocketManager.js";
4
+ import { UnpHistorico as i } from "./utils/unp-historico/UnpHistorico.js";
8
5
  export {
9
- r as AuthProvider,
6
+ e as AuthProvider,
10
7
  p as ProtectedRoute,
11
- c as UnpHistorico,
12
- m as UserRoute,
13
- s as WebSocketManager,
14
- u as WebSocketProvider,
15
- d as useWebSocket
8
+ i as UnpHistorico,
9
+ m as UserRoute
16
10
  };
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": "1.3.0-pre-release.8",
5
+ "version": "1.3.0",
6
6
  "type": "module",
7
7
  "exports": {
8
8
  ".": {
@@ -1 +0,0 @@
1
- :root{--toastify-color-light: #fff;--toastify-color-dark: #121212;--toastify-color-info: #3498db;--toastify-color-success: #07bc0c;--toastify-color-warning: #f1c40f;--toastify-color-error: hsl(6, 78%, 57%);--toastify-color-transparent: rgba(255, 255, 255, .7);--toastify-icon-color-info: var(--toastify-color-info);--toastify-icon-color-success: var(--toastify-color-success);--toastify-icon-color-warning: var(--toastify-color-warning);--toastify-icon-color-error: var(--toastify-color-error);--toastify-container-width: fit-content;--toastify-toast-width: 320px;--toastify-toast-offset: 16px;--toastify-toast-top: max(var(--toastify-toast-offset), env(safe-area-inset-top));--toastify-toast-right: max(var(--toastify-toast-offset), env(safe-area-inset-right));--toastify-toast-left: max(var(--toastify-toast-offset), env(safe-area-inset-left));--toastify-toast-bottom: max(var(--toastify-toast-offset), env(safe-area-inset-bottom));--toastify-toast-background: #fff;--toastify-toast-padding: 14px;--toastify-toast-min-height: 64px;--toastify-toast-max-height: 800px;--toastify-toast-bd-radius: 6px;--toastify-toast-shadow: 0px 4px 12px rgba(0, 0, 0, .1);--toastify-font-family: sans-serif;--toastify-z-index: 9999;--toastify-text-color-light: #757575;--toastify-text-color-dark: #fff;--toastify-text-color-info: #fff;--toastify-text-color-success: #fff;--toastify-text-color-warning: #fff;--toastify-text-color-error: #fff;--toastify-spinner-color: #616161;--toastify-spinner-color-empty-area: #e0e0e0;--toastify-color-progress-light: linear-gradient(to right, #4cd964, #5ac8fa, #007aff, #34aadc, #5856d6, #ff2d55);--toastify-color-progress-dark: #bb86fc;--toastify-color-progress-info: var(--toastify-color-info);--toastify-color-progress-success: var(--toastify-color-success);--toastify-color-progress-warning: var(--toastify-color-warning);--toastify-color-progress-error: var(--toastify-color-error);--toastify-color-progress-bgo: .2}.Toastify__toast-container{z-index:var(--toastify-z-index);-webkit-transform:translate3d(0,0,var(--toastify-z-index));position:fixed;width:var(--toastify-container-width);box-sizing:border-box;color:#fff;display:flex;flex-direction:column}.Toastify__toast-container--top-left{top:var(--toastify-toast-top);left:var(--toastify-toast-left)}.Toastify__toast-container--top-center{top:var(--toastify-toast-top);left:50%;transform:translate(-50%);align-items:center}.Toastify__toast-container--top-right{top:var(--toastify-toast-top);right:var(--toastify-toast-right);align-items:end}.Toastify__toast-container--bottom-left{bottom:var(--toastify-toast-bottom);left:var(--toastify-toast-left)}.Toastify__toast-container--bottom-center{bottom:var(--toastify-toast-bottom);left:50%;transform:translate(-50%);align-items:center}.Toastify__toast-container--bottom-right{bottom:var(--toastify-toast-bottom);right:var(--toastify-toast-right);align-items:end}.Toastify__toast{--y: 0;position:relative;touch-action:none;width:var(--toastify-toast-width);min-height:var(--toastify-toast-min-height);box-sizing:border-box;margin-bottom:1rem;padding:var(--toastify-toast-padding);border-radius:var(--toastify-toast-bd-radius);box-shadow:var(--toastify-toast-shadow);max-height:var(--toastify-toast-max-height);font-family:var(--toastify-font-family);z-index:0;display:flex;flex:1 auto;align-items:center;word-break:break-word}@media only screen and (max-width: 480px){.Toastify__toast-container{width:100vw;left:env(safe-area-inset-left);margin:0}.Toastify__toast-container--top-left,.Toastify__toast-container--top-center,.Toastify__toast-container--top-right{top:env(safe-area-inset-top);transform:translate(0)}.Toastify__toast-container--bottom-left,.Toastify__toast-container--bottom-center,.Toastify__toast-container--bottom-right{bottom:env(safe-area-inset-bottom);transform:translate(0)}.Toastify__toast-container--rtl{right:env(safe-area-inset-right);left:initial}.Toastify__toast{--toastify-toast-width: 100%;margin-bottom:0;border-radius:0}}.Toastify__toast-container[data-stacked=true]{width:var(--toastify-toast-width)}.Toastify__toast--stacked{position:absolute;width:100%;transform:translate3d(0,var(--y),0) scale(var(--s));transition:transform .3s}.Toastify__toast--stacked[data-collapsed] .Toastify__toast-body,.Toastify__toast--stacked[data-collapsed] .Toastify__close-button{transition:opacity .1s}.Toastify__toast--stacked[data-collapsed=false]{overflow:visible}.Toastify__toast--stacked[data-collapsed=true]:not(:last-child)>*{opacity:0}.Toastify__toast--stacked:after{content:"";position:absolute;left:0;right:0;height:calc(var(--g) * 1px);bottom:100%}.Toastify__toast--stacked[data-pos=top]{top:0}.Toastify__toast--stacked[data-pos=bot]{bottom:0}.Toastify__toast--stacked[data-pos=bot].Toastify__toast--stacked:before{transform-origin:top}.Toastify__toast--stacked[data-pos=top].Toastify__toast--stacked:before{transform-origin:bottom}.Toastify__toast--stacked:before{content:"";position:absolute;left:0;right:0;bottom:0;height:100%;transform:scaleY(3);z-index:-1}.Toastify__toast--rtl{direction:rtl}.Toastify__toast--close-on-click{cursor:pointer}.Toastify__toast-icon{margin-inline-end:10px;width:22px;flex-shrink:0;display:flex}.Toastify--animate{animation-fill-mode:both;animation-duration:.5s}.Toastify--animate-icon{animation-fill-mode:both;animation-duration:.3s}.Toastify__toast-theme--dark{background:var(--toastify-color-dark);color:var(--toastify-text-color-dark)}.Toastify__toast-theme--light,.Toastify__toast-theme--colored.Toastify__toast--default{background:var(--toastify-color-light);color:var(--toastify-text-color-light)}.Toastify__toast-theme--colored.Toastify__toast--info{color:var(--toastify-text-color-info);background:var(--toastify-color-info)}.Toastify__toast-theme--colored.Toastify__toast--success{color:var(--toastify-text-color-success);background:var(--toastify-color-success)}.Toastify__toast-theme--colored.Toastify__toast--warning{color:var(--toastify-text-color-warning);background:var(--toastify-color-warning)}.Toastify__toast-theme--colored.Toastify__toast--error{color:var(--toastify-text-color-error);background:var(--toastify-color-error)}.Toastify__progress-bar-theme--light{background:var(--toastify-color-progress-light)}.Toastify__progress-bar-theme--dark{background:var(--toastify-color-progress-dark)}.Toastify__progress-bar--info{background:var(--toastify-color-progress-info)}.Toastify__progress-bar--success{background:var(--toastify-color-progress-success)}.Toastify__progress-bar--warning{background:var(--toastify-color-progress-warning)}.Toastify__progress-bar--error{background:var(--toastify-color-progress-error)}.Toastify__progress-bar-theme--colored.Toastify__progress-bar--info,.Toastify__progress-bar-theme--colored.Toastify__progress-bar--success,.Toastify__progress-bar-theme--colored.Toastify__progress-bar--warning,.Toastify__progress-bar-theme--colored.Toastify__progress-bar--error{background:var(--toastify-color-transparent)}.Toastify__close-button{color:#fff;position:absolute;top:6px;right:6px;background:transparent;outline:none;border:none;padding:0;cursor:pointer;opacity:.7;transition:.3s ease;z-index:1}.Toastify__toast--rtl .Toastify__close-button{left:6px;right:unset}.Toastify__close-button--light{color:#000;opacity:.3}.Toastify__close-button>svg{fill:currentColor;height:16px;width:14px}.Toastify__close-button:hover,.Toastify__close-button:focus{opacity:1}@keyframes Toastify__trackProgress{0%{transform:scaleX(1)}to{transform:scaleX(0)}}.Toastify__progress-bar{position:absolute;bottom:0;left:0;width:100%;height:100%;z-index:1;opacity:.7;transform-origin:left}.Toastify__progress-bar--animated{animation:Toastify__trackProgress linear 1 forwards}.Toastify__progress-bar--controlled{transition:transform .2s}.Toastify__progress-bar--rtl{right:0;left:initial;transform-origin:right;border-bottom-left-radius:initial}.Toastify__progress-bar--wrp{position:absolute;overflow:hidden;bottom:0;left:0;width:100%;height:5px;border-bottom-left-radius:var(--toastify-toast-bd-radius);border-bottom-right-radius:var(--toastify-toast-bd-radius)}.Toastify__progress-bar--wrp[data-hidden=true]{opacity:0}.Toastify__progress-bar--bg{opacity:var(--toastify-color-progress-bgo);width:100%;height:100%}.Toastify__spinner{width:20px;height:20px;box-sizing:border-box;border:2px solid;border-radius:100%;border-color:var(--toastify-spinner-color-empty-area);border-right-color:var(--toastify-spinner-color);animation:Toastify__spin .65s linear infinite}@keyframes Toastify__bounceInRight{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(3000px,0,0)}60%{opacity:1;transform:translate3d(-25px,0,0)}75%{transform:translate3d(10px,0,0)}90%{transform:translate3d(-5px,0,0)}to{transform:none}}@keyframes Toastify__bounceOutRight{20%{opacity:1;transform:translate3d(-20px,var(--y),0)}to{opacity:0;transform:translate3d(2000px,var(--y),0)}}@keyframes Toastify__bounceInLeft{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(-3000px,0,0)}60%{opacity:1;transform:translate3d(25px,0,0)}75%{transform:translate3d(-10px,0,0)}90%{transform:translate3d(5px,0,0)}to{transform:none}}@keyframes Toastify__bounceOutLeft{20%{opacity:1;transform:translate3d(20px,var(--y),0)}to{opacity:0;transform:translate3d(-2000px,var(--y),0)}}@keyframes Toastify__bounceInUp{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(0,3000px,0)}60%{opacity:1;transform:translate3d(0,-20px,0)}75%{transform:translate3d(0,10px,0)}90%{transform:translate3d(0,-5px,0)}to{transform:translateZ(0)}}@keyframes Toastify__bounceOutUp{20%{transform:translate3d(0,calc(var(--y) - 10px),0)}40%,45%{opacity:1;transform:translate3d(0,calc(var(--y) + 20px),0)}to{opacity:0;transform:translate3d(0,-2000px,0)}}@keyframes Toastify__bounceInDown{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(0,-3000px,0)}60%{opacity:1;transform:translate3d(0,25px,0)}75%{transform:translate3d(0,-10px,0)}90%{transform:translate3d(0,5px,0)}to{transform:none}}@keyframes Toastify__bounceOutDown{20%{transform:translate3d(0,calc(var(--y) - 10px),0)}40%,45%{opacity:1;transform:translate3d(0,calc(var(--y) + 20px),0)}to{opacity:0;transform:translate3d(0,2000px,0)}}.Toastify__bounce-enter--top-left,.Toastify__bounce-enter--bottom-left{animation-name:Toastify__bounceInLeft}.Toastify__bounce-enter--top-right,.Toastify__bounce-enter--bottom-right{animation-name:Toastify__bounceInRight}.Toastify__bounce-enter--top-center{animation-name:Toastify__bounceInDown}.Toastify__bounce-enter--bottom-center{animation-name:Toastify__bounceInUp}.Toastify__bounce-exit--top-left,.Toastify__bounce-exit--bottom-left{animation-name:Toastify__bounceOutLeft}.Toastify__bounce-exit--top-right,.Toastify__bounce-exit--bottom-right{animation-name:Toastify__bounceOutRight}.Toastify__bounce-exit--top-center{animation-name:Toastify__bounceOutUp}.Toastify__bounce-exit--bottom-center{animation-name:Toastify__bounceOutDown}@keyframes Toastify__zoomIn{0%{opacity:0;transform:scale3d(.3,.3,.3)}50%{opacity:1}}@keyframes Toastify__zoomOut{0%{opacity:1}50%{opacity:0;transform:translate3d(0,var(--y),0) scale3d(.3,.3,.3)}to{opacity:0}}.Toastify__zoom-enter{animation-name:Toastify__zoomIn}.Toastify__zoom-exit{animation-name:Toastify__zoomOut}@keyframes Toastify__flipIn{0%{transform:perspective(400px) rotateX(90deg);animation-timing-function:ease-in;opacity:0}40%{transform:perspective(400px) rotateX(-20deg);animation-timing-function:ease-in}60%{transform:perspective(400px) rotateX(10deg);opacity:1}80%{transform:perspective(400px) rotateX(-5deg)}to{transform:perspective(400px)}}@keyframes Toastify__flipOut{0%{transform:translate3d(0,var(--y),0) perspective(400px)}30%{transform:translate3d(0,var(--y),0) perspective(400px) rotateX(-20deg);opacity:1}to{transform:translate3d(0,var(--y),0) perspective(400px) rotateX(90deg);opacity:0}}.Toastify__flip-enter{animation-name:Toastify__flipIn}.Toastify__flip-exit{animation-name:Toastify__flipOut}@keyframes Toastify__slideInRight{0%{transform:translate3d(110%,0,0);visibility:visible}to{transform:translate3d(0,var(--y),0)}}@keyframes Toastify__slideInLeft{0%{transform:translate3d(-110%,0,0);visibility:visible}to{transform:translate3d(0,var(--y),0)}}@keyframes Toastify__slideInUp{0%{transform:translate3d(0,110%,0);visibility:visible}to{transform:translate3d(0,var(--y),0)}}@keyframes Toastify__slideInDown{0%{transform:translate3d(0,-110%,0);visibility:visible}to{transform:translate3d(0,var(--y),0)}}@keyframes Toastify__slideOutRight{0%{transform:translate3d(0,var(--y),0)}to{visibility:hidden;transform:translate3d(110%,var(--y),0)}}@keyframes Toastify__slideOutLeft{0%{transform:translate3d(0,var(--y),0)}to{visibility:hidden;transform:translate3d(-110%,var(--y),0)}}@keyframes Toastify__slideOutDown{0%{transform:translate3d(0,var(--y),0)}to{visibility:hidden;transform:translate3d(0,500px,0)}}@keyframes Toastify__slideOutUp{0%{transform:translate3d(0,var(--y),0)}to{visibility:hidden;transform:translate3d(0,-500px,0)}}.Toastify__slide-enter--top-left,.Toastify__slide-enter--bottom-left{animation-name:Toastify__slideInLeft}.Toastify__slide-enter--top-right,.Toastify__slide-enter--bottom-right{animation-name:Toastify__slideInRight}.Toastify__slide-enter--top-center{animation-name:Toastify__slideInDown}.Toastify__slide-enter--bottom-center{animation-name:Toastify__slideInUp}.Toastify__slide-exit--top-left,.Toastify__slide-exit--bottom-left{animation-name:Toastify__slideOutLeft;animation-timing-function:ease-in;animation-duration:.3s}.Toastify__slide-exit--top-right,.Toastify__slide-exit--bottom-right{animation-name:Toastify__slideOutRight;animation-timing-function:ease-in;animation-duration:.3s}.Toastify__slide-exit--top-center{animation-name:Toastify__slideOutUp;animation-timing-function:ease-in;animation-duration:.3s}.Toastify__slide-exit--bottom-center{animation-name:Toastify__slideOutDown;animation-timing-function:ease-in;animation-duration:.3s}@keyframes Toastify__spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}
@@ -1,394 +0,0 @@
1
- import T, { useState as Q, useRef as D, useEffect as H, useSyncExternalStore as dt, useLayoutEffect as at, isValidElement as U, cloneElement as Z } from "react";
2
- function ot(t) {
3
- var e, a, o = "";
4
- if (typeof t == "string" || typeof t == "number") o += t;
5
- else if (typeof t == "object") if (Array.isArray(t)) {
6
- var r = t.length;
7
- for (e = 0; e < r; e++) t[e] && (a = ot(t[e])) && (o && (o += " "), o += a);
8
- } else for (a in t) t[a] && (o && (o += " "), o += a);
9
- return o;
10
- }
11
- function N() {
12
- for (var t, e, a = 0, o = "", r = arguments.length; a < r; a++) (t = arguments[a]) && (e = ot(t)) && (o && (o += " "), o += e);
13
- return o;
14
- }
15
- function yt(t) {
16
- if (typeof document > "u") return;
17
- let e = document.head || document.getElementsByTagName("head")[0], a = document.createElement("style");
18
- a.type = "text/css", e.firstChild ? e.insertBefore(a, e.firstChild) : e.appendChild(a), a.styleSheet ? a.styleSheet.cssText = t : a.appendChild(document.createTextNode(t));
19
- }
20
- yt(`:root{--toastify-color-light: #fff;--toastify-color-dark: #121212;--toastify-color-info: #3498db;--toastify-color-success: #07bc0c;--toastify-color-warning: #f1c40f;--toastify-color-error: hsl(6, 78%, 57%);--toastify-color-transparent: rgba(255, 255, 255, .7);--toastify-icon-color-info: var(--toastify-color-info);--toastify-icon-color-success: var(--toastify-color-success);--toastify-icon-color-warning: var(--toastify-color-warning);--toastify-icon-color-error: var(--toastify-color-error);--toastify-container-width: fit-content;--toastify-toast-width: 320px;--toastify-toast-offset: 16px;--toastify-toast-top: max(var(--toastify-toast-offset), env(safe-area-inset-top));--toastify-toast-right: max(var(--toastify-toast-offset), env(safe-area-inset-right));--toastify-toast-left: max(var(--toastify-toast-offset), env(safe-area-inset-left));--toastify-toast-bottom: max(var(--toastify-toast-offset), env(safe-area-inset-bottom));--toastify-toast-background: #fff;--toastify-toast-padding: 14px;--toastify-toast-min-height: 64px;--toastify-toast-max-height: 800px;--toastify-toast-bd-radius: 6px;--toastify-toast-shadow: 0px 4px 12px rgba(0, 0, 0, .1);--toastify-font-family: sans-serif;--toastify-z-index: 9999;--toastify-text-color-light: #757575;--toastify-text-color-dark: #fff;--toastify-text-color-info: #fff;--toastify-text-color-success: #fff;--toastify-text-color-warning: #fff;--toastify-text-color-error: #fff;--toastify-spinner-color: #616161;--toastify-spinner-color-empty-area: #e0e0e0;--toastify-color-progress-light: linear-gradient(to right, #4cd964, #5ac8fa, #007aff, #34aadc, #5856d6, #ff2d55);--toastify-color-progress-dark: #bb86fc;--toastify-color-progress-info: var(--toastify-color-info);--toastify-color-progress-success: var(--toastify-color-success);--toastify-color-progress-warning: var(--toastify-color-warning);--toastify-color-progress-error: var(--toastify-color-error);--toastify-color-progress-bgo: .2}.Toastify__toast-container{z-index:var(--toastify-z-index);-webkit-transform:translate3d(0,0,var(--toastify-z-index));position:fixed;width:var(--toastify-container-width);box-sizing:border-box;color:#fff;display:flex;flex-direction:column}.Toastify__toast-container--top-left{top:var(--toastify-toast-top);left:var(--toastify-toast-left)}.Toastify__toast-container--top-center{top:var(--toastify-toast-top);left:50%;transform:translate(-50%);align-items:center}.Toastify__toast-container--top-right{top:var(--toastify-toast-top);right:var(--toastify-toast-right);align-items:end}.Toastify__toast-container--bottom-left{bottom:var(--toastify-toast-bottom);left:var(--toastify-toast-left)}.Toastify__toast-container--bottom-center{bottom:var(--toastify-toast-bottom);left:50%;transform:translate(-50%);align-items:center}.Toastify__toast-container--bottom-right{bottom:var(--toastify-toast-bottom);right:var(--toastify-toast-right);align-items:end}.Toastify__toast{--y: 0;position:relative;touch-action:none;width:var(--toastify-toast-width);min-height:var(--toastify-toast-min-height);box-sizing:border-box;margin-bottom:1rem;padding:var(--toastify-toast-padding);border-radius:var(--toastify-toast-bd-radius);box-shadow:var(--toastify-toast-shadow);max-height:var(--toastify-toast-max-height);font-family:var(--toastify-font-family);z-index:0;display:flex;flex:1 auto;align-items:center;word-break:break-word}@media only screen and (max-width: 480px){.Toastify__toast-container{width:100vw;left:env(safe-area-inset-left);margin:0}.Toastify__toast-container--top-left,.Toastify__toast-container--top-center,.Toastify__toast-container--top-right{top:env(safe-area-inset-top);transform:translate(0)}.Toastify__toast-container--bottom-left,.Toastify__toast-container--bottom-center,.Toastify__toast-container--bottom-right{bottom:env(safe-area-inset-bottom);transform:translate(0)}.Toastify__toast-container--rtl{right:env(safe-area-inset-right);left:initial}.Toastify__toast{--toastify-toast-width: 100%;margin-bottom:0;border-radius:0}}.Toastify__toast-container[data-stacked=true]{width:var(--toastify-toast-width)}.Toastify__toast--stacked{position:absolute;width:100%;transform:translate3d(0,var(--y),0) scale(var(--s));transition:transform .3s}.Toastify__toast--stacked[data-collapsed] .Toastify__toast-body,.Toastify__toast--stacked[data-collapsed] .Toastify__close-button{transition:opacity .1s}.Toastify__toast--stacked[data-collapsed=false]{overflow:visible}.Toastify__toast--stacked[data-collapsed=true]:not(:last-child)>*{opacity:0}.Toastify__toast--stacked:after{content:"";position:absolute;left:0;right:0;height:calc(var(--g) * 1px);bottom:100%}.Toastify__toast--stacked[data-pos=top]{top:0}.Toastify__toast--stacked[data-pos=bot]{bottom:0}.Toastify__toast--stacked[data-pos=bot].Toastify__toast--stacked:before{transform-origin:top}.Toastify__toast--stacked[data-pos=top].Toastify__toast--stacked:before{transform-origin:bottom}.Toastify__toast--stacked:before{content:"";position:absolute;left:0;right:0;bottom:0;height:100%;transform:scaleY(3);z-index:-1}.Toastify__toast--rtl{direction:rtl}.Toastify__toast--close-on-click{cursor:pointer}.Toastify__toast-icon{margin-inline-end:10px;width:22px;flex-shrink:0;display:flex}.Toastify--animate{animation-fill-mode:both;animation-duration:.5s}.Toastify--animate-icon{animation-fill-mode:both;animation-duration:.3s}.Toastify__toast-theme--dark{background:var(--toastify-color-dark);color:var(--toastify-text-color-dark)}.Toastify__toast-theme--light,.Toastify__toast-theme--colored.Toastify__toast--default{background:var(--toastify-color-light);color:var(--toastify-text-color-light)}.Toastify__toast-theme--colored.Toastify__toast--info{color:var(--toastify-text-color-info);background:var(--toastify-color-info)}.Toastify__toast-theme--colored.Toastify__toast--success{color:var(--toastify-text-color-success);background:var(--toastify-color-success)}.Toastify__toast-theme--colored.Toastify__toast--warning{color:var(--toastify-text-color-warning);background:var(--toastify-color-warning)}.Toastify__toast-theme--colored.Toastify__toast--error{color:var(--toastify-text-color-error);background:var(--toastify-color-error)}.Toastify__progress-bar-theme--light{background:var(--toastify-color-progress-light)}.Toastify__progress-bar-theme--dark{background:var(--toastify-color-progress-dark)}.Toastify__progress-bar--info{background:var(--toastify-color-progress-info)}.Toastify__progress-bar--success{background:var(--toastify-color-progress-success)}.Toastify__progress-bar--warning{background:var(--toastify-color-progress-warning)}.Toastify__progress-bar--error{background:var(--toastify-color-progress-error)}.Toastify__progress-bar-theme--colored.Toastify__progress-bar--info,.Toastify__progress-bar-theme--colored.Toastify__progress-bar--success,.Toastify__progress-bar-theme--colored.Toastify__progress-bar--warning,.Toastify__progress-bar-theme--colored.Toastify__progress-bar--error{background:var(--toastify-color-transparent)}.Toastify__close-button{color:#fff;position:absolute;top:6px;right:6px;background:transparent;outline:none;border:none;padding:0;cursor:pointer;opacity:.7;transition:.3s ease;z-index:1}.Toastify__toast--rtl .Toastify__close-button{left:6px;right:unset}.Toastify__close-button--light{color:#000;opacity:.3}.Toastify__close-button>svg{fill:currentColor;height:16px;width:14px}.Toastify__close-button:hover,.Toastify__close-button:focus{opacity:1}@keyframes Toastify__trackProgress{0%{transform:scaleX(1)}to{transform:scaleX(0)}}.Toastify__progress-bar{position:absolute;bottom:0;left:0;width:100%;height:100%;z-index:1;opacity:.7;transform-origin:left}.Toastify__progress-bar--animated{animation:Toastify__trackProgress linear 1 forwards}.Toastify__progress-bar--controlled{transition:transform .2s}.Toastify__progress-bar--rtl{right:0;left:initial;transform-origin:right;border-bottom-left-radius:initial}.Toastify__progress-bar--wrp{position:absolute;overflow:hidden;bottom:0;left:0;width:100%;height:5px;border-bottom-left-radius:var(--toastify-toast-bd-radius);border-bottom-right-radius:var(--toastify-toast-bd-radius)}.Toastify__progress-bar--wrp[data-hidden=true]{opacity:0}.Toastify__progress-bar--bg{opacity:var(--toastify-color-progress-bgo);width:100%;height:100%}.Toastify__spinner{width:20px;height:20px;box-sizing:border-box;border:2px solid;border-radius:100%;border-color:var(--toastify-spinner-color-empty-area);border-right-color:var(--toastify-spinner-color);animation:Toastify__spin .65s linear infinite}@keyframes Toastify__bounceInRight{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(3000px,0,0)}60%{opacity:1;transform:translate3d(-25px,0,0)}75%{transform:translate3d(10px,0,0)}90%{transform:translate3d(-5px,0,0)}to{transform:none}}@keyframes Toastify__bounceOutRight{20%{opacity:1;transform:translate3d(-20px,var(--y),0)}to{opacity:0;transform:translate3d(2000px,var(--y),0)}}@keyframes Toastify__bounceInLeft{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(-3000px,0,0)}60%{opacity:1;transform:translate3d(25px,0,0)}75%{transform:translate3d(-10px,0,0)}90%{transform:translate3d(5px,0,0)}to{transform:none}}@keyframes Toastify__bounceOutLeft{20%{opacity:1;transform:translate3d(20px,var(--y),0)}to{opacity:0;transform:translate3d(-2000px,var(--y),0)}}@keyframes Toastify__bounceInUp{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(0,3000px,0)}60%{opacity:1;transform:translate3d(0,-20px,0)}75%{transform:translate3d(0,10px,0)}90%{transform:translate3d(0,-5px,0)}to{transform:translateZ(0)}}@keyframes Toastify__bounceOutUp{20%{transform:translate3d(0,calc(var(--y) - 10px),0)}40%,45%{opacity:1;transform:translate3d(0,calc(var(--y) + 20px),0)}to{opacity:0;transform:translate3d(0,-2000px,0)}}@keyframes Toastify__bounceInDown{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(0,-3000px,0)}60%{opacity:1;transform:translate3d(0,25px,0)}75%{transform:translate3d(0,-10px,0)}90%{transform:translate3d(0,5px,0)}to{transform:none}}@keyframes Toastify__bounceOutDown{20%{transform:translate3d(0,calc(var(--y) - 10px),0)}40%,45%{opacity:1;transform:translate3d(0,calc(var(--y) + 20px),0)}to{opacity:0;transform:translate3d(0,2000px,0)}}.Toastify__bounce-enter--top-left,.Toastify__bounce-enter--bottom-left{animation-name:Toastify__bounceInLeft}.Toastify__bounce-enter--top-right,.Toastify__bounce-enter--bottom-right{animation-name:Toastify__bounceInRight}.Toastify__bounce-enter--top-center{animation-name:Toastify__bounceInDown}.Toastify__bounce-enter--bottom-center{animation-name:Toastify__bounceInUp}.Toastify__bounce-exit--top-left,.Toastify__bounce-exit--bottom-left{animation-name:Toastify__bounceOutLeft}.Toastify__bounce-exit--top-right,.Toastify__bounce-exit--bottom-right{animation-name:Toastify__bounceOutRight}.Toastify__bounce-exit--top-center{animation-name:Toastify__bounceOutUp}.Toastify__bounce-exit--bottom-center{animation-name:Toastify__bounceOutDown}@keyframes Toastify__zoomIn{0%{opacity:0;transform:scale3d(.3,.3,.3)}50%{opacity:1}}@keyframes Toastify__zoomOut{0%{opacity:1}50%{opacity:0;transform:translate3d(0,var(--y),0) scale3d(.3,.3,.3)}to{opacity:0}}.Toastify__zoom-enter{animation-name:Toastify__zoomIn}.Toastify__zoom-exit{animation-name:Toastify__zoomOut}@keyframes Toastify__flipIn{0%{transform:perspective(400px) rotateX(90deg);animation-timing-function:ease-in;opacity:0}40%{transform:perspective(400px) rotateX(-20deg);animation-timing-function:ease-in}60%{transform:perspective(400px) rotateX(10deg);opacity:1}80%{transform:perspective(400px) rotateX(-5deg)}to{transform:perspective(400px)}}@keyframes Toastify__flipOut{0%{transform:translate3d(0,var(--y),0) perspective(400px)}30%{transform:translate3d(0,var(--y),0) perspective(400px) rotateX(-20deg);opacity:1}to{transform:translate3d(0,var(--y),0) perspective(400px) rotateX(90deg);opacity:0}}.Toastify__flip-enter{animation-name:Toastify__flipIn}.Toastify__flip-exit{animation-name:Toastify__flipOut}@keyframes Toastify__slideInRight{0%{transform:translate3d(110%,0,0);visibility:visible}to{transform:translate3d(0,var(--y),0)}}@keyframes Toastify__slideInLeft{0%{transform:translate3d(-110%,0,0);visibility:visible}to{transform:translate3d(0,var(--y),0)}}@keyframes Toastify__slideInUp{0%{transform:translate3d(0,110%,0);visibility:visible}to{transform:translate3d(0,var(--y),0)}}@keyframes Toastify__slideInDown{0%{transform:translate3d(0,-110%,0);visibility:visible}to{transform:translate3d(0,var(--y),0)}}@keyframes Toastify__slideOutRight{0%{transform:translate3d(0,var(--y),0)}to{visibility:hidden;transform:translate3d(110%,var(--y),0)}}@keyframes Toastify__slideOutLeft{0%{transform:translate3d(0,var(--y),0)}to{visibility:hidden;transform:translate3d(-110%,var(--y),0)}}@keyframes Toastify__slideOutDown{0%{transform:translate3d(0,var(--y),0)}to{visibility:hidden;transform:translate3d(0,500px,0)}}@keyframes Toastify__slideOutUp{0%{transform:translate3d(0,var(--y),0)}to{visibility:hidden;transform:translate3d(0,-500px,0)}}.Toastify__slide-enter--top-left,.Toastify__slide-enter--bottom-left{animation-name:Toastify__slideInLeft}.Toastify__slide-enter--top-right,.Toastify__slide-enter--bottom-right{animation-name:Toastify__slideInRight}.Toastify__slide-enter--top-center{animation-name:Toastify__slideInDown}.Toastify__slide-enter--bottom-center{animation-name:Toastify__slideInUp}.Toastify__slide-exit--top-left,.Toastify__slide-exit--bottom-left{animation-name:Toastify__slideOutLeft;animation-timing-function:ease-in;animation-duration:.3s}.Toastify__slide-exit--top-right,.Toastify__slide-exit--bottom-right{animation-name:Toastify__slideOutRight;animation-timing-function:ease-in;animation-duration:.3s}.Toastify__slide-exit--top-center{animation-name:Toastify__slideOutUp;animation-timing-function:ease-in;animation-duration:.3s}.Toastify__slide-exit--bottom-center{animation-name:Toastify__slideOutDown;animation-timing-function:ease-in;animation-duration:.3s}@keyframes Toastify__spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}
21
- `);
22
- var M = (t) => typeof t == "number" && !isNaN(t), A = (t) => typeof t == "string", z = (t) => typeof t == "function", ut = (t) => A(t) || M(t), j = (t) => A(t) || z(t) ? t : null, pt = (t, e) => t === !1 || M(t) && t > 0 ? t : e, W = (t) => U(t) || A(t) || z(t) || M(t);
23
- function mt(t, e, a = 300) {
24
- let { scrollHeight: o, style: r } = t;
25
- requestAnimationFrame(() => {
26
- r.minHeight = "initial", r.height = o + "px", r.transition = `all ${a}ms`, requestAnimationFrame(() => {
27
- r.height = "0", r.padding = "0", r.margin = "0", setTimeout(e, a);
28
- });
29
- });
30
- }
31
- function _t({ enter: t, exit: e, appendPosition: a = !1, collapse: o = !0, collapseDuration: r = 300 }) {
32
- return function({ children: l, position: s, preventExitTransition: d, done: f, nodeRef: u, isIn: _, playToast: x }) {
33
- let E = a ? `${t}--${s}` : t, k = a ? `${e}--${s}` : e, I = D(0);
34
- return at(() => {
35
- let v = u.current, m = E.split(" "), p = (n) => {
36
- n.target === u.current && (x(), v.removeEventListener("animationend", p), v.removeEventListener("animationcancel", p), I.current === 0 && n.type !== "animationcancel" && v.classList.remove(...m));
37
- };
38
- v.classList.add(...m), v.addEventListener("animationend", p), v.addEventListener("animationcancel", p);
39
- }, []), H(() => {
40
- let v = u.current, m = () => {
41
- v.removeEventListener("animationend", m), o ? mt(v, f, r) : f();
42
- };
43
- _ || (d ? m() : (I.current = 1, v.className += ` ${k}`, v.addEventListener("animationend", m)));
44
- }, [_]), T.createElement(T.Fragment, null, l);
45
- };
46
- }
47
- function et(t, e) {
48
- return { content: st(t.content, t.props), containerId: t.props.containerId, id: t.props.toastId, theme: t.props.theme, type: t.props.type, data: t.props.data || {}, isLoading: t.props.isLoading, icon: t.props.icon, reason: t.removalReason, status: e };
49
- }
50
- function st(t, e, a = !1) {
51
- return U(t) && !A(t.type) ? Z(t, { closeToast: e.closeToast, toastProps: e, data: e.data, isPaused: a }) : z(t) ? t({ closeToast: e.closeToast, toastProps: e, data: e.data, isPaused: a }) : t;
52
- }
53
- function gt({ closeToast: t, theme: e, ariaLabel: a = "close" }) {
54
- return T.createElement("button", { className: `Toastify__close-button Toastify__close-button--${e}`, type: "button", onClick: (o) => {
55
- o.stopPropagation(), t(!0);
56
- }, "aria-label": a }, T.createElement("svg", { "aria-hidden": "true", viewBox: "0 0 14 16" }, T.createElement("path", { fillRule: "evenodd", d: "M7.71 8.23l3.75 3.75-1.48 1.48-3.75-3.75-3.75 3.75L1 11.98l3.75-3.75L1 4.48 2.48 3l3.75 3.75L9.98 3l1.48 1.48-3.75 3.75z" })));
57
- }
58
- function bt({ delay: t, isRunning: e, closeToast: a, type: o = "default", hide: r, className: l, controlledProgress: s, progress: d, rtl: f, isIn: u, theme: _ }) {
59
- let x = r || s && d === 0, E = { animationDuration: `${t}ms`, animationPlayState: e ? "running" : "paused" };
60
- s && (E.transform = `scaleX(${d})`);
61
- let k = N("Toastify__progress-bar", s ? "Toastify__progress-bar--controlled" : "Toastify__progress-bar--animated", `Toastify__progress-bar-theme--${_}`, `Toastify__progress-bar--${o}`, { "Toastify__progress-bar--rtl": f }), I = z(l) ? l({ rtl: f, type: o, defaultClassName: k }) : N(k, l), v = { [s && d >= 1 ? "onTransitionEnd" : "onAnimationEnd"]: s && d < 1 ? null : () => {
62
- u && a();
63
- } };
64
- return T.createElement("div", { className: "Toastify__progress-bar--wrp", "data-hidden": x }, T.createElement("div", { className: `Toastify__progress-bar--bg Toastify__progress-bar-theme--${_} Toastify__progress-bar--${o}` }), T.createElement("div", { role: "progressbar", "aria-hidden": x ? "true" : "false", "aria-label": "notification timer", className: I, style: E, ...v }));
65
- }
66
- var vt = 1, rt = () => `${vt++}`;
67
- function Tt(t, e, a) {
68
- let o = 1, r = 0, l = [], s = [], d = e, f = /* @__PURE__ */ new Map(), u = /* @__PURE__ */ new Set(), _ = (n) => (u.add(n), () => u.delete(n)), x = () => {
69
- s = Array.from(f.values()), u.forEach((n) => n());
70
- }, E = ({ containerId: n, toastId: i, updateId: c }) => {
71
- let h = n ? n !== t : t !== 1, C = f.has(i) && c == null;
72
- return h || C;
73
- }, k = (n, i) => {
74
- f.forEach((c) => {
75
- var h;
76
- (i == null || i === c.props.toastId) && ((h = c.toggle) == null || h.call(c, n));
77
- });
78
- }, I = (n) => {
79
- var i, c;
80
- (c = (i = n.props) == null ? void 0 : i.onClose) == null || c.call(i, n.removalReason), n.isActive = !1;
81
- }, v = (n) => {
82
- if (n == null) f.forEach(I);
83
- else {
84
- let i = f.get(n);
85
- i && I(i);
86
- }
87
- x();
88
- }, m = () => {
89
- r -= l.length, l = [];
90
- }, p = (n) => {
91
- var i, c;
92
- let { toastId: h, updateId: C } = n.props, y = C == null;
93
- n.staleId && f.delete(n.staleId), n.isActive = !0, f.set(h, n), x(), a(et(n, y ? "added" : "updated")), y && ((c = (i = n.props).onOpen) == null || c.call(i));
94
- };
95
- return { id: t, props: d, observe: _, toggle: k, removeToast: v, toasts: f, clearQueue: m, buildToast: (n, i) => {
96
- if (E(i)) return;
97
- let { toastId: c, updateId: h, data: C, staleId: y, delay: b } = i, L = h == null;
98
- L && r++;
99
- let P = { ...d, style: d.toastStyle, key: o++, ...Object.fromEntries(Object.entries(i).filter(([$, S]) => S != null)), toastId: c, updateId: h, data: C, isIn: !1, className: j(i.className || d.toastClassName), progressClassName: j(i.progressClassName || d.progressClassName), autoClose: i.isLoading ? !1 : pt(i.autoClose, d.autoClose), closeToast($) {
100
- f.get(c).removalReason = $, v(c);
101
- }, deleteToast() {
102
- let $ = f.get(c);
103
- if ($ != null) {
104
- if (a(et($, "removed")), f.delete(c), r--, r < 0 && (r = 0), l.length > 0) {
105
- p(l.shift());
106
- return;
107
- }
108
- x();
109
- }
110
- } };
111
- P.closeButton = d.closeButton, i.closeButton === !1 || W(i.closeButton) ? P.closeButton = i.closeButton : i.closeButton === !0 && (P.closeButton = W(d.closeButton) ? d.closeButton : !0);
112
- let O = { content: n, props: P, staleId: y };
113
- d.limit && d.limit > 0 && r > d.limit && L ? l.push(O) : M(b) ? setTimeout(() => {
114
- p(O);
115
- }, b) : p(O);
116
- }, setProps(n) {
117
- d = n;
118
- }, setToggle: (n, i) => {
119
- let c = f.get(n);
120
- c && (c.toggle = i);
121
- }, isToastActive: (n) => {
122
- var i;
123
- return (i = f.get(n)) == null ? void 0 : i.isActive;
124
- }, getSnapshot: () => s };
125
- }
126
- var w = /* @__PURE__ */ new Map(), R = [], V = /* @__PURE__ */ new Set(), ht = (t) => V.forEach((e) => e(t)), nt = () => w.size > 0;
127
- function xt() {
128
- R.forEach((t) => lt(t.content, t.options)), R = [];
129
- }
130
- var kt = (t, { containerId: e }) => {
131
- var a;
132
- return (a = w.get(e || 1)) == null ? void 0 : a.toasts.get(t);
133
- };
134
- function it(t, e) {
135
- var a;
136
- if (e) return !!((a = w.get(e)) != null && a.isToastActive(t));
137
- let o = !1;
138
- return w.forEach((r) => {
139
- r.isToastActive(t) && (o = !0);
140
- }), o;
141
- }
142
- function Et(t) {
143
- if (!nt()) {
144
- R = R.filter((e) => t != null && e.options.toastId !== t);
145
- return;
146
- }
147
- if (t == null || ut(t)) w.forEach((e) => {
148
- e.removeToast(t);
149
- });
150
- else if (t && ("containerId" in t || "id" in t)) {
151
- let e = w.get(t.containerId);
152
- e ? e.removeToast(t.id) : w.forEach((a) => {
153
- a.removeToast(t.id);
154
- });
155
- }
156
- }
157
- var wt = (t = {}) => {
158
- w.forEach((e) => {
159
- e.props.limit && (!t.containerId || e.id === t.containerId) && e.clearQueue();
160
- });
161
- };
162
- function lt(t, e) {
163
- W(t) && (nt() || R.push({ content: t, options: e }), w.forEach((a) => {
164
- a.buildToast(t, e);
165
- }));
166
- }
167
- function It(t) {
168
- var e;
169
- (e = w.get(t.containerId || 1)) == null || e.setToggle(t.id, t.fn);
170
- }
171
- function ft(t, e) {
172
- w.forEach((a) => {
173
- (e == null || !(e != null && e.containerId) || (e == null ? void 0 : e.containerId) === a.id) && a.toggle(t, e == null ? void 0 : e.id);
174
- });
175
- }
176
- function Ct(t) {
177
- let e = t.containerId || 1;
178
- return { subscribe(a) {
179
- let o = Tt(e, t, ht);
180
- w.set(e, o);
181
- let r = o.observe(a);
182
- return xt(), () => {
183
- r(), w.delete(e);
184
- };
185
- }, setProps(a) {
186
- var o;
187
- (o = w.get(e)) == null || o.setProps(a);
188
- }, getSnapshot() {
189
- var a;
190
- return (a = w.get(e)) == null ? void 0 : a.getSnapshot();
191
- } };
192
- }
193
- function Lt(t) {
194
- return V.add(t), () => {
195
- V.delete(t);
196
- };
197
- }
198
- function Ot(t) {
199
- return t && (A(t.toastId) || M(t.toastId)) ? t.toastId : rt();
200
- }
201
- function B(t, e) {
202
- return lt(t, e), e.toastId;
203
- }
204
- function F(t, e) {
205
- return { ...e, type: e && e.type || t, toastId: Ot(e) };
206
- }
207
- function Y(t) {
208
- return (e, a) => B(e, F(t, a));
209
- }
210
- function g(t, e) {
211
- return B(t, F("default", e));
212
- }
213
- g.loading = (t, e) => B(t, F("default", { isLoading: !0, autoClose: !1, closeOnClick: !1, closeButton: !1, draggable: !1, ...e }));
214
- function zt(t, { pending: e, error: a, success: o }, r) {
215
- let l;
216
- e && (l = A(e) ? g.loading(e, r) : g.loading(e.render, { ...r, ...e }));
217
- let s = { isLoading: null, autoClose: null, closeOnClick: null, closeButton: null, draggable: null }, d = (u, _, x) => {
218
- if (_ == null) {
219
- g.dismiss(l);
220
- return;
221
- }
222
- let E = { type: u, ...s, ...r, data: x }, k = A(_) ? { render: _ } : _;
223
- return l ? g.update(l, { ...E, ...k }) : g(k.render, { ...E, ...k }), x;
224
- }, f = z(t) ? t() : t;
225
- return f.then((u) => d("success", o, u)).catch((u) => d("error", a, u)), f;
226
- }
227
- g.promise = zt;
228
- g.success = Y("success");
229
- g.info = Y("info");
230
- g.error = Y("error");
231
- g.warning = Y("warning");
232
- g.warn = g.warning;
233
- g.dark = (t, e) => B(t, F("default", { theme: "dark", ...e }));
234
- function Pt(t) {
235
- Et(t);
236
- }
237
- g.dismiss = Pt;
238
- g.clearWaitingQueue = wt;
239
- g.isActive = it;
240
- g.update = (t, e = {}) => {
241
- let a = kt(t, e);
242
- if (a) {
243
- let { props: o, content: r } = a, l = { delay: 100, ...o, ...e, toastId: e.toastId || t, updateId: rt() };
244
- l.toastId !== t && (l.staleId = t);
245
- let s = l.render || r;
246
- delete l.render, B(s, l);
247
- }
248
- };
249
- g.done = (t) => {
250
- g.update(t, { progress: 1 });
251
- };
252
- g.onChange = Lt;
253
- g.play = (t) => ft(!0, t);
254
- g.pause = (t) => ft(!1, t);
255
- function $t(t) {
256
- var e;
257
- let { subscribe: a, getSnapshot: o, setProps: r } = D(Ct(t)).current;
258
- r(t);
259
- let l = (e = dt(a, o, o)) == null ? void 0 : e.slice();
260
- function s(d) {
261
- if (!l) return [];
262
- let f = /* @__PURE__ */ new Map();
263
- return t.newestOnTop && l.reverse(), l.forEach((u) => {
264
- let { position: _ } = u.props;
265
- f.has(_) || f.set(_, []), f.get(_).push(u);
266
- }), Array.from(f, (u) => d(u[0], u[1]));
267
- }
268
- return { getToastToRender: s, isToastActive: it, count: l == null ? void 0 : l.length };
269
- }
270
- function Nt(t) {
271
- let [e, a] = Q(!1), [o, r] = Q(!1), l = D(null), s = D({ start: 0, delta: 0, removalDistance: 0, canCloseOnClick: !0, canDrag: !1, didMove: !1 }).current, { autoClose: d, pauseOnHover: f, closeToast: u, onClick: _, closeOnClick: x } = t;
272
- It({ id: t.toastId, containerId: t.containerId, fn: a }), H(() => {
273
- if (t.pauseOnFocusLoss) return E(), () => {
274
- k();
275
- };
276
- }, [t.pauseOnFocusLoss]);
277
- function E() {
278
- document.hasFocus() || p(), window.addEventListener("focus", m), window.addEventListener("blur", p);
279
- }
280
- function k() {
281
- window.removeEventListener("focus", m), window.removeEventListener("blur", p);
282
- }
283
- function I(y) {
284
- if (t.draggable === !0 || t.draggable === y.pointerType) {
285
- n();
286
- let b = l.current;
287
- s.canCloseOnClick = !0, s.canDrag = !0, b.style.transition = "none", t.draggableDirection === "x" ? (s.start = y.clientX, s.removalDistance = b.offsetWidth * (t.draggablePercent / 100)) : (s.start = y.clientY, s.removalDistance = b.offsetHeight * (t.draggablePercent === 80 ? t.draggablePercent * 1.5 : t.draggablePercent) / 100);
288
- }
289
- }
290
- function v(y) {
291
- let { top: b, bottom: L, left: P, right: O } = l.current.getBoundingClientRect();
292
- y.nativeEvent.type !== "touchend" && t.pauseOnHover && y.clientX >= P && y.clientX <= O && y.clientY >= b && y.clientY <= L ? p() : m();
293
- }
294
- function m() {
295
- a(!0);
296
- }
297
- function p() {
298
- a(!1);
299
- }
300
- function n() {
301
- s.didMove = !1, document.addEventListener("pointermove", c), document.addEventListener("pointerup", h);
302
- }
303
- function i() {
304
- document.removeEventListener("pointermove", c), document.removeEventListener("pointerup", h);
305
- }
306
- function c(y) {
307
- let b = l.current;
308
- if (s.canDrag && b) {
309
- s.didMove = !0, e && p(), t.draggableDirection === "x" ? s.delta = y.clientX - s.start : s.delta = y.clientY - s.start, s.start !== y.clientX && (s.canCloseOnClick = !1);
310
- let L = t.draggableDirection === "x" ? `${s.delta}px, var(--y)` : `0, calc(${s.delta}px + var(--y))`;
311
- b.style.transform = `translate3d(${L},0)`, b.style.opacity = `${1 - Math.abs(s.delta / s.removalDistance)}`;
312
- }
313
- }
314
- function h() {
315
- i();
316
- let y = l.current;
317
- if (s.canDrag && s.didMove && y) {
318
- if (s.canDrag = !1, Math.abs(s.delta) > s.removalDistance) {
319
- r(!0), t.closeToast(!0), t.collapseAll();
320
- return;
321
- }
322
- y.style.transition = "transform 0.2s, opacity 0.2s", y.style.removeProperty("transform"), y.style.removeProperty("opacity");
323
- }
324
- }
325
- let C = { onPointerDown: I, onPointerUp: v };
326
- return d && f && (C.onMouseEnter = p, t.stacked || (C.onMouseLeave = m)), x && (C.onClick = (y) => {
327
- _ && _(y), s.canCloseOnClick && u(!0);
328
- }), { playToast: m, pauseToast: p, isRunning: e, preventExitTransition: o, toastRef: l, eventHandlers: C };
329
- }
330
- var At = typeof window < "u" ? at : H, q = ({ theme: t, type: e, isLoading: a, ...o }) => T.createElement("svg", { viewBox: "0 0 24 24", width: "100%", height: "100%", fill: t === "colored" ? "currentColor" : `var(--toastify-icon-color-${e})`, ...o });
331
- function Dt(t) {
332
- return T.createElement(q, { ...t }, T.createElement("path", { d: "M23.32 17.191L15.438 2.184C14.728.833 13.416 0 11.996 0c-1.42 0-2.733.833-3.443 2.184L.533 17.448a4.744 4.744 0 000 4.368C1.243 23.167 2.555 24 3.975 24h16.05C22.22 24 24 22.044 24 19.632c0-.904-.251-1.746-.68-2.44zm-9.622 1.46c0 1.033-.724 1.823-1.698 1.823s-1.698-.79-1.698-1.822v-.043c0-1.028.724-1.822 1.698-1.822s1.698.79 1.698 1.822v.043zm.039-12.285l-.84 8.06c-.057.581-.408.943-.897.943-.49 0-.84-.367-.896-.942l-.84-8.065c-.057-.624.25-1.095.779-1.095h1.91c.528.005.84.476.784 1.1z" }));
333
- }
334
- function Rt(t) {
335
- return T.createElement(q, { ...t }, T.createElement("path", { d: "M12 0a12 12 0 1012 12A12.013 12.013 0 0012 0zm.25 5a1.5 1.5 0 11-1.5 1.5 1.5 1.5 0 011.5-1.5zm2.25 13.5h-4a1 1 0 010-2h.75a.25.25 0 00.25-.25v-4.5a.25.25 0 00-.25-.25h-.75a1 1 0 010-2h1a2 2 0 012 2v4.75a.25.25 0 00.25.25h.75a1 1 0 110 2z" }));
336
- }
337
- function Mt(t) {
338
- return T.createElement(q, { ...t }, T.createElement("path", { d: "M12 0a12 12 0 1012 12A12.014 12.014 0 0012 0zm6.927 8.2l-6.845 9.289a1.011 1.011 0 01-1.43.188l-4.888-3.908a1 1 0 111.25-1.562l4.076 3.261 6.227-8.451a1 1 0 111.61 1.183z" }));
339
- }
340
- function Bt(t) {
341
- return T.createElement(q, { ...t }, T.createElement("path", { d: "M11.983 0a12.206 12.206 0 00-8.51 3.653A11.8 11.8 0 000 12.207 11.779 11.779 0 0011.8 24h.214A12.111 12.111 0 0024 11.791 11.766 11.766 0 0011.983 0zM10.5 16.542a1.476 1.476 0 011.449-1.53h.027a1.527 1.527 0 011.523 1.47 1.475 1.475 0 01-1.449 1.53h-.027a1.529 1.529 0 01-1.523-1.47zM11 12.5v-6a1 1 0 012 0v6a1 1 0 11-2 0z" }));
342
- }
343
- function St() {
344
- return T.createElement("div", { className: "Toastify__spinner" });
345
- }
346
- var G = { info: Rt, warning: Dt, success: Mt, error: Bt, spinner: St }, Xt = (t) => t in G;
347
- function Ht({ theme: t, type: e, isLoading: a, icon: o }) {
348
- let r = null, l = { theme: t, type: e };
349
- return o === !1 || (z(o) ? r = o({ ...l, isLoading: a }) : U(o) ? r = Z(o, l) : a ? r = G.spinner() : Xt(e) && (r = G[e](l))), r;
350
- }
351
- var Ut = (t) => {
352
- let { isRunning: e, preventExitTransition: a, toastRef: o, eventHandlers: r, playToast: l } = Nt(t), { closeButton: s, children: d, autoClose: f, onClick: u, type: _, hideProgressBar: x, closeToast: E, transition: k, position: I, className: v, style: m, progressClassName: p, updateId: n, role: i, progress: c, rtl: h, toastId: C, deleteToast: y, isIn: b, isLoading: L, closeOnClick: P, theme: O, ariaLabel: $ } = t, S = N("Toastify__toast", `Toastify__toast-theme--${O}`, `Toastify__toast--${_}`, { "Toastify__toast--rtl": h }, { "Toastify__toast--close-on-click": P }), ct = z(v) ? v({ rtl: h, position: I, type: _, defaultClassName: S }) : N(S, v), J = Ht(t), tt = !!c || !f, K = { closeToast: E, type: _, theme: O }, X = null;
353
- return s === !1 || (z(s) ? X = s(K) : U(s) ? X = Z(s, K) : X = gt(K)), T.createElement(k, { isIn: b, done: y, position: I, preventExitTransition: a, nodeRef: o, playToast: l }, T.createElement("div", { id: C, tabIndex: 0, onClick: u, "data-in": b, className: ct, ...r, style: m, ref: o, ...b && { role: i, "aria-label": $ } }, J != null && T.createElement("div", { className: N("Toastify__toast-icon", { "Toastify--animate-icon Toastify__zoom-enter": !L }) }, J), st(d, t, !e), X, !t.customProgressBar && T.createElement(bt, { ...n && !tt ? { key: `p-${n}` } : {}, rtl: h, theme: O, delay: f, isRunning: e, isIn: b, closeToast: E, hide: x, type: _, className: p, controlledProgress: tt, progress: c || 0 })));
354
- }, Ft = (t, e = !1) => ({ enter: `Toastify--animate Toastify__${t}-enter`, exit: `Toastify--animate Toastify__${t}-exit`, appendPosition: e }), Yt = _t(Ft("bounce", !0)), qt = { position: "top-right", transition: Yt, autoClose: 5e3, closeButton: !0, pauseOnHover: !0, pauseOnFocusLoss: !0, draggable: "touch", draggablePercent: 80, draggableDirection: "x", role: "alert", theme: "light", "aria-label": "Notifications Alt+T", hotKeys: (t) => t.altKey && t.code === "KeyT" };
355
- function Qt(t) {
356
- let e = { ...qt, ...t }, a = t.stacked, [o, r] = Q(!0), l = D(null), { getToastToRender: s, isToastActive: d, count: f } = $t(e), { className: u, style: _, rtl: x, containerId: E, hotKeys: k } = e;
357
- function I(m) {
358
- let p = N("Toastify__toast-container", `Toastify__toast-container--${m}`, { "Toastify__toast-container--rtl": x });
359
- return z(u) ? u({ position: m, rtl: x, defaultClassName: p }) : N(p, j(u));
360
- }
361
- function v() {
362
- a && (r(!0), g.play());
363
- }
364
- return At(() => {
365
- var m;
366
- if (a) {
367
- let p = l.current.querySelectorAll('[data-in="true"]'), n = 12, i = (m = e.position) == null ? void 0 : m.includes("top"), c = 0, h = 0;
368
- Array.from(p).reverse().forEach((C, y) => {
369
- let b = C;
370
- b.classList.add("Toastify__toast--stacked"), y > 0 && (b.dataset.collapsed = `${o}`), b.dataset.pos || (b.dataset.pos = i ? "top" : "bot");
371
- let L = c * (o ? 0.2 : 1) + (o ? 0 : n * y);
372
- b.style.setProperty("--y", `${i ? L : L * -1}px`), b.style.setProperty("--g", `${n}`), b.style.setProperty("--s", `${1 - (o ? h : 0)}`), c += b.offsetHeight, h += 0.025;
373
- });
374
- }
375
- }, [o, f, a]), H(() => {
376
- function m(p) {
377
- var n;
378
- let i = l.current;
379
- k(p) && ((n = i.querySelector('[tabIndex="0"]')) == null || n.focus(), r(!1), g.pause()), p.key === "Escape" && (document.activeElement === i || i != null && i.contains(document.activeElement)) && (r(!0), g.play());
380
- }
381
- return document.addEventListener("keydown", m), () => {
382
- document.removeEventListener("keydown", m);
383
- };
384
- }, [k]), T.createElement("section", { ref: l, className: "Toastify", id: E, onMouseEnter: () => {
385
- a && (r(!1), g.pause());
386
- }, onMouseLeave: v, "aria-live": "polite", "aria-atomic": "false", "aria-relevant": "additions text", "aria-label": e["aria-label"] }, s((m, p) => {
387
- let n = p.length ? { ..._ } : { ..._, pointerEvents: "none" };
388
- return T.createElement("div", { tabIndex: -1, className: I(m), "data-stacked": a, style: n, key: `c-${m}` }, p.map(({ content: i, props: c }) => T.createElement(Ut, { ...c, stacked: a, collapseAll: v, isIn: d(c.toastId, c.containerId), key: `t-${c.key}` }, i)));
389
- }));
390
- }
391
- export {
392
- Qt as L,
393
- g as y
394
- };
@@ -1,14 +0,0 @@
1
- import { default as React } from 'react';
2
- interface WebSocketMessageHandler {
3
- message: string;
4
- action: (data: any) => void;
5
- }
6
- interface WebSocketManagerProps {
7
- urlWs: string;
8
- handlers: WebSocketMessageHandler[];
9
- socketKey: string;
10
- autoReconnect?: boolean;
11
- maxReconnectAttempts?: number;
12
- }
13
- declare const WebSocketManager: React.FC<WebSocketManagerProps>;
14
- export { WebSocketManager };
@@ -1,14 +0,0 @@
1
- import { ReactNode } from 'react';
2
- type WebSocketStatus = "connecting" | "connected" | "disconnected" | "error";
3
- interface WebSocketContextType {
4
- sockets: Record<string, WebSocket>;
5
- statuses: Record<string, WebSocketStatus>;
6
- setSocket: (key: string, socket: WebSocket) => void;
7
- setStatus: (key: string, status: WebSocketStatus) => void;
8
- removeSocket: (key: string) => void;
9
- }
10
- export declare const WebSocketProvider: ({ children }: {
11
- children: ReactNode;
12
- }) => import("react/jsx-runtime").JSX.Element;
13
- export declare const useWebSocketContext: () => WebSocketContextType;
14
- export {};
@@ -1,4 +0,0 @@
1
- export declare const useWebSocket: (key: string) => {
2
- socket: WebSocket;
3
- status: "error" | "connecting" | "connected" | "disconnected";
4
- };
@@ -1,47 +0,0 @@
1
- import { jsx as W } from "react/jsx-runtime";
2
- import { useRef as i, useEffect as x } from "react";
3
- import { L as k } from "../../index-Cs6Q8pv4.js";
4
- import { useWebSocketContext as C } from "./WebSocketProvider.js";
5
- import '../../assets/WebSocketManager.css';const z = ({
6
- urlWs: f,
7
- handlers: m,
8
- socketKey: e,
9
- autoReconnect: d = !0,
10
- maxReconnectAttempts: S = 5
11
- }) => {
12
- const r = i(null), a = i(0), u = i(!1), { setSocket: g, setStatus: t, removeSocket: l } = C();
13
- return x(() => {
14
- let c = !1;
15
- const b = () => {
16
- r.current && (r.current.readyState === WebSocket.OPEN || r.current.readyState === WebSocket.CONNECTING) && r.current.close(), console.log(`Conectando WebSocket: ${e}`), t(e, "connecting");
17
- const o = new WebSocket(f);
18
- r.current = o, o.onopen = () => {
19
- c || (console.log("WebSocket conectado."), a.current = 0, u.current = !0, g(e, o), t(e, "connected"));
20
- }, o.onmessage = (n) => {
21
- if (!c)
22
- try {
23
- const s = JSON.parse(n.data), p = m.find((N) => N.message === s.message);
24
- p ? p.action(s) : console.warn("No se encontró handler para el mensaje:", s.message);
25
- } catch (s) {
26
- console.error("Error procesando mensaje:", s);
27
- }
28
- }, o.onerror = (n) => {
29
- c || (console.error("Error en WebSocket:", n), t(e, "error"));
30
- }, o.onclose = () => {
31
- if (!c)
32
- if (console.log("WebSocket cerrado."), t(e, "disconnected"), l(e), d && a.current < S && u.current) {
33
- const n = Math.min(3e4, 1e3 * 2 ** a.current);
34
- console.log(`Reintentando conexión en ${n / 1e3}s...`), setTimeout(() => {
35
- a.current += 1, b();
36
- }, n);
37
- } else u.current ? console.error("No se realizará más reconexiones. Máximo alcanzado.") : console.error("Nunca se logró conectar. No se realizarán reconexiones.");
38
- };
39
- };
40
- return b(), () => {
41
- c = !0, r.current && (r.current.close(), l(e));
42
- };
43
- }, [f, m, e, d, S, g, t, l]), /* @__PURE__ */ W(k, {});
44
- };
45
- export {
46
- z as WebSocketManager
47
- };
@@ -1,24 +0,0 @@
1
- import { jsx as a } from "react/jsx-runtime";
2
- import { createContext as b, useState as r, useContext as m } from "react";
3
- const u = b(void 0), W = ({ children: s }) => {
4
- const [S, n] = r({}), [i, c] = r({}), d = (e, t) => {
5
- n((o) => ({ ...o, [e]: t }));
6
- }, k = (e, t) => {
7
- c((o) => ({ ...o, [e]: t }));
8
- }, x = (e) => {
9
- n((t) => {
10
- const o = { ...t };
11
- return delete o[e], o;
12
- }), c((t) => ({ ...t, [e]: "disconnected" }));
13
- };
14
- return /* @__PURE__ */ a(u.Provider, { value: { sockets: S, statuses: i, setSocket: d, setStatus: k, removeSocket: x }, children: s });
15
- }, f = () => {
16
- const s = m(u);
17
- if (!s)
18
- throw new Error("useWebSocketContext must be used within a WebSocketProvider");
19
- return s;
20
- };
21
- export {
22
- W as WebSocketProvider,
23
- f as useWebSocketContext
24
- };
@@ -1,8 +0,0 @@
1
- import { useWebSocketContext as o } from "./WebSocketProvider.js";
2
- const r = (t) => {
3
- const { sockets: s, statuses: e } = o();
4
- return { socket: s[t], status: e[t] };
5
- };
6
- export {
7
- r as useWebSocket
8
- };