@tracktor/shared-module 1.0.0-beta.5 → 1.0.0-beta.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,4 +1,4 @@
1
1
  # [Versions](https://github.com/Tracktor/shared-module/releases)
2
2
 
3
- ## v1.0.0-beta.5
4
- - **[docs]** : DaysJSConfig - Make props `language` optional
3
+ ## v1.0.0-beta.6
4
+ - **[docs]** : DaysJSConfig fix export
@@ -0,0 +1,17 @@
1
+ var r = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {}, a = { exports: {} };
2
+ (function(t, d) {
3
+ (function(n, e) {
4
+ t.exports = e();
5
+ })(r, function() {
6
+ return { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(n) {
7
+ var e = ["th", "st", "nd", "rd"], o = n % 100;
8
+ return "[" + n + (e[(o - 20) % 10] || e[o] || e[0]) + "]";
9
+ } };
10
+ });
11
+ })(a);
12
+ const u = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
13
+ __proto__: null
14
+ }, Symbol.toStringTag, { value: "Module" }));
15
+ export {
16
+ u as e
17
+ };
package/dist/main.d.ts CHANGED
@@ -12,6 +12,8 @@ export { default as MaskTextField } from './components/Inputs/MaskTextField';
12
12
  export * from './components/Inputs/MaskTextField';
13
13
  export { default as MapBoxConfig } from './components/Utils/MapBoxConfig';
14
14
  export * from './components/Utils/MapBoxConfig';
15
+ export { default as DaysJSConfig } from './components/Utils/DaysJSConfig';
16
+ export * from './components/Utils/DaysJSConfig';
15
17
  export { default as InjectDependenciesProvider } from './context/InjectDependenciesProvider';
16
18
  export * from './context/InjectDependenciesProvider';
17
19
  export { default as QueryClientConfigProvider } from './context/QueryClientConfigProvider';
package/dist/main.js CHANGED
@@ -1,14 +1,14 @@
1
- import We, { useState as br, useRef as Rr, useLayoutEffect as _r, Suspense as Cr, useEffect as Le, createContext as Tr, useMemo as ie, useContext as Ye, useCallback as ae } from "react";
1
+ import Le, { useState as Rr, useRef as _r, useLayoutEffect as Cr, Suspense as Tr, useEffect as ie, createContext as Sr, useMemo as ue, useContext as Ye, useCallback as ae } from "react";
2
2
  import k from "axios";
3
- import { useLocation as ue, Navigate as $e, Outlet as Me, createRoutesFromChildren as Sr, matchRoutes as wr, useNavigationType as Or } from "react-router-dom";
4
- import { useGoogleTagManager as xr } from "@tracktor/react-google-tag-manager";
5
- import W, { t as jr } from "i18next";
6
- import Pr from "i18next-browser-languagedetector";
7
- import { initReactI18next as Ar } from "react-i18next";
3
+ import { useLocation as se, Navigate as De, Outlet as Me, createRoutesFromChildren as wr, matchRoutes as Or, useNavigationType as xr } from "react-router-dom";
4
+ import { useGoogleTagManager as jr } from "@tracktor/react-google-tag-manager";
5
+ import W, { t as Pr } from "i18next";
6
+ import Ar from "i18next-browser-languagedetector";
7
+ import { initReactI18next as kr } from "react-i18next";
8
8
  import * as ne from "@sentry/react";
9
- import De from "mapbox-gl";
10
- import { QueryClient as kr, QueryClientProvider as $r } from "@tanstack/react-query";
11
- import Dr from "dayjs";
9
+ import Fe from "mapbox-gl";
10
+ import Ve from "dayjs";
11
+ import { QueryClient as $r, QueryClientProvider as Dr } from "@tanstack/react-query";
12
12
  var oe = { exports: {} }, M = {};
13
13
  /**
14
14
  * @license React
@@ -19,17 +19,17 @@ var oe = { exports: {} }, M = {};
19
19
  * This source code is licensed under the MIT license found in the
20
20
  * LICENSE file in the root directory of this source tree.
21
21
  */
