thecore-auth 0.0.77 → 0.0.78

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,10 +1,10 @@
1
1
  import * as r from "react";
2
- import F, { createContext as ae, useState as j, useContext as se, useEffect as z } from "react";
3
- import at from "jwt-decode";
4
- import { useNavigate as Ue, useLocation as st, matchPath as ze, Outlet as Ce, Navigate as it, useParams as lt, Routes as ct, Route as Q } from "react-router-dom";
5
- import { BrowserRouter as Vt, Link as Xt, NavLink as Jt, Outlet as Kt, Route as Qt, Routes as e0, useLocation as t0, useMatch as r0, useNavigate as o0 } from "react-router-dom";
6
- import ut from "axios";
7
- import { default as a0 } from "axios";
2
+ import D, { createContext as ae, useState as j, useContext as se, useEffect as I } from "react";
3
+ import it from "jwt-decode";
4
+ import { useNavigate as Ue, useLocation as qe, matchPath as ze, Outlet as ye, Navigate as He, useParams as lt, Link as ct, Routes as ut, Route as Q } from "react-router-dom";
5
+ import { BrowserRouter as Xt, Link as Kt, NavLink as Qt, Outlet as e0, Route as t0, Routes as r0, useLocation as o0, useMatch as n0, useNavigate as a0 } from "react-router-dom";
6
+ import ft from "axios";
7
+ import { default as i0 } from "axios";
8
8
  var me = { exports: {} }, ue = {};
9
9
  /**
10
10
  * @license React
@@ -16,22 +16,22 @@ var me = { exports: {} }, ue = {};
16
16
  * LICENSE file in the root directory of this source tree.
17
17
  */
18
18
  var Ge;
