@tracktor/shared-module 2.13.1 → 2.14.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 +15 -2
- package/dist/components/Utils/InitializeAxiosConfig.d.ts +2 -2
- package/dist/hooks/useFilters.d.ts +5 -0
- package/dist/hooks/useResponseError/useResponseError.d.ts +1 -1
- package/dist/main.cjs +9 -9
- package/dist/main.js +560 -521
- package/dist/utils/isReactNative.d.ts +5 -0
- package/package.json +1 -1
package/dist/main.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
var
|
|
1
|
+
import Ue, { createContext as yt, useMemo as de, useContext as D, useState as Ve, useRef as ht, useEffect as V, Suspense as mt, useCallback as re } from "react";
|
|
2
|
+
var fe = { exports: {} }, J = {};
|
|
3
3
|
/**
|
|
4
4
|
* @license React
|
|
5
5
|
* react-jsx-runtime.production.min.js
|
|
@@ -9,21 +9,21 @@ var le = { exports: {} }, J = {};
|
|
|
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
|
|
13
|
-
function
|
|
14
|
-
if (
|
|
15
|
-
|
|
16
|
-
var t =
|
|
17
|
-
function
|
|
18
|
-
var g,
|
|
19
|
-
|
|
20
|
-
for (g in
|
|
21
|
-
if (
|
|
22
|
-
return { $$typeof: n, type:
|
|
12
|
+
var Ne;
|
|
13
|
+
function Et() {
|
|
14
|
+
if (Ne) return J;
|
|
15
|
+
Ne = 1;
|
|
16
|
+
var t = Ue, n = Symbol.for("react.element"), a = Symbol.for("react.fragment"), o = Object.prototype.hasOwnProperty, i = t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, u = { key: !0, ref: !0, __self: !0, __source: !0 };
|
|
17
|
+
function f(v, l, y) {
|
|
18
|
+
var g, b = {}, p = null, s = null;
|
|
19
|
+
y !== void 0 && (p = "" + y), l.key !== void 0 && (p = "" + l.key), l.ref !== void 0 && (s = l.ref);
|
|
20
|
+
for (g in l) o.call(l, g) && !u.hasOwnProperty(g) && (b[g] = l[g]);
|
|
21
|
+
if (v && v.defaultProps) for (g in l = v.defaultProps, l) b[g] === void 0 && (b[g] = l[g]);
|
|
22
|
+
return { $$typeof: n, type: v, key: p, ref: s, props: b, _owner: i.current };
|
|
23
23
|
}
|
|
24
|
-
return J.Fragment =
|
|
24
|
+
return J.Fragment = a, J.jsx = f, J.jsxs = f, J;
|
|
25
25
|
}
|
|
26
|
-
var
|
|
26
|
+
var B = {};
|
|
27
27
|
/**
|
|
28
28
|
* @license React
|
|
29
29
|
* react-jsx-runtime.development.js
|
|
@@ -33,91 +33,91 @@ var q = {};
|
|
|
33
33
|
* This source code is licensed under the MIT license found in the
|
|
34
34
|
* LICENSE file in the root directory of this source tree.
|
|
35
35
|
*/
|
|
36
|
-
var
|
|
37
|
-
function
|
|
38
|
-
return
|
|
39
|
-
var t =
|
|
40
|
-
function
|
|
36
|
+
var Ye;
|
|
37
|
+
function pt() {
|
|
38
|
+
return Ye || (Ye = 1, process.env.NODE_ENV !== "production" && function() {
|
|
39
|
+
var t = Ue, n = Symbol.for("react.element"), a = Symbol.for("react.portal"), o = Symbol.for("react.fragment"), i = Symbol.for("react.strict_mode"), u = Symbol.for("react.profiler"), f = Symbol.for("react.provider"), v = Symbol.for("react.context"), l = Symbol.for("react.forward_ref"), y = Symbol.for("react.suspense"), g = Symbol.for("react.suspense_list"), b = Symbol.for("react.memo"), p = Symbol.for("react.lazy"), s = Symbol.for("react.offscreen"), w = Symbol.iterator, _ = "@@iterator";
|
|
40
|
+
function O(e) {
|
|
41
41
|
if (e === null || typeof e != "object")
|
|
42
42
|
return null;
|
|
43
|
-
var r =
|
|
43
|
+
var r = w && e[w] || e[_];
|
|
44
44
|
return typeof r == "function" ? r : null;
|
|
45
45
|
}
|
|
46
|
-
var
|
|
47
|
-
function
|
|
46
|
+
var E = t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
|
|
47
|
+
function C(e) {
|
|
48
48
|
{
|
|
49
|
-
for (var r = arguments.length, c = new Array(r > 1 ? r - 1 : 0),
|
|
50
|
-
c[
|
|
51
|
-
|
|
49
|
+
for (var r = arguments.length, c = new Array(r > 1 ? r - 1 : 0), d = 1; d < r; d++)
|
|
50
|
+
c[d - 1] = arguments[d];
|
|
51
|
+
F("error", e, c);
|
|
52
52
|
}
|
|
53
53
|
}
|
|
54
|
-
function
|
|
54
|
+
function F(e, r, c) {
|
|
55
55
|
{
|
|
56
|
-
var
|
|
57
|
-
|
|
58
|
-
var
|
|
59
|
-
return String(
|
|
56
|
+
var d = E.ReactDebugCurrentFrame, R = d.getStackAddendum();
|
|
57
|
+
R !== "" && (r += "%s", c = c.concat([R]));
|
|
58
|
+
var S = c.map(function(m) {
|
|
59
|
+
return String(m);
|
|
60
60
|
});
|
|
61
|
-
|
|
61
|
+
S.unshift("Warning: " + r), Function.prototype.apply.call(console[e], console, S);
|
|
62
62
|
}
|
|
63
63
|
}
|
|
64
|
-
var
|
|
65
|
-
|
|
66
|
-
function
|
|
67
|
-
return !!(typeof e == "string" || typeof e == "function" || e ===
|
|
64
|
+
var $ = !1, N = !1, Y = !1, T = !1, ve = !1, ne;
|
|
65
|
+
ne = Symbol.for("react.module.reference");
|
|
66
|
+
function q(e) {
|
|
67
|
+
return !!(typeof e == "string" || typeof e == "function" || e === o || e === u || ve || e === i || e === y || e === g || T || e === s || $ || N || Y || typeof e == "object" && e !== null && (e.$$typeof === p || e.$$typeof === b || e.$$typeof === f || e.$$typeof === v || e.$$typeof === l || // This needs to include all possible module reference object
|
|
68
68
|
// types supported by any Flight configuration anywhere since
|
|
69
69
|
// we don't know which Flight build this will end up being used
|
|
70
70
|
// with.
|
|
71
|
-
e.$$typeof ===
|
|
71
|
+
e.$$typeof === ne || e.getModuleId !== void 0));
|
|
72
72
|
}
|
|
73
|
-
function
|
|
74
|
-
var
|
|
75
|
-
if (
|
|
76
|
-
return
|
|
77
|
-
var
|
|
78
|
-
return
|
|
73
|
+
function ze(e, r, c) {
|
|
74
|
+
var d = e.displayName;
|
|
75
|
+
if (d)
|
|
76
|
+
return d;
|
|
77
|
+
var R = r.displayName || r.name || "";
|
|
78
|
+
return R !== "" ? c + "(" + R + ")" : c;
|
|
79
79
|
}
|
|
80
|
-
function
|
|
80
|
+
function ge(e) {
|
|
81
81
|
return e.displayName || "Context";
|
|
82
82
|
}
|
|
83
83
|
function W(e) {
|
|
84
84
|
if (e == null)
|
|
85
85
|
return null;
|
|
86
|
-
if (typeof e.tag == "number" &&
|
|
86
|
+
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")
|
|
87
87
|
return e.displayName || e.name || null;
|
|
88
88
|
if (typeof e == "string")
|
|
89
89
|
return e;
|
|
90
90
|
switch (e) {
|
|
91
|
-
case i:
|
|
92
|
-
return "Fragment";
|
|
93
91
|
case o:
|
|
92
|
+
return "Fragment";
|
|
93
|
+
case a:
|
|
94
94
|
return "Portal";
|
|
95
|
-
case
|
|
95
|
+
case u:
|
|
96
96
|
return "Profiler";
|
|
97
|
-
case
|
|
97
|
+
case i:
|
|
98
98
|
return "StrictMode";
|
|
99
|
-
case
|
|
99
|
+
case y:
|
|
100
100
|
return "Suspense";
|
|
101
101
|
case g:
|
|
102
102
|
return "SuspenseList";
|
|
103
103
|
}
|
|
104
104
|
if (typeof e == "object")
|
|
105
105
|
switch (e.$$typeof) {
|
|
106
|
-
case
|
|
106
|
+
case v:
|
|
107
107
|
var r = e;
|
|
108
|
-
return
|
|
109
|
-
case
|
|
108
|
+
return ge(r) + ".Consumer";
|
|
109
|
+
case f:
|
|
110
110
|
var c = e;
|
|
111
|
-
return
|
|
112
|
-
case
|
|
113
|
-
return
|
|
114
|
-
case
|
|
115
|
-
var
|
|
116
|
-
return
|
|
117
|
-
case
|
|
118
|
-
var
|
|
111
|
+
return ge(c._context) + ".Provider";
|
|
112
|
+
case l:
|
|
113
|
+
return ze(e, e.render, "ForwardRef");
|
|
114
|
+
case b:
|
|
115
|
+
var d = e.displayName || null;
|
|
116
|
+
return d !== null ? d : W(e.type) || "Memo";
|
|
117
|
+
case p: {
|
|
118
|
+
var R = e, S = R._payload, m = R._init;
|
|
119
119
|
try {
|
|
120
|
-
return W(
|
|
120
|
+
return W(m(S));
|
|
121
121
|
} catch {
|
|
122
122
|
return null;
|
|
123
123
|
}
|
|
@@ -125,18 +125,18 @@ function Et() {
|
|
|
125
125
|
}
|
|
126
126
|
return null;
|
|
127
127
|
}
|
|
128
|
-
var U = Object.assign, G = 0,
|
|
129
|
-
function
|
|
128
|
+
var U = Object.assign, G = 0, ye, he, me, Ee, pe, we, Re;
|
|
129
|
+
function _e() {
|
|
130
130
|
}
|
|
131
|
-
|
|
132
|
-
function
|
|
131
|
+
_e.__reactDisabledLog = !0;
|
|
132
|
+
function Me() {
|
|
133
133
|
{
|
|
134
134
|
if (G === 0) {
|
|
135
|
-
|
|
135
|
+
ye = console.log, he = console.info, me = console.warn, Ee = console.error, pe = console.group, we = console.groupCollapsed, Re = console.groupEnd;
|
|
136
136
|
var e = {
|
|
137
137
|
configurable: !0,
|
|
138
138
|
enumerable: !0,
|
|
139
|
-
value:
|
|
139
|
+
value: _e,
|
|
140
140
|
writable: !0
|
|
141
141
|
};
|
|
142
142
|
Object.defineProperties(console, {
|
|
@@ -152,7 +152,7 @@ function Et() {
|
|
|
152
152
|
G++;
|
|
153
153
|
}
|
|
154
154
|
}
|
|
155
|
-
function
|
|
155
|
+
function Ge() {
|
|
156
156
|
{
|
|
157
157
|
if (G--, G === 0) {
|
|
158
158
|
var e = {
|
|
@@ -162,19 +162,19 @@ function Et() {
|
|
|
162
162
|
};
|
|
163
163
|
Object.defineProperties(console, {
|
|
164
164
|
log: U({}, e, {
|
|
165
|
-
value:
|
|
165
|
+
value: ye
|
|
166
166
|
}),
|
|
167
167
|
info: U({}, e, {
|
|
168
168
|
value: he
|
|
169
169
|
}),
|
|
170
170
|
warn: U({}, e, {
|
|
171
|
-
value:
|
|
171
|
+
value: me
|
|
172
172
|
}),
|
|
173
173
|
error: U({}, e, {
|
|
174
|
-
value:
|
|
174
|
+
value: Ee
|
|
175
175
|
}),
|
|
176
176
|
group: U({}, e, {
|
|
177
|
-
value:
|
|
177
|
+
value: pe
|
|
178
178
|
}),
|
|
179
179
|
groupCollapsed: U({}, e, {
|
|
180
180
|
value: we
|
|
@@ -184,215 +184,215 @@ function Et() {
|
|
|
184
184
|
})
|
|
185
185
|
});
|
|
186
186
|
}
|
|
187
|
-
G < 0 &&
|
|
187
|
+
G < 0 && C("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
|
|
188
188
|
}
|
|
189
189
|
}
|
|
190
|
-
var
|
|
191
|
-
function
|
|
190
|
+
var oe = E.ReactCurrentDispatcher, ae;
|
|
191
|
+
function Q(e, r, c) {
|
|
192
192
|
{
|
|
193
|
-
if (
|
|
193
|
+
if (ae === void 0)
|
|
194
194
|
try {
|
|
195
195
|
throw Error();
|
|
196
|
-
} catch (
|
|
197
|
-
var
|
|
198
|
-
|
|
196
|
+
} catch (R) {
|
|
197
|
+
var d = R.stack.trim().match(/\n( *(at )?)/);
|
|
198
|
+
ae = d && d[1] || "";
|
|
199
199
|
}
|
|
200
200
|
return `
|
|
201
|
-
` +
|
|
201
|
+
` + ae + e;
|
|
202
202
|
}
|
|
203
203
|
}
|
|
204
|
-
var
|
|
204
|
+
var ie = !1, H;
|
|
205
205
|
{
|
|
206
|
-
var
|
|
207
|
-
|
|
206
|
+
var Je = typeof WeakMap == "function" ? WeakMap : Map;
|
|
207
|
+
H = new Je();
|
|
208
208
|
}
|
|
209
|
-
function
|
|
210
|
-
if (!e ||
|
|
209
|
+
function be(e, r) {
|
|
210
|
+
if (!e || ie)
|
|
211
211
|
return "";
|
|
212
212
|
{
|
|
213
|
-
var c =
|
|
213
|
+
var c = H.get(e);
|
|
214
214
|
if (c !== void 0)
|
|
215
215
|
return c;
|
|
216
216
|
}
|
|
217
|
-
var
|
|
218
|
-
|
|
219
|
-
var
|
|
217
|
+
var d;
|
|
218
|
+
ie = !0;
|
|
219
|
+
var R = Error.prepareStackTrace;
|
|
220
220
|
Error.prepareStackTrace = void 0;
|
|
221
|
-
var
|
|
222
|
-
|
|
221
|
+
var S;
|
|
222
|
+
S = oe.current, oe.current = null, Me();
|
|
223
223
|
try {
|
|
224
224
|
if (r) {
|
|
225
|
-
var
|
|
225
|
+
var m = function() {
|
|
226
226
|
throw Error();
|
|
227
227
|
};
|
|
228
|
-
if (Object.defineProperty(
|
|
228
|
+
if (Object.defineProperty(m.prototype, "props", {
|
|
229
229
|
set: function() {
|
|
230
230
|
throw Error();
|
|
231
231
|
}
|
|
232
232
|
}), typeof Reflect == "object" && Reflect.construct) {
|
|
233
233
|
try {
|
|
234
|
-
Reflect.construct(
|
|
235
|
-
} catch (
|
|
236
|
-
|
|
234
|
+
Reflect.construct(m, []);
|
|
235
|
+
} catch (L) {
|
|
236
|
+
d = L;
|
|
237
237
|
}
|
|
238
|
-
Reflect.construct(e, [],
|
|
238
|
+
Reflect.construct(e, [], m);
|
|
239
239
|
} else {
|
|
240
240
|
try {
|
|
241
|
-
|
|
242
|
-
} catch (
|
|
243
|
-
|
|
241
|
+
m.call();
|
|
242
|
+
} catch (L) {
|
|
243
|
+
d = L;
|
|
244
244
|
}
|
|
245
|
-
e.call(
|
|
245
|
+
e.call(m.prototype);
|
|
246
246
|
}
|
|
247
247
|
} else {
|
|
248
248
|
try {
|
|
249
249
|
throw Error();
|
|
250
|
-
} catch (
|
|
251
|
-
|
|
250
|
+
} catch (L) {
|
|
251
|
+
d = L;
|
|
252
252
|
}
|
|
253
253
|
e();
|
|
254
254
|
}
|
|
255
|
-
} catch (
|
|
256
|
-
if (
|
|
257
|
-
for (var
|
|
258
|
-
`), A =
|
|
259
|
-
`), j =
|
|
260
|
-
|
|
261
|
-
for (; j >= 1 &&
|
|
262
|
-
if (
|
|
263
|
-
if (j !== 1 ||
|
|
255
|
+
} catch (L) {
|
|
256
|
+
if (L && d && typeof L.stack == "string") {
|
|
257
|
+
for (var h = L.stack.split(`
|
|
258
|
+
`), A = d.stack.split(`
|
|
259
|
+
`), j = h.length - 1, P = A.length - 1; j >= 1 && P >= 0 && h[j] !== A[P]; )
|
|
260
|
+
P--;
|
|
261
|
+
for (; j >= 1 && P >= 0; j--, P--)
|
|
262
|
+
if (h[j] !== A[P]) {
|
|
263
|
+
if (j !== 1 || P !== 1)
|
|
264
264
|
do
|
|
265
|
-
if (j--,
|
|
266
|
-
var
|
|
267
|
-
` +
|
|
268
|
-
return e.displayName &&
|
|
265
|
+
if (j--, P--, P < 0 || h[j] !== A[P]) {
|
|
266
|
+
var x = `
|
|
267
|
+
` + h[j].replace(" at new ", " at ");
|
|
268
|
+
return e.displayName && x.includes("<anonymous>") && (x = x.replace("<anonymous>", e.displayName)), typeof e == "function" && H.set(e, x), x;
|
|
269
269
|
}
|
|
270
|
-
while (j >= 1 &&
|
|
270
|
+
while (j >= 1 && P >= 0);
|
|
271
271
|
break;
|
|
272
272
|
}
|
|
273
273
|
}
|
|
274
274
|
} finally {
|
|
275
|
-
|
|
275
|
+
ie = !1, oe.current = S, Ge(), Error.prepareStackTrace = R;
|
|
276
276
|
}
|
|
277
|
-
var M = e ? e.displayName || e.name : "",
|
|
278
|
-
return typeof e == "function" &&
|
|
277
|
+
var M = e ? e.displayName || e.name : "", $e = M ? Q(M) : "";
|
|
278
|
+
return typeof e == "function" && H.set(e, $e), $e;
|
|
279
279
|
}
|
|
280
|
-
function
|
|
281
|
-
return
|
|
280
|
+
function Be(e, r, c) {
|
|
281
|
+
return be(e, !1);
|
|
282
282
|
}
|
|
283
|
-
function
|
|
283
|
+
function Ke(e) {
|
|
284
284
|
var r = e.prototype;
|
|
285
285
|
return !!(r && r.isReactComponent);
|
|
286
286
|
}
|
|
287
|
-
function
|
|
287
|
+
function X(e, r, c) {
|
|
288
288
|
if (e == null)
|
|
289
289
|
return "";
|
|
290
290
|
if (typeof e == "function")
|
|
291
|
-
return
|
|
291
|
+
return be(e, Ke(e));
|
|
292
292
|
if (typeof e == "string")
|
|
293
|
-
return
|
|
293
|
+
return Q(e);
|
|
294
294
|
switch (e) {
|
|
295
|
-
case
|
|
296
|
-
return
|
|
295
|
+
case y:
|
|
296
|
+
return Q("Suspense");
|
|
297
297
|
case g:
|
|
298
|
-
return
|
|
298
|
+
return Q("SuspenseList");
|
|
299
299
|
}
|
|
300
300
|
if (typeof e == "object")
|
|
301
301
|
switch (e.$$typeof) {
|
|
302
|
-
case
|
|
303
|
-
return
|
|
304
|
-
case
|
|
305
|
-
return
|
|
306
|
-
case
|
|
307
|
-
var
|
|
302
|
+
case l:
|
|
303
|
+
return Be(e.render);
|
|
304
|
+
case b:
|
|
305
|
+
return X(e.type, r, c);
|
|
306
|
+
case p: {
|
|
307
|
+
var d = e, R = d._payload, S = d._init;
|
|
308
308
|
try {
|
|
309
|
-
return
|
|
309
|
+
return X(S(R), r, c);
|
|
310
310
|
} catch {
|
|
311
311
|
}
|
|
312
312
|
}
|
|
313
313
|
}
|
|
314
314
|
return "";
|
|
315
315
|
}
|
|
316
|
-
var
|
|
317
|
-
function
|
|
316
|
+
var Z = Object.prototype.hasOwnProperty, Se = {}, Ce = E.ReactDebugCurrentFrame;
|
|
317
|
+
function ee(e) {
|
|
318
318
|
if (e) {
|
|
319
|
-
var r = e._owner, c =
|
|
319
|
+
var r = e._owner, c = X(e.type, e._source, r ? r.type : null);
|
|
320
320
|
Ce.setExtraStackFrame(c);
|
|
321
321
|
} else
|
|
322
322
|
Ce.setExtraStackFrame(null);
|
|
323
323
|
}
|
|
324
|
-
function
|
|
324
|
+
function qe(e, r, c, d, R) {
|
|
325
325
|
{
|
|
326
|
-
var
|
|
327
|
-
for (var
|
|
328
|
-
if (
|
|
329
|
-
var
|
|
326
|
+
var S = Function.call.bind(Z);
|
|
327
|
+
for (var m in e)
|
|
328
|
+
if (S(e, m)) {
|
|
329
|
+
var h = void 0;
|
|
330
330
|
try {
|
|
331
|
-
if (typeof e[
|
|
332
|
-
var A = Error((
|
|
331
|
+
if (typeof e[m] != "function") {
|
|
332
|
+
var A = Error((d || "React class") + ": " + c + " type `" + m + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof e[m] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
|
|
333
333
|
throw A.name = "Invariant Violation", A;
|
|
334
334
|
}
|
|
335
|
-
|
|
335
|
+
h = e[m](r, m, d, c, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
|
|
336
336
|
} catch (j) {
|
|
337
|
-
|
|
337
|
+
h = j;
|
|
338
338
|
}
|
|
339
|
-
|
|
339
|
+
h && !(h instanceof Error) && (ee(R), 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).", d || "React class", c, m, typeof h), ee(null)), h instanceof Error && !(h.message in Se) && (Se[h.message] = !0, ee(R), C("Failed %s type: %s", c, h.message), ee(null));
|
|
340
340
|
}
|
|
341
341
|
}
|
|
342
342
|
}
|
|
343
|
-
var
|
|
344
|
-
function
|
|
345
|
-
return
|
|
343
|
+
var Qe = Array.isArray;
|
|
344
|
+
function ce(e) {
|
|
345
|
+
return Qe(e);
|
|
346
346
|
}
|
|
347
|
-
function
|
|
347
|
+
function He(e) {
|
|
348
348
|
{
|
|
349
349
|
var r = typeof Symbol == "function" && Symbol.toStringTag, c = r && e[Symbol.toStringTag] || e.constructor.name || "Object";
|
|
350
350
|
return c;
|
|
351
351
|
}
|
|
352
352
|
}
|
|
353
|
-
function
|
|
353
|
+
function Xe(e) {
|
|
354
354
|
try {
|
|
355
|
-
return
|
|
355
|
+
return je(e), !1;
|
|
356
356
|
} catch {
|
|
357
357
|
return !0;
|
|
358
358
|
}
|
|
359
359
|
}
|
|
360
|
-
function
|
|
360
|
+
function je(e) {
|
|
361
361
|
return "" + e;
|
|
362
362
|
}
|
|
363
|
-
function
|
|
364
|
-
if (
|
|
365
|
-
return
|
|
363
|
+
function Pe(e) {
|
|
364
|
+
if (Xe(e))
|
|
365
|
+
return C("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", He(e)), je(e);
|
|
366
366
|
}
|
|
367
|
-
var
|
|
367
|
+
var Te = E.ReactCurrentOwner, Ze = {
|
|
368
368
|
key: !0,
|
|
369
369
|
ref: !0,
|
|
370
370
|
__self: !0,
|
|
371
371
|
__source: !0
|
|
372
|
-
},
|
|
373
|
-
function
|
|
374
|
-
if (
|
|
372
|
+
}, Oe, Ae;
|
|
373
|
+
function et(e) {
|
|
374
|
+
if (Z.call(e, "ref")) {
|
|
375
375
|
var r = Object.getOwnPropertyDescriptor(e, "ref").get;
|
|
376
376
|
if (r && r.isReactWarning)
|
|
377
377
|
return !1;
|
|
378
378
|
}
|
|
379
379
|
return e.ref !== void 0;
|
|
380
380
|
}
|
|
381
|
-
function
|
|
382
|
-
if (
|
|
381
|
+
function tt(e) {
|
|
382
|
+
if (Z.call(e, "key")) {
|
|
383
383
|
var r = Object.getOwnPropertyDescriptor(e, "key").get;
|
|
384
384
|
if (r && r.isReactWarning)
|
|
385
385
|
return !1;
|
|
386
386
|
}
|
|
387
387
|
return e.key !== void 0;
|
|
388
388
|
}
|
|
389
|
-
function tt(e, r) {
|
|
390
|
-
typeof e.ref == "string" && je.current;
|
|
391
|
-
}
|
|
392
389
|
function rt(e, r) {
|
|
390
|
+
typeof e.ref == "string" && Te.current;
|
|
391
|
+
}
|
|
392
|
+
function nt(e, r) {
|
|
393
393
|
{
|
|
394
394
|
var c = function() {
|
|
395
|
-
|
|
395
|
+
Oe || (Oe = !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));
|
|
396
396
|
};
|
|
397
397
|
c.isReactWarning = !0, Object.defineProperty(e, "key", {
|
|
398
398
|
get: c,
|
|
@@ -400,10 +400,10 @@ function Et() {
|
|
|
400
400
|
});
|
|
401
401
|
}
|
|
402
402
|
}
|
|
403
|
-
function
|
|
403
|
+
function ot(e, r) {
|
|
404
404
|
{
|
|
405
405
|
var c = function() {
|
|
406
|
-
|
|
406
|
+
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));
|
|
407
407
|
};
|
|
408
408
|
c.isReactWarning = !0, Object.defineProperty(e, "ref", {
|
|
409
409
|
get: c,
|
|
@@ -411,70 +411,70 @@ function Et() {
|
|
|
411
411
|
});
|
|
412
412
|
}
|
|
413
413
|
}
|
|
414
|
-
var
|
|
415
|
-
var
|
|
414
|
+
var at = function(e, r, c, d, R, S, m) {
|
|
415
|
+
var h = {
|
|
416
416
|
// This tag allows us to uniquely identify this as a React Element
|
|
417
417
|
$$typeof: n,
|
|
418
418
|
// Built-in properties that belong on the element
|
|
419
419
|
type: e,
|
|
420
420
|
key: r,
|
|
421
421
|
ref: c,
|
|
422
|
-
props:
|
|
422
|
+
props: m,
|
|
423
423
|
// Record the component responsible for creating this element.
|
|
424
|
-
_owner:
|
|
424
|
+
_owner: S
|
|
425
425
|
};
|
|
426
|
-
return
|
|
426
|
+
return h._store = {}, Object.defineProperty(h._store, "validated", {
|
|
427
427
|
configurable: !1,
|
|
428
428
|
enumerable: !1,
|
|
429
429
|
writable: !0,
|
|
430
430
|
value: !1
|
|
431
|
-
}), Object.defineProperty(
|
|
431
|
+
}), Object.defineProperty(h, "_self", {
|
|
432
432
|
configurable: !1,
|
|
433
433
|
enumerable: !1,
|
|
434
434
|
writable: !1,
|
|
435
|
-
value:
|
|
436
|
-
}), Object.defineProperty(
|
|
435
|
+
value: d
|
|
436
|
+
}), Object.defineProperty(h, "_source", {
|
|
437
437
|
configurable: !1,
|
|
438
438
|
enumerable: !1,
|
|
439
439
|
writable: !1,
|
|
440
|
-
value:
|
|
441
|
-
}), Object.freeze && (Object.freeze(
|
|
440
|
+
value: R
|
|
441
|
+
}), Object.freeze && (Object.freeze(h.props), Object.freeze(h)), h;
|
|
442
442
|
};
|
|
443
|
-
function
|
|
443
|
+
function it(e, r, c, d, R) {
|
|
444
444
|
{
|
|
445
|
-
var
|
|
446
|
-
c !== void 0 && (
|
|
447
|
-
for (
|
|
448
|
-
|
|
445
|
+
var S, m = {}, h = null, A = null;
|
|
446
|
+
c !== void 0 && (Pe(c), h = "" + c), tt(r) && (Pe(r.key), h = "" + r.key), et(r) && (A = r.ref, rt(r, R));
|
|
447
|
+
for (S in r)
|
|
448
|
+
Z.call(r, S) && !Ze.hasOwnProperty(S) && (m[S] = r[S]);
|
|
449
449
|
if (e && e.defaultProps) {
|
|
450
450
|
var j = e.defaultProps;
|
|
451
|
-
for (
|
|
452
|
-
|
|
451
|
+
for (S in j)
|
|
452
|
+
m[S] === void 0 && (m[S] = j[S]);
|
|
453
453
|
}
|
|
454
|
-
if (
|
|
455
|
-
var
|
|
456
|
-
|
|
454
|
+
if (h || A) {
|
|
455
|
+
var P = typeof e == "function" ? e.displayName || e.name || "Unknown" : e;
|
|
456
|
+
h && nt(m, P), A && ot(m, P);
|
|
457
457
|
}
|
|
458
|
-
return
|
|
458
|
+
return at(e, h, A, R, d, Te.current, m);
|
|
459
459
|
}
|
|
460
460
|
}
|
|
461
|
-
var
|
|
461
|
+
var se = E.ReactCurrentOwner, xe = E.ReactDebugCurrentFrame;
|
|
462
462
|
function z(e) {
|
|
463
463
|
if (e) {
|
|
464
|
-
var r = e._owner, c =
|
|
465
|
-
|
|
464
|
+
var r = e._owner, c = X(e.type, e._source, r ? r.type : null);
|
|
465
|
+
xe.setExtraStackFrame(c);
|
|
466
466
|
} else
|
|
467
|
-
|
|
467
|
+
xe.setExtraStackFrame(null);
|
|
468
468
|
}
|
|
469
|
-
var
|
|
470
|
-
|
|
471
|
-
function
|
|
469
|
+
var ue;
|
|
470
|
+
ue = !1;
|
|
471
|
+
function le(e) {
|
|
472
472
|
return typeof e == "object" && e !== null && e.$$typeof === n;
|
|
473
473
|
}
|
|
474
|
-
function
|
|
474
|
+
function ke() {
|
|
475
475
|
{
|
|
476
|
-
if (
|
|
477
|
-
var e = W(
|
|
476
|
+
if (se.current) {
|
|
477
|
+
var e = W(se.current.type);
|
|
478
478
|
if (e)
|
|
479
479
|
return `
|
|
480
480
|
|
|
@@ -483,13 +483,13 @@ Check the render method of \`` + e + "`.";
|
|
|
483
483
|
return "";
|
|
484
484
|
}
|
|
485
485
|
}
|
|
486
|
-
function
|
|
486
|
+
function ct(e) {
|
|
487
487
|
return "";
|
|
488
488
|
}
|
|
489
|
-
var
|
|
490
|
-
function
|
|
489
|
+
var Fe = {};
|
|
490
|
+
function st(e) {
|
|
491
491
|
{
|
|
492
|
-
var r =
|
|
492
|
+
var r = ke();
|
|
493
493
|
if (!r) {
|
|
494
494
|
var c = typeof e == "string" ? e : e.displayName || e.name;
|
|
495
495
|
c && (r = `
|
|
@@ -504,34 +504,34 @@ Check the top-level render call using <` + c + ">.");
|
|
|
504
504
|
if (!e._store || e._store.validated || e.key != null)
|
|
505
505
|
return;
|
|
506
506
|
e._store.validated = !0;
|
|
507
|
-
var c =
|
|
508
|
-
if (
|
|
507
|
+
var c = st(r);
|
|
508
|
+
if (Fe[c])
|
|
509
509
|
return;
|
|
510
|
-
|
|
511
|
-
var
|
|
512
|
-
e && e._owner && e._owner !==
|
|
510
|
+
Fe[c] = !0;
|
|
511
|
+
var d = "";
|
|
512
|
+
e && e._owner && e._owner !== se.current && (d = " It was passed a child from " + W(e._owner.type) + "."), z(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.', c, d), z(null);
|
|
513
513
|
}
|
|
514
514
|
}
|
|
515
|
-
function
|
|
515
|
+
function Le(e, r) {
|
|
516
516
|
{
|
|
517
517
|
if (typeof e != "object")
|
|
518
518
|
return;
|
|
519
|
-
if (
|
|
519
|
+
if (ce(e))
|
|
520
520
|
for (var c = 0; c < e.length; c++) {
|
|
521
|
-
var
|
|
522
|
-
|
|
521
|
+
var d = e[c];
|
|
522
|
+
le(d) && De(d, r);
|
|
523
523
|
}
|
|
524
|
-
else if (
|
|
524
|
+
else if (le(e))
|
|
525
525
|
e._store && (e._store.validated = !0);
|
|
526
526
|
else if (e) {
|
|
527
|
-
var
|
|
528
|
-
if (typeof
|
|
529
|
-
for (var
|
|
530
|
-
|
|
527
|
+
var R = O(e);
|
|
528
|
+
if (typeof R == "function" && R !== e.entries)
|
|
529
|
+
for (var S = R.call(e), m; !(m = S.next()).done; )
|
|
530
|
+
le(m.value) && De(m.value, r);
|
|
531
531
|
}
|
|
532
532
|
}
|
|
533
533
|
}
|
|
534
|
-
function
|
|
534
|
+
function ut(e) {
|
|
535
535
|
{
|
|
536
536
|
var r = e.type;
|
|
537
537
|
if (r == null || typeof r == "string")
|
|
@@ -539,139 +539,149 @@ Check the top-level render call using <` + c + ">.");
|
|
|
539
539
|
var c;
|
|
540
540
|
if (typeof r == "function")
|
|
541
541
|
c = r.propTypes;
|
|
542
|
-
else if (typeof r == "object" && (r.$$typeof ===
|
|
542
|
+
else if (typeof r == "object" && (r.$$typeof === l || // Note: Memo only checks outer props here.
|
|
543
543
|
// Inner props are checked in the reconciler.
|
|
544
|
-
r.$$typeof ===
|
|
544
|
+
r.$$typeof === b))
|
|
545
545
|
c = r.propTypes;
|
|
546
546
|
else
|
|
547
547
|
return;
|
|
548
548
|
if (c) {
|
|
549
|
-
var
|
|
550
|
-
|
|
551
|
-
} else if (r.PropTypes !== void 0 && !
|
|
552
|
-
|
|
553
|
-
var
|
|
554
|
-
|
|
549
|
+
var d = W(r);
|
|
550
|
+
qe(c, e.props, "prop", d, e);
|
|
551
|
+
} else if (r.PropTypes !== void 0 && !ue) {
|
|
552
|
+
ue = !0;
|
|
553
|
+
var R = W(r);
|
|
554
|
+
C("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", R || "Unknown");
|
|
555
555
|
}
|
|
556
|
-
typeof r.getDefaultProps == "function" && !r.getDefaultProps.isReactClassApproved &&
|
|
556
|
+
typeof r.getDefaultProps == "function" && !r.getDefaultProps.isReactClassApproved && C("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
|
|
557
557
|
}
|
|
558
558
|
}
|
|
559
|
-
function
|
|
559
|
+
function lt(e) {
|
|
560
560
|
{
|
|
561
561
|
for (var r = Object.keys(e.props), c = 0; c < r.length; c++) {
|
|
562
|
-
var
|
|
563
|
-
if (
|
|
564
|
-
z(e),
|
|
562
|
+
var d = r[c];
|
|
563
|
+
if (d !== "children" && d !== "key") {
|
|
564
|
+
z(e), C("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", d), z(null);
|
|
565
565
|
break;
|
|
566
566
|
}
|
|
567
567
|
}
|
|
568
|
-
e.ref !== null && (z(e),
|
|
568
|
+
e.ref !== null && (z(e), C("Invalid attribute `ref` supplied to `React.Fragment`."), z(null));
|
|
569
569
|
}
|
|
570
570
|
}
|
|
571
|
-
function
|
|
571
|
+
function Ie(e, r, c, d, R, S) {
|
|
572
572
|
{
|
|
573
|
-
var
|
|
574
|
-
if (!
|
|
575
|
-
var
|
|
576
|
-
(e === void 0 || typeof e == "object" && e !== null && Object.keys(e).length === 0) && (
|
|
577
|
-
var A =
|
|
578
|
-
A ?
|
|
573
|
+
var m = q(e);
|
|
574
|
+
if (!m) {
|
|
575
|
+
var h = "";
|
|
576
|
+
(e === void 0 || typeof e == "object" && e !== null && Object.keys(e).length === 0) && (h += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
|
|
577
|
+
var A = ct();
|
|
578
|
+
A ? h += A : h += ke();
|
|
579
579
|
var j;
|
|
580
|
-
e === null ? j = "null" :
|
|
580
|
+
e === null ? j = "null" : ce(e) ? j = "array" : e !== void 0 && e.$$typeof === n ? (j = "<" + (W(e.type) || "Unknown") + " />", h = " Did you accidentally export a JSX literal instead of a component?") : j = 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", j, h);
|
|
581
581
|
}
|
|
582
|
-
var
|
|
583
|
-
if (
|
|
584
|
-
return
|
|
585
|
-
if (
|
|
586
|
-
var
|
|
587
|
-
if (
|
|
588
|
-
if (
|
|
589
|
-
if (
|
|
590
|
-
for (var M = 0; M <
|
|
591
|
-
|
|
592
|
-
Object.freeze && Object.freeze(
|
|
582
|
+
var P = it(e, r, c, R, S);
|
|
583
|
+
if (P == null)
|
|
584
|
+
return P;
|
|
585
|
+
if (m) {
|
|
586
|
+
var x = r.children;
|
|
587
|
+
if (x !== void 0)
|
|
588
|
+
if (d)
|
|
589
|
+
if (ce(x)) {
|
|
590
|
+
for (var M = 0; M < x.length; M++)
|
|
591
|
+
Le(x[M], e);
|
|
592
|
+
Object.freeze && Object.freeze(x);
|
|
593
593
|
} else
|
|
594
|
-
|
|
594
|
+
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.");
|
|
595
595
|
else
|
|
596
|
-
|
|
596
|
+
Le(x, e);
|
|
597
597
|
}
|
|
598
|
-
return e ===
|
|
598
|
+
return e === o ? lt(P) : ut(P), P;
|
|
599
599
|
}
|
|
600
600
|
}
|
|
601
|
-
function lt(e, r, c) {
|
|
602
|
-
return Le(e, r, c, !0);
|
|
603
|
-
}
|
|
604
601
|
function ft(e, r, c) {
|
|
605
|
-
return
|
|
602
|
+
return Ie(e, r, c, !0);
|
|
603
|
+
}
|
|
604
|
+
function dt(e, r, c) {
|
|
605
|
+
return Ie(e, r, c, !1);
|
|
606
606
|
}
|
|
607
|
-
var
|
|
608
|
-
|
|
609
|
-
}()),
|
|
607
|
+
var vt = dt, gt = ft;
|
|
608
|
+
B.Fragment = o, B.jsx = vt, B.jsxs = gt;
|
|
609
|
+
}()), B;
|
|
610
610
|
}
|
|
611
|
-
process.env.NODE_ENV === "production" ?
|
|
612
|
-
var
|
|
613
|
-
const
|
|
614
|
-
const
|
|
611
|
+
process.env.NODE_ENV === "production" ? fe.exports = Et() : fe.exports = pt();
|
|
612
|
+
var I = fe.exports;
|
|
613
|
+
const k = yt({}), $t = ({ children: t, apiURL: n, libraries: a, localStorageKeys: o }) => {
|
|
614
|
+
const i = de(
|
|
615
615
|
() => ({
|
|
616
616
|
apiURL: n,
|
|
617
|
-
libraries:
|
|
618
|
-
localStorageKeys:
|
|
617
|
+
libraries: a,
|
|
618
|
+
localStorageKeys: o
|
|
619
619
|
}),
|
|
620
|
-
[n,
|
|
620
|
+
[n, a, o]
|
|
621
621
|
);
|
|
622
|
-
return /* @__PURE__ */
|
|
623
|
-
}, wt = "user",
|
|
624
|
-
var
|
|
625
|
-
const { libraries:
|
|
626
|
-
if (!
|
|
622
|
+
return /* @__PURE__ */ I.jsx(k.Provider, { value: i, children: t });
|
|
623
|
+
}, wt = "user", Nt = ({ Fallback: t, isLogged: n, loginPath: a = "/login", redirect401Path: o = "/login", ...i }) => {
|
|
624
|
+
var F, $, N, Y;
|
|
625
|
+
const { libraries: u, localStorageKeys: f } = D(k), v = (i == null ? void 0 : i.reactRouter) || (u == null ? void 0 : u.reactRouter), l = (i == null ? void 0 : i.axios) || (u == null ? void 0 : u.axios), y = (i == null ? void 0 : i.localStorageKey) || (f == null ? void 0 : f.user) || wt;
|
|
626
|
+
if (!v)
|
|
627
627
|
throw new Error("React Router is not provided. You can provide it with InjectDependenciesProvider or directly in props.");
|
|
628
|
-
const [g,
|
|
628
|
+
const [g, b] = Ve(null), { useLocation: p, Navigate: s, Outlet: w } = v, _ = p(), O = ht(!1), E = typeof n == "function" ? n() : !!n, C = typeof E == "boolean" ? E : E == null ? void 0 : E.isLogged;
|
|
629
629
|
return V(() => {
|
|
630
|
-
|
|
631
|
-
(
|
|
632
|
-
async (
|
|
633
|
-
var
|
|
634
|
-
return typeof
|
|
630
|
+
O.current || (O.current = !0, l.interceptors.response.use(
|
|
631
|
+
(T) => T,
|
|
632
|
+
async (T) => {
|
|
633
|
+
var q;
|
|
634
|
+
return typeof T == "object" && T && "response" in T && T.response && typeof T.response == "object" && "status" in T.response && T.response && typeof T.response == "object" && "status" in T.response && ((q = T == null ? void 0 : T.response) == null ? void 0 : q.status) === 401 && (l.defaults.headers.common.Authorization = null, typeof window < "u" && window.localStorage && localStorage.removeItem(y), b(o)), Promise.reject(T);
|
|
635
635
|
}
|
|
636
636
|
));
|
|
637
|
-
}, [
|
|
638
|
-
},
|
|
639
|
-
const { libraries:
|
|
640
|
-
if (!
|
|
637
|
+
}, [l.defaults.headers.common, l.interceptors.response, y, o]), C && !g ? /* @__PURE__ */ I.jsx(mt, { fallback: t, children: ($ = (F = _.state) == null ? void 0 : F.from) != null && $.state && ((Y = (N = _.state) == null ? void 0 : N.from) == null ? void 0 : Y.pathname) === a ? /* @__PURE__ */ I.jsx(s, { to: _.state.from.state.from.pathname + _.state.from.state.from.search, replace: !0 }) : /* @__PURE__ */ I.jsx(w, {}) }) : /* @__PURE__ */ I.jsx(s, { to: a + _.search, state: { from: _ }, replace: !0 });
|
|
638
|
+
}, Yt = ({ data: t, ...n }) => {
|
|
639
|
+
const { libraries: a } = D(k), o = (n == null ? void 0 : n.reactRouter) || (a == null ? void 0 : a.reactRouter), i = (n == null ? void 0 : n.gtm) || (a == null ? void 0 : a.gtm);
|
|
640
|
+
if (!o)
|
|
641
641
|
throw new Error(
|
|
642
642
|
"React Router is not provided. You can provide it with InjectDependenciesProvider or directly in props of GTMSendPageView."
|
|
643
643
|
);
|
|
644
|
-
if (!
|
|
644
|
+
if (!i)
|
|
645
645
|
throw new Error("GTM is not provided. You can provide it with InjectDependenciesProvider or directly in props of GTMSendPageView.");
|
|
646
|
-
const { useGoogleTagManager:
|
|
646
|
+
const { useGoogleTagManager: u } = i, { useLocation: f, Outlet: v } = o, { pathname: l } = f(), { sendEvent: y } = u();
|
|
647
647
|
return V(() => {
|
|
648
|
-
|
|
648
|
+
y({
|
|
649
649
|
event: "pageView",
|
|
650
|
-
pathname:
|
|
650
|
+
pathname: l,
|
|
651
651
|
...t
|
|
652
652
|
});
|
|
653
|
-
}, [t,
|
|
654
|
-
},
|
|
653
|
+
}, [t, l, y]), /* @__PURE__ */ I.jsx(v, {});
|
|
654
|
+
}, K = (() => {
|
|
655
|
+
try {
|
|
656
|
+
return typeof global == "object" && global !== null && ("HermesInternal" in global || // Hermes JS engine
|
|
657
|
+
"__fbBatchedBridge" in global || // RN Bridge
|
|
658
|
+
"__metro" in global) || typeof window > "u" && typeof global < "u" ? !0 : typeof navigator < "u" && navigator.userAgent ? /react.native|ReactNative/i.test(navigator.userAgent) : !1;
|
|
659
|
+
} catch {
|
|
660
|
+
return !1;
|
|
661
|
+
}
|
|
662
|
+
})(), Rt = "user", Wt = ({
|
|
655
663
|
tokenTypeKey: t = "tokenType",
|
|
656
664
|
tokenKey: n = "accessToken",
|
|
657
|
-
postContentType:
|
|
658
|
-
...
|
|
665
|
+
postContentType: a = "application/json",
|
|
666
|
+
...o
|
|
659
667
|
}) => {
|
|
660
|
-
const { apiURL:
|
|
661
|
-
if (!
|
|
668
|
+
const { apiURL: i = o.apiURL, libraries: u, localStorageKeys: f } = D(k), v = (o == null ? void 0 : o.userLocalStorageKey) || (f == null ? void 0 : f.user) || Rt, l = (o == null ? void 0 : o.axios) || (u == null ? void 0 : u.axios);
|
|
669
|
+
if (!l)
|
|
662
670
|
throw new Error("Axios is not provided. You can provide it with InjectDependenciesProvider or directly in props.");
|
|
663
|
-
if (!(
|
|
671
|
+
if (!(l != null && l.defaults) || K)
|
|
664
672
|
return null;
|
|
665
673
|
if (typeof window < "u" && window.localStorage) {
|
|
666
|
-
const
|
|
667
|
-
s && (
|
|
674
|
+
const y = localStorage.getItem(v), g = y ? JSON.parse(y) : null, b = g != null && g[t] ? g[t] : null, p = g != null && g[n] ? g[n] : null, s = y ? `${b} ${p}` : null;
|
|
675
|
+
s && (l.defaults.headers.common.Authorization = s);
|
|
668
676
|
}
|
|
669
|
-
return
|
|
670
|
-
},
|
|
671
|
-
const { libraries:
|
|
672
|
-
if (
|
|
677
|
+
return l.defaults.baseURL = i, l.defaults.headers.post["Content-Type"] = a, null;
|
|
678
|
+
}, Ut = ({ debug: t, resources: n, ...a }) => {
|
|
679
|
+
const { libraries: o } = D(k), i = (a == null ? void 0 : a.i18) || (o == null ? void 0 : o.i18), { i18next: u, initReactI18next: f, languageDetector: v } = i || {};
|
|
680
|
+
if (K)
|
|
681
|
+
return null;
|
|
682
|
+
if (!i)
|
|
673
683
|
throw new Error("i18 is not provided. You can provide it with InjectDependenciesProvider or directly in props.");
|
|
674
|
-
return
|
|
684
|
+
return u != null && u.isInitialized || (u.use(v).use(f).init({
|
|
675
685
|
debug: t,
|
|
676
686
|
fallbackLng: "en",
|
|
677
687
|
interpolation: {
|
|
@@ -685,37 +695,37 @@ const D = gt({}), Lt = ({ children: t, apiURL: n, libraries: o, localStorageKeys
|
|
|
685
695
|
resources: n,
|
|
686
696
|
returnNull: !1
|
|
687
697
|
}).then(() => {
|
|
688
|
-
document.documentElement.lang !==
|
|
689
|
-
}),
|
|
690
|
-
document.documentElement.setAttribute("lang",
|
|
698
|
+
document.documentElement.lang !== u.resolvedLanguage && u.resolvedLanguage && document.documentElement.setAttribute("lang", u.resolvedLanguage);
|
|
699
|
+
}), u.on("languageChanged", (l) => {
|
|
700
|
+
document.documentElement.setAttribute("lang", l);
|
|
691
701
|
})), null;
|
|
692
|
-
},
|
|
702
|
+
}, Vt = ({
|
|
693
703
|
dsn: t,
|
|
694
704
|
integrations: n,
|
|
695
|
-
tracesSampleRate:
|
|
696
|
-
replaysSessionSampleRate:
|
|
697
|
-
replaysOnErrorSampleRate:
|
|
698
|
-
tracePropagationTargets:
|
|
699
|
-
ignoreErrors:
|
|
700
|
-
debug:
|
|
701
|
-
environment:
|
|
702
|
-
release:
|
|
705
|
+
tracesSampleRate: a,
|
|
706
|
+
replaysSessionSampleRate: o,
|
|
707
|
+
replaysOnErrorSampleRate: i,
|
|
708
|
+
tracePropagationTargets: u,
|
|
709
|
+
ignoreErrors: f,
|
|
710
|
+
debug: v,
|
|
711
|
+
environment: l,
|
|
712
|
+
release: y,
|
|
703
713
|
...g
|
|
704
714
|
}) => {
|
|
705
|
-
const { libraries:
|
|
706
|
-
if (!
|
|
715
|
+
const { libraries: b } = D(k), p = (g == null ? void 0 : g.sentry) || (b == null ? void 0 : b.sentry), s = (g == null ? void 0 : g.reactRouter) || (b == null ? void 0 : b.reactRouter);
|
|
716
|
+
if (!p)
|
|
707
717
|
throw new Error("Sentry is not provided. You can provide it with InjectDependenciesProvider or directly in props.");
|
|
708
718
|
if (!s)
|
|
709
719
|
throw new Error("React Router is not provided. You can provide it with InjectDependenciesProvider or directly in props.");
|
|
710
|
-
if (
|
|
720
|
+
if (p.isInitialized())
|
|
711
721
|
return null;
|
|
712
|
-
const { createRoutesFromChildren:
|
|
713
|
-
return (
|
|
714
|
-
debug:
|
|
722
|
+
const { createRoutesFromChildren: w, matchRoutes: _, useLocation: O, useNavigationType: E } = s;
|
|
723
|
+
return (v || process.env.NODE_ENV === "prod" || process.env.NODE_ENV === "production") && p.init({
|
|
724
|
+
debug: v,
|
|
715
725
|
dsn: t,
|
|
716
|
-
environment:
|
|
726
|
+
environment: l || "production",
|
|
717
727
|
ignoreErrors: [
|
|
718
|
-
...
|
|
728
|
+
...f || [],
|
|
719
729
|
/dynamically imported module/,
|
|
720
730
|
/Cannot read properties of undefined \(reading 'default'\)/,
|
|
721
731
|
/Loading chunk \d+ failed/,
|
|
@@ -724,44 +734,46 @@ const D = gt({}), Lt = ({ children: t, apiURL: n, libraries: o, localStorageKeys
|
|
|
724
734
|
/vite:preloadError/
|
|
725
735
|
],
|
|
726
736
|
integrations: [
|
|
727
|
-
|
|
728
|
-
createRoutesFromChildren:
|
|
729
|
-
matchRoutes:
|
|
737
|
+
p.reactRouterV6BrowserTracingIntegration({
|
|
738
|
+
createRoutesFromChildren: w,
|
|
739
|
+
matchRoutes: _,
|
|
730
740
|
useEffect: V,
|
|
731
|
-
useLocation:
|
|
732
|
-
useNavigationType:
|
|
741
|
+
useLocation: O,
|
|
742
|
+
useNavigationType: E
|
|
733
743
|
}),
|
|
734
744
|
...n || []
|
|
735
745
|
],
|
|
736
|
-
release:
|
|
737
|
-
replaysOnErrorSampleRate:
|
|
738
|
-
replaysSessionSampleRate:
|
|
739
|
-
tracePropagationTargets:
|
|
740
|
-
tracesSampleRate:
|
|
746
|
+
release: y,
|
|
747
|
+
replaysOnErrorSampleRate: i || 1,
|
|
748
|
+
replaysSessionSampleRate: o || 0.1,
|
|
749
|
+
tracePropagationTargets: u,
|
|
750
|
+
tracesSampleRate: a || 1
|
|
741
751
|
}), null;
|
|
742
|
-
},
|
|
743
|
-
const
|
|
752
|
+
}, zt = ({ IMaskMixin: t, ...n }) => {
|
|
753
|
+
const a = de(
|
|
744
754
|
// eslint-disable-next-line react/jsx-props-no-spreading
|
|
745
|
-
() => t(({ TextField:
|
|
755
|
+
() => t(({ TextField: o, ...i }) => /* @__PURE__ */ I.jsx(o, { ...i })),
|
|
746
756
|
[t]
|
|
747
757
|
);
|
|
748
|
-
return /* @__PURE__ */
|
|
749
|
-
},
|
|
750
|
-
const { libraries:
|
|
751
|
-
if (!
|
|
758
|
+
return /* @__PURE__ */ I.jsx(a, { ...n });
|
|
759
|
+
}, Mt = ({ language: t, ...n }) => {
|
|
760
|
+
const { libraries: a } = D(k), o = (n == null ? void 0 : n.dayjs) || (a == null ? void 0 : a.dayjs), i = (n == null ? void 0 : n.plugin) || (a == null ? void 0 : a.dayjsPlugin);
|
|
761
|
+
if (!o)
|
|
752
762
|
throw new Error(
|
|
753
763
|
"Dayjs is not provided. You can provide it with InjectDependenciesProvider or directly in props of InitializeDaysJSConfig."
|
|
754
764
|
);
|
|
755
765
|
return V(() => {
|
|
756
766
|
(async () => {
|
|
757
|
-
var
|
|
758
|
-
const
|
|
759
|
-
|
|
760
|
-
|
|
761
|
-
}), await import("dayjs/locale/en"), await import("dayjs/locale/fr"),
|
|
767
|
+
var v;
|
|
768
|
+
const f = t || ((v = navigator.language) == null ? void 0 : v.slice(0, 2)) || "en";
|
|
769
|
+
i && i.forEach((l) => {
|
|
770
|
+
l && o.extend(l);
|
|
771
|
+
}), await import("dayjs/locale/en"), await import("dayjs/locale/fr"), o.locale(f);
|
|
762
772
|
})().then();
|
|
763
|
-
}, [
|
|
764
|
-
},
|
|
773
|
+
}, [o, i, t]), null;
|
|
774
|
+
}, Gt = () => (V(() => {
|
|
775
|
+
if (K)
|
|
776
|
+
return;
|
|
765
777
|
const t = (n) => {
|
|
766
778
|
try {
|
|
767
779
|
n.preventDefault(), n.stopPropagation(), n.stopImmediatePropagation(), window.location.reload();
|
|
@@ -771,294 +783,321 @@ const D = gt({}), Lt = ({ children: t, apiURL: n, libraries: o, localStorageKeys
|
|
|
771
783
|
return window.addEventListener("vite:preloadError", t), () => {
|
|
772
784
|
window.removeEventListener("vite:preloadError", t);
|
|
773
785
|
};
|
|
774
|
-
}, []), null),
|
|
786
|
+
}, []), null), _t = (t) => t && typeof t == "function", bt = (t) => t && typeof t == "function", Jt = ({
|
|
775
787
|
children: t,
|
|
776
788
|
defaultQueriesOptions: n,
|
|
777
|
-
defaultMutationsOptions:
|
|
778
|
-
...
|
|
789
|
+
defaultMutationsOptions: a,
|
|
790
|
+
...o
|
|
779
791
|
}) => {
|
|
780
|
-
var
|
|
781
|
-
const { libraries:
|
|
782
|
-
if (!
|
|
792
|
+
var l, y;
|
|
793
|
+
const { libraries: i } = D(k), u = (o == null ? void 0 : o.QueryClient) || ((l = i == null ? void 0 : i.reactQuery) == null ? void 0 : l.QueryClient), f = (o == null ? void 0 : o.QueryClientProvider) || ((y = i == null ? void 0 : i.reactQuery) == null ? void 0 : y.QueryClientProvider);
|
|
794
|
+
if (!u)
|
|
783
795
|
throw new Error("QueryClient is not provided. You can provide it with InjectDependenciesProvider or directly in props.");
|
|
784
|
-
if (!
|
|
796
|
+
if (!f)
|
|
785
797
|
throw new Error("QueryClientProvider is not provided. You can provide it with InjectDependenciesProvider or directly in props.");
|
|
786
|
-
if (!pt(l))
|
|
787
|
-
throw new Error("Provided QueryClientProvider dependencies are not valid.");
|
|
788
798
|
if (!_t(f))
|
|
799
|
+
throw new Error("Provided QueryClientProvider dependencies are not valid.");
|
|
800
|
+
if (!bt(u))
|
|
789
801
|
throw new Error("Provided QueryClient dependencies are not valid.");
|
|
790
|
-
const
|
|
802
|
+
const v = new u({
|
|
791
803
|
defaultOptions: {
|
|
792
804
|
mutations: {
|
|
793
|
-
...
|
|
805
|
+
...a
|
|
794
806
|
},
|
|
795
807
|
queries: {
|
|
796
|
-
getNextPageParam: (g,
|
|
808
|
+
getNextPageParam: (g, b, p) => g.length + (p || 0),
|
|
797
809
|
refetchOnWindowFocus: !1,
|
|
798
810
|
retry: 3,
|
|
799
811
|
...n
|
|
800
812
|
}
|
|
801
813
|
}
|
|
802
814
|
});
|
|
803
|
-
return /* @__PURE__ */
|
|
804
|
-
},
|
|
805
|
-
var
|
|
806
|
-
const { libraries: n } =
|
|
807
|
-
(
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
815
|
+
return /* @__PURE__ */ I.jsx(f, { client: v, children: t });
|
|
816
|
+
}, Bt = (t) => {
|
|
817
|
+
var y, g, b;
|
|
818
|
+
const { libraries: n } = D(k), a = (t == null ? void 0 : t.i18) || (n == null ? void 0 : n.i18), o = ((y = t == null ? void 0 : t.i18) == null ? void 0 : y.translateFunction) || ((g = n == null ? void 0 : n.i18) == null ? void 0 : g.translateFunction), i = ((b = a == null ? void 0 : a.i18next) == null ? void 0 : b.t) || o || ((p) => p), { unknownErrorTranslationKey: u = "error.unknownError" } = t || {}, f = i(u), v = re(
|
|
819
|
+
(p) => {
|
|
820
|
+
if (p && typeof p == "object" && "response" in p) {
|
|
821
|
+
const { response: s } = p || {};
|
|
822
|
+
if (s && typeof s == "object" && "reason" in s)
|
|
823
|
+
return String(s.reason);
|
|
824
|
+
if (s && typeof s == "object" && "data" in s && s.data && typeof s.data == "object" && "reason" in s.data)
|
|
825
|
+
return String(s.data.reason);
|
|
826
|
+
if (s && typeof s == "object" && "data" in s && s.data && typeof s.data == "object" && "message" in s.data)
|
|
827
|
+
return String(s.data.message);
|
|
828
|
+
if (s && typeof s == "object" && "data" in s && s.data && typeof s.data == "object" && "detail" in s.data) {
|
|
829
|
+
const { detail: w } = s.data;
|
|
830
|
+
if (Array.isArray(w) && w.length > 0 && typeof w[0] == "object" && w[0] !== null && "msg" in w[0]) {
|
|
831
|
+
const { msg: _ } = w[0];
|
|
832
|
+
if (typeof _ == "string")
|
|
833
|
+
return String(_);
|
|
834
|
+
}
|
|
835
|
+
}
|
|
836
|
+
}
|
|
837
|
+
return p instanceof Error ? p.message : f;
|
|
813
838
|
},
|
|
814
|
-
[
|
|
839
|
+
[f]
|
|
815
840
|
);
|
|
816
|
-
return { getErrorCode:
|
|
817
|
-
var
|
|
818
|
-
const { response: s } =
|
|
819
|
-
return s != null && s.error_code ? String(s == null ? void 0 : s.error_code) : (
|
|
820
|
-
}, []), printError:
|
|
821
|
-
},
|
|
841
|
+
return { getErrorCode: re((p) => {
|
|
842
|
+
var w, _, O;
|
|
843
|
+
const { response: s } = p || {};
|
|
844
|
+
return s != null && s.error_code ? String(s == null ? void 0 : s.error_code) : (w = s == null ? void 0 : s.data) != null && w.error_code ? String((_ = s == null ? void 0 : s.data) == null ? void 0 : _.error_code) : s != null && s.error_code ? String(s == null ? void 0 : s.error_code) : (O = s == null ? void 0 : s.data) != null && O.error_code ? String(s.data.error_code) : "unknown_error_code";
|
|
845
|
+
}, []), printError: v };
|
|
846
|
+
}, Kt = ({
|
|
822
847
|
data: t,
|
|
823
848
|
fetchNextPage: n,
|
|
824
|
-
isFetchingNextPage:
|
|
825
|
-
isInitialLoading:
|
|
826
|
-
isLoading:
|
|
827
|
-
enabled:
|
|
849
|
+
isFetchingNextPage: a,
|
|
850
|
+
isInitialLoading: o,
|
|
851
|
+
isLoading: i,
|
|
852
|
+
enabled: u = !0
|
|
828
853
|
}) => {
|
|
829
|
-
const
|
|
830
|
-
async (
|
|
831
|
-
|
|
854
|
+
const f = re(
|
|
855
|
+
async (l) => {
|
|
856
|
+
a || !u || await n({ pageParam: (l == null ? void 0 : l.pageParam) || l.visibleRowsCount });
|
|
832
857
|
},
|
|
833
|
-
[
|
|
834
|
-
),
|
|
858
|
+
[u, n, a]
|
|
859
|
+
), v = de(() => {
|
|
835
860
|
if (t)
|
|
836
|
-
return t.pages.reduce((
|
|
861
|
+
return t.pages.reduce((l, y) => [...l, ...y], []);
|
|
837
862
|
}, [t]);
|
|
838
863
|
return {
|
|
839
|
-
fetchNextPageOnRowsScrollEnd:
|
|
840
|
-
isLoading:
|
|
841
|
-
loadingVariant:
|
|
842
|
-
rows:
|
|
864
|
+
fetchNextPageOnRowsScrollEnd: f,
|
|
865
|
+
isLoading: a || i,
|
|
866
|
+
loadingVariant: o ? "skeleton" : "linear",
|
|
867
|
+
rows: v
|
|
843
868
|
};
|
|
844
869
|
}, qt = (t) => {
|
|
845
|
-
const { libraries: n } =
|
|
846
|
-
if (!
|
|
870
|
+
const { libraries: n } = D(k), a = (t == null ? void 0 : t.axios) || (n == null ? void 0 : n.axios), o = (t == null ? void 0 : t.localStorageKey) || "user";
|
|
871
|
+
if (!a)
|
|
847
872
|
throw new Error("Axios is not provided. You can provide it with InjectDependenciesProvider or directly in params of useAuth.");
|
|
848
|
-
const
|
|
849
|
-
({ tokenType:
|
|
850
|
-
|
|
873
|
+
const i = re(
|
|
874
|
+
({ tokenType: f, accessToken: v }) => {
|
|
875
|
+
a.defaults.headers.common.Authorization = `${f} ${v}`;
|
|
851
876
|
},
|
|
852
|
-
[
|
|
853
|
-
),
|
|
854
|
-
|
|
877
|
+
[a.defaults.headers.common]
|
|
878
|
+
), u = () => {
|
|
879
|
+
a.defaults.headers.common.Authorization = null;
|
|
855
880
|
};
|
|
856
881
|
return V(() => {
|
|
857
|
-
|
|
858
|
-
|
|
882
|
+
if (K)
|
|
883
|
+
return;
|
|
884
|
+
const f = ({ newValue: v, key: l }) => {
|
|
885
|
+
if (l === o && v)
|
|
859
886
|
try {
|
|
860
|
-
const { accessToken:
|
|
861
|
-
|
|
862
|
-
} catch (
|
|
863
|
-
console.error("Failed to parse newValue from localStorage:",
|
|
887
|
+
const { accessToken: y, tokenType: g } = JSON.parse(v);
|
|
888
|
+
i({ accessToken: y, tokenType: g });
|
|
889
|
+
} catch (y) {
|
|
890
|
+
console.error("Failed to parse newValue from localStorage:", y);
|
|
864
891
|
}
|
|
865
892
|
};
|
|
866
|
-
return window.addEventListener("storage",
|
|
867
|
-
window.removeEventListener("storage",
|
|
893
|
+
return window.addEventListener("storage", f), () => {
|
|
894
|
+
window.removeEventListener("storage", f);
|
|
868
895
|
};
|
|
869
|
-
}, [
|
|
870
|
-
clearAuthenticationToken:
|
|
871
|
-
setAuthenticationToken:
|
|
896
|
+
}, [o, i]), {
|
|
897
|
+
clearAuthenticationToken: u,
|
|
898
|
+
setAuthenticationToken: i
|
|
872
899
|
};
|
|
873
|
-
}, St = ({ library: t, date: n, format:
|
|
874
|
-
const { fractionDigits:
|
|
875
|
-
return Number.isNaN(
|
|
876
|
-
},
|
|
900
|
+
}, St = ({ library: t, date: n, format: a = "ll" }) => t(n).format(a), Ct = (t, n) => {
|
|
901
|
+
const { fractionDigits: a = 0, metric: o = "km" } = n || {}, i = Number(t);
|
|
902
|
+
return Number.isNaN(i) ? `0${o}` : `${i.toFixed(a)}${o}`;
|
|
903
|
+
}, jt = (t) => !t || typeof t != "string" ? "" : t.replace(/_/g, " ").toLowerCase().split(" ").map((a) => a.length > 0 ? a.charAt(0).toUpperCase() + a.slice(1) : a).join(" "), Pt = (t) => t != null && t.startsWith("/") ? t != null && t.startsWith("/files") ? t : `/files${t}` : t != null && t.startsWith("files") ? `/${t}` : `/files/${t}`, Tt = ({ path: t, size: n, apiURL: a }) => {
|
|
877
904
|
if (!t)
|
|
878
905
|
return "";
|
|
879
|
-
const
|
|
880
|
-
return typeof n == "number" &&
|
|
881
|
-
},
|
|
882
|
-
const { apiURL: n, libraries:
|
|
906
|
+
const o = Pt(t), i = `${a}${o}`, u = i.match(/\.(jpeg|jpg|png|gif|bmp|webp|svg|avif)$/) !== null;
|
|
907
|
+
return typeof n == "number" && u ? `${i.replace("/files", `/thumbs/${n}`)}` : i;
|
|
908
|
+
}, Qt = (t) => {
|
|
909
|
+
const { apiURL: n, libraries: a } = D(k), o = (t == null ? void 0 : t.dayjs) || (a == null ? void 0 : a.dayjs);
|
|
883
910
|
return {
|
|
884
|
-
dateAdapter: (
|
|
885
|
-
if (!
|
|
911
|
+
dateAdapter: (f, v) => {
|
|
912
|
+
if (!o)
|
|
886
913
|
throw new Error("Dayjs is not provided. You can provide it with InjectDependenciesProvider or directly in props.");
|
|
887
914
|
return St({
|
|
888
|
-
date:
|
|
889
|
-
format:
|
|
890
|
-
library:
|
|
915
|
+
date: f,
|
|
916
|
+
format: v,
|
|
917
|
+
library: o
|
|
891
918
|
});
|
|
892
919
|
},
|
|
893
920
|
distanceAdapter: Ct,
|
|
894
|
-
filePathAdapter: (
|
|
921
|
+
filePathAdapter: (f, v) => {
|
|
895
922
|
if (!n)
|
|
896
923
|
throw new Error(
|
|
897
924
|
"API URL is not provided. You can provide it with InjectDependenciesProvider or directly in props to filePathAdapter."
|
|
898
925
|
);
|
|
899
|
-
return
|
|
926
|
+
return Tt({
|
|
900
927
|
apiURL: n,
|
|
901
|
-
path:
|
|
902
|
-
size:
|
|
928
|
+
path: f,
|
|
929
|
+
size: v
|
|
903
930
|
});
|
|
904
931
|
},
|
|
905
|
-
worksiteNameAdapter:
|
|
932
|
+
worksiteNameAdapter: jt
|
|
906
933
|
};
|
|
907
|
-
},
|
|
908
|
-
const [
|
|
909
|
-
const
|
|
910
|
-
return t && "isInitialized" in t && t.isInitialized,
|
|
934
|
+
}, te = (t, n) => n === "short" ? t.split("-")[0] : t, Ht = (t, n = "full") => {
|
|
935
|
+
const [a, o] = Ve(() => {
|
|
936
|
+
const i = (t == null ? void 0 : t.language) || navigator.language;
|
|
937
|
+
return t && "isInitialized" in t && t.isInitialized, te(i, n);
|
|
911
938
|
});
|
|
912
939
|
return V(() => {
|
|
913
|
-
var
|
|
914
|
-
t && "isInitialized" in t && t.isInitialized && t.language &&
|
|
915
|
-
const
|
|
916
|
-
|
|
940
|
+
var u;
|
|
941
|
+
t && "isInitialized" in t && t.isInitialized && t.language && o(te(t.language, n));
|
|
942
|
+
const i = (f) => {
|
|
943
|
+
o(te(f, n));
|
|
917
944
|
};
|
|
918
|
-
return (
|
|
919
|
-
var
|
|
920
|
-
(
|
|
945
|
+
return (u = t == null ? void 0 : t.on) == null || u.call(t, "languageChanged", i), () => {
|
|
946
|
+
var f;
|
|
947
|
+
(f = t == null ? void 0 : t.off) == null || f.call(t, "languageChanged", i);
|
|
921
948
|
};
|
|
922
|
-
}, [t, n]),
|
|
923
|
-
},
|
|
924
|
-
|
|
925
|
-
|
|
949
|
+
}, [t, n]), a;
|
|
950
|
+
}, Ot = "tracktor.filter", At = {
|
|
951
|
+
getFilter: () => {
|
|
952
|
+
},
|
|
953
|
+
getFilters: () => ({}),
|
|
954
|
+
handleFilter: () => () => {
|
|
955
|
+
},
|
|
956
|
+
setFilter: () => {
|
|
957
|
+
}
|
|
958
|
+
}, We = (t, n, a) => `${a}_${t}=>${n}`, Xt = (t) => {
|
|
959
|
+
var p, s;
|
|
960
|
+
const { libraries: n, localStorageKeys: a } = D(k), o = (t == null ? void 0 : t.reactRouter) || (n == null ? void 0 : n.reactRouter), { pathname: i } = ((p = o == null ? void 0 : o.useLocation) == null ? void 0 : p.call(o)) ?? { pathname: "/" }, [u, f] = ((s = o == null ? void 0 : o.useSearchParams) == null ? void 0 : s.call(o)) ?? [new URLSearchParams(), () => {
|
|
961
|
+
}], v = (a == null ? void 0 : a.filter) || Ot;
|
|
962
|
+
if (K)
|
|
963
|
+
return At;
|
|
964
|
+
if (!o)
|
|
926
965
|
throw new Error(
|
|
927
966
|
"React Router is not provided. You can provide it with InjectDependenciesProvider or directly in props of GTMSendPageView."
|
|
928
967
|
);
|
|
929
|
-
const
|
|
930
|
-
const
|
|
931
|
-
if (!
|
|
932
|
-
|
|
968
|
+
const l = (w, _, O = !0) => {
|
|
969
|
+
const E = We(w, (t == null ? void 0 : t.pathname) || i, v);
|
|
970
|
+
if (!_ || Array.isArray(_) && !_.length) {
|
|
971
|
+
u.delete(w), f(u), localStorage.removeItem(E);
|
|
933
972
|
return;
|
|
934
973
|
}
|
|
935
|
-
|
|
974
|
+
O && _ && localStorage.setItem(E, JSON.stringify({ ...u, [w]: _ })), _ && (u.set(w, JSON.stringify(_)), f(u));
|
|
936
975
|
};
|
|
937
976
|
return {
|
|
938
|
-
getFilter: (
|
|
939
|
-
const
|
|
940
|
-
if (
|
|
977
|
+
getFilter: (w, _) => {
|
|
978
|
+
const O = u.get(w);
|
|
979
|
+
if (O)
|
|
941
980
|
try {
|
|
942
|
-
return JSON.parse(
|
|
981
|
+
return JSON.parse(O);
|
|
943
982
|
} catch {
|
|
944
|
-
return
|
|
983
|
+
return O;
|
|
945
984
|
}
|
|
946
|
-
const
|
|
947
|
-
if (
|
|
985
|
+
const E = We(w, (t == null ? void 0 : t.pathname) || i, v), C = localStorage.getItem(E);
|
|
986
|
+
if (C)
|
|
948
987
|
try {
|
|
949
|
-
return JSON.parse(
|
|
988
|
+
return JSON.parse(C)[w];
|
|
950
989
|
} catch {
|
|
951
990
|
}
|
|
952
|
-
return
|
|
991
|
+
return _;
|
|
953
992
|
},
|
|
954
993
|
getFilters: () => {
|
|
955
|
-
const
|
|
956
|
-
(
|
|
957
|
-
).reduce((
|
|
958
|
-
var
|
|
959
|
-
const
|
|
960
|
-
if (
|
|
961
|
-
const
|
|
962
|
-
|
|
994
|
+
const w = Object.fromEntries(u.entries()), O = Object.keys(localStorage).filter(
|
|
995
|
+
(E) => E.startsWith(v) && E.endsWith((t == null ? void 0 : t.pathname) || i)
|
|
996
|
+
).reduce((E, C) => {
|
|
997
|
+
var $, N;
|
|
998
|
+
const F = localStorage.getItem(C);
|
|
999
|
+
if (F) {
|
|
1000
|
+
const Y = JSON.parse(F), T = ($ = Object.keys(Y)) == null ? void 0 : $[0];
|
|
1001
|
+
E[T] = (N = Object.values(Y)) == null ? void 0 : N[0];
|
|
963
1002
|
}
|
|
964
|
-
return
|
|
1003
|
+
return E;
|
|
965
1004
|
}, {});
|
|
966
1005
|
return {
|
|
967
|
-
...
|
|
968
|
-
...
|
|
1006
|
+
...w,
|
|
1007
|
+
...O
|
|
969
1008
|
};
|
|
970
1009
|
},
|
|
971
|
-
handleFilter: (
|
|
972
|
-
if (
|
|
973
|
-
const
|
|
974
|
-
|
|
1010
|
+
handleFilter: (w, _) => (O, E) => {
|
|
1011
|
+
if (E || Array.isArray(E) && E.length === 0) {
|
|
1012
|
+
const C = _ || "value", F = typeof E == "object" && C in E ? E[C] : E;
|
|
1013
|
+
l(w, F);
|
|
975
1014
|
return;
|
|
976
1015
|
}
|
|
977
|
-
|
|
1016
|
+
l(w, void 0);
|
|
978
1017
|
},
|
|
979
|
-
setFilter:
|
|
1018
|
+
setFilter: l
|
|
980
1019
|
};
|
|
981
|
-
},
|
|
982
|
-
const
|
|
983
|
-
return
|
|
984
|
-
},
|
|
985
|
-
const
|
|
986
|
-
return t && typeof t == "object" && "operationId" in t && (
|
|
987
|
-
},
|
|
988
|
-
const
|
|
989
|
-
return t == null || t.forEach((
|
|
990
|
-
o
|
|
1020
|
+
}, xt = (t) => t.charAt(0).toUpperCase() + t.slice(1).toLowerCase(), kt = (t) => {
|
|
1021
|
+
const o = t.split("/").filter((i) => i.length > 0).map((i) => i.replace(/\${([^}]*)}/g, "$1").split(/[_-]/).map((l) => l.charAt(0).toUpperCase() + l.slice(1)).join("")).join("");
|
|
1022
|
+
return o.charAt(0).toLowerCase() + o.slice(1);
|
|
1023
|
+
}, Ft = (t) => (t.split("/").pop() || t).replace(/\.json$/, "").replace(/^openapi\./, ""), Dt = (t, n, a, o) => {
|
|
1024
|
+
const i = kt(n), u = xt(a), f = `${i}${u}`;
|
|
1025
|
+
return t && typeof t == "object" && "operationId" in t && (o != null && o.includes(String(t.operationId))) ? `${f}AsQuery` : f;
|
|
1026
|
+
}, Lt = (t, n) => {
|
|
1027
|
+
const a = {};
|
|
1028
|
+
return t == null || t.forEach((o) => {
|
|
1029
|
+
a[o] = {
|
|
991
1030
|
query: {
|
|
992
1031
|
useInfinite: !0,
|
|
993
1032
|
useInfiniteQueryParam: "offset",
|
|
994
1033
|
useQuery: !0
|
|
995
1034
|
}
|
|
996
1035
|
};
|
|
997
|
-
}), n == null || n.filter((
|
|
998
|
-
o
|
|
1036
|
+
}), n == null || n.filter((o) => !a[o]).forEach((o) => {
|
|
1037
|
+
a[o] = {
|
|
999
1038
|
query: {
|
|
1000
1039
|
useQuery: !0
|
|
1001
1040
|
}
|
|
1002
1041
|
};
|
|
1003
|
-
}), Object.keys(
|
|
1004
|
-
},
|
|
1005
|
-
const { output:
|
|
1042
|
+
}), Object.keys(a).length ? a : void 0;
|
|
1043
|
+
}, Zt = (t) => (Array.isArray(t) ? t : [t]).reduce((a, o) => {
|
|
1044
|
+
const { output: i, useInfiniteIds: u, useQueryIds: f, input: v = "./openapi.json" } = o || {}, l = Ft(v);
|
|
1006
1045
|
return {
|
|
1007
|
-
...
|
|
1008
|
-
[
|
|
1046
|
+
...a,
|
|
1047
|
+
[l]: {
|
|
1009
1048
|
hooks: {
|
|
1010
1049
|
afterAllFilesWrite: "prettier src/api/ --write"
|
|
1011
1050
|
},
|
|
1012
|
-
input:
|
|
1051
|
+
input: v,
|
|
1013
1052
|
output: {
|
|
1014
|
-
baseUrl:
|
|
1053
|
+
baseUrl: i == null ? void 0 : i.baseUrl,
|
|
1015
1054
|
client: "react-query",
|
|
1016
1055
|
mode: "tags-split",
|
|
1017
1056
|
override: {
|
|
1018
|
-
...((
|
|
1019
|
-
operations:
|
|
1057
|
+
...((u == null ? void 0 : u.length) || (f == null ? void 0 : f.length)) && {
|
|
1058
|
+
operations: Lt(u, f)
|
|
1020
1059
|
},
|
|
1021
|
-
header: (
|
|
1060
|
+
header: (y) => [
|
|
1022
1061
|
"Generated by orval 🍺",
|
|
1023
|
-
...
|
|
1024
|
-
...
|
|
1062
|
+
...y.title ? [y.title] : [],
|
|
1063
|
+
...y.description ? [y.description] : []
|
|
1025
1064
|
],
|
|
1026
1065
|
mutator: {
|
|
1027
1066
|
name: "axiosCustomInstance",
|
|
1028
1067
|
path: "./node_modules/@tracktor/shared-module/dist/axiosCustomInstance.ts"
|
|
1029
1068
|
},
|
|
1030
|
-
operationName: (
|
|
1069
|
+
operationName: (y, g, b) => Dt(y, g, b, f),
|
|
1031
1070
|
query: {
|
|
1032
1071
|
useQuery: !0
|
|
1033
1072
|
}
|
|
1034
1073
|
},
|
|
1035
|
-
schemas: (
|
|
1036
|
-
target: (
|
|
1037
|
-
...
|
|
1074
|
+
schemas: (i == null ? void 0 : i.schemas) || `src/api/${l}/model`,
|
|
1075
|
+
target: (i == null ? void 0 : i.target) || `src/api/${l}/services/api.ts`,
|
|
1076
|
+
...i
|
|
1038
1077
|
}
|
|
1039
1078
|
}
|
|
1040
1079
|
};
|
|
1041
1080
|
}, {});
|
|
1042
1081
|
export {
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
|
|
1053
|
-
|
|
1082
|
+
Yt as GTMSendPageView,
|
|
1083
|
+
Wt as InitializeAxiosConfig,
|
|
1084
|
+
Mt as InitializeDaysJSConfig,
|
|
1085
|
+
Ut as InitializeI18nConfig,
|
|
1086
|
+
Vt as InitializeSentryConfig,
|
|
1087
|
+
k as InjectDependenciesContext,
|
|
1088
|
+
$t as InjectDependenciesProvider,
|
|
1089
|
+
zt as MaskTextField,
|
|
1090
|
+
Gt as PreloadErrorHandler,
|
|
1091
|
+
Jt as QueryClientProviderWithConfig,
|
|
1092
|
+
Nt as RequireAuth,
|
|
1054
1093
|
St as dateAdapter,
|
|
1055
1094
|
Ct as distanceAdapter,
|
|
1056
|
-
|
|
1057
|
-
|
|
1095
|
+
Zt as getOrvalConfig,
|
|
1096
|
+
Qt as useAdapter,
|
|
1058
1097
|
qt as useAuth,
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
1098
|
+
Ht as useCurrentLanguage,
|
|
1099
|
+
Xt as useFilters,
|
|
1100
|
+
Kt as useInfiniteDataGrid,
|
|
1101
|
+
Bt as useResponseError,
|
|
1102
|
+
jt as worksiteNameAdapter
|
|
1064
1103
|
};
|