@tracktor/shared-module 0.18.2 → 0.19.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (31) hide show
  1. package/CHANGELOG.md +5 -2
  2. package/dist/{src/context → context}/InjectDependenciesProvider.d.ts +6 -1
  3. package/dist/hooks/useAdapter/index.d.ts +3 -0
  4. package/dist/hooks/useAdapter/useAdapter.d.ts +8 -0
  5. package/dist/{src/main.d.ts → main.d.ts} +2 -0
  6. package/dist/main.js +446 -454
  7. package/dist/main.umd.cjs +10 -10
  8. package/dist/utils/adapter/filePathAdapter.d.ts +10 -0
  9. package/dist/utils/adapter/index.d.ts +7 -0
  10. package/package.json +1 -1
  11. package/dist/src/utils/adapter/filePathAdapter.d.ts +0 -7
  12. package/dist/src/utils/adapter/index.d.ts +0 -4
  13. /package/dist/{src/components → components}/Inputs/MaskTextField.d.ts +0 -0
  14. /package/dist/{src/components → components}/Utils/AxiosConfig.d.ts +0 -0
  15. /package/dist/{src/components → components}/Utils/GTMSendPageView.d.ts +0 -0
  16. /package/dist/{src/components → components}/Utils/I18nConfig.d.ts +0 -0
  17. /package/dist/{src/components → components}/Utils/MapBoxConfig.d.ts +0 -0
  18. /package/dist/{src/components → components}/Utils/RequireAuth.d.ts +0 -0
  19. /package/dist/{src/components → components}/Utils/SentryConfig.d.ts +0 -0
  20. /package/dist/{src/config → config}/orval/index.d.ts +0 -0
  21. /package/dist/{src/config → config}/orval/mutator/axiosCustomInstance.d.ts +0 -0
  22. /package/dist/{src/config → config}/orval/orval.d.ts +0 -0
  23. /package/dist/{src/config → config}/orval/orval.test.d.ts +0 -0
  24. /package/dist/{src/context → context}/QueryClientConfigProvider.d.ts +0 -0
  25. /package/dist/{src/hooks → hooks}/useAuth/index.d.ts +0 -0
  26. /package/dist/{src/hooks → hooks}/useAuth/useAuth.d.ts +0 -0
  27. /package/dist/{src/hooks → hooks}/useInfiniteDataGrid/index.d.ts +0 -0
  28. /package/dist/{src/hooks → hooks}/useInfiniteDataGrid/useInfiniteDataGrid.d.ts +0 -0
  29. /package/dist/{src/hooks → hooks}/useResponseError/index.d.ts +0 -0
  30. /package/dist/{src/hooks → hooks}/useResponseError/useResponseError.d.ts +0 -0
  31. /package/dist/{src/hooks → hooks}/useResponseError/useResponseError.test.d.ts +0 -0
package/dist/main.js CHANGED
@@ -1,4 +1,4 @@
1
- import Ne, { createContext as gr, useMemo as se, useContext as ce, useState as mr, useRef as hr, useLayoutEffect as Er, Suspense as yr, useEffect as Rr, useCallback as U } from "react";
1
+ import Ne, { createContext as pr, useMemo as se, useContext as K, useState as gr, useRef as mr, useLayoutEffect as hr, Suspense as Er, useEffect as yr, useCallback as Y } from "react";
2
2
  var ue = { exports: {} }, M = {};
3
3
  /**
4
4
  * @license React
@@ -9,91 +9,91 @@ var ue = { exports: {} }, M = {};
9
9
  * This source code is licensed under the MIT license found in the
10
10
  * LICENSE file in the root directory of this source tree.
11
11
  */