19
- function ft() {
19
+ function dt() {
20
20
  if (Ge) return ue;
21
21
  Ge = 1;
22
22
  var t = Symbol.for("react.transitional.element"), o = Symbol.for("react.fragment");
23
- function n(s, c, u) {
23
+ function n(a, i, u) {
24
24
  var f = null;
25
- if (u !== void 0 && (f = "" + u), c.key !== void 0 && (f = "" + c.key), "key" in c) {
25
+ if (u !== void 0 && (f = "" + u), i.key !== void 0 && (f = "" + i.key), "key" in i) {
26
26
  u = {};
27
- for (var m in c)
28
- m !== "key" && (u[m] = c[m]);
29
- } else u = c;
30
- return c = u.ref, {
27
+ for (var m in i)
28
+ m !== "key" && (u[m] = i[m]);
29
+ } else u = i;
30
+ return i = u.ref, {
31
31
  $$typeof: t,
32
- type: s,
32
+ type: a,
33
33
  key: f,
34
- ref: c !== void 0 ? c : null,
34
+ ref: i !== void 0 ? i : null,
35
35
  props: u
36
36
  };
37
37
  }
@@ -48,19 +48,19 @@ var fe = {};
48
48
  * LICENSE file in the root directory of this source tree.
49
49
  */
50
50
  var Be;
51
- function dt() {
51
+ function mt() {
52
52
  return Be || (Be = 1, process.env.NODE_ENV !== "production" && function() {
53
53
  function t(e) {
54
54
  if (e == null) return null;
55
55
  if (typeof e == "function")
56
- return e.$$typeof === M ? null : e.displayName || e.name || null;
56
+ return e.$$typeof === A ? null : e.displayName || e.name || null;
57
57
  if (typeof e == "string") return e;
58
58
  switch (e) {
59
- case D:
59
+ case W:
60
60
  return "Fragment";
61
- case T:
61
+ case N:
62
62
  return "Portal";
63
- case W:
63
+ case Y:
64
64
  return "Profiler";
65
65
  case te:
66
66
  return "StrictMode";
@@ -73,19 +73,19 @@ function dt() {
73
73
  switch (typeof e.tag == "number" && console.error(
74
74
  "Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."
75
75
  ), e.$$typeof) {
76
- case H:
76
+ case J:
77
77
  return (e.displayName || "Context") + ".Provider";
78
- case q:
78
+ case H:
79
79
  return (e._context.displayName || "Context") + ".Consumer";
80
- case Y:
81
- var i = e.render;
82
- return e = e.displayName, e || (e = i.displayName || i.name || "", e = e !== "" ? "ForwardRef(" + e + ")" : "ForwardRef"), e;
80
+ case Z:
81
+ var l = e.render;
82
+ return e = e.displayName, e || (e = l.displayName || l.name || "", e = e !== "" ? "ForwardRef(" + e + ")" : "ForwardRef"), e;
83
83
  case X:
84
- return i = e.displayName || null, i !== null ? i : t(e.type) || "Memo";
85
- case R:
86
- i = e._payload, e = e._init;
84
+ return l = e.displayName || null, l !== null ? l : t(e.type) || "Memo";
85
+ case k:
86
+ l = e._payload, e = e._init;
87
87
  try {
88
- return t(e(i));
88
+ return t(e(l));
89
89
  } catch {
90
90
  }
91
91
  }
@@ -97,29 +97,29 @@ function dt() {
97
97
  function n(e) {
98
98
  try {
99
99
  o(e);
100
- var i = !1;
100
+ var l = !1;
101
101
  } catch {
102
- i = !0;
102
+ l = !0;
103
103
  }
104
- if (i) {
105
- i = console;
106
- var l = i.error, E = typeof Symbol == "function" && Symbol.toStringTag && e[Symbol.toStringTag] || e.constructor.name || "Object";
107
- return l.call(
108
- i,
104
+ if (l) {
105
+ l = console;
106
+ var c = l.error, b = typeof Symbol == "function" && Symbol.toStringTag && e[Symbol.toStringTag] || e.constructor.name || "Object";
107
+ return c.call(
108
+ l,
109
109
  "The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
110
- E
110
+ b
111
111
  ), o(e);
112
112
  }
113
113
  }
114
- function s() {
114
+ function a() {
115
115
  }
116
- function c() {
116
+ function i() {
117
117
  if (le === 0) {
118
- Le = console.log, Se = console.info, Oe = console.warn, Pe = console.error, ke = console.group, Re = console.groupCollapsed, Te = console.groupEnd;
118
+ Le = console.log, Se = console.info, Oe = console.warn, Pe = console.error, ke = console.group, _e = console.groupCollapsed, Re = console.groupEnd;
119
119
  var e = {
120
120
  configurable: !0,
121
121
  enumerable: !0,
122
- value: s,
122
+ value: a,
123
123
  writable: !0
124
124
  };
125
125
  Object.defineProperties(console, {
@@ -138,13 +138,13 @@ function dt() {
138
138
  if (le--, le === 0) {
139
139
  var e = { configurable: !0, enumerable: !0, writable: !0 };
140
140
  Object.defineProperties(console, {
141
- log: J({}, e, { value: Le }),
142
- info: J({}, e, { value: Se }),
143
- warn: J({}, e, { value: Oe }),
144
- error: J({}, e, { value: Pe }),
145
- group: J({}, e, { value: ke }),
146
- groupCollapsed: J({}, e, { value: Re }),
147
- groupEnd: J({}, e, { value: Te })
141
+ log: B({}, e, { value: Le }),
142
+ info: B({}, e, { value: Se }),
143
+ warn: B({}, e, { value: Oe }),
144
+ error: B({}, e, { value: Pe }),
145
+ group: B({}, e, { value: ke }),
146
+ groupCollapsed: B({}, e, { value: _e }),
147
+ groupEnd: B({}, e, { value: Re })
148
148
  });
149
149
  }
150
150
  0 > le && console.error(
@@ -152,121 +152,121 @@ function dt() {
152
152
  );
153
153
  }
154
154
  function f(e) {
155
- if (Ee === void 0)
155
+ if (ve === void 0)
156
156
  try {
157
157
  throw Error();
158
- } catch (l) {
159
- var i = l.stack.trim().match(/\n( *(at )?)/);
160
- Ee = i && i[1] || "", _e = -1 < l.stack.indexOf(`
161
- at`) ? " (<anonymous>)" : -1 < l.stack.indexOf("@") ? "@unknown:0:0" : "";
158
+ } catch (c) {
159
+ var l = c.stack.trim().match(/\n( *(at )?)/);
160
+ ve = l && l[1] || "", Te = -1 < c.stack.indexOf(`
161
+ at`) ? " (<anonymous>)" : -1 < c.stack.indexOf("@") ? "@unknown:0:0" : "";
162
162
  }
163
163
  return `
164
- ` + Ee + e + _e;
164
+ ` + ve + e + Te;
165
165
  }
166
- function m(e, i) {
166
+ function m(e, l) {
167
167
  if (!e || be) return "";
168
- var l = ye.get(e);
169
- if (l !== void 0) return l;
170
- be = !0, l = Error.prepareStackTrace, Error.prepareStackTrace = void 0;
171
- var E = null;
172
- E = I.H, I.H = null, c();
168
+ var c = Ee.get(e);
169
+ if (c !== void 0) return c;
170
+ be = !0, c = Error.prepareStackTrace, Error.prepareStackTrace = void 0;
171
+ var b = null;
172
+ b = z.H, z.H = null, i();
173
173
  try {
174
- var _ = {
174
+ var R = {
175
175
  DetermineComponentFrameRoot: function() {
176
176
  try {
177
- if (i) {
178
- var U = function() {
177
+ if (l) {
178
+ var q = function() {
179
179
  throw Error();
180
180
  };
181
- if (Object.defineProperty(U.prototype, "props", {
181
+ if (Object.defineProperty(q.prototype, "props", {
182
182
  set: function() {
183
183
  throw Error();
184
184
  }
185
185
  }), typeof Reflect == "object" && Reflect.construct) {
186
186
  try {
187
- Reflect.construct(U, []);
188
- } catch ($) {
189
- var de = $;
187
+ Reflect.construct(q, []);
188
+ } catch (F) {
189
+ var de = F;
190
190
  }
191
- Reflect.construct(e, [], U);
191
+ Reflect.construct(e, [], q);
192
192
  } else {
193
193
  try {
194
- U.call();
195
- } catch ($) {
196
- de = $;
194
+ q.call();
195
+ } catch (F) {
196
+ de = F;
197
197
  }
198
- e.call(U.prototype);
198
+ e.call(q.prototype);
199
199
  }
200
200
  } else {
201
201
  try {
202
202
  throw Error();
203
- } catch ($) {
204
- de = $;
203
+ } catch (F) {
204
+ de = F;
205
205
  }
206
- (U = e()) && typeof U.catch == "function" && U.catch(function() {
206
+ (q = e()) && typeof q.catch == "function" && q.catch(function() {
207
207
  });
208
208
  }
209
- } catch ($) {
210
- if ($ && de && typeof $.stack == "string")
211
- return [$.stack, de.stack];
209
+ } catch (F) {
210
+ if (F && de && typeof F.stack == "string")
211
+ return [F.stack, de.stack];
212
212
  }
213
213
  return [null, null];
214
214
  }
215
215
  };
216
- _.DetermineComponentFrameRoot.displayName = "DetermineComponentFrameRoot";
217
- var S = Object.getOwnPropertyDescriptor(
218
- _.DetermineComponentFrameRoot,
216
+ R.DetermineComponentFrameRoot.displayName = "DetermineComponentFrameRoot";
217
+ var O = Object.getOwnPropertyDescriptor(
218
+ R.DetermineComponentFrameRoot,
219
219
  "name"
220
220
  );
221
- S && S.configurable && Object.defineProperty(
222
- _.DetermineComponentFrameRoot,
221
+ O && O.configurable && Object.defineProperty(
222
+ R.DetermineComponentFrameRoot,
223
223
  "name",
224
224
  { value: "DetermineComponentFrameRoot" }
225
225
  );
226
- var h = _.DetermineComponentFrameRoot(), B = h[0], oe = h[1];
227
- if (B && oe) {
228
- var N = B.split(`
226
+ var g = R.DetermineComponentFrameRoot(), $ = g[0], oe = g[1];
227
+ if ($ && oe) {
228
+ var T = $.split(`
229
229
  `), K = oe.split(`
230
230
  `);
231
- for (h = S = 0; S < N.length && !N[S].includes(
231
+ for (g = O = 0; O < T.length && !T[O].includes(
232
232
  "DetermineComponentFrameRoot"
233
233
  ); )
234
- S++;
235
- for (; h < K.length && !K[h].includes(
234
+ O++;
235
+ for (; g < K.length && !K[g].includes(
236
236
  "DetermineComponentFrameRoot"
237
237
  ); )
238
- h++;
239
- if (S === N.length || h === K.length)
240
- for (S = N.length - 1, h = K.length - 1; 1 <= S && 0 <= h && N[S] !== K[h]; )
241
- h--;
242
- for (; 1 <= S && 0 <= h; S--, h--)
243
- if (N[S] !== K[h]) {
244
- if (S !== 1 || h !== 1)
238
+ g++;
239
+ if (O === T.length || g === K.length)
240
+ for (O = T.length - 1, g = K.length - 1; 1 <= O && 0 <= g && T[O] !== K[g]; )
241
+ g--;
242
+ for (; 1 <= O && 0 <= g; O--, g--)
243
+ if (T[O] !== K[g]) {
244
+ if (O !== 1 || g !== 1)
245
245
  do
246
- if (S--, h--, 0 > h || N[S] !== K[h]) {
246
+ if (O--, g--, 0 > g || T[O] !== K[g]) {
247
247
  var ce = `
248
- ` + N[S].replace(
248
+ ` + T[O].replace(
249
249
  " at new ",
250
250
  " at "
251
251
  );
252
- return e.displayName && ce.includes("<anonymous>") && (ce = ce.replace("<anonymous>", e.displayName)), typeof e == "function" && ye.set(e, ce), ce;
252
+ return e.displayName && ce.includes("<anonymous>") && (ce = ce.replace("<anonymous>", e.displayName)), typeof e == "function" && Ee.set(e, ce), ce;
253
253
  }
254
- while (1 <= S && 0 <= h);
254
+ while (1 <= O && 0 <= g);
255
255
  break;
256
256
  }
257
257
  }
258
258
  } finally {
259
- be = !1, I.H = E, u(), Error.prepareStackTrace = l;
259
+ be = !1, z.H = b, u(), Error.prepareStackTrace = c;
260
260
  }
261
- return N = (N = e ? e.displayName || e.name : "") ? f(N) : "", typeof e == "function" && ye.set(e, N), N;
261
+ return T = (T = e ? e.displayName || e.name : "") ? f(T) : "", typeof e == "function" && Ee.set(e, T), T;
262
262
  }
263
- function d(e) {
263
+ function p(e) {
264
264
  if (e == null) return "";
265
265
  if (typeof e == "function") {
266
- var i = e.prototype;
266
+ var l = e.prototype;
267
267
  return m(
268
268
  e,
269
- !(!i || !i.isReactComponent)
269
+ !(!l || !l.isReactComponent)
270
270
  );
271
271
  }
272
272
  if (typeof e == "string") return f(e);
@@ -278,58 +278,58 @@ function dt() {
278
278
  }
279
279
  if (typeof e == "object")
280
280
  switch (e.$$typeof) {
281
- case Y:
281
+ case Z:
282
282
  return e = m(e.render, !1), e;
283
283
  case X:
284
- return d(e.type);
285
- case R:
286
- i = e._payload, e = e._init;
284
+ return p(e.type);
285
+ case k:
286
+ l = e._payload, e = e._init;
287
287
  try {
288
- return d(e(i));
288
+ return p(e(l));
289
289
  } catch {
290
290
  }
291
291
  }
292
292
  return "";
293
293
  }
294
294
  function C() {
295
- var e = I.A;
295
+ var e = z.A;
296
296
  return e === null ? null : e.getOwner();
297
297
  }
298
- function y(e) {
298
+ function E(e) {
299
299
  if (re.call(e, "key")) {
300
- var i = Object.getOwnPropertyDescriptor(e, "key").get;
301
- if (i && i.isReactWarning) return !1;
300
+ var l = Object.getOwnPropertyDescriptor(e, "key").get;
301
+ if (l && l.isReactWarning) return !1;
302
302
  }
303
303
  return e.key !== void 0;
304
304
  }
305
- function O(e, i) {
306
- function l() {
305
+ function _(e, l) {
306
+ function c() {
307
307
  Ne || (Ne = !0, console.error(
308
308
  "%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",
309
- i
309
+ l
310
310
  ));
311
311
  }
312
- l.isReactWarning = !0, Object.defineProperty(e, "key", {
313
- get: l,
312
+ c.isReactWarning = !0, Object.defineProperty(e, "key", {
313
+ get: c,
314
314
  configurable: !0
315
315
  });
316
316
  }
317
- function P() {
317
+ function S() {
318
318
  var e = t(this.type);
319
319
  return Ae[e] || (Ae[e] = !0, console.error(
320
320
  "Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
321
321
  )), e = this.props.ref, e !== void 0 ? e : null;
322
322
  }
323
- function p(e, i, l, E, _, S) {
324
- return l = S.ref, e = {
325
- $$typeof: w,
323
+ function d(e, l, c, b, R, O) {
324
+ return c = O.ref, e = {
325
+ $$typeof: L,
326
326
  type: e,
327
- key: i,
328
- props: S,
329
- _owner: _
330
- }, (l !== void 0 ? l : null) !== null ? Object.defineProperty(e, "ref", {
327
+ key: l,
328
+ props: O,
329
+ _owner: R
330
+ }, (c !== void 0 ? c : null) !== null ? Object.defineProperty(e, "ref", {
331
331
  enumerable: !1,
332
- get: P
332
+ get: S
333
333
  }) : Object.defineProperty(e, "ref", { enumerable: !1, value: null }), e._store = {}, Object.defineProperty(e._store, "validated", {
334
334
  configurable: !1,
335
335
  enumerable: !1,
@@ -342,122 +342,122 @@ function dt() {
342
342
  value: null
343
343
  }), Object.freeze && (Object.freeze(e.props), Object.freeze(e)), e;
344
344
  }
345
- function v(e, i, l, E, _, S) {
346
- if (typeof e == "string" || typeof e == "function" || e === D || e === W || e === te || e === V || e === G || e === A || typeof e == "object" && e !== null && (e.$$typeof === R || e.$$typeof === X || e.$$typeof === H || e.$$typeof === q || e.$$typeof === Y || e.$$typeof === ot || e.getModuleId !== void 0)) {
347
- var h = i.children;
348
- if (h !== void 0)
349
- if (E)
350
- if (ve(h)) {
351
- for (E = 0; E < h.length; E++)
352
- x(h[E], e);
353
- Object.freeze && Object.freeze(h);
345
+ function x(e, l, c, b, R, O) {
346
+ if (typeof e == "string" || typeof e == "function" || e === W || e === Y || e === te || e === V || e === G || e === M || typeof e == "object" && e !== null && (e.$$typeof === k || e.$$typeof === X || e.$$typeof === J || e.$$typeof === H || e.$$typeof === Z || e.$$typeof === at || e.getModuleId !== void 0)) {
347
+ var g = l.children;
348
+ if (g !== void 0)
349
+ if (b)
350
+ if (xe(g)) {
351
+ for (b = 0; b < g.length; b++)
352
+ h(g[b], e);
353
+ Object.freeze && Object.freeze(g);
354
354
  } else
355
355
  console.error(
356
356
  "React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead."
357
357
  );
358
- else x(h, e);
358
+ else h(g, e);
359
359
  } else
360
- h = "", (e === void 0 || typeof e == "object" && e !== null && Object.keys(e).length === 0) && (h += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports."), e === null ? E = "null" : ve(e) ? E = "array" : e !== void 0 && e.$$typeof === w ? (E = "<" + (t(e.type) || "Unknown") + " />", h = " Did you accidentally export a JSX literal instead of a component?") : E = typeof e, console.error(
360
+ g = "", (e === void 0 || typeof e == "object" && e !== null && Object.keys(e).length === 0) && (g += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports."), e === null ? b = "null" : xe(e) ? b = "array" : e !== void 0 && e.$$typeof === L ? (b = "<" + (t(e.type) || "Unknown") + " />", g = " Did you accidentally export a JSX literal instead of a component?") : b = typeof e, console.error(
361
361
  "React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",
362
- E,
363
- h
362
+ b,
363
+ g
364
364
  );
365
- if (re.call(i, "key")) {
366
- h = t(e);
367
- var B = Object.keys(i).filter(function(N) {
368
- return N !== "key";
365
+ if (re.call(l, "key")) {
366
+ g = t(e);
367
+ var $ = Object.keys(l).filter(function(T) {
368
+ return T !== "key";
369
369
  });
370
- E = 0 < B.length ? "{key: someKey, " + B.join(": ..., ") + ": ...}" : "{key: someKey}", Me[h + E] || (B = 0 < B.length ? "{" + B.join(": ..., ") + ": ...}" : "{}", console.error(
370
+ b = 0 < $.length ? "{key: someKey, " + $.join(": ..., ") + ": ...}" : "{key: someKey}", Me[g + b] || ($ = 0 < $.length ? "{" + $.join(": ..., ") + ": ...}" : "{}", console.error(
371
371
  `A props object containing a "key" prop is being spread into JSX:
372
372
  let props = %s;
373
373
  <%s {...props} />
374
374
  React keys must be passed directly to JSX without using spread:
375
375
  let props = %s;
376
376
  <%s key={someKey} {...props} />`,
377
- E,
378
- h,
379
- B,
380
- h
381
- ), Me[h + E] = !0);
377
+ b,
378
+ g,
379
+ $,
380
+ g
381
+ ), Me[g + b] = !0);
382
382
  }
383
- if (h = null, l !== void 0 && (n(l), h = "" + l), y(i) && (n(i.key), h = "" + i.key), "key" in i) {
384
- l = {};
385
- for (var oe in i)
386
- oe !== "key" && (l[oe] = i[oe]);
387
- } else l = i;
388
- return h && O(
389
- l,
383
+ if (g = null, c !== void 0 && (n(c), g = "" + c), E(l) && (n(l.key), g = "" + l.key), "key" in l) {
384
+ c = {};
385
+ for (var oe in l)
386
+ oe !== "key" && (c[oe] = l[oe]);
387
+ } else c = l;
388
+ return g && _(
389
+ c,
390
390
  typeof e == "function" ? e.displayName || e.name || "Unknown" : e
391
- ), p(e, h, S, _, C(), l);
391
+ ), d(e, g, O, R, C(), c);
392
392
  }
393
- function x(e, i) {
394
- if (typeof e == "object" && e && e.$$typeof !== nt) {
395
- if (ve(e))
396
- for (var l = 0; l < e.length; l++) {
397
- var E = e[l];
398
- L(E) && b(E, i);
393
+ function h(e, l) {
394
+ if (typeof e == "object" && e && e.$$typeof !== st) {
395
+ if (xe(e))
396
+ for (var c = 0; c < e.length; c++) {
397
+ var b = e[c];
398
+ v(b) && y(b, l);
399
399
  }
400
- else if (L(e))
400
+ else if (v(e))
401
401
  e._store && (e._store.validated = 1);
402
- else if (e === null || typeof e != "object" ? l = null : (l = Z && e[Z] || e["@@iterator"], l = typeof l == "function" ? l : null), typeof l == "function" && l !== e.entries && (l = l.call(e), l !== e))
403
- for (; !(e = l.next()).done; )
404
- L(e.value) && b(e.value, i);
402
+ else if (e === null || typeof e != "object" ? c = null : (c = U && e[U] || e["@@iterator"], c = typeof c == "function" ? c : null), typeof c == "function" && c !== e.entries && (c = c.call(e), c !== e))
403
+ for (; !(e = c.next()).done; )
404
+ v(e.value) && y(e.value, l);
405
405
  }
406
406
  }
407
- function L(e) {
408
- return typeof e == "object" && e !== null && e.$$typeof === w;
407
+ function v(e) {
408
+ return typeof e == "object" && e !== null && e.$$typeof === L;
409
409
  }
410
- function b(e, i) {
411
- if (e._store && !e._store.validated && e.key == null && (e._store.validated = 1, i = g(i), !Ie[i])) {
412
- Ie[i] = !0;
413
- var l = "";
414
- e && e._owner != null && e._owner !== C() && (l = null, typeof e._owner.tag == "number" ? l = t(e._owner.type) : typeof e._owner.name == "string" && (l = e._owner.name), l = " It was passed a child from " + l + ".");
415
- var E = I.getCurrentStack;
416
- I.getCurrentStack = function() {
417
- var _ = d(e.type);
418
- return E && (_ += E() || ""), _;
410
+ function y(e, l) {
411
+ if (e._store && !e._store.validated && e.key == null && (e._store.validated = 1, l = w(l), !Ie[l])) {
412
+ Ie[l] = !0;
413
+ var c = "";
414
+ e && e._owner != null && e._owner !== C() && (c = null, typeof e._owner.tag == "number" ? c = t(e._owner.type) : typeof e._owner.name == "string" && (c = e._owner.name), c = " It was passed a child from " + c + ".");
415
+ var b = z.getCurrentStack;
416
+ z.getCurrentStack = function() {
417
+ var R = p(e.type);
418
+ return b && (R += b() || ""), R;
419
419
  }, console.error(
420
420
  'Each child in a list should have a unique "key" prop.%s%s See https://react.dev/link/warning-keys for more information.',
421
- i,
422
- l
423
- ), I.getCurrentStack = E;
421
+ l,
422
+ c
423
+ ), z.getCurrentStack = b;
424
424
  }
425
425
  }
426
- function g(e) {
427
- var i = "", l = C();
428
- return l && (l = t(l.type)) && (i = `
426
+ function w(e) {
427
+ var l = "", c = C();
428
+ return c && (c = t(c.type)) && (l = `
429
429
 
430
- Check the render method of \`` + l + "`."), i || (e = t(e)) && (i = `
430
+ Check the render method of \`` + c + "`."), l || (e = t(e)) && (l = `
431
431
 
432
- Check the top-level render call using <` + e + ">."), i;
432
+ Check the top-level render call using <` + e + ">."), l;
433
433
  }
434
- var k = F, w = Symbol.for("react.transitional.element"), T = Symbol.for("react.portal"), D = Symbol.for("react.fragment"), te = Symbol.for("react.strict_mode"), W = Symbol.for("react.profiler"), q = Symbol.for("react.consumer"), H = Symbol.for("react.context"), Y = Symbol.for("react.forward_ref"), V = Symbol.for("react.suspense"), G = Symbol.for("react.suspense_list"), X = Symbol.for("react.memo"), R = Symbol.for("react.lazy"), A = Symbol.for("react.offscreen"), Z = Symbol.iterator, M = Symbol.for("react.client.reference"), I = k.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, re = Object.prototype.hasOwnProperty, J = Object.assign, ot = Symbol.for("react.client.reference"), ve = Array.isArray, le = 0, Le, Se, Oe, Pe, ke, Re, Te;
435
- s.__reactDisabledLog = !0;
436
- var Ee, _e, be = !1, ye = new (typeof WeakMap == "function" ? WeakMap : Map)(), nt = Symbol.for("react.client.reference"), Ne, Ae = {}, Me = {}, Ie = {};
437
- fe.Fragment = D, fe.jsx = function(e, i, l, E, _) {
438
- return v(e, i, l, !1, E, _);
439
- }, fe.jsxs = function(e, i, l, E, _) {
440
- return v(e, i, l, !0, E, _);
434
+ var P = D, L = Symbol.for("react.transitional.element"), N = Symbol.for("react.portal"), W = Symbol.for("react.fragment"), te = Symbol.for("react.strict_mode"), Y = Symbol.for("react.profiler"), H = Symbol.for("react.consumer"), J = Symbol.for("react.context"), Z = Symbol.for("react.forward_ref"), V = Symbol.for("react.suspense"), G = Symbol.for("react.suspense_list"), X = Symbol.for("react.memo"), k = Symbol.for("react.lazy"), M = Symbol.for("react.offscreen"), U = Symbol.iterator, A = Symbol.for("react.client.reference"), z = P.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, re = Object.prototype.hasOwnProperty, B = Object.assign, at = Symbol.for("react.client.reference"), xe = Array.isArray, le = 0, Le, Se, Oe, Pe, ke, _e, Re;
435
+ a.__reactDisabledLog = !0;
436
+ var ve, Te, be = !1, Ee = new (typeof WeakMap == "function" ? WeakMap : Map)(), st = Symbol.for("react.client.reference"), Ne, Ae = {}, Me = {}, Ie = {};
437
+ fe.Fragment = W, fe.jsx = function(e, l, c, b, R) {
438
+ return x(e, l, c, !1, b, R);
439
+ }, fe.jsxs = function(e, l, c, b, R) {
440
+ return x(e, l, c, !0, b, R);
441
441
  };
442
442
  }()), fe;
443
443
  }
444
444
  var $e;
445
- function mt() {
446
- return $e || ($e = 1, process.env.NODE_ENV === "production" ? me.exports = ft() : me.exports = dt()), me.exports;
445
+ function pt() {
446
+ return $e || ($e = 1, process.env.NODE_ENV === "production" ? me.exports = dt() : me.exports = mt()), me.exports;
447
447
  }
448
- var a = mt();
449
- const qe = ae(), Bt = ({ children: t }) => {
450
- const [o, n] = j(!1), [s, c] = j(!1), [u, f] = j({});
451
- return /* @__PURE__ */ a.jsx(qe.Provider, { value: { isLoading: o, setIsLoading: n, isLoadingComponent: s, setIsLoadingComponent: c, loadingProps: u, setLoadingProps: f }, children: t });
452
- }, xe = () => {
453
- const t = se(qe);
448
+ var s = pt();
449
+ const Je = ae(), $t = ({ children: t }) => {
450
+ const [o, n] = j(!1), [a, i] = j(!1), [u, f] = j({});
451
+ return /* @__PURE__ */ s.jsx(Je.Provider, { value: { isLoading: o, setIsLoading: n, isLoadingComponent: a, setIsLoadingComponent: i, loadingProps: u, setLoadingProps: f }, children: t });
452
+ }, he = () => {
453
+ const t = se(Je);
454
454
  if (t === void 0) throw new Error("Non puoi settare il loading");
455
455
  return t;
456
- }, pt = ({ errorMessage: t, errorShow: o }) => /* @__PURE__ */ a.jsx("section", { className: o ? "" : "hidden", children: /* @__PURE__ */ a.jsxs("div", { className: "container mx-auto", children: [
457
- /* @__PURE__ */ a.jsx("h1", { className: "text-center text-8xl my-12", children: "Errore" }),
458
- /* @__PURE__ */ a.jsx("pre", { className: "text-xl", children: t })
459
- ] }) }), He = ae(), $t = ({ children: t }) => {
460
- const [o, n] = j({}), [s, c] = j(!1), u = `Creare un file config.json in public per il corretto funzionamento
456
+ }, gt = ({ errorMessage: t, errorShow: o }) => /* @__PURE__ */ s.jsx("section", { className: o ? "" : "hidden", children: /* @__PURE__ */ s.jsxs("div", { className: "container mx-auto", children: [
457
+ /* @__PURE__ */ s.jsx("h1", { className: "text-center text-8xl my-12", children: "Errore" }),
458
+ /* @__PURE__ */ s.jsx("pre", { className: "text-xl", children: t })
459
+ ] }) }), Ve = ae(), Ft = ({ children: t }) => {
460
+ const [o, n] = j({}), [a, i] = j(!1), u = `Creare un file config.json in public per il corretto funzionamento
461
461
  Esempio di config.json:
462
462
 
463
463
  {
@@ -484,90 +484,90 @@ Esempio di config.json:
484
484
  "autoLoginEmail": ,
485
485
  "autoLoginPassword":
486
486
  }`, f = () => {
487
- const p = /* @__PURE__ */ new Date(), v = String(p.getDate()).padStart(2, "0"), x = String(p.getMonth() + 1).padStart(2, "0"), L = p.getFullYear(), b = String(p.getHours()).padStart(2, "0"), g = String(p.getMinutes()).padStart(2, "0"), k = String(p.getSeconds()).padStart(2, "0");
488
- return `${v}/${x}/${L} ${b}:${g}:${k}`;
489
- }, m = (p) => new Promise((v, x) => {
490
- const L = indexedDB.open("configDatabase", 1);
491
- L.onupgradeneeded = (b) => {
492
- const g = b.target.result;
493
- g.objectStoreNames.contains(p) || g.createObjectStore(p, { keyPath: "id" });
494
- }, L.onsuccess = (b) => v(b.target.result), L.onerror = (b) => x(b.target.error);
495
- }), d = async (p, v) => {
496
- let x = await m(p);
497
- return new Promise((L, b) => {
498
- if (!x) {
499
- b("Errore: DB non disponibile");
487
+ const d = /* @__PURE__ */ new Date(), x = String(d.getDate()).padStart(2, "0"), h = String(d.getMonth() + 1).padStart(2, "0"), v = d.getFullYear(), y = String(d.getHours()).padStart(2, "0"), w = String(d.getMinutes()).padStart(2, "0"), P = String(d.getSeconds()).padStart(2, "0");
488
+ return `${x}/${h}/${v} ${y}:${w}:${P}`;
489
+ }, m = (d) => new Promise((x, h) => {
490
+ const v = indexedDB.open("configDatabase", 1);
491
+ v.onupgradeneeded = (y) => {
492
+ const w = y.target.result;
493
+ w.objectStoreNames.contains(d) || w.createObjectStore(d, { keyPath: "id" });
494
+ }, v.onsuccess = (y) => x(y.target.result), v.onerror = (y) => h(y.target.error);
495
+ }), p = async (d, x) => {
496
+ let h = await m(d);
497
+ return new Promise((v, y) => {
498
+ if (!h) {
499
+ y("Errore: DB non disponibile");
500
500
  return;
501
501
  }
502
- const g = x == null ? void 0 : x.transaction(p, "readonly"), k = g == null ? void 0 : g.objectStore(p), w = k == null ? void 0 : k.get(v);
503
- w.onsuccess = () => L(w.result), w.onerror = (T) => b(T.target.error);
502
+ const w = h == null ? void 0 : h.transaction(d, "readonly"), P = w == null ? void 0 : w.objectStore(d), L = P == null ? void 0 : P.get(x);
503
+ L.onsuccess = () => v(L.result), L.onerror = (N) => y(N.target.error);
504
504
  });
505
- }, C = async (p, v) => {
506
- let x = await m(p);
507
- return new Promise((L, b) => {
508
- if (!x) {
509
- b("Errore: DB non disponibile");
505
+ }, C = async (d, x) => {
506
+ let h = await m(d);
507
+ return new Promise((v, y) => {
508
+ if (!h) {
509
+ y("Errore: DB non disponibile");
510
510
  return;
511
511
  }
512
- const g = x == null ? void 0 : x.transaction(p, "readwrite"), k = g == null ? void 0 : g.objectStore(p), w = k == null ? void 0 : k.put(v);
513
- w.onsuccess = () => L(w.result), w.onerror = (T) => b(T.target.error);
512
+ const w = h == null ? void 0 : h.transaction(d, "readwrite"), P = w == null ? void 0 : w.objectStore(d), L = P == null ? void 0 : P.put(x);
513
+ L.onsuccess = () => v(L.result), L.onerror = (N) => y(N.target.error);
514
514
  });
515
- }, y = async (p) => {
516
- let v = Date.now(), x;
515
+ }, E = async (d) => {
516
+ let x = Date.now(), h;
517
517
  do
518
- x = await d(p, v), x && v++;
519
- while (x);
520
- return v;
521
- }, O = async (p, v) => {
522
- v.id || (v.id = await y(p)), await C(p, v);
523
- }, P = async () => {
518
+ h = await p(d, x), h && x++;
519
+ while (h);
520
+ return x;
521
+ }, _ = async (d, x) => {
522
+ x.id || (x.id = await E(d)), await C(d, x);
523
+ }, S = async () => {
524
524
  try {
525
- const x = {
525
+ const h = {
526
526
  ...await (await fetch("/config.json")).json(),
527
527
  openIndexedDB: m,
528
- getDataIndexedDB: d,
528
+ getDataIndexedDB: p,
529
529
  setDataIndexedDB: C,
530
- generateUniqueId: y,
531
- setDataWithAutoId: O,
530
+ generateUniqueId: E,
531
+ setDataWithAutoId: _,
532
532
  setCurrentDate: f
533
533
  };
534
- n(x);
535
- } catch (p) {
536
- console.error(p), c(!0);
534
+ n(h);
535
+ } catch (d) {
536
+ console.error(d), i(!0);
537
537
  }
538
538
  };
539
- return z(() => {
540
- P();
541
- }, []), Object.keys(o).length === 0 ? /* @__PURE__ */ a.jsx(pt, { errorShow: s, errorMessage: u }) : /* @__PURE__ */ a.jsx(He.Provider, { value: o, children: t });
539
+ return I(() => {
540
+ S();
541
+ }, []), Object.keys(o).length === 0 ? /* @__PURE__ */ s.jsx(gt, { errorShow: a, errorMessage: u }) : /* @__PURE__ */ s.jsx(Ve.Provider, { value: o, children: t });
542
542
  }, ee = () => {
543
- const t = se(He);
543
+ const t = se(Ve);
544
544
  if (t === void 0) throw new Error("Non puoi leggere i config");
545
545
  return t;
546
- }, gt = (t) => /* @__PURE__ */ r.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", xmlnsXlink: "http://www.w3.org/1999/xlink", width: 500, zoomAndPan: "magnify", viewBox: "0 0 375 374.999991", height: 500, preserveAspectRatio: "xMidYMid meet", ...t }, /* @__PURE__ */ r.createElement("defs", null, /* @__PURE__ */ r.createElement("g", null), /* @__PURE__ */ r.createElement("clipPath", { id: "6ca7e2bf04" }, /* @__PURE__ */ r.createElement("path", { d: "M 265.136719 0 L 375 109.863281 L 375 265.136719 L 265.136719 375 L 109.863281 375 L 0 265.136719 L 0 109.863281 L 109.863281 0 Z M 265.136719 0 ", clipRule: "nonzero" })), /* @__PURE__ */ r.createElement("clipPath", { id: "2c77c820c6" }, /* @__PURE__ */ r.createElement("path", { d: "M 12.878906 12.878906 L 362.121094 12.878906 L 362.121094 362.121094 L 12.878906 362.121094 Z M 12.878906 12.878906 ", clipRule: "nonzero" })), /* @__PURE__ */ r.createElement("clipPath", { id: "3d94df7d66" }, /* @__PURE__ */ r.createElement("path", { d: "M 259.804688 12.878906 L 362.121094 115.195312 L 362.121094 259.804688 L 259.804688 362.121094 L 115.195312 362.121094 L 12.878906 259.804688 L 12.878906 115.195312 L 115.195312 12.878906 Z M 259.804688 12.878906 ", clipRule: "nonzero" })), /* @__PURE__ */ r.createElement("clipPath", { id: "8793709a64" }, /* @__PURE__ */ r.createElement("path", { d: "M 12.878906 12.878906 L 362.109375 12.878906 L 362.109375 362.109375 L 12.878906 362.109375 Z M 12.878906 12.878906 ", clipRule: "nonzero" })), /* @__PURE__ */ r.createElement("clipPath", { id: "fdb3fe29d8" }, /* @__PURE__ */ r.createElement("path", { d: "M 259.796875 12.878906 L 362.109375 115.191406 L 362.109375 259.796875 L 259.796875 362.109375 L 115.191406 362.109375 L 12.878906 259.796875 L 12.878906 115.191406 L 115.191406 12.878906 Z M 259.796875 12.878906 ", clipRule: "nonzero" }))), /* @__PURE__ */ r.createElement("g", { clipPath: "url(#6ca7e2bf04)" }, /* @__PURE__ */ r.createElement("rect", { x: -37.5, width: 450, fill: "#b91c1c", y: -37.499999, height: 449.999989, fillOpacity: 1 })), /* @__PURE__ */ r.createElement("g", { clipPath: "url(#2c77c820c6)" }, /* @__PURE__ */ r.createElement("g", { clipPath: "url(#3d94df7d66)" }, /* @__PURE__ */ r.createElement("path", { fill: "#b91c1c", d: "M 12.878906 12.878906 L 362.121094 12.878906 L 362.121094 362.121094 L 12.878906 362.121094 Z M 12.878906 12.878906 ", fillOpacity: 1, fillRule: "nonzero" }))), /* @__PURE__ */ r.createElement("g", { clipPath: "url(#8793709a64)" }, /* @__PURE__ */ r.createElement("g", { clipPath: "url(#fdb3fe29d8)" }, /* @__PURE__ */ r.createElement("path", { strokeLinecap: "butt", transform: "matrix(0.75, 0, 0, 0.75, 12.879396, 12.879392)", fill: "none", strokeLinejoin: "miter", d: "M 329.223327 -0.000647072 L 465.640003 136.416029 L 465.640003 329.223333 L 329.223327 465.640009 L 136.416023 465.640009 L -0.000653072 329.223333 L -0.000653072 136.416029 L 136.416023 -0.000647072 Z M 329.223327 -0.000647072 ", stroke: "#ffffff", strokeWidth: 34, strokeOpacity: 1, strokeMiterlimit: 4 }))), /* @__PURE__ */ r.createElement("g", { fill: "#ffffff", fillOpacity: 1 }, /* @__PURE__ */ r.createElement("g", { transform: "translate(111.648432, 267.442446)" }, /* @__PURE__ */ r.createElement("g", null, /* @__PURE__ */ r.createElement("path", { d: "M 2.828125 0 L 56.25 -79.859375 L 3.046875 -159.609375 L 37.28125 -159.609375 L 75.90625 -98.046875 L 114.53125 -159.609375 L 148.765625 -159.609375 L 95.5625 -79.859375 L 148.984375 0 L 114.765625 0 L 75.671875 -60.65625 L 37.046875 0 Z M 2.828125 0 " }))))), ht = (t) => /* @__PURE__ */ r.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", xmlnsXlink: "http://www.w3.org/1999/xlink", width: 500, zoomAndPan: "magnify", viewBox: "0 0 375 374.999991", height: 500, preserveAspectRatio: "xMidYMid meet", ...t }, /* @__PURE__ */ r.createElement("defs", null, /* @__PURE__ */ r.createElement("g", null), /* @__PURE__ */ r.createElement("clipPath", { id: "30562604dd" }, /* @__PURE__ */ r.createElement("path", { d: "M 187.5 0 C 83.945312 0 0 83.945312 0 187.5 C 0 291.054688 83.945312 375 187.5 375 C 291.054688 375 375 291.054688 375 187.5 C 375 83.945312 291.054688 0 187.5 0 Z M 187.5 0 ", clipRule: "nonzero" })), /* @__PURE__ */ r.createElement("clipPath", { id: "971fcd5f72" }, /* @__PURE__ */ r.createElement("path", { d: "M 18.570312 18.570312 L 356.429688 18.570312 L 356.429688 356.429688 L 18.570312 356.429688 Z M 18.570312 18.570312 ", clipRule: "nonzero" })), /* @__PURE__ */ r.createElement("clipPath", { id: "e891a7f57e" }, /* @__PURE__ */ r.createElement("path", { d: "M 187.5 18.570312 C 94.203125 18.570312 18.570312 94.203125 18.570312 187.5 C 18.570312 280.796875 94.203125 356.429688 187.5 356.429688 C 280.796875 356.429688 356.429688 280.796875 356.429688 187.5 C 356.429688 94.203125 280.796875 18.570312 187.5 18.570312 Z M 187.5 18.570312 ", clipRule: "nonzero" })), /* @__PURE__ */ r.createElement("clipPath", { id: "19a9ddc130" }, /* @__PURE__ */ r.createElement("path", { d: "M 18.570312 18.570312 L 356.070312 18.570312 L 356.070312 356.070312 L 18.570312 356.070312 Z M 18.570312 18.570312 ", clipRule: "nonzero" })), /* @__PURE__ */ r.createElement("clipPath", { id: "5e650d5bd0" }, /* @__PURE__ */ r.createElement("path", { d: "M 187.496094 18.570312 C 94.199219 18.570312 18.570312 94.199219 18.570312 187.496094 C 18.570312 280.792969 94.199219 356.421875 187.496094 356.421875 C 280.792969 356.421875 356.421875 280.792969 356.421875 187.496094 C 356.421875 94.199219 280.792969 18.570312 187.496094 18.570312 Z M 187.496094 18.570312 ", clipRule: "nonzero" }))), /* @__PURE__ */ r.createElement("g", { clipPath: "url(#30562604dd)" }, /* @__PURE__ */ r.createElement("rect", { x: -37.5, width: 450, fill: "#1d4ed8", y: -37.499999, height: 449.999989, fillOpacity: 1 })), /* @__PURE__ */ r.createElement("g", { clipPath: "url(#971fcd5f72)" }, /* @__PURE__ */ r.createElement("g", { clipPath: "url(#e891a7f57e)" }, /* @__PURE__ */ r.createElement("path", { fill: "#1d4ed8", d: "M 18.570312 18.570312 L 356.429688 18.570312 L 356.429688 356.429688 L 18.570312 356.429688 Z M 18.570312 18.570312 ", fillOpacity: 1, fillRule: "nonzero" }))), /* @__PURE__ */ r.createElement("g", { clipPath: "url(#19a9ddc130)" }, /* @__PURE__ */ r.createElement("g", { clipPath: "url(#5e650d5bd0)" }, /* @__PURE__ */ r.createElement("path", { strokeLinecap: "butt", transform: "matrix(0.75, 0, 0, 0.75, 18.570291, 18.570286)", fill: "none", strokeLinejoin: "miter", d: "M 225.234419 0.0000349326 C 100.838577 0.0000349326 0.0000289326 100.838583 0.0000289326 225.234425 C 0.0000289326 349.630266 100.838577 450.468815 225.234419 450.468815 C 349.63026 450.468815 450.468809 349.630266 450.468809 225.234425 C 450.468809 100.838583 349.63026 0.0000349326 225.234419 0.0000349326 Z M 225.234419 0.0000349326 ", stroke: "#ffffff", strokeWidth: 34, strokeOpacity: 1, strokeMiterlimit: 4 }))), /* @__PURE__ */ r.createElement("g", { fill: "#ffffff", fillOpacity: 1 }, /* @__PURE__ */ r.createElement("g", { transform: "translate(136.121787, 300.837436)" }, /* @__PURE__ */ r.createElement("g", null, /* @__PURE__ */ r.createElement("path", { d: "M 60 -193.78125 C 54.707031 -193.78125 50.109375 -195.734375 46.203125 -199.640625 C 42.296875 -203.554688 40.34375 -208.15625 40.34375 -213.4375 C 40.34375 -218.726562 42.296875 -223.328125 46.203125 -227.234375 C 50.109375 -231.140625 54.707031 -233.09375 60 -233.09375 C 65.28125 -233.09375 69.875 -231.140625 73.78125 -227.234375 C 77.695312 -223.328125 79.65625 -218.726562 79.65625 -213.4375 C 79.65625 -208.15625 77.695312 -203.554688 73.78125 -199.640625 C 69.875 -195.734375 65.28125 -193.78125 60 -193.78125 Z M 45.171875 4.828125 C 39.191406 4.828125 35.28125 2.414062 33.4375 -2.40625 C 31.601562 -7.238281 30.6875 -13.675781 30.6875 -21.71875 C 30.6875 -34.59375 31.773438 -47.234375 33.953125 -59.640625 C 36.140625 -72.054688 38.328125 -83.894531 40.515625 -95.15625 C 42.703125 -106.425781 43.796875 -116.890625 43.796875 -126.546875 C 43.796875 -129.078125 43.675781 -131.832031 43.4375 -134.8125 C 43.207031 -137.800781 42.632812 -140.101562 41.71875 -141.71875 C 38.039062 -139.414062 33.269531 -135.617188 27.40625 -130.328125 C 21.550781 -125.046875 16.898438 -119.1875 13.453125 -112.75 C 11.835938 -114.363281 11.03125 -116.550781 11.03125 -119.3125 C 11.03125 -123.21875 12.582031 -127.46875 15.6875 -132.0625 C 18.789062 -136.65625 22.925781 -141.078125 28.09375 -145.328125 C 33.269531 -149.585938 38.847656 -153.097656 44.828125 -155.859375 C 50.804688 -158.617188 56.664062 -160 62.40625 -160 C 67.695312 -160 71.085938 -158.734375 72.578125 -156.203125 C 74.078125 -153.671875 74.828125 -150.453125 74.828125 -146.546875 C 74.828125 -140.796875 74.078125 -133.378906 72.578125 -124.296875 C 71.085938 -115.222656 69.363281 -105.515625 67.40625 -95.171875 C 65.457031 -84.828125 63.734375 -74.484375 62.234375 -64.140625 C 60.742188 -53.796875 60 -44.367188 60 -35.859375 C 60 -31.492188 60.226562 -27.414062 60.6875 -23.625 C 61.144531 -19.832031 61.71875 -16.671875 62.40625 -14.140625 C 68.15625 -16.671875 73.613281 -20.40625 78.78125 -25.34375 C 83.957031 -30.28125 87.8125 -34.9375 90.34375 -39.3125 C 91.71875 -37.238281 92.40625 -35.050781 92.40625 -32.75 C 92.40625 -29.070312 90.796875 -25.050781 87.578125 -20.6875 C 84.359375 -16.320312 80.332031 -12.179688 75.5 -8.265625 C 70.675781 -4.359375 65.5625 -1.203125 60.15625 1.203125 C 54.757812 3.617188 49.765625 4.828125 45.171875 4.828125 Z M 45.171875 4.828125 " }))))), xt = (t) => /* @__PURE__ */ r.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", xmlnsXlink: "http://www.w3.org/1999/xlink", width: 500, zoomAndPan: "magnify", viewBox: "0 0 375 374.999991", height: 500, preserveAspectRatio: "xMidYMid meet", ...t }, /* @__PURE__ */ r.createElement("defs", null, /* @__PURE__ */ r.createElement("g", null), /* @__PURE__ */ r.createElement("clipPath", { id: "59a10ac27a" }, /* @__PURE__ */ r.createElement("path", { d: "M 17.179688 32.695312 L 360 32.695312 L 360 337.5 L 17.179688 337.5 Z M 17.179688 32.695312 ", clipRule: "nonzero" })), /* @__PURE__ */ r.createElement("clipPath", { id: "664b27481e" }, /* @__PURE__ */ r.createElement("path", { d: "M 207.042969 43.574219 L 356.394531 304.941406 C 360.242188 311.675781 360.214844 319.953125 356.324219 326.660156 C 352.429688 333.371094 345.257812 337.5 337.5 337.5 L 39.375 337.5 C 31.617188 337.5 24.445312 333.371094 20.554688 326.660156 C 16.660156 319.953125 16.632812 311.675781 20.480469 304.941406 L 169.832031 43.574219 C 173.648438 36.898438 180.746094 32.777344 188.4375 32.777344 C 196.128906 32.777344 203.226562 36.898438 207.042969 43.574219 Z M 207.042969 43.574219 ", clipRule: "nonzero" }))), /* @__PURE__ */ r.createElement("g", { clipPath: "url(#59a10ac27a)" }, /* @__PURE__ */ r.createElement("g", { clipPath: "url(#664b27481e)" }, /* @__PURE__ */ r.createElement("path", { fill: "#d97706", d: "M 1.875 11.015625 L 375.546875 11.015625 L 375.546875 337.5 L 1.875 337.5 Z M 1.875 11.015625 ", fillOpacity: 1, fillRule: "nonzero" }))), /* @__PURE__ */ r.createElement("g", { fill: "#ffffff", fillOpacity: 1 }, /* @__PURE__ */ r.createElement("g", { transform: "translate(158.410439, 295.655517)" }, /* @__PURE__ */ r.createElement("g", null, /* @__PURE__ */ r.createElement("path", { d: "M 46.890625 -63.21875 C 46.890625 -63.21875 46.890625 -64.445312 46.890625 -66.90625 L 46.890625 -176.46875 C 46.890625 -178.925781 46.1875 -180.859375 44.78125 -182.265625 C 43.375 -183.671875 41.441406 -184.375 38.984375 -184.375 L 21.078125 -184.375 C 18.617188 -184.375 16.6875 -183.671875 15.28125 -182.265625 C 13.875 -180.859375 13.171875 -178.925781 13.171875 -176.46875 L 13.171875 -66.90625 C 13.171875 -64.445312 13.875 -62.515625 15.28125 -61.109375 C 16.6875 -59.703125 18.617188 -59 21.078125 -59 L 38.984375 -59 C 41.441406 -59 43.375 -59.703125 44.78125 -61.109375 C 46.1875 -62.515625 46.890625 -63.21875 46.890625 -63.21875 Z M 46.890625 -4.21875 C 46.890625 -4.21875 46.890625 -5.445312 46.890625 -7.90625 L 46.890625 -25.546875 C 46.890625 -28.003906 46.1875 -29.9375 44.78125 -31.34375 C 43.375 -32.75 41.441406 -33.453125 38.984375 -33.453125 L 21.078125 -33.453125 C 18.617188 -33.453125 16.6875 -32.75 15.28125 -31.34375 C 13.875 -29.9375 13.171875 -28.003906 13.171875 -25.546875 L 13.171875 -7.90625 C 13.171875 -5.445312 13.875 -3.515625 15.28125 -2.109375 C 16.6875 -0.703125 18.617188 0 21.078125 0 L 38.984375 0 C 41.441406 0 43.375 -0.703125 44.78125 -2.109375 C 46.1875 -3.515625 46.890625 -4.21875 46.890625 -4.21875 Z M 46.890625 -4.21875 " })))));
547
- var Ve = {
546
+ }, ht = (t) => /* @__PURE__ */ r.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", xmlnsXlink: "http://www.w3.org/1999/xlink", width: 500, zoomAndPan: "magnify", viewBox: "0 0 375 374.999991", height: 500, preserveAspectRatio: "xMidYMid meet", ...t }, /* @__PURE__ */ r.createElement("defs", null, /* @__PURE__ */ r.createElement("g", null), /* @__PURE__ */ r.createElement("clipPath", { id: "6ca7e2bf04" }, /* @__PURE__ */ r.createElement("path", { d: "M 265.136719 0 L 375 109.863281 L 375 265.136719 L 265.136719 375 L 109.863281 375 L 0 265.136719 L 0 109.863281 L 109.863281 0 Z M 265.136719 0 ", clipRule: "nonzero" })), /* @__PURE__ */ r.createElement("clipPath", { id: "2c77c820c6" }, /* @__PURE__ */ r.createElement("path", { d: "M 12.878906 12.878906 L 362.121094 12.878906 L 362.121094 362.121094 L 12.878906 362.121094 Z M 12.878906 12.878906 ", clipRule: "nonzero" })), /* @__PURE__ */ r.createElement("clipPath", { id: "3d94df7d66" }, /* @__PURE__ */ r.createElement("path", { d: "M 259.804688 12.878906 L 362.121094 115.195312 L 362.121094 259.804688 L 259.804688 362.121094 L 115.195312 362.121094 L 12.878906 259.804688 L 12.878906 115.195312 L 115.195312 12.878906 Z M 259.804688 12.878906 ", clipRule: "nonzero" })), /* @__PURE__ */ r.createElement("clipPath", { id: "8793709a64" }, /* @__PURE__ */ r.createElement("path", { d: "M 12.878906 12.878906 L 362.109375 12.878906 L 362.109375 362.109375 L 12.878906 362.109375 Z M 12.878906 12.878906 ", clipRule: "nonzero" })), /* @__PURE__ */ r.createElement("clipPath", { id: "fdb3fe29d8" }, /* @__PURE__ */ r.createElement("path", { d: "M 259.796875 12.878906 L 362.109375 115.191406 L 362.109375 259.796875 L 259.796875 362.109375 L 115.191406 362.109375 L 12.878906 259.796875 L 12.878906 115.191406 L 115.191406 12.878906 Z M 259.796875 12.878906 ", clipRule: "nonzero" }))), /* @__PURE__ */ r.createElement("g", { clipPath: "url(#6ca7e2bf04)" }, /* @__PURE__ */ r.createElement("rect", { x: -37.5, width: 450, fill: "#b91c1c", y: -37.499999, height: 449.999989, fillOpacity: 1 })), /* @__PURE__ */ r.createElement("g", { clipPath: "url(#2c77c820c6)" }, /* @__PURE__ */ r.createElement("g", { clipPath: "url(#3d94df7d66)" }, /* @__PURE__ */ r.createElement("path", { fill: "#b91c1c", d: "M 12.878906 12.878906 L 362.121094 12.878906 L 362.121094 362.121094 L 12.878906 362.121094 Z M 12.878906 12.878906 ", fillOpacity: 1, fillRule: "nonzero" }))), /* @__PURE__ */ r.createElement("g", { clipPath: "url(#8793709a64)" }, /* @__PURE__ */ r.createElement("g", { clipPath: "url(#fdb3fe29d8)" }, /* @__PURE__ */ r.createElement("path", { strokeLinecap: "butt", transform: "matrix(0.75, 0, 0, 0.75, 12.879396, 12.879392)", fill: "none", strokeLinejoin: "miter", d: "M 329.223327 -0.000647072 L 465.640003 136.416029 L 465.640003 329.223333 L 329.223327 465.640009 L 136.416023 465.640009 L -0.000653072 329.223333 L -0.000653072 136.416029 L 136.416023 -0.000647072 Z M 329.223327 -0.000647072 ", stroke: "#ffffff", strokeWidth: 34, strokeOpacity: 1, strokeMiterlimit: 4 }))), /* @__PURE__ */ r.createElement("g", { fill: "#ffffff", fillOpacity: 1 }, /* @__PURE__ */ r.createElement("g", { transform: "translate(111.648432, 267.442446)" }, /* @__PURE__ */ r.createElement("g", null, /* @__PURE__ */ r.createElement("path", { d: "M 2.828125 0 L 56.25 -79.859375 L 3.046875 -159.609375 L 37.28125 -159.609375 L 75.90625 -98.046875 L 114.53125 -159.609375 L 148.765625 -159.609375 L 95.5625 -79.859375 L 148.984375 0 L 114.765625 0 L 75.671875 -60.65625 L 37.046875 0 Z M 2.828125 0 " }))))), xt = (t) => /* @__PURE__ */ r.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", xmlnsXlink: "http://www.w3.org/1999/xlink", width: 500, zoomAndPan: "magnify", viewBox: "0 0 375 374.999991", height: 500, preserveAspectRatio: "xMidYMid meet", ...t }, /* @__PURE__ */ r.createElement("defs", null, /* @__PURE__ */ r.createElement("g", null), /* @__PURE__ */ r.createElement("clipPath", { id: "30562604dd" }, /* @__PURE__ */ r.createElement("path", { d: "M 187.5 0 C 83.945312 0 0 83.945312 0 187.5 C 0 291.054688 83.945312 375 187.5 375 C 291.054688 375 375 291.054688 375 187.5 C 375 83.945312 291.054688 0 187.5 0 Z M 187.5 0 ", clipRule: "nonzero" })), /* @__PURE__ */ r.createElement("clipPath", { id: "971fcd5f72" }, /* @__PURE__ */ r.createElement("path", { d: "M 18.570312 18.570312 L 356.429688 18.570312 L 356.429688 356.429688 L 18.570312 356.429688 Z M 18.570312 18.570312 ", clipRule: "nonzero" })), /* @__PURE__ */ r.createElement("clipPath", { id: "e891a7f57e" }, /* @__PURE__ */ r.createElement("path", { d: "M 187.5 18.570312 C 94.203125 18.570312 18.570312 94.203125 18.570312 187.5 C 18.570312 280.796875 94.203125 356.429688 187.5 356.429688 C 280.796875 356.429688 356.429688 280.796875 356.429688 187.5 C 356.429688 94.203125 280.796875 18.570312 187.5 18.570312 Z M 187.5 18.570312 ", clipRule: "nonzero" })), /* @__PURE__ */ r.createElement("clipPath", { id: "19a9ddc130" }, /* @__PURE__ */ r.createElement("path", { d: "M 18.570312 18.570312 L 356.070312 18.570312 L 356.070312 356.070312 L 18.570312 356.070312 Z M 18.570312 18.570312 ", clipRule: "nonzero" })), /* @__PURE__ */ r.createElement("clipPath", { id: "5e650d5bd0" }, /* @__PURE__ */ r.createElement("path", { d: "M 187.496094 18.570312 C 94.199219 18.570312 18.570312 94.199219 18.570312 187.496094 C 18.570312 280.792969 94.199219 356.421875 187.496094 356.421875 C 280.792969 356.421875 356.421875 280.792969 356.421875 187.496094 C 356.421875 94.199219 280.792969 18.570312 187.496094 18.570312 Z M 187.496094 18.570312 ", clipRule: "nonzero" }))), /* @__PURE__ */ r.createElement("g", { clipPath: "url(#30562604dd)" }, /* @__PURE__ */ r.createElement("rect", { x: -37.5, width: 450, fill: "#1d4ed8", y: -37.499999, height: 449.999989, fillOpacity: 1 })), /* @__PURE__ */ r.createElement("g", { clipPath: "url(#971fcd5f72)" }, /* @__PURE__ */ r.createElement("g", { clipPath: "url(#e891a7f57e)" }, /* @__PURE__ */ r.createElement("path", { fill: "#1d4ed8", d: "M 18.570312 18.570312 L 356.429688 18.570312 L 356.429688 356.429688 L 18.570312 356.429688 Z M 18.570312 18.570312 ", fillOpacity: 1, fillRule: "nonzero" }))), /* @__PURE__ */ r.createElement("g", { clipPath: "url(#19a9ddc130)" }, /* @__PURE__ */ r.createElement("g", { clipPath: "url(#5e650d5bd0)" }, /* @__PURE__ */ r.createElement("path", { strokeLinecap: "butt", transform: "matrix(0.75, 0, 0, 0.75, 18.570291, 18.570286)", fill: "none", strokeLinejoin: "miter", d: "M 225.234419 0.0000349326 C 100.838577 0.0000349326 0.0000289326 100.838583 0.0000289326 225.234425 C 0.0000289326 349.630266 100.838577 450.468815 225.234419 450.468815 C 349.63026 450.468815 450.468809 349.630266 450.468809 225.234425 C 450.468809 100.838583 349.63026 0.0000349326 225.234419 0.0000349326 Z M 225.234419 0.0000349326 ", stroke: "#ffffff", strokeWidth: 34, strokeOpacity: 1, strokeMiterlimit: 4 }))), /* @__PURE__ */ r.createElement("g", { fill: "#ffffff", fillOpacity: 1 }, /* @__PURE__ */ r.createElement("g", { transform: "translate(136.121787, 300.837436)" }, /* @__PURE__ */ r.createElement("g", null, /* @__PURE__ */ r.createElement("path", { d: "M 60 -193.78125 C 54.707031 -193.78125 50.109375 -195.734375 46.203125 -199.640625 C 42.296875 -203.554688 40.34375 -208.15625 40.34375 -213.4375 C 40.34375 -218.726562 42.296875 -223.328125 46.203125 -227.234375 C 50.109375 -231.140625 54.707031 -233.09375 60 -233.09375 C 65.28125 -233.09375 69.875 -231.140625 73.78125 -227.234375 C 77.695312 -223.328125 79.65625 -218.726562 79.65625 -213.4375 C 79.65625 -208.15625 77.695312 -203.554688 73.78125 -199.640625 C 69.875 -195.734375 65.28125 -193.78125 60 -193.78125 Z M 45.171875 4.828125 C 39.191406 4.828125 35.28125 2.414062 33.4375 -2.40625 C 31.601562 -7.238281 30.6875 -13.675781 30.6875 -21.71875 C 30.6875 -34.59375 31.773438 -47.234375 33.953125 -59.640625 C 36.140625 -72.054688 38.328125 -83.894531 40.515625 -95.15625 C 42.703125 -106.425781 43.796875 -116.890625 43.796875 -126.546875 C 43.796875 -129.078125 43.675781 -131.832031 43.4375 -134.8125 C 43.207031 -137.800781 42.632812 -140.101562 41.71875 -141.71875 C 38.039062 -139.414062 33.269531 -135.617188 27.40625 -130.328125 C 21.550781 -125.046875 16.898438 -119.1875 13.453125 -112.75 C 11.835938 -114.363281 11.03125 -116.550781 11.03125 -119.3125 C 11.03125 -123.21875 12.582031 -127.46875 15.6875 -132.0625 C 18.789062 -136.65625 22.925781 -141.078125 28.09375 -145.328125 C 33.269531 -149.585938 38.847656 -153.097656 44.828125 -155.859375 C 50.804688 -158.617188 56.664062 -160 62.40625 -160 C 67.695312 -160 71.085938 -158.734375 72.578125 -156.203125 C 74.078125 -153.671875 74.828125 -150.453125 74.828125 -146.546875 C 74.828125 -140.796875 74.078125 -133.378906 72.578125 -124.296875 C 71.085938 -115.222656 69.363281 -105.515625 67.40625 -95.171875 C 65.457031 -84.828125 63.734375 -74.484375 62.234375 -64.140625 C 60.742188 -53.796875 60 -44.367188 60 -35.859375 C 60 -31.492188 60.226562 -27.414062 60.6875 -23.625 C 61.144531 -19.832031 61.71875 -16.671875 62.40625 -14.140625 C 68.15625 -16.671875 73.613281 -20.40625 78.78125 -25.34375 C 83.957031 -30.28125 87.8125 -34.9375 90.34375 -39.3125 C 91.71875 -37.238281 92.40625 -35.050781 92.40625 -32.75 C 92.40625 -29.070312 90.796875 -25.050781 87.578125 -20.6875 C 84.359375 -16.320312 80.332031 -12.179688 75.5 -8.265625 C 70.675781 -4.359375 65.5625 -1.203125 60.15625 1.203125 C 54.757812 3.617188 49.765625 4.828125 45.171875 4.828125 Z M 45.171875 4.828125 " }))))), vt = (t) => /* @__PURE__ */ r.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", xmlnsXlink: "http://www.w3.org/1999/xlink", width: 500, zoomAndPan: "magnify", viewBox: "0 0 375 374.999991", height: 500, preserveAspectRatio: "xMidYMid meet", ...t }, /* @__PURE__ */ r.createElement("defs", null, /* @__PURE__ */ r.createElement("g", null), /* @__PURE__ */ r.createElement("clipPath", { id: "59a10ac27a" }, /* @__PURE__ */ r.createElement("path", { d: "M 17.179688 32.695312 L 360 32.695312 L 360 337.5 L 17.179688 337.5 Z M 17.179688 32.695312 ", clipRule: "nonzero" })), /* @__PURE__ */ r.createElement("clipPath", { id: "664b27481e" }, /* @__PURE__ */ r.createElement("path", { d: "M 207.042969 43.574219 L 356.394531 304.941406 C 360.242188 311.675781 360.214844 319.953125 356.324219 326.660156 C 352.429688 333.371094 345.257812 337.5 337.5 337.5 L 39.375 337.5 C 31.617188 337.5 24.445312 333.371094 20.554688 326.660156 C 16.660156 319.953125 16.632812 311.675781 20.480469 304.941406 L 169.832031 43.574219 C 173.648438 36.898438 180.746094 32.777344 188.4375 32.777344 C 196.128906 32.777344 203.226562 36.898438 207.042969 43.574219 Z M 207.042969 43.574219 ", clipRule: "nonzero" }))), /* @__PURE__ */ r.createElement("g", { clipPath: "url(#59a10ac27a)" }, /* @__PURE__ */ r.createElement("g", { clipPath: "url(#664b27481e)" }, /* @__PURE__ */ r.createElement("path", { fill: "#d97706", d: "M 1.875 11.015625 L 375.546875 11.015625 L 375.546875 337.5 L 1.875 337.5 Z M 1.875 11.015625 ", fillOpacity: 1, fillRule: "nonzero" }))), /* @__PURE__ */ r.createElement("g", { fill: "#ffffff", fillOpacity: 1 }, /* @__PURE__ */ r.createElement("g", { transform: "translate(158.410439, 295.655517)" }, /* @__PURE__ */ r.createElement("g", null, /* @__PURE__ */ r.createElement("path", { d: "M 46.890625 -63.21875 C 46.890625 -63.21875 46.890625 -64.445312 46.890625 -66.90625 L 46.890625 -176.46875 C 46.890625 -178.925781 46.1875 -180.859375 44.78125 -182.265625 C 43.375 -183.671875 41.441406 -184.375 38.984375 -184.375 L 21.078125 -184.375 C 18.617188 -184.375 16.6875 -183.671875 15.28125 -182.265625 C 13.875 -180.859375 13.171875 -178.925781 13.171875 -176.46875 L 13.171875 -66.90625 C 13.171875 -64.445312 13.875 -62.515625 15.28125 -61.109375 C 16.6875 -59.703125 18.617188 -59 21.078125 -59 L 38.984375 -59 C 41.441406 -59 43.375 -59.703125 44.78125 -61.109375 C 46.1875 -62.515625 46.890625 -63.21875 46.890625 -63.21875 Z M 46.890625 -4.21875 C 46.890625 -4.21875 46.890625 -5.445312 46.890625 -7.90625 L 46.890625 -25.546875 C 46.890625 -28.003906 46.1875 -29.9375 44.78125 -31.34375 C 43.375 -32.75 41.441406 -33.453125 38.984375 -33.453125 L 21.078125 -33.453125 C 18.617188 -33.453125 16.6875 -32.75 15.28125 -31.34375 C 13.875 -29.9375 13.171875 -28.003906 13.171875 -25.546875 L 13.171875 -7.90625 C 13.171875 -5.445312 13.875 -3.515625 15.28125 -2.109375 C 16.6875 -0.703125 18.617188 0 21.078125 0 L 38.984375 0 C 41.441406 0 43.375 -0.703125 44.78125 -2.109375 C 46.1875 -3.515625 46.890625 -4.21875 46.890625 -4.21875 Z M 46.890625 -4.21875 " })))));
547
+ var Xe = {
548
548
  color: void 0,
549
549
  size: void 0,
550
550
  className: void 0,
551
551
  style: void 0,
552
552
  attr: void 0
553
- }, Fe = F.createContext && /* @__PURE__ */ F.createContext(Ve), vt = ["attr", "size", "title"];
553
+ }, Fe = D.createContext && /* @__PURE__ */ D.createContext(Xe), bt = ["attr", "size", "title"];
554
554
  function Et(t, o) {
555
555
  if (t == null) return {};
556
- var n = bt(t, o), s, c;
556
+ var n = yt(t, o), a, i;
557
557
  if (Object.getOwnPropertySymbols) {
558
558
  var u = Object.getOwnPropertySymbols(t);
559
- for (c = 0; c < u.length; c++)
560
- s = u[c], !(o.indexOf(s) >= 0) && Object.prototype.propertyIsEnumerable.call(t, s) && (n[s] = t[s]);
559
+ for (i = 0; i < u.length; i++)
560
+ a = u[i], !(o.indexOf(a) >= 0) && Object.prototype.propertyIsEnumerable.call(t, a) && (n[a] = t[a]);
561
561
  }
562
562
  return n;
563
563
  }
564
- function bt(t, o) {
564
+ function yt(t, o) {
565
565
  if (t == null) return {};
566
566
  var n = {};
567
- for (var s in t)
568
- if (Object.prototype.hasOwnProperty.call(t, s)) {
569
- if (o.indexOf(s) >= 0) continue;
570
- n[s] = t[s];
567
+ for (var a in t)
568
+ if (Object.prototype.hasOwnProperty.call(t, a)) {
569
+ if (o.indexOf(a) >= 0) continue;
570
+ n[a] = t[a];
571
571
  }
572
572
  return n;
573
573
  }
@@ -575,8 +575,8 @@ function pe() {
575
575
  return pe = Object.assign ? Object.assign.bind() : function(t) {
576
576
  for (var o = 1; o < arguments.length; o++) {
577
577
  var n = arguments[o];
578
- for (var s in n)
579
- Object.prototype.hasOwnProperty.call(n, s) && (t[s] = n[s]);
578
+ for (var a in n)
579
+ Object.prototype.hasOwnProperty.call(n, a) && (t[a] = n[a]);
580
580
  }
581
581
  return t;
582
582
  }, pe.apply(this, arguments);
@@ -584,83 +584,83 @@ function pe() {
584
584
  function De(t, o) {
585
585
  var n = Object.keys(t);
586
586
  if (Object.getOwnPropertySymbols) {
587
- var s = Object.getOwnPropertySymbols(t);
588
- o && (s = s.filter(function(c) {
589
- return Object.getOwnPropertyDescriptor(t, c).enumerable;
590
- })), n.push.apply(n, s);
587
+ var a = Object.getOwnPropertySymbols(t);
588
+ o && (a = a.filter(function(i) {
589
+ return Object.getOwnPropertyDescriptor(t, i).enumerable;
590
+ })), n.push.apply(n, a);
591
591
  }
592
592
  return n;
593
593
  }
594
594
  function ge(t) {
595
595
  for (var o = 1; o < arguments.length; o++) {
596
596
  var n = arguments[o] != null ? arguments[o] : {};
597
- o % 2 ? De(Object(n), !0).forEach(function(s) {
598
- yt(t, s, n[s]);
599
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(t, Object.getOwnPropertyDescriptors(n)) : De(Object(n)).forEach(function(s) {
600
- Object.defineProperty(t, s, Object.getOwnPropertyDescriptor(n, s));
597
+ o % 2 ? De(Object(n), !0).forEach(function(a) {
598
+ Ct(t, a, n[a]);
599
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(t, Object.getOwnPropertyDescriptors(n)) : De(Object(n)).forEach(function(a) {
600
+ Object.defineProperty(t, a, Object.getOwnPropertyDescriptor(n, a));
601
601
  });
602
602
  }
603
603
  return t;
604
604
  }
605
- function yt(t, o, n) {
606
- return o = Ct(o), o in t ? Object.defineProperty(t, o, { value: n, enumerable: !0, configurable: !0, writable: !0 }) : t[o] = n, t;
605
+ function Ct(t, o, n) {
606
+ return o = wt(o), o in t ? Object.defineProperty(t, o, { value: n, enumerable: !0, configurable: !0, writable: !0 }) : t[o] = n, t;
607
607
  }
608
- function Ct(t) {
609
- var o = wt(t, "string");
608
+ function wt(t) {
609
+ var o = jt(t, "string");
610
610
  return typeof o == "symbol" ? o : o + "";
611
611
  }
612
- function wt(t, o) {
612
+ function jt(t, o) {
613
613
  if (typeof t != "object" || !t) return t;
614
614
  var n = t[Symbol.toPrimitive];
615
615
  if (n !== void 0) {
616
- var s = n.call(t, o || "default");
617
- if (typeof s != "object") return s;
616
+ var a = n.call(t, o || "default");
617
+ if (typeof a != "object") return a;
618
618
  throw new TypeError("@@toPrimitive must return a primitive value.");
619
619
  }
620
620
  return (o === "string" ? String : Number)(t);
621
621
  }
622
- function Xe(t) {
623
- return t && t.map((o, n) => /* @__PURE__ */ F.createElement(o.tag, ge({
622
+ function Ke(t) {
623
+ return t && t.map((o, n) => /* @__PURE__ */ D.createElement(o.tag, ge({
624
624
  key: n
625
- }, o.attr), Xe(o.child)));
625
+ }, o.attr), Ke(o.child)));
626
626
  }
627
627
  function we(t) {
628
- return (o) => /* @__PURE__ */ F.createElement(jt, pe({
628
+ return (o) => /* @__PURE__ */ D.createElement(Lt, pe({
629
629
  attr: ge({}, t.attr)
630
- }, o), Xe(t.child));
630
+ }, o), Ke(t.child));
631
631
  }
632
- function jt(t) {
632
+ function Lt(t) {
633
633
  var o = (n) => {
634
634
  var {
635
- attr: s,
636
- size: c,
635
+ attr: a,
636
+ size: i,
637
637
  title: u
638
- } = t, f = Et(t, vt), m = c || n.size || "1em", d;
639
- return n.className && (d = n.className), t.className && (d = (d ? d + " " : "") + t.className), /* @__PURE__ */ F.createElement("svg", pe({
638
+ } = t, f = Et(t, bt), m = i || n.size || "1em", p;
639
+ return n.className && (p = n.className), t.className && (p = (p ? p + " " : "") + t.className), /* @__PURE__ */ D.createElement("svg", pe({
640
640
  stroke: "currentColor",
641
641
  fill: "currentColor",
642
642
  strokeWidth: "0"
643
- }, n.attr, s, f, {
644
- className: d,
643
+ }, n.attr, a, f, {
644
+ className: p,
645
645
  style: ge(ge({
646
646
  color: t.color || n.color
647
647
  }, n.style), t.style),
648
648
  height: m,
649
649
  width: m,
650
650
  xmlns: "http://www.w3.org/2000/svg"
651
- }), u && /* @__PURE__ */ F.createElement("title", null, u), t.children);
651
+ }), u && /* @__PURE__ */ D.createElement("title", null, u), t.children);
652
652
  };
653
- return Fe !== void 0 ? /* @__PURE__ */ F.createElement(Fe.Consumer, null, (n) => o(n)) : o(Ve);
653
+ return Fe !== void 0 ? /* @__PURE__ */ D.createElement(Fe.Consumer, null, (n) => o(n)) : o(Xe);
654
654
  }
655
- function Lt(t) {
655
+ function St(t) {
656
656
  return we({ tag: "svg", attr: { viewBox: "0 0 512 512" }, child: [{ tag: "path", attr: { d: "M17.47 250.9C88.82 328.1 158 397.6 224.5 485.5c72.3-143.8 146.3-288.1 268.4-444.37L460 26.06C356.9 135.4 276.8 238.9 207.2 361.9c-48.4-43.6-126.62-105.3-174.38-137z" }, child: [] }] })(t);
657
657
  }
658
- const Je = ae(), Ft = ({ children: t }) => {
659
- const [o, n] = j(!1), [s, c] = j(), [u, f] = j(), O = {
658
+ const Qe = ae(), Dt = ({ children: t }) => {
659
+ const [o, n] = j(!1), [a, i] = j(), [u, f] = j(), _ = {
660
660
  showAlert: o,
661
661
  setShowAlert: n,
662
- typeAlert: s,
663
- setTypeAlert: c,
662
+ typeAlert: a,
663
+ setTypeAlert: i,
664
664
  messageAlert: u,
665
665
  setMessageAlert: f,
666
666
  alertConfig: {
@@ -697,48 +697,48 @@ const Je = ae(), Ft = ({ children: t }) => {
697
697
  progressColor: "bg-warning-progress"
698
698
  }
699
699
  },
700
- getIcon: (P) => {
701
- switch (P) {
700
+ getIcon: (S) => {
701
+ switch (S) {
702
702
  case "danger":
703
- return /* @__PURE__ */ a.jsx(gt, { className: "w-[20px] h-[20px]" });
703
+ return /* @__PURE__ */ s.jsx(ht, { className: "w-[20px] h-[20px]" });
704
704
  case "info":
705
- return /* @__PURE__ */ a.jsx(ht, { className: "w-[20px] h-[20px]" });
705
+ return /* @__PURE__ */ s.jsx(xt, { className: "w-[20px] h-[20px]" });
706
706
  case "success":
707
- return /* @__PURE__ */ a.jsx(Lt, { className: "text-xl" });
707
+ return /* @__PURE__ */ s.jsx(St, { className: "text-xl" });
708
708
  case "warning":
709
- return /* @__PURE__ */ a.jsx(xt, { className: "w-[20px] h-[20px]" });
709
+ return /* @__PURE__ */ s.jsx(vt, { className: "w-[20px] h-[20px]" });
710
710
  }
711
711
  },
712
712
  closeAlert: () => {
713
713
  n(!o);
714
714
  },
715
- activeAlert: (P, p) => {
715
+ activeAlert: (S, d) => {
716
716
  n(!1), setTimeout(() => {
717
- c(P), f(p), n(!0);
717
+ i(S), f(d), n(!0);
718
718
  }, 50);
719
719
  }
720
720
  };
721
- return /* @__PURE__ */ a.jsx(Je.Provider, { value: O, children: t });
721
+ return /* @__PURE__ */ s.jsx(Qe.Provider, { value: _, children: t });
722
722
  }, ie = () => {
723
- const t = se(Je);
723
+ const t = se(Qe);
724
724
  if (t === void 0) throw new Error("Non puoi modificare l'alert");
725
725
  return t;
726
726
  };
727
727
  let ne;
728
- const he = async (t, o, n) => {
728
+ const Ce = async (t, o, n) => {
729
729
  if (ne) return ne;
730
730
  try {
731
- const c = await (await fetch("/config.json")).json(), u = c.baseUri, { unauthorized: f, notFound: m, defaultMessage: d } = c.axiosErrors, C = c.axiosTimeout;
732
- return ne = ut.create({
731
+ const i = await (await fetch("/config.json")).json(), u = i.baseUri, { unauthorized: f, notFound: m, defaultMessage: p } = i.axiosErrors, C = i.axiosTimeout;
732
+ return ne = ft.create({
733
733
  baseURL: u,
734
734
  timeout: C
735
735
  }), ne.interceptors.request.use(
736
- (y) => y
736
+ (E) => E
737
737
  ), ne.interceptors.response.use(
738
- (y) => y,
739
- (y) => {
740
- if (y.response)
741
- switch (t(!0), o("danger"), y.response.status) {
738
+ (E) => E,
739
+ (E) => {
740
+ if (E.response)
741
+ switch (t(!0), o("danger"), E.response.status) {
742
742
  case 401:
743
743
  localStorage.removeItem("accessToken"), n(f);
744
744
  break;
@@ -746,93 +746,93 @@ const he = async (t, o, n) => {
746
746
  n(m);
747
747
  break;
748
748
  default:
749
- n(`${d} ${y.response.status} ${y.response.data.error}`);
749
+ n(`${p} ${E.response.status} ${E.response.data.error}`);
750
750
  }
751
- return Promise.reject(y);
751
+ return Promise.reject(E);
752
752
  }
753
753
  ), ne;
754
- } catch (s) {
755
- console.error(s);
754
+ } catch (a) {
755
+ console.error(a);
756
756
  }
757
- }, Ke = ae(), Dt = ({ children: t }) => {
758
- const { heartbeatEndpoint: o, firstPrivatePath: n, infiniteSession: s, timeDeducted: c, authenticatedEndpoint: u, autoLogin: f, autoLoginEmail: m, autoLoginPassword: d, setCurrentDate: C } = ee(), { setIsLoading: y } = xe(), { setShowAlert: O, setMessageAlert: P, setTypeAlert: p, activeAlert: v } = ie(), x = Ue(), [L, b] = j(null), [g, k] = j(), [w, T] = j(), [D, te] = j(), [W, q] = j(!1), H = async (R = null, A) => {
759
- R && R.preventDefault(), q(!0);
757
+ }, et = ae(), Wt = ({ children: t }) => {
758
+ const { heartbeatEndpoint: o, firstPrivatePath: n, infiniteSession: a, timeDeducted: i, authenticatedEndpoint: u, autoLogin: f, autoLoginEmail: m, autoLoginPassword: p, setCurrentDate: C } = ee(), { setIsLoading: E } = he(), { setShowAlert: _, setMessageAlert: S, setTypeAlert: d, activeAlert: x } = ie(), h = Ue(), [v, y] = j(null), [w, P] = j(), [L, N] = j(), [W, te] = j(), [Y, H] = j(!1), J = async (k = null, M) => {
759
+ k && k.preventDefault(), H(!0);
760
760
  try {
761
- y(!0), O(!1);
762
- const M = await (await he(O, p, P)).post(u, {
763
- auth: A
764
- }), I = M.data.id, re = M.headers.token;
765
- re && (localStorage.setItem("accessToken", re), localStorage.setItem("id", I), b(!0), k(re), x(`${n}${I}`));
766
- } catch (Z) {
767
- console.error(Z);
761
+ E(!0), _(!1);
762
+ const A = await (await Ce(_, d, S)).post(u, {
763
+ auth: M
764
+ }), z = A.data.id, re = A.headers.token, B = A.data;
765
+ re && (localStorage.setItem("accessToken", re), localStorage.setItem("id", z), localStorage.setItem("user", JSON.stringify(B)), y(!0), P(re), h(`${n}${z}`));
766
+ } catch (U) {
767
+ console.error(U);
768
768
  } finally {
769
- q(!1), y(!1);
769
+ H(!1), E(!1);
770
770
  }
771
- }, Y = () => {
772
- localStorage.removeItem("accessToken"), localStorage.removeItem("id"), b(!1), k(null);
771
+ }, Z = () => {
772
+ localStorage.removeItem("accessToken"), localStorage.removeItem("id"), localStorage.removeItem("user"), y(!1), P(null);
773
773
  }, V = async () => {
774
774
  try {
775
- const R = localStorage.getItem("accessToken"), M = (await (await he(O, p, P)).get(
775
+ const k = localStorage.getItem("accessToken"), A = (await (await Ce(_, d, S)).get(
776
776
  `${o}`,
777
777
  { headers: {
778
- Authorization: R
778
+ Authorization: k
779
779
  } }
780
780
  )).headers.token;
781
- localStorage.setItem("accessToken", M), k(M), console.log("nuovo token: ", M, "Data:", C());
782
- } catch (R) {
783
- console.error(R), Y();
781
+ localStorage.setItem("accessToken", A), P(A), console.log("nuovo token: ", A, "Data:", C());
782
+ } catch (k) {
783
+ console.error(k), Z();
784
784
  }
785
785
  }, G = () => {
786
- if (!g)
786
+ if (!w)
787
787
  return;
788
- const A = at(g).exp, Z = Math.floor(Date.now() / 1e3), M = (A - Z) * 1e3;
789
- te(M), T(M - c);
788
+ const M = it(w).exp, U = Math.floor(Date.now() / 1e3), A = (M - U) * 1e3;
789
+ te(A), N(A - i);
790
790
  };
791
- z(() => {
791
+ I(() => {
792
792
  if (localStorage.getItem("accessToken"))
793
- b(!0);
793
+ y(!0);
794
794
  else {
795
- b(!1);
795
+ y(!1);
796
796
  return;
797
797
  }
798
- }, []), z(() => {
799
- const R = localStorage.getItem("accessToken");
800
- f && !R && !W && H(null, {
798
+ }, []), I(() => {
799
+ const k = localStorage.getItem("accessToken");
800
+ f && !k && !Y && J(null, {
801
801
  email: m,
802
- password: d
802
+ password: p
803
803
  });
804
- }, [f, W]), z(() => {
804
+ }, [f, Y]), I(() => {
805
805
  G();
806
- let R;
807
- s && g && w && (R = setInterval(() => {
806
+ let k;
807
+ a && w && L && (k = setInterval(() => {
808
808
  V();
809
- }, w));
810
- let A;
811
- return !s && g && D && (A = setTimeout(() => {
812
- Y(), v("danger", "Sessione scaduta");
813
- }, D)), () => {
814
- R && clearInterval(R), A && clearTimeout(A);
809
+ }, L));
810
+ let M;
811
+ return !a && w && W && (M = setTimeout(() => {
812
+ Z(), x("danger", "Sessione scaduta");
813
+ }, W)), () => {
814
+ k && clearInterval(k), M && clearTimeout(M);
815
815
  };
816
- }, [g, w]), z(() => {
817
- L || f && !W && H(null, {
816
+ }, [w, L]), I(() => {
817
+ v || f && !Y && J(null, {
818
818
  email: m,
819
- password: d
819
+ password: p
820
820
  });
821
- }, [L]);
821
+ }, [v]);
822
822
  const X = {
823
- isAuthenticated: L,
824
- setIsAuthenticated: b,
825
- login: H,
826
- logout: Y,
827
- setCurrentToken: k
823
+ isAuthenticated: v,
824
+ setIsAuthenticated: y,
825
+ login: J,
826
+ logout: Z,
827
+ setCurrentToken: P
828
828
  };
829
- return /* @__PURE__ */ a.jsx(Ke.Provider, { value: X, children: t });
829
+ return /* @__PURE__ */ s.jsx(et.Provider, { value: X, children: t });
830
830
  }, je = () => {
831
- const t = se(Ke);
831
+ const t = se(et);
832
832
  if (t === void 0) throw new Error("Non sei dentro al Auth Provider");
833
833
  return t;
834
- }, Qe = ae(), Wt = ({ children: t, publicRoutes: o = [], privateRoutes: n = [] }) => /* @__PURE__ */ a.jsx(Qe.Provider, { value: { publicRoutes: o, privateRoutes: n }, children: t }), St = () => {
835
- const t = se(Qe);
834
+ }, tt = ae(), Yt = ({ children: t, publicRoutes: o = [], privateRoutes: n = [] }) => /* @__PURE__ */ s.jsx(tt.Provider, { value: { publicRoutes: o, privateRoutes: n }, children: t }), Ot = () => {
835
+ const t = se(tt);
836
836
  if (t === void 0)
837
837
  throw new Error(
838
838
  `Errore: Le rotte non sono state inizializzate correttamente.
@@ -846,149 +846,151 @@ Esempio:
846
846
  </RouteProvider>`
847
847
  );
848
848
  return t;
849
- }, et = ae(), Yt = ({ children: t }) => {
850
- const { login: o } = je(), { clearLoginFormOnError: n } = ee(), s = {
849
+ }, rt = ae(), Zt = ({ children: t }) => {
850
+ const { login: o } = je(), { clearLoginFormOnError: n } = ee(), a = {
851
851
  email: "",
852
852
  password: ""
853
- }, [c, u] = j("Accedi"), [f, m] = j("Email"), [d, C] = j("email"), [y, O] = j("example@example.it"), [P, p] = j("Accedi"), [v, x] = j(s), [L, b] = j(), [g, k] = j(), [w, T] = j(), [D, te] = j(), [W, q] = j({}), V = {
854
- overrideStyle: W,
855
- setOverrideStyle: q,
856
- title: c,
853
+ }, [i, u] = j("Accedi"), [f, m] = j("Email"), [p, C] = j("email"), [E, _] = j("example@example.it"), [S, d] = j("Accedi"), [x, h] = j(a), [v, y] = j(), [w, P] = j(), [L, N] = j(), [W, te] = j(), [Y, H] = j({}), V = {
854
+ overrideStyle: Y,
855
+ setOverrideStyle: H,
856
+ title: i,
857
857
  setTitle: u,
858
858
  label: f,
859
859
  setLabel: m,
860
- type: d,
860
+ type: p,
861
861
  setType: C,
862
- placeholder: y,
863
- setPlaceholder: O,
864
- buttonText: P,
865
- setButtonText: p,
866
- formData: v,
867
- setFormData: x,
868
- LogoImg: L,
869
- setLogoImg: b,
870
- styleCardForm: g,
871
- setStyleCardForm: k,
872
- styleContainerLogo: w,
873
- setStyleContainerLogo: T,
874
- styleLogo: D,
862
+ placeholder: E,
863
+ setPlaceholder: _,
864
+ buttonText: S,
865
+ setButtonText: d,
866
+ formData: x,
867
+ setFormData: h,
868
+ LogoImg: v,
869
+ setLogoImg: y,
870
+ styleCardForm: w,
871
+ setStyleCardForm: P,
872
+ styleContainerLogo: L,
873
+ setStyleContainerLogo: N,
874
+ styleLogo: W,
875
875
  setStyleLogo: te,
876
876
  changeData: (G, X) => {
877
- x((R) => ({ ...R, [G]: X }));
877
+ h((k) => ({ ...k, [G]: X }));
878
878
  },
879
879
  handleLogin: (G) => {
880
- o(G, v), n && x(s);
880
+ o(G, x), n && h(a);
881
881
  }
882
882
  };
883
- return /* @__PURE__ */ a.jsx(et.Provider, { value: V, children: t });
884
- }, tt = () => {
885
- const t = se(et);
883
+ return /* @__PURE__ */ s.jsx(rt.Provider, { value: V, children: t });
884
+ }, ot = () => {
885
+ const t = se(rt);
886
886
  if (t === void 0) throw new Error("Non puoi modificare La login");
887
887
  return t;
888
888
  };
889
- function rt(t) {
889
+ function nt(t) {
890
890
  return we({ tag: "svg", attr: { version: "1.1", viewBox: "0 0 16 16" }, child: [{ tag: "path", attr: { d: "M8 0c-4.355 0-7.898 3.481-7.998 7.812 0.092-3.779 2.966-6.812 6.498-6.812 3.59 0 6.5 3.134 6.5 7 0 0.828 0.672 1.5 1.5 1.5s1.5-0.672 1.5-1.5c0-4.418-3.582-8-8-8zM8 16c4.355 0 7.898-3.481 7.998-7.812-0.092 3.779-2.966 6.812-6.498 6.812-3.59 0-6.5-3.134-6.5-7 0-0.828-0.672-1.5-1.5-1.5s-1.5 0.672-1.5 1.5c0 4.418 3.582 8 8 8z" }, child: [] }] })(t);
891
891
  }
892
- const Ot = () => {
893
- const { loadingProps: t } = xe(), { spinner: o = !0, spinnerStyle: n, text: s, textStyle: c, children: u, containerStyle: f, overrideStyle: m = {} } = t;
894
- return /* @__PURE__ */ a.jsxs("div", { className: m.container || `fixed top-0 bottom-0 left-0 right-0 flex items-center justify-center bg-loading-bg z-[999] ${f}`, children: [
895
- o && /* @__PURE__ */ a.jsx(rt, { className: m.spinner || `text-[20rem] relative animate-spin text-spinner ${n}` }),
896
- u || /* @__PURE__ */ a.jsx("p", { className: m.text || `text-white text-2xl select-none absolute ${c}`, children: s || "Loading..." })
892
+ const Pt = () => {
893
+ const { loadingProps: t } = he(), { spinner: o = !0, spinnerStyle: n, text: a, textStyle: i, children: u, containerStyle: f, overrideStyle: m = {} } = t;
894
+ return /* @__PURE__ */ s.jsxs("div", { className: m.container || `fixed top-0 bottom-0 left-0 right-0 flex items-center justify-center bg-loading-bg z-[999] ${f}`, children: [
895
+ o && /* @__PURE__ */ s.jsx(nt, { className: m.spinner || `text-[20rem] relative animate-spin text-spinner ${n}` }),
896
+ u || /* @__PURE__ */ s.jsx("p", { className: m.text || `text-white text-2xl select-none absolute ${i}`, children: a || "Loading..." })
897
897
  ] });
898
898
  };
899
- function Pt(t) {
899
+ function kt(t) {
900
900
  return we({ tag: "svg", attr: { viewBox: "0 0 15 15", fill: "none" }, child: [{ tag: "path", attr: { fillRule: "evenodd", clipRule: "evenodd", d: "M11.7816 4.03157C12.0062 3.80702 12.0062 3.44295 11.7816 3.2184C11.5571 2.99385 11.193 2.99385 10.9685 3.2184L7.50005 6.68682L4.03164 3.2184C3.80708 2.99385 3.44301 2.99385 3.21846 3.2184C2.99391 3.44295 2.99391 3.80702 3.21846 4.03157L6.68688 7.49999L3.21846 10.9684C2.99391 11.193 2.99391 11.557 3.21846 11.7816C3.44301 12.0061 3.80708 12.0061 4.03164 11.7816L7.50005 8.31316L10.9685 11.7816C11.193 12.0061 11.5571 12.0061 11.7816 11.7816C12.0062 11.557 12.0062 11.193 11.7816 10.9684L8.31322 7.49999L11.7816 4.03157Z", fill: "currentColor" }, child: [] }] })(t);
901
901
  }
902
902
  const We = () => {
903
- const { messageAlert: t, typeAlert: o, alertConfig: n, getIcon: s, closeAlert: c } = ie(), { alertTimeout: u } = ee(), [f, m] = j(0), { bgColor: d, textColor: C, buttonBg: y, hoverBg: O, focusRing: P, progressColor: p } = n[o];
904
- return z(() => {
905
- let v;
906
- const L = 100 / (u / 100);
907
- v = setInterval(() => {
908
- m((g) => g >= 100 ? (clearInterval(v), 100) : g + L);
903
+ const { messageAlert: t, typeAlert: o, alertConfig: n, getIcon: a, closeAlert: i } = ie(), { alertTimeout: u } = ee(), [f, m] = j(0), { bgColor: p, textColor: C, buttonBg: E, hoverBg: _, focusRing: S, progressColor: d } = n[o];
904
+ return I(() => {
905
+ let x;
906
+ const v = 100 / (u / 100);
907
+ x = setInterval(() => {
908
+ m((w) => w >= 100 ? (clearInterval(x), 100) : w + v);
909
909
  }, 100);
910
- const b = setTimeout(() => {
911
- c();
910
+ const y = setTimeout(() => {
911
+ i();
912
912
  }, u);
913
913
  return () => {
914
- clearTimeout(b), clearInterval(v);
914
+ clearTimeout(y), clearInterval(x);
915
915
  };
916
- }, []), /* @__PURE__ */ a.jsxs("div", { className: `flex items-center p-4 pt-6 ${C} rounded-lg ${d} mx-auto max-sm:min-w-[280px] sm:max-w-1/3 fixed top-[calc(100vh-100px)] sm:right-10 right-1/2 translate-x-1/2 sm:translate-0 z-100`, role: "alert", children: [
917
- /* @__PURE__ */ a.jsx("div", { className: "w-full bg-gray-200 rounded-t-lg overflow-hidden h-2.5 absolute top-0 left-0 right-0", children: /* @__PURE__ */ a.jsx("div", { className: `${p} h-2.5 rounded-t-lg`, style: { width: `${f}%` } }) }),
918
- s(o),
919
- /* @__PURE__ */ a.jsx("div", { className: "px-4 text-sm font-medium", children: t }),
920
- /* @__PURE__ */ a.jsx(
916
+ }, []), /* @__PURE__ */ s.jsxs("div", { className: `flex items-center p-4 pt-6 ${C} rounded-lg ${p} mx-auto max-sm:min-w-[280px] sm:max-w-1/3 fixed top-[calc(100vh-100px)] sm:right-10 right-1/2 translate-x-1/2 sm:translate-0 z-100`, role: "alert", children: [
917
+ /* @__PURE__ */ s.jsx("div", { className: "w-full bg-gray-200 rounded-t-lg overflow-hidden h-2.5 absolute top-0 left-0 right-0", children: /* @__PURE__ */ s.jsx("div", { className: `${d} h-2.5 rounded-t-lg`, style: { width: `${f}%` } }) }),
918
+ a(o),
919
+ /* @__PURE__ */ s.jsx("div", { className: "px-4 text-sm font-medium", children: t }),
920
+ /* @__PURE__ */ s.jsx(
921
921
  "button",
922
922
  {
923
923
  type: "button",
924
- className: `ms-auto ${y} rounded-lg focus:ring-2 ${P} p-1.5 ${O} inline-flex items-center justify-center h-8 w-8 cursor-pointer`,
924
+ className: `ms-auto ${E} rounded-lg focus:ring-2 ${S} p-1.5 ${_} inline-flex items-center justify-center h-8 w-8 cursor-pointer`,
925
925
  title: "Close",
926
- onClick: c,
927
- children: /* @__PURE__ */ a.jsx(Pt, { className: "text-xl" })
926
+ onClick: i,
927
+ children: /* @__PURE__ */ s.jsx(kt, { className: "text-xl" })
928
928
  }
929
929
  )
930
930
  ] });
931
- }, kt = (t) => {
932
- const { isLoading: o } = xe(), { showAlert: n } = ie(), s = st(), {
933
- isMain: c = !0,
931
+ }, _t = (t) => {
932
+ const { isLoading: o } = he(), { showAlert: n } = ie(), a = qe(), {
933
+ isMain: i = !0,
934
934
  headerComponent: u = null,
935
935
  showHeaderOnLogin: f = !1,
936
936
  headerExcludedRoutes: m = [],
937
- footerComponent: d = null,
937
+ footerComponent: p = null,
938
938
  showFooterOnLogin: C = !1,
939
- footerExcludedRoutes: y = []
940
- } = t, O = m.some((x) => ze(x, s.pathname));
941
- let P;
942
- s.pathname === "/" ? P = u && f : P = u && !O;
943
- const p = y.some((x) => ze(x, s.pathname));
944
- let v;
945
- return s.pathname === "/" ? v = d && C : v = d && !p, /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
946
- o && /* @__PURE__ */ a.jsx(Ot, {}),
947
- n && /* @__PURE__ */ a.jsx(We, {}),
948
- P && u,
949
- c ? /* @__PURE__ */ a.jsxs("main", { className: o ? "hidden" : "", children: [
950
- n && /* @__PURE__ */ a.jsx(We, {}),
951
- /* @__PURE__ */ a.jsx(Ce, {})
952
- ] }) : /* @__PURE__ */ a.jsx(Ce, {}),
953
- v && d
939
+ footerExcludedRoutes: E = []
940
+ } = t, _ = m.some((h) => ze(h, a.pathname));
941
+ let S;
942
+ a.pathname === "/" ? S = u && f : S = u && !_;
943
+ const d = E.some((h) => ze(h, a.pathname));
944
+ let x;
945
+ return a.pathname === "/" ? x = p && C : x = p && !d, /* @__PURE__ */ s.jsxs(s.Fragment, { children: [
946
+ o && /* @__PURE__ */ s.jsx(Pt, {}),
947
+ n && /* @__PURE__ */ s.jsx(We, {}),
948
+ S && u,
949
+ i ? /* @__PURE__ */ s.jsxs("main", { className: o ? "hidden" : "", children: [
950
+ n && /* @__PURE__ */ s.jsx(We, {}),
951
+ /* @__PURE__ */ s.jsx(ye, {})
952
+ ] }) : /* @__PURE__ */ s.jsx(ye, {}),
953
+ x && p
954
954
  ] });
955
955
  }, Ye = (t) => {
956
956
  const {
957
957
  inputType: o,
958
958
  inputId: n,
959
- inputPlaceholder: s,
960
- inputRequired: c,
959
+ inputPlaceholder: a,
960
+ inputRequired: i,
961
961
  inputValue: u,
962
962
  inputChange: f,
963
963
  autoFocus: m,
964
- inputStyle: d,
965
- overrideStyle: C
966
- } = t, O = ["text", "email", "password", "search", "tel", "url"].includes(o) ? o : "text";
967
- return /* @__PURE__ */ a.jsx(
964
+ inputStyle: p,
965
+ overrideStyle: C,
966
+ disabled: E
967
+ } = t, S = ["text", "email", "password", "search", "tel", "url"].includes(o) ? o : "text";
968
+ return /* @__PURE__ */ s.jsx(
968
969
  "input",
969
970
  {
970
- type: O,
971
+ type: S,
971
972
  autoFocus: m,
972
973
  id: n,
973
- className: C || `bg-input-bg border border-input-border text-input-text text-input-placeholder input-rounded focus:ring focus:ring-primary focus:border-primary focus:outline-none focus:shadow-(--shadow-primary-input) block w-full p-input ${d}`,
974
- placeholder: s,
975
- required: c ?? !0,
974
+ className: C || `bg-input-bg border border-input-border text-input-text text-input-placeholder input-rounded focus:ring focus:ring-primary focus:border-primary focus:outline-none focus:shadow-(--shadow-primary-input) block w-full p-input ${p}`,
975
+ placeholder: a,
976
+ required: i ?? !0,
976
977
  value: u,
977
- onChange: f
978
+ onChange: f,
979
+ disabled: E
978
980
  }
979
981
  );
980
- }, Ze = ({ label: t, labelId: o, labelStyle: n, overrideStyle: s }) => /* @__PURE__ */ a.jsx("label", { htmlFor: o, className: s || `show-label mb-2 text-input-label font-medium text-color-label ${n}`, children: t }), Rt = () => {
981
- const { title: t, label: o, type: n, placeholder: s, buttonText: c, formData: u, changeData: f, handleLogin: m, overrideStyle: d } = tt();
982
- return /* @__PURE__ */ a.jsxs("form", { onSubmit: m, className: d.form || "form-size", children: [
983
- /* @__PURE__ */ a.jsx("h1", { className: d.title || "text-form-title-size show-title title-position m-form-title", children: t }),
984
- /* @__PURE__ */ a.jsxs("div", { className: d.containerEmail || "flex justify-center flex-col gap-1 m-input-form input-size mx-auto", children: [
985
- /* @__PURE__ */ a.jsx(Ze, { labelId: "user-email", label: o }),
986
- /* @__PURE__ */ a.jsx(
982
+ }, Ze = ({ label: t, labelId: o, labelStyle: n, overrideStyle: a }) => /* @__PURE__ */ s.jsx("label", { htmlFor: o, className: a || `show-label mb-2 text-input-label font-medium text-color-label ${n}`, children: t }), Rt = () => {
983
+ const { title: t, label: o, type: n, placeholder: a, buttonText: i, formData: u, changeData: f, handleLogin: m, overrideStyle: p } = ot();
984
+ return /* @__PURE__ */ s.jsxs("form", { onSubmit: m, className: p.form || "form-size", children: [
985
+ /* @__PURE__ */ s.jsx("h1", { className: p.title || "text-form-title-size show-title title-position m-form-title", children: t }),
986
+ /* @__PURE__ */ s.jsxs("div", { className: p.containerEmail || "flex justify-center flex-col gap-1 m-input-form input-size mx-auto", children: [
987
+ /* @__PURE__ */ s.jsx(Ze, { labelId: "user-email", label: o }),
988
+ /* @__PURE__ */ s.jsx(
987
989
  Ye,
988
990
  {
989
991
  inputType: n,
990
992
  inputId: "user-email",
991
- inputPlaceholder: s,
993
+ inputPlaceholder: a,
992
994
  inputValue: u.email,
993
995
  inputChange: (C) => {
994
996
  f("email", C.target.value);
@@ -997,9 +999,9 @@ const We = () => {
997
999
  }
998
1000
  )
999
1001
  ] }),
1000
- /* @__PURE__ */ a.jsxs("div", { className: d.containerPassword || "flex justify-center flex-col gap-1 my-4 input-size mx-auto", children: [
1001
- /* @__PURE__ */ a.jsx(Ze, { labelId: "password", label: "Password" }),
1002
- /* @__PURE__ */ a.jsx(
1002
+ /* @__PURE__ */ s.jsxs("div", { className: p.containerPassword || "flex justify-center flex-col gap-1 my-4 input-size mx-auto", children: [
1003
+ /* @__PURE__ */ s.jsx(Ze, { labelId: "password", label: "Password" }),
1004
+ /* @__PURE__ */ s.jsx(
1003
1005
  Ye,
1004
1006
  {
1005
1007
  inputType: "password",
@@ -1012,101 +1014,91 @@ const We = () => {
1012
1014
  }
1013
1015
  )
1014
1016
  ] }),
1015
- /* @__PURE__ */ a.jsx("div", { className: d.containerButton || "flex button-position items-center m-primary-button", children: /* @__PURE__ */ a.jsx("button", { className: d.button || "font-bold cursor-pointer shadow-(--shadow-primary) transition-all duration-200 hover:shadow-(--shadow-primary-hover) active:shadow-(--shadow-primary-active) active:translate-y-[2px] p-primary-button rounded-primary-button bg-primary hover:bg-primary-hover text-primary-text", children: c }) })
1017
+ /* @__PURE__ */ s.jsx("div", { className: p.containerButton || "flex button-position items-center m-primary-button", children: /* @__PURE__ */ s.jsx("button", { className: p.button || "font-bold cursor-pointer shadow-(--shadow-primary) transition-all duration-200 hover:shadow-(--shadow-primary-hover) active:shadow-(--shadow-primary-active) active:translate-y-[2px] p-primary-button rounded-primary-button bg-primary hover:bg-primary-hover text-primary-text", children: i }) })
1016
1018
  ] });
1017
1019
  }, Tt = ({ Logo: t }) => {
1018
- const { activeAlert: o } = ie(), { styleCardForm: n, styleContainerLogo: s, styleLogo: c, overrideStyle: u } = tt(), { firstPrivatePath: f } = ee(), m = Ue();
1019
- return z(() => {
1020
- const d = localStorage.getItem("id");
1021
- localStorage.getItem("accessToken") && d && (m(`${f}${d}`), o("info", "Sei già loggato"));
1022
- }, []), /* @__PURE__ */ a.jsx("section", { id: "login-page", children: /* @__PURE__ */ a.jsx("div", { className: u.container || "container mx-auto flex items-center justify-center h-screen", children: /* @__PURE__ */ a.jsxs("div", { className: u.cardForm || `bg-form card-style card-size flex flex-col sm:flex-row sm:items-center justify-center ${n}`, children: [
1023
- /* @__PURE__ */ a.jsx("div", { className: u.containerLogo || `basis-1/2 flex items-center justify-center ${s}`, children: t && /* @__PURE__ */ a.jsx(t, { className: u.logo || `login-logo h-full sm:h-auto ${c}` }) }),
1024
- /* @__PURE__ */ a.jsx(Rt, {})
1020
+ const { styleCardForm: o, styleContainerLogo: n, styleLogo: a, overrideStyle: i } = ot(), { firstPrivatePath: u } = ee(), f = Ue();
1021
+ return I(() => {
1022
+ const m = localStorage.getItem("id");
1023
+ localStorage.getItem("accessToken") && m && f(`${u}${m}`);
1024
+ }, []), /* @__PURE__ */ s.jsx("section", { id: "login-page", children: /* @__PURE__ */ s.jsx("div", { className: i.container || "container mx-auto flex items-center justify-center h-screen", children: /* @__PURE__ */ s.jsxs("div", { className: i.cardForm || `bg-form card-style card-size flex flex-col sm:flex-row sm:items-center justify-center ${o}`, children: [
1025
+ /* @__PURE__ */ s.jsx("div", { className: i.containerLogo || `basis-1/2 flex items-center justify-center ${n}`, children: t && /* @__PURE__ */ s.jsx(t, { className: i.logo || `login-logo h-full sm:h-auto ${a}` }) }),
1026
+ /* @__PURE__ */ s.jsx(Rt, {})
1025
1027
  ] }) }) });
1026
- }, _t = () => {
1027
- const { isAuthenticated: t } = je(), { activeAlert: o } = ie(), { autoLogin: n } = ee();
1028
- return z(() => {
1029
- const s = localStorage.getItem("accessToken");
1030
- !t && !s && !n && o("danger", "Non sei autorizzato");
1031
- }, []), t === null ? null : t ? /* @__PURE__ */ a.jsx(Ce, {}) : /* @__PURE__ */ a.jsx(it, { to: "/", replace: !0 });
1032
1028
  }, Nt = () => {
1033
- const { id: t } = lt(), { logout: o, setCurrentToken: n } = je(), { usersEndpoint: s } = ee(), { setIsLoading: c } = xe(), { setShowAlert: u, setTypeAlert: f, setMessageAlert: m, activeAlert: d } = ie(), [C, y] = j({}), [O, P] = j(null), [p, v] = j(!1), x = async () => {
1034
- try {
1035
- c(!0);
1036
- const g = localStorage.getItem("accessToken");
1037
- if (!g) {
1038
- o(), d("danger", "Sessione Scaduta");
1039
- return;
1040
- }
1041
- n(g);
1042
- const T = (await (await he(u, f, m)).get(
1043
- `${s}${t}`,
1044
- { headers: {
1045
- Authorization: g
1046
- } }
1047
- )).data;
1048
- y(T);
1049
- } catch (g) {
1050
- console.error(g), o();
1051
- } finally {
1052
- c(!1);
1053
- }
1054
- }, L = async () => {
1029
+ const { isAuthenticated: t } = je(), { activeAlert: o } = ie(), { autoLogin: n } = ee();
1030
+ return I(() => {
1031
+ const a = localStorage.getItem("accessToken");
1032
+ !t && !a && !n && o("danger", "Non sei autorizzato");
1033
+ }, []), t === null ? null : t ? /* @__PURE__ */ s.jsx(ye, {}) : /* @__PURE__ */ s.jsx(He, { to: "/", replace: !0 });
1034
+ }, At = () => {
1035
+ const { id: t } = lt(), { logout: o, setCurrentToken: n } = je(), { usersEndpoint: a } = ee(), { setIsLoading: i } = he(), { setShowAlert: u, setTypeAlert: f, setMessageAlert: m, activeAlert: p } = ie(), [C, E] = j(null), [_, S] = j(!1), d = JSON.parse(localStorage.getItem("user")), x = async () => {
1055
1036
  try {
1056
- v(!0);
1057
- const g = localStorage.getItem("accessToken");
1058
- if (!g) {
1059
- o(), d("danger", "Sessione Scaduta");
1037
+ S(!0);
1038
+ const v = localStorage.getItem("accessToken");
1039
+ if (!v) {
1040
+ o(), p("danger", "Sessione Scaduta");
1060
1041
  return;
1061
1042
  }
1062
- const T = (await (await he(u, f, m)).get(
1063
- `${s}`,
1043
+ const P = (await (await Ce(u, f, m)).get(
1044
+ `${a}`,
1064
1045
  { headers: {
1065
- Authorization: g
1046
+ Authorization: v
1066
1047
  } }
1067
1048
  )).data;
1068
- P(T);
1069
- } catch (g) {
1070
- console.error(g), c(!1);
1049
+ E(P);
1050
+ } catch (v) {
1051
+ console.error(v), i(!1);
1071
1052
  } finally {
1072
- v(!1);
1053
+ S(!1);
1073
1054
  }
1074
- }, b = () => {
1075
- o(), d("info", "Hai effettuato il logout");
1055
+ }, h = () => {
1056
+ o(), p("info", "Hai effettuato il logout");
1076
1057
  };
1077
- return z(() => {
1078
- x();
1079
- }, []), /* @__PURE__ */ a.jsx("section", { children: /* @__PURE__ */ a.jsxs("div", { className: "container mx-auto py-8", children: [
1080
- /* @__PURE__ */ a.jsxs("div", { className: "flex items-center justify-center gap-8 h-20", children: [
1081
- /* @__PURE__ */ a.jsxs("h1", { className: "text-4xl text-center text-slate-800", children: [
1058
+ return I(() => {
1059
+ const v = localStorage.getItem("accessToken");
1060
+ v && n(v);
1061
+ }, []), /* @__PURE__ */ s.jsx("section", { children: /* @__PURE__ */ s.jsxs("div", { className: "container mx-auto py-8", children: [
1062
+ /* @__PURE__ */ s.jsxs("div", { className: "flex items-center justify-center gap-8 h-20", children: [
1063
+ /* @__PURE__ */ s.jsxs("h1", { className: "text-4xl text-center text-slate-800", children: [
1082
1064
  "Email: ",
1083
- C.email
1065
+ d.email
1084
1066
  ] }),
1085
- /* @__PURE__ */ a.jsx(
1067
+ /* @__PURE__ */ s.jsx(
1086
1068
  "button",
1087
1069
  {
1088
- onClick: b,
1070
+ onClick: h,
1089
1071
  className: "bg-red-500 hover:bg-red-700 text-white font-bold py-2 px-4 rounded-full cursor-pointer shadow-[0_4px_10px_rgba(239,68,68,0.3),0_2px_4px_rgba(239,68,68,0.2)] hover:shadow-[0_6px_14px_rgba(185,28,28,0.4),0_3px_6px_rgba(185,28,28,0.3)] active:shadow-[0_2px_5px_rgba(239,68,68,0.3)] transition-all duration-200 active:translate-y-[2px]",
1090
1072
  children: "Logout"
1091
1073
  }
1092
1074
  )
1093
1075
  ] }),
1094
- /* @__PURE__ */ a.jsx("div", { className: "flex justify-center items-center my-12", children: /* @__PURE__ */ a.jsx(
1095
- "button",
1096
- {
1097
- onClick: L,
1098
- className: "bg-blue-500 hover:bg-blue-700 text-white font-bold py-2 px-4 rounded-full disabled:bg-blue-300 disabled:text-gray-500 disabled:cursor-not-allowed cursor-pointer transition-all duration-200 active:translate-y-[2px] shadow-[0_4px_10px_rgba(59,130,246,0.3),0_2px_4px_rgba(59,130,246,0.2)] hover:shadow-[0_6px_14px_rgba(29,78,216,0.4),0_3px_6px_rgba(29,78,216,0.3)] active:shadow-[0_2px_5px_rgba(59,130,246,0.3)]",
1099
- disabled: p,
1100
- children: "Lista degli utenti"
1101
- }
1102
- ) }),
1103
- /* @__PURE__ */ a.jsx("div", { className: "flex justify-center items-center", children: O && /* @__PURE__ */ a.jsx("ul", { children: O.map((g) => /* @__PURE__ */ a.jsxs("li", { className: "text-xl my-4", children: [
1104
- g.id,
1076
+ /* @__PURE__ */ s.jsxs("div", { className: "flex justify-center items-center my-12 gap-8", children: [
1077
+ /* @__PURE__ */ s.jsx(
1078
+ "button",
1079
+ {
1080
+ onClick: x,
1081
+ className: "bg-blue-500 hover:bg-blue-700 text-white font-bold py-2 px-4 rounded-full disabled:bg-blue-300 disabled:text-gray-500 disabled:cursor-not-allowed cursor-pointer transition-all duration-200 active:translate-y-[2px] shadow-[0_4px_10px_rgba(59,130,246,0.3),0_2px_4px_rgba(59,130,246,0.2)] hover:shadow-[0_6px_14px_rgba(29,78,216,0.4),0_3px_6px_rgba(29,78,216,0.3)] active:shadow-[0_2px_5px_rgba(59,130,246,0.3)]",
1082
+ disabled: _,
1083
+ children: "Lista degli utenti"
1084
+ }
1085
+ ),
1086
+ d.admin && /* @__PURE__ */ s.jsx(
1087
+ ct,
1088
+ {
1089
+ to: `/about/${t}`,
1090
+ className: "bg-green-500 hover:bg-green-700 text-white font-bold py-2 px-4 rounded-full disabled:bg-green-300 disabled:text-gray-500 disabled:cursor-not-allowed cursor-pointer transition-all duration-200 active:translate-y-[2px] shadow-[0_4px_10px_rgba(59,130,246,0.3),0_2px_4px_rgba(59,130,246,0.2)] hover:shadow-[0_6px_14px_rgba(29,78,216,0.4),0_3px_6px_rgba(29,78,216,0.3)] active:shadow-[0_2px_5px_rgba(59,130,246,0.3)]",
1091
+ children: "About Page"
1092
+ }
1093
+ )
1094
+ ] }),
1095
+ /* @__PURE__ */ s.jsx("div", { className: "flex justify-center items-center", children: C && /* @__PURE__ */ s.jsx("ul", { children: C.map((v) => /* @__PURE__ */ s.jsxs("li", { className: "text-xl my-4", children: [
1096
+ v.id,
1105
1097
  " - ",
1106
- g.email
1107
- ] }, `user-${g.id}`)) }) })
1098
+ v.email
1099
+ ] }, `user-${v.id}`)) }) })
1108
1100
  ] }) });
1109
- }, At = (t) => /* @__PURE__ */ r.createElement("svg", { width: "108.41262mm", height: "108.41262mm", viewBox: "0 0 108.41262 108.41262", id: "svg1", xmlSpace: "preserve", xmlnsXlink: "http://www.w3.org/1999/xlink", xmlns: "http://www.w3.org/2000/svg", "xmlns:svg": "http://www.w3.org/2000/svg", ...t }, /* @__PURE__ */ r.createElement("defs", { id: "defs1" }, /* @__PURE__ */ r.createElement("linearGradient", { id: "linearGradient27" }, /* @__PURE__ */ r.createElement("stop", { style: {
1101
+ }, Mt = (t) => /* @__PURE__ */ r.createElement("svg", { width: "108.41262mm", height: "108.41262mm", viewBox: "0 0 108.41262 108.41262", id: "svg1", xmlSpace: "preserve", xmlnsXlink: "http://www.w3.org/1999/xlink", xmlns: "http://www.w3.org/2000/svg", "xmlns:svg": "http://www.w3.org/2000/svg", ...t }, /* @__PURE__ */ r.createElement("defs", { id: "defs1" }, /* @__PURE__ */ r.createElement("linearGradient", { id: "linearGradient27" }, /* @__PURE__ */ r.createElement("stop", { style: {
1110
1102
  stopColor: "#ff0000",
1111
1103
  stopOpacity: 1
1112
1104
  }, offset: 0, id: "stop27" }), /* @__PURE__ */ r.createElement("stop", { style: {
@@ -1152,86 +1144,93 @@ const We = () => {
1152
1144
  strokeWidth: 0,
1153
1145
  strokeOpacity: 1,
1154
1146
  paintOrder: "stroke markers fill"
1155
- }, d: "", id: "path40", transform: "scale(0.26458333)" }))), Zt = (t) => {
1156
- const { publicRoutes: o, privateRoutes: n } = St(), { firstPrivatePath: s } = ee(), {
1157
- logoImg: c = At,
1147
+ }, d: "", id: "path40", transform: "scale(0.26458333)" }))), Ut = (t) => {
1148
+ const { publicRoutes: o, privateRoutes: n } = Ot(), { firstPrivatePath: a } = ee(), {
1149
+ logoImg: i = Mt,
1158
1150
  pathImg: u = "./src/assets/MyWarehouse.svg",
1159
- firstPrivateElement: f = /* @__PURE__ */ a.jsx(Nt, {}),
1151
+ firstPrivateElement: f = /* @__PURE__ */ s.jsx(At, {}),
1160
1152
  globalLayout: m,
1161
- isMain: d,
1153
+ isMain: p,
1162
1154
  headerComponent: C,
1163
- showHeaderOnLogin: y,
1164
- headerExcludedRoutes: O,
1165
- footerComponent: P,
1166
- showFooterOnLogin: p,
1167
- footerExcludedRoutes: v,
1168
- privateProvider: x,
1169
- customProvider: L
1170
- } = t, b = m || /* @__PURE__ */ a.jsx(
1171
- kt,
1155
+ showHeaderOnLogin: E,
1156
+ headerExcludedRoutes: _,
1157
+ footerComponent: S,
1158
+ showFooterOnLogin: d,
1159
+ footerExcludedRoutes: x,
1160
+ privateProvider: h,
1161
+ customProvider: v
1162
+ } = t, y = m || /* @__PURE__ */ s.jsx(
1163
+ _t,
1172
1164
  {
1173
- isMain: d,
1165
+ isMain: p,
1174
1166
  headerComponent: C,
1175
- showHeaderOnLogin: y,
1176
- headerExcludedRoutes: O,
1177
- footerComponent: P,
1178
- showFooterOnLogin: p,
1179
- footerExcludedRoutes: v
1167
+ showHeaderOnLogin: E,
1168
+ headerExcludedRoutes: _,
1169
+ footerComponent: S,
1170
+ showFooterOnLogin: d,
1171
+ footerExcludedRoutes: x
1180
1172
  }
1181
- ), g = x ? F.cloneElement(x, {}, L) : /* @__PURE__ */ a.jsx(_t, { children: L }), k = () => {
1182
- const w = document.querySelector("link[rel='icon']");
1183
- u && (w.href = u);
1173
+ ), w = h ? D.cloneElement(h, {}, v) : /* @__PURE__ */ s.jsx(Nt, { children: v }), P = () => {
1174
+ const L = document.querySelector("link[rel='icon']");
1175
+ u && (L.href = u);
1184
1176
  };
1185
- return z(() => {
1186
- k();
1187
- }, []), /* @__PURE__ */ a.jsx(ct, { children: /* @__PURE__ */ a.jsxs(Q, { element: m === "none" ? null : b, children: [
1188
- /* @__PURE__ */ a.jsxs(Q, { path: "/", children: [
1189
- /* @__PURE__ */ a.jsx(Q, { index: !0, element: /* @__PURE__ */ a.jsx(Tt, { Logo: c }) }),
1190
- o.map((w, T) => /* @__PURE__ */ a.jsx(Q, { path: w.path, element: w.element }, `public-${T}`))
1177
+ return I(() => {
1178
+ P();
1179
+ }, []), /* @__PURE__ */ s.jsx(ut, { children: /* @__PURE__ */ s.jsxs(Q, { element: m === "none" ? null : y, children: [
1180
+ /* @__PURE__ */ s.jsxs(Q, { path: "/", children: [
1181
+ /* @__PURE__ */ s.jsx(Q, { index: !0, element: /* @__PURE__ */ s.jsx(Tt, { Logo: i }) }),
1182
+ o.map((L, N) => /* @__PURE__ */ s.jsx(Q, { path: L.path, element: L.element }, `public-${N}`))
1191
1183
  ] }),
1192
- /* @__PURE__ */ a.jsxs(Q, { element: g, children: [
1193
- /* @__PURE__ */ a.jsx(Q, { path: `${s ?? "/dashboard/"}:id`, element: f }),
1194
- n.map((w, T) => /* @__PURE__ */ a.jsx(Q, { path: w.path, element: w.element }, `private-${T}`))
1184
+ /* @__PURE__ */ s.jsxs(Q, { element: w, children: [
1185
+ /* @__PURE__ */ s.jsx(Q, { path: `${a ?? "/dashboard/"}:id`, element: f }),
1186
+ n.map((L, N) => /* @__PURE__ */ s.jsx(Q, { path: L.path, element: L.element }, `private-${N}`))
1195
1187
  ] })
1196
1188
  ] }) });
1197
- }, Ut = ({ spinner: t = !0, spinnerStyle: o, text: n, textStyle: s, children: c, containerStyle: u, overrideStyle: f = {} }) => /* @__PURE__ */ a.jsxs("div", { className: f.container || `w-full h-full relative flex items-center justify-center ${u}`, children: [
1198
- t && /* @__PURE__ */ a.jsx(rt, { className: f.spinner || `text-[20rem] animate-spin text-black ${o}` }),
1199
- c || /* @__PURE__ */ a.jsx("p", { className: f.text || `text-black text-2xl select-none absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 ${s}`, children: n || "Loading..." })
1189
+ }, qt = ({ children: t }) => {
1190
+ var i;
1191
+ const o = qe(), { activeAlert: n } = ie(), a = JSON.parse(localStorage.getItem("user"));
1192
+ return I(() => {
1193
+ (!a || !a.admin) && n("warning", "Non puoi accedere a questa pagina");
1194
+ }, [a]), !a || !a.admin ? /* @__PURE__ */ s.jsx(He, { to: ((i = o.state) == null ? void 0 : i.from) || "/", replace: !0 }) : t;
1195
+ }, Ht = ({ spinner: t = !0, spinnerStyle: o, text: n, textStyle: a, children: i, containerStyle: u, overrideStyle: f = {} }) => /* @__PURE__ */ s.jsxs("div", { className: f.container || `w-full h-full relative flex items-center justify-center ${u}`, children: [
1196
+ t && /* @__PURE__ */ s.jsx(nt, { className: f.spinner || `text-[20rem] animate-spin text-black ${o}` }),
1197
+ i || /* @__PURE__ */ s.jsx("p", { className: f.text || `text-black text-2xl select-none absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 ${a}`, children: n || "Loading..." })
1200
1198
  ] });
1201
1199
  export {
1202
1200
  We as Alert,
1203
- Ft as AlertProvider,
1204
- _t as AuthPage,
1205
- Dt as AuthProvider,
1206
- Vt as BrowserRouter,
1207
- $t as ConfigProvider,
1208
- Nt as Dashboard,
1209
- kt as DefaultLayout,
1210
- pt as ErrorPage,
1201
+ Dt as AlertProvider,
1202
+ qt as AuthAdmin,
1203
+ Nt as AuthPage,
1204
+ Wt as AuthProvider,
1205
+ Xt as BrowserRouter,
1206
+ Ft as ConfigProvider,
1207
+ At as Dashboard,
1208
+ _t as DefaultLayout,
1209
+ gt as ErrorPage,
1211
1210
  Ye as Input,
1212
1211
  Ze as InputLabel,
1213
- Xt as Link,
1214
- Ot as Loading,
1215
- Ut as LoadingComponent,
1216
- Bt as LoadingProvider,
1212
+ Kt as Link,
1213
+ Pt as Loading,
1214
+ Ht as LoadingComponent,
1215
+ $t as LoadingProvider,
1217
1216
  Tt as Login,
1218
1217
  Rt as LoginForm,
1219
- Yt as LoginFormProvider,
1220
- Jt as NavLink,
1221
- Kt as Outlet,
1222
- Zt as PackageRoutes,
1223
- Qt as Route,
1224
- Wt as RouteProvider,
1225
- e0 as Routes,
1226
- a0 as axios,
1227
- he as fetchAxiosConfig,
1218
+ Zt as LoginFormProvider,
1219
+ Qt as NavLink,
1220
+ e0 as Outlet,
1221
+ Ut as PackageRoutes,
1222
+ t0 as Route,
1223
+ Yt as RouteProvider,
1224
+ r0 as Routes,
1225
+ i0 as axios,
1226
+ Ce as fetchAxiosConfig,
1228
1227
  ie as useAlert,
1229
1228
  je as useAuth,
1230
1229
  ee as useConfig,
1231
- xe as useLoading,
1232
- t0 as useLocation,
1233
- tt as useLoginForm,
1234
- r0 as useMatch,
1235
- o0 as useNavigate,
1236
- St as useRoutesInjection
1230
+ he as useLoading,
1231
+ o0 as useLocation,
1232
+ ot as useLoginForm,
1233
+ n0 as useMatch,
1234
+ a0 as useNavigate,
1235
+ Ot as useRoutesInjection
1237
1236
  };