@tracktor/shared-module 0.19.2 → 0.20.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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,5 @@
1
1
  # [Versions](https://github.com/Tracktor/shared-module/releases)
2
2
 
3
- ## v0.19.2
4
- - **[fix]** : filePathAdapter
3
+ ## v0.20.0
4
+ - **[feat]** : add `distanceAdapter` to export utils
5
5
  __
@@ -1,5 +1,5 @@
1
1
  export declare const useAdapter: () => {
2
- distanceAdapter: (distance?: string | number | null, metric?: string) => string;
2
+ distanceAdapter: (distance?: string | number | null | undefined, metric?: string) => string;
3
3
  filePathAdapter: (href?: string | null | {
4
4
  pathname: string;
5
5
  origin: string;
package/dist/main.d.ts CHANGED
@@ -26,5 +26,7 @@ export { default as useAdapter } from './hooks/useAdapter';
26
26
  export * from './hooks/useAdapter';
27
27
  export { default as getOrvalConfig } from './config/orval';
28
28
  export * from './config/orval';
29
+ export { default as distanceAdapter } from './utils/adapter/distanceAdapter';
30
+ export * from './utils/adapter/distanceAdapter';
29
31
  export { default as filePathAdapter } from './utils/adapter/filePathAdapter';
30
32
  export * from './utils/adapter/filePathAdapter';
package/dist/main.js CHANGED
@@ -12,7 +12,7 @@ var ue = { exports: {} }, M = {};
12
12
  var De;
13
13
  function Rr() {
14
14
  return De || (De = 1, process.env.NODE_ENV !== "production" && function() {
15
- var t = Ne, u = Symbol.for("react.element"), o = Symbol.for("react.portal"), i = 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";
15
+ var t = 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"), 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
16
  function F(e) {
17
17
  if (e === null || typeof e != "object")
18
18
  return null;
@@ -22,17 +22,17 @@ function Rr() {
22
22
  var j = t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
23
23
  function b(e) {
24
24
  {
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];
25
+ for (var r = arguments.length, a = new Array(r > 1 ? r - 1 : 0), s = 1; s < r; s++)
26
+ a[s - 1] = arguments[s];
27
27
  _("error", e, a);
28
28
  }
29
29
  }
30
30
  function _(e, r, a) {
31
31
  {
32
- var c = j.ReactDebugCurrentFrame, p = c.getStackAddendum();
32
+ var s = j.ReactDebugCurrentFrame, p = s.getStackAddendum();
33
33
  p !== "" && (r += "%s", a = a.concat([p]));
34
- var g = a.map(function(v) {
35
- return String(v);
34
+ var g = a.map(function(d) {
35
+ return String(d);
36
36
  });
37
37
  g.unshift("Warning: " + r), Function.prototype.apply.call(console[e], console, g);
38
38
  }
@@ -40,16 +40,16 @@ function Rr() {
40
40
  var ce = !1, le = !1, U = !1, We = !1, Me = !1, fe;
41
41
  fe = Symbol.for("react.module.reference");
42
42
  function Ve(e) {
43
- return !!(typeof e == "string" || typeof e == "function" || e === i || 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
43
+ return !!(typeof e == "string" || typeof e == "function" || e === u || e === v || Me || e === c || 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
47
  e.$$typeof === fe || e.getModuleId !== void 0));
48
48
  }
49
49
  function Ye(e, r, a) {
50
- var c = e.displayName;
51
- if (c)
52
- return c;
50
+ var s = e.displayName;
51
+ if (s)
52
+ return s;
53
53
  var p = r.displayName || r.name || "";
54
54
  return p !== "" ? a + "(" + p + ")" : a;
55
55
  }
@@ -64,13 +64,13 @@ function Rr() {
64
64
  if (typeof e == "string")
65
65
  return e;
66
66
  switch (e) {
67
- case i:
67
+ case u:
68
68
  return "Fragment";
69
69
  case o:
70
70
  return "Portal";
71
- case f:
71
+ case v:
72
72
  return "Profiler";
73
- case s:
73
+ case c:
74
74
  return "StrictMode";
75
75
  case m:
76
76
  return "Suspense";
@@ -88,12 +88,12 @@ function Rr() {
88
88
  case l:
89
89
  return Ye(e, e.render, "ForwardRef");
90
90
  case C:
91
- var c = e.displayName || null;
92
- return c !== null ? c : P(e.type) || "Memo";
91
+ var s = e.displayName || null;
92
+ return s !== null ? s : P(e.type) || "Memo";
93
93
  case O: {
94
- var p = e, g = p._payload, v = p._init;
94
+ var p = e, g = p._payload, d = p._init;
95
95
  try {
96
- return P(v(g));
96
+ return P(d(g));
97
97
  } catch {
98
98
  return null;
99
99
  }
@@ -170,8 +170,8 @@ function Rr() {
170
170
  try {
171
171
  throw Error();
172
172
  } catch (p) {
173
- var c = p.stack.trim().match(/\n( *(at )?)/);
174
- Q = c && c[1] || "";
173
+ var s = p.stack.trim().match(/\n( *(at )?)/);
174
+ Q = s && s[1] || "";
175
175
  }
176
176
  return `
177
177
  ` + Q + e;
@@ -190,7 +190,7 @@ function Rr() {
190
190
  if (a !== void 0)
191
191
  return a;
192
192
  }
193
- var c;
193
+ var s;
194
194
  ee = !0;
195
195
  var p = Error.prepareStackTrace;
196
196
  Error.prepareStackTrace = void 0;
@@ -198,49 +198,49 @@ function Rr() {
198
198
  g = Z.current, Z.current = null, qe();
199
199
  try {
200
200
  if (r) {
201
- var v = function() {
201
+ var d = function() {
202
202
  throw Error();
203
203
  };
204
- if (Object.defineProperty(v.prototype, "props", {
204
+ if (Object.defineProperty(d.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(v, []);
210
+ Reflect.construct(d, []);
211
211
  } catch (A) {
212
- c = A;
212
+ s = A;
213
213
  }
214
- Reflect.construct(e, [], v);
214
+ Reflect.construct(e, [], d);
215
215
  } else {
216
216
  try {
217
- v.call();
217
+ d.call();
218
218
  } catch (A) {
219
- c = A;
219
+ s = A;
220
220
  }
221
- e.call(v.prototype);
221
+ e.call(d.prototype);
222
222
  }
223
223
  } else {
224
224
  try {
225
225
  throw Error();
226
226
  } catch (A) {
227
- c = A;
227
+ s = A;
228
228
  }
229
229
  e();
230
230
  }
231
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]; )
232
+ if (A && s && typeof A.stack == "string") {
233
+ for (var f = A.stack.split(`
234
+ `), w = s.stack.split(`
235
+ `), y = f.length - 1, R = w.length - 1; y >= 1 && R >= 0 && f[y] !== w[R]; )
236
236
  R--;
237
237
  for (; y >= 1 && R >= 0; y--, R--)
238
- if (d[y] !== w[R]) {
238
+ if (f[y] !== w[R]) {
239
239
  if (y !== 1 || R !== 1)
240
240
  do
241
- if (y--, R--, R < 0 || d[y] !== w[R]) {
241
+ if (y--, R--, R < 0 || f[y] !== w[R]) {
242
242
  var S = `
243
- ` + d[y].replace(" at new ", " at ");
243
+ ` + f[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);
@@ -280,7 +280,7 @@ function Rr() {
280
280
  case C:
281
281
  return G(e.type, r, a);
282
282
  case O: {
283
- var c = e, p = c._payload, g = c._init;
283
+ var s = e, p = s._payload, g = s._init;
284
284
  try {
285
285
  return G(g(p), r, a);
286
286
  } catch {
@@ -297,22 +297,22 @@ function Rr() {
297
297
  } else
298
298
  we.setExtraStackFrame(null);
299
299
  }
300
- function Je(e, r, a, c, p) {
300
+ function Je(e, r, a, s, p) {
301
301
  {
302
302
  var g = Function.call.bind(J);
303
- for (var v in e)
304
- if (g(e, v)) {
305
- var d = void 0;
303
+ for (var d in e)
304
+ if (g(e, d)) {
305
+ var f = void 0;
306
306
  try {
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`.");
307
+ if (typeof e[d] != "function") {
308
+ var w = Error((s || "React class") + ": " + a + " 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`.");
309
309
  throw w.name = "Invariant Violation", w;
310
310
  }
311
- d = e[v](r, v, c, a, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
311
+ f = e[d](r, d, s, a, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
312
312
  } catch (y) {
313
- d = y;
313
+ f = y;
314
314
  }
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));
315
+ f && !(f 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).", s || "React class", a, d, typeof f), X(null)), f instanceof Error && !(f.message in _e) && (_e[f.message] = !0, X(p), b("Failed %s type: %s", a, f.message), X(null));
316
316
  }
317
317
  }
318
318
  }
@@ -391,51 +391,51 @@ function Rr() {
391
391
  });
392
392
  }
393
393
  }
394
- var ar = function(e, r, a, c, p, g, v) {
395
- var d = {
394
+ var ar = function(e, r, a, s, p, g, d) {
395
+ var f = {
396
396
  // This tag allows us to uniquely identify this as a React Element
397
- $$typeof: u,
397
+ $$typeof: i,
398
398
  // Built-in properties that belong on the element
399
399
  type: e,
400
400
  key: r,
401
401
  ref: a,
402
- props: v,
402
+ props: d,
403
403
  // Record the component responsible for creating this element.
404
404
  _owner: g
405
405
  };
406
- return d._store = {}, Object.defineProperty(d._store, "validated", {
406
+ return f._store = {}, Object.defineProperty(f._store, "validated", {
407
407
  configurable: !1,
408
408
  enumerable: !1,
409
409
  writable: !0,
410
410
  value: !1
411
- }), Object.defineProperty(d, "_self", {
411
+ }), Object.defineProperty(f, "_self", {
412
412
  configurable: !1,
413
413
  enumerable: !1,
414
414
  writable: !1,
415
- value: c
416
- }), Object.defineProperty(d, "_source", {
415
+ value: s
416
+ }), Object.defineProperty(f, "_source", {
417
417
  configurable: !1,
418
418
  enumerable: !1,
419
419
  writable: !1,
420
420
  value: p
421
- }), Object.freeze && (Object.freeze(d.props), Object.freeze(d)), d;
421
+ }), Object.freeze && (Object.freeze(f.props), Object.freeze(f)), f;
422
422
  };
423
- function or(e, r, a, c, p) {
423
+ function or(e, r, a, s, p) {
424
424
  {
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));
425
+ var g, d = {}, f = null, w = null;
426
+ a !== void 0 && (Te(a), f = "" + a), er(r) && (Te(r.key), f = "" + r.key), Qe(r) && (w = r.ref, rr(r, p));
427
427
  for (g in r)
428
- J.call(r, g) && !Ze.hasOwnProperty(g) && (v[g] = r[g]);
428
+ J.call(r, g) && !Ze.hasOwnProperty(g) && (d[g] = r[g]);
429
429
  if (e && e.defaultProps) {
430
430
  var y = e.defaultProps;
431
431
  for (g in y)
432
- v[g] === void 0 && (v[g] = y[g]);
432
+ d[g] === void 0 && (d[g] = y[g]);
433
433
  }
434
- if (d || w) {
434
+ if (f || w) {
435
435
  var R = typeof e == "function" ? e.displayName || e.name || "Unknown" : e;
436
- d && tr(v, R), w && nr(v, R);
436
+ f && tr(d, R), w && nr(d, R);
437
437
  }
438
- return ar(e, d, w, p, c, W.current, v);
438
+ return ar(e, f, w, p, s, W.current, d);
439
439
  }
440
440
  }
441
441
  var ne = j.ReactCurrentOwner, je = j.ReactDebugCurrentFrame;
@@ -449,7 +449,7 @@ function Rr() {
449
449
  var ae;
450
450
  ae = !1;
451
451
  function oe(e) {
452
- return typeof e == "object" && e !== null && e.$$typeof === u;
452
+ return typeof e == "object" && e !== null && e.$$typeof === i;
453
453
  }
454
454
  function Pe() {
455
455
  {
@@ -496,8 +496,8 @@ Check the top-level render call using <` + a + ">.");
496
496
  if (Ae[a])
497
497
  return;
498
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);
499
+ var s = "";
500
+ e && e._owner && e._owner !== ne.current && (s = " 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, s), L(null);
501
501
  }
502
502
  }
503
503
  function ke(e, r) {
@@ -506,16 +506,16 @@ Check the top-level render call using <` + a + ">.");
506
506
  return;
507
507
  if (re(e))
508
508
  for (var a = 0; a < e.length; a++) {
509
- var c = e[a];
510
- oe(c) && xe(c, r);
509
+ var s = e[a];
510
+ oe(s) && xe(s, r);
511
511
  }
512
512
  else if (oe(e))
513
513
  e._store && (e._store.validated = !0);
514
514
  else if (e) {
515
515
  var p = F(e);
516
516
  if (typeof p == "function" && p !== e.entries)
517
- for (var g = p.call(e), v; !(v = g.next()).done; )
518
- oe(v.value) && xe(v.value, r);
517
+ for (var g = p.call(e), d; !(d = g.next()).done; )
518
+ oe(d.value) && xe(d.value, r);
519
519
  }
520
520
  }
521
521
  }
@@ -534,8 +534,8 @@ Check the top-level render call using <` + a + ">.");
534
534
  else
535
535
  return;
536
536
  if (a) {
537
- var c = P(r);
538
- Je(a, e.props, "prop", c, e);
537
+ var s = P(r);
538
+ Je(a, e.props, "prop", s, e);
539
539
  } else if (r.PropTypes !== void 0 && !ae) {
540
540
  ae = !0;
541
541
  var p = P(r);
@@ -547,33 +547,33 @@ Check the top-level render call using <` + a + ">.");
547
547
  function cr(e) {
548
548
  {
549
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);
550
+ var s = r[a];
551
+ if (s !== "children" && s !== "key") {
552
+ L(e), b("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", s), L(null);
553
553
  break;
554
554
  }
555
555
  }
556
556
  e.ref !== null && (L(e), b("Invalid attribute `ref` supplied to `React.Fragment`."), L(null));
557
557
  }
558
558
  }
559
- function $e(e, r, a, c, p, g) {
559
+ function $e(e, r, a, s, p, g) {
560
560
  {
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.");
561
+ var d = Ve(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
565
  var w = ir(p);
566
- w ? d += w : d += Pe();
566
+ w ? f += w : f += Pe();
567
567
  var y;
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);
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, 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, f);
569
569
  }
570
570
  var R = or(e, r, a, p, g);
571
571
  if (R == null)
572
572
  return R;
573
- if (v) {
573
+ if (d) {
574
574
  var S = r.children;
575
575
  if (S !== void 0)
576
- if (c)
576
+ if (s)
577
577
  if (re(S)) {
578
578
  for (var I = 0; I < S.length; I++)
579
579
  ke(S[I], e);
@@ -583,7 +583,7 @@ Check the top-level render call using <` + a + ">.");
583
583
  else
584
584
  ke(S, e);
585
585
  }
586
- return e === i ? cr(R) : sr(R), R;
586
+ return e === u ? cr(R) : sr(R), R;
587
587
  }
588
588
  }
589
589
  function lr(e, r, a) {
@@ -593,7 +593,7 @@ Check the top-level render call using <` + a + ">.");
593
593
  return $e(e, r, a, !1);
594
594
  }
595
595
  var dr = fr, vr = lr;
596
- M.Fragment = i, M.jsx = dr, M.jsxs = vr;
596
+ M.Fragment = u, M.jsx = dr, M.jsxs = vr;
597
597
  }()), M;
598
598
  }
599
599
  var V = {};
@@ -611,16 +611,16 @@ function br() {
611
611
  if (Le)
612
612
  return V;
613
613
  Le = 1;
614
- var t = Ne, u = Symbol.for("react.element"), o = Symbol.for("react.fragment"), i = 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 };
614
+ var t = Ne, i = Symbol.for("react.element"), o = Symbol.for("react.fragment"), u = Object.prototype.hasOwnProperty, c = t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, v = { key: !0, ref: !0, __self: !0, __source: !0 };
615
615
  function h(n, l, m) {
616
616
  var E, C = {}, O = null, T = null;
617
617
  m !== void 0 && (O = "" + m), l.key !== void 0 && (O = "" + l.key), l.ref !== void 0 && (T = l.ref);
618
618
  for (E in l)
619
- i.call(l, E) && !f.hasOwnProperty(E) && (C[E] = l[E]);
619
+ u.call(l, E) && !v.hasOwnProperty(E) && (C[E] = l[E]);
620
620
  if (n && n.defaultProps)
621
621
  for (E in l = n.defaultProps, l)
622
622
  C[E] === void 0 && (C[E] = l[E]);
623
- return { $$typeof: u, type: n, key: O, ref: T, props: C, _owner: s.current };
623
+ return { $$typeof: i, type: n, key: O, ref: T, props: C, _owner: c.current };
624
624
  }
625
625
  return V.Fragment = o, V.jsx = h, V.jsxs = h, V;
626
626
  }
@@ -635,13 +635,13 @@ const q = pr({
635
635
  translate: void 0,
636
636
  useAuth: void 0,
637
637
  useLocation: void 0
638
- }), Sr = ({
638
+ }), jr = ({
639
639
  axios: t,
640
- children: u,
640
+ children: i,
641
641
  translate: o,
642
- useAuth: i,
643
- Outlet: s,
644
- Navigate: f,
642
+ useAuth: u,
643
+ Outlet: c,
644
+ Navigate: v,
645
645
  useLocation: h,
646
646
  useGoogleTagManager: n,
647
647
  apiURL: l
@@ -650,30 +650,30 @@ const q = pr({
650
650
  () => ({
651
651
  apiURL: l,
652
652
  axios: t,
653
- Navigate: f,
654
- Outlet: s,
653
+ Navigate: v,
654
+ Outlet: c,
655
655
  translate: o,
656
- useAuth: i,
656
+ useAuth: u,
657
657
  useGoogleTagManager: n,
658
658
  useLocation: h
659
659
  }),
660
- [f, s, l, t, o, i, n, h]
660
+ [v, c, l, t, o, u, n, h]
661
661
  );
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 = ({
662
+ return /* @__PURE__ */ x.jsx(q.Provider, { value: m, children: i });
663
+ }, H = (t) => `RequireAuth require « ${t} » dependency. You can provide with InjectDependenciesProvider or directly in props.`, Pr = ({
664
664
  Fallback: t,
665
- loginPath: u = "/login",
665
+ loginPath: i = "/login",
666
666
  localStorageKey: o = "user",
667
- redirect401Path: i = "/login",
668
- ...s
667
+ redirect401Path: u = "/login",
668
+ ...c
669
669
  }) => {
670
670
  var $, F, j, b;
671
671
  const {
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
672
+ axios: v = c.axios,
673
+ useLocation: h = c.useLocation,
674
+ useAuth: n = c.useAuth,
675
+ Outlet: l = c.Outlet,
676
+ Navigate: m = c.Navigate
677
677
  } = K(q);
678
678
  if (n === void 0)
679
679
  throw new Error(H("useAuth"));
@@ -685,50 +685,50 @@ const q = pr({
685
685
  throw new Error(H("Navigate"));
686
686
  const [E, C] = gr(null), { isLogged: O } = n(), T = h(), k = mr(!1);
687
687
  return hr(() => {
688
- k.current || (k.current = !0, f == null || f.interceptors.response.use(
688
+ k.current || (k.current = !0, v == null || v.interceptors.response.use(
689
689
  (_) => _,
690
690
  async (_) => {
691
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(o), C(i)), Promise.reject(_);
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 && (v.defaults.headers.common.Authorization = null, localStorage.removeItem(o), C(u)), Promise.reject(_);
693
693
  }
694
694
  ));
695
- }, [f == null ? void 0 : f.defaults.headers.common, f == null ? void 0 : f.interceptors.response, o, i]), 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 }) => {
695
+ }, [v == null ? void 0 : v.defaults.headers.common, v == null ? void 0 : v.interceptors.response, o, u]), 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) === i ? /* @__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: i, state: { from: T }, replace: !0 });
696
+ }, ie = (t) => `GTMSendPageView require « ${t} » dependency. You can provide with InjectDependenciesProvider or directly in props.`, Ar = ({ ...t }) => {
697
697
  const {
698
- useLocation: u = t.useLocation,
698
+ useLocation: i = t.useLocation,
699
699
  Outlet: o = t.Outlet,
700
- useGoogleTagManager: i = t.useGoogleTagManager
700
+ useGoogleTagManager: u = t.useGoogleTagManager
701
701
  } = K(q);
702
- if (u === void 0)
702
+ if (i === void 0)
703
703
  throw new Error(ie("useLocation"));
704
704
  if (o === void 0)
705
705
  throw new Error(ie("Outlet"));
706
- if (i === void 0)
706
+ if (u === void 0)
707
707
  throw new Error(ie("useGoogleTagManager"));
708
- const { pathname: s } = u(), { sendEvent: f } = i();
708
+ const { pathname: c } = i(), { sendEvent: v } = u();
709
709
  return yr(() => {
710
- f({ event: "pageView", pathname: s });
711
- }, [s, f]), /* @__PURE__ */ x.jsx(o, {});
712
- }, Ar = ({
710
+ v({ event: "pageView", pathname: c });
711
+ }, [c, v]), /* @__PURE__ */ x.jsx(o, {});
712
+ }, xr = ({
713
713
  axios: t,
714
- baseURL: u,
714
+ baseURL: i,
715
715
  tokenTypeKey: o = "tokenType",
716
- userLocalStorageKey: i = "user",
717
- tokenKey: s = "accessToken",
718
- postContentType: f = "application/json"
716
+ userLocalStorageKey: u = "user",
717
+ tokenKey: c = "accessToken",
718
+ postContentType: v = "application/json"
719
719
  }) => {
720
720
  if (!t.defaults)
721
721
  return null;
722
- const h = localStorage.getItem(i), n = h ? JSON.parse(h) : null, l = n != null && n[o] ? n[o] : 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 = ({
722
+ const h = localStorage.getItem(u), n = h ? JSON.parse(h) : null, l = n != null && n[o] ? n[o] : null, m = n != null && n[c] ? n[c] : null, E = h ? `${l} ${m}` : null;
723
+ return t.defaults.baseURL = i, t.defaults.headers.post["Content-Type"] = v, E && (t.defaults.headers.common.Authorization = E), null;
724
+ }, kr = ({
725
725
  i18n: t,
726
- debug: u,
726
+ debug: i,
727
727
  initReactI18next: o,
728
- resources: i,
729
- LanguageDetector: s
730
- }) => (t != null && t.isInitialized || (t.use(s).use(o).init({
731
- debug: u,
728
+ resources: u,
729
+ LanguageDetector: c
730
+ }) => (t != null && t.isInitialized || (t.use(c).use(o).init({
731
+ debug: i,
732
732
  fallbackLng: "en",
733
733
  interpolation: {
734
734
  escapeValue: !1
@@ -738,111 +738,111 @@ const q = pr({
738
738
  bindI18n: !1,
739
739
  useSuspense: !0
740
740
  },
741
- resources: i,
741
+ resources: u,
742
742
  returnNull: !1
743
743
  }).then(() => {
744
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 = ({
745
+ }), t.on("languageChanged", (v) => {
746
+ document.documentElement.setAttribute("lang", v);
747
+ })), null), $r = ({
748
748
  dsn: t,
749
- sentry: u,
749
+ sentry: i,
750
750
  integrations: o,
751
- tracesSampleRate: i,
752
- routingInstrumentationDependencies: s,
753
- replaysSessionSampleRate: f,
751
+ tracesSampleRate: u,
752
+ routingInstrumentationDependencies: c,
753
+ replaysSessionSampleRate: v,
754
754
  replaysOnErrorSampleRate: h,
755
755
  tracePropagationTargets: n,
756
756
  ignoreErrors: l,
757
757
  debug: m
758
- }) => (u.isInitialized() || (m || process.env.NODE_ENV === "prod" || process.env.NODE_ENV === "production") && u.init({
758
+ }) => (i.isInitialized() || (m || process.env.NODE_ENV === "prod" || process.env.NODE_ENV === "production") && i.init({
759
759
  debug: m,
760
760
  dsn: t,
761
761
  ignoreErrors: l || [/Failed to fetch dynamically imported module/],
762
762
  integrations: [
763
- new u.BrowserTracing({
764
- routingInstrumentation: u.reactRouterV6Instrumentation(
765
- s.useEffect,
766
- s.useLocation,
767
- s.useNavigationType,
768
- s.createRoutesFromChildren,
769
- s.matchRoutes
763
+ new i.BrowserTracing({
764
+ routingInstrumentation: i.reactRouterV6Instrumentation(
765
+ c.useEffect,
766
+ c.useLocation,
767
+ c.useNavigationType,
768
+ c.createRoutesFromChildren,
769
+ c.matchRoutes
770
770
  )
771
771
  }),
772
- u.replayIntegration(),
772
+ i.replayIntegration(),
773
773
  ...o || []
774
774
  ],
775
775
  replaysOnErrorSampleRate: h || 1,
776
- replaysSessionSampleRate: f || 0.1,
776
+ replaysSessionSampleRate: v || 0.1,
777
777
  tracePropagationTargets: n,
778
- tracesSampleRate: i || 1
779
- }), null), $r = ({ IMaskMixin: t, ...u }) => {
778
+ tracesSampleRate: u || 1
779
+ }), null), Fr = ({ IMaskMixin: t, ...i }) => {
780
780
  const o = se(
781
781
  // eslint-disable-next-line react/jsx-props-no-spreading
782
- () => t(({ TextField: i, ...s }) => /* @__PURE__ */ x.jsx(i, { ...s })),
782
+ () => t(({ TextField: u, ...c }) => /* @__PURE__ */ x.jsx(u, { ...c })),
783
783
  [t]
784
784
  );
785
- return /* @__PURE__ */ x.jsx(o, { ...u });
786
- }, Fr = ({ mapbox: t, accessToken: u }) => (t && u && (t.accessToken = u), null), Dr = ({
785
+ return /* @__PURE__ */ x.jsx(o, { ...i });
786
+ }, Dr = ({ mapbox: t, accessToken: i }) => (t && i && (t.accessToken = i), null), Lr = ({
787
787
  children: t,
788
- defaultOptions: u,
788
+ defaultOptions: i,
789
789
  QueryClient: o,
790
- QueryClientProvider: i
790
+ QueryClientProvider: u
791
791
  }) => {
792
- const s = new o({
792
+ const c = new o({
793
793
  defaultOptions: {
794
794
  queries: {
795
795
  refetchOnWindowFocus: !1,
796
796
  retry: 3,
797
- ...u
797
+ ...i
798
798
  }
799
799
  }
800
800
  });
801
- return /* @__PURE__ */ x.jsx(i, { client: s, children: t });
802
- }, Lr = (t) => {
803
- const { unknownErrorTranslationKey: u = "error.unknownError" } = t || {}, { translate: o = t == null ? void 0 : t.translate } = K(q), i = o ? o(u) : "Unknown error", s = Y(
801
+ return /* @__PURE__ */ x.jsx(u, { client: c, children: t });
802
+ }, Ir = (t) => {
803
+ const { unknownErrorTranslationKey: i = "error.unknownError" } = t || {}, { translate: o = t == null ? void 0 : t.translate } = K(q), u = o ? o(i) : "Unknown error", c = Y(
804
804
  (h) => {
805
805
  var l, m, E, C, O, T, k, $, F;
806
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) : i;
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) : u;
808
808
  },
809
- [i]
810
- ), f = Y(
809
+ [u]
810
+ ), v = Y(
811
811
  (h) => {
812
812
  var l, m, E;
813
813
  const { response: n } = h || {};
814
- return o && (n != null && n.error_code) ? o(n == null ? void 0 : n.error_code) : o && ((l = n == null ? void 0 : n.data) != null && l.error_code) ? o((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) : i;
814
+ return o && (n != null && n.error_code) ? o(n == null ? void 0 : n.error_code) : o && ((l = n == null ? void 0 : n.data) != null && l.error_code) ? o((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) : u;
815
815
  },
816
- [i, o]
816
+ [u, o]
817
817
  );
818
- return { printError: s, printErrorCode: f };
819
- }, Ir = ({
818
+ return { printError: c, printErrorCode: v };
819
+ }, Nr = ({
820
820
  data: t,
821
- fetchNextPage: u,
821
+ fetchNextPage: i,
822
822
  isFetchingNextPage: o,
823
- isInitialLoading: i,
824
- isLoading: s,
825
- enabled: f = !0
823
+ isInitialLoading: u,
824
+ isLoading: c,
825
+ enabled: v = !0
826
826
  }) => {
827
827
  const h = Y(
828
828
  async (l) => {
829
- o || !f || await u({ pageParam: (l == null ? void 0 : l.pageParam) || l.visibleRowsCount });
829
+ o || !v || await i({ pageParam: (l == null ? void 0 : l.pageParam) || l.visibleRowsCount });
830
830
  },
831
- [f, u, o]
831
+ [v, i, o]
832
832
  ), n = se(() => {
833
833
  if (t)
834
834
  return t.pages.reduce((l, m) => [...l, ...m], []);
835
835
  }, [t]);
836
836
  return {
837
837
  fetchNextPageOnRowsScrollEnd: h,
838
- isLoading: o || s,
839
- loadingVariant: i ? "skeleton" : "linear",
838
+ isLoading: o || c,
839
+ loadingVariant: u ? "skeleton" : "linear",
840
840
  rows: n
841
841
  };
842
- }, Nr = (t) => {
843
- const u = Y(
844
- ({ tokenType: i, accessToken: s }) => {
845
- t.defaults.headers.common.Authorization = `${i} ${s}`;
842
+ }, Wr = (t) => {
843
+ const i = Y(
844
+ ({ tokenType: u, accessToken: c }) => {
845
+ t.defaults.headers.common.Authorization = `${u} ${c}`;
846
846
  },
847
847
  [t.defaults.headers.common]
848
848
  );
@@ -850,56 +850,59 @@ const q = pr({
850
850
  clearAuthenticationToken: Y(() => {
851
851
  t.defaults.headers.common.Authorization = null;
852
852
  }, [t.defaults.headers.common]),
853
- setAuthenticationToken: u
853
+ setAuthenticationToken: i
854
854
  };
855
- }, Ie = (t, u) => {
855
+ }, _r = (t, i = "km") => {
856
+ const o = Number(t);
857
+ return Number.isNaN(o) ? `0 ${i}` : `${o.toFixed(2)} ${i}`;
858
+ }, Ie = (t, i) => {
856
859
  if (!t)
857
860
  return "";
858
861
  const o = typeof t == "object" && "pathname" in t ? `${t.origin}${t.pathname}` : t;
859
- return typeof u == "number" ? `${o.replace("/files", `/thumbs/${u}`)}` : o;
860
- }, Wr = () => {
862
+ return typeof i == "number" ? `${o.replace("/files", `/thumbs/${i}`)}` : o;
863
+ }, Mr = () => {
861
864
  const { apiURL: t } = K(q);
862
- return { distanceAdapter: (i, s = "km") => {
863
- const f = Number(i);
864
- return Number.isNaN(f) ? `0 ${s}` : `${f.toFixed(2)} ${s}`;
865
- }, filePathAdapter: (i, s) => Ie(t && typeof i == "string" ? { origin: t, pathname: i } : i, s) };
866
- }, _r = (t) => t.charAt(0).toUpperCase() + t.slice(1).toLowerCase(), wr = (t) => {
867
- const i = 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 i.charAt(0).toLowerCase() + i.slice(1);
869
- }, Cr = (t, u, o) => {
870
- const i = wr(u), s = _r(o);
871
- return `${i}${s}`;
872
- }, Tr = (t) => {
865
+ return {
866
+ distanceAdapter: _r,
867
+ filePathAdapter: (o, u) => Ie(t && typeof o == "string" ? { origin: t, pathname: o } : o, u)
868
+ };
869
+ }, wr = (t) => t.charAt(0).toUpperCase() + t.slice(1).toLowerCase(), Cr = (t) => {
870
+ const u = t.split("/").filter((c) => c.length > 0).map((c) => c.replace(/\${([^}]*)}/g, "$1").split(/[_-]/).map((l) => l.charAt(0).toUpperCase() + l.slice(1)).join("")).join("");
871
+ return u.charAt(0).toLowerCase() + u.slice(1);
872
+ }, Tr = (t, i, o) => {
873
+ const u = Cr(i), c = wr(o);
874
+ return `${u}${c}`;
875
+ }, Or = (t) => {
873
876
  if (t)
874
- return (t == null ? void 0 : t.reduce((u, o) => (u[o] = {
877
+ return (t == null ? void 0 : t.reduce((i, o) => (i[o] = {
875
878
  query: {
876
879
  useInfinite: !0,
877
880
  useInfiniteQueryParam: "offset"
878
881
  }
879
- }, u), {})) || {};
880
- }, Mr = (t) => {
881
- const { input: u = "./openapi.json", operationsToGenerateInfiniteQueryHook: o = void 0 } = t || {};
882
+ }, i), {})) || {};
883
+ }, Vr = (t) => {
884
+ const { input: i = "./openapi.json", operationsToGenerateInfiniteQueryHook: o = void 0 } = t || {};
882
885
  return {
883
886
  api: {
884
887
  hooks: {
885
888
  afterAllFilesWrite: "prettier src/api/ --write"
886
889
  },
887
- input: u,
890
+ input: i,
888
891
  output: {
889
892
  client: "react-query",
890
893
  mode: "tags-split",
891
894
  override: {
892
- header: (i) => [
895
+ header: (u) => [
893
896
  "Generated by orval 🍺",
894
- ...i.title ? [i.title] : [],
895
- ...i.description ? [i.description] : []
897
+ ...u.title ? [u.title] : [],
898
+ ...u.description ? [u.description] : []
896
899
  ],
897
900
  mutator: {
898
901
  name: "axiosCustomInstance",
899
902
  path: `${__dirname}/config/orval/mutator/axiosCustomInstance.ts`
900
903
  },
901
- operationName: Cr,
902
- ...(o == null ? void 0 : o.length) && { operations: Tr(o) },
904
+ operationName: Tr,
905
+ ...(o == null ? void 0 : o.length) && { operations: Or(o) },
903
906
  query: {
904
907
  useQuery: !0
905
908
  }
@@ -911,20 +914,21 @@ const q = pr({
911
914
  };
912
915
  };
913
916
  export {
914
- Ar as AxiosConfig,
915
- Pr as GTMSendPageView,
916
- xr as I18nConfig,
917
+ xr as AxiosConfig,
918
+ Ar as GTMSendPageView,
919
+ kr as I18nConfig,
917
920
  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,
921
+ jr as InjectDependenciesProvider,
922
+ Dr as MapBoxConfig,
923
+ Fr as MaskTextField,
924
+ Lr as QueryClientConfigProvider,
925
+ Pr as RequireAuth,
926
+ $r as SentryConfig,
927
+ _r as distanceAdapter,
924
928
  Ie as filePathAdapter,
925
- Mr as getOrvalConfig,
926
- Wr as useAdapter,
927
- Nr as useAuth,
928
- Ir as useInfiniteDataGrid,
929
- Lr as useResponseError
929
+ Vr as getOrvalConfig,
930
+ Mr as useAdapter,
931
+ Wr as useAuth,
932
+ Nr as useInfiniteDataGrid,
933
+ Ir as useResponseError
930
934
  };
package/dist/main.umd.cjs CHANGED
@@ -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 Ne(){return ce||(ce=1,process.env.NODE_ENV!=="production"&&function(){var t=h,u=Symbol.for("react.element"),o=Symbol.for("react.portal"),i=Symbol.for("react.fragment"),s=Symbol.for("react.strict_mode"),f=Symbol.for("react.profiler"),E=Symbol.for("react.provider"),n=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),m=Symbol.for("react.suspense"),y=Symbol.for("react.suspense_list"),O=Symbol.for("react.memo"),j=Symbol.for("react.lazy"),S=Symbol.for("react.offscreen"),F=Symbol.iterator,I="@@iterator";function L(e){if(e===null||typeof e!="object")return null;var r=F&&e[F]||e[I];return typeof r=="function"?r:null}var k=t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function C(e){{for(var r=arguments.length,a=new Array(r>1?r-1:0),c=1;c<r;c++)a[c-1]=arguments[c];w("error",e,a)}}function w(e,r,a){{var c=k.ReactDebugCurrentFrame,p=c.getStackAddendum();p!==""&&(r+="%s",a=a.concat([p]));var g=a.map(function(v){return String(v)});g.unshift("Warning: "+r),Function.prototype.apply.call(console[e],console,g)}}var fe=!1,de=!1,J=!1,nr=!1,ar=!1,ve;ve=Symbol.for("react.module.reference");function or(e){return!!(typeof e=="string"||typeof e=="function"||e===i||e===f||ar||e===s||e===m||e===y||nr||e===S||fe||de||J||typeof e=="object"&&e!==null&&(e.$$typeof===j||e.$$typeof===O||e.$$typeof===E||e.$$typeof===n||e.$$typeof===l||e.$$typeof===ve||e.getModuleId!==void 0))}function ir(e,r,a){var c=e.displayName;if(c)return c;var p=r.displayName||r.name||"";return p!==""?a+"("+p+")":a}function pe(e){return e.displayName||"Context"}function x(e){if(e==null)return null;if(typeof e.tag=="number"&&C("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 i:return"Fragment";case o:return"Portal";case f:return"Profiler";case s:return"StrictMode";case m:return"Suspense";case y:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case n:var r=e;return pe(r)+".Consumer";case E:var a=e;return pe(a._context)+".Provider";case l:return ir(e,e.render,"ForwardRef");case O:var c=e.displayName||null;return c!==null?c:x(e.type)||"Memo";case j:{var p=e,g=p._payload,v=p._init;try{return x(v(g))}catch{return null}}}return null}var N=Object.assign,z=0,ge,me,he,Ee,ye,be,Re;function _e(){}_e.__reactDisabledLog=!0;function ur(){{if(z===0){ge=console.log,me=console.info,he=console.warn,Ee=console.error,ye=console.group,be=console.groupCollapsed,Re=console.groupEnd;var e={configurable:!0,enumerable:!0,value:_e,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:N({},e,{value:ge}),info:N({},e,{value:me}),warn:N({},e,{value:he}),error:N({},e,{value:Ee}),group:N({},e,{value:ye}),groupCollapsed:N({},e,{value:be}),groupEnd:N({},e,{value:Re})})}z<0&&C("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var re=k.ReactCurrentDispatcher,te;function $(e,r,a){{if(te===void 0)try{throw Error()}catch(p){var c=p.stack.trim().match(/\n( *(at )?)/);te=c&&c[1]||""}return`
10
- `+te+e}}var ne=!1,X;{var cr=typeof WeakMap=="function"?WeakMap:Map;X=new cr}function Ce(e,r){if(!e||ne)return"";{var a=X.get(e);if(a!==void 0)return a}var c;ne=!0;var p=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var g;g=re.current,re.current=null,ur();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(D){c=D}Reflect.construct(e,[],v)}else{try{v.call()}catch(D){c=D}e.call(v.prototype)}}else{try{throw Error()}catch(D){c=D}e()}}catch(D){if(D&&c&&typeof D.stack=="string"){for(var d=D.stack.split(`
11
- `),T=c.stack.split(`
12
- `),R=d.length-1,_=T.length-1;R>=1&&_>=0&&d[R]!==T[_];)_--;for(;R>=1&&_>=0;R--,_--)if(d[R]!==T[_]){if(R!==1||_!==1)do if(R--,_--,_<0||d[R]!==T[_]){var P=`
13
- `+d[R].replace(" at new "," at ");return e.displayName&&P.includes("<anonymous>")&&(P=P.replace("<anonymous>",e.displayName)),typeof e=="function"&&X.set(e,P),P}while(R>=1&&_>=0);break}}}finally{ne=!1,re.current=g,sr(),Error.prepareStackTrace=p}var V=e?e.displayName||e.name:"",Le=V?$(V):"";return typeof e=="function"&&X.set(e,Le),Le}function lr(e,r,a){return Ce(e,!1)}function fr(e){var r=e.prototype;return!!(r&&r.isReactComponent)}function H(e,r,a){if(e==null)return"";if(typeof e=="function")return Ce(e,fr(e));if(typeof e=="string")return $(e);switch(e){case m:return $("Suspense");case y:return $("SuspenseList")}if(typeof e=="object")switch(e.$$typeof){case l:return lr(e.render);case O:return H(e.type,r,a);case j:{var c=e,p=c._payload,g=c._init;try{return H(g(p),r,a)}catch{}}}return""}var K=Object.prototype.hasOwnProperty,we={},Te=k.ReactDebugCurrentFrame;function Z(e){if(e){var r=e._owner,a=H(e.type,e._source,r?r.type:null);Te.setExtraStackFrame(a)}else Te.setExtraStackFrame(null)}function dr(e,r,a,c,p){{var g=Function.call.bind(K);for(var v in e)if(g(e,v)){var d=void 0;try{if(typeof e[v]!="function"){var T=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`.");throw T.name="Invariant Violation",T}d=e[v](r,v,c,a,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(R){d=R}d&&!(d instanceof Error)&&(Z(p),C("%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),Z(null)),d instanceof Error&&!(d.message in we)&&(we[d.message]=!0,Z(p),C("Failed %s type: %s",a,d.message),Z(null))}}}var vr=Array.isArray;function ae(e){return vr(e)}function pr(e){{var r=typeof Symbol=="function"&&Symbol.toStringTag,a=r&&e[Symbol.toStringTag]||e.constructor.name||"Object";return a}}function gr(e){try{return Oe(e),!1}catch{return!0}}function Oe(e){return""+e}function Se(e){if(gr(e))return C("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",pr(e)),Oe(e)}var B=k.ReactCurrentOwner,mr={key:!0,ref:!0,__self:!0,__source:!0},je,Pe,oe;oe={};function hr(e){if(K.call(e,"ref")){var r=Object.getOwnPropertyDescriptor(e,"ref").get;if(r&&r.isReactWarning)return!1}return e.ref!==void 0}function Er(e){if(K.call(e,"key")){var r=Object.getOwnPropertyDescriptor(e,"key").get;if(r&&r.isReactWarning)return!1}return e.key!==void 0}function yr(e,r){if(typeof e.ref=="string"&&B.current&&r&&B.current.stateNode!==r){var a=x(B.current.type);oe[a]||(C('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(B.current.type),e.ref),oe[a]=!0)}}function br(e,r){{var a=function(){je||(je=!0,C("%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))};a.isReactWarning=!0,Object.defineProperty(e,"key",{get:a,configurable:!0})}}function Rr(e,r){{var a=function(){Pe||(Pe=!0,C("%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))};a.isReactWarning=!0,Object.defineProperty(e,"ref",{get:a,configurable:!0})}}var _r=function(e,r,a,c,p,g,v){var d={$$typeof:u,type:e,key:r,ref:a,props:v,_owner:g};return d._store={},Object.defineProperty(d._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(d,"_self",{configurable:!1,enumerable:!1,writable:!1,value:c}),Object.defineProperty(d,"_source",{configurable:!1,enumerable:!1,writable:!1,value:p}),Object.freeze&&(Object.freeze(d.props),Object.freeze(d)),d};function Cr(e,r,a,c,p){{var g,v={},d=null,T=null;a!==void 0&&(Se(a),d=""+a),Er(r)&&(Se(r.key),d=""+r.key),hr(r)&&(T=r.ref,yr(r,p));for(g in r)K.call(r,g)&&!mr.hasOwnProperty(g)&&(v[g]=r[g]);if(e&&e.defaultProps){var R=e.defaultProps;for(g in R)v[g]===void 0&&(v[g]=R[g])}if(d||T){var _=typeof e=="function"?e.displayName||e.name||"Unknown":e;d&&br(v,_),T&&Rr(v,_)}return _r(e,d,T,p,c,B.current,v)}}var ie=k.ReactCurrentOwner,Ae=k.ReactDebugCurrentFrame;function W(e){if(e){var r=e._owner,a=H(e.type,e._source,r?r.type:null);Ae.setExtraStackFrame(a)}else Ae.setExtraStackFrame(null)}var ue;ue=!1;function se(e){return typeof e=="object"&&e!==null&&e.$$typeof===u}function ke(){{if(ie.current){var e=x(ie.current.type);if(e)return`
9
+ */var ce;function Me(){return ce||(ce=1,process.env.NODE_ENV!=="production"&&function(){var t=h,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"),E=Symbol.for("react.provider"),n=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),m=Symbol.for("react.suspense"),y=Symbol.for("react.suspense_list"),O=Symbol.for("react.memo"),j=Symbol.for("react.lazy"),S=Symbol.for("react.offscreen"),F=Symbol.iterator,I="@@iterator";function L(e){if(e===null||typeof e!="object")return null;var r=F&&e[F]||e[I];return typeof r=="function"?r:null}var k=t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function C(e){{for(var r=arguments.length,a=new Array(r>1?r-1:0),s=1;s<r;s++)a[s-1]=arguments[s];w("error",e,a)}}function w(e,r,a){{var s=k.ReactDebugCurrentFrame,p=s.getStackAddendum();p!==""&&(r+="%s",a=a.concat([p]));var g=a.map(function(d){return String(d)});g.unshift("Warning: "+r),Function.prototype.apply.call(console[e],console,g)}}var de=!1,ve=!1,J=!1,ar=!1,or=!1,pe;pe=Symbol.for("react.module.reference");function ir(e){return!!(typeof e=="string"||typeof e=="function"||e===u||e===v||or||e===c||e===m||e===y||ar||e===S||de||ve||J||typeof e=="object"&&e!==null&&(e.$$typeof===j||e.$$typeof===O||e.$$typeof===E||e.$$typeof===n||e.$$typeof===l||e.$$typeof===pe||e.getModuleId!==void 0))}function ur(e,r,a){var s=e.displayName;if(s)return s;var p=r.displayName||r.name||"";return p!==""?a+"("+p+")":a}function ge(e){return e.displayName||"Context"}function x(e){if(e==null)return null;if(typeof e.tag=="number"&&C("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 o:return"Portal";case v:return"Profiler";case c:return"StrictMode";case m:return"Suspense";case y:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case n:var r=e;return ge(r)+".Consumer";case E:var a=e;return ge(a._context)+".Provider";case l:return ur(e,e.render,"ForwardRef");case O:var s=e.displayName||null;return s!==null?s:x(e.type)||"Memo";case j:{var p=e,g=p._payload,d=p._init;try{return x(d(g))}catch{return null}}}return null}var N=Object.assign,z=0,me,he,Ee,ye,be,Re,_e;function Ce(){}Ce.__reactDisabledLog=!0;function sr(){{if(z===0){me=console.log,he=console.info,Ee=console.warn,ye=console.error,be=console.group,Re=console.groupCollapsed,_e=console.groupEnd;var e={configurable:!0,enumerable:!0,value:Ce,writable:!0};Object.defineProperties(console,{info:e,log:e,warn:e,error:e,group:e,groupCollapsed:e,groupEnd:e})}z++}}function cr(){{if(z--,z===0){var e={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:N({},e,{value:me}),info:N({},e,{value:he}),warn:N({},e,{value:Ee}),error:N({},e,{value:ye}),group:N({},e,{value:be}),groupCollapsed:N({},e,{value:Re}),groupEnd:N({},e,{value:_e})})}z<0&&C("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var re=k.ReactCurrentDispatcher,te;function $(e,r,a){{if(te===void 0)try{throw Error()}catch(p){var s=p.stack.trim().match(/\n( *(at )?)/);te=s&&s[1]||""}return`
10
+ `+te+e}}var ne=!1,X;{var lr=typeof WeakMap=="function"?WeakMap:Map;X=new lr}function we(e,r){if(!e||ne)return"";{var a=X.get(e);if(a!==void 0)return a}var s;ne=!0;var p=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var g;g=re.current,re.current=null,sr();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(D){s=D}Reflect.construct(e,[],d)}else{try{d.call()}catch(D){s=D}e.call(d.prototype)}}else{try{throw Error()}catch(D){s=D}e()}}catch(D){if(D&&s&&typeof D.stack=="string"){for(var f=D.stack.split(`
11
+ `),T=s.stack.split(`
12
+ `),R=f.length-1,_=T.length-1;R>=1&&_>=0&&f[R]!==T[_];)_--;for(;R>=1&&_>=0;R--,_--)if(f[R]!==T[_]){if(R!==1||_!==1)do if(R--,_--,_<0||f[R]!==T[_]){var P=`
13
+ `+f[R].replace(" at new "," at ");return e.displayName&&P.includes("<anonymous>")&&(P=P.replace("<anonymous>",e.displayName)),typeof e=="function"&&X.set(e,P),P}while(R>=1&&_>=0);break}}}finally{ne=!1,re.current=g,cr(),Error.prepareStackTrace=p}var V=e?e.displayName||e.name:"",Ne=V?$(V):"";return typeof e=="function"&&X.set(e,Ne),Ne}function fr(e,r,a){return we(e,!1)}function dr(e){var r=e.prototype;return!!(r&&r.isReactComponent)}function H(e,r,a){if(e==null)return"";if(typeof e=="function")return we(e,dr(e));if(typeof e=="string")return $(e);switch(e){case m:return $("Suspense");case y:return $("SuspenseList")}if(typeof e=="object")switch(e.$$typeof){case l:return fr(e.render);case O:return H(e.type,r,a);case j:{var s=e,p=s._payload,g=s._init;try{return H(g(p),r,a)}catch{}}}return""}var K=Object.prototype.hasOwnProperty,Te={},Oe=k.ReactDebugCurrentFrame;function Z(e){if(e){var r=e._owner,a=H(e.type,e._source,r?r.type:null);Oe.setExtraStackFrame(a)}else Oe.setExtraStackFrame(null)}function vr(e,r,a,s,p){{var g=Function.call.bind(K);for(var d in e)if(g(e,d)){var f=void 0;try{if(typeof e[d]!="function"){var T=Error((s||"React class")+": "+a+" 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 T.name="Invariant Violation",T}f=e[d](r,d,s,a,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(R){f=R}f&&!(f instanceof Error)&&(Z(p),C("%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",a,d,typeof f),Z(null)),f instanceof Error&&!(f.message in Te)&&(Te[f.message]=!0,Z(p),C("Failed %s type: %s",a,f.message),Z(null))}}}var pr=Array.isArray;function ae(e){return pr(e)}function gr(e){{var r=typeof Symbol=="function"&&Symbol.toStringTag,a=r&&e[Symbol.toStringTag]||e.constructor.name||"Object";return a}}function mr(e){try{return Se(e),!1}catch{return!0}}function Se(e){return""+e}function je(e){if(mr(e))return C("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",gr(e)),Se(e)}var B=k.ReactCurrentOwner,hr={key:!0,ref:!0,__self:!0,__source:!0},Pe,Ae,oe;oe={};function Er(e){if(K.call(e,"ref")){var r=Object.getOwnPropertyDescriptor(e,"ref").get;if(r&&r.isReactWarning)return!1}return e.ref!==void 0}function yr(e){if(K.call(e,"key")){var r=Object.getOwnPropertyDescriptor(e,"key").get;if(r&&r.isReactWarning)return!1}return e.key!==void 0}function br(e,r){if(typeof e.ref=="string"&&B.current&&r&&B.current.stateNode!==r){var a=x(B.current.type);oe[a]||(C('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(B.current.type),e.ref),oe[a]=!0)}}function Rr(e,r){{var a=function(){Pe||(Pe=!0,C("%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))};a.isReactWarning=!0,Object.defineProperty(e,"key",{get:a,configurable:!0})}}function _r(e,r){{var a=function(){Ae||(Ae=!0,C("%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))};a.isReactWarning=!0,Object.defineProperty(e,"ref",{get:a,configurable:!0})}}var Cr=function(e,r,a,s,p,g,d){var f={$$typeof:i,type:e,key:r,ref:a,props:d,_owner:g};return f._store={},Object.defineProperty(f._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(f,"_self",{configurable:!1,enumerable:!1,writable:!1,value:s}),Object.defineProperty(f,"_source",{configurable:!1,enumerable:!1,writable:!1,value:p}),Object.freeze&&(Object.freeze(f.props),Object.freeze(f)),f};function wr(e,r,a,s,p){{var g,d={},f=null,T=null;a!==void 0&&(je(a),f=""+a),yr(r)&&(je(r.key),f=""+r.key),Er(r)&&(T=r.ref,br(r,p));for(g in r)K.call(r,g)&&!hr.hasOwnProperty(g)&&(d[g]=r[g]);if(e&&e.defaultProps){var R=e.defaultProps;for(g in R)d[g]===void 0&&(d[g]=R[g])}if(f||T){var _=typeof e=="function"?e.displayName||e.name||"Unknown":e;f&&Rr(d,_),T&&_r(d,_)}return Cr(e,f,T,p,s,B.current,d)}}var ie=k.ReactCurrentOwner,ke=k.ReactDebugCurrentFrame;function W(e){if(e){var r=e._owner,a=H(e.type,e._source,r?r.type:null);ke.setExtraStackFrame(a)}else ke.setExtraStackFrame(null)}var ue;ue=!1;function se(e){return typeof e=="object"&&e!==null&&e.$$typeof===i}function xe(){{if(ie.current){var e=x(ie.current.type);if(e)return`
14
14
 
15
- Check the render method of \``+e+"`."}return""}}function wr(e){{if(e!==void 0){var r=e.fileName.replace(/^.*[\\\/]/,""),a=e.lineNumber;return`
15
+ Check the render method of \``+e+"`."}return""}}function Tr(e){{if(e!==void 0){var r=e.fileName.replace(/^.*[\\\/]/,""),a=e.lineNumber;return`
16
16
 
17
- Check your code at `+r+":"+a+"."}return""}}var xe={};function Tr(e){{var r=ke();if(!r){var a=typeof e=="string"?e:e.displayName||e.name;a&&(r=`
17
+ Check your code at `+r+":"+a+"."}return""}}var De={};function Or(e){{var r=xe();if(!r){var a=typeof e=="string"?e:e.displayName||e.name;a&&(r=`
18
18
 
19
- Check the top-level render call using <`+a+">.")}return r}}function De(e,r){{if(!e._store||e._store.validated||e.key!=null)return;e._store.validated=!0;var a=Tr(r);if(xe[a])return;xe[a]=!0;var c="";e&&e._owner&&e._owner!==ie.current&&(c=" It was passed a child from "+x(e._owner.type)+"."),W(e),C('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),W(null)}}function Fe(e,r){{if(typeof e!="object")return;if(ae(e))for(var a=0;a<e.length;a++){var c=e[a];se(c)&&De(c,r)}else if(se(e))e._store&&(e._store.validated=!0);else if(e){var p=L(e);if(typeof p=="function"&&p!==e.entries)for(var g=p.call(e),v;!(v=g.next()).done;)se(v.value)&&De(v.value,r)}}}function Or(e){{var r=e.type;if(r==null||typeof r=="string")return;var a;if(typeof r=="function")a=r.propTypes;else if(typeof r=="object"&&(r.$$typeof===l||r.$$typeof===O))a=r.propTypes;else return;if(a){var c=x(r);dr(a,e.props,"prop",c,e)}else if(r.PropTypes!==void 0&&!ue){ue=!0;var p=x(r);C("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",p||"Unknown")}typeof r.getDefaultProps=="function"&&!r.getDefaultProps.isReactClassApproved&&C("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function Sr(e){{for(var r=Object.keys(e.props),a=0;a<r.length;a++){var c=r[a];if(c!=="children"&&c!=="key"){W(e),C("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",c),W(null);break}}e.ref!==null&&(W(e),C("Invalid attribute `ref` supplied to `React.Fragment`."),W(null))}}function Ie(e,r,a,c,p,g){{var v=or(e);if(!v){var d="";(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.");var T=wr(p);T?d+=T:d+=ke();var R;e===null?R="null":ae(e)?R="array":e!==void 0&&e.$$typeof===u?(R="<"+(x(e.type)||"Unknown")+" />",d=" Did you accidentally export a JSX literal instead of a component?"):R=typeof e,C("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",R,d)}var _=Cr(e,r,a,p,g);if(_==null)return _;if(v){var P=r.children;if(P!==void 0)if(c)if(ae(P)){for(var V=0;V<P.length;V++)Fe(P[V],e);Object.freeze&&Object.freeze(P)}else C("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 Fe(P,e)}return e===i?Sr(_):Or(_),_}}function jr(e,r,a){return Ie(e,r,a,!0)}function Pr(e,r,a){return Ie(e,r,a,!1)}var Ar=Pr,kr=jr;Y.Fragment=i,Y.jsx=Ar,Y.jsxs=kr}()),Y}var U={};/**
19
+ Check the top-level render call using <`+a+">.")}return r}}function Fe(e,r){{if(!e._store||e._store.validated||e.key!=null)return;e._store.validated=!0;var a=Or(r);if(De[a])return;De[a]=!0;var s="";e&&e._owner&&e._owner!==ie.current&&(s=" It was passed a child from "+x(e._owner.type)+"."),W(e),C('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',a,s),W(null)}}function Ie(e,r){{if(typeof e!="object")return;if(ae(e))for(var a=0;a<e.length;a++){var s=e[a];se(s)&&Fe(s,r)}else if(se(e))e._store&&(e._store.validated=!0);else if(e){var p=L(e);if(typeof p=="function"&&p!==e.entries)for(var g=p.call(e),d;!(d=g.next()).done;)se(d.value)&&Fe(d.value,r)}}}function Sr(e){{var r=e.type;if(r==null||typeof r=="string")return;var a;if(typeof r=="function")a=r.propTypes;else if(typeof r=="object"&&(r.$$typeof===l||r.$$typeof===O))a=r.propTypes;else return;if(a){var s=x(r);vr(a,e.props,"prop",s,e)}else if(r.PropTypes!==void 0&&!ue){ue=!0;var p=x(r);C("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",p||"Unknown")}typeof r.getDefaultProps=="function"&&!r.getDefaultProps.isReactClassApproved&&C("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function jr(e){{for(var r=Object.keys(e.props),a=0;a<r.length;a++){var s=r[a];if(s!=="children"&&s!=="key"){W(e),C("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),C("Invalid attribute `ref` supplied to `React.Fragment`."),W(null))}}function Le(e,r,a,s,p,g){{var d=ir(e);if(!d){var f="";(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.");var T=Tr(p);T?f+=T:f+=xe();var R;e===null?R="null":ae(e)?R="array":e!==void 0&&e.$$typeof===i?(R="<"+(x(e.type)||"Unknown")+" />",f=" Did you accidentally export a JSX literal instead of a component?"):R=typeof e,C("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",R,f)}var _=wr(e,r,a,p,g);if(_==null)return _;if(d){var P=r.children;if(P!==void 0)if(s)if(ae(P)){for(var V=0;V<P.length;V++)Ie(P[V],e);Object.freeze&&Object.freeze(P)}else C("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 Ie(P,e)}return e===u?jr(_):Sr(_),_}}function Pr(e,r,a){return Le(e,r,a,!0)}function Ar(e,r,a){return Le(e,r,a,!1)}var kr=Ar,xr=Pr;Y.Fragment=u,Y.jsx=kr,Y.jsxs=xr}()),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 <`+a+">.")}return r}}function De(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 Me(){if(le)return U;le=1;var t=h,u=Symbol.for("react.element"),o=Symbol.for("react.fragment"),i=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};function E(n,l,m){var y,O={},j=null,S=null;m!==void 0&&(j=""+m),l.key!==void 0&&(j=""+l.key),l.ref!==void 0&&(S=l.ref);for(y in l)i.call(l,y)&&!f.hasOwnProperty(y)&&(O[y]=l[y]);if(n&&n.defaultProps)for(y in l=n.defaultProps,l)O[y]===void 0&&(O[y]=l[y]);return{$$typeof:u,type:n,key:j,ref:S,props:O,_owner:s.current}}return U.Fragment=o,U.jsx=E,U.jsxs=E,U}process.env.NODE_ENV==="production"?q.exports=Me():q.exports=Ne();var A=q.exports;const M=h.createContext({apiURL:void 0,axios:void 0,children:void 0,Navigate:void 0,Outlet:void 0,translate:void 0,useAuth:void 0,useLocation:void 0}),We=({axios:t,children:u,translate:o,useAuth:i,Outlet:s,Navigate:f,useLocation:E,useGoogleTagManager:n,apiURL:l})=>{const m=h.useMemo(()=>({apiURL:l,axios:t,Navigate:f,Outlet:s,translate:o,useAuth:i,useGoogleTagManager:n,useLocation:E}),[f,s,l,t,o,i,n,E]);return A.jsx(M.Provider,{value:m,children:u})},G=t=>`RequireAuth require « ${t} » dependency. You can provide with InjectDependenciesProvider or directly in props.`,Ve=({Fallback:t,loginPath:u="/login",localStorageKey:o="user",redirect401Path:i="/login",...s})=>{var I,L,k,C;const{axios:f=s.axios,useLocation:E=s.useLocation,useAuth:n=s.useAuth,Outlet:l=s.Outlet,Navigate:m=s.Navigate}=h.useContext(M);if(n===void 0)throw new Error(G("useAuth"));if(E===void 0)throw new Error(G("useLocation"));if(l===void 0)throw new Error(G("Outlet"));if(m===void 0)throw new Error(G("Navigate"));const[y,O]=h.useState(null),{isLogged:j}=n(),S=E(),F=h.useRef(!1);return h.useLayoutEffect(()=>{F.current||(F.current=!0,f==null||f.interceptors.response.use(w=>w,async w=>{var J;return typeof w=="object"&&w&&"response"in w&&w.response&&typeof w.response=="object"&&"status"in w.response&&w.response&&typeof w.response=="object"&&"status"in w.response&&((J=w==null?void 0:w.response)==null?void 0:J.status)===401&&(f.defaults.headers.common.Authorization=null,localStorage.removeItem(o),O(i)),Promise.reject(w)}))},[f==null?void 0:f.defaults.headers.common,f==null?void 0:f.interceptors.response,o,i]),j&&!y?A.jsx(h.Suspense,{fallback:t,children:(L=(I=S.state)==null?void 0:I.from)!=null&&L.state&&((C=(k=S.state)==null?void 0:k.from)==null?void 0:C.pathname)===u?A.jsx(m,{to:S.state.from.state.from.pathname+S.state.from.state.from.search,replace:!0}):A.jsx(l,{})}):A.jsx(m,{to:u,state:{from:S},replace:!0})},Q=t=>`GTMSendPageView require « ${t} » dependency. You can provide with InjectDependenciesProvider or directly in props.`,Ye=({...t})=>{const{useLocation:u=t.useLocation,Outlet:o=t.Outlet,useGoogleTagManager:i=t.useGoogleTagManager}=h.useContext(M);if(u===void 0)throw new Error(Q("useLocation"));if(o===void 0)throw new Error(Q("Outlet"));if(i===void 0)throw new Error(Q("useGoogleTagManager"));const{pathname:s}=u(),{sendEvent:f}=i();return h.useEffect(()=>{f({event:"pageView",pathname:s})},[s,f]),A.jsx(o,{})},Ue=({axios:t,baseURL:u,tokenTypeKey:o="tokenType",userLocalStorageKey:i="user",tokenKey:s="accessToken",postContentType:f="application/json"})=>{if(!t.defaults)return null;const E=localStorage.getItem(i),n=E?JSON.parse(E):null,l=n!=null&&n[o]?n[o]:null,m=n!=null&&n[s]?n[s]:null,y=E?`${l} ${m}`:null;return t.defaults.baseURL=u,t.defaults.headers.post["Content-Type"]=f,y&&(t.defaults.headers.common.Authorization=y),null},ze=({i18n:t,debug:u,initReactI18next:o,resources:i,LanguageDetector:s})=>(t!=null&&t.isInitialized||(t.use(s).use(o).init({debug:u,fallbackLng:"en",interpolation:{escapeValue:!1},load:"languageOnly",react:{bindI18n:!1,useSuspense:!0},resources:i,returnNull:!1}).then(()=>{document.documentElement.lang!==t.resolvedLanguage&&t.resolvedLanguage&&document.documentElement.setAttribute("lang",t.resolvedLanguage)}),t.on("languageChanged",f=>{document.documentElement.setAttribute("lang",f)})),null),Be=({dsn:t,sentry:u,integrations:o,tracesSampleRate:i,routingInstrumentationDependencies:s,replaysSessionSampleRate:f,replaysOnErrorSampleRate:E,tracePropagationTargets:n,ignoreErrors:l,debug:m})=>(u.isInitialized()||(m||process.env.NODE_ENV==="prod"||process.env.NODE_ENV==="production")&&u.init({debug:m,dsn:t,ignoreErrors:l||[/Failed to fetch dynamically imported module/],integrations:[new u.BrowserTracing({routingInstrumentation:u.reactRouterV6Instrumentation(s.useEffect,s.useLocation,s.useNavigationType,s.createRoutesFromChildren,s.matchRoutes)}),u.replayIntegration(),...o||[]],replaysOnErrorSampleRate:E||1,replaysSessionSampleRate:f||.1,tracePropagationTargets:n,tracesSampleRate:i||1}),null),Ge=({IMaskMixin:t,...u})=>{const o=h.useMemo(()=>t(({TextField:i,...s})=>A.jsx(i,{...s})),[t]);return A.jsx(o,{...u})},Je=({mapbox:t,accessToken:u})=>(t&&u&&(t.accessToken=u),null),$e=({children:t,defaultOptions:u,QueryClient:o,QueryClientProvider:i})=>{const s=new o({defaultOptions:{queries:{refetchOnWindowFocus:!1,retry:3,...u}}});return A.jsx(i,{client:s,children:t})},Xe=t=>{const{unknownErrorTranslationKey:u="error.unknownError"}=t||{},{translate:o=t==null?void 0:t.translate}=h.useContext(M),i=o?o(u):"Unknown error",s=h.useCallback(E=>{var l,m,y,O,j,S,F,I,L;const{response:n}=E||{};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):(O=(y=n==null?void 0:n.data)==null?void 0:y.detail)!=null&&O.length&&Array.isArray((j=n==null?void 0:n.data)==null?void 0:j.detail)&&((F=(S=n==null?void 0:n.data)==null?void 0:S.detail[0])!=null&&F.msg)&&typeof((L=(I=n==null?void 0:n.data)==null?void 0:I.detail[0])==null?void 0:L.msg)=="string"?String(n.data.detail[0].msg):i},[i]),f=h.useCallback(E=>{var l,m,y;const{response:n}=E||{};return o&&(n!=null&&n.error_code)?o(n==null?void 0:n.error_code):o&&((l=n==null?void 0:n.data)!=null&&l.error_code)?o((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):(y=n==null?void 0:n.data)!=null&&y.error_code?String(n.data.error_code):i},[i,o]);return{printError:s,printErrorCode:f}},He=({data:t,fetchNextPage:u,isFetchingNextPage:o,isInitialLoading:i,isLoading:s,enabled:f=!0})=>{const E=h.useCallback(async l=>{o||!f||await u({pageParam:(l==null?void 0:l.pageParam)||l.visibleRowsCount})},[f,u,o]),n=h.useMemo(()=>{if(t)return t.pages.reduce((l,m)=>[...l,...m],[])},[t]);return{fetchNextPageOnRowsScrollEnd:E,isLoading:o||s,loadingVariant:i?"skeleton":"linear",rows:n}},Ke=t=>{const u=h.useCallback(({tokenType:i,accessToken:s})=>{t.defaults.headers.common.Authorization=`${i} ${s}`},[t.defaults.headers.common]);return{clearAuthenticationToken:h.useCallback(()=>{t.defaults.headers.common.Authorization=null},[t.defaults.headers.common]),setAuthenticationToken:u}},ee=(t,u)=>{if(!t)return"";const o=typeof t=="object"&&"pathname"in t?`${t.origin}${t.pathname}`:t;return typeof u=="number"?`${o.replace("/files",`/thumbs/${u}`)}`:o},Ze=()=>{const{apiURL:t}=h.useContext(M);return{distanceAdapter:(i,s="km")=>{const f=Number(i);return Number.isNaN(f)?`0 ${s}`:`${f.toFixed(2)} ${s}`},filePathAdapter:(i,s)=>ee(t&&typeof i=="string"?{origin:t,pathname:i}:i,s)}},qe=t=>t.charAt(0).toUpperCase()+t.slice(1).toLowerCase(),Qe=t=>{const i=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("");return i.charAt(0).toLowerCase()+i.slice(1)},er=(t,u,o)=>{const i=Qe(u),s=qe(o);return`${i}${s}`},rr=t=>{if(t)return(t==null?void 0:t.reduce((u,o)=>(u[o]={query:{useInfinite:!0,useInfiniteQueryParam:"offset"}},u),{}))||{}},tr=t=>{const{input:u="./openapi.json",operationsToGenerateInfiniteQueryHook:o=void 0}=t||{};return{api:{hooks:{afterAllFilesWrite:"prettier src/api/ --write"},input:u,output:{client:"react-query",mode:"tags-split",override:{header:i=>["Generated by orval 🍺",...i.title?[i.title]:[],...i.description?[i.description]:[]],mutator:{name:"axiosCustomInstance",path:`${__dirname}/config/orval/mutator/axiosCustomInstance.ts`},operationName:er,...(o==null?void 0:o.length)&&{operations:rr(o)},query:{useQuery:!0}},schemas:"src/api/model",target:"src/api/services/api.ts"}}}};b.AxiosConfig=Ue,b.GTMSendPageView=Ye,b.I18nConfig=ze,b.InjectDependenciesContext=M,b.InjectDependenciesProvider=We,b.MapBoxConfig=Je,b.MaskTextField=Ge,b.QueryClientConfigProvider=$e,b.RequireAuth=Ve,b.SentryConfig=Be,b.filePathAdapter=ee,b.getOrvalConfig=tr,b.useAdapter=Ze,b.useAuth=Ke,b.useInfiniteDataGrid=He,b.useResponseError=Xe,Object.defineProperty(b,Symbol.toStringTag,{value:"Module"})});
27
+ */var le;function We(){if(le)return U;le=1;var t=h,i=Symbol.for("react.element"),o=Symbol.for("react.fragment"),u=Object.prototype.hasOwnProperty,c=t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,v={key:!0,ref:!0,__self:!0,__source:!0};function E(n,l,m){var y,O={},j=null,S=null;m!==void 0&&(j=""+m),l.key!==void 0&&(j=""+l.key),l.ref!==void 0&&(S=l.ref);for(y in l)u.call(l,y)&&!v.hasOwnProperty(y)&&(O[y]=l[y]);if(n&&n.defaultProps)for(y in l=n.defaultProps,l)O[y]===void 0&&(O[y]=l[y]);return{$$typeof:i,type:n,key:j,ref:S,props:O,_owner:c.current}}return U.Fragment=o,U.jsx=E,U.jsxs=E,U}process.env.NODE_ENV==="production"?q.exports=We():q.exports=Me();var A=q.exports;const M=h.createContext({apiURL:void 0,axios:void 0,children:void 0,Navigate:void 0,Outlet:void 0,translate:void 0,useAuth:void 0,useLocation:void 0}),Ve=({axios:t,children:i,translate:o,useAuth:u,Outlet:c,Navigate:v,useLocation:E,useGoogleTagManager:n,apiURL:l})=>{const m=h.useMemo(()=>({apiURL:l,axios:t,Navigate:v,Outlet:c,translate:o,useAuth:u,useGoogleTagManager:n,useLocation:E}),[v,c,l,t,o,u,n,E]);return A.jsx(M.Provider,{value:m,children:i})},G=t=>`RequireAuth require « ${t} » dependency. You can provide with InjectDependenciesProvider or directly in props.`,Ye=({Fallback:t,loginPath:i="/login",localStorageKey:o="user",redirect401Path:u="/login",...c})=>{var I,L,k,C;const{axios:v=c.axios,useLocation:E=c.useLocation,useAuth:n=c.useAuth,Outlet:l=c.Outlet,Navigate:m=c.Navigate}=h.useContext(M);if(n===void 0)throw new Error(G("useAuth"));if(E===void 0)throw new Error(G("useLocation"));if(l===void 0)throw new Error(G("Outlet"));if(m===void 0)throw new Error(G("Navigate"));const[y,O]=h.useState(null),{isLogged:j}=n(),S=E(),F=h.useRef(!1);return h.useLayoutEffect(()=>{F.current||(F.current=!0,v==null||v.interceptors.response.use(w=>w,async w=>{var J;return typeof w=="object"&&w&&"response"in w&&w.response&&typeof w.response=="object"&&"status"in w.response&&w.response&&typeof w.response=="object"&&"status"in w.response&&((J=w==null?void 0:w.response)==null?void 0:J.status)===401&&(v.defaults.headers.common.Authorization=null,localStorage.removeItem(o),O(u)),Promise.reject(w)}))},[v==null?void 0:v.defaults.headers.common,v==null?void 0:v.interceptors.response,o,u]),j&&!y?A.jsx(h.Suspense,{fallback:t,children:(L=(I=S.state)==null?void 0:I.from)!=null&&L.state&&((C=(k=S.state)==null?void 0:k.from)==null?void 0:C.pathname)===i?A.jsx(m,{to:S.state.from.state.from.pathname+S.state.from.state.from.search,replace:!0}):A.jsx(l,{})}):A.jsx(m,{to:i,state:{from:S},replace:!0})},Q=t=>`GTMSendPageView require « ${t} » dependency. You can provide with InjectDependenciesProvider or directly in props.`,Ue=({...t})=>{const{useLocation:i=t.useLocation,Outlet:o=t.Outlet,useGoogleTagManager:u=t.useGoogleTagManager}=h.useContext(M);if(i===void 0)throw new Error(Q("useLocation"));if(o===void 0)throw new Error(Q("Outlet"));if(u===void 0)throw new Error(Q("useGoogleTagManager"));const{pathname:c}=i(),{sendEvent:v}=u();return h.useEffect(()=>{v({event:"pageView",pathname:c})},[c,v]),A.jsx(o,{})},ze=({axios:t,baseURL:i,tokenTypeKey:o="tokenType",userLocalStorageKey:u="user",tokenKey:c="accessToken",postContentType:v="application/json"})=>{if(!t.defaults)return null;const E=localStorage.getItem(u),n=E?JSON.parse(E):null,l=n!=null&&n[o]?n[o]:null,m=n!=null&&n[c]?n[c]:null,y=E?`${l} ${m}`:null;return t.defaults.baseURL=i,t.defaults.headers.post["Content-Type"]=v,y&&(t.defaults.headers.common.Authorization=y),null},Be=({i18n:t,debug:i,initReactI18next:o,resources:u,LanguageDetector:c})=>(t!=null&&t.isInitialized||(t.use(c).use(o).init({debug:i,fallbackLng:"en",interpolation:{escapeValue:!1},load:"languageOnly",react:{bindI18n:!1,useSuspense:!0},resources:u,returnNull:!1}).then(()=>{document.documentElement.lang!==t.resolvedLanguage&&t.resolvedLanguage&&document.documentElement.setAttribute("lang",t.resolvedLanguage)}),t.on("languageChanged",v=>{document.documentElement.setAttribute("lang",v)})),null),Ge=({dsn:t,sentry:i,integrations:o,tracesSampleRate:u,routingInstrumentationDependencies:c,replaysSessionSampleRate:v,replaysOnErrorSampleRate:E,tracePropagationTargets:n,ignoreErrors:l,debug:m})=>(i.isInitialized()||(m||process.env.NODE_ENV==="prod"||process.env.NODE_ENV==="production")&&i.init({debug:m,dsn:t,ignoreErrors:l||[/Failed to fetch dynamically imported module/],integrations:[new i.BrowserTracing({routingInstrumentation:i.reactRouterV6Instrumentation(c.useEffect,c.useLocation,c.useNavigationType,c.createRoutesFromChildren,c.matchRoutes)}),i.replayIntegration(),...o||[]],replaysOnErrorSampleRate:E||1,replaysSessionSampleRate:v||.1,tracePropagationTargets:n,tracesSampleRate:u||1}),null),Je=({IMaskMixin:t,...i})=>{const o=h.useMemo(()=>t(({TextField:u,...c})=>A.jsx(u,{...c})),[t]);return A.jsx(o,{...i})},$e=({mapbox:t,accessToken:i})=>(t&&i&&(t.accessToken=i),null),Xe=({children:t,defaultOptions:i,QueryClient:o,QueryClientProvider:u})=>{const c=new o({defaultOptions:{queries:{refetchOnWindowFocus:!1,retry:3,...i}}});return A.jsx(u,{client:c,children:t})},He=t=>{const{unknownErrorTranslationKey:i="error.unknownError"}=t||{},{translate:o=t==null?void 0:t.translate}=h.useContext(M),u=o?o(i):"Unknown error",c=h.useCallback(E=>{var l,m,y,O,j,S,F,I,L;const{response:n}=E||{};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):(O=(y=n==null?void 0:n.data)==null?void 0:y.detail)!=null&&O.length&&Array.isArray((j=n==null?void 0:n.data)==null?void 0:j.detail)&&((F=(S=n==null?void 0:n.data)==null?void 0:S.detail[0])!=null&&F.msg)&&typeof((L=(I=n==null?void 0:n.data)==null?void 0:I.detail[0])==null?void 0:L.msg)=="string"?String(n.data.detail[0].msg):u},[u]),v=h.useCallback(E=>{var l,m,y;const{response:n}=E||{};return o&&(n!=null&&n.error_code)?o(n==null?void 0:n.error_code):o&&((l=n==null?void 0:n.data)!=null&&l.error_code)?o((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):(y=n==null?void 0:n.data)!=null&&y.error_code?String(n.data.error_code):u},[u,o]);return{printError:c,printErrorCode:v}},Ke=({data:t,fetchNextPage:i,isFetchingNextPage:o,isInitialLoading:u,isLoading:c,enabled:v=!0})=>{const E=h.useCallback(async l=>{o||!v||await i({pageParam:(l==null?void 0:l.pageParam)||l.visibleRowsCount})},[v,i,o]),n=h.useMemo(()=>{if(t)return t.pages.reduce((l,m)=>[...l,...m],[])},[t]);return{fetchNextPageOnRowsScrollEnd:E,isLoading:o||c,loadingVariant:u?"skeleton":"linear",rows:n}},Ze=t=>{const i=h.useCallback(({tokenType:u,accessToken:c})=>{t.defaults.headers.common.Authorization=`${u} ${c}`},[t.defaults.headers.common]);return{clearAuthenticationToken:h.useCallback(()=>{t.defaults.headers.common.Authorization=null},[t.defaults.headers.common]),setAuthenticationToken:i}},fe=(t,i="km")=>{const o=Number(t);return Number.isNaN(o)?`0 ${i}`:`${o.toFixed(2)} ${i}`},ee=(t,i)=>{if(!t)return"";const o=typeof t=="object"&&"pathname"in t?`${t.origin}${t.pathname}`:t;return typeof i=="number"?`${o.replace("/files",`/thumbs/${i}`)}`:o},qe=()=>{const{apiURL:t}=h.useContext(M);return{distanceAdapter:fe,filePathAdapter:(o,u)=>ee(t&&typeof o=="string"?{origin:t,pathname:o}:o,u)}},Qe=t=>t.charAt(0).toUpperCase()+t.slice(1).toLowerCase(),er=t=>{const u=t.split("/").filter(c=>c.length>0).map(c=>c.replace(/\${([^}]*)}/g,"$1").split(/[_-]/).map(l=>l.charAt(0).toUpperCase()+l.slice(1)).join("")).join("");return u.charAt(0).toLowerCase()+u.slice(1)},rr=(t,i,o)=>{const u=er(i),c=Qe(o);return`${u}${c}`},tr=t=>{if(t)return(t==null?void 0:t.reduce((i,o)=>(i[o]={query:{useInfinite:!0,useInfiniteQueryParam:"offset"}},i),{}))||{}},nr=t=>{const{input:i="./openapi.json",operationsToGenerateInfiniteQueryHook:o=void 0}=t||{};return{api:{hooks:{afterAllFilesWrite:"prettier src/api/ --write"},input:i,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:rr,...(o==null?void 0:o.length)&&{operations:tr(o)},query:{useQuery:!0}},schemas:"src/api/model",target:"src/api/services/api.ts"}}}};b.AxiosConfig=ze,b.GTMSendPageView=Ue,b.I18nConfig=Be,b.InjectDependenciesContext=M,b.InjectDependenciesProvider=Ve,b.MapBoxConfig=$e,b.MaskTextField=Je,b.QueryClientConfigProvider=Xe,b.RequireAuth=Ye,b.SentryConfig=Ge,b.distanceAdapter=fe,b.filePathAdapter=ee,b.getOrvalConfig=nr,b.useAdapter=qe,b.useAuth=Ze,b.useInfiniteDataGrid=Ke,b.useResponseError=He,Object.defineProperty(b,Symbol.toStringTag,{value:"Module"})});
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Adapter for distance
3
+ * Get distance and metric and return formatted distance
4
+ * @param distance
5
+ * @param metric
6
+ */
7
+ declare const distanceAdapter: (distance?: string | number | null, metric?: string) => string;
8
+ export default distanceAdapter;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tracktor/shared-module",
3
- "version": "0.19.2",
3
+ "version": "0.20.0",
4
4
  "type": "module",
5
5
  "license": "UNLICENSED",
6
6
  "types": "./dist/main.d.ts",