@odynn/awayz-core 0.4.3 → 0.4.5
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/dist/{AccountService-CR5oZ1Bu.js → AccountService-DdcBI9BS.js} +134 -134
- package/dist/{TripsService-zpli8uBM.js → TripsService-CLvs14Rq.js} +1 -1
- package/dist/components/CashValue/CashValue.js +1 -1
- package/dist/components/CashValue/CashValue.stories.js +1 -1
- package/dist/components/Wallet/Card/Card.stories.js +1 -1
- package/dist/hooks/useAwayzAuth/useAwayzAuth.js +1 -1
- package/dist/hooks/useBookingManagement/useBookingManagement.js +1 -1
- package/dist/hooks/useBookingManagement/useBookingManagement.test.js +1 -1
- package/dist/hooks/useSearchLimit.js +1 -1
- package/dist/hooks/useTripManagement/useTripManagement.js +2 -2
- package/dist/hooks/useTripManagement/useTripManagement.test.js +2 -2
- package/dist/hooks/useWallet/useWallet.js +40 -38
- package/dist/hooks/useWallet/useWallet.test.js +1 -1
- package/dist/main.js +1 -1
- package/dist/providers/AwayzProvider.js +1 -1
- package/dist/services/account/AccountService.js +1 -1
- package/dist/services/bookings/BookingService.js +1 -1
- package/dist/services/currency/CurrencyService.js +1 -1
- package/dist/services/index.js +1 -1
- package/dist/services/instance.js +1 -1
- package/dist/services/instanceConfig.js +1 -1
- package/dist/services/noRetryInstance.js +1 -1
- package/dist/services/preferences/PreferencesService.js +1 -1
- package/dist/services/rewards/RewardsService.js +1 -1
- package/dist/services/trips/TripsService.js +2 -2
- package/dist/services/wallet/WalletService.js +1 -1
- package/package.json +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
var lt = Object.defineProperty;
|
|
2
2
|
var ft = (e, t, n) => t in e ? lt(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
|
|
3
|
-
var
|
|
3
|
+
var x = (e, t, n) => ft(e, typeof t != "symbol" ? t + "" : t, n);
|
|
4
4
|
import "./arrayExtensions-DlcBOj5a.js";
|
|
5
5
|
import "react";
|
|
6
6
|
import { getBaseUrl as qe } from "./configs/baseUrl.js";
|
|
@@ -23,34 +23,34 @@ const ge = (e) => Array.isArray(e) ? e.map((t) => ge(t)) : typeof e == "object"
|
|
|
23
23
|
}, {}) : e, lr = (e) => (Object.keys(e).forEach(
|
|
24
24
|
(t) => !e[t] && delete e[t]
|
|
25
25
|
), e);
|
|
26
|
-
var $ = /* @__PURE__ */ ((e) => (e.LOCATIONS = "LOCATIONS", e.CHECK_USER = "CHECK_USER", e.USER_REGIONS = "USER_REGIONS", e.CONVERT_CURRENCY = "CONVERT_CURRENCY", e.CLIENT_COMPONENT_KEY = "CLIENT_COMPONENT_KEY", e.SEARCH_LIMIT = "SEARCH_LIMIT", e.PROGRAMS = "PROGRAMS", e.USER_PROGRAMS = "USER_PROGRAMS", e.BANKS = "BANKS", e.CARDS = "CARDS", e.USER_CARDS = "USER_CARDS", e.TRIPS = "TRIPS", e.UNCATEGORISED_BOOKINGS = "UNCATEGORISED_BOOKINGS", e.BOOKING = "BOOKING", e.VALUE_CENTS = "VALUE_CENTS", e))($ || {}), mt = /* @__PURE__ */ ((e) => (e.HOTEL = "Hotel", e.AIRLINE = "Airline", e.BANK = "Bank", e))(mt || {}),
|
|
27
|
-
function
|
|
26
|
+
var $ = /* @__PURE__ */ ((e) => (e.LOCATIONS = "LOCATIONS", e.CHECK_USER = "CHECK_USER", e.USER_REGIONS = "USER_REGIONS", e.CONVERT_CURRENCY = "CONVERT_CURRENCY", e.CLIENT_COMPONENT_KEY = "CLIENT_COMPONENT_KEY", e.SEARCH_LIMIT = "SEARCH_LIMIT", e.PROGRAMS = "PROGRAMS", e.USER_PROGRAMS = "USER_PROGRAMS", e.LINKED_USER_PROGRAMS = "LINKED_USER_PROGRAMS", e.BANKS = "BANKS", e.CARDS = "CARDS", e.USER_CARDS = "USER_CARDS", e.TRIPS = "TRIPS", e.UNCATEGORISED_BOOKINGS = "UNCATEGORISED_BOOKINGS", e.BOOKING = "BOOKING", e.VALUE_CENTS = "VALUE_CENTS", e))($ || {}), mt = /* @__PURE__ */ ((e) => (e.HOTEL = "Hotel", e.AIRLINE = "Airline", e.BANK = "Bank", e))(mt || {}), P = /* @__PURE__ */ ((e) => (e.TOKEN = "token", e.REFRESH_TOKEN = "refreshToken", e.CLIENT_ID = "clientId", e.AUTH_FLOW = "authFlow", e))(P || {});
|
|
27
|
+
function Me(e, t) {
|
|
28
28
|
return function() {
|
|
29
29
|
return e.apply(t, arguments);
|
|
30
30
|
};
|
|
31
31
|
}
|
|
32
|
-
const { toString: Et } = Object.prototype, { getPrototypeOf: ye } = Object, { iterator: te, toStringTag:
|
|
32
|
+
const { toString: Et } = Object.prototype, { getPrototypeOf: ye } = Object, { iterator: te, toStringTag: He } = Symbol, ne = /* @__PURE__ */ ((e) => (t) => {
|
|
33
33
|
const n = Et.call(t);
|
|
34
34
|
return e[n] || (e[n] = n.slice(8, -1).toLowerCase());
|
|
35
|
-
})(/* @__PURE__ */ Object.create(null)),
|
|
35
|
+
})(/* @__PURE__ */ Object.create(null)), U = (e) => (e = e.toLowerCase(), (t) => ne(t) === e), re = (e) => (t) => typeof t === e, { isArray: j } = Array, v = re("undefined");
|
|
36
36
|
function yt(e) {
|
|
37
37
|
return e !== null && !v(e) && e.constructor !== null && !v(e.constructor) && _(e.constructor.isBuffer) && e.constructor.isBuffer(e);
|
|
38
38
|
}
|
|
39
|
-
const je =
|
|
40
|
-
function
|
|
39
|
+
const je = U("ArrayBuffer");
|
|
40
|
+
function Rt(e) {
|
|
41
41
|
let t;
|
|
42
42
|
return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? t = ArrayBuffer.isView(e) : t = e && e.buffer && je(e.buffer), t;
|
|
43
43
|
}
|
|
44
|
-
const
|
|
44
|
+
const wt = re("string"), _ = re("function"), ze = re("number"), se = (e) => e !== null && typeof e == "object", St = (e) => e === !0 || e === !1, X = (e) => {
|
|
45
45
|
if (ne(e) !== "object")
|
|
46
46
|
return !1;
|
|
47
47
|
const t = ye(e);
|
|
48
|
-
return (t === null || t === Object.prototype || Object.getPrototypeOf(t) === null) && !(
|
|
49
|
-
}, gt =
|
|
48
|
+
return (t === null || t === Object.prototype || Object.getPrototypeOf(t) === null) && !(He in e) && !(te in e);
|
|
49
|
+
}, gt = U("Date"), bt = U("File"), Tt = U("Blob"), Ot = U("FileList"), At = (e) => se(e) && _(e.pipe), _t = (e) => {
|
|
50
50
|
let t;
|
|
51
51
|
return e && (typeof FormData == "function" && e instanceof FormData || _(e.append) && ((t = ne(e)) === "formdata" || // detect form-data instance
|
|
52
52
|
t === "object" && _(e.toString) && e.toString() === "[object FormData]"));
|
|
53
|
-
}, Nt =
|
|
53
|
+
}, Nt = U("URLSearchParams"), [Ct, Ut, xt, kt] = ["ReadableStream", "Request", "Response", "Headers"].map(U), Pt = (e) => e.trim ? e.trim() : e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
|
|
54
54
|
function G(e, t, { allOwnKeys: n = !1 } = {}) {
|
|
55
55
|
if (e === null || typeof e > "u")
|
|
56
56
|
return;
|
|
@@ -84,8 +84,8 @@ function fe() {
|
|
|
84
84
|
arguments[r] && G(arguments[r], n);
|
|
85
85
|
return t;
|
|
86
86
|
}
|
|
87
|
-
const
|
|
88
|
-
n && _(s) ? e[o] =
|
|
87
|
+
const Ft = (e, t, n, { allOwnKeys: r } = {}) => (G(t, (s, o) => {
|
|
88
|
+
n && _(s) ? e[o] = Me(s, n) : e[o] = s;
|
|
89
89
|
}, { allOwnKeys: r }), e), It = (e) => (e.charCodeAt(0) === 65279 && (e = e.slice(1)), e), Lt = (e, t, n, r) => {
|
|
90
90
|
e.prototype = Object.create(t.prototype, r), e.prototype.constructor = e, Object.defineProperty(e, "super", {
|
|
91
91
|
value: t.prototype
|
|
@@ -113,7 +113,7 @@ const Pt = (e, t, n, { allOwnKeys: r } = {}) => (G(t, (s, o) => {
|
|
|
113
113
|
for (; t-- > 0; )
|
|
114
114
|
n[t] = e[t];
|
|
115
115
|
return n;
|
|
116
|
-
},
|
|
116
|
+
}, Mt = /* @__PURE__ */ ((e) => (t) => e && t instanceof e)(typeof Uint8Array < "u" && ye(Uint8Array)), Ht = (e, t) => {
|
|
117
117
|
const r = (e && e[te]).call(e);
|
|
118
118
|
let s;
|
|
119
119
|
for (; (s = r.next()) && !s.done; ) {
|
|
@@ -126,12 +126,12 @@ const Pt = (e, t, n, { allOwnKeys: r } = {}) => (G(t, (s, o) => {
|
|
|
126
126
|
for (; (n = e.exec(t)) !== null; )
|
|
127
127
|
r.push(n);
|
|
128
128
|
return r;
|
|
129
|
-
}, zt =
|
|
129
|
+
}, zt = U("HTMLFormElement"), Kt = (e) => e.toLowerCase().replace(
|
|
130
130
|
/[-_\s]([a-z\d])(\w*)/g,
|
|
131
131
|
function(n, r, s) {
|
|
132
132
|
return r.toUpperCase() + s;
|
|
133
133
|
}
|
|
134
|
-
), be = (({ hasOwnProperty: e }) => (t, n) => e.call(t, n))(Object.prototype), $t =
|
|
134
|
+
), be = (({ hasOwnProperty: e }) => (t, n) => e.call(t, n))(Object.prototype), $t = U("RegExp"), ve = (e, t) => {
|
|
135
135
|
const n = Object.getOwnPropertyDescriptors(e), r = {};
|
|
136
136
|
G(n, (s, o) => {
|
|
137
137
|
let i;
|
|
@@ -162,7 +162,7 @@ const Pt = (e, t, n, { allOwnKeys: r } = {}) => (G(t, (s, o) => {
|
|
|
162
162
|
}, Jt = () => {
|
|
163
163
|
}, Vt = (e, t) => e != null && Number.isFinite(e = +e) ? e : t;
|
|
164
164
|
function Wt(e) {
|
|
165
|
-
return !!(e && _(e.append) && e[
|
|
165
|
+
return !!(e && _(e.append) && e[He] === "FormData" && e[te]);
|
|
166
166
|
}
|
|
167
167
|
const Xt = (e) => {
|
|
168
168
|
const t = new Array(10), n = (r, s) => {
|
|
@@ -181,7 +181,7 @@ const Xt = (e) => {
|
|
|
181
181
|
return r;
|
|
182
182
|
};
|
|
183
183
|
return n(e, 0);
|
|
184
|
-
}, Yt =
|
|
184
|
+
}, Yt = U("AsyncFunction"), Zt = (e) => e && (se(e) || _(e)) && _(e.then) && _(e.catch), Ge = ((e, t) => e ? setImmediate : t ? ((n, r) => (q.addEventListener("message", ({ source: s, data: o }) => {
|
|
185
185
|
s === q && o === n && r.length && r.shift()();
|
|
186
186
|
}, !1), (s) => {
|
|
187
187
|
r.push(s), q.postMessage(n, "*");
|
|
@@ -193,15 +193,15 @@ const Xt = (e) => {
|
|
|
193
193
|
isArrayBuffer: je,
|
|
194
194
|
isBuffer: yt,
|
|
195
195
|
isFormData: _t,
|
|
196
|
-
isArrayBufferView:
|
|
197
|
-
isString:
|
|
196
|
+
isArrayBufferView: Rt,
|
|
197
|
+
isString: wt,
|
|
198
198
|
isNumber: ze,
|
|
199
199
|
isBoolean: St,
|
|
200
200
|
isObject: se,
|
|
201
201
|
isPlainObject: X,
|
|
202
202
|
isReadableStream: Ct,
|
|
203
|
-
isRequest:
|
|
204
|
-
isResponse:
|
|
203
|
+
isRequest: Ut,
|
|
204
|
+
isResponse: xt,
|
|
205
205
|
isHeaders: kt,
|
|
206
206
|
isUndefined: v,
|
|
207
207
|
isDate: gt,
|
|
@@ -211,20 +211,20 @@ const Xt = (e) => {
|
|
|
211
211
|
isFunction: _,
|
|
212
212
|
isStream: At,
|
|
213
213
|
isURLSearchParams: Nt,
|
|
214
|
-
isTypedArray:
|
|
214
|
+
isTypedArray: Mt,
|
|
215
215
|
isFileList: Ot,
|
|
216
216
|
forEach: G,
|
|
217
217
|
merge: fe,
|
|
218
|
-
extend:
|
|
219
|
-
trim:
|
|
218
|
+
extend: Ft,
|
|
219
|
+
trim: Pt,
|
|
220
220
|
stripBOM: It,
|
|
221
221
|
inherits: Lt,
|
|
222
222
|
toFlatObject: Dt,
|
|
223
223
|
kindOf: ne,
|
|
224
|
-
kindOfTest:
|
|
224
|
+
kindOfTest: U,
|
|
225
225
|
endsWith: Bt,
|
|
226
226
|
toArray: qt,
|
|
227
|
-
forEachEntry:
|
|
227
|
+
forEachEntry: Ht,
|
|
228
228
|
matchAll: jt,
|
|
229
229
|
isHTMLForm: zt,
|
|
230
230
|
hasOwnProperty: be,
|
|
@@ -337,15 +337,15 @@ function oe(e, t, n) {
|
|
|
337
337
|
return a.isArrayBuffer(h) || a.isTypedArray(h) ? f && typeof Blob == "function" ? new Blob([h]) : Buffer.from(h) : h;
|
|
338
338
|
}
|
|
339
339
|
function l(h, m, p) {
|
|
340
|
-
let
|
|
340
|
+
let w = h;
|
|
341
341
|
if (h && !p && typeof h == "object") {
|
|
342
342
|
if (a.endsWith(m, "{}"))
|
|
343
343
|
m = r ? m : m.slice(0, -2), h = JSON.stringify(h);
|
|
344
|
-
else if (a.isArray(h) && nn(h) || (a.isFileList(h) || a.endsWith(m, "[]")) && (
|
|
345
|
-
return m = We(m),
|
|
344
|
+
else if (a.isArray(h) && nn(h) || (a.isFileList(h) || a.endsWith(m, "[]")) && (w = a.toArray(h)))
|
|
345
|
+
return m = We(m), w.forEach(function(b, F) {
|
|
346
346
|
!(a.isUndefined(b) || b === null) && t.append(
|
|
347
347
|
// eslint-disable-next-line no-nested-ternary
|
|
348
|
-
i === !0 ? Te([m],
|
|
348
|
+
i === !0 ? Te([m], F, o) : i === null ? m : m + "[]",
|
|
349
349
|
u(b)
|
|
350
350
|
);
|
|
351
351
|
}), !1;
|
|
@@ -357,24 +357,24 @@ function oe(e, t, n) {
|
|
|
357
357
|
convertValue: u,
|
|
358
358
|
isVisitable: de
|
|
359
359
|
});
|
|
360
|
-
function
|
|
360
|
+
function R(h, m) {
|
|
361
361
|
if (!a.isUndefined(h)) {
|
|
362
362
|
if (d.indexOf(h) !== -1)
|
|
363
363
|
throw Error("Circular reference detected in " + m.join("."));
|
|
364
|
-
d.push(h), a.forEach(h, function(
|
|
365
|
-
(!(a.isUndefined(
|
|
364
|
+
d.push(h), a.forEach(h, function(w, g) {
|
|
365
|
+
(!(a.isUndefined(w) || w === null) && s.call(
|
|
366
366
|
t,
|
|
367
|
-
|
|
367
|
+
w,
|
|
368
368
|
a.isString(g) ? g.trim() : g,
|
|
369
369
|
m,
|
|
370
370
|
y
|
|
371
|
-
)) === !0 && w
|
|
371
|
+
)) === !0 && R(w, m ? m.concat(g) : [g]);
|
|
372
372
|
}), d.pop();
|
|
373
373
|
}
|
|
374
374
|
}
|
|
375
375
|
if (!a.isObject(e))
|
|
376
376
|
throw new TypeError("data must be an object");
|
|
377
|
-
return
|
|
377
|
+
return R(e), t;
|
|
378
378
|
}
|
|
379
379
|
function Oe(e) {
|
|
380
380
|
const t = {
|
|
@@ -390,10 +390,10 @@ function Oe(e) {
|
|
|
390
390
|
return t[r];
|
|
391
391
|
});
|
|
392
392
|
}
|
|
393
|
-
function
|
|
393
|
+
function Re(e, t) {
|
|
394
394
|
this._pairs = [], e && oe(e, this, t);
|
|
395
395
|
}
|
|
396
|
-
const Xe =
|
|
396
|
+
const Xe = Re.prototype;
|
|
397
397
|
Xe.append = function(t, n) {
|
|
398
398
|
this._pairs.push([t, n]);
|
|
399
399
|
};
|
|
@@ -417,7 +417,7 @@ function Ye(e, t, n) {
|
|
|
417
417
|
});
|
|
418
418
|
const s = n && n.serialize;
|
|
419
419
|
let o;
|
|
420
|
-
if (s ? o = s(t, n) : o = a.isURLSearchParams(t) ? t.toString() : new
|
|
420
|
+
if (s ? o = s(t, n) : o = a.isURLSearchParams(t) ? t.toString() : new Re(t, n).toString(r), o) {
|
|
421
421
|
const i = e.indexOf("#");
|
|
422
422
|
i !== -1 && (e = e.slice(0, i)), e += (e.indexOf("?") === -1 ? "?" : "&") + o;
|
|
423
423
|
}
|
|
@@ -481,7 +481,7 @@ const Ze = {
|
|
|
481
481
|
silentJSONParsing: !0,
|
|
482
482
|
forcedJSONParsing: !0,
|
|
483
483
|
clarifyTimeoutError: !1
|
|
484
|
-
}, on = typeof URLSearchParams < "u" ? URLSearchParams :
|
|
484
|
+
}, on = typeof URLSearchParams < "u" ? URLSearchParams : Re, an = typeof FormData < "u" ? FormData : null, cn = typeof Blob < "u" ? Blob : null, un = {
|
|
485
485
|
isBrowser: !0,
|
|
486
486
|
classes: {
|
|
487
487
|
URLSearchParams: on,
|
|
@@ -489,10 +489,10 @@ const Ze = {
|
|
|
489
489
|
Blob: cn
|
|
490
490
|
},
|
|
491
491
|
protocols: ["http", "https", "file", "blob", "url", "data"]
|
|
492
|
-
},
|
|
493
|
-
self instanceof WorkerGlobalScope && typeof self.importScripts == "function", dn =
|
|
492
|
+
}, we = typeof window < "u" && typeof document < "u", pe = typeof navigator == "object" && navigator || void 0, ln = we && (!pe || ["ReactNative", "NativeScript", "NS"].indexOf(pe.product) < 0), fn = typeof WorkerGlobalScope < "u" && // eslint-disable-next-line no-undef
|
|
493
|
+
self instanceof WorkerGlobalScope && typeof self.importScripts == "function", dn = we && window.location.href || "http://localhost", pn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
494
494
|
__proto__: null,
|
|
495
|
-
hasBrowserEnv:
|
|
495
|
+
hasBrowserEnv: we,
|
|
496
496
|
hasStandardBrowserEnv: ln,
|
|
497
497
|
hasStandardBrowserWebWorkerEnv: fn,
|
|
498
498
|
navigator: pe,
|
|
@@ -614,7 +614,7 @@ const J = {
|
|
|
614
614
|
a.forEach(["delete", "get", "head", "post", "put", "patch"], (e) => {
|
|
615
615
|
J.headers[e] = {};
|
|
616
616
|
});
|
|
617
|
-
const
|
|
617
|
+
const Rn = a.toObjectSet([
|
|
618
618
|
"age",
|
|
619
619
|
"authorization",
|
|
620
620
|
"content-length",
|
|
@@ -632,12 +632,12 @@ const wn = a.toObjectSet([
|
|
|
632
632
|
"referer",
|
|
633
633
|
"retry-after",
|
|
634
634
|
"user-agent"
|
|
635
|
-
]),
|
|
635
|
+
]), wn = (e) => {
|
|
636
636
|
const t = {};
|
|
637
637
|
let n, r, s;
|
|
638
638
|
return e && e.split(`
|
|
639
639
|
`).forEach(function(i) {
|
|
640
|
-
s = i.indexOf(":"), n = i.substring(0, s).trim().toLowerCase(), r = i.substring(s + 1).trim(), !(!n || t[n] &&
|
|
640
|
+
s = i.indexOf(":"), n = i.substring(0, s).trim().toLowerCase(), r = i.substring(s + 1).trim(), !(!n || t[n] && Rn[n]) && (n === "set-cookie" ? t[n] ? t[n].push(r) : t[n] = [r] : t[n] = t[n] ? t[n] + ", " + r : r);
|
|
641
641
|
}), t;
|
|
642
642
|
}, _e = Symbol("internals");
|
|
643
643
|
function K(e) {
|
|
@@ -695,7 +695,7 @@ let N = class {
|
|
|
695
695
|
if (a.isPlainObject(t) || t instanceof this.constructor)
|
|
696
696
|
i(t, n);
|
|
697
697
|
else if (a.isString(t) && (t = t.trim()) && !gn(t))
|
|
698
|
-
i(
|
|
698
|
+
i(wn(t), n);
|
|
699
699
|
else if (a.isObject(t) && a.isIterable(t)) {
|
|
700
700
|
let c = {}, f, u;
|
|
701
701
|
for (const l of t) {
|
|
@@ -857,8 +857,8 @@ function An(e, t) {
|
|
|
857
857
|
y += n[d++], d = d % e;
|
|
858
858
|
if (s = (s + 1) % e, s === o && (o = (o + 1) % e), u - i < t)
|
|
859
859
|
return;
|
|
860
|
-
const
|
|
861
|
-
return
|
|
860
|
+
const R = l && u - l;
|
|
861
|
+
return R ? Math.round(y * 1e3 / R) : void 0;
|
|
862
862
|
};
|
|
863
863
|
}
|
|
864
864
|
function _n(e, t) {
|
|
@@ -929,18 +929,18 @@ const Q = (e, t, n = 3) => {
|
|
|
929
929
|
}
|
|
930
930
|
}
|
|
931
931
|
);
|
|
932
|
-
function
|
|
932
|
+
function Un(e) {
|
|
933
933
|
return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(e);
|
|
934
934
|
}
|
|
935
|
-
function
|
|
935
|
+
function xn(e, t) {
|
|
936
936
|
return t ? e.replace(/\/?\/$/, "") + "/" + t.replace(/^\/+/, "") : e;
|
|
937
937
|
}
|
|
938
938
|
function nt(e, t, n) {
|
|
939
|
-
let r = !
|
|
940
|
-
return e && (r || n == !1) ?
|
|
939
|
+
let r = !Un(t);
|
|
940
|
+
return e && (r || n == !1) ? xn(e, t) : t;
|
|
941
941
|
}
|
|
942
|
-
const
|
|
943
|
-
function
|
|
942
|
+
const Ue = (e) => e instanceof N ? { ...e } : e;
|
|
943
|
+
function H(e, t) {
|
|
944
944
|
t = t || {};
|
|
945
945
|
const n = {};
|
|
946
946
|
function r(u, l, d, y) {
|
|
@@ -997,7 +997,7 @@ function M(e, t) {
|
|
|
997
997
|
socketPath: i,
|
|
998
998
|
responseEncoding: i,
|
|
999
999
|
validateStatus: c,
|
|
1000
|
-
headers: (u, l, d) => s(
|
|
1000
|
+
headers: (u, l, d) => s(Ue(u), Ue(l), d, !0)
|
|
1001
1001
|
};
|
|
1002
1002
|
return a.forEach(Object.keys(Object.assign({}, e, t)), function(l) {
|
|
1003
1003
|
const d = f[l] || s, y = d(e[l], t[l], l);
|
|
@@ -1005,7 +1005,7 @@ function M(e, t) {
|
|
|
1005
1005
|
}), n;
|
|
1006
1006
|
}
|
|
1007
1007
|
const rt = (e) => {
|
|
1008
|
-
const t =
|
|
1008
|
+
const t = H({}, e);
|
|
1009
1009
|
let { data: n, withXSRFToken: r, xsrfHeaderName: s, xsrfCookieName: o, headers: i, auth: c } = t;
|
|
1010
1010
|
t.headers = i = N.from(i), t.url = Ye(nt(t.baseURL, t.url, t.allowAbsoluteUrls), e.params, e.paramsSerializer), c && i.set(
|
|
1011
1011
|
"Authorization",
|
|
@@ -1025,18 +1025,18 @@ const rt = (e) => {
|
|
|
1025
1025
|
u && i.set(s, u);
|
|
1026
1026
|
}
|
|
1027
1027
|
return t;
|
|
1028
|
-
}, kn = typeof XMLHttpRequest < "u",
|
|
1028
|
+
}, kn = typeof XMLHttpRequest < "u", Pn = kn && function(e) {
|
|
1029
1029
|
return new Promise(function(n, r) {
|
|
1030
1030
|
const s = rt(e);
|
|
1031
1031
|
let o = s.data;
|
|
1032
1032
|
const i = N.from(s.headers).normalize();
|
|
1033
|
-
let { responseType: c, onUploadProgress: f, onDownloadProgress: u } = s, l, d, y,
|
|
1033
|
+
let { responseType: c, onUploadProgress: f, onDownloadProgress: u } = s, l, d, y, R, h;
|
|
1034
1034
|
function m() {
|
|
1035
|
-
|
|
1035
|
+
R && R(), h && h(), s.cancelToken && s.cancelToken.unsubscribe(l), s.signal && s.signal.removeEventListener("abort", l);
|
|
1036
1036
|
}
|
|
1037
1037
|
let p = new XMLHttpRequest();
|
|
1038
1038
|
p.open(s.method.toUpperCase(), s.url, !0), p.timeout = s.timeout;
|
|
1039
|
-
function
|
|
1039
|
+
function w() {
|
|
1040
1040
|
if (!p)
|
|
1041
1041
|
return;
|
|
1042
1042
|
const b = N.from(
|
|
@@ -1055,24 +1055,24 @@ const rt = (e) => {
|
|
|
1055
1055
|
r(D), m();
|
|
1056
1056
|
}, A), p = null;
|
|
1057
1057
|
}
|
|
1058
|
-
"onloadend" in p ? p.onloadend =
|
|
1059
|
-
!p || p.readyState !== 4 || p.status === 0 && !(p.responseURL && p.responseURL.indexOf("file:") === 0) || setTimeout(
|
|
1058
|
+
"onloadend" in p ? p.onloadend = w : p.onreadystatechange = function() {
|
|
1059
|
+
!p || p.readyState !== 4 || p.status === 0 && !(p.responseURL && p.responseURL.indexOf("file:") === 0) || setTimeout(w);
|
|
1060
1060
|
}, p.onabort = function() {
|
|
1061
1061
|
p && (r(new E("Request aborted", E.ECONNABORTED, e, p)), p = null);
|
|
1062
1062
|
}, p.onerror = function() {
|
|
1063
1063
|
r(new E("Network Error", E.ERR_NETWORK, e, p)), p = null;
|
|
1064
1064
|
}, p.ontimeout = function() {
|
|
1065
|
-
let
|
|
1065
|
+
let F = s.timeout ? "timeout of " + s.timeout + "ms exceeded" : "timeout exceeded";
|
|
1066
1066
|
const A = s.transitional || Ze;
|
|
1067
|
-
s.timeoutErrorMessage && (
|
|
1068
|
-
|
|
1067
|
+
s.timeoutErrorMessage && (F = s.timeoutErrorMessage), r(new E(
|
|
1068
|
+
F,
|
|
1069
1069
|
A.clarifyTimeoutError ? E.ETIMEDOUT : E.ECONNABORTED,
|
|
1070
1070
|
e,
|
|
1071
1071
|
p
|
|
1072
1072
|
)), p = null;
|
|
1073
|
-
}, o === void 0 && i.setContentType(null), "setRequestHeader" in p && a.forEach(i.toJSON(), function(
|
|
1074
|
-
p.setRequestHeader(A,
|
|
1075
|
-
}), a.isUndefined(s.withCredentials) || (p.withCredentials = !!s.withCredentials), c && c !== "json" && (p.responseType = s.responseType), u && ([y, h] = Q(u, !0), p.addEventListener("progress", y)), f && p.upload && ([d,
|
|
1073
|
+
}, o === void 0 && i.setContentType(null), "setRequestHeader" in p && a.forEach(i.toJSON(), function(F, A) {
|
|
1074
|
+
p.setRequestHeader(A, F);
|
|
1075
|
+
}), a.isUndefined(s.withCredentials) || (p.withCredentials = !!s.withCredentials), c && c !== "json" && (p.responseType = s.responseType), u && ([y, h] = Q(u, !0), p.addEventListener("progress", y)), f && p.upload && ([d, R] = Q(f), p.upload.addEventListener("progress", d), p.upload.addEventListener("loadend", R)), (s.cancelToken || s.signal) && (l = (b) => {
|
|
1076
1076
|
p && (r(!b || b.type ? new z(null, e, p) : b), p.abort(), p = null);
|
|
1077
1077
|
}, s.cancelToken && s.cancelToken.subscribe(l), s.signal && (s.signal.aborted ? l() : s.signal.addEventListener("abort", l)));
|
|
1078
1078
|
const g = On(s.url);
|
|
@@ -1082,7 +1082,7 @@ const rt = (e) => {
|
|
|
1082
1082
|
}
|
|
1083
1083
|
p.send(o || null);
|
|
1084
1084
|
});
|
|
1085
|
-
},
|
|
1085
|
+
}, Fn = (e, t) => {
|
|
1086
1086
|
const { length: n } = e = e ? e.filter(Boolean) : [];
|
|
1087
1087
|
if (t || n) {
|
|
1088
1088
|
let r = new AbortController(), s;
|
|
@@ -1133,7 +1133,7 @@ const rt = (e) => {
|
|
|
1133
1133
|
} finally {
|
|
1134
1134
|
await t.cancel();
|
|
1135
1135
|
}
|
|
1136
|
-
},
|
|
1136
|
+
}, xe = (e, t, n, r) => {
|
|
1137
1137
|
const s = Ln(e, t);
|
|
1138
1138
|
let o = 0, i, c = (f) => {
|
|
1139
1139
|
i || (i = !0, r && r(f));
|
|
@@ -1188,7 +1188,7 @@ ie && ((e) => {
|
|
|
1188
1188
|
});
|
|
1189
1189
|
});
|
|
1190
1190
|
})(new Response());
|
|
1191
|
-
const
|
|
1191
|
+
const Mn = async (e) => {
|
|
1192
1192
|
if (e == null)
|
|
1193
1193
|
return 0;
|
|
1194
1194
|
if (a.isBlob(e))
|
|
@@ -1202,9 +1202,9 @@ const Hn = async (e) => {
|
|
|
1202
1202
|
return e.byteLength;
|
|
1203
1203
|
if (a.isURLSearchParams(e) && (e = e + ""), a.isString(e))
|
|
1204
1204
|
return (await Bn(e)).byteLength;
|
|
1205
|
-
},
|
|
1205
|
+
}, Hn = async (e, t) => {
|
|
1206
1206
|
const n = a.toFiniteNumber(e.getContentLength());
|
|
1207
|
-
return n ??
|
|
1207
|
+
return n ?? Mn(t);
|
|
1208
1208
|
}, jn = ie && (async (e) => {
|
|
1209
1209
|
let {
|
|
1210
1210
|
url: t,
|
|
@@ -1221,13 +1221,13 @@ const Hn = async (e) => {
|
|
|
1221
1221
|
fetchOptions: y
|
|
1222
1222
|
} = rt(e);
|
|
1223
1223
|
u = u ? (u + "").toLowerCase() : "text";
|
|
1224
|
-
let
|
|
1225
|
-
const m =
|
|
1226
|
-
|
|
1224
|
+
let R = Fn([s, o && o.toAbortSignal()], i), h;
|
|
1225
|
+
const m = R && R.unsubscribe && (() => {
|
|
1226
|
+
R.unsubscribe();
|
|
1227
1227
|
});
|
|
1228
1228
|
let p;
|
|
1229
1229
|
try {
|
|
1230
|
-
if (f && qn && n !== "get" && n !== "head" && (p = await
|
|
1230
|
+
if (f && qn && n !== "get" && n !== "head" && (p = await Hn(l, r)) !== 0) {
|
|
1231
1231
|
let A = new Request(t, {
|
|
1232
1232
|
method: "POST",
|
|
1233
1233
|
body: r,
|
|
@@ -1238,19 +1238,19 @@ const Hn = async (e) => {
|
|
|
1238
1238
|
p,
|
|
1239
1239
|
Q(Ce(f))
|
|
1240
1240
|
);
|
|
1241
|
-
r =
|
|
1241
|
+
r = xe(A.body, ke, D, V);
|
|
1242
1242
|
}
|
|
1243
1243
|
}
|
|
1244
1244
|
a.isString(d) || (d = d ? "include" : "omit");
|
|
1245
|
-
const
|
|
1245
|
+
const w = "credentials" in Request.prototype;
|
|
1246
1246
|
h = new Request(t, {
|
|
1247
1247
|
...y,
|
|
1248
|
-
signal:
|
|
1248
|
+
signal: R,
|
|
1249
1249
|
method: n.toUpperCase(),
|
|
1250
1250
|
headers: l.normalize().toJSON(),
|
|
1251
1251
|
body: r,
|
|
1252
1252
|
duplex: "half",
|
|
1253
|
-
credentials:
|
|
1253
|
+
credentials: w ? d : void 0
|
|
1254
1254
|
});
|
|
1255
1255
|
let g = await fetch(h);
|
|
1256
1256
|
const b = he && (u === "stream" || u === "response");
|
|
@@ -1264,17 +1264,17 @@ const Hn = async (e) => {
|
|
|
1264
1264
|
Q(Ce(c), !0)
|
|
1265
1265
|
) || [];
|
|
1266
1266
|
g = new Response(
|
|
1267
|
-
|
|
1267
|
+
xe(g.body, ke, D, () => {
|
|
1268
1268
|
V && V(), m && m();
|
|
1269
1269
|
}),
|
|
1270
1270
|
A
|
|
1271
1271
|
);
|
|
1272
1272
|
}
|
|
1273
1273
|
u = u || "text";
|
|
1274
|
-
let
|
|
1274
|
+
let F = await ee[a.findKey(ee, u) || "text"](g, e);
|
|
1275
1275
|
return !b && m && m(), await new Promise((A, I) => {
|
|
1276
1276
|
tt(A, I, {
|
|
1277
|
-
data:
|
|
1277
|
+
data: F,
|
|
1278
1278
|
headers: N.from(g.headers),
|
|
1279
1279
|
status: g.status,
|
|
1280
1280
|
statusText: g.statusText,
|
|
@@ -1282,17 +1282,17 @@ const Hn = async (e) => {
|
|
|
1282
1282
|
request: h
|
|
1283
1283
|
});
|
|
1284
1284
|
});
|
|
1285
|
-
} catch (
|
|
1286
|
-
throw m && m(),
|
|
1285
|
+
} catch (w) {
|
|
1286
|
+
throw m && m(), w && w.name === "TypeError" && /Load failed|fetch/i.test(w.message) ? Object.assign(
|
|
1287
1287
|
new E("Network Error", E.ERR_NETWORK, e, h),
|
|
1288
1288
|
{
|
|
1289
|
-
cause:
|
|
1289
|
+
cause: w.cause || w
|
|
1290
1290
|
}
|
|
1291
|
-
) : E.from(
|
|
1291
|
+
) : E.from(w, w && w.code, e, h);
|
|
1292
1292
|
}
|
|
1293
1293
|
}), me = {
|
|
1294
1294
|
http: tn,
|
|
1295
|
-
xhr:
|
|
1295
|
+
xhr: Pn,
|
|
1296
1296
|
fetch: jn
|
|
1297
1297
|
};
|
|
1298
1298
|
a.forEach(me, (e, t) => {
|
|
@@ -1304,7 +1304,7 @@ a.forEach(me, (e, t) => {
|
|
|
1304
1304
|
Object.defineProperty(e, "adapterName", { value: t });
|
|
1305
1305
|
}
|
|
1306
1306
|
});
|
|
1307
|
-
const
|
|
1307
|
+
const Pe = (e) => `- ${e}`, zn = (e) => a.isFunction(e) || e === null || e === !1, it = {
|
|
1308
1308
|
getAdapter: (e) => {
|
|
1309
1309
|
e = a.isArray(e) ? e : [e];
|
|
1310
1310
|
const { length: t } = e;
|
|
@@ -1324,8 +1324,8 @@ const Fe = (e) => `- ${e}`, zn = (e) => a.isFunction(e) || e === null || e === !
|
|
|
1324
1324
|
([c, f]) => `adapter ${c} ` + (f === !1 ? "is not supported by the environment" : "is not available in the build")
|
|
1325
1325
|
);
|
|
1326
1326
|
let i = t ? o.length > 1 ? `since :
|
|
1327
|
-
` + o.map(
|
|
1328
|
-
`) : " " +
|
|
1327
|
+
` + o.map(Pe).join(`
|
|
1328
|
+
`) : " " + Pe(o[0]) : "as no adapter specified";
|
|
1329
1329
|
throw new E(
|
|
1330
1330
|
"There is no suitable adapter to dispatch the request " + i,
|
|
1331
1331
|
"ERR_NOT_SUPPORT"
|
|
@@ -1339,7 +1339,7 @@ function le(e) {
|
|
|
1339
1339
|
if (e.cancelToken && e.cancelToken.throwIfRequested(), e.signal && e.signal.aborted)
|
|
1340
1340
|
throw new z(null, e);
|
|
1341
1341
|
}
|
|
1342
|
-
function
|
|
1342
|
+
function Fe(e) {
|
|
1343
1343
|
return le(e), e.headers = N.from(e.headers), e.data = ue.call(
|
|
1344
1344
|
e,
|
|
1345
1345
|
e.transformRequest
|
|
@@ -1406,7 +1406,7 @@ const Z = {
|
|
|
1406
1406
|
assertOptions: Kn,
|
|
1407
1407
|
validators: ae
|
|
1408
1408
|
}, k = Z.validators;
|
|
1409
|
-
let
|
|
1409
|
+
let M = class {
|
|
1410
1410
|
constructor(t) {
|
|
1411
1411
|
this.defaults = t || {}, this.interceptors = {
|
|
1412
1412
|
request: new Ae(),
|
|
@@ -1439,7 +1439,7 @@ let H = class {
|
|
|
1439
1439
|
}
|
|
1440
1440
|
}
|
|
1441
1441
|
_request(t, n) {
|
|
1442
|
-
typeof t == "string" ? (n = n || {}, n.url = t) : n = t || {}, n =
|
|
1442
|
+
typeof t == "string" ? (n = n || {}, n.url = t) : n = t || {}, n = H(this.defaults, n);
|
|
1443
1443
|
const { transitional: r, paramsSerializer: s, headers: o } = n;
|
|
1444
1444
|
r !== void 0 && Z.assertOptions(r, {
|
|
1445
1445
|
silentJSONParsing: k.transitional(k.boolean),
|
|
@@ -1475,24 +1475,24 @@ let H = class {
|
|
|
1475
1475
|
});
|
|
1476
1476
|
let l, d = 0, y;
|
|
1477
1477
|
if (!f) {
|
|
1478
|
-
const h = [
|
|
1478
|
+
const h = [Fe.bind(this), void 0];
|
|
1479
1479
|
for (h.unshift.apply(h, c), h.push.apply(h, u), y = h.length, l = Promise.resolve(n); d < y; )
|
|
1480
1480
|
l = l.then(h[d++], h[d++]);
|
|
1481
1481
|
return l;
|
|
1482
1482
|
}
|
|
1483
1483
|
y = c.length;
|
|
1484
|
-
let
|
|
1484
|
+
let R = n;
|
|
1485
1485
|
for (d = 0; d < y; ) {
|
|
1486
1486
|
const h = c[d++], m = c[d++];
|
|
1487
1487
|
try {
|
|
1488
|
-
|
|
1488
|
+
R = h(R);
|
|
1489
1489
|
} catch (p) {
|
|
1490
1490
|
m.call(this, p);
|
|
1491
1491
|
break;
|
|
1492
1492
|
}
|
|
1493
1493
|
}
|
|
1494
1494
|
try {
|
|
1495
|
-
l =
|
|
1495
|
+
l = Fe.call(this, R);
|
|
1496
1496
|
} catch (h) {
|
|
1497
1497
|
return Promise.reject(h);
|
|
1498
1498
|
}
|
|
@@ -1501,14 +1501,14 @@ let H = class {
|
|
|
1501
1501
|
return l;
|
|
1502
1502
|
}
|
|
1503
1503
|
getUri(t) {
|
|
1504
|
-
t =
|
|
1504
|
+
t = H(this.defaults, t);
|
|
1505
1505
|
const n = nt(t.baseURL, t.url, t.allowAbsoluteUrls);
|
|
1506
1506
|
return Ye(n, t.params, t.paramsSerializer);
|
|
1507
1507
|
}
|
|
1508
1508
|
};
|
|
1509
1509
|
a.forEach(["delete", "get", "head", "options"], function(t) {
|
|
1510
|
-
|
|
1511
|
-
return this.request(
|
|
1510
|
+
M.prototype[t] = function(n, r) {
|
|
1511
|
+
return this.request(H(r || {}, {
|
|
1512
1512
|
method: t,
|
|
1513
1513
|
url: n,
|
|
1514
1514
|
data: (r || {}).data
|
|
@@ -1518,7 +1518,7 @@ a.forEach(["delete", "get", "head", "options"], function(t) {
|
|
|
1518
1518
|
a.forEach(["post", "put", "patch"], function(t) {
|
|
1519
1519
|
function n(r) {
|
|
1520
1520
|
return function(o, i, c) {
|
|
1521
|
-
return this.request(
|
|
1521
|
+
return this.request(H(c || {}, {
|
|
1522
1522
|
method: t,
|
|
1523
1523
|
headers: r ? {
|
|
1524
1524
|
"Content-Type": "multipart/form-data"
|
|
@@ -1528,7 +1528,7 @@ a.forEach(["post", "put", "patch"], function(t) {
|
|
|
1528
1528
|
}));
|
|
1529
1529
|
};
|
|
1530
1530
|
}
|
|
1531
|
-
|
|
1531
|
+
M.prototype[t] = n(), M.prototype[t + "Form"] = n(!0);
|
|
1532
1532
|
});
|
|
1533
1533
|
let $n = class ct {
|
|
1534
1534
|
constructor(t) {
|
|
@@ -1680,13 +1680,13 @@ Object.entries(Ee).forEach(([e, t]) => {
|
|
|
1680
1680
|
Ee[t] = e;
|
|
1681
1681
|
});
|
|
1682
1682
|
function ut(e) {
|
|
1683
|
-
const t = new
|
|
1684
|
-
return a.extend(n,
|
|
1685
|
-
return ut(
|
|
1683
|
+
const t = new M(e), n = Me(M.prototype.request, t);
|
|
1684
|
+
return a.extend(n, M.prototype, t, { allOwnKeys: !0 }), a.extend(n, t, null, { allOwnKeys: !0 }), n.create = function(s) {
|
|
1685
|
+
return ut(H(e, s));
|
|
1686
1686
|
}, n;
|
|
1687
1687
|
}
|
|
1688
1688
|
const S = ut(J);
|
|
1689
|
-
S.Axios =
|
|
1689
|
+
S.Axios = M;
|
|
1690
1690
|
S.CanceledError = z;
|
|
1691
1691
|
S.CancelToken = $n;
|
|
1692
1692
|
S.isCancel = et;
|
|
@@ -1699,7 +1699,7 @@ S.all = function(t) {
|
|
|
1699
1699
|
};
|
|
1700
1700
|
S.spread = vn;
|
|
1701
1701
|
S.isAxiosError = Gn;
|
|
1702
|
-
S.mergeConfig =
|
|
1702
|
+
S.mergeConfig = H;
|
|
1703
1703
|
S.AxiosHeaders = N;
|
|
1704
1704
|
S.formToJSON = (e) => Qe(a.isHTMLForm(e) ? new FormData(e) : e);
|
|
1705
1705
|
S.getAdapter = it.getAdapter;
|
|
@@ -1712,8 +1712,8 @@ const {
|
|
|
1712
1712
|
isCancel: mr,
|
|
1713
1713
|
CancelToken: Er,
|
|
1714
1714
|
VERSION: yr,
|
|
1715
|
-
all:
|
|
1716
|
-
Cancel:
|
|
1715
|
+
all: Rr,
|
|
1716
|
+
Cancel: wr,
|
|
1717
1717
|
isAxiosError: Sr,
|
|
1718
1718
|
spread: gr,
|
|
1719
1719
|
toFormData: br,
|
|
@@ -1722,7 +1722,7 @@ const {
|
|
|
1722
1722
|
formToJSON: Or,
|
|
1723
1723
|
getAdapter: Ar,
|
|
1724
1724
|
mergeConfig: _r
|
|
1725
|
-
} = S, Vn = (e) => (e.baseURL = qe(), e.headers.Authorization = localStorage.getItem(
|
|
1725
|
+
} = S, Vn = (e) => (e.baseURL = qe(), e.headers.Authorization = localStorage.getItem(P.TOKEN), e.headers["client-id"] = localStorage.getItem(P.CLIENT_ID), e.metadata = { startTime: /* @__PURE__ */ new Date() }, { ...e }), Le = (e, t, n) => {
|
|
1726
1726
|
for (const r of e)
|
|
1727
1727
|
t ? r.rej(t) : r.res(n);
|
|
1728
1728
|
}, Wn = async (e) => new Promise((t, n) => {
|
|
@@ -1741,7 +1741,7 @@ const {
|
|
|
1741
1741
|
);
|
|
1742
1742
|
}, Yn = async (e, t, n, r, s) => {
|
|
1743
1743
|
var f, u, l;
|
|
1744
|
-
const o = t.config, i = localStorage.getItem(
|
|
1744
|
+
const o = t.config, i = localStorage.getItem(P.REFRESH_TOKEN), c = ((f = t.response) == null ? void 0 : f.status) || B.InternalServerError;
|
|
1745
1745
|
if (!o || o.__retries === n)
|
|
1746
1746
|
throw t;
|
|
1747
1747
|
if (c === B.Unauthorized && o.url !== O.REFRESH_EMBED_TOKEN && o.url !== O.REFRESH_TOKEN && o.url !== O.SIGN_IN && o.url !== O.SIGN_UP) {
|
|
@@ -1751,16 +1751,16 @@ const {
|
|
|
1751
1751
|
"no refresh token found to reauthenticate user"
|
|
1752
1752
|
), t;
|
|
1753
1753
|
if (r)
|
|
1754
|
-
return new Promise((p,
|
|
1755
|
-
e.push({ res: p, rej:
|
|
1754
|
+
return new Promise((p, w) => {
|
|
1755
|
+
e.push({ res: p, rej: w });
|
|
1756
1756
|
}).then((p) => (o.headers && (o.headers.Authorization = `Bearer ${p}`), s(o))).catch((p) => {
|
|
1757
1757
|
throw p;
|
|
1758
1758
|
});
|
|
1759
1759
|
r = !0;
|
|
1760
|
-
const y = localStorage.getItem(
|
|
1760
|
+
const y = localStorage.getItem(P.AUTH_FLOW) === dt.POST_MESSAGE ? Be.refreshEmbedToken : Be.refreshToken, { data: R, success: h, message: m } = await y(i);
|
|
1761
1761
|
if (!h)
|
|
1762
1762
|
throw (u = o == null ? void 0 : o.url) != null && u.includes(O.EXCHANGE_TOKEN) || De("refresh_token", m), r = !1, Le(e, t), t;
|
|
1763
|
-
return (l = o.url) != null && l.includes(O.EXCHANGE_TOKEN) && "id_token" in
|
|
1763
|
+
return (l = o.url) != null && l.includes(O.EXCHANGE_TOKEN) && "id_token" in R && (o.data = JSON.stringify({ idToken: R.id_token })), r = !1, o.headers && (o.headers.Authorization = `Bearer ${R.token}`), Le(e, null, R.token), s(o);
|
|
1764
1764
|
}
|
|
1765
1765
|
if ([
|
|
1766
1766
|
B.Unauthorized,
|
|
@@ -1776,7 +1776,7 @@ const {
|
|
|
1776
1776
|
// Exponential backoff 50ms, 500ms, 5000ms
|
|
1777
1777
|
);
|
|
1778
1778
|
}, Zn = S.create();
|
|
1779
|
-
Zn.interceptors.request.use((e) => (e.baseURL = qe(), e.headers.Authorization = localStorage.getItem(
|
|
1779
|
+
Zn.interceptors.request.use((e) => (e.baseURL = qe(), e.headers.Authorization = localStorage.getItem(P.TOKEN), e.metadata = { startTime: /* @__PURE__ */ new Date() }, { ...e }));
|
|
1780
1780
|
const C = S.create();
|
|
1781
1781
|
C.interceptors.request.use((e) => (e = Vn(e), e));
|
|
1782
1782
|
const Qn = 3;
|
|
@@ -1791,7 +1791,7 @@ class nr {
|
|
|
1791
1791
|
* @param params - The sign-in parameters containing email and password.
|
|
1792
1792
|
* @returns A promise that resolves to a service response containing authentication data.
|
|
1793
1793
|
*/
|
|
1794
|
-
|
|
1794
|
+
x(this, "login", async (t) => {
|
|
1795
1795
|
var n, r, s, o, i;
|
|
1796
1796
|
try {
|
|
1797
1797
|
const { data: c } = await C.post(O.SIGN_IN, {
|
|
@@ -1801,7 +1801,7 @@ class nr {
|
|
|
1801
1801
|
queryKey: [$.USER_REGIONS],
|
|
1802
1802
|
queryFn: this.getRegions
|
|
1803
1803
|
}), u = L(c.data), l = (n = c.data) == null ? void 0 : n.accessToken;
|
|
1804
|
-
return localStorage.setItem(
|
|
1804
|
+
return localStorage.setItem(P.TOKEN, l), {
|
|
1805
1805
|
success: !0,
|
|
1806
1806
|
data: L({
|
|
1807
1807
|
...c.data,
|
|
@@ -1827,7 +1827,7 @@ class nr {
|
|
|
1827
1827
|
* @param params - The sign-up parameters containing email, password, and region.
|
|
1828
1828
|
* @returns A promise that resolves to a service response containing authentication data.
|
|
1829
1829
|
*/
|
|
1830
|
-
|
|
1830
|
+
x(this, "signUp", async (t) => {
|
|
1831
1831
|
var n, r, s, o, i, c;
|
|
1832
1832
|
try {
|
|
1833
1833
|
const { data: f } = await C.post(O.SIGN_UP, {
|
|
@@ -1843,7 +1843,7 @@ class nr {
|
|
|
1843
1843
|
queryKey: [$.USER_REGIONS],
|
|
1844
1844
|
queryFn: this.getRegions
|
|
1845
1845
|
}), l = L(f.data), d = (n = f.data) == null ? void 0 : n.tokens.accessToken;
|
|
1846
|
-
return localStorage.setItem(
|
|
1846
|
+
return localStorage.setItem(P.TOKEN, d), {
|
|
1847
1847
|
success: !0,
|
|
1848
1848
|
data: {
|
|
1849
1849
|
accessToken: (r = f.data) == null ? void 0 : r.tokens.accessToken,
|
|
@@ -1863,7 +1863,7 @@ class nr {
|
|
|
1863
1863
|
};
|
|
1864
1864
|
}
|
|
1865
1865
|
});
|
|
1866
|
-
|
|
1866
|
+
x(this, "resendVerificationEmail", async (t) => {
|
|
1867
1867
|
var n, r, s;
|
|
1868
1868
|
try {
|
|
1869
1869
|
return (await C.post(
|
|
@@ -1887,7 +1887,7 @@ class nr {
|
|
|
1887
1887
|
* @param idToken - The ID token to authenticate with.
|
|
1888
1888
|
* @returns A promise that resolves to a service response containing authentication data.
|
|
1889
1889
|
*/
|
|
1890
|
-
|
|
1890
|
+
x(this, "authenticateWithToken", async (t) => {
|
|
1891
1891
|
var n, r, s;
|
|
1892
1892
|
try {
|
|
1893
1893
|
const { data: o } = await C.post(O.EXCHANGE_TOKEN, {
|
|
@@ -1920,7 +1920,7 @@ class nr {
|
|
|
1920
1920
|
*
|
|
1921
1921
|
* @returns A promise that resolves to a service response containing the user details.
|
|
1922
1922
|
*/
|
|
1923
|
-
|
|
1923
|
+
x(this, "checkUser", async () => {
|
|
1924
1924
|
try {
|
|
1925
1925
|
const { data: t } = await C.get(O.ME), n = await W.ensureQueryData({
|
|
1926
1926
|
queryKey: [$.USER_REGIONS],
|
|
@@ -1950,7 +1950,7 @@ class nr {
|
|
|
1950
1950
|
*
|
|
1951
1951
|
* @param refreshToken - The refresh token
|
|
1952
1952
|
*/
|
|
1953
|
-
|
|
1953
|
+
x(this, "refreshEmbedToken", async (t) => {
|
|
1954
1954
|
try {
|
|
1955
1955
|
const { data: n } = await C.post(
|
|
1956
1956
|
O.REFRESH_EMBED_TOKEN,
|
|
@@ -1958,7 +1958,7 @@ class nr {
|
|
|
1958
1958
|
refreshToken: t
|
|
1959
1959
|
}
|
|
1960
1960
|
), r = n.data.token;
|
|
1961
|
-
return localStorage.setItem(
|
|
1961
|
+
return localStorage.setItem(P.TOKEN, r), {
|
|
1962
1962
|
success: !0,
|
|
1963
1963
|
data: n.data
|
|
1964
1964
|
};
|
|
@@ -1975,7 +1975,7 @@ class nr {
|
|
|
1975
1975
|
*
|
|
1976
1976
|
* @param refreshToken - The refresh token
|
|
1977
1977
|
*/
|
|
1978
|
-
|
|
1978
|
+
x(this, "refreshToken", async (t) => {
|
|
1979
1979
|
try {
|
|
1980
1980
|
const { data: n } = await C.post(
|
|
1981
1981
|
O.REFRESH_TOKEN,
|
|
@@ -1983,7 +1983,7 @@ class nr {
|
|
|
1983
1983
|
refreshToken: t
|
|
1984
1984
|
}
|
|
1985
1985
|
), r = n.data.accessToken;
|
|
1986
|
-
return localStorage.setItem(
|
|
1986
|
+
return localStorage.setItem(P.TOKEN, r), {
|
|
1987
1987
|
success: !0,
|
|
1988
1988
|
data: {
|
|
1989
1989
|
...n.data,
|
|
@@ -2003,13 +2003,13 @@ class nr {
|
|
|
2003
2003
|
*
|
|
2004
2004
|
* @returns A promise that resolves to a service response containing the request limit data.
|
|
2005
2005
|
*/
|
|
2006
|
-
|
|
2006
|
+
x(this, "getRequestLimit", async () => (await C.get(O.REQUEST_LIMIT)).data);
|
|
2007
2007
|
/**
|
|
2008
2008
|
* Retrieves the regions available for user registration.
|
|
2009
2009
|
*
|
|
2010
2010
|
* @returns A promise that resolves to a service response containing the available regions.
|
|
2011
2011
|
*/
|
|
2012
|
-
|
|
2012
|
+
x(this, "getRegions", async () => {
|
|
2013
2013
|
var n;
|
|
2014
2014
|
const t = await C.get(O.REGIONS);
|
|
2015
2015
|
return L((n = t.data) == null ? void 0 : n.data);
|
|
@@ -2023,7 +2023,7 @@ export {
|
|
|
2023
2023
|
mt as a,
|
|
2024
2024
|
L as b,
|
|
2025
2025
|
C as c,
|
|
2026
|
-
|
|
2026
|
+
P as d,
|
|
2027
2027
|
S as e,
|
|
2028
2028
|
Jn as f,
|
|
2029
2029
|
Vn as g,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
var _ = Object.defineProperty;
|
|
2
2
|
var g = (a, e, s) => e in a ? _(a, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : a[e] = s;
|
|
3
3
|
var r = (a, e, s) => g(a, typeof e != "symbol" ? e + "" : e, s);
|
|
4
|
-
import { c as n, j as p, b as o, r as T } from "./AccountService-
|
|
4
|
+
import { c as n, j as p, b as o, r as T } from "./AccountService-DdcBI9BS.js";
|
|
5
5
|
import { EBookingType as m } from "./services/trips/TripService.types.js";
|
|
6
6
|
import { EMyTripsEndpoints as i } from "./configs/endpoints.js";
|
|
7
7
|
import "./arrayExtensions-DlcBOj5a.js";
|
|
@@ -5,7 +5,7 @@ import { u as D, a as ot, c as A, b as q, d as ve, e as st, f as it, g as G, o a
|
|
|
5
5
|
import { r as yt, R as gt } from "../../index-Cv-wvFlM.js";
|
|
6
6
|
import { useQuery as Ct } from "@tanstack/react-query";
|
|
7
7
|
import "../../arrayExtensions-DlcBOj5a.js";
|
|
8
|
-
import { E as Et } from "../../AccountService-
|
|
8
|
+
import { E as Et } from "../../AccountService-DdcBI9BS.js";
|
|
9
9
|
import { b as ue } from "../../index-CDh8vAM_.js";
|
|
10
10
|
import "../../context/AwayzContext.js";
|
|
11
11
|
import "../../configs/awayzClient.js";
|
|
@@ -5,7 +5,7 @@ import "react";
|
|
|
5
5
|
import "../../context/AwayzContext.js";
|
|
6
6
|
import "@tanstack/react-query";
|
|
7
7
|
import "../../arrayExtensions-DlcBOj5a.js";
|
|
8
|
-
import "../../AccountService-
|
|
8
|
+
import "../../AccountService-DdcBI9BS.js";
|
|
9
9
|
import "../../configs/awayzClient.js";
|
|
10
10
|
import { EAuthFlow as i } from "../../types/EAuthFlow.js";
|
|
11
11
|
import "../../services/noRetryInstance.js";
|
|
@@ -5,7 +5,7 @@ import "react";
|
|
|
5
5
|
import "../../../context/AwayzContext.js";
|
|
6
6
|
import "@tanstack/react-query";
|
|
7
7
|
import "../../../arrayExtensions-DlcBOj5a.js";
|
|
8
|
-
import "../../../AccountService-
|
|
8
|
+
import "../../../AccountService-DdcBI9BS.js";
|
|
9
9
|
import "../../../configs/awayzClient.js";
|
|
10
10
|
import { EAuthFlow as e } from "../../../types/EAuthFlow.js";
|
|
11
11
|
import "../../../services/noRetryInstance.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import "../../arrayExtensions-DlcBOj5a.js";
|
|
2
|
-
import { f as P, d as n, A as o, E as U } from "../../AccountService-
|
|
2
|
+
import { f as P, d as n, A as o, E as U } from "../../AccountService-DdcBI9BS.js";
|
|
3
3
|
import { useState as m, useCallback as A, useEffect as S } from "react";
|
|
4
4
|
import { awayzClient as O } from "../../configs/awayzClient.js";
|
|
5
5
|
import { PreferencesService as v } from "../../services/preferences/PreferencesService.js";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { useQuery as a, useMutation as s } from "@tanstack/react-query";
|
|
2
2
|
import { EBookingType as e } from "../../services/trips/TripService.types.js";
|
|
3
3
|
import "../../arrayExtensions-DlcBOj5a.js";
|
|
4
|
-
import { E as t } from "../../AccountService-
|
|
4
|
+
import { E as t } from "../../AccountService-DdcBI9BS.js";
|
|
5
5
|
import "react";
|
|
6
6
|
import { BookingService as o } from "../../services/bookings/BookingService.js";
|
|
7
7
|
import "react/jsx-runtime";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { renderHook as t, waitFor as r } from "../../tests/TestWrapper.js";
|
|
2
2
|
import { useBookingManagement as a } from "./useBookingManagement.js";
|
|
3
|
-
import { c as i } from "../../AccountService-
|
|
3
|
+
import { c as i } from "../../AccountService-DdcBI9BS.js";
|
|
4
4
|
import "../../services/noRetryInstance.js";
|
|
5
5
|
import "../../arrayExtensions-DlcBOj5a.js";
|
|
6
6
|
import "react";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { useQuery as u } from "@tanstack/react-query";
|
|
2
2
|
import "../arrayExtensions-DlcBOj5a.js";
|
|
3
|
-
import { E as m, A as c, b as f } from "../AccountService-
|
|
3
|
+
import { E as m, A as c, b as f } from "../AccountService-DdcBI9BS.js";
|
|
4
4
|
import { useEffect as d } from "react";
|
|
5
5
|
import { useAwayzContext as y } from "./useAwayzContext.js";
|
|
6
6
|
var i = /* @__PURE__ */ ((r) => (r.HOTEL = "Hotel", r.FLIGHT = "Flight", r))(i || {});
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { useQuery as p, useMutation as s } from "@tanstack/react-query";
|
|
2
2
|
import { h as m } from "../../arrayExtensions-DlcBOj5a.js";
|
|
3
|
-
import { E as e } from "../../AccountService-
|
|
3
|
+
import { E as e } from "../../AccountService-DdcBI9BS.js";
|
|
4
4
|
import "react";
|
|
5
|
-
import { T as t } from "../../TripsService-
|
|
5
|
+
import { T as t } from "../../TripsService-CLvs14Rq.js";
|
|
6
6
|
import "react/jsx-runtime";
|
|
7
7
|
import "../../context/AwayzContext.js";
|
|
8
8
|
import { awayzClient as o } from "../../configs/awayzClient.js";
|
|
@@ -4,9 +4,9 @@ import { useTripManagement as n } from "./useTripManagement.js";
|
|
|
4
4
|
import "react/jsx-runtime";
|
|
5
5
|
import "react";
|
|
6
6
|
import "../../context/AwayzContext.js";
|
|
7
|
-
import { D as f } from "../../TripsService-
|
|
7
|
+
import { D as f } from "../../TripsService-CLvs14Rq.js";
|
|
8
8
|
import "../../configs/awayzClient.js";
|
|
9
|
-
import { c } from "../../AccountService-
|
|
9
|
+
import { c } from "../../AccountService-DdcBI9BS.js";
|
|
10
10
|
import { EMyTripsEndpoints as d } from "../../configs/endpoints.js";
|
|
11
11
|
import "@tanstack/react-query";
|
|
12
12
|
import { EBookingType as m } from "../../services/trips/TripService.types.js";
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { useQuery as n, useMutation as
|
|
1
|
+
import { useQuery as n, useMutation as s } from "@tanstack/react-query";
|
|
2
2
|
import "../../arrayExtensions-DlcBOj5a.js";
|
|
3
|
-
import { E as t, a as u } from "../../AccountService-
|
|
3
|
+
import { E as t, a as u } from "../../AccountService-DdcBI9BS.js";
|
|
4
4
|
import "react";
|
|
5
5
|
import "react/jsx-runtime";
|
|
6
6
|
import "../../context/AwayzContext.js";
|
|
7
|
-
import { awayzClient as
|
|
8
|
-
import { useAwayzContext as
|
|
7
|
+
import { awayzClient as i } from "../../configs/awayzClient.js";
|
|
8
|
+
import { useAwayzContext as q } from "../useAwayzContext.js";
|
|
9
9
|
import "../../services/noRetryInstance.js";
|
|
10
10
|
import '../../assets/_styles5.css';import '../../assets/_styles4.css';import '../../assets/_styles3.css';import '../../assets/_styles2.css';import '../../assets/_styles.css';/* empty css */
|
|
11
11
|
/* empty css */
|
|
@@ -13,18 +13,18 @@ import '../../assets/_styles5.css';import '../../assets/_styles4.css';import '..
|
|
|
13
13
|
/* empty css */
|
|
14
14
|
/* empty css */
|
|
15
15
|
import { WalletService as o } from "../../services/wallet/WalletService.js";
|
|
16
|
-
const
|
|
17
|
-
const { user: r } =
|
|
16
|
+
const I = () => {
|
|
17
|
+
const { user: r } = q(), { data: e } = n({
|
|
18
18
|
queryKey: [t.PROGRAMS],
|
|
19
19
|
queryFn: o.getAwards,
|
|
20
20
|
placeholderData: []
|
|
21
|
-
}), { data:
|
|
21
|
+
}), { data: y } = n({
|
|
22
22
|
queryKey: [t.USER_PROGRAMS, r == null ? void 0 : r.id],
|
|
23
23
|
queryFn: () => r != null && r.id ? o.getUserAwards(r.id) : [],
|
|
24
24
|
placeholderData: [],
|
|
25
25
|
enabled: !!(r != null && r.id)
|
|
26
|
-
}), { data:
|
|
27
|
-
queryKey: [t.
|
|
26
|
+
}), { data: c } = n({
|
|
27
|
+
queryKey: [t.LINKED_USER_PROGRAMS, r == null ? void 0 : r.id],
|
|
28
28
|
queryFn: () => r != null && r.id ? o.getLinkedUserAwards(r.id) : [],
|
|
29
29
|
placeholderData: [],
|
|
30
30
|
enabled: !!(r != null && r.id)
|
|
@@ -32,62 +32,64 @@ const B = () => {
|
|
|
32
32
|
queryKey: [t.BANKS],
|
|
33
33
|
queryFn: o.getBanks,
|
|
34
34
|
placeholderData: []
|
|
35
|
-
}), { data:
|
|
35
|
+
}), { data: R } = n({
|
|
36
36
|
queryKey: [t.CARDS],
|
|
37
37
|
queryFn: o.getCards,
|
|
38
38
|
placeholderData: []
|
|
39
|
-
}), { data:
|
|
39
|
+
}), { data: A } = n({
|
|
40
40
|
queryKey: [t.USER_CARDS],
|
|
41
41
|
queryFn: o.getUserCards,
|
|
42
42
|
placeholderData: []
|
|
43
|
-
}), { mutate:
|
|
43
|
+
}), { mutate: S } = s({
|
|
44
44
|
mutationFn: async (a) => {
|
|
45
45
|
const { mainProgram: d, awardsAmount: m } = typeof a == "string" ? { mainProgram: a, awardsAmount: 0 } : a;
|
|
46
46
|
await o.addAwardProgram(d, m);
|
|
47
47
|
},
|
|
48
48
|
onSuccess: () => {
|
|
49
|
-
|
|
50
|
-
queryKey: [t.
|
|
49
|
+
i.invalidateQueries({
|
|
50
|
+
queryKey: [t.LINKED_USER_PROGRAMS]
|
|
51
51
|
});
|
|
52
52
|
}
|
|
53
|
-
}), { mutate:
|
|
53
|
+
}), { mutate: P } = s({
|
|
54
54
|
mutationFn: async (a) => {
|
|
55
55
|
await o.removeAwardProgram(a);
|
|
56
56
|
},
|
|
57
57
|
onSuccess: () => {
|
|
58
|
-
|
|
59
|
-
queryKey: [t.
|
|
58
|
+
i.invalidateQueries({
|
|
59
|
+
queryKey: [t.LINKED_USER_PROGRAMS]
|
|
60
60
|
});
|
|
61
61
|
}
|
|
62
|
-
}), { mutate:
|
|
62
|
+
}), { mutate: p } = s({
|
|
63
63
|
mutationFn: async (a) => {
|
|
64
|
-
const { mainProgram: d, awardsAmount: m } = a,
|
|
65
|
-
(
|
|
64
|
+
const { mainProgram: d, awardsAmount: m } = a, l = e == null ? void 0 : e.find(
|
|
65
|
+
(C) => C.mainProgram === d
|
|
66
66
|
);
|
|
67
|
-
if (!
|
|
67
|
+
if (!l)
|
|
68
68
|
throw new Error("Program not found");
|
|
69
|
-
await o.setAwardPoints(
|
|
69
|
+
await o.setAwardPoints(l.mainProgram, m);
|
|
70
70
|
},
|
|
71
71
|
onSuccess: () => {
|
|
72
|
-
|
|
73
|
-
queryKey: [t.
|
|
72
|
+
i.invalidateQueries({
|
|
73
|
+
queryKey: [t.LINKED_USER_PROGRAMS]
|
|
74
|
+
}), i.invalidateQueries({
|
|
75
|
+
queryKey: [t.USER_PROGRAMS]
|
|
74
76
|
});
|
|
75
77
|
}
|
|
76
|
-
}), { mutate:
|
|
78
|
+
}), { mutate: E } = s({
|
|
77
79
|
mutationFn: async (a) => {
|
|
78
80
|
await o.addCardsToWallet(a);
|
|
79
81
|
},
|
|
80
82
|
onSuccess: () => {
|
|
81
|
-
|
|
83
|
+
i.invalidateQueries({
|
|
82
84
|
queryKey: [t.USER_CARDS]
|
|
83
85
|
});
|
|
84
86
|
}
|
|
85
|
-
}), { mutate:
|
|
87
|
+
}), { mutate: K } = s({
|
|
86
88
|
mutationFn: async (a) => {
|
|
87
89
|
await o.removeCardsFromWallet(a);
|
|
88
90
|
},
|
|
89
91
|
onSuccess: () => {
|
|
90
|
-
|
|
92
|
+
i.invalidateQueries({
|
|
91
93
|
queryKey: [t.USER_CARDS]
|
|
92
94
|
});
|
|
93
95
|
}
|
|
@@ -95,8 +97,8 @@ const B = () => {
|
|
|
95
97
|
return {
|
|
96
98
|
// Program Management
|
|
97
99
|
allPrograms: e || [],
|
|
98
|
-
userPrograms:
|
|
99
|
-
linkedUserPrograms:
|
|
100
|
+
userPrograms: y || [],
|
|
101
|
+
linkedUserPrograms: c || [],
|
|
100
102
|
hotelPrograms: (e == null ? void 0 : e.filter(
|
|
101
103
|
(a) => a.category.includes(u.HOTEL)
|
|
102
104
|
)) || [],
|
|
@@ -106,17 +108,17 @@ const B = () => {
|
|
|
106
108
|
bankPrograms: (e == null ? void 0 : e.filter(
|
|
107
109
|
(a) => a.category.includes(u.BANK)
|
|
108
110
|
)) || [],
|
|
109
|
-
updatePoints:
|
|
110
|
-
addAwardProgram:
|
|
111
|
-
removeAwardProgram:
|
|
111
|
+
updatePoints: p,
|
|
112
|
+
addAwardProgram: S,
|
|
113
|
+
removeAwardProgram: P,
|
|
112
114
|
// Car Management
|
|
113
115
|
banks: g || [],
|
|
114
|
-
allCards:
|
|
115
|
-
userCards:
|
|
116
|
-
addCards:
|
|
117
|
-
removeCards:
|
|
116
|
+
allCards: R || [],
|
|
117
|
+
userCards: A || [],
|
|
118
|
+
addCards: E,
|
|
119
|
+
removeCards: K
|
|
118
120
|
};
|
|
119
121
|
};
|
|
120
122
|
export {
|
|
121
|
-
|
|
123
|
+
I as useWallet
|
|
122
124
|
};
|
|
@@ -4,7 +4,7 @@ import "react";
|
|
|
4
4
|
import "../../context/AwayzContext.js";
|
|
5
5
|
import "../../arrayExtensions-DlcBOj5a.js";
|
|
6
6
|
import "../../configs/awayzClient.js";
|
|
7
|
-
import { c as l } from "../../AccountService-
|
|
7
|
+
import { c as l } from "../../AccountService-DdcBI9BS.js";
|
|
8
8
|
import "@tanstack/react-query";
|
|
9
9
|
import { useWallet as t } from "./useWallet.js";
|
|
10
10
|
import "../../services/noRetryInstance.js";
|
package/dist/main.js
CHANGED
|
@@ -6,7 +6,7 @@ import { useTripManagement as f, validateUpdateTripArgs as s } from "./hooks/use
|
|
|
6
6
|
import { useBookingManagement as c } from "./hooks/useBookingManagement/useBookingManagement.js";
|
|
7
7
|
import { EAuthFlow as y } from "./types/EAuthFlow.js";
|
|
8
8
|
import { EHotelCurrencyOption as d, currencySymbols as C } from "./types/ECurrency.js";
|
|
9
|
-
import { c as w, i as A } from "./AccountService-
|
|
9
|
+
import { c as w, i as A } from "./AccountService-DdcBI9BS.js";
|
|
10
10
|
import { clientNoRetryInstance as E } from "./services/noRetryInstance.js";
|
|
11
11
|
import { CurrencyService as h } from "./services/currency/CurrencyService.js";
|
|
12
12
|
import { EBookingType as S } from "./services/trips/TripService.types.js";
|
|
@@ -2,7 +2,7 @@ import { jsx as t } from "react/jsx-runtime";
|
|
|
2
2
|
import { useEffect as a } from "react";
|
|
3
3
|
import { AwayzContext as m } from "../context/AwayzContext.js";
|
|
4
4
|
import "../arrayExtensions-DlcBOj5a.js";
|
|
5
|
-
import { d as r } from "../AccountService-
|
|
5
|
+
import { d as r } from "../AccountService-DdcBI9BS.js";
|
|
6
6
|
import { useAwayzAuth as l } from "../hooks/useAwayzAuth/useAwayzAuth.js";
|
|
7
7
|
import { setCustomBaseUrl as i, setBaseUrl as u } from "../configs/baseUrl.js";
|
|
8
8
|
import { QueryClientProvider as d } from "@tanstack/react-query";
|
|
@@ -2,7 +2,7 @@ var l = Object.defineProperty;
|
|
|
2
2
|
var u = (r, e, a) => e in r ? l(r, e, { enumerable: !0, configurable: !0, writable: !0, value: a }) : r[e] = a;
|
|
3
3
|
var c = (r, e, a) => u(r, typeof e != "symbol" ? e + "" : e, a);
|
|
4
4
|
import "../../arrayExtensions-DlcBOj5a.js";
|
|
5
|
-
import { c as i, b as s } from "../../AccountService-
|
|
5
|
+
import { c as i, b as s } from "../../AccountService-DdcBI9BS.js";
|
|
6
6
|
import "react";
|
|
7
7
|
import { EBookingEndpoints as d } from "../../configs/endpoints.js";
|
|
8
8
|
const _ = (r) => {
|
|
@@ -2,7 +2,7 @@ import '../../assets/_styles5.css';import '../../assets/_styles4.css';import '..
|
|
|
2
2
|
var y = (t, r, e) => r in t ? u(t, r, { enumerable: !0, configurable: !0, writable: !0, value: e }) : t[r] = e;
|
|
3
3
|
var n = (t, r, e) => y(t, typeof r != "symbol" ? r + "" : r, e);
|
|
4
4
|
import "../../arrayExtensions-DlcBOj5a.js";
|
|
5
|
-
import { A as p, E as m, c as a } from "../../AccountService-
|
|
5
|
+
import { A as p, E as m, c as a } from "../../AccountService-DdcBI9BS.js";
|
|
6
6
|
import "react";
|
|
7
7
|
import { ECurrencyEndpoints as s } from "../../configs/endpoints.js";
|
|
8
8
|
import "react/jsx-runtime";
|
package/dist/services/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { c as o, i as t } from "../AccountService-
|
|
1
|
+
import { c as o, i as t } from "../AccountService-DdcBI9BS.js";
|
|
2
2
|
import { clientNoRetryInstance as c } from "./noRetryInstance.js";
|
|
3
3
|
import { CurrencyService as a } from "./currency/CurrencyService.js";
|
|
4
4
|
import { EBookingType as s } from "./trips/TripService.types.js";
|
|
@@ -2,7 +2,7 @@ var a = Object.defineProperty;
|
|
|
2
2
|
var o = (s, e, r) => e in s ? a(s, e, { enumerable: !0, configurable: !0, writable: !0, value: r }) : s[e] = r;
|
|
3
3
|
var n = (s, e, r) => o(s, typeof e != "symbol" ? e + "" : e, r);
|
|
4
4
|
import { EPreferencesEndpoints as u } from "../../configs/endpoints.js";
|
|
5
|
-
import { c as i } from "../../AccountService-
|
|
5
|
+
import { c as i } from "../../AccountService-DdcBI9BS.js";
|
|
6
6
|
class E {
|
|
7
7
|
constructor() {
|
|
8
8
|
n(this, "setCurrency", async (e) => {
|
|
@@ -2,7 +2,7 @@ var s = Object.defineProperty;
|
|
|
2
2
|
var n = (t, e, a) => e in t ? s(t, e, { enumerable: !0, configurable: !0, writable: !0, value: a }) : t[e] = a;
|
|
3
3
|
var r = (t, e, a) => n(t, typeof e != "symbol" ? e + "" : e, a);
|
|
4
4
|
import { ERewardsEndpoints as c } from "../../configs/endpoints.js";
|
|
5
|
-
import { c as o } from "../../AccountService-
|
|
5
|
+
import { c as o } from "../../AccountService-DdcBI9BS.js";
|
|
6
6
|
class i {
|
|
7
7
|
constructor() {
|
|
8
8
|
/**
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import "../../AccountService-
|
|
1
|
+
import "../../AccountService-DdcBI9BS.js";
|
|
2
2
|
import "./TripService.types.js";
|
|
3
3
|
import "../../configs/endpoints.js";
|
|
4
4
|
import "../../arrayExtensions-DlcBOj5a.js";
|
|
5
|
-
import { T as s } from "../../TripsService-
|
|
5
|
+
import { T as s } from "../../TripsService-CLvs14Rq.js";
|
|
6
6
|
import "react";
|
|
7
7
|
export {
|
|
8
8
|
s as TripsService
|
|
@@ -2,7 +2,7 @@ var o = Object.defineProperty;
|
|
|
2
2
|
var i = (d, a, t) => a in d ? o(d, a, { enumerable: !0, configurable: !0, writable: !0, value: t }) : d[a] = t;
|
|
3
3
|
var r = (d, a, t) => i(d, typeof a != "symbol" ? a + "" : a, t);
|
|
4
4
|
import "../../arrayExtensions-DlcBOj5a.js";
|
|
5
|
-
import { c as s, b as c } from "../../AccountService-
|
|
5
|
+
import { c as s, b as c } from "../../AccountService-DdcBI9BS.js";
|
|
6
6
|
import "react";
|
|
7
7
|
import { EWalletEndpoints as e } from "../../configs/endpoints.js";
|
|
8
8
|
class A {
|