22
- var Fe;
22
+ var Ie;
23
23
  function Fr() {
24
- return Fe || (Fe = 1, process.env.NODE_ENV !== "production" && function() {
25
- var o = We, n = Symbol.for("react.element"), i = Symbol.for("react.portal"), s = Symbol.for("react.fragment"), m = Symbol.for("react.strict_mode"), b = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), f = Symbol.for("react.context"), c = Symbol.for("react.forward_ref"), g = Symbol.for("react.suspense"), h = Symbol.for("react.suspense_list"), C = Symbol.for("react.memo"), S = Symbol.for("react.lazy"), O = Symbol.for("react.offscreen"), A = Symbol.iterator, $ = "@@iterator";
24
+ return Ie || (Ie = 1, process.env.NODE_ENV !== "production" && function() {
25
+ var n = Le, a = Symbol.for("react.element"), i = Symbol.for("react.portal"), s = Symbol.for("react.fragment"), m = Symbol.for("react.strict_mode"), b = Symbol.for("react.profiler"), o = Symbol.for("react.provider"), f = Symbol.for("react.context"), c = Symbol.for("react.forward_ref"), g = Symbol.for("react.suspense"), h = Symbol.for("react.suspense_list"), C = Symbol.for("react.memo"), S = Symbol.for("react.lazy"), O = Symbol.for("react.offscreen"), A = Symbol.iterator, $ = "@@iterator";
26
26
  function R(e) {
27
27
  if (e === null || typeof e != "object")
28
28
  return null;
29
29
  var r = A && e[A] || e[$];
30
30
  return typeof r == "function" ? r : null;
31
31
  }
32
- var D = o.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
32
+ var D = n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
33
33
  function _(e) {
34
34
  {
35
35
  for (var r = arguments.length, t = new Array(r > 1 ? r - 1 : 0), u = 1; u < r; u++)
@@ -47,23 +47,23 @@ function Fr() {
47
47
  p.unshift("Warning: " + r), Function.prototype.apply.call(console[e], console, p);
48
48
  }
49
49
  }
50
- var Ve = !1, Ue = !1, qe = !1, ze = !1, Be = !1, ce;
51
- ce = Symbol.for("react.module.reference");
52
- function Ge(e) {
53
- return !!(typeof e == "string" || typeof e == "function" || e === s || e === b || Be || e === m || e === g || e === h || ze || e === O || Ve || Ue || qe || typeof e == "object" && e !== null && (e.$$typeof === S || e.$$typeof === C || e.$$typeof === a || e.$$typeof === f || e.$$typeof === c || // This needs to include all possible module reference object
50
+ var Ue = !1, qe = !1, ze = !1, Be = !1, Ge = !1, le;
51
+ le = Symbol.for("react.module.reference");
52
+ function Je(e) {
53
+ return !!(typeof e == "string" || typeof e == "function" || e === s || e === b || Ge || e === m || e === g || e === h || Be || e === O || Ue || qe || ze || typeof e == "object" && e !== null && (e.$$typeof === S || e.$$typeof === C || e.$$typeof === o || e.$$typeof === f || e.$$typeof === c || // This needs to include all possible module reference object
54
54
  // types supported by any Flight configuration anywhere since
55
55
  // we don't know which Flight build this will end up being used
56
56
  // with.
57
- e.$$typeof === ce || e.getModuleId !== void 0));
57
+ e.$$typeof === le || e.getModuleId !== void 0));
58
58
  }
59
- function Je(e, r, t) {
59
+ function Xe(e, r, t) {
60
60
  var u = e.displayName;
61
61
  if (u)
62
62
  return u;
63
63
  var v = r.displayName || r.name || "";
64
64
  return v !== "" ? t + "(" + v + ")" : t;
65
65
  }
66
- function le(e) {
66
+ function fe(e) {
67
67
  return e.displayName || "Context";
68
68
  }
69
69
  function x(e) {
@@ -91,12 +91,12 @@ function Fr() {
91
91
  switch (e.$$typeof) {
92
92
  case f:
93
93
  var r = e;
94
- return le(r) + ".Consumer";
95
- case a:
94
+ return fe(r) + ".Consumer";
95
+ case o:
96
96
  var t = e;
97
- return le(t._context) + ".Provider";
97
+ return fe(t._context) + ".Provider";
98
98
  case c:
99
- return Je(e, e.render, "ForwardRef");
99
+ return Xe(e, e.render, "ForwardRef");
100
100
  case C:
101
101
  var u = e.displayName || null;
102
102
  return u !== null ? u : x(e.type) || "Memo";
@@ -111,18 +111,18 @@ function Fr() {
111
111
  }
112
112
  return null;
113
113
  }
114
- var F = Object.assign, L = 0, fe, de, ve, pe, me, ge, he;
115
- function ye() {
114
+ var F = Object.assign, L = 0, de, ve, pe, me, ge, he, ye;
115
+ function Ee() {
116
116
  }
117
- ye.__reactDisabledLog = !0;
118
- function Xe() {
117
+ Ee.__reactDisabledLog = !0;
118
+ function He() {
119
119
  {
120
120
  if (L === 0) {
121
- fe = console.log, de = console.info, ve = console.warn, pe = console.error, me = console.group, ge = console.groupCollapsed, he = console.groupEnd;
121
+ de = console.log, ve = console.info, pe = console.warn, me = console.error, ge = console.group, he = console.groupCollapsed, ye = console.groupEnd;
122
122
  var e = {
123
123
  configurable: !0,
124
124
  enumerable: !0,
125
- value: ye,
125
+ value: Ee,
126
126
  writable: !0
127
127
  };
128
128
  Object.defineProperties(console, {
@@ -138,7 +138,7 @@ function Fr() {
138
138
  L++;
139
139
  }
140
140
  }
141
- function He() {
141
+ function Ke() {
142
142
  {
143
143
  if (L--, L === 0) {
144
144
  var e = {
@@ -148,25 +148,25 @@ function Fr() {
148
148
  };
149
149
  Object.defineProperties(console, {
150
150
  log: F({}, e, {
151
- value: fe
151
+ value: de
152
152
  }),
153
153
  info: F({}, e, {
154
- value: de
154
+ value: ve
155
155
  }),
156
156
  warn: F({}, e, {
157
- value: ve
157
+ value: pe
158
158
  }),
159
159
  error: F({}, e, {
160
- value: pe
160
+ value: me
161
161
  }),
162
162
  group: F({}, e, {
163
- value: me
163
+ value: ge
164
164
  }),
165
165
  groupCollapsed: F({}, e, {
166
- value: ge
166
+ value: he
167
167
  }),
168
168
  groupEnd: F({}, e, {
169
- value: he
169
+ value: ye
170
170
  })
171
171
  });
172
172
  }
@@ -189,10 +189,10 @@ function Fr() {
189
189
  }
190
190
  var K = !1, z;
191
191
  {
192
- var Ke = typeof WeakMap == "function" ? WeakMap : Map;
193
- z = new Ke();
192
+ var Ze = typeof WeakMap == "function" ? WeakMap : Map;
193
+ z = new Ze();
194
194
  }
195
- function Ee(e, r) {
195
+ function be(e, r) {
196
196
  if (!e || K)
197
197
  return "";
198
198
  {
@@ -205,7 +205,7 @@ function Fr() {
205
205
  var v = Error.prepareStackTrace;
206
206
  Error.prepareStackTrace = void 0;
207
207
  var p;
208
- p = X.current, X.current = null, Xe();
208
+ p = X.current, X.current = null, He();
209
209
  try {
210
210
  if (r) {
211
211
  var d = function() {
@@ -258,15 +258,15 @@ function Fr() {
258
258
  }
259
259
  }
260
260
  } finally {
261
- K = !1, X.current = p, He(), Error.prepareStackTrace = v;
261
+ K = !1, X.current = p, Ke(), Error.prepareStackTrace = v;
262
262
  }
263
- var N = e ? e.displayName || e.name : "", ke = N ? q(N) : "";
264
- return typeof e == "function" && z.set(e, ke), ke;
263
+ var N = e ? e.displayName || e.name : "", $e = N ? q(N) : "";
264
+ return typeof e == "function" && z.set(e, $e), $e;
265
265
  }
266
- function Ze(e, r, t) {
267
- return Ee(e, !1);
266
+ function Qe(e, r, t) {
267
+ return be(e, !1);
268
268
  }
269
- function Qe(e) {
269
+ function er(e) {
270
270
  var r = e.prototype;
271
271
  return !!(r && r.isReactComponent);
272
272
  }
@@ -274,7 +274,7 @@ function Fr() {
274
274
  if (e == null)
275
275
  return "";
276
276
  if (typeof e == "function")
277
- return Ee(e, Qe(e));
277
+ return be(e, er(e));
278
278
  if (typeof e == "string")
279
279
  return q(e);
280
280
  switch (e) {
@@ -286,7 +286,7 @@ function Fr() {
286
286
  if (typeof e == "object")
287
287
  switch (e.$$typeof) {
288
288
  case c:
289
- return Ze(e.render);
289
+ return Qe(e.render);
290
290
  case C:
291
291
  return B(e.type, r, t);
292
292
  case S: {
@@ -299,15 +299,15 @@ function Fr() {
299
299
  }
300
300
  return "";
301
301
  }
302
- var G = Object.prototype.hasOwnProperty, be = {}, Re = D.ReactDebugCurrentFrame;
302
+ var G = Object.prototype.hasOwnProperty, Re = {}, _e = D.ReactDebugCurrentFrame;
303
303
  function J(e) {
304
304
  if (e) {
305
305
  var r = e._owner, t = B(e.type, e._source, r ? r.type : null);
306
- Re.setExtraStackFrame(t);
306
+ _e.setExtraStackFrame(t);
307
307
  } else
308
- Re.setExtraStackFrame(null);
308
+ _e.setExtraStackFrame(null);
309
309
  }
310
- function er(e, r, t, u, v) {
310
+ function rr(e, r, t, u, v) {
311
311
  {
312
312
  var p = Function.call.bind(G);
313
313
  for (var d in e)
@@ -322,42 +322,42 @@ function Fr() {
322
322
  } catch (y) {
323
323
  l = y;
324
324
  }
325
- l && !(l instanceof Error) && (J(v), _("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", u || "React class", t, d, typeof l), J(null)), l instanceof Error && !(l.message in be) && (be[l.message] = !0, J(v), _("Failed %s type: %s", t, l.message), J(null));
325
+ l && !(l instanceof Error) && (J(v), _("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", u || "React class", t, d, typeof l), J(null)), l instanceof Error && !(l.message in Re) && (Re[l.message] = !0, J(v), _("Failed %s type: %s", t, l.message), J(null));
326
326
  }
327
327
  }
328
328
  }
329
- var rr = Array.isArray;
329
+ var tr = Array.isArray;
330
330
  function Z(e) {
331
- return rr(e);
331
+ return tr(e);
332
332
  }
333
- function tr(e) {
333
+ function nr(e) {
334
334
  {
335
335
  var r = typeof Symbol == "function" && Symbol.toStringTag, t = r && e[Symbol.toStringTag] || e.constructor.name || "Object";
336
336
  return t;
337
337
  }
338
338
  }
339
- function nr(e) {
339
+ function ar(e) {
340
340
  try {
341
- return _e(e), !1;
341
+ return Ce(e), !1;
342
342
  } catch {
343
343
  return !0;
344
344
  }
345
345
  }
346
- function _e(e) {
346
+ function Ce(e) {
347
347
  return "" + e;
348
348
  }
349
- function Ce(e) {
350
- if (nr(e))
351
- return _("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", tr(e)), _e(e);
349
+ function Te(e) {
350
+ if (ar(e))
351
+ return _("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", nr(e)), Ce(e);
352
352
  }
353
- var Y = D.ReactCurrentOwner, ar = {
353
+ var Y = D.ReactCurrentOwner, or = {
354
354
  key: !0,
355
355
  ref: !0,
356
356
  __self: !0,
357
357
  __source: !0
358
- }, Te, Se, Q;
358
+ }, Se, we, Q;
359
359
  Q = {};
360
- function or(e) {
360
+ function ir(e) {
361
361
  if (G.call(e, "ref")) {
362
362
  var r = Object.getOwnPropertyDescriptor(e, "ref").get;
363
363
  if (r && r.isReactWarning)
@@ -365,7 +365,7 @@ function Fr() {
365
365
  }
366
366
  return e.ref !== void 0;
367
367
  }
368
- function ir(e) {
368
+ function ur(e) {
369
369
  if (G.call(e, "key")) {
370
370
  var r = Object.getOwnPropertyDescriptor(e, "key").get;
371
371
  if (r && r.isReactWarning)
@@ -373,16 +373,16 @@ function Fr() {
373
373
  }
374
374
  return e.key !== void 0;
375
375
  }
376
- function ur(e, r) {
376
+ function sr(e, r) {
377
377
  if (typeof e.ref == "string" && Y.current && r && Y.current.stateNode !== r) {
378
378
  var t = x(Y.current.type);
379
379
  Q[t] || (_('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref', x(Y.current.type), e.ref), Q[t] = !0);
380
380
  }
381
381
  }
382
- function sr(e, r) {
382
+ function cr(e, r) {
383
383
  {
384
384
  var t = function() {
385
- Te || (Te = !0, _("%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://reactjs.org/link/special-props)", r));
385
+ Se || (Se = !0, _("%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://reactjs.org/link/special-props)", r));
386
386
  };
387
387
  t.isReactWarning = !0, Object.defineProperty(e, "key", {
388
388
  get: t,
@@ -390,10 +390,10 @@ function Fr() {
390
390
  });
391
391
  }
392
392
  }
393
- function cr(e, r) {
393
+ function lr(e, r) {
394
394
  {
395
395
  var t = function() {
396
- Se || (Se = !0, _("%s: `ref` 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://reactjs.org/link/special-props)", r));
396
+ we || (we = !0, _("%s: `ref` 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://reactjs.org/link/special-props)", r));
397
397
  };
398
398
  t.isReactWarning = !0, Object.defineProperty(e, "ref", {
399
399
  get: t,
@@ -401,10 +401,10 @@ function Fr() {
401
401
  });
402
402
  }
403
403
  }
404
- var lr = function(e, r, t, u, v, p, d) {
404
+ var fr = function(e, r, t, u, v, p, d) {
405
405
  var l = {
406
406
  // This tag allows us to uniquely identify this as a React Element
407
- $$typeof: n,
407
+ $$typeof: a,
408
408
  // Built-in properties that belong on the element
409
409
  type: e,
410
410
  key: r,
@@ -430,12 +430,12 @@ function Fr() {
430
430
  value: v
431
431
  }), Object.freeze && (Object.freeze(l.props), Object.freeze(l)), l;
432
432
  };
433
- function fr(e, r, t, u, v) {
433
+ function dr(e, r, t, u, v) {
434
434
  {
435
435
  var p, d = {}, l = null, T = null;
436
- t !== void 0 && (Ce(t), l = "" + t), ir(r) && (Ce(r.key), l = "" + r.key), or(r) && (T = r.ref, ur(r, v));
436
+ t !== void 0 && (Te(t), l = "" + t), ur(r) && (Te(r.key), l = "" + r.key), ir(r) && (T = r.ref, sr(r, v));
437
437
  for (p in r)
438
- G.call(r, p) && !ar.hasOwnProperty(p) && (d[p] = r[p]);
438
+ G.call(r, p) && !or.hasOwnProperty(p) && (d[p] = r[p]);
439
439
  if (e && e.defaultProps) {
440
440
  var y = e.defaultProps;
441
441
  for (p in y)
@@ -443,25 +443,25 @@ function Fr() {
443
443
  }
444
444
  if (l || T) {
445
445
  var E = typeof e == "function" ? e.displayName || e.name || "Unknown" : e;
446
- l && sr(d, E), T && cr(d, E);
446
+ l && cr(d, E), T && lr(d, E);
447
447
  }
448
- return lr(e, l, T, v, u, Y.current, d);
448
+ return fr(e, l, T, v, u, Y.current, d);
449
449
  }
450
450
  }
451
- var ee = D.ReactCurrentOwner, we = D.ReactDebugCurrentFrame;
451
+ var ee = D.ReactCurrentOwner, Oe = D.ReactDebugCurrentFrame;
452
452
  function I(e) {
453
453
  if (e) {
454
454
  var r = e._owner, t = B(e.type, e._source, r ? r.type : null);
455
- we.setExtraStackFrame(t);
455
+ Oe.setExtraStackFrame(t);
456
456
  } else
457
- we.setExtraStackFrame(null);
457
+ Oe.setExtraStackFrame(null);
458
458
  }
459
459
  var re;
460
460
  re = !1;
461
461
  function te(e) {
462
- return typeof e == "object" && e !== null && e.$$typeof === n;
462
+ return typeof e == "object" && e !== null && e.$$typeof === a;
463
463
  }
464
- function Oe() {
464
+ function xe() {
465
465
  {
466
466
  if (ee.current) {
467
467
  var e = x(ee.current.type);
@@ -473,7 +473,7 @@ Check the render method of \`` + e + "`.";
473
473
  return "";
474
474
  }
475
475
  }
476
- function dr(e) {
476
+ function vr(e) {
477
477
  {
478
478
  if (e !== void 0) {
479
479
  var r = e.fileName.replace(/^.*[\\\/]/, ""), t = e.lineNumber;
@@ -484,10 +484,10 @@ Check your code at ` + r + ":" + t + ".";
484
484
  return "";
485
485
  }
486
486
  }
487
- var xe = {};
488
- function vr(e) {
487
+ var je = {};
488
+ function pr(e) {
489
489
  {
490
- var r = Oe();
490
+ var r = xe();
491
491
  if (!r) {
492
492
  var t = typeof e == "string" ? e : e.displayName || e.name;
493
493
  t && (r = `
@@ -497,27 +497,27 @@ Check the top-level render call using <` + t + ">.");
497
497
  return r;
498
498
  }
499
499
  }
500
- function je(e, r) {
500
+ function Pe(e, r) {
501
501
  {
502
502
  if (!e._store || e._store.validated || e.key != null)
503
503
  return;
504
504
  e._store.validated = !0;
505
- var t = vr(r);
506
- if (xe[t])
505
+ var t = pr(r);
506
+ if (je[t])
507
507
  return;
508
- xe[t] = !0;
508
+ je[t] = !0;
509
509
  var u = "";
510
510
  e && e._owner && e._owner !== ee.current && (u = " It was passed a child from " + x(e._owner.type) + "."), I(e), _('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', t, u), I(null);
511
511
  }
512
512
  }
513
- function Pe(e, r) {
513
+ function Ae(e, r) {
514
514
  {
515
515
  if (typeof e != "object")
516
516
  return;
517
517
  if (Z(e))
518
518
  for (var t = 0; t < e.length; t++) {
519
519
  var u = e[t];
520
- te(u) && je(u, r);
520
+ te(u) && Pe(u, r);
521
521
  }
522
522
  else if (te(e))
523
523
  e._store && (e._store.validated = !0);
@@ -525,11 +525,11 @@ Check the top-level render call using <` + t + ">.");
525
525
  var v = R(e);
526
526
  if (typeof v == "function" && v !== e.entries)
527
527
  for (var p = v.call(e), d; !(d = p.next()).done; )
528
- te(d.value) && je(d.value, r);
528
+ te(d.value) && Pe(d.value, r);
529
529
  }
530
530
  }
531
531
  }
532
- function pr(e) {
532
+ function mr(e) {
533
533
  {
534
534
  var r = e.type;
535
535
  if (r == null || typeof r == "string")
@@ -545,7 +545,7 @@ Check the top-level render call using <` + t + ">.");
545
545
  return;
546
546
  if (t) {
547
547
  var u = x(r);
548
- er(t, e.props, "prop", u, e);
548
+ rr(t, e.props, "prop", u, e);
549
549
  } else if (r.PropTypes !== void 0 && !re) {
550
550
  re = !0;
551
551
  var v = x(r);
@@ -554,7 +554,7 @@ Check the top-level render call using <` + t + ">.");
554
554
  typeof r.getDefaultProps == "function" && !r.getDefaultProps.isReactClassApproved && _("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
555
555
  }
556
556
  }
557
- function mr(e) {
557
+ function gr(e) {
558
558
  {
559
559
  for (var r = Object.keys(e.props), t = 0; t < r.length; t++) {
560
560
  var u = r[t];
@@ -566,18 +566,18 @@ Check the top-level render call using <` + t + ">.");
566
566
  e.ref !== null && (I(e), _("Invalid attribute `ref` supplied to `React.Fragment`."), I(null));
567
567
  }
568
568
  }
569
- function Ae(e, r, t, u, v, p) {
569
+ function ke(e, r, t, u, v, p) {
570
570
  {
571
- var d = Ge(e);
571
+ var d = Je(e);
572
572
  if (!d) {
573
573
  var l = "";
574
574
  (e === void 0 || typeof e == "object" && e !== null && Object.keys(e).length === 0) && (l += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
575
- var T = dr(v);
576
- T ? l += T : l += Oe();
575
+ var T = vr(v);
576
+ T ? l += T : l += xe();
577
577
  var y;
578
- e === null ? y = "null" : Z(e) ? y = "array" : e !== void 0 && e.$$typeof === n ? (y = "<" + (x(e.type) || "Unknown") + " />", l = " Did you accidentally export a JSX literal instead of a component?") : y = typeof e, _("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", y, l);
578
+ e === null ? y = "null" : Z(e) ? y = "array" : e !== void 0 && e.$$typeof === a ? (y = "<" + (x(e.type) || "Unknown") + " />", l = " Did you accidentally export a JSX literal instead of a component?") : y = typeof e, _("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", y, l);
579
579
  }
580
- var E = fr(e, r, t, v, p);
580
+ var E = dr(e, r, t, v, p);
581
581
  if (E == null)
582
582
  return E;
583
583
  if (d) {
@@ -586,24 +586,24 @@ Check the top-level render call using <` + t + ">.");
586
586
  if (u)
587
587
  if (Z(w)) {
588
588
  for (var N = 0; N < w.length; N++)
589
- Pe(w[N], e);
589
+ Ae(w[N], e);
590
590
  Object.freeze && Object.freeze(w);
591
591
  } else
592
592
  _("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
593
593
  else
594
- Pe(w, e);
594
+ Ae(w, e);
595
595
  }
596
- return e === s ? mr(E) : pr(E), E;
596
+ return e === s ? gr(E) : mr(E), E;
597
597
  }
598
598
  }
599
- function gr(e, r, t) {
600
- return Ae(e, r, t, !0);
601
- }
602
599
  function hr(e, r, t) {
603
- return Ae(e, r, t, !1);
600
+ return ke(e, r, t, !0);
601
+ }
602
+ function yr(e, r, t) {
603
+ return ke(e, r, t, !1);
604
604
  }
605
- var yr = hr, Er = gr;
606
- M.Fragment = s, M.jsx = yr, M.jsxs = Er;
605
+ var Er = yr, br = hr;
606
+ M.Fragment = s, M.jsx = Er, M.jsxs = br;
607
607
  }()), M;
608
608
  }
609
609
  var V = {};
@@ -616,13 +616,13 @@ var V = {};
616
616
  * This source code is licensed under the MIT license found in the
617
617
  * LICENSE file in the root directory of this source tree.
618
618
  */
619
- var Ie;
619
+ var Ne;
620
620
  function Ir() {
621
- if (Ie)
621
+ if (Ne)
622
622
  return V;
623
- Ie = 1;
624
- var o = We, n = Symbol.for("react.element"), i = Symbol.for("react.fragment"), s = Object.prototype.hasOwnProperty, m = o.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, b = { key: !0, ref: !0, __self: !0, __source: !0 };
625
- function a(f, c, g) {
623
+ Ne = 1;
624
+ var n = Le, a = Symbol.for("react.element"), i = Symbol.for("react.fragment"), s = Object.prototype.hasOwnProperty, m = n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, b = { key: !0, ref: !0, __self: !0, __source: !0 };
625
+ function o(f, c, g) {
626
626
  var h, C = {}, S = null, O = null;
627
627
  g !== void 0 && (S = "" + g), c.key !== void 0 && (S = "" + c.key), c.ref !== void 0 && (O = c.ref);
628
628
  for (h in c)
@@ -630,63 +630,63 @@ function Ir() {
630
630
  if (f && f.defaultProps)
631
631
  for (h in c = f.defaultProps, c)
632
632
  C[h] === void 0 && (C[h] = c[h]);
633
- return { $$typeof: n, type: f, key: S, ref: O, props: C, _owner: m.current };
633
+ return { $$typeof: a, type: f, key: S, ref: O, props: C, _owner: m.current };
634
634
  }
635
- return V.Fragment = i, V.jsx = a, V.jsxs = a, V;
635
+ return V.Fragment = i, V.jsx = o, V.jsxs = o, V;
636
636
  }
637
637
  process.env.NODE_ENV === "production" ? oe.exports = Ir() : oe.exports = Fr();
638
638
  var P = oe.exports;
639
639
  const et = ({
640
- Fallback: o,
641
- loginPath: n = "/login",
640
+ Fallback: n,
641
+ loginPath: a = "/login",
642
642
  localStorageKey: i = "user",
643
643
  redirect401Path: s = "/login",
644
644
  isLogged: m
645
645
  }) => {
646
646
  var C, S, O, A;
647
- const [b, a] = br(null), f = ue(), c = Rr(!1), g = typeof m == "function" ? m() : !!m, h = typeof g == "boolean" ? g : g == null ? void 0 : g.isLogged;
648
- return _r(() => {
647
+ const [b, o] = Rr(null), f = se(), c = _r(!1), g = typeof m == "function" ? m() : !!m, h = typeof g == "boolean" ? g : g == null ? void 0 : g.isLogged;
648
+ return Cr(() => {
649
649
  var $;
650
650
  c.current || (c.current = !0, ($ = k) == null || $.interceptors.response.use(
651
651
  (R) => R,
652
652
  async (R) => {
653
653
  var U;
654
- return typeof R == "object" && R && "response" in R && R.response && typeof R.response == "object" && "status" in R.response && R.response && typeof R.response == "object" && "status" in R.response && ((U = R == null ? void 0 : R.response) == null ? void 0 : U.status) === 401 && (k.defaults.headers.common.Authorization = null, localStorage.removeItem(i), a(s)), Promise.reject(R);
654
+ return typeof R == "object" && R && "response" in R && R.response && typeof R.response == "object" && "status" in R.response && R.response && typeof R.response == "object" && "status" in R.response && ((U = R == null ? void 0 : R.response) == null ? void 0 : U.status) === 401 && (k.defaults.headers.common.Authorization = null, localStorage.removeItem(i), o(s)), Promise.reject(R);
655
655
  }
656
656
  ));
657
- }, [i, s]), h && !b ? /* @__PURE__ */ P.jsx(Cr, { fallback: o, children: (S = (C = f.state) == null ? void 0 : C.from) != null && S.state && ((A = (O = f.state) == null ? void 0 : O.from) == null ? void 0 : A.pathname) === n ? /* @__PURE__ */ P.jsx($e, { to: f.state.from.state.from.pathname + f.state.from.state.from.search, replace: !0 }) : /* @__PURE__ */ P.jsx(Me, {}) }) : /* @__PURE__ */ P.jsx($e, { to: n, state: { from: f }, replace: !0 });
657
+ }, [i, s]), h && !b ? /* @__PURE__ */ P.jsx(Tr, { fallback: n, children: (S = (C = f.state) == null ? void 0 : C.from) != null && S.state && ((A = (O = f.state) == null ? void 0 : O.from) == null ? void 0 : A.pathname) === a ? /* @__PURE__ */ P.jsx(De, { to: f.state.from.state.from.pathname + f.state.from.state.from.search, replace: !0 }) : /* @__PURE__ */ P.jsx(Me, {}) }) : /* @__PURE__ */ P.jsx(De, { to: a, state: { from: f }, replace: !0 });
658
658
  }, rt = () => {
659
- const { pathname: o } = ue(), { sendEvent: n } = xr();
660
- return Le(() => {
661
- n({ event: "pageView", pathname: o });
662
- }, [o, n]), /* @__PURE__ */ P.jsx(Me, {});
663
- }, se = Tr({
659
+ const { pathname: n } = se(), { sendEvent: a } = jr();
660
+ return ie(() => {
661
+ a({ event: "pageView", pathname: n });
662
+ }, [n, a]), /* @__PURE__ */ P.jsx(Me, {});
663
+ }, ce = Sr({
664
664
  apiURL: void 0,
665
665
  children: void 0
666
- }), tt = ({ children: o, apiURL: n }) => {
667
- const i = ie(
666
+ }), tt = ({ children: n, apiURL: a }) => {
667
+ const i = ue(
668
668
  () => ({
669
- apiURL: n
669
+ apiURL: a
670
670
  }),
671
- [n]
671
+ [a]
672
672
  );
673
- return /* @__PURE__ */ P.jsx(se.Provider, { value: i, children: o });
673
+ return /* @__PURE__ */ P.jsx(ce.Provider, { value: i, children: n });
674
674
  }, nt = ({
675
- tokenTypeKey: o = "tokenType",
676
- userLocalStorageKey: n = "user",
675
+ tokenTypeKey: n = "tokenType",
676
+ userLocalStorageKey: a = "user",
677
677
  tokenKey: i = "accessToken",
678
678
  postContentType: s = "application/json",
679
679
  ...m
680
680
  }) => {
681
- const { apiURL: b = m.baseURL } = Ye(se);
681
+ const { apiURL: b = m.baseURL } = Ye(ce);
682
682
  if (!k.defaults)
683
683
  return null;
684
- const a = localStorage.getItem(n), f = a ? JSON.parse(a) : null, c = f != null && f[o] ? f[o] : null, g = f != null && f[i] ? f[i] : null, h = a ? `${c} ${g}` : null;
684
+ const o = localStorage.getItem(a), f = o ? JSON.parse(o) : null, c = f != null && f[n] ? f[n] : null, g = f != null && f[i] ? f[i] : null, h = o ? `${c} ${g}` : null;
685
685
  return k.defaults.baseURL = b, k.defaults.headers.post["Content-Type"] = s, h && (k.defaults.headers.common.Authorization = h), null;
686
- }, at = ({ debug: o, resources: n }) => {
686
+ }, at = ({ debug: n, resources: a }) => {
687
687
  var i;
688
- return (i = W) != null && i.isInitialized || (W.use(Pr).use(Ar).init({
689
- debug: o,
688
+ return (i = W) != null && i.isInitialized || (W.use(Ar).use(kr).init({
689
+ debug: n,
690
690
  fallbackLng: "en",
691
691
  interpolation: {
692
692
  escapeValue: !1
@@ -696,7 +696,7 @@ const et = ({
696
696
  bindI18n: !1,
697
697
  useSuspense: !0
698
698
  },
699
- resources: n,
699
+ resources: a,
700
700
  returnNull: !1
701
701
  }).then(() => {
702
702
  document.documentElement.lang !== W.resolvedLanguage && W.resolvedLanguage && document.documentElement.setAttribute("lang", W.resolvedLanguage);
@@ -704,147 +704,153 @@ const et = ({
704
704
  document.documentElement.setAttribute("lang", s);
705
705
  })), null;
706
706
  }, ot = ({
707
- dsn: o,
708
- integrations: n,
707
+ dsn: n,
708
+ integrations: a,
709
709
  tracesSampleRate: i,
710
710
  replaysSessionSampleRate: s,
711
711
  replaysOnErrorSampleRate: m,
712
712
  tracePropagationTargets: b,
713
- ignoreErrors: a,
713
+ ignoreErrors: o,
714
714
  debug: f,
715
715
  environment: c
716
716
  }) => (ne.isInitialized() || (f || process.env.NODE_ENV === "prod" || process.env.NODE_ENV === "production") && ne.init({
717
717
  debug: f,
718
- dsn: o,
718
+ dsn: n,
719
719
  environment: c || "production",
720
- ignoreErrors: [...a || [], /dynamically imported module/],
720
+ ignoreErrors: [...o || [], /dynamically imported module/],
721
721
  integrations: [
722
722
  ne.reactRouterV6BrowserTracingIntegration({
723
- createRoutesFromChildren: Sr,
724
- matchRoutes: wr,
725
- useEffect: Le,
726
- useLocation: ue,
727
- useNavigationType: Or
723
+ createRoutesFromChildren: wr,
724
+ matchRoutes: Or,
725
+ useEffect: ie,
726
+ useLocation: se,
727
+ useNavigationType: xr
728
728
  }),
729
- ...n || []
729
+ ...a || []
730
730
  ],
731
731
  replaysOnErrorSampleRate: m || 1,
732
732
  replaysSessionSampleRate: s || 0.1,
733
733
  tracePropagationTargets: b,
734
734
  tracesSampleRate: i || 1
735
- }), null), it = ({ IMaskMixin: o, ...n }) => {
736
- const i = ie(
735
+ }), null), it = ({ IMaskMixin: n, ...a }) => {
736
+ const i = ue(
737
737
  // eslint-disable-next-line react/jsx-props-no-spreading
738
- () => o(({ TextField: s, ...m }) => /* @__PURE__ */ P.jsx(s, { ...m })),
739
- [o]
738
+ () => n(({ TextField: s, ...m }) => /* @__PURE__ */ P.jsx(s, { ...m })),
739
+ [n]
740
740
  );
741
- return /* @__PURE__ */ P.jsx(i, { ...n });
742
- }, ut = ({ accessToken: o }) => (De && o && (De.accessToken = o), null), st = ({ children: o, defaultQueriesOptions: n, defaultMutationsOptions: i }) => {
743
- const s = new kr({
741
+ return /* @__PURE__ */ P.jsx(i, { ...a });
742
+ }, ut = ({ accessToken: n }) => (Fe && n && (Fe.accessToken = n), null), st = ({ language: n = window.navigator.language }) => (ie(() => {
743
+ import(`dayjs/locale/${n}`).then(() => {
744
+ Ve.locale(n);
745
+ }).catch(() => {
746
+ import("./en-HVfn094c.js").then((a) => a.e);
747
+ });
748
+ }, [n]), null), ct = ({ children: n, defaultQueriesOptions: a, defaultMutationsOptions: i }) => {
749
+ const s = new $r({
744
750
  defaultOptions: {
745
751
  mutations: {
746
752
  ...i
747
753
  },
748
754
  queries: {
749
- getNextPageParam: (m, b, a) => m.length + (a || 0),
755
+ getNextPageParam: (m, b, o) => m.length + (o || 0),
750
756
  refetchOnWindowFocus: !1,
751
757
  retry: 3,
752
- ...n
758
+ ...a
753
759
  }
754
760
  }
755
761
  });
756
- return /* @__PURE__ */ P.jsx($r, { client: s, children: o });
757
- }, ct = (o) => {
758
- const { unknownErrorTranslationKey: n = "error.unknownError" } = o || {}, i = jr(n), s = ae(
762
+ return /* @__PURE__ */ P.jsx(Dr, { client: s, children: n });
763
+ }, lt = (n) => {
764
+ const { unknownErrorTranslationKey: a = "error.unknownError" } = n || {}, i = Pr(a), s = ae(
759
765
  (b) => {
760
766
  var f, c, g, h, C, S, O, A, $;
761
- const { response: a } = b || {};
762
- return a != null && a.reason ? String(a.reason) : (f = a == null ? void 0 : a.data) != null && f.reason ? String(a.data.reason) : (c = a == null ? void 0 : a.data) != null && c.message ? String(a.data.message) : (h = (g = a == null ? void 0 : a.data) == null ? void 0 : g.detail) != null && h.length && Array.isArray((C = a == null ? void 0 : a.data) == null ? void 0 : C.detail) && ((O = (S = a == null ? void 0 : a.data) == null ? void 0 : S.detail[0]) != null && O.msg) && typeof (($ = (A = a == null ? void 0 : a.data) == null ? void 0 : A.detail[0]) == null ? void 0 : $.msg) == "string" ? String(a.data.detail[0].msg) : i;
767
+ const { response: o } = b || {};
768
+ return o != null && o.reason ? String(o.reason) : (f = o == null ? void 0 : o.data) != null && f.reason ? String(o.data.reason) : (c = o == null ? void 0 : o.data) != null && c.message ? String(o.data.message) : (h = (g = o == null ? void 0 : o.data) == null ? void 0 : g.detail) != null && h.length && Array.isArray((C = o == null ? void 0 : o.data) == null ? void 0 : C.detail) && ((O = (S = o == null ? void 0 : o.data) == null ? void 0 : S.detail[0]) != null && O.msg) && typeof (($ = (A = o == null ? void 0 : o.data) == null ? void 0 : A.detail[0]) == null ? void 0 : $.msg) == "string" ? String(o.data.detail[0].msg) : i;
763
769
  },
764
770
  [i]
765
771
  );
766
772
  return { getErrorCode: ae((b) => {
767
773
  var f, c, g;
768
- const { response: a } = b || {};
769
- return a != null && a.error_code ? String(a == null ? void 0 : a.error_code) : (f = a == null ? void 0 : a.data) != null && f.error_code ? String((c = a == null ? void 0 : a.data) == null ? void 0 : c.error_code) : a != null && a.error_code ? String(a == null ? void 0 : a.error_code) : (g = a == null ? void 0 : a.data) != null && g.error_code ? String(a.data.error_code) : "unknown_error_code";
774
+ const { response: o } = b || {};
775
+ return o != null && o.error_code ? String(o == null ? void 0 : o.error_code) : (f = o == null ? void 0 : o.data) != null && f.error_code ? String((c = o == null ? void 0 : o.data) == null ? void 0 : c.error_code) : o != null && o.error_code ? String(o == null ? void 0 : o.error_code) : (g = o == null ? void 0 : o.data) != null && g.error_code ? String(o.data.error_code) : "unknown_error_code";
770
776
  }, []), printError: s };
771
- }, lt = ({
772
- data: o,
773
- fetchNextPage: n,
777
+ }, ft = ({
778
+ data: n,
779
+ fetchNextPage: a,
774
780
  isFetchingNextPage: i,
775
781
  isInitialLoading: s,
776
782
  isLoading: m,
777
783
  enabled: b = !0
778
784
  }) => {
779
- const a = ae(
785
+ const o = ae(
780
786
  async (c) => {
781
- i || !b || await n({ pageParam: (c == null ? void 0 : c.pageParam) || c.visibleRowsCount });
787
+ i || !b || await a({ pageParam: (c == null ? void 0 : c.pageParam) || c.visibleRowsCount });
782
788
  },
783
- [b, n, i]
784
- ), f = ie(() => {
785
- if (o)
786
- return o.pages.reduce((c, g) => [...c, ...g], []);
787
- }, [o]);
789
+ [b, a, i]
790
+ ), f = ue(() => {
791
+ if (n)
792
+ return n.pages.reduce((c, g) => [...c, ...g], []);
793
+ }, [n]);
788
794
  return {
789
- fetchNextPageOnRowsScrollEnd: a,
795
+ fetchNextPageOnRowsScrollEnd: o,
790
796
  isLoading: i || m,
791
797
  loadingVariant: s ? "skeleton" : "linear",
792
798
  rows: f
793
799
  };
794
- }, ft = () => ({
800
+ }, dt = () => ({
795
801
  clearAuthenticationToken: () => {
796
802
  k.defaults.headers.common.Authorization = null;
797
803
  },
798
804
  setAuthenticationToken: ({ tokenType: i, accessToken: s }) => {
799
805
  k.defaults.headers.common.Authorization = `${i} ${s}`;
800
806
  }
801
- }), Nr = (o, n = "ddd D MMM YY") => Dr(o).format(n), Wr = (o, n = "km") => {
802
- const i = Number(o);
803
- return Number.isNaN(i) ? `0 ${n}` : `${i.toFixed(2)} ${n}`;
804
- }, Lr = (o) => {
805
- const n = o && typeof o == "object" && "pathname" in o && o.pathname ? o.pathname : o;
806
- return typeof n == "string" ? n != null && n.startsWith("/") ? n != null && n.startsWith("/files") ? n : `/files${n}` : n != null && n.startsWith("files") ? `/${n}` : n != null && n.startsWith("files") ? `/${n}` : `/files/${n}` : n;
807
- }, Ne = (o, n) => {
808
- if (!o)
807
+ }), Nr = (n, a = "ddd D MMM YY") => Ve(n).format(a), Wr = (n, a = "km") => {
808
+ const i = Number(n);
809
+ return Number.isNaN(i) ? `0 ${a}` : `${i.toFixed(2)} ${a}`;
810
+ }, Lr = (n) => {
811
+ const a = n && typeof n == "object" && "pathname" in n && n.pathname ? n.pathname : n;
812
+ return typeof a == "string" ? a != null && a.startsWith("/") ? a != null && a.startsWith("/files") ? a : `/files${a}` : a != null && a.startsWith("files") ? `/${a}` : a != null && a.startsWith("files") ? `/${a}` : `/files/${a}` : a;
813
+ }, We = (n, a) => {
814
+ if (!n)
809
815
  return "";
810
- const i = Lr(o), s = typeof o == "object" && "pathname" in o ? `${o.origin}${i}` : o;
811
- return typeof n == "number" ? `${s.replace("/files", `/thumbs/${n}`)}` : s;
812
- }, dt = () => {
813
- const { apiURL: o } = Ye(se);
816
+ const i = Lr(n), s = typeof n == "object" && "pathname" in n ? `${n.origin}${i}` : n;
817
+ return typeof a == "number" ? `${s.replace("/files", `/thumbs/${a}`)}` : s;
818
+ }, vt = () => {
819
+ const { apiURL: n } = Ye(ce);
814
820
  return {
815
821
  dateAdapter: Nr,
816
822
  distanceAdapter: Wr,
817
- filePathAdapter: (i, s) => Ne(
818
- o && typeof i == "string" ? {
819
- origin: o,
823
+ filePathAdapter: (i, s) => We(
824
+ n && typeof i == "string" ? {
825
+ origin: n,
820
826
  pathname: i
821
827
  } : i,
822
828
  s
823
829
  )
824
830
  };
825
- }, Yr = (o) => o.charAt(0).toUpperCase() + o.slice(1).toLowerCase(), Mr = (o) => {
826
- const s = o.split("/").filter((m) => m.length > 0).map((m) => m.replace(/\${([^}]*)}/g, "$1").split(/[_-]/).map((c) => c.charAt(0).toUpperCase() + c.slice(1)).join("")).join("");
831
+ }, Yr = (n) => n.charAt(0).toUpperCase() + n.slice(1).toLowerCase(), Mr = (n) => {
832
+ const s = n.split("/").filter((m) => m.length > 0).map((m) => m.replace(/\${([^}]*)}/g, "$1").split(/[_-]/).map((c) => c.charAt(0).toUpperCase() + c.slice(1)).join("")).join("");
827
833
  return s.charAt(0).toLowerCase() + s.slice(1);
828
- }, Vr = (o, n, i) => {
829
- const s = Mr(n), m = Yr(i);
834
+ }, Vr = (n, a, i) => {
835
+ const s = Mr(a), m = Yr(i);
830
836
  return `${s}${m}`;
831
- }, Ur = (o) => {
832
- if (o)
833
- return (o == null ? void 0 : o.reduce((n, i) => (n[i] = {
837
+ }, Ur = (n) => {
838
+ if (n)
839
+ return (n == null ? void 0 : n.reduce((a, i) => (a[i] = {
834
840
  query: {
835
841
  useInfinite: !0,
836
842
  useInfiniteQueryParam: "offset",
837
843
  useQuery: !0
838
844
  }
839
- }, n), {})) || {};
840
- }, vt = (o) => {
841
- const { input: n = "./openapi.json", operationsToGenerateInfiniteQueryHook: i = void 0 } = o || {};
845
+ }, a), {})) || {};
846
+ }, pt = (n) => {
847
+ const { input: a = "./openapi.json", operationsToGenerateInfiniteQueryHook: i = void 0 } = n || {};
842
848
  return {
843
849
  api: {
844
850
  hooks: {
845
851
  afterAllFilesWrite: "prettier src/api/ --write"
846
852
  },
847
- input: n,
853
+ input: a,
848
854
  output: {
849
855
  client: "react-query",
850
856
  mode: "tags-split",
@@ -872,20 +878,21 @@ const et = ({
872
878
  };
873
879
  export {
874
880
  nt as AxiosConfig,
881
+ st as DaysJSConfig,
875
882
  rt as GTMSendPageView,
876
883
  at as I18nConfig,
877
- se as InjectDependenciesContext,
884
+ ce as InjectDependenciesContext,
878
885
  tt as InjectDependenciesProvider,
879
886
  ut as MapBoxConfig,
880
887
  it as MaskTextField,
881
- st as QueryClientConfigProvider,
888
+ ct as QueryClientConfigProvider,
882
889
  et as RequireAuth,
883
890
  ot as SentryConfig,
884
891
  Nr as dateAdapter,
885
892
  Wr as distanceAdapter,
886
- vt as getOrvalConfig,
887
- dt as useAdapter,
888
- ft as useAuth,
889
- lt as useInfiniteDataGrid,
890
- ct as useResponseError
893
+ pt as getOrvalConfig,
894
+ vt as useAdapter,
895
+ dt as useAuth,
896
+ ft as useInfiniteDataGrid,
897
+ lt as useResponseError
891
898
  };
package/dist/main.umd.cjs CHANGED
@@ -1,4 +1,4 @@
1
- (function(v,y){typeof exports=="object"&&typeof module<"u"?y(exports,require("react"),require("axios"),require("react-router-dom"),require("@tracktor/react-google-tag-manager"),require("i18next"),require("i18next-browser-languagedetector"),require("react-i18next"),require("@sentry/react"),require("mapbox-gl"),require("@tanstack/react-query"),require("dayjs")):typeof define=="function"&&define.amd?define(["exports","react","axios","react-router-dom","@tracktor/react-google-tag-manager","i18next","i18next-browser-languagedetector","react-i18next","@sentry/react","mapbox-gl","@tanstack/react-query","dayjs"],y):(v=typeof globalThis<"u"?globalThis:v||self,y(v["@tracktor/shared-module"]={},v.React,v.axios,v.reactRouterDom,v.reactGoogleTagManager,v.i18n,v.LanguageDetector,v.reactI18next,v.Sentry,v.mapbox,v.reactQuery,v.dayjs))})(this,function(v,y,P,k,We,x,Ve,Ye,Ue,ue,se,ze){"use strict";function Be(n){const a=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(n){for(const i in n)if(i!=="default"){const s=Object.getOwnPropertyDescriptor(n,i);Object.defineProperty(a,i,s.get?s:{enumerable:!0,get:()=>n[i]})}}return a.default=n,Object.freeze(a)}const K=Be(Ue);var Q={exports:{}},Y={};/**
1
+ (function(f,y){typeof exports=="object"&&typeof module<"u"?y(exports,require("react"),require("axios"),require("react-router-dom"),require("@tracktor/react-google-tag-manager"),require("i18next"),require("i18next-browser-languagedetector"),require("react-i18next"),require("@sentry/react"),require("mapbox-gl"),require("dayjs"),require("@tanstack/react-query")):typeof define=="function"&&define.amd?define(["exports","react","axios","react-router-dom","@tracktor/react-google-tag-manager","i18next","i18next-browser-languagedetector","react-i18next","@sentry/react","mapbox-gl","dayjs","@tanstack/react-query"],y):(f=typeof globalThis<"u"?globalThis:f||self,y(f["@tracktor/shared-module"]={},f.React,f.axios,f.reactRouterDom,f.reactGoogleTagManager,f.i18n,f.LanguageDetector,f.reactI18next,f.Sentry,f.mapbox,f.dayjs,f.reactQuery))})(this,function(f,y,P,k,Ve,x,Ye,Ue,ze,ue,se,ce){"use strict";function Be(t){const a=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const i in t)if(i!=="default"){const u=Object.getOwnPropertyDescriptor(t,i);Object.defineProperty(a,i,u.get?u:{enumerable:!0,get:()=>t[i]})}}return a.default=t,Object.freeze(a)}const K=Be(ze);var $e=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},Q={exports:{}},Y={};/**
2
2
  * @license React
3
3
  * react-jsx-runtime.development.js
4
4
  *
@@ -6,17 +6,17 @@
6
6
  *
7
7
  * This source code is licensed under the MIT license found in the
8
8
  * LICENSE file in the root directory of this source tree.
9
- */var ce;function $e(){return ce||(ce=1,process.env.NODE_ENV!=="production"&&function(){var n=y,a=Symbol.for("react.element"),i=Symbol.for("react.portal"),s=Symbol.for("react.fragment"),m=Symbol.for("react.strict_mode"),C=Symbol.for("react.profiler"),o=Symbol.for("react.provider"),f=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),h=Symbol.for("react.suspense"),E=Symbol.for("react.suspense_list"),S=Symbol.for("react.memo"),j=Symbol.for("react.lazy"),A=Symbol.for("react.offscreen"),N=Symbol.iterator,_="@@iterator";function pe(e){if(e===null||typeof e!="object")return null;var r=N&&e[N]||e[_];return typeof r=="function"?r:null}var L=n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function T(e){{for(var r=arguments.length,t=new Array(r>1?r-1:0),u=1;u<r;u++)t[u-1]=arguments[u];dr("error",e,t)}}function dr(e,r,t){{var u=L.ReactDebugCurrentFrame,p=u.getStackAddendum();p!==""&&(r+="%s",t=t.concat([p]));var g=t.map(function(d){return String(d)});g.unshift("Warning: "+r),Function.prototype.apply.call(console[e],console,g)}}var vr=!1,pr=!1,gr=!1,mr=!1,hr=!1,ge;ge=Symbol.for("react.module.reference");function yr(e){return!!(typeof e=="string"||typeof e=="function"||e===s||e===C||hr||e===m||e===h||e===E||mr||e===A||vr||pr||gr||typeof e=="object"&&e!==null&&(e.$$typeof===j||e.$$typeof===S||e.$$typeof===o||e.$$typeof===f||e.$$typeof===c||e.$$typeof===ge||e.getModuleId!==void 0))}function Er(e,r,t){var u=e.displayName;if(u)return u;var p=r.displayName||r.name||"";return p!==""?t+"("+p+")":t}function me(e){return e.displayName||"Context"}function D(e){if(e==null)return null;if(typeof e.tag=="number"&&T("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case s:return"Fragment";case i:return"Portal";case C:return"Profiler";case m:return"StrictMode";case h:return"Suspense";case E:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case f:var r=e;return me(r)+".Consumer";case o:var t=e;return me(t._context)+".Provider";case c:return Er(e,e.render,"ForwardRef");case S:var u=e.displayName||null;return u!==null?u:D(e.type)||"Memo";case j:{var p=e,g=p._payload,d=p._init;try{return D(d(g))}catch{return null}}}return null}var M=Object.assign,z=0,he,ye,Ee,be,_e,Re,Ce;function Te(){}Te.__reactDisabledLog=!0;function br(){{if(z===0){he=console.log,ye=console.info,Ee=console.warn,be=console.error,_e=console.group,Re=console.groupCollapsed,Ce=console.groupEnd;var e={configurable:!0,enumerable:!0,value:Te,writable:!0};Object.defineProperties(console,{info:e,log:e,warn:e,error:e,group:e,groupCollapsed:e,groupEnd:e})}z++}}function _r(){{if(z--,z===0){var e={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:M({},e,{value:he}),info:M({},e,{value:ye}),warn:M({},e,{value:Ee}),error:M({},e,{value:be}),group:M({},e,{value:_e}),groupCollapsed:M({},e,{value:Re}),groupEnd:M({},e,{value:Ce})})}z<0&&T("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var Z=L.ReactCurrentDispatcher,ee;function G(e,r,t){{if(ee===void 0)try{throw Error()}catch(p){var u=p.stack.trim().match(/\n( *(at )?)/);ee=u&&u[1]||""}return`
10
- `+ee+e}}var re=!1,q;{var Rr=typeof WeakMap=="function"?WeakMap:Map;q=new Rr}function Se(e,r){if(!e||re)return"";{var t=q.get(e);if(t!==void 0)return t}var u;re=!0;var p=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var g;g=Z.current,Z.current=null,br();try{if(r){var d=function(){throw Error()};if(Object.defineProperty(d.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(d,[])}catch(I){u=I}Reflect.construct(e,[],d)}else{try{d.call()}catch(I){u=I}e.call(d.prototype)}}else{try{throw Error()}catch(I){u=I}e()}}catch(I){if(I&&u&&typeof I.stack=="string"){for(var l=I.stack.split(`
11
- `),O=u.stack.split(`
12
- `),b=l.length-1,R=O.length-1;b>=1&&R>=0&&l[b]!==O[R];)R--;for(;b>=1&&R>=0;b--,R--)if(l[b]!==O[R]){if(b!==1||R!==1)do if(b--,R--,R<0||l[b]!==O[R]){var w=`
13
- `+l[b].replace(" at new "," at ");return e.displayName&&w.includes("<anonymous>")&&(w=w.replace("<anonymous>",e.displayName)),typeof e=="function"&&q.set(e,w),w}while(b>=1&&R>=0);break}}}finally{re=!1,Z.current=g,_r(),Error.prepareStackTrace=p}var V=e?e.displayName||e.name:"",Me=V?G(V):"";return typeof e=="function"&&q.set(e,Me),Me}function Cr(e,r,t){return Se(e,!1)}function Tr(e){var r=e.prototype;return!!(r&&r.isReactComponent)}function J(e,r,t){if(e==null)return"";if(typeof e=="function")return Se(e,Tr(e));if(typeof e=="string")return G(e);switch(e){case h:return G("Suspense");case E:return G("SuspenseList")}if(typeof e=="object")switch(e.$$typeof){case c:return Cr(e.render);case S:return J(e.type,r,t);case j:{var u=e,p=u._payload,g=u._init;try{return J(g(p),r,t)}catch{}}}return""}var X=Object.prototype.hasOwnProperty,Oe={},je=L.ReactDebugCurrentFrame;function H(e){if(e){var r=e._owner,t=J(e.type,e._source,r?r.type:null);je.setExtraStackFrame(t)}else je.setExtraStackFrame(null)}function Sr(e,r,t,u,p){{var g=Function.call.bind(X);for(var d in e)if(g(e,d)){var l=void 0;try{if(typeof e[d]!="function"){var O=Error((u||"React class")+": "+t+" type `"+d+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof e[d]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw O.name="Invariant Violation",O}l=e[d](r,d,u,t,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(b){l=b}l&&!(l instanceof Error)&&(H(p),T("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",u||"React class",t,d,typeof l),H(null)),l instanceof Error&&!(l.message in Oe)&&(Oe[l.message]=!0,H(p),T("Failed %s type: %s",t,l.message),H(null))}}}var Or=Array.isArray;function te(e){return Or(e)}function jr(e){{var r=typeof Symbol=="function"&&Symbol.toStringTag,t=r&&e[Symbol.toStringTag]||e.constructor.name||"Object";return t}}function wr(e){try{return we(e),!1}catch{return!0}}function we(e){return""+e}function Pe(e){if(wr(e))return T("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",jr(e)),we(e)}var B=L.ReactCurrentOwner,Pr={key:!0,ref:!0,__self:!0,__source:!0},ke,Ae,ne;ne={};function kr(e){if(X.call(e,"ref")){var r=Object.getOwnPropertyDescriptor(e,"ref").get;if(r&&r.isReactWarning)return!1}return e.ref!==void 0}function Ar(e){if(X.call(e,"key")){var r=Object.getOwnPropertyDescriptor(e,"key").get;if(r&&r.isReactWarning)return!1}return e.key!==void 0}function xr(e,r){if(typeof e.ref=="string"&&B.current&&r&&B.current.stateNode!==r){var t=D(B.current.type);ne[t]||(T('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref',D(B.current.type),e.ref),ne[t]=!0)}}function Fr(e,r){{var t=function(){ke||(ke=!0,T("%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://reactjs.org/link/special-props)",r))};t.isReactWarning=!0,Object.defineProperty(e,"key",{get:t,configurable:!0})}}function Dr(e,r){{var t=function(){Ae||(Ae=!0,T("%s: `ref` 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://reactjs.org/link/special-props)",r))};t.isReactWarning=!0,Object.defineProperty(e,"ref",{get:t,configurable:!0})}}var Ir=function(e,r,t,u,p,g,d){var l={$$typeof:a,type:e,key:r,ref:t,props:d,_owner:g};return l._store={},Object.defineProperty(l._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(l,"_self",{configurable:!1,enumerable:!1,writable:!1,value:u}),Object.defineProperty(l,"_source",{configurable:!1,enumerable:!1,writable:!1,value:p}),Object.freeze&&(Object.freeze(l.props),Object.freeze(l)),l};function Nr(e,r,t,u,p){{var g,d={},l=null,O=null;t!==void 0&&(Pe(t),l=""+t),Ar(r)&&(Pe(r.key),l=""+r.key),kr(r)&&(O=r.ref,xr(r,p));for(g in r)X.call(r,g)&&!Pr.hasOwnProperty(g)&&(d[g]=r[g]);if(e&&e.defaultProps){var b=e.defaultProps;for(g in b)d[g]===void 0&&(d[g]=b[g])}if(l||O){var R=typeof e=="function"?e.displayName||e.name||"Unknown":e;l&&Fr(d,R),O&&Dr(d,R)}return Ir(e,l,O,p,u,B.current,d)}}var ae=L.ReactCurrentOwner,xe=L.ReactDebugCurrentFrame;function W(e){if(e){var r=e._owner,t=J(e.type,e._source,r?r.type:null);xe.setExtraStackFrame(t)}else xe.setExtraStackFrame(null)}var oe;oe=!1;function ie(e){return typeof e=="object"&&e!==null&&e.$$typeof===a}function Fe(){{if(ae.current){var e=D(ae.current.type);if(e)return`
9
+ */var le;function Ge(){return le||(le=1,process.env.NODE_ENV!=="production"&&function(){var t=y,a=Symbol.for("react.element"),i=Symbol.for("react.portal"),u=Symbol.for("react.fragment"),g=Symbol.for("react.strict_mode"),C=Symbol.for("react.profiler"),o=Symbol.for("react.provider"),d=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),h=Symbol.for("react.suspense"),_=Symbol.for("react.suspense_list"),S=Symbol.for("react.memo"),O=Symbol.for("react.lazy"),A=Symbol.for("react.offscreen"),N=Symbol.iterator,E="@@iterator";function ge(e){if(e===null||typeof e!="object")return null;var r=N&&e[N]||e[E];return typeof r=="function"?r:null}var M=t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function T(e){{for(var r=arguments.length,n=new Array(r>1?r-1:0),s=1;s<r;s++)n[s-1]=arguments[s];mr("error",e,n)}}function mr(e,r,n){{var s=M.ReactDebugCurrentFrame,p=s.getStackAddendum();p!==""&&(r+="%s",n=n.concat([p]));var m=n.map(function(v){return String(v)});m.unshift("Warning: "+r),Function.prototype.apply.call(console[e],console,m)}}var yr=!1,hr=!1,_r=!1,br=!1,Er=!1,me;me=Symbol.for("react.module.reference");function Rr(e){return!!(typeof e=="string"||typeof e=="function"||e===u||e===C||Er||e===g||e===h||e===_||br||e===A||yr||hr||_r||typeof e=="object"&&e!==null&&(e.$$typeof===O||e.$$typeof===S||e.$$typeof===o||e.$$typeof===d||e.$$typeof===c||e.$$typeof===me||e.getModuleId!==void 0))}function Cr(e,r,n){var s=e.displayName;if(s)return s;var p=r.displayName||r.name||"";return p!==""?n+"("+p+")":n}function ye(e){return e.displayName||"Context"}function F(e){if(e==null)return null;if(typeof e.tag=="number"&&T("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case u:return"Fragment";case i:return"Portal";case C:return"Profiler";case g:return"StrictMode";case h:return"Suspense";case _:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case d:var r=e;return ye(r)+".Consumer";case o:var n=e;return ye(n._context)+".Provider";case c:return Cr(e,e.render,"ForwardRef");case S:var s=e.displayName||null;return s!==null?s:F(e.type)||"Memo";case O:{var p=e,m=p._payload,v=p._init;try{return F(v(m))}catch{return null}}}return null}var L=Object.assign,z=0,he,_e,be,Ee,Re,Ce,Te;function Se(){}Se.__reactDisabledLog=!0;function Tr(){{if(z===0){he=console.log,_e=console.info,be=console.warn,Ee=console.error,Re=console.group,Ce=console.groupCollapsed,Te=console.groupEnd;var e={configurable:!0,enumerable:!0,value:Se,writable:!0};Object.defineProperties(console,{info:e,log:e,warn:e,error:e,group:e,groupCollapsed:e,groupEnd:e})}z++}}function Sr(){{if(z--,z===0){var e={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:L({},e,{value:he}),info:L({},e,{value:_e}),warn:L({},e,{value:be}),error:L({},e,{value:Ee}),group:L({},e,{value:Re}),groupCollapsed:L({},e,{value:Ce}),groupEnd:L({},e,{value:Te})})}z<0&&T("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var Z=M.ReactCurrentDispatcher,ee;function G(e,r,n){{if(ee===void 0)try{throw Error()}catch(p){var s=p.stack.trim().match(/\n( *(at )?)/);ee=s&&s[1]||""}return`
10
+ `+ee+e}}var re=!1,J;{var wr=typeof WeakMap=="function"?WeakMap:Map;J=new wr}function we(e,r){if(!e||re)return"";{var n=J.get(e);if(n!==void 0)return n}var s;re=!0;var p=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var m;m=Z.current,Z.current=null,Tr();try{if(r){var v=function(){throw Error()};if(Object.defineProperty(v.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(v,[])}catch(I){s=I}Reflect.construct(e,[],v)}else{try{v.call()}catch(I){s=I}e.call(v.prototype)}}else{try{throw Error()}catch(I){s=I}e()}}catch(I){if(I&&s&&typeof I.stack=="string"){for(var l=I.stack.split(`
11
+ `),w=s.stack.split(`
12
+ `),b=l.length-1,R=w.length-1;b>=1&&R>=0&&l[b]!==w[R];)R--;for(;b>=1&&R>=0;b--,R--)if(l[b]!==w[R]){if(b!==1||R!==1)do if(b--,R--,R<0||l[b]!==w[R]){var j=`
13
+ `+l[b].replace(" at new "," at ");return e.displayName&&j.includes("<anonymous>")&&(j=j.replace("<anonymous>",e.displayName)),typeof e=="function"&&J.set(e,j),j}while(b>=1&&R>=0);break}}}finally{re=!1,Z.current=m,Sr(),Error.prepareStackTrace=p}var V=e?e.displayName||e.name:"",We=V?G(V):"";return typeof e=="function"&&J.set(e,We),We}function Or(e,r,n){return we(e,!1)}function jr(e){var r=e.prototype;return!!(r&&r.isReactComponent)}function q(e,r,n){if(e==null)return"";if(typeof e=="function")return we(e,jr(e));if(typeof e=="string")return G(e);switch(e){case h:return G("Suspense");case _:return G("SuspenseList")}if(typeof e=="object")switch(e.$$typeof){case c:return Or(e.render);case S:return q(e.type,r,n);case O:{var s=e,p=s._payload,m=s._init;try{return q(m(p),r,n)}catch{}}}return""}var X=Object.prototype.hasOwnProperty,Oe={},je=M.ReactDebugCurrentFrame;function H(e){if(e){var r=e._owner,n=q(e.type,e._source,r?r.type:null);je.setExtraStackFrame(n)}else je.setExtraStackFrame(null)}function Pr(e,r,n,s,p){{var m=Function.call.bind(X);for(var v in e)if(m(e,v)){var l=void 0;try{if(typeof e[v]!="function"){var w=Error((s||"React class")+": "+n+" type `"+v+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof e[v]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw w.name="Invariant Violation",w}l=e[v](r,v,s,n,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(b){l=b}l&&!(l instanceof Error)&&(H(p),T("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",s||"React class",n,v,typeof l),H(null)),l instanceof Error&&!(l.message in Oe)&&(Oe[l.message]=!0,H(p),T("Failed %s type: %s",n,l.message),H(null))}}}var kr=Array.isArray;function te(e){return kr(e)}function Ar(e){{var r=typeof Symbol=="function"&&Symbol.toStringTag,n=r&&e[Symbol.toStringTag]||e.constructor.name||"Object";return n}}function xr(e){try{return Pe(e),!1}catch{return!0}}function Pe(e){return""+e}function ke(e){if(xr(e))return T("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",Ar(e)),Pe(e)}var B=M.ReactCurrentOwner,Dr={key:!0,ref:!0,__self:!0,__source:!0},Ae,xe,ne;ne={};function Fr(e){if(X.call(e,"ref")){var r=Object.getOwnPropertyDescriptor(e,"ref").get;if(r&&r.isReactWarning)return!1}return e.ref!==void 0}function Ir(e){if(X.call(e,"key")){var r=Object.getOwnPropertyDescriptor(e,"key").get;if(r&&r.isReactWarning)return!1}return e.key!==void 0}function Nr(e,r){if(typeof e.ref=="string"&&B.current&&r&&B.current.stateNode!==r){var n=F(B.current.type);ne[n]||(T('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref',F(B.current.type),e.ref),ne[n]=!0)}}function Mr(e,r){{var n=function(){Ae||(Ae=!0,T("%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://reactjs.org/link/special-props)",r))};n.isReactWarning=!0,Object.defineProperty(e,"key",{get:n,configurable:!0})}}function Lr(e,r){{var n=function(){xe||(xe=!0,T("%s: `ref` 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://reactjs.org/link/special-props)",r))};n.isReactWarning=!0,Object.defineProperty(e,"ref",{get:n,configurable:!0})}}var Wr=function(e,r,n,s,p,m,v){var l={$$typeof:a,type:e,key:r,ref:n,props:v,_owner:m};return l._store={},Object.defineProperty(l._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(l,"_self",{configurable:!1,enumerable:!1,writable:!1,value:s}),Object.defineProperty(l,"_source",{configurable:!1,enumerable:!1,writable:!1,value:p}),Object.freeze&&(Object.freeze(l.props),Object.freeze(l)),l};function Vr(e,r,n,s,p){{var m,v={},l=null,w=null;n!==void 0&&(ke(n),l=""+n),Ir(r)&&(ke(r.key),l=""+r.key),Fr(r)&&(w=r.ref,Nr(r,p));for(m in r)X.call(r,m)&&!Dr.hasOwnProperty(m)&&(v[m]=r[m]);if(e&&e.defaultProps){var b=e.defaultProps;for(m in b)v[m]===void 0&&(v[m]=b[m])}if(l||w){var R=typeof e=="function"?e.displayName||e.name||"Unknown":e;l&&Mr(v,R),w&&Lr(v,R)}return Wr(e,l,w,p,s,B.current,v)}}var ae=M.ReactCurrentOwner,De=M.ReactDebugCurrentFrame;function W(e){if(e){var r=e._owner,n=q(e.type,e._source,r?r.type:null);De.setExtraStackFrame(n)}else De.setExtraStackFrame(null)}var oe;oe=!1;function ie(e){return typeof e=="object"&&e!==null&&e.$$typeof===a}function Fe(){{if(ae.current){var e=F(ae.current.type);if(e)return`
14
14
 
15
- Check the render method of \``+e+"`."}return""}}function Lr(e){{if(e!==void 0){var r=e.fileName.replace(/^.*[\\\/]/,""),t=e.lineNumber;return`
15
+ Check the render method of \``+e+"`."}return""}}function Yr(e){{if(e!==void 0){var r=e.fileName.replace(/^.*[\\\/]/,""),n=e.lineNumber;return`
16
16
 
17
- Check your code at `+r+":"+t+"."}return""}}var De={};function Mr(e){{var r=Fe();if(!r){var t=typeof e=="string"?e:e.displayName||e.name;t&&(r=`
17
+ Check your code at `+r+":"+n+"."}return""}}var Ie={};function Ur(e){{var r=Fe();if(!r){var n=typeof e=="string"?e:e.displayName||e.name;n&&(r=`
18
18
 
19
- Check the top-level render call using <`+t+">.")}return r}}function Ie(e,r){{if(!e._store||e._store.validated||e.key!=null)return;e._store.validated=!0;var t=Mr(r);if(De[t])return;De[t]=!0;var u="";e&&e._owner&&e._owner!==ae.current&&(u=" It was passed a child from "+D(e._owner.type)+"."),W(e),T('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',t,u),W(null)}}function Ne(e,r){{if(typeof e!="object")return;if(te(e))for(var t=0;t<e.length;t++){var u=e[t];ie(u)&&Ie(u,r)}else if(ie(e))e._store&&(e._store.validated=!0);else if(e){var p=pe(e);if(typeof p=="function"&&p!==e.entries)for(var g=p.call(e),d;!(d=g.next()).done;)ie(d.value)&&Ie(d.value,r)}}}function Wr(e){{var r=e.type;if(r==null||typeof r=="string")return;var t;if(typeof r=="function")t=r.propTypes;else if(typeof r=="object"&&(r.$$typeof===c||r.$$typeof===S))t=r.propTypes;else return;if(t){var u=D(r);Sr(t,e.props,"prop",u,e)}else if(r.PropTypes!==void 0&&!oe){oe=!0;var p=D(r);T("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",p||"Unknown")}typeof r.getDefaultProps=="function"&&!r.getDefaultProps.isReactClassApproved&&T("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function Vr(e){{for(var r=Object.keys(e.props),t=0;t<r.length;t++){var u=r[t];if(u!=="children"&&u!=="key"){W(e),T("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",u),W(null);break}}e.ref!==null&&(W(e),T("Invalid attribute `ref` supplied to `React.Fragment`."),W(null))}}function Le(e,r,t,u,p,g){{var d=yr(e);if(!d){var l="";(e===void 0||typeof e=="object"&&e!==null&&Object.keys(e).length===0)&&(l+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var O=Lr(p);O?l+=O:l+=Fe();var b;e===null?b="null":te(e)?b="array":e!==void 0&&e.$$typeof===a?(b="<"+(D(e.type)||"Unknown")+" />",l=" Did you accidentally export a JSX literal instead of a component?"):b=typeof e,T("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",b,l)}var R=Nr(e,r,t,p,g);if(R==null)return R;if(d){var w=r.children;if(w!==void 0)if(u)if(te(w)){for(var V=0;V<w.length;V++)Ne(w[V],e);Object.freeze&&Object.freeze(w)}else T("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else Ne(w,e)}return e===s?Vr(R):Wr(R),R}}function Yr(e,r,t){return Le(e,r,t,!0)}function Ur(e,r,t){return Le(e,r,t,!1)}var zr=Ur,Br=Yr;Y.Fragment=s,Y.jsx=zr,Y.jsxs=Br}()),Y}var U={};/**
19
+ Check the top-level render call using <`+n+">.")}return r}}function Ne(e,r){{if(!e._store||e._store.validated||e.key!=null)return;e._store.validated=!0;var n=Ur(r);if(Ie[n])return;Ie[n]=!0;var s="";e&&e._owner&&e._owner!==ae.current&&(s=" It was passed a child from "+F(e._owner.type)+"."),W(e),T('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',n,s),W(null)}}function Me(e,r){{if(typeof e!="object")return;if(te(e))for(var n=0;n<e.length;n++){var s=e[n];ie(s)&&Ne(s,r)}else if(ie(e))e._store&&(e._store.validated=!0);else if(e){var p=ge(e);if(typeof p=="function"&&p!==e.entries)for(var m=p.call(e),v;!(v=m.next()).done;)ie(v.value)&&Ne(v.value,r)}}}function zr(e){{var r=e.type;if(r==null||typeof r=="string")return;var n;if(typeof r=="function")n=r.propTypes;else if(typeof r=="object"&&(r.$$typeof===c||r.$$typeof===S))n=r.propTypes;else return;if(n){var s=F(r);Pr(n,e.props,"prop",s,e)}else if(r.PropTypes!==void 0&&!oe){oe=!0;var p=F(r);T("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",p||"Unknown")}typeof r.getDefaultProps=="function"&&!r.getDefaultProps.isReactClassApproved&&T("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function Br(e){{for(var r=Object.keys(e.props),n=0;n<r.length;n++){var s=r[n];if(s!=="children"&&s!=="key"){W(e),T("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",s),W(null);break}}e.ref!==null&&(W(e),T("Invalid attribute `ref` supplied to `React.Fragment`."),W(null))}}function Le(e,r,n,s,p,m){{var v=Rr(e);if(!v){var l="";(e===void 0||typeof e=="object"&&e!==null&&Object.keys(e).length===0)&&(l+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var w=Yr(p);w?l+=w:l+=Fe();var b;e===null?b="null":te(e)?b="array":e!==void 0&&e.$$typeof===a?(b="<"+(F(e.type)||"Unknown")+" />",l=" Did you accidentally export a JSX literal instead of a component?"):b=typeof e,T("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",b,l)}var R=Vr(e,r,n,p,m);if(R==null)return R;if(v){var j=r.children;if(j!==void 0)if(s)if(te(j)){for(var V=0;V<j.length;V++)Me(j[V],e);Object.freeze&&Object.freeze(j)}else T("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else Me(j,e)}return e===u?Br(R):zr(R),R}}function $r(e,r,n){return Le(e,r,n,!0)}function Gr(e,r,n){return Le(e,r,n,!1)}var Jr=Gr,qr=$r;Y.Fragment=u,Y.jsx=Jr,Y.jsxs=qr}()),Y}var U={};/**
20
20
  * @license React
21
21
  * react-jsx-runtime.production.min.js
22
22
  *
@@ -24,4 +24,4 @@ Check the top-level render call using <`+t+">.")}return r}}function Ie(e,r){{if(
24
24
  *
25
25
  * This source code is licensed under the MIT license found in the
26
26
  * LICENSE file in the root directory of this source tree.
27
- */var le;function Ge(){if(le)return U;le=1;var n=y,a=Symbol.for("react.element"),i=Symbol.for("react.fragment"),s=Object.prototype.hasOwnProperty,m=n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,C={key:!0,ref:!0,__self:!0,__source:!0};function o(f,c,h){var E,S={},j=null,A=null;h!==void 0&&(j=""+h),c.key!==void 0&&(j=""+c.key),c.ref!==void 0&&(A=c.ref);for(E in c)s.call(c,E)&&!C.hasOwnProperty(E)&&(S[E]=c[E]);if(f&&f.defaultProps)for(E in c=f.defaultProps,c)S[E]===void 0&&(S[E]=c[E]);return{$$typeof:a,type:f,key:j,ref:A,props:S,_owner:m.current}}return U.Fragment=i,U.jsx=o,U.jsxs=o,U}process.env.NODE_ENV==="production"?Q.exports=Ge():Q.exports=$e();var F=Q.exports;const qe=({Fallback:n,loginPath:a="/login",localStorageKey:i="user",redirect401Path:s="/login",isLogged:m})=>{var S,j,A,N;const[C,o]=y.useState(null),f=k.useLocation(),c=y.useRef(!1),h=typeof m=="function"?m():!!m,E=typeof h=="boolean"?h:h==null?void 0:h.isLogged;return y.useLayoutEffect(()=>{c.current||(c.current=!0,P==null||P.interceptors.response.use(_=>_,async _=>{var T;return typeof _=="object"&&_&&"response"in _&&_.response&&typeof _.response=="object"&&"status"in _.response&&_.response&&typeof _.response=="object"&&"status"in _.response&&((T=_==null?void 0:_.response)==null?void 0:T.status)===401&&(P.defaults.headers.common.Authorization=null,localStorage.removeItem(i),o(s)),Promise.reject(_)}))},[i,s]),E&&!C?F.jsx(y.Suspense,{fallback:n,children:(j=(S=f.state)==null?void 0:S.from)!=null&&j.state&&((N=(A=f.state)==null?void 0:A.from)==null?void 0:N.pathname)===a?F.jsx(k.Navigate,{to:f.state.from.state.from.pathname+f.state.from.state.from.search,replace:!0}):F.jsx(k.Outlet,{})}):F.jsx(k.Navigate,{to:a,state:{from:f},replace:!0})},Je=()=>{const{pathname:n}=k.useLocation(),{sendEvent:a}=We.useGoogleTagManager();return y.useEffect(()=>{a({event:"pageView",pathname:n})},[n,a]),F.jsx(k.Outlet,{})},$=y.createContext({apiURL:void 0,children:void 0}),Xe=({children:n,apiURL:a})=>{const i=y.useMemo(()=>({apiURL:a}),[a]);return F.jsx($.Provider,{value:i,children:n})},He=({tokenTypeKey:n="tokenType",userLocalStorageKey:a="user",tokenKey:i="accessToken",postContentType:s="application/json",...m})=>{const{apiURL:C=m.baseURL}=y.useContext($);if(!P.defaults)return null;const o=localStorage.getItem(a),f=o?JSON.parse(o):null,c=f!=null&&f[n]?f[n]:null,h=f!=null&&f[i]?f[i]:null,E=o?`${c} ${h}`:null;return P.defaults.baseURL=C,P.defaults.headers.post["Content-Type"]=s,E&&(P.defaults.headers.common.Authorization=E),null},Ke=({debug:n,resources:a})=>(x!=null&&x.isInitialized||(x.use(Ve).use(Ye.initReactI18next).init({debug:n,fallbackLng:"en",interpolation:{escapeValue:!1},load:"languageOnly",react:{bindI18n:!1,useSuspense:!0},resources:a,returnNull:!1}).then(()=>{document.documentElement.lang!==x.resolvedLanguage&&x.resolvedLanguage&&document.documentElement.setAttribute("lang",x.resolvedLanguage)}),x.on("languageChanged",i=>{document.documentElement.setAttribute("lang",i)})),null),Qe=({dsn:n,integrations:a,tracesSampleRate:i,replaysSessionSampleRate:s,replaysOnErrorSampleRate:m,tracePropagationTargets:C,ignoreErrors:o,debug:f,environment:c})=>(K.isInitialized()||(f||process.env.NODE_ENV==="prod"||process.env.NODE_ENV==="production")&&K.init({debug:f,dsn:n,environment:c||"production",ignoreErrors:[...o||[],/dynamically imported module/],integrations:[K.reactRouterV6BrowserTracingIntegration({createRoutesFromChildren:k.createRoutesFromChildren,matchRoutes:k.matchRoutes,useEffect:y.useEffect,useLocation:k.useLocation,useNavigationType:k.useNavigationType}),...a||[]],replaysOnErrorSampleRate:m||1,replaysSessionSampleRate:s||.1,tracePropagationTargets:C,tracesSampleRate:i||1}),null),Ze=({IMaskMixin:n,...a})=>{const i=y.useMemo(()=>n(({TextField:s,...m})=>F.jsx(s,{...m})),[n]);return F.jsx(i,{...a})},er=({accessToken:n})=>(ue&&n&&(ue.accessToken=n),null),rr=({children:n,defaultQueriesOptions:a,defaultMutationsOptions:i})=>{const s=new se.QueryClient({defaultOptions:{mutations:{...i},queries:{getNextPageParam:(m,C,o)=>m.length+(o||0),refetchOnWindowFocus:!1,retry:3,...a}}});return F.jsx(se.QueryClientProvider,{client:s,children:n})},tr=n=>{const{unknownErrorTranslationKey:a="error.unknownError"}=n||{},i=x.t(a),s=y.useCallback(C=>{var f,c,h,E,S,j,A,N,_;const{response:o}=C||{};return o!=null&&o.reason?String(o.reason):(f=o==null?void 0:o.data)!=null&&f.reason?String(o.data.reason):(c=o==null?void 0:o.data)!=null&&c.message?String(o.data.message):(E=(h=o==null?void 0:o.data)==null?void 0:h.detail)!=null&&E.length&&Array.isArray((S=o==null?void 0:o.data)==null?void 0:S.detail)&&((A=(j=o==null?void 0:o.data)==null?void 0:j.detail[0])!=null&&A.msg)&&typeof((_=(N=o==null?void 0:o.data)==null?void 0:N.detail[0])==null?void 0:_.msg)=="string"?String(o.data.detail[0].msg):i},[i]);return{getErrorCode:y.useCallback(C=>{var f,c,h;const{response:o}=C||{};return o!=null&&o.error_code?String(o==null?void 0:o.error_code):(f=o==null?void 0:o.data)!=null&&f.error_code?String((c=o==null?void 0:o.data)==null?void 0:c.error_code):o!=null&&o.error_code?String(o==null?void 0:o.error_code):(h=o==null?void 0:o.data)!=null&&h.error_code?String(o.data.error_code):"unknown_error_code"},[]),printError:s}},nr=({data:n,fetchNextPage:a,isFetchingNextPage:i,isInitialLoading:s,isLoading:m,enabled:C=!0})=>{const o=y.useCallback(async c=>{i||!C||await a({pageParam:(c==null?void 0:c.pageParam)||c.visibleRowsCount})},[C,a,i]),f=y.useMemo(()=>{if(n)return n.pages.reduce((c,h)=>[...c,...h],[])},[n]);return{fetchNextPageOnRowsScrollEnd:o,isLoading:i||m,loadingVariant:s?"skeleton":"linear",rows:f}},ar=()=>({clearAuthenticationToken:()=>{P.defaults.headers.common.Authorization=null},setAuthenticationToken:({tokenType:i,accessToken:s})=>{P.defaults.headers.common.Authorization=`${i} ${s}`}}),fe=(n,a="ddd D MMM YY")=>ze(n).format(a),de=(n,a="km")=>{const i=Number(n);return Number.isNaN(i)?`0 ${a}`:`${i.toFixed(2)} ${a}`},or=n=>{const a=n&&typeof n=="object"&&"pathname"in n&&n.pathname?n.pathname:n;return typeof a=="string"?a!=null&&a.startsWith("/")?a!=null&&a.startsWith("/files")?a:`/files${a}`:a!=null&&a.startsWith("files")?`/${a}`:a!=null&&a.startsWith("files")?`/${a}`:`/files/${a}`:a},ve=(n,a)=>{if(!n)return"";const i=or(n),s=typeof n=="object"&&"pathname"in n?`${n.origin}${i}`:n;return typeof a=="number"?`${s.replace("/files",`/thumbs/${a}`)}`:s},ir=()=>{const{apiURL:n}=y.useContext($);return{dateAdapter:fe,distanceAdapter:de,filePathAdapter:(i,s)=>ve(n&&typeof i=="string"?{origin:n,pathname:i}:i,s)}},ur=n=>n.charAt(0).toUpperCase()+n.slice(1).toLowerCase(),sr=n=>{const s=n.split("/").filter(m=>m.length>0).map(m=>m.replace(/\${([^}]*)}/g,"$1").split(/[_-]/).map(c=>c.charAt(0).toUpperCase()+c.slice(1)).join("")).join("");return s.charAt(0).toLowerCase()+s.slice(1)},cr=(n,a,i)=>{const s=sr(a),m=ur(i);return`${s}${m}`},lr=n=>{if(n)return(n==null?void 0:n.reduce((a,i)=>(a[i]={query:{useInfinite:!0,useInfiniteQueryParam:"offset",useQuery:!0}},a),{}))||{}},fr=n=>{const{input:a="./openapi.json",operationsToGenerateInfiniteQueryHook:i=void 0}=n||{};return{api:{hooks:{afterAllFilesWrite:"prettier src/api/ --write"},input:a,output:{client:"react-query",mode:"tags-split",override:{header:s=>["Generated by orval 🍺",...s.title?[s.title]:[],...s.description?[s.description]:[]],mutator:{name:"axiosCustomInstance",path:`${__dirname}/config/orval/mutator/axiosCustomInstance.ts`},operationName:cr,...(i==null?void 0:i.length)&&{operations:lr(i)},query:{useQuery:!0}},schemas:"src/api/model",target:"src/api/services/api.ts"}}}};v.AxiosConfig=He,v.GTMSendPageView=Je,v.I18nConfig=Ke,v.InjectDependenciesContext=$,v.InjectDependenciesProvider=Xe,v.MapBoxConfig=er,v.MaskTextField=Ze,v.QueryClientConfigProvider=rr,v.RequireAuth=qe,v.SentryConfig=Qe,v.dateAdapter=fe,v.distanceAdapter=de,v.getOrvalConfig=fr,v.useAdapter=ir,v.useAuth=ar,v.useInfiniteDataGrid=nr,v.useResponseError=tr,Object.defineProperty(v,Symbol.toStringTag,{value:"Module"})});
27
+ */var fe;function Je(){if(fe)return U;fe=1;var t=y,a=Symbol.for("react.element"),i=Symbol.for("react.fragment"),u=Object.prototype.hasOwnProperty,g=t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,C={key:!0,ref:!0,__self:!0,__source:!0};function o(d,c,h){var _,S={},O=null,A=null;h!==void 0&&(O=""+h),c.key!==void 0&&(O=""+c.key),c.ref!==void 0&&(A=c.ref);for(_ in c)u.call(c,_)&&!C.hasOwnProperty(_)&&(S[_]=c[_]);if(d&&d.defaultProps)for(_ in c=d.defaultProps,c)S[_]===void 0&&(S[_]=c[_]);return{$$typeof:a,type:d,key:O,ref:A,props:S,_owner:g.current}}return U.Fragment=i,U.jsx=o,U.jsxs=o,U}process.env.NODE_ENV==="production"?Q.exports=Je():Q.exports=Ge();var D=Q.exports;const qe=({Fallback:t,loginPath:a="/login",localStorageKey:i="user",redirect401Path:u="/login",isLogged:g})=>{var S,O,A,N;const[C,o]=y.useState(null),d=k.useLocation(),c=y.useRef(!1),h=typeof g=="function"?g():!!g,_=typeof h=="boolean"?h:h==null?void 0:h.isLogged;return y.useLayoutEffect(()=>{c.current||(c.current=!0,P==null||P.interceptors.response.use(E=>E,async E=>{var T;return typeof E=="object"&&E&&"response"in E&&E.response&&typeof E.response=="object"&&"status"in E.response&&E.response&&typeof E.response=="object"&&"status"in E.response&&((T=E==null?void 0:E.response)==null?void 0:T.status)===401&&(P.defaults.headers.common.Authorization=null,localStorage.removeItem(i),o(u)),Promise.reject(E)}))},[i,u]),_&&!C?D.jsx(y.Suspense,{fallback:t,children:(O=(S=d.state)==null?void 0:S.from)!=null&&O.state&&((N=(A=d.state)==null?void 0:A.from)==null?void 0:N.pathname)===a?D.jsx(k.Navigate,{to:d.state.from.state.from.pathname+d.state.from.state.from.search,replace:!0}):D.jsx(k.Outlet,{})}):D.jsx(k.Navigate,{to:a,state:{from:d},replace:!0})},Xe=()=>{const{pathname:t}=k.useLocation(),{sendEvent:a}=Ve.useGoogleTagManager();return y.useEffect(()=>{a({event:"pageView",pathname:t})},[t,a]),D.jsx(k.Outlet,{})},$=y.createContext({apiURL:void 0,children:void 0}),He=({children:t,apiURL:a})=>{const i=y.useMemo(()=>({apiURL:a}),[a]);return D.jsx($.Provider,{value:i,children:t})},Ke=({tokenTypeKey:t="tokenType",userLocalStorageKey:a="user",tokenKey:i="accessToken",postContentType:u="application/json",...g})=>{const{apiURL:C=g.baseURL}=y.useContext($);if(!P.defaults)return null;const o=localStorage.getItem(a),d=o?JSON.parse(o):null,c=d!=null&&d[t]?d[t]:null,h=d!=null&&d[i]?d[i]:null,_=o?`${c} ${h}`:null;return P.defaults.baseURL=C,P.defaults.headers.post["Content-Type"]=u,_&&(P.defaults.headers.common.Authorization=_),null},Qe=({debug:t,resources:a})=>(x!=null&&x.isInitialized||(x.use(Ye).use(Ue.initReactI18next).init({debug:t,fallbackLng:"en",interpolation:{escapeValue:!1},load:"languageOnly",react:{bindI18n:!1,useSuspense:!0},resources:a,returnNull:!1}).then(()=>{document.documentElement.lang!==x.resolvedLanguage&&x.resolvedLanguage&&document.documentElement.setAttribute("lang",x.resolvedLanguage)}),x.on("languageChanged",i=>{document.documentElement.setAttribute("lang",i)})),null),Ze=({dsn:t,integrations:a,tracesSampleRate:i,replaysSessionSampleRate:u,replaysOnErrorSampleRate:g,tracePropagationTargets:C,ignoreErrors:o,debug:d,environment:c})=>(K.isInitialized()||(d||process.env.NODE_ENV==="prod"||process.env.NODE_ENV==="production")&&K.init({debug:d,dsn:t,environment:c||"production",ignoreErrors:[...o||[],/dynamically imported module/],integrations:[K.reactRouterV6BrowserTracingIntegration({createRoutesFromChildren:k.createRoutesFromChildren,matchRoutes:k.matchRoutes,useEffect:y.useEffect,useLocation:k.useLocation,useNavigationType:k.useNavigationType}),...a||[]],replaysOnErrorSampleRate:g||1,replaysSessionSampleRate:u||.1,tracePropagationTargets:C,tracesSampleRate:i||1}),null),er=({IMaskMixin:t,...a})=>{const i=y.useMemo(()=>t(({TextField:u,...g})=>D.jsx(u,{...g})),[t]);return D.jsx(i,{...a})},rr=({accessToken:t})=>(ue&&t&&(ue.accessToken=t),null),tr=({language:t=window.navigator.language})=>(y.useEffect(()=>{import(`dayjs/locale/${t}`).then(()=>{se.locale(t)}).catch(()=>{Promise.resolve().then(()=>gr)})},[t]),null),nr=({children:t,defaultQueriesOptions:a,defaultMutationsOptions:i})=>{const u=new ce.QueryClient({defaultOptions:{mutations:{...i},queries:{getNextPageParam:(g,C,o)=>g.length+(o||0),refetchOnWindowFocus:!1,retry:3,...a}}});return D.jsx(ce.QueryClientProvider,{client:u,children:t})},ar=t=>{const{unknownErrorTranslationKey:a="error.unknownError"}=t||{},i=x.t(a),u=y.useCallback(C=>{var d,c,h,_,S,O,A,N,E;const{response:o}=C||{};return o!=null&&o.reason?String(o.reason):(d=o==null?void 0:o.data)!=null&&d.reason?String(o.data.reason):(c=o==null?void 0:o.data)!=null&&c.message?String(o.data.message):(_=(h=o==null?void 0:o.data)==null?void 0:h.detail)!=null&&_.length&&Array.isArray((S=o==null?void 0:o.data)==null?void 0:S.detail)&&((A=(O=o==null?void 0:o.data)==null?void 0:O.detail[0])!=null&&A.msg)&&typeof((E=(N=o==null?void 0:o.data)==null?void 0:N.detail[0])==null?void 0:E.msg)=="string"?String(o.data.detail[0].msg):i},[i]);return{getErrorCode:y.useCallback(C=>{var d,c,h;const{response:o}=C||{};return o!=null&&o.error_code?String(o==null?void 0:o.error_code):(d=o==null?void 0:o.data)!=null&&d.error_code?String((c=o==null?void 0:o.data)==null?void 0:c.error_code):o!=null&&o.error_code?String(o==null?void 0:o.error_code):(h=o==null?void 0:o.data)!=null&&h.error_code?String(o.data.error_code):"unknown_error_code"},[]),printError:u}},or=({data:t,fetchNextPage:a,isFetchingNextPage:i,isInitialLoading:u,isLoading:g,enabled:C=!0})=>{const o=y.useCallback(async c=>{i||!C||await a({pageParam:(c==null?void 0:c.pageParam)||c.visibleRowsCount})},[C,a,i]),d=y.useMemo(()=>{if(t)return t.pages.reduce((c,h)=>[...c,...h],[])},[t]);return{fetchNextPageOnRowsScrollEnd:o,isLoading:i||g,loadingVariant:u?"skeleton":"linear",rows:d}},ir=()=>({clearAuthenticationToken:()=>{P.defaults.headers.common.Authorization=null},setAuthenticationToken:({tokenType:i,accessToken:u})=>{P.defaults.headers.common.Authorization=`${i} ${u}`}}),de=(t,a="ddd D MMM YY")=>se(t).format(a),ve=(t,a="km")=>{const i=Number(t);return Number.isNaN(i)?`0 ${a}`:`${i.toFixed(2)} ${a}`},ur=t=>{const a=t&&typeof t=="object"&&"pathname"in t&&t.pathname?t.pathname:t;return typeof a=="string"?a!=null&&a.startsWith("/")?a!=null&&a.startsWith("/files")?a:`/files${a}`:a!=null&&a.startsWith("files")?`/${a}`:a!=null&&a.startsWith("files")?`/${a}`:`/files/${a}`:a},pe=(t,a)=>{if(!t)return"";const i=ur(t),u=typeof t=="object"&&"pathname"in t?`${t.origin}${i}`:t;return typeof a=="number"?`${u.replace("/files",`/thumbs/${a}`)}`:u},sr=()=>{const{apiURL:t}=y.useContext($);return{dateAdapter:de,distanceAdapter:ve,filePathAdapter:(i,u)=>pe(t&&typeof i=="string"?{origin:t,pathname:i}:i,u)}},cr=t=>t.charAt(0).toUpperCase()+t.slice(1).toLowerCase(),lr=t=>{const u=t.split("/").filter(g=>g.length>0).map(g=>g.replace(/\${([^}]*)}/g,"$1").split(/[_-]/).map(c=>c.charAt(0).toUpperCase()+c.slice(1)).join("")).join("");return u.charAt(0).toLowerCase()+u.slice(1)},fr=(t,a,i)=>{const u=lr(a),g=cr(i);return`${u}${g}`},dr=t=>{if(t)return(t==null?void 0:t.reduce((a,i)=>(a[i]={query:{useInfinite:!0,useInfiniteQueryParam:"offset",useQuery:!0}},a),{}))||{}},vr=t=>{const{input:a="./openapi.json",operationsToGenerateInfiniteQueryHook:i=void 0}=t||{};return{api:{hooks:{afterAllFilesWrite:"prettier src/api/ --write"},input:a,output:{client:"react-query",mode:"tags-split",override:{header:u=>["Generated by orval 🍺",...u.title?[u.title]:[],...u.description?[u.description]:[]],mutator:{name:"axiosCustomInstance",path:`${__dirname}/config/orval/mutator/axiosCustomInstance.ts`},operationName:fr,...(i==null?void 0:i.length)&&{operations:dr(i)},query:{useQuery:!0}},schemas:"src/api/model",target:"src/api/services/api.ts"}}}};var pr={exports:{}};(function(t,a){(function(i,u){t.exports=u()})($e,function(){return{name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(i){var u=["th","st","nd","rd"],g=i%100;return"["+i+(u[(g-20)%10]||u[g]||u[0])+"]"}}})})(pr);const gr=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"}));f.AxiosConfig=Ke,f.DaysJSConfig=tr,f.GTMSendPageView=Xe,f.I18nConfig=Qe,f.InjectDependenciesContext=$,f.InjectDependenciesProvider=He,f.MapBoxConfig=rr,f.MaskTextField=er,f.QueryClientConfigProvider=nr,f.RequireAuth=qe,f.SentryConfig=Ze,f.dateAdapter=de,f.distanceAdapter=ve,f.getOrvalConfig=vr,f.useAdapter=sr,f.useAuth=ir,f.useInfiniteDataGrid=or,f.useResponseError=ar,Object.defineProperty(f,Symbol.toStringTag,{value:"Module"})});
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tracktor/shared-module",
3
- "version": "1.0.0-beta.5",
3
+ "version": "1.0.0-beta.6",
4
4
  "type": "module",
5
5
  "license": "UNLICENSED",
6
6
  "types": "./dist/main.d.ts",