12
- var Ie;
13
- function _r() {
14
- return Ie || (Ie = 1, process.env.NODE_ENV !== "production" && function() {
15
- var a = Ne, i = Symbol.for("react.element"), o = Symbol.for("react.portal"), u = Symbol.for("react.fragment"), c = Symbol.for("react.strict_mode"), v = Symbol.for("react.profiler"), m = Symbol.for("react.provider"), t = Symbol.for("react.context"), l = Symbol.for("react.forward_ref"), E = Symbol.for("react.suspense"), h = Symbol.for("react.suspense_list"), C = Symbol.for("react.memo"), O = Symbol.for("react.lazy"), T = Symbol.for("react.offscreen"), k = Symbol.iterator, $ = "@@iterator";
16
- function D(e) {
12
+ var De;
13
+ function Rr() {
14
+ return De || (De = 1, process.env.NODE_ENV !== "production" && function() {
15
+ var t = Ne, u = Symbol.for("react.element"), i = Symbol.for("react.portal"), o = Symbol.for("react.fragment"), s = Symbol.for("react.strict_mode"), f = Symbol.for("react.profiler"), h = Symbol.for("react.provider"), n = Symbol.for("react.context"), l = Symbol.for("react.forward_ref"), m = Symbol.for("react.suspense"), E = Symbol.for("react.suspense_list"), C = Symbol.for("react.memo"), O = Symbol.for("react.lazy"), T = Symbol.for("react.offscreen"), k = Symbol.iterator, $ = "@@iterator";
16
+ function F(e) {
17
17
  if (e === null || typeof e != "object")
18
18
  return null;
19
19
  var r = k && e[k] || e[$];
20
20
  return typeof r == "function" ? r : null;
21
21
  }
22
- var j = a.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
23
- function _(e) {
22
+ var j = t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
23
+ function b(e) {
24
24
  {
25
- for (var r = arguments.length, n = new Array(r > 1 ? r - 1 : 0), s = 1; s < r; s++)
26
- n[s - 1] = arguments[s];
27
- b("error", e, n);
25
+ for (var r = arguments.length, a = new Array(r > 1 ? r - 1 : 0), c = 1; c < r; c++)
26
+ a[c - 1] = arguments[c];
27
+ _("error", e, a);
28
28
  }
29
29
  }
30
- function b(e, r, n) {
30
+ function _(e, r, a) {
31
31
  {
32
- var s = j.ReactDebugCurrentFrame, p = s.getStackAddendum();
33
- p !== "" && (r += "%s", n = n.concat([p]));
34
- var g = n.map(function(d) {
35
- return String(d);
32
+ var c = j.ReactDebugCurrentFrame, p = c.getStackAddendum();
33
+ p !== "" && (r += "%s", a = a.concat([p]));
34
+ var g = a.map(function(v) {
35
+ return String(v);
36
36
  });
37
37
  g.unshift("Warning: " + r), Function.prototype.apply.call(console[e], console, g);
38
38
  }
39
39
  }
40
- var le = !1, fe = !1, q = !1, Ve = !1, Me = !1, de;
41
- de = Symbol.for("react.module.reference");
42
- function Ye(e) {
43
- return !!(typeof e == "string" || typeof e == "function" || e === u || e === v || Me || e === c || e === E || e === h || Ve || e === T || le || fe || q || typeof e == "object" && e !== null && (e.$$typeof === O || e.$$typeof === C || e.$$typeof === m || e.$$typeof === t || e.$$typeof === l || // This needs to include all possible module reference object
40
+ var ce = !1, le = !1, U = !1, We = !1, Me = !1, fe;
41
+ fe = Symbol.for("react.module.reference");
42
+ function Ve(e) {
43
+ return !!(typeof e == "string" || typeof e == "function" || e === o || e === f || Me || e === s || e === m || e === E || We || e === T || ce || le || U || typeof e == "object" && e !== null && (e.$$typeof === O || e.$$typeof === C || e.$$typeof === h || e.$$typeof === n || e.$$typeof === l || // This needs to include all possible module reference object
44
44
  // types supported by any Flight configuration anywhere since
45
45
  // we don't know which Flight build this will end up being used
46
46
  // with.
47
- e.$$typeof === de || e.getModuleId !== void 0));
47
+ e.$$typeof === fe || e.getModuleId !== void 0));
48
48
  }
49
- function Ue(e, r, n) {
50
- var s = e.displayName;
51
- if (s)
52
- return s;
49
+ function Ye(e, r, a) {
50
+ var c = e.displayName;
51
+ if (c)
52
+ return c;
53
53
  var p = r.displayName || r.name || "";
54
- return p !== "" ? n + "(" + p + ")" : n;
54
+ return p !== "" ? a + "(" + p + ")" : a;
55
55
  }
56
- function ve(e) {
56
+ function de(e) {
57
57
  return e.displayName || "Context";
58
58
  }
59
59
  function P(e) {
60
60
  if (e == null)
61
61
  return null;
62
- if (typeof e.tag == "number" && _("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof e == "function")
62
+ if (typeof e.tag == "number" && b("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof e == "function")
63
63
  return e.displayName || e.name || null;
64
64
  if (typeof e == "string")
65
65
  return e;
66
66
  switch (e) {
67
- case u:
68
- return "Fragment";
69
67
  case o:
68
+ return "Fragment";
69
+ case i:
70
70
  return "Portal";
71
- case v:
71
+ case f:
72
72
  return "Profiler";
73
- case c:
73
+ case s:
74
74
  return "StrictMode";
75
- case E:
75
+ case m:
76
76
  return "Suspense";
77
- case h:
77
+ case E:
78
78
  return "SuspenseList";
79
79
  }
80
80
  if (typeof e == "object")
81
81
  switch (e.$$typeof) {
82
- case t:
82
+ case n:
83
83
  var r = e;
84
- return ve(r) + ".Consumer";
85
- case m:
86
- var n = e;
87
- return ve(n._context) + ".Provider";
84
+ return de(r) + ".Consumer";
85
+ case h:
86
+ var a = e;
87
+ return de(a._context) + ".Provider";
88
88
  case l:
89
- return Ue(e, e.render, "ForwardRef");
89
+ return Ye(e, e.render, "ForwardRef");
90
90
  case C:
91
- var s = e.displayName || null;
92
- return s !== null ? s : P(e.type) || "Memo";
91
+ var c = e.displayName || null;
92
+ return c !== null ? c : P(e.type) || "Memo";
93
93
  case O: {
94
- var p = e, g = p._payload, d = p._init;
94
+ var p = e, g = p._payload, v = p._init;
95
95
  try {
96
- return P(d(g));
96
+ return P(v(g));
97
97
  } catch {
98
98
  return null;
99
99
  }
@@ -101,18 +101,18 @@ function _r() {
101
101
  }
102
102
  return null;
103
103
  }
104
- var F = Object.assign, N = 0, pe, ge, me, he, Ee, ye, Re;
105
- function _e() {
104
+ var D = Object.assign, N = 0, ve, pe, ge, me, he, Ee, ye;
105
+ function Re() {
106
106
  }
107
- _e.__reactDisabledLog = !0;
107
+ Re.__reactDisabledLog = !0;
108
108
  function qe() {
109
109
  {
110
110
  if (N === 0) {
111
- pe = console.log, ge = console.info, me = console.warn, he = console.error, Ee = console.group, ye = console.groupCollapsed, Re = console.groupEnd;
111
+ ve = console.log, pe = console.info, ge = console.warn, me = console.error, he = console.group, Ee = console.groupCollapsed, ye = console.groupEnd;
112
112
  var e = {
113
113
  configurable: !0,
114
114
  enumerable: !0,
115
- value: _e,
115
+ value: Re,
116
116
  writable: !0
117
117
  };
118
118
  Object.defineProperties(console, {
@@ -128,7 +128,7 @@ function _r() {
128
128
  N++;
129
129
  }
130
130
  }
131
- function ze() {
131
+ function Ue() {
132
132
  {
133
133
  if (N--, N === 0) {
134
134
  var e = {
@@ -137,41 +137,41 @@ function _r() {
137
137
  writable: !0
138
138
  };
139
139
  Object.defineProperties(console, {
140
- log: F({}, e, {
140
+ log: D({}, e, {
141
+ value: ve
142
+ }),
143
+ info: D({}, e, {
141
144
  value: pe
142
145
  }),
143
- info: F({}, e, {
146
+ warn: D({}, e, {
144
147
  value: ge
145
148
  }),
146
- warn: F({}, e, {
149
+ error: D({}, e, {
147
150
  value: me
148
151
  }),
149
- error: F({}, e, {
152
+ group: D({}, e, {
150
153
  value: he
151
154
  }),
152
- group: F({}, e, {
155
+ groupCollapsed: D({}, e, {
153
156
  value: Ee
154
157
  }),
155
- groupCollapsed: F({}, e, {
158
+ groupEnd: D({}, e, {
156
159
  value: ye
157
- }),
158
- groupEnd: F({}, e, {
159
- value: Re
160
160
  })
161
161
  });
162
162
  }
163
- N < 0 && _("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
163
+ N < 0 && b("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
164
164
  }
165
165
  }
166
166
  var Z = j.ReactCurrentDispatcher, Q;
167
- function z(e, r, n) {
167
+ function z(e, r, a) {
168
168
  {
169
169
  if (Q === void 0)
170
170
  try {
171
171
  throw Error();
172
172
  } catch (p) {
173
- var s = p.stack.trim().match(/\n( *(at )?)/);
174
- Q = s && s[1] || "";
173
+ var c = p.stack.trim().match(/\n( *(at )?)/);
174
+ Q = c && c[1] || "";
175
175
  }
176
176
  return `
177
177
  ` + Q + e;
@@ -179,18 +179,18 @@ function _r() {
179
179
  }
180
180
  var ee = !1, B;
181
181
  {
182
- var Be = typeof WeakMap == "function" ? WeakMap : Map;
183
- B = new Be();
182
+ var ze = typeof WeakMap == "function" ? WeakMap : Map;
183
+ B = new ze();
184
184
  }
185
185
  function be(e, r) {
186
186
  if (!e || ee)
187
187
  return "";
188
188
  {
189
- var n = B.get(e);
190
- if (n !== void 0)
191
- return n;
189
+ var a = B.get(e);
190
+ if (a !== void 0)
191
+ return a;
192
192
  }
193
- var s;
193
+ var c;
194
194
  ee = !0;
195
195
  var p = Error.prepareStackTrace;
196
196
  Error.prepareStackTrace = void 0;
@@ -198,49 +198,49 @@ function _r() {
198
198
  g = Z.current, Z.current = null, qe();
199
199
  try {
200
200
  if (r) {
201
- var d = function() {
201
+ var v = function() {
202
202
  throw Error();
203
203
  };
204
- if (Object.defineProperty(d.prototype, "props", {
204
+ if (Object.defineProperty(v.prototype, "props", {
205
205
  set: function() {
206
206
  throw Error();
207
207
  }
208
208
  }), typeof Reflect == "object" && Reflect.construct) {
209
209
  try {
210
- Reflect.construct(d, []);
211
- } catch (x) {
212
- s = x;
210
+ Reflect.construct(v, []);
211
+ } catch (A) {
212
+ c = A;
213
213
  }
214
- Reflect.construct(e, [], d);
214
+ Reflect.construct(e, [], v);
215
215
  } else {
216
216
  try {
217
- d.call();
218
- } catch (x) {
219
- s = x;
217
+ v.call();
218
+ } catch (A) {
219
+ c = A;
220
220
  }
221
- e.call(d.prototype);
221
+ e.call(v.prototype);
222
222
  }
223
223
  } else {
224
224
  try {
225
225
  throw Error();
226
- } catch (x) {
227
- s = x;
226
+ } catch (A) {
227
+ c = A;
228
228
  }
229
229
  e();
230
230
  }
231
- } catch (x) {
232
- if (x && s && typeof x.stack == "string") {
233
- for (var f = x.stack.split(`
234
- `), w = s.stack.split(`
235
- `), y = f.length - 1, R = w.length - 1; y >= 1 && R >= 0 && f[y] !== w[R]; )
231
+ } catch (A) {
232
+ if (A && c && typeof A.stack == "string") {
233
+ for (var d = A.stack.split(`
234
+ `), w = c.stack.split(`
235
+ `), y = d.length - 1, R = w.length - 1; y >= 1 && R >= 0 && d[y] !== w[R]; )
236
236
  R--;
237
237
  for (; y >= 1 && R >= 0; y--, R--)
238
- if (f[y] !== w[R]) {
238
+ if (d[y] !== w[R]) {
239
239
  if (y !== 1 || R !== 1)
240
240
  do
241
- if (y--, R--, R < 0 || f[y] !== w[R]) {
241
+ if (y--, R--, R < 0 || d[y] !== w[R]) {
242
242
  var S = `
243
- ` + f[y].replace(" at new ", " at ");
243
+ ` + d[y].replace(" at new ", " at ");
244
244
  return e.displayName && S.includes("<anonymous>") && (S = S.replace("<anonymous>", e.displayName)), typeof e == "function" && B.set(e, S), S;
245
245
  }
246
246
  while (y >= 1 && R >= 0);
@@ -248,106 +248,106 @@ function _r() {
248
248
  }
249
249
  }
250
250
  } finally {
251
- ee = !1, Z.current = g, ze(), Error.prepareStackTrace = p;
251
+ ee = !1, Z.current = g, Ue(), Error.prepareStackTrace = p;
252
252
  }
253
- var L = e ? e.displayName || e.name : "", Fe = L ? z(L) : "";
253
+ var I = e ? e.displayName || e.name : "", Fe = I ? z(I) : "";
254
254
  return typeof e == "function" && B.set(e, Fe), Fe;
255
255
  }
256
- function Ge(e, r, n) {
256
+ function Be(e, r, a) {
257
257
  return be(e, !1);
258
258
  }
259
- function Je(e) {
259
+ function Ge(e) {
260
260
  var r = e.prototype;
261
261
  return !!(r && r.isReactComponent);
262
262
  }
263
- function G(e, r, n) {
263
+ function G(e, r, a) {
264
264
  if (e == null)
265
265
  return "";
266
266
  if (typeof e == "function")
267
- return be(e, Je(e));
267
+ return be(e, Ge(e));
268
268
  if (typeof e == "string")
269
269
  return z(e);
270
270
  switch (e) {
271
- case E:
271
+ case m:
272
272
  return z("Suspense");
273
- case h:
273
+ case E:
274
274
  return z("SuspenseList");
275
275
  }
276
276
  if (typeof e == "object")
277
277
  switch (e.$$typeof) {
278
278
  case l:
279
- return Ge(e.render);
279
+ return Be(e.render);
280
280
  case C:
281
- return G(e.type, r, n);
281
+ return G(e.type, r, a);
282
282
  case O: {
283
- var s = e, p = s._payload, g = s._init;
283
+ var c = e, p = c._payload, g = c._init;
284
284
  try {
285
- return G(g(p), r, n);
285
+ return G(g(p), r, a);
286
286
  } catch {
287
287
  }
288
288
  }
289
289
  }
290
290
  return "";
291
291
  }
292
- var J = Object.prototype.hasOwnProperty, we = {}, Ce = j.ReactDebugCurrentFrame;
292
+ var J = Object.prototype.hasOwnProperty, _e = {}, we = j.ReactDebugCurrentFrame;
293
293
  function X(e) {
294
294
  if (e) {
295
- var r = e._owner, n = G(e.type, e._source, r ? r.type : null);
296
- Ce.setExtraStackFrame(n);
295
+ var r = e._owner, a = G(e.type, e._source, r ? r.type : null);
296
+ we.setExtraStackFrame(a);
297
297
  } else
298
- Ce.setExtraStackFrame(null);
298
+ we.setExtraStackFrame(null);
299
299
  }
300
- function Xe(e, r, n, s, p) {
300
+ function Je(e, r, a, c, p) {
301
301
  {
302
302
  var g = Function.call.bind(J);
303
- for (var d in e)
304
- if (g(e, d)) {
305
- var f = void 0;
303
+ for (var v in e)
304
+ if (g(e, v)) {
305
+ var d = void 0;
306
306
  try {
307
- if (typeof e[d] != "function") {
308
- var w = Error((s || "React class") + ": " + n + " 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`.");
307
+ if (typeof e[v] != "function") {
308
+ var w = Error((c || "React class") + ": " + a + " 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`.");
309
309
  throw w.name = "Invariant Violation", w;
310
310
  }
311
- f = e[d](r, d, s, n, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
311
+ d = e[v](r, v, c, a, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
312
312
  } catch (y) {
313
- f = y;
313
+ d = y;
314
314
  }
315
- f && !(f instanceof Error) && (X(p), _("%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, d, typeof f), X(null)), f instanceof Error && !(f.message in we) && (we[f.message] = !0, X(p), _("Failed %s type: %s", n, f.message), X(null));
315
+ d && !(d instanceof Error) && (X(p), b("%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).", c || "React class", a, v, typeof d), X(null)), d instanceof Error && !(d.message in _e) && (_e[d.message] = !0, X(p), b("Failed %s type: %s", a, d.message), X(null));
316
316
  }
317
317
  }
318
318
  }
319
- var He = Array.isArray;
319
+ var Xe = Array.isArray;
320
320
  function re(e) {
321
- return He(e);
321
+ return Xe(e);
322
322
  }
323
- function Ke(e) {
323
+ function He(e) {
324
324
  {
325
- var r = typeof Symbol == "function" && Symbol.toStringTag, n = r && e[Symbol.toStringTag] || e.constructor.name || "Object";
326
- return n;
325
+ var r = typeof Symbol == "function" && Symbol.toStringTag, a = r && e[Symbol.toStringTag] || e.constructor.name || "Object";
326
+ return a;
327
327
  }
328
328
  }
329
- function Ze(e) {
329
+ function Ke(e) {
330
330
  try {
331
- return Te(e), !1;
331
+ return Ce(e), !1;
332
332
  } catch {
333
333
  return !0;
334
334
  }
335
335
  }
336
- function Te(e) {
336
+ function Ce(e) {
337
337
  return "" + e;
338
338
  }
339
- function Oe(e) {
340
- if (Ze(e))
341
- return _("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", Ke(e)), Te(e);
339
+ function Te(e) {
340
+ if (Ke(e))
341
+ return b("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", He(e)), Ce(e);
342
342
  }
343
- var V = j.ReactCurrentOwner, Qe = {
343
+ var W = j.ReactCurrentOwner, Ze = {
344
344
  key: !0,
345
345
  ref: !0,
346
346
  __self: !0,
347
347
  __source: !0
348
- }, Se, je, te;
348
+ }, Oe, Se, te;
349
349
  te = {};
350
- function er(e) {
350
+ function Qe(e) {
351
351
  if (J.call(e, "ref")) {
352
352
  var r = Object.getOwnPropertyDescriptor(e, "ref").get;
353
353
  if (r && r.isReactWarning)
@@ -355,7 +355,7 @@ function _r() {
355
355
  }
356
356
  return e.ref !== void 0;
357
357
  }
358
- function rr(e) {
358
+ function er(e) {
359
359
  if (J.call(e, "key")) {
360
360
  var r = Object.getOwnPropertyDescriptor(e, "key").get;
361
361
  if (r && r.isReactWarning)
@@ -363,95 +363,95 @@ function _r() {
363
363
  }
364
364
  return e.key !== void 0;
365
365
  }
366
- function tr(e, r) {
367
- if (typeof e.ref == "string" && V.current && r && V.current.stateNode !== r) {
368
- var n = P(V.current.type);
369
- te[n] || (_('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', P(V.current.type), e.ref), te[n] = !0);
366
+ function rr(e, r) {
367
+ if (typeof e.ref == "string" && W.current && r && W.current.stateNode !== r) {
368
+ var a = P(W.current.type);
369
+ te[a] || (b('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', P(W.current.type), e.ref), te[a] = !0);
370
370
  }
371
371
  }
372
- function nr(e, r) {
372
+ function tr(e, r) {
373
373
  {
374
- var n = function() {
375
- 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));
374
+ var a = function() {
375
+ Oe || (Oe = !0, b("%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));
376
376
  };
377
- n.isReactWarning = !0, Object.defineProperty(e, "key", {
378
- get: n,
377
+ a.isReactWarning = !0, Object.defineProperty(e, "key", {
378
+ get: a,
379
379
  configurable: !0
380
380
  });
381
381
  }
382
382
  }
383
- function ar(e, r) {
383
+ function nr(e, r) {
384
384
  {
385
- var n = function() {
386
- je || (je = !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));
385
+ var a = function() {
386
+ Se || (Se = !0, b("%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));
387
387
  };
388
- n.isReactWarning = !0, Object.defineProperty(e, "ref", {
389
- get: n,
388
+ a.isReactWarning = !0, Object.defineProperty(e, "ref", {
389
+ get: a,
390
390
  configurable: !0
391
391
  });
392
392
  }
393
393
  }
394
- var or = function(e, r, n, s, p, g, d) {
395
- var f = {
394
+ var ar = function(e, r, a, c, p, g, v) {
395
+ var d = {
396
396
  // This tag allows us to uniquely identify this as a React Element
397
- $$typeof: i,
397
+ $$typeof: u,
398
398
  // Built-in properties that belong on the element
399
399
  type: e,
400
400
  key: r,
401
- ref: n,
402
- props: d,
401
+ ref: a,
402
+ props: v,
403
403
  // Record the component responsible for creating this element.
404
404
  _owner: g
405
405
  };
406
- return f._store = {}, Object.defineProperty(f._store, "validated", {
406
+ return d._store = {}, Object.defineProperty(d._store, "validated", {
407
407
  configurable: !1,
408
408
  enumerable: !1,
409
409
  writable: !0,
410
410
  value: !1
411
- }), Object.defineProperty(f, "_self", {
411
+ }), Object.defineProperty(d, "_self", {
412
412
  configurable: !1,
413
413
  enumerable: !1,
414
414
  writable: !1,
415
- value: s
416
- }), Object.defineProperty(f, "_source", {
415
+ value: c
416
+ }), Object.defineProperty(d, "_source", {
417
417
  configurable: !1,
418
418
  enumerable: !1,
419
419
  writable: !1,
420
420
  value: p
421
- }), Object.freeze && (Object.freeze(f.props), Object.freeze(f)), f;
421
+ }), Object.freeze && (Object.freeze(d.props), Object.freeze(d)), d;
422
422
  };
423
- function ir(e, r, n, s, p) {
423
+ function or(e, r, a, c, p) {
424
424
  {
425
- var g, d = {}, f = null, w = null;
426
- n !== void 0 && (Oe(n), f = "" + n), rr(r) && (Oe(r.key), f = "" + r.key), er(r) && (w = r.ref, tr(r, p));
425
+ var g, v = {}, d = null, w = null;
426
+ a !== void 0 && (Te(a), d = "" + a), er(r) && (Te(r.key), d = "" + r.key), Qe(r) && (w = r.ref, rr(r, p));
427
427
  for (g in r)
428
- J.call(r, g) && !Qe.hasOwnProperty(g) && (d[g] = r[g]);
428
+ J.call(r, g) && !Ze.hasOwnProperty(g) && (v[g] = r[g]);
429
429
  if (e && e.defaultProps) {
430
430
  var y = e.defaultProps;
431
431
  for (g in y)
432
- d[g] === void 0 && (d[g] = y[g]);
432
+ v[g] === void 0 && (v[g] = y[g]);
433
433
  }
434
- if (f || w) {
434
+ if (d || w) {
435
435
  var R = typeof e == "function" ? e.displayName || e.name || "Unknown" : e;
436
- f && nr(d, R), w && ar(d, R);
436
+ d && tr(v, R), w && nr(v, R);
437
437
  }
438
- return or(e, f, w, p, s, V.current, d);
438
+ return ar(e, d, w, p, c, W.current, v);
439
439
  }
440
440
  }
441
- var ne = j.ReactCurrentOwner, Pe = j.ReactDebugCurrentFrame;
442
- function I(e) {
441
+ var ne = j.ReactCurrentOwner, je = j.ReactDebugCurrentFrame;
442
+ function L(e) {
443
443
  if (e) {
444
- var r = e._owner, n = G(e.type, e._source, r ? r.type : null);
445
- Pe.setExtraStackFrame(n);
444
+ var r = e._owner, a = G(e.type, e._source, r ? r.type : null);
445
+ je.setExtraStackFrame(a);
446
446
  } else
447
- Pe.setExtraStackFrame(null);
447
+ je.setExtraStackFrame(null);
448
448
  }
449
449
  var ae;
450
450
  ae = !1;
451
451
  function oe(e) {
452
- return typeof e == "object" && e !== null && e.$$typeof === i;
452
+ return typeof e == "object" && e !== null && e.$$typeof === u;
453
453
  }
454
- function xe() {
454
+ function Pe() {
455
455
  {
456
456
  if (ne.current) {
457
457
  var e = P(ne.current.type);
@@ -463,140 +463,140 @@ Check the render method of \`` + e + "`.";
463
463
  return "";
464
464
  }
465
465
  }
466
- function ur(e) {
466
+ function ir(e) {
467
467
  {
468
468
  if (e !== void 0) {
469
- var r = e.fileName.replace(/^.*[\\\/]/, ""), n = e.lineNumber;
469
+ var r = e.fileName.replace(/^.*[\\\/]/, ""), a = e.lineNumber;
470
470
  return `
471
471
 
472
- Check your code at ` + r + ":" + n + ".";
472
+ Check your code at ` + r + ":" + a + ".";
473
473
  }
474
474
  return "";
475
475
  }
476
476
  }
477
477
  var Ae = {};
478
- function sr(e) {
478
+ function ur(e) {
479
479
  {
480
- var r = xe();
480
+ var r = Pe();
481
481
  if (!r) {
482
- var n = typeof e == "string" ? e : e.displayName || e.name;
483
- n && (r = `
482
+ var a = typeof e == "string" ? e : e.displayName || e.name;
483
+ a && (r = `
484
484
 
485
- Check the top-level render call using <` + n + ">.");
485
+ Check the top-level render call using <` + a + ">.");
486
486
  }
487
487
  return r;
488
488
  }
489
489
  }
490
- function ke(e, r) {
490
+ function xe(e, r) {
491
491
  {
492
492
  if (!e._store || e._store.validated || e.key != null)
493
493
  return;
494
494
  e._store.validated = !0;
495
- var n = sr(r);
496
- if (Ae[n])
495
+ var a = ur(r);
496
+ if (Ae[a])
497
497
  return;
498
- Ae[n] = !0;
499
- var s = "";
500
- e && e._owner && e._owner !== ne.current && (s = " It was passed a child from " + P(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.', n, s), I(null);
498
+ Ae[a] = !0;
499
+ var c = "";
500
+ e && e._owner && e._owner !== ne.current && (c = " It was passed a child from " + P(e._owner.type) + "."), L(e), b('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', a, c), L(null);
501
501
  }
502
502
  }
503
- function $e(e, r) {
503
+ function ke(e, r) {
504
504
  {
505
505
  if (typeof e != "object")
506
506
  return;
507
507
  if (re(e))
508
- for (var n = 0; n < e.length; n++) {
509
- var s = e[n];
510
- oe(s) && ke(s, r);
508
+ for (var a = 0; a < e.length; a++) {
509
+ var c = e[a];
510
+ oe(c) && xe(c, r);
511
511
  }
512
512
  else if (oe(e))
513
513
  e._store && (e._store.validated = !0);
514
514
  else if (e) {
515
- var p = D(e);
515
+ var p = F(e);
516
516
  if (typeof p == "function" && p !== e.entries)
517
- for (var g = p.call(e), d; !(d = g.next()).done; )
518
- oe(d.value) && ke(d.value, r);
517
+ for (var g = p.call(e), v; !(v = g.next()).done; )
518
+ oe(v.value) && xe(v.value, r);
519
519
  }
520
520
  }
521
521
  }
522
- function cr(e) {
522
+ function sr(e) {
523
523
  {
524
524
  var r = e.type;
525
525
  if (r == null || typeof r == "string")
526
526
  return;
527
- var n;
527
+ var a;
528
528
  if (typeof r == "function")
529
- n = r.propTypes;
529
+ a = r.propTypes;
530
530
  else if (typeof r == "object" && (r.$$typeof === l || // Note: Memo only checks outer props here.
531
531
  // Inner props are checked in the reconciler.
532
532
  r.$$typeof === C))
533
- n = r.propTypes;
533
+ a = r.propTypes;
534
534
  else
535
535
  return;
536
- if (n) {
537
- var s = P(r);
538
- Xe(n, e.props, "prop", s, e);
536
+ if (a) {
537
+ var c = P(r);
538
+ Je(a, e.props, "prop", c, e);
539
539
  } else if (r.PropTypes !== void 0 && !ae) {
540
540
  ae = !0;
541
541
  var p = P(r);
542
- _("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", p || "Unknown");
542
+ b("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", p || "Unknown");
543
543
  }
544
- typeof r.getDefaultProps == "function" && !r.getDefaultProps.isReactClassApproved && _("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
544
+ typeof r.getDefaultProps == "function" && !r.getDefaultProps.isReactClassApproved && b("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
545
545
  }
546
546
  }
547
- function lr(e) {
547
+ function cr(e) {
548
548
  {
549
- for (var r = Object.keys(e.props), n = 0; n < r.length; n++) {
550
- var s = r[n];
551
- if (s !== "children" && s !== "key") {
552
- I(e), _("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", s), I(null);
549
+ for (var r = Object.keys(e.props), a = 0; a < r.length; a++) {
550
+ var c = r[a];
551
+ if (c !== "children" && c !== "key") {
552
+ L(e), b("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", c), L(null);
553
553
  break;
554
554
  }
555
555
  }
556
- e.ref !== null && (I(e), _("Invalid attribute `ref` supplied to `React.Fragment`."), I(null));
556
+ e.ref !== null && (L(e), b("Invalid attribute `ref` supplied to `React.Fragment`."), L(null));
557
557
  }
558
558
  }
559
- function De(e, r, n, s, p, g) {
559
+ function $e(e, r, a, c, p, g) {
560
560
  {
561
- var d = Ye(e);
562
- if (!d) {
563
- var f = "";
564
- (e === void 0 || typeof e == "object" && e !== null && Object.keys(e).length === 0) && (f += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
565
- var w = ur(p);
566
- w ? f += w : f += xe();
561
+ var v = Ve(e);
562
+ if (!v) {
563
+ var d = "";
564
+ (e === void 0 || typeof e == "object" && e !== null && Object.keys(e).length === 0) && (d += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
565
+ var w = ir(p);
566
+ w ? d += w : d += Pe();
567
567
  var y;
568
- e === null ? y = "null" : re(e) ? y = "array" : e !== void 0 && e.$$typeof === i ? (y = "<" + (P(e.type) || "Unknown") + " />", f = " 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, f);
568
+ e === null ? y = "null" : re(e) ? y = "array" : e !== void 0 && e.$$typeof === u ? (y = "<" + (P(e.type) || "Unknown") + " />", d = " Did you accidentally export a JSX literal instead of a component?") : y = typeof e, b("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", y, d);
569
569
  }
570
- var R = ir(e, r, n, p, g);
570
+ var R = or(e, r, a, p, g);
571
571
  if (R == null)
572
572
  return R;
573
- if (d) {
573
+ if (v) {
574
574
  var S = r.children;
575
575
  if (S !== void 0)
576
- if (s)
576
+ if (c)
577
577
  if (re(S)) {
578
- for (var L = 0; L < S.length; L++)
579
- $e(S[L], e);
578
+ for (var I = 0; I < S.length; I++)
579
+ ke(S[I], e);
580
580
  Object.freeze && Object.freeze(S);
581
581
  } else
582
- _("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
582
+ b("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
583
583
  else
584
- $e(S, e);
584
+ ke(S, e);
585
585
  }
586
- return e === u ? lr(R) : cr(R), R;
586
+ return e === o ? cr(R) : sr(R), R;
587
587
  }
588
588
  }
589
- function fr(e, r, n) {
590
- return De(e, r, n, !0);
589
+ function lr(e, r, a) {
590
+ return $e(e, r, a, !0);
591
591
  }
592
- function dr(e, r, n) {
593
- return De(e, r, n, !1);
592
+ function fr(e, r, a) {
593
+ return $e(e, r, a, !1);
594
594
  }
595
- var vr = dr, pr = fr;
596
- M.Fragment = u, M.jsx = vr, M.jsxs = pr;
595
+ var dr = fr, vr = lr;
596
+ M.Fragment = o, M.jsx = dr, M.jsxs = vr;
597
597
  }()), M;
598
598
  }
599
- var Y = {};
599
+ var V = {};
600
600
  /**
601
601
  * @license React
602
602
  * react-jsx-runtime.production.min.js
@@ -609,24 +609,25 @@ var Y = {};
609
609
  var Le;
610
610
  function br() {
611
611
  if (Le)
612
- return Y;
612
+ return V;
613
613
  Le = 1;
614
- var a = Ne, i = Symbol.for("react.element"), o = Symbol.for("react.fragment"), u = Object.prototype.hasOwnProperty, c = a.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, v = { key: !0, ref: !0, __self: !0, __source: !0 };
615
- function m(t, l, E) {
616
- var h, C = {}, O = null, T = null;
617
- E !== void 0 && (O = "" + E), l.key !== void 0 && (O = "" + l.key), l.ref !== void 0 && (T = l.ref);
618
- for (h in l)
619
- u.call(l, h) && !v.hasOwnProperty(h) && (C[h] = l[h]);
620
- if (t && t.defaultProps)
621
- for (h in l = t.defaultProps, l)
622
- C[h] === void 0 && (C[h] = l[h]);
623
- return { $$typeof: i, type: t, key: O, ref: T, props: C, _owner: c.current };
614
+ var t = Ne, u = Symbol.for("react.element"), i = Symbol.for("react.fragment"), o = Object.prototype.hasOwnProperty, s = t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, f = { key: !0, ref: !0, __self: !0, __source: !0 };
615
+ function h(n, l, m) {
616
+ var E, C = {}, O = null, T = null;
617
+ m !== void 0 && (O = "" + m), l.key !== void 0 && (O = "" + l.key), l.ref !== void 0 && (T = l.ref);
618
+ for (E in l)
619
+ o.call(l, E) && !f.hasOwnProperty(E) && (C[E] = l[E]);
620
+ if (n && n.defaultProps)
621
+ for (E in l = n.defaultProps, l)
622
+ C[E] === void 0 && (C[E] = l[E]);
623
+ return { $$typeof: u, type: n, key: O, ref: T, props: C, _owner: s.current };
624
624
  }
625
- return Y.Fragment = o, Y.jsx = m, Y.jsxs = m, Y;
625
+ return V.Fragment = i, V.jsx = h, V.jsxs = h, V;
626
626
  }
627
- process.env.NODE_ENV === "production" ? ue.exports = br() : ue.exports = _r();
628
- var A = ue.exports;
629
- const K = gr({
627
+ process.env.NODE_ENV === "production" ? ue.exports = br() : ue.exports = Rr();
628
+ var x = ue.exports;
629
+ const q = pr({
630
+ apiURL: void 0,
630
631
  axios: void 0,
631
632
  children: void 0,
632
633
  Navigate: void 0,
@@ -634,98 +635,100 @@ const K = gr({
634
635
  translate: void 0,
635
636
  useAuth: void 0,
636
637
  useLocation: void 0
637
- }), Pr = ({
638
- axios: a,
639
- children: i,
640
- translate: o,
641
- useAuth: u,
642
- Outlet: c,
643
- Navigate: v,
644
- useLocation: m,
645
- useGoogleTagManager: t
638
+ }), Sr = ({
639
+ axios: t,
640
+ children: u,
641
+ translate: i,
642
+ useAuth: o,
643
+ Outlet: s,
644
+ Navigate: f,
645
+ useLocation: h,
646
+ useGoogleTagManager: n,
647
+ apiURL: l
646
648
  }) => {
647
- const l = se(
649
+ const m = se(
648
650
  () => ({
649
- axios: a,
650
- Navigate: v,
651
- Outlet: c,
652
- translate: o,
653
- useAuth: u,
654
- useGoogleTagManager: t,
655
- useLocation: m
651
+ apiURL: l,
652
+ axios: t,
653
+ Navigate: f,
654
+ Outlet: s,
655
+ translate: i,
656
+ useAuth: o,
657
+ useGoogleTagManager: n,
658
+ useLocation: h
656
659
  }),
657
- [v, c, a, o, u, t, m]
660
+ [f, s, l, t, i, o, n, h]
658
661
  );
659
- return /* @__PURE__ */ A.jsx(K.Provider, { value: l, children: i });
660
- }, H = (a) => `RequireAuth require « ${a} » dependency. You can provide with InjectDependenciesProvider or directly in props.`, xr = ({
661
- Fallback: a,
662
- loginPath: i = "/login",
663
- localStorageKey: o = "user",
664
- redirect401Path: u = "/login",
665
- ...c
662
+ return /* @__PURE__ */ x.jsx(q.Provider, { value: m, children: u });
663
+ }, H = (t) => `RequireAuth require « ${t} » dependency. You can provide with InjectDependenciesProvider or directly in props.`, jr = ({
664
+ Fallback: t,
665
+ loginPath: u = "/login",
666
+ localStorageKey: i = "user",
667
+ redirect401Path: o = "/login",
668
+ ...s
666
669
  }) => {
667
- var $, D, j, _;
670
+ var $, F, j, b;
668
671
  const {
669
- axios: v = c.axios,
670
- useLocation: m = c.useLocation,
671
- useAuth: t = c.useAuth,
672
- Outlet: l = c.Outlet,
673
- Navigate: E = c.Navigate
674
- } = ce(K);
675
- if (t === void 0)
672
+ axios: f = s.axios,
673
+ useLocation: h = s.useLocation,
674
+ useAuth: n = s.useAuth,
675
+ Outlet: l = s.Outlet,
676
+ Navigate: m = s.Navigate
677
+ } = K(q);
678
+ if (n === void 0)
676
679
  throw new Error(H("useAuth"));
677
- if (m === void 0)
680
+ if (h === void 0)
678
681
  throw new Error(H("useLocation"));
679
682
  if (l === void 0)
680
683
  throw new Error(H("Outlet"));
681
- if (E === void 0)
684
+ if (m === void 0)
682
685
  throw new Error(H("Navigate"));
683
- const [h, C] = mr(null), { isLogged: O } = t(), T = m(), k = hr(!1);
684
- return Er(() => {
685
- k.current || (k.current = !0, v == null || v.interceptors.response.use(
686
- (b) => b,
687
- async (b) => {
688
- var q;
689
- return typeof b == "object" && b && "response" in b && b.response && typeof b.response == "object" && "status" in b.response && b.response && typeof b.response == "object" && "status" in b.response && ((q = b == null ? void 0 : b.response) == null ? void 0 : q.status) === 401 && (v.defaults.headers.common.Authorization = null, localStorage.removeItem(o), C(u)), Promise.reject(b);
686
+ const [E, C] = gr(null), { isLogged: O } = n(), T = h(), k = mr(!1);
687
+ return hr(() => {
688
+ k.current || (k.current = !0, f == null || f.interceptors.response.use(
689
+ (_) => _,
690
+ async (_) => {
691
+ var U;
692
+ return typeof _ == "object" && _ && "response" in _ && _.response && typeof _.response == "object" && "status" in _.response && _.response && typeof _.response == "object" && "status" in _.response && ((U = _ == null ? void 0 : _.response) == null ? void 0 : U.status) === 401 && (f.defaults.headers.common.Authorization = null, localStorage.removeItem(i), C(o)), Promise.reject(_);
690
693
  }
691
694
  ));
692
- }, [v == null ? void 0 : v.defaults.headers.common, v == null ? void 0 : v.interceptors.response, o, u]), O && !h ? /* @__PURE__ */ A.jsx(yr, { fallback: a, children: (D = ($ = T.state) == null ? void 0 : $.from) != null && D.state && ((_ = (j = T.state) == null ? void 0 : j.from) == null ? void 0 : _.pathname) === i ? /* @__PURE__ */ A.jsx(E, { to: T.state.from.state.from.pathname + T.state.from.state.from.search, replace: !0 }) : /* @__PURE__ */ A.jsx(l, {}) }) : /* @__PURE__ */ A.jsx(E, { to: i, state: { from: T }, replace: !0 });
693
- }, ie = (a) => `GTMSendPageView require « ${a} » dependency. You can provide with InjectDependenciesProvider or directly in props.`, Ar = ({ ...a }) => {
695
+ }, [f == null ? void 0 : f.defaults.headers.common, f == null ? void 0 : f.interceptors.response, i, o]), O && !E ? /* @__PURE__ */ x.jsx(Er, { fallback: t, children: (F = ($ = T.state) == null ? void 0 : $.from) != null && F.state && ((b = (j = T.state) == null ? void 0 : j.from) == null ? void 0 : b.pathname) === u ? /* @__PURE__ */ x.jsx(m, { to: T.state.from.state.from.pathname + T.state.from.state.from.search, replace: !0 }) : /* @__PURE__ */ x.jsx(l, {}) }) : /* @__PURE__ */ x.jsx(m, { to: u, state: { from: T }, replace: !0 });
696
+ }, ie = (t) => `GTMSendPageView require « ${t} » dependency. You can provide with InjectDependenciesProvider or directly in props.`, Pr = ({ ...t }) => {
694
697
  const {
695
- useLocation: i = a.useLocation,
696
- Outlet: o = a.Outlet,
697
- useGoogleTagManager: u = a.useGoogleTagManager
698
- } = ce(K);
699
- if (i === void 0)
698
+ useLocation: u = t.useLocation,
699
+ Outlet: i = t.Outlet,
700
+ useGoogleTagManager: o = t.useGoogleTagManager
701
+ } = K(q);
702
+ if (u === void 0)
700
703
  throw new Error(ie("useLocation"));
701
- if (o === void 0)
704
+ if (i === void 0)
702
705
  throw new Error(ie("Outlet"));
703
- if (u === void 0)
706
+ if (o === void 0)
704
707
  throw new Error(ie("useGoogleTagManager"));
705
- const { pathname: c } = i(), { sendEvent: v } = u();
706
- return Rr(() => {
707
- v({ event: "pageView", pathname: c });
708
- }, [c, v]), /* @__PURE__ */ A.jsx(o, {});
709
- }, kr = ({
710
- axios: a,
711
- baseURL: i,
712
- tokenTypeKey: o = "tokenType",
713
- userLocalStorageKey: u = "user",
714
- tokenKey: c = "accessToken",
715
- postContentType: v = "application/json"
708
+ const { pathname: s } = u(), { sendEvent: f } = o();
709
+ return yr(() => {
710
+ f({ event: "pageView", pathname: s });
711
+ }, [s, f]), /* @__PURE__ */ x.jsx(i, {});
712
+ }, Ar = ({
713
+ axios: t,
714
+ baseURL: u,
715
+ tokenTypeKey: i = "tokenType",
716
+ userLocalStorageKey: o = "user",
717
+ tokenKey: s = "accessToken",
718
+ postContentType: f = "application/json"
716
719
  }) => {
717
- if (!a.defaults)
720
+ if (!t.defaults)
718
721
  return null;
719
- const m = localStorage.getItem(u), t = m ? JSON.parse(m) : null, l = t != null && t[o] ? t[o] : null, E = t != null && t[c] ? t[c] : null, h = m ? `${l} ${E}` : null;
720
- return a.defaults.baseURL = i, a.defaults.headers.post["Content-Type"] = v, h && (a.defaults.headers.common.Authorization = h), null;
721
- }, $r = ({
722
- i18n: a,
723
- debug: i,
724
- initReactI18next: o,
725
- resources: u,
726
- LanguageDetector: c
727
- }) => (a != null && a.isInitialized || (a.use(c).use(o).init({
728
- debug: i,
722
+ const h = localStorage.getItem(o), n = h ? JSON.parse(h) : null, l = n != null && n[i] ? n[i] : null, m = n != null && n[s] ? n[s] : null, E = h ? `${l} ${m}` : null;
723
+ return t.defaults.baseURL = u, t.defaults.headers.post["Content-Type"] = f, E && (t.defaults.headers.common.Authorization = E), null;
724
+ }, xr = ({
725
+ i18n: t,
726
+ debug: u,
727
+ initReactI18next: i,
728
+ resources: o,
729
+ LanguageDetector: s
730
+ }) => (t != null && t.isInitialized || (t.use(s).use(i).init({
731
+ debug: u,
729
732
  fallbackLng: "en",
730
733
  interpolation: {
731
734
  escapeValue: !1
@@ -735,157 +738,168 @@ const K = gr({
735
738
  bindI18n: !1,
736
739
  useSuspense: !0
737
740
  },
738
- resources: u,
741
+ resources: o,
739
742
  returnNull: !1
740
743
  }).then(() => {
741
- document.documentElement.lang !== a.resolvedLanguage && a.resolvedLanguage && document.documentElement.setAttribute("lang", a.resolvedLanguage);
742
- }), a.on("languageChanged", (v) => {
743
- document.documentElement.setAttribute("lang", v);
744
- })), null), Dr = ({
745
- dsn: a,
746
- sentry: i,
747
- integrations: o,
748
- tracesSampleRate: u,
749
- routingInstrumentationDependencies: c,
750
- replaysSessionSampleRate: v,
751
- replaysOnErrorSampleRate: m,
752
- tracePropagationTargets: t,
744
+ document.documentElement.lang !== t.resolvedLanguage && t.resolvedLanguage && document.documentElement.setAttribute("lang", t.resolvedLanguage);
745
+ }), t.on("languageChanged", (f) => {
746
+ document.documentElement.setAttribute("lang", f);
747
+ })), null), kr = ({
748
+ dsn: t,
749
+ sentry: u,
750
+ integrations: i,
751
+ tracesSampleRate: o,
752
+ routingInstrumentationDependencies: s,
753
+ replaysSessionSampleRate: f,
754
+ replaysOnErrorSampleRate: h,
755
+ tracePropagationTargets: n,
753
756
  ignoreErrors: l,
754
- debug: E
755
- }) => (i.isInitialized() || (E || process.env.NODE_ENV === "prod" || process.env.NODE_ENV === "production") && i.init({
756
- debug: E,
757
- dsn: a,
757
+ debug: m
758
+ }) => (u.isInitialized() || (m || process.env.NODE_ENV === "prod" || process.env.NODE_ENV === "production") && u.init({
759
+ debug: m,
760
+ dsn: t,
758
761
  ignoreErrors: l || [/Failed to fetch dynamically imported module/],
759
762
  integrations: [
760
- new i.BrowserTracing({
761
- routingInstrumentation: i.reactRouterV6Instrumentation(
762
- c.useEffect,
763
- c.useLocation,
764
- c.useNavigationType,
765
- c.createRoutesFromChildren,
766
- c.matchRoutes
763
+ new u.BrowserTracing({
764
+ routingInstrumentation: u.reactRouterV6Instrumentation(
765
+ s.useEffect,
766
+ s.useLocation,
767
+ s.useNavigationType,
768
+ s.createRoutesFromChildren,
769
+ s.matchRoutes
767
770
  )
768
771
  }),
769
- i.replayIntegration(),
770
- ...o || []
772
+ u.replayIntegration(),
773
+ ...i || []
771
774
  ],
772
- replaysOnErrorSampleRate: m || 1,
773
- replaysSessionSampleRate: v || 0.1,
774
- tracePropagationTargets: t,
775
- tracesSampleRate: u || 1
776
- }), null), Fr = ({ IMaskMixin: a, ...i }) => {
777
- const o = se(
775
+ replaysOnErrorSampleRate: h || 1,
776
+ replaysSessionSampleRate: f || 0.1,
777
+ tracePropagationTargets: n,
778
+ tracesSampleRate: o || 1
779
+ }), null), $r = ({ IMaskMixin: t, ...u }) => {
780
+ const i = se(
778
781
  // eslint-disable-next-line react/jsx-props-no-spreading
779
- () => a(({ TextField: u, ...c }) => /* @__PURE__ */ A.jsx(u, { ...c })),
780
- [a]
782
+ () => t(({ TextField: o, ...s }) => /* @__PURE__ */ x.jsx(o, { ...s })),
783
+ [t]
781
784
  );
782
- return /* @__PURE__ */ A.jsx(o, { ...i });
783
- }, Ir = ({ mapbox: a, accessToken: i }) => (a && i && (a.accessToken = i), null), Lr = ({
784
- children: a,
785
- defaultOptions: i,
786
- QueryClient: o,
787
- QueryClientProvider: u
785
+ return /* @__PURE__ */ x.jsx(i, { ...u });
786
+ }, Fr = ({ mapbox: t, accessToken: u }) => (t && u && (t.accessToken = u), null), Dr = ({
787
+ children: t,
788
+ defaultOptions: u,
789
+ QueryClient: i,
790
+ QueryClientProvider: o
788
791
  }) => {
789
- const c = new o({
792
+ const s = new i({
790
793
  defaultOptions: {
791
794
  queries: {
792
795
  refetchOnWindowFocus: !1,
793
796
  retry: 3,
794
- ...i
797
+ ...u
795
798
  }
796
799
  }
797
800
  });
798
- return /* @__PURE__ */ A.jsx(u, { client: c, children: a });
799
- }, Wr = (a) => {
800
- const { unknownErrorTranslationKey: i = "error.unknownError" } = a || {}, { translate: o = a == null ? void 0 : a.translate } = ce(K), u = o ? o(i) : "Unknown error", c = U(
801
- (m) => {
802
- var l, E, h, C, O, T, k, $, D;
803
- const { response: t } = m || {};
804
- return t != null && t.reason ? String(t.reason) : (l = t == null ? void 0 : t.data) != null && l.reason ? String(t.data.reason) : (E = t == null ? void 0 : t.data) != null && E.message ? String(t.data.message) : (C = (h = t == null ? void 0 : t.data) == null ? void 0 : h.detail) != null && C.length && Array.isArray((O = t == null ? void 0 : t.data) == null ? void 0 : O.detail) && ((k = (T = t == null ? void 0 : t.data) == null ? void 0 : T.detail[0]) != null && k.msg) && typeof ((D = ($ = t == null ? void 0 : t.data) == null ? void 0 : $.detail[0]) == null ? void 0 : D.msg) == "string" ? String(t.data.detail[0].msg) : u;
801
+ return /* @__PURE__ */ x.jsx(o, { client: s, children: t });
802
+ }, Lr = (t) => {
803
+ const { unknownErrorTranslationKey: u = "error.unknownError" } = t || {}, { translate: i = t == null ? void 0 : t.translate } = K(q), o = i ? i(u) : "Unknown error", s = Y(
804
+ (h) => {
805
+ var l, m, E, C, O, T, k, $, F;
806
+ const { response: n } = h || {};
807
+ return n != null && n.reason ? String(n.reason) : (l = n == null ? void 0 : n.data) != null && l.reason ? String(n.data.reason) : (m = n == null ? void 0 : n.data) != null && m.message ? String(n.data.message) : (C = (E = n == null ? void 0 : n.data) == null ? void 0 : E.detail) != null && C.length && Array.isArray((O = n == null ? void 0 : n.data) == null ? void 0 : O.detail) && ((k = (T = n == null ? void 0 : n.data) == null ? void 0 : T.detail[0]) != null && k.msg) && typeof ((F = ($ = n == null ? void 0 : n.data) == null ? void 0 : $.detail[0]) == null ? void 0 : F.msg) == "string" ? String(n.data.detail[0].msg) : o;
805
808
  },
806
- [u]
807
- ), v = U(
808
- (m) => {
809
- var l, E, h;
810
- const { response: t } = m || {};
811
- return o && (t != null && t.error_code) ? o(t == null ? void 0 : t.error_code) : o && ((l = t == null ? void 0 : t.data) != null && l.error_code) ? o((E = t == null ? void 0 : t.data) == null ? void 0 : E.error_code) : t != null && t.error_code ? String(t == null ? void 0 : t.error_code) : (h = t == null ? void 0 : t.data) != null && h.error_code ? String(t.data.error_code) : u;
809
+ [o]
810
+ ), f = Y(
811
+ (h) => {
812
+ var l, m, E;
813
+ const { response: n } = h || {};
814
+ return i && (n != null && n.error_code) ? i(n == null ? void 0 : n.error_code) : i && ((l = n == null ? void 0 : n.data) != null && l.error_code) ? i((m = n == null ? void 0 : n.data) == null ? void 0 : m.error_code) : n != null && n.error_code ? String(n == null ? void 0 : n.error_code) : (E = n == null ? void 0 : n.data) != null && E.error_code ? String(n.data.error_code) : o;
812
815
  },
813
- [u, o]
816
+ [o, i]
814
817
  );
815
- return { printError: c, printErrorCode: v };
816
- }, Nr = ({
817
- data: a,
818
- fetchNextPage: i,
819
- isFetchingNextPage: o,
820
- isInitialLoading: u,
821
- isLoading: c,
822
- enabled: v = !0
818
+ return { printError: s, printErrorCode: f };
819
+ }, Ir = ({
820
+ data: t,
821
+ fetchNextPage: u,
822
+ isFetchingNextPage: i,
823
+ isInitialLoading: o,
824
+ isLoading: s,
825
+ enabled: f = !0
823
826
  }) => {
824
- const m = U(
827
+ const h = Y(
825
828
  async (l) => {
826
- o || !v || await i({ pageParam: (l == null ? void 0 : l.pageParam) || l.visibleRowsCount });
829
+ i || !f || await u({ pageParam: (l == null ? void 0 : l.pageParam) || l.visibleRowsCount });
827
830
  },
828
- [v, i, o]
829
- ), t = se(() => {
830
- if (a)
831
- return a.pages.reduce((l, E) => [...l, ...E], []);
832
- }, [a]);
831
+ [f, u, i]
832
+ ), n = se(() => {
833
+ if (t)
834
+ return t.pages.reduce((l, m) => [...l, ...m], []);
835
+ }, [t]);
833
836
  return {
834
- fetchNextPageOnRowsScrollEnd: m,
835
- isLoading: o || c,
836
- loadingVariant: u ? "skeleton" : "linear",
837
- rows: t
837
+ fetchNextPageOnRowsScrollEnd: h,
838
+ isLoading: i || s,
839
+ loadingVariant: o ? "skeleton" : "linear",
840
+ rows: n
838
841
  };
839
- }, Vr = (a) => {
840
- const i = U(
841
- ({ tokenType: u, accessToken: c }) => {
842
- a.defaults.headers.common.Authorization = `${u} ${c}`;
842
+ }, Nr = (t) => {
843
+ const u = Y(
844
+ ({ tokenType: o, accessToken: s }) => {
845
+ t.defaults.headers.common.Authorization = `${o} ${s}`;
843
846
  },
844
- [a.defaults.headers.common]
847
+ [t.defaults.headers.common]
845
848
  );
846
849
  return {
847
- clearAuthenticationToken: U(() => {
848
- a.defaults.headers.common.Authorization = null;
849
- }, [a.defaults.headers.common]),
850
- setAuthenticationToken: i
850
+ clearAuthenticationToken: Y(() => {
851
+ t.defaults.headers.common.Authorization = null;
852
+ }, [t.defaults.headers.common]),
853
+ setAuthenticationToken: u
851
854
  };
852
- }, wr = (a) => a.charAt(0).toUpperCase() + a.slice(1).toLowerCase(), Cr = (a) => {
853
- const u = a.split("/").filter((c) => c.length > 0).map((c) => c.replace(/\${([^}]*)}/g, "$1").split(/[_-]/).map((l) => l.charAt(0).toUpperCase() + l.slice(1)).join("")).join("");
854
- return u.charAt(0).toLowerCase() + u.slice(1);
855
- }, Tr = (a, i, o) => {
856
- const u = Cr(i), c = wr(o);
857
- return `${u}${c}`;
858
- }, Or = (a) => {
859
- if (a)
860
- return (a == null ? void 0 : a.reduce((i, o) => (i[o] = {
855
+ }, Ie = (t, u) => {
856
+ if (!t)
857
+ return "";
858
+ const i = typeof t == "object" && "pathname" in t ? `${t.origin}${t.pathname}` : t, o = i.startsWith("/") ? i : `/${i}`;
859
+ return typeof u == "number" ? `${t}${o.replace("/files", `/thumbs/${u}`)}` : `${t}${o}`;
860
+ }, Wr = () => {
861
+ const { apiURL: t } = K(q);
862
+ return { distanceAdapter: (o, s = "km") => {
863
+ const f = Number(o);
864
+ return Number.isNaN(f) ? `0 ${s}` : `${f.toFixed(2)} ${s}`;
865
+ }, filePathAdapter: (o, s) => Ie(t && typeof o == "string" ? { origin: t, pathname: o } : o, s) };
866
+ }, _r = (t) => t.charAt(0).toUpperCase() + t.slice(1).toLowerCase(), wr = (t) => {
867
+ const o = t.split("/").filter((s) => s.length > 0).map((s) => s.replace(/\${([^}]*)}/g, "$1").split(/[_-]/).map((l) => l.charAt(0).toUpperCase() + l.slice(1)).join("")).join("");
868
+ return o.charAt(0).toLowerCase() + o.slice(1);
869
+ }, Cr = (t, u, i) => {
870
+ const o = wr(u), s = _r(i);
871
+ return `${o}${s}`;
872
+ }, Tr = (t) => {
873
+ if (t)
874
+ return (t == null ? void 0 : t.reduce((u, i) => (u[i] = {
861
875
  query: {
862
876
  useInfinite: !0,
863
877
  useInfiniteQueryParam: "offset"
864
878
  }
865
- }, i), {})) || {};
866
- }, Mr = (a) => {
867
- const { input: i = "./openapi.json", operationsToGenerateInfiniteQueryHook: o = void 0 } = a || {};
879
+ }, u), {})) || {};
880
+ }, Mr = (t) => {
881
+ const { input: u = "./openapi.json", operationsToGenerateInfiniteQueryHook: i = void 0 } = t || {};
868
882
  return {
869
883
  api: {
870
884
  hooks: {
871
885
  afterAllFilesWrite: "prettier src/api/ --write"
872
886
  },
873
- input: i,
887
+ input: u,
874
888
  output: {
875
889
  client: "react-query",
876
890
  mode: "tags-split",
877
891
  override: {
878
- header: (u) => [
892
+ header: (o) => [
879
893
  "Generated by orval 🍺",
880
- ...u.title ? [u.title] : [],
881
- ...u.description ? [u.description] : []
894
+ ...o.title ? [o.title] : [],
895
+ ...o.description ? [o.description] : []
882
896
  ],
883
897
  mutator: {
884
898
  name: "axiosCustomInstance",
885
899
  path: `${__dirname}/config/orval/mutator/axiosCustomInstance.ts`
886
900
  },
887
- operationName: Tr,
888
- ...(o == null ? void 0 : o.length) && { operations: Or(o) },
901
+ operationName: Cr,
902
+ ...(i == null ? void 0 : i.length) && { operations: Tr(i) },
889
903
  query: {
890
904
  useQuery: !0
891
905
  }
@@ -895,44 +909,22 @@ const K = gr({
895
909
  }
896
910
  }
897
911
  };
898
- }, W = {
899
- react: "^18.2.0",
900
- "react-dom": "^18.2.0"
901
- }, We = {
902
- "@testing-library/jest-dom": "^5.17.0",
903
- "@testing-library/react": "^14.0.0",
904
- "@testing-library/user-event": "^14.5.1",
905
- "@types/react": "^18.2.30",
906
- "@types/react-dom": "^18.2.14",
907
- "@vitejs/plugin-react": "^4.2.1",
908
- "eslint-config-react-tracktor": "^1.7.1",
909
- husky: "^8.0.3",
910
- jsdom: "^22.1.0",
911
- typescript: "^5.3.3",
912
- vite: "^5.1.5",
913
- "vite-plugin-dts": "^3.7.3",
914
- "vite-plugin-static-copy": "^0.17.1",
915
- vitest: "^1.3.1"
916
- }, Sr = () => "react-native" in W && W["react-native"] && "expo" in W && W.expo ? process.env.EXPO_PUBLIC_API_URL : "react" in W && W.react && "vite" in We && We.vite ? imprort.meta.env.VITE_API_URL : "", Yr = (a, i) => {
917
- if (!a)
918
- return "";
919
- const o = a.startsWith("/") ? a : `/${a}`, u = Sr();
920
- return typeof i == "number" ? `${u}${o.replace("/files", `/thumbs/${i}`)}` : `${u}${o}`;
921
912
  };
922
913
  export {
923
- kr as AxiosConfig,
924
- Ar as GTMSendPageView,
925
- $r as I18nConfig,
926
- K as InjectDependenciesContext,
927
- Pr as InjectDependenciesProvider,
928
- Ir as MapBoxConfig,
929
- Fr as MaskTextField,
930
- Lr as QueryClientConfigProvider,
931
- xr as RequireAuth,
932
- Dr as SentryConfig,
933
- Yr as filePathAdapter,
914
+ Ar as AxiosConfig,
915
+ Pr as GTMSendPageView,
916
+ xr as I18nConfig,
917
+ q as InjectDependenciesContext,
918
+ Sr as InjectDependenciesProvider,
919
+ Fr as MapBoxConfig,
920
+ $r as MaskTextField,
921
+ Dr as QueryClientConfigProvider,
922
+ jr as RequireAuth,
923
+ kr as SentryConfig,
924
+ Ie as filePathAdapter,
934
925
  Mr as getOrvalConfig,
935
- Vr as useAuth,
936
- Nr as useInfiniteDataGrid,
937
- Wr as useResponseError
926
+ Wr as useAdapter,
927
+ Nr as useAuth,
928
+ Ir as useInfiniteDataGrid,
929
+ Lr as useResponseError
938
930
  };