@das-fed/utils 6.3.0-beta.3 → 6.3.0-beta.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (88) hide show
  1. package/__VLS_types.d.ts +124 -0
  2. package/api-services/modules/app-manage/index.d.ts +2 -0
  3. package/api-services/modules/app-manage/index.js +5 -0
  4. package/api-services/modules/authentication/index.d.ts +2 -0
  5. package/api-services/modules/authentication/index.js +5 -0
  6. package/api-services/modules/bems/index.d.ts +6 -0
  7. package/api-services/modules/bems/index.js +9 -0
  8. package/api-services/modules/contract/index.d.ts +2 -0
  9. package/api-services/modules/contract/index.js +5 -0
  10. package/api-services/modules/duty-manage/index.d.ts +7 -0
  11. package/api-services/modules/duty-manage/index.js +14 -0
  12. package/api-services/modules/enterpriseright/index.d.ts +2 -0
  13. package/api-services/modules/enterpriseright/index.js +5 -0
  14. package/api-services/modules/file/index.d.ts +36 -0
  15. package/api-services/modules/file/index.js +499 -0
  16. package/api-services/modules/file/index.js.gz +0 -0
  17. package/api-services/modules/gateway-edge/index.d.ts +2 -0
  18. package/api-services/modules/gateway-edge/index.js +5 -0
  19. package/api-services/modules/index.d.ts +21 -0
  20. package/api-services/modules/index.js +59 -0
  21. package/api-services/modules/index.js.gz +0 -0
  22. package/api-services/modules/iot/index.d.ts +15 -0
  23. package/api-services/modules/iot/index.js +18 -0
  24. package/api-services/modules/justauth/index.d.ts +3 -0
  25. package/api-services/modules/justauth/index.js +6 -0
  26. package/api-services/modules/knowledge/index.d.ts +2 -0
  27. package/api-services/modules/knowledge/index.js +5 -0
  28. package/api-services/modules/link/index.d.ts +2 -0
  29. package/api-services/modules/link/index.js +5 -0
  30. package/api-services/modules/permission/index.d.ts +2 -0
  31. package/api-services/modules/permission/index.js +5 -0
  32. package/api-services/modules/platformManage/index.d.ts +14 -0
  33. package/api-services/modules/platformManage/index.js +13 -0
  34. package/api-services/modules/portal/index.d.ts +2 -0
  35. package/api-services/modules/portal/index.js +5 -0
  36. package/api-services/modules/space-manage/index.d.ts +2 -0
  37. package/api-services/modules/space-manage/index.js +5 -0
  38. package/api-services/modules/super-admin/index.d.ts +8 -0
  39. package/api-services/modules/super-admin/index.js +8 -0
  40. package/api-services/modules/supplier/index.d.ts +6 -0
  41. package/api-services/modules/supplier/index.js +7 -0
  42. package/api-services/modules/supplychain-manage/index.d.ts +2 -0
  43. package/api-services/modules/supplychain-manage/index.js +5 -0
  44. package/api-services/modules/systemConfiguration/index.d.ts +2 -0
  45. package/api-services/modules/systemConfiguration/index.js +5 -0
  46. package/api-services/modules/tool/index.d.ts +2 -0
  47. package/api-services/modules/tool/index.js +5 -0
  48. package/api-services/src/create-service/index.d.ts +1 -0
  49. package/api-services/src/create-service/index.js +4 -0
  50. package/common-info/getIframeUrl/index.d.ts +9 -0
  51. package/common-info/getIframeUrl/index.js +10 -0
  52. package/common-info/getInfoFromUrl/index.d.ts +8 -0
  53. package/common-info/getInfoFromUrl/index.js +84 -0
  54. package/common-info/getInfoFromUrl/index.js.gz +0 -0
  55. package/common-info/set-personal-info/index.d.ts +5 -0
  56. package/common-info/set-personal-info/index.js +1664 -0
  57. package/common-info/set-personal-info/index.js.gz +0 -0
  58. package/common-info/type.d.ts +104 -0
  59. package/common-tools/arr-tools/index.d.ts +15 -0
  60. package/common-tools/arr-tools/index.js +8 -0
  61. package/common-tools/date-format/index.d.ts +7 -0
  62. package/common-tools/date-format/index.js +18 -0
  63. package/common-tools/get-url-params/index.d.ts +46 -0
  64. package/common-tools/get-url-params/index.js +60 -0
  65. package/common-tools/get-url-params/index.js.gz +0 -0
  66. package/common-tools/handle-data/index.d.ts +6 -0
  67. package/common-tools/handle-data/index.js +4 -0
  68. package/common-tools/nest-tree-format/index.d.ts +30 -0
  69. package/common-tools/nest-tree-format/index.js +24 -0
  70. package/common-tools/obj-tools/index.d.ts +7 -0
  71. package/common-tools/obj-tools/index.js +14 -0
  72. package/common-tools/platform-tools/index.d.ts +18 -0
  73. package/common-tools/platform-tools/index.js +14 -0
  74. package/common-tools/queue-promise/index.d.ts +6 -0
  75. package/common-tools/queue-promise/index.js +9 -0
  76. package/common-tools/setHtmlMinWH/index.d.ts +5 -0
  77. package/common-tools/setHtmlMinWH/index.js +11 -0
  78. package/common-tools/update-fav-icon/index.d.ts +11 -0
  79. package/common-tools/update-fav-icon/index.js +21 -0
  80. package/create-api-service/proxy-sso/index.d.ts +3 -0
  81. package/create-api-service/proxy-sso/index.js +21 -0
  82. package/create-api-service/sso/index.d.ts +23 -0
  83. package/create-api-service/sso/index.js +1946 -0
  84. package/create-api-service/sso/index.js.gz +0 -0
  85. package/curring-http/type.d.ts +89 -0
  86. package/esm-map.json +3 -3
  87. package/package.json +3 -3
  88. package/webSocket-service/type.d.ts +28 -0
@@ -0,0 +1,1664 @@
1
+ import { getProjectInfo as ve } from "@das-fed/utils/common-info";
2
+ import { getConfig as Ge } from "@das-fed/utils/config";
3
+ function Te(e, t) {
4
+ return function() {
5
+ return e.apply(t, arguments);
6
+ };
7
+ }
8
+ const { toString: Xe } = Object.prototype, { getPrototypeOf: oe } = Object, J = /* @__PURE__ */ ((e) => (t) => {
9
+ const n = Xe.call(t);
10
+ return e[n] || (e[n] = n.slice(8, -1).toLowerCase());
11
+ })(/* @__PURE__ */ Object.create(null)), A = (e) => (e = e.toLowerCase(), (t) => J(t) === e), V = (e) => (t) => typeof t === e, { isArray: _ } = Array, k = V("undefined");
12
+ function Qe(e) {
13
+ return e !== null && !k(e) && e.constructor !== null && !k(e.constructor) && O(e.constructor.isBuffer) && e.constructor.isBuffer(e);
14
+ }
15
+ const Ae = A("ArrayBuffer");
16
+ function Ze(e) {
17
+ let t;
18
+ return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? t = ArrayBuffer.isView(e) : t = e && e.buffer && Ae(e.buffer), t;
19
+ }
20
+ const Ye = V("string"), O = V("function"), xe = V("number"), W = (e) => e !== null && typeof e == "object", et = (e) => e === !0 || e === !1, I = (e) => {
21
+ if (J(e) !== "object")
22
+ return !1;
23
+ const t = oe(e);
24
+ return (t === null || t === Object.prototype || Object.getPrototypeOf(t) === null) && !(Symbol.toStringTag in e) && !(Symbol.iterator in e);
25
+ }, tt = A("Date"), nt = A("File"), rt = A("Blob"), st = A("FileList"), ot = (e) => W(e) && O(e.pipe), it = (e) => {
26
+ let t;
27
+ return e && (typeof FormData == "function" && e instanceof FormData || O(e.append) && ((t = J(e)) === "formdata" || // detect form-data instance
28
+ t === "object" && O(e.toString) && e.toString() === "[object FormData]"));
29
+ }, at = A("URLSearchParams"), [ct, ut, lt, ft] = ["ReadableStream", "Request", "Response", "Headers"].map(A), dt = (e) => e.trim ? e.trim() : e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
30
+ function j(e, t, { allOwnKeys: n = !1 } = {}) {
31
+ if (e === null || typeof e > "u")
32
+ return;
33
+ let r, s;
34
+ if (typeof e != "object" && (e = [e]), _(e))
35
+ for (r = 0, s = e.length; r < s; r++)
36
+ t.call(null, e[r], r, e);
37
+ else {
38
+ const o = n ? Object.getOwnPropertyNames(e) : Object.keys(e), i = o.length;
39
+ let c;
40
+ for (r = 0; r < i; r++)
41
+ c = o[r], t.call(null, e[c], c, e);
42
+ }
43
+ }
44
+ function Ce(e, t) {
45
+ t = t.toLowerCase();
46
+ const n = Object.keys(e);
47
+ let r = n.length, s;
48
+ for (; r-- > 0; )
49
+ if (s = n[r], t === s.toLowerCase())
50
+ return s;
51
+ return null;
52
+ }
53
+ const Ne = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : global, Pe = (e) => !k(e) && e !== Ne;
54
+ function Z() {
55
+ const { caseless: e } = Pe(this) && this || {}, t = {}, n = (r, s) => {
56
+ const o = e && Ce(t, s) || s;
57
+ I(t[o]) && I(r) ? t[o] = Z(t[o], r) : I(r) ? t[o] = Z({}, r) : _(r) ? t[o] = r.slice() : t[o] = r;
58
+ };
59
+ for (let r = 0, s = arguments.length; r < s; r++)
60
+ arguments[r] && j(arguments[r], n);
61
+ return t;
62
+ }
63
+ const pt = (e, t, n, { allOwnKeys: r } = {}) => (j(t, (s, o) => {
64
+ n && O(s) ? e[o] = Te(s, n) : e[o] = s;
65
+ }, { allOwnKeys: r }), e), ht = (e) => (e.charCodeAt(0) === 65279 && (e = e.slice(1)), e), mt = (e, t, n, r) => {
66
+ e.prototype = Object.create(t.prototype, r), e.prototype.constructor = e, Object.defineProperty(e, "super", {
67
+ value: t.prototype
68
+ }), n && Object.assign(e.prototype, n);
69
+ }, yt = (e, t, n, r) => {
70
+ let s, o, i;
71
+ const c = {};
72
+ if (t = t || {}, e == null) return t;
73
+ do {
74
+ for (s = Object.getOwnPropertyNames(e), o = s.length; o-- > 0; )
75
+ i = s[o], (!r || r(i, e, t)) && !c[i] && (t[i] = e[i], c[i] = !0);
76
+ e = n !== !1 && oe(e);
77
+ } while (e && (!n || n(e, t)) && e !== Object.prototype);
78
+ return t;
79
+ }, wt = (e, t, n) => {
80
+ e = String(e), (n === void 0 || n > e.length) && (n = e.length), n -= t.length;
81
+ const r = e.indexOf(t, n);
82
+ return r !== -1 && r === n;
83
+ }, bt = (e) => {
84
+ if (!e) return null;
85
+ if (_(e)) return e;
86
+ let t = e.length;
87
+ if (!xe(t)) return null;
88
+ const n = new Array(t);
89
+ for (; t-- > 0; )
90
+ n[t] = e[t];
91
+ return n;
92
+ }, Et = /* @__PURE__ */ ((e) => (t) => e && t instanceof e)(typeof Uint8Array < "u" && oe(Uint8Array)), Rt = (e, t) => {
93
+ const r = (e && e[Symbol.iterator]).call(e);
94
+ let s;
95
+ for (; (s = r.next()) && !s.done; ) {
96
+ const o = s.value;
97
+ t.call(e, o[0], o[1]);
98
+ }
99
+ }, gt = (e, t) => {
100
+ let n;
101
+ const r = [];
102
+ for (; (n = e.exec(t)) !== null; )
103
+ r.push(n);
104
+ return r;
105
+ }, St = A("HTMLFormElement"), Ot = (e) => e.toLowerCase().replace(
106
+ /[-_\s]([a-z\d])(\w*)/g,
107
+ function(n, r, s) {
108
+ return r.toUpperCase() + s;
109
+ }
110
+ ), fe = (({ hasOwnProperty: e }) => (t, n) => e.call(t, n))(Object.prototype), Tt = A("RegExp"), Fe = (e, t) => {
111
+ const n = Object.getOwnPropertyDescriptors(e), r = {};
112
+ j(n, (s, o) => {
113
+ let i;
114
+ (i = t(s, o, e)) !== !1 && (r[o] = i || s);
115
+ }), Object.defineProperties(e, r);
116
+ }, At = (e) => {
117
+ Fe(e, (t, n) => {
118
+ if (O(e) && ["arguments", "caller", "callee"].indexOf(n) !== -1)
119
+ return !1;
120
+ const r = e[n];
121
+ if (O(r)) {
122
+ if (t.enumerable = !1, "writable" in t) {
123
+ t.writable = !1;
124
+ return;
125
+ }
126
+ t.set || (t.set = () => {
127
+ throw Error("Can not rewrite read-only method '" + n + "'");
128
+ });
129
+ }
130
+ });
131
+ }, xt = (e, t) => {
132
+ const n = {}, r = (s) => {
133
+ s.forEach((o) => {
134
+ n[o] = !0;
135
+ });
136
+ };
137
+ return _(e) ? r(e) : r(String(e).split(t)), n;
138
+ }, Ct = () => {
139
+ }, Nt = (e, t) => e != null && Number.isFinite(e = +e) ? e : t, v = "abcdefghijklmnopqrstuvwxyz", de = "0123456789", Le = {
140
+ DIGIT: de,
141
+ ALPHA: v,
142
+ ALPHA_DIGIT: v + v.toUpperCase() + de
143
+ }, Pt = (e = 16, t = Le.ALPHA_DIGIT) => {
144
+ let n = "";
145
+ const { length: r } = t;
146
+ for (; e--; )
147
+ n += t[Math.random() * r | 0];
148
+ return n;
149
+ };
150
+ function Ft(e) {
151
+ return !!(e && O(e.append) && e[Symbol.toStringTag] === "FormData" && e[Symbol.iterator]);
152
+ }
153
+ const Lt = (e) => {
154
+ const t = new Array(10), n = (r, s) => {
155
+ if (W(r)) {
156
+ if (t.indexOf(r) >= 0)
157
+ return;
158
+ if (!("toJSON" in r)) {
159
+ t[s] = r;
160
+ const o = _(r) ? [] : {};
161
+ return j(r, (i, c) => {
162
+ const f = n(i, s + 1);
163
+ !k(f) && (o[c] = f);
164
+ }), t[s] = void 0, o;
165
+ }
166
+ }
167
+ return r;
168
+ };
169
+ return n(e, 0);
170
+ }, _t = A("AsyncFunction"), Bt = (e) => e && (W(e) || O(e)) && O(e.then) && O(e.catch), a = {
171
+ isArray: _,
172
+ isArrayBuffer: Ae,
173
+ isBuffer: Qe,
174
+ isFormData: it,
175
+ isArrayBufferView: Ze,
176
+ isString: Ye,
177
+ isNumber: xe,
178
+ isBoolean: et,
179
+ isObject: W,
180
+ isPlainObject: I,
181
+ isReadableStream: ct,
182
+ isRequest: ut,
183
+ isResponse: lt,
184
+ isHeaders: ft,
185
+ isUndefined: k,
186
+ isDate: tt,
187
+ isFile: nt,
188
+ isBlob: rt,
189
+ isRegExp: Tt,
190
+ isFunction: O,
191
+ isStream: ot,
192
+ isURLSearchParams: at,
193
+ isTypedArray: Et,
194
+ isFileList: st,
195
+ forEach: j,
196
+ merge: Z,
197
+ extend: pt,
198
+ trim: dt,
199
+ stripBOM: ht,
200
+ inherits: mt,
201
+ toFlatObject: yt,
202
+ kindOf: J,
203
+ kindOfTest: A,
204
+ endsWith: wt,
205
+ toArray: bt,
206
+ forEachEntry: Rt,
207
+ matchAll: gt,
208
+ isHTMLForm: St,
209
+ hasOwnProperty: fe,
210
+ hasOwnProp: fe,
211
+ // an alias to avoid ESLint no-prototype-builtins detection
212
+ reduceDescriptors: Fe,
213
+ freezeMethods: At,
214
+ toObjectSet: xt,
215
+ toCamelCase: Ot,
216
+ noop: Ct,
217
+ toFiniteNumber: Nt,
218
+ findKey: Ce,
219
+ global: Ne,
220
+ isContextDefined: Pe,
221
+ ALPHABET: Le,
222
+ generateString: Pt,
223
+ isSpecCompliantForm: Ft,
224
+ toJSONObject: Lt,
225
+ isAsyncFn: _t,
226
+ isThenable: Bt
227
+ };
228
+ function h(e, t, n, r, s) {
229
+ Error.call(this), Error.captureStackTrace ? Error.captureStackTrace(this, this.constructor) : this.stack = new Error().stack, this.message = e, this.name = "AxiosError", t && (this.code = t), n && (this.config = n), r && (this.request = r), s && (this.response = s);
230
+ }
231
+ a.inherits(h, Error, {
232
+ toJSON: function() {
233
+ return {
234
+ // Standard
235
+ message: this.message,
236
+ name: this.name,
237
+ // Microsoft
238
+ description: this.description,
239
+ number: this.number,
240
+ // Mozilla
241
+ fileName: this.fileName,
242
+ lineNumber: this.lineNumber,
243
+ columnNumber: this.columnNumber,
244
+ stack: this.stack,
245
+ // Axios
246
+ config: a.toJSONObject(this.config),
247
+ code: this.code,
248
+ status: this.response && this.response.status ? this.response.status : null
249
+ };
250
+ }
251
+ });
252
+ const _e = h.prototype, Be = {};
253
+ [
254
+ "ERR_BAD_OPTION_VALUE",
255
+ "ERR_BAD_OPTION",
256
+ "ECONNABORTED",
257
+ "ETIMEDOUT",
258
+ "ERR_NETWORK",
259
+ "ERR_FR_TOO_MANY_REDIRECTS",
260
+ "ERR_DEPRECATED",
261
+ "ERR_BAD_RESPONSE",
262
+ "ERR_BAD_REQUEST",
263
+ "ERR_CANCELED",
264
+ "ERR_NOT_SUPPORT",
265
+ "ERR_INVALID_URL"
266
+ // eslint-disable-next-line func-names
267
+ ].forEach((e) => {
268
+ Be[e] = { value: e };
269
+ });
270
+ Object.defineProperties(h, Be);
271
+ Object.defineProperty(_e, "isAxiosError", { value: !0 });
272
+ h.from = (e, t, n, r, s, o) => {
273
+ const i = Object.create(_e);
274
+ return a.toFlatObject(e, i, function(f) {
275
+ return f !== Error.prototype;
276
+ }, (c) => c !== "isAxiosError"), h.call(i, e.message, t, n, r, s), i.cause = e, i.name = e.name, o && Object.assign(i, o), i;
277
+ };
278
+ const Dt = null;
279
+ function Y(e) {
280
+ return a.isPlainObject(e) || a.isArray(e);
281
+ }
282
+ function De(e) {
283
+ return a.endsWith(e, "[]") ? e.slice(0, -2) : e;
284
+ }
285
+ function pe(e, t, n) {
286
+ return e ? e.concat(t).map(function(s, o) {
287
+ return s = De(s), !n && o ? "[" + s + "]" : s;
288
+ }).join(n ? "." : "") : t;
289
+ }
290
+ function Ut(e) {
291
+ return a.isArray(e) && !e.some(Y);
292
+ }
293
+ const kt = a.toFlatObject(a, {}, null, function(t) {
294
+ return /^is[A-Z]/.test(t);
295
+ });
296
+ function $(e, t, n) {
297
+ if (!a.isObject(e))
298
+ throw new TypeError("target must be an object");
299
+ t = t || new FormData(), n = a.toFlatObject(n, {
300
+ metaTokens: !0,
301
+ dots: !1,
302
+ indexes: !1
303
+ }, !1, function(m, R) {
304
+ return !a.isUndefined(R[m]);
305
+ });
306
+ const r = n.metaTokens, s = n.visitor || u, o = n.dots, i = n.indexes, f = (n.Blob || typeof Blob < "u" && Blob) && a.isSpecCompliantForm(t);
307
+ if (!a.isFunction(s))
308
+ throw new TypeError("visitor must be a function");
309
+ function l(d) {
310
+ if (d === null) return "";
311
+ if (a.isDate(d))
312
+ return d.toISOString();
313
+ if (!f && a.isBlob(d))
314
+ throw new h("Blob is not supported. Use a Buffer instead.");
315
+ return a.isArrayBuffer(d) || a.isTypedArray(d) ? f && typeof Blob == "function" ? new Blob([d]) : Buffer.from(d) : d;
316
+ }
317
+ function u(d, m, R) {
318
+ let g = d;
319
+ if (d && !R && typeof d == "object") {
320
+ if (a.endsWith(m, "{}"))
321
+ m = r ? m : m.slice(0, -2), d = JSON.stringify(d);
322
+ else if (a.isArray(d) && Ut(d) || (a.isFileList(d) || a.endsWith(m, "[]")) && (g = a.toArray(d)))
323
+ return m = De(m), g.forEach(function(w, D) {
324
+ !(a.isUndefined(w) || w === null) && t.append(
325
+ // eslint-disable-next-line no-nested-ternary
326
+ i === !0 ? pe([m], D, o) : i === null ? m : m + "[]",
327
+ l(w)
328
+ );
329
+ }), !1;
330
+ }
331
+ return Y(d) ? !0 : (t.append(pe(R, m, o), l(d)), !1);
332
+ }
333
+ const p = [], b = Object.assign(kt, {
334
+ defaultVisitor: u,
335
+ convertValue: l,
336
+ isVisitable: Y
337
+ });
338
+ function y(d, m) {
339
+ if (!a.isUndefined(d)) {
340
+ if (p.indexOf(d) !== -1)
341
+ throw Error("Circular reference detected in " + m.join("."));
342
+ p.push(d), a.forEach(d, function(g, x) {
343
+ (!(a.isUndefined(g) || g === null) && s.call(
344
+ t,
345
+ g,
346
+ a.isString(x) ? x.trim() : x,
347
+ m,
348
+ b
349
+ )) === !0 && y(g, m ? m.concat(x) : [x]);
350
+ }), p.pop();
351
+ }
352
+ }
353
+ if (!a.isObject(e))
354
+ throw new TypeError("data must be an object");
355
+ return y(e), t;
356
+ }
357
+ function he(e) {
358
+ const t = {
359
+ "!": "%21",
360
+ "'": "%27",
361
+ "(": "%28",
362
+ ")": "%29",
363
+ "~": "%7E",
364
+ "%20": "+",
365
+ "%00": "\0"
366
+ };
367
+ return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g, function(r) {
368
+ return t[r];
369
+ });
370
+ }
371
+ function ie(e, t) {
372
+ this._pairs = [], e && $(e, this, t);
373
+ }
374
+ const Ue = ie.prototype;
375
+ Ue.append = function(t, n) {
376
+ this._pairs.push([t, n]);
377
+ };
378
+ Ue.toString = function(t) {
379
+ const n = t ? function(r) {
380
+ return t.call(this, r, he);
381
+ } : he;
382
+ return this._pairs.map(function(s) {
383
+ return n(s[0]) + "=" + n(s[1]);
384
+ }, "").join("&");
385
+ };
386
+ function jt(e) {
387
+ return encodeURIComponent(e).replace(/%3A/gi, ":").replace(/%24/g, "$").replace(/%2C/gi, ",").replace(/%20/g, "+").replace(/%5B/gi, "[").replace(/%5D/gi, "]");
388
+ }
389
+ function ke(e, t, n) {
390
+ if (!t)
391
+ return e;
392
+ const r = n && n.encode || jt, s = n && n.serialize;
393
+ let o;
394
+ if (s ? o = s(t, n) : o = a.isURLSearchParams(t) ? t.toString() : new ie(t, n).toString(r), o) {
395
+ const i = e.indexOf("#");
396
+ i !== -1 && (e = e.slice(0, i)), e += (e.indexOf("?") === -1 ? "?" : "&") + o;
397
+ }
398
+ return e;
399
+ }
400
+ class me {
401
+ constructor() {
402
+ this.handlers = [];
403
+ }
404
+ /**
405
+ * Add a new interceptor to the stack
406
+ *
407
+ * @param {Function} fulfilled The function to handle `then` for a `Promise`
408
+ * @param {Function} rejected The function to handle `reject` for a `Promise`
409
+ *
410
+ * @return {Number} An ID used to remove interceptor later
411
+ */
412
+ use(t, n, r) {
413
+ return this.handlers.push({
414
+ fulfilled: t,
415
+ rejected: n,
416
+ synchronous: r ? r.synchronous : !1,
417
+ runWhen: r ? r.runWhen : null
418
+ }), this.handlers.length - 1;
419
+ }
420
+ /**
421
+ * Remove an interceptor from the stack
422
+ *
423
+ * @param {Number} id The ID that was returned by `use`
424
+ *
425
+ * @returns {Boolean} `true` if the interceptor was removed, `false` otherwise
426
+ */
427
+ eject(t) {
428
+ this.handlers[t] && (this.handlers[t] = null);
429
+ }
430
+ /**
431
+ * Clear all interceptors from the stack
432
+ *
433
+ * @returns {void}
434
+ */
435
+ clear() {
436
+ this.handlers && (this.handlers = []);
437
+ }
438
+ /**
439
+ * Iterate over all the registered interceptors
440
+ *
441
+ * This method is particularly useful for skipping over any
442
+ * interceptors that may have become `null` calling `eject`.
443
+ *
444
+ * @param {Function} fn The function to call for each interceptor
445
+ *
446
+ * @returns {void}
447
+ */
448
+ forEach(t) {
449
+ a.forEach(this.handlers, function(r) {
450
+ r !== null && t(r);
451
+ });
452
+ }
453
+ }
454
+ const je = {
455
+ silentJSONParsing: !0,
456
+ forcedJSONParsing: !0,
457
+ clarifyTimeoutError: !1
458
+ }, qt = typeof URLSearchParams < "u" ? URLSearchParams : ie, It = typeof FormData < "u" ? FormData : null, Ht = typeof Blob < "u" ? Blob : null, Mt = {
459
+ isBrowser: !0,
460
+ classes: {
461
+ URLSearchParams: qt,
462
+ FormData: It,
463
+ Blob: Ht
464
+ },
465
+ protocols: ["http", "https", "file", "blob", "url", "data"]
466
+ }, ae = typeof window < "u" && typeof document < "u", zt = ((e) => ae && ["ReactNative", "NativeScript", "NS"].indexOf(e) < 0)(typeof navigator < "u" && navigator.product), Jt = typeof WorkerGlobalScope < "u" && // eslint-disable-next-line no-undef
467
+ self instanceof WorkerGlobalScope && typeof self.importScripts == "function", Vt = ae && window.location.href || "http://localhost", Wt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
468
+ __proto__: null,
469
+ hasBrowserEnv: ae,
470
+ hasStandardBrowserEnv: zt,
471
+ hasStandardBrowserWebWorkerEnv: Jt,
472
+ origin: Vt
473
+ }, Symbol.toStringTag, { value: "Module" })), T = {
474
+ ...Wt,
475
+ ...Mt
476
+ };
477
+ function $t(e, t) {
478
+ return $(e, new T.classes.URLSearchParams(), Object.assign({
479
+ visitor: function(n, r, s, o) {
480
+ return T.isNode && a.isBuffer(n) ? (this.append(r, n.toString("base64")), !1) : o.defaultVisitor.apply(this, arguments);
481
+ }
482
+ }, t));
483
+ }
484
+ function Kt(e) {
485
+ return a.matchAll(/\w+|\[(\w*)]/g, e).map((t) => t[0] === "[]" ? "" : t[1] || t[0]);
486
+ }
487
+ function vt(e) {
488
+ const t = {}, n = Object.keys(e);
489
+ let r;
490
+ const s = n.length;
491
+ let o;
492
+ for (r = 0; r < s; r++)
493
+ o = n[r], t[o] = e[o];
494
+ return t;
495
+ }
496
+ function qe(e) {
497
+ function t(n, r, s, o) {
498
+ let i = n[o++];
499
+ if (i === "__proto__") return !0;
500
+ const c = Number.isFinite(+i), f = o >= n.length;
501
+ return i = !i && a.isArray(s) ? s.length : i, f ? (a.hasOwnProp(s, i) ? s[i] = [s[i], r] : s[i] = r, !c) : ((!s[i] || !a.isObject(s[i])) && (s[i] = []), t(n, r, s[i], o) && a.isArray(s[i]) && (s[i] = vt(s[i])), !c);
502
+ }
503
+ if (a.isFormData(e) && a.isFunction(e.entries)) {
504
+ const n = {};
505
+ return a.forEachEntry(e, (r, s) => {
506
+ t(Kt(r), s, n, 0);
507
+ }), n;
508
+ }
509
+ return null;
510
+ }
511
+ function Gt(e, t, n) {
512
+ if (a.isString(e))
513
+ try {
514
+ return (t || JSON.parse)(e), a.trim(e);
515
+ } catch (r) {
516
+ if (r.name !== "SyntaxError")
517
+ throw r;
518
+ }
519
+ return (n || JSON.stringify)(e);
520
+ }
521
+ const q = {
522
+ transitional: je,
523
+ adapter: ["xhr", "http", "fetch"],
524
+ transformRequest: [function(t, n) {
525
+ const r = n.getContentType() || "", s = r.indexOf("application/json") > -1, o = a.isObject(t);
526
+ if (o && a.isHTMLForm(t) && (t = new FormData(t)), a.isFormData(t))
527
+ return s ? JSON.stringify(qe(t)) : t;
528
+ if (a.isArrayBuffer(t) || a.isBuffer(t) || a.isStream(t) || a.isFile(t) || a.isBlob(t) || a.isReadableStream(t))
529
+ return t;
530
+ if (a.isArrayBufferView(t))
531
+ return t.buffer;
532
+ if (a.isURLSearchParams(t))
533
+ return n.setContentType("application/x-www-form-urlencoded;charset=utf-8", !1), t.toString();
534
+ let c;
535
+ if (o) {
536
+ if (r.indexOf("application/x-www-form-urlencoded") > -1)
537
+ return $t(t, this.formSerializer).toString();
538
+ if ((c = a.isFileList(t)) || r.indexOf("multipart/form-data") > -1) {
539
+ const f = this.env && this.env.FormData;
540
+ return $(
541
+ c ? { "files[]": t } : t,
542
+ f && new f(),
543
+ this.formSerializer
544
+ );
545
+ }
546
+ }
547
+ return o || s ? (n.setContentType("application/json", !1), Gt(t)) : t;
548
+ }],
549
+ transformResponse: [function(t) {
550
+ const n = this.transitional || q.transitional, r = n && n.forcedJSONParsing, s = this.responseType === "json";
551
+ if (a.isResponse(t) || a.isReadableStream(t))
552
+ return t;
553
+ if (t && a.isString(t) && (r && !this.responseType || s)) {
554
+ const i = !(n && n.silentJSONParsing) && s;
555
+ try {
556
+ return JSON.parse(t);
557
+ } catch (c) {
558
+ if (i)
559
+ throw c.name === "SyntaxError" ? h.from(c, h.ERR_BAD_RESPONSE, this, null, this.response) : c;
560
+ }
561
+ }
562
+ return t;
563
+ }],
564
+ /**
565
+ * A timeout in milliseconds to abort a request. If set to 0 (default) a
566
+ * timeout is not created.
567
+ */
568
+ timeout: 0,
569
+ xsrfCookieName: "XSRF-TOKEN",
570
+ xsrfHeaderName: "X-XSRF-TOKEN",
571
+ maxContentLength: -1,
572
+ maxBodyLength: -1,
573
+ env: {
574
+ FormData: T.classes.FormData,
575
+ Blob: T.classes.Blob
576
+ },
577
+ validateStatus: function(t) {
578
+ return t >= 200 && t < 300;
579
+ },
580
+ headers: {
581
+ common: {
582
+ Accept: "application/json, text/plain, */*",
583
+ "Content-Type": void 0
584
+ }
585
+ }
586
+ };
587
+ a.forEach(["delete", "get", "head", "post", "put", "patch"], (e) => {
588
+ q.headers[e] = {};
589
+ });
590
+ const Xt = a.toObjectSet([
591
+ "age",
592
+ "authorization",
593
+ "content-length",
594
+ "content-type",
595
+ "etag",
596
+ "expires",
597
+ "from",
598
+ "host",
599
+ "if-modified-since",
600
+ "if-unmodified-since",
601
+ "last-modified",
602
+ "location",
603
+ "max-forwards",
604
+ "proxy-authorization",
605
+ "referer",
606
+ "retry-after",
607
+ "user-agent"
608
+ ]), Qt = (e) => {
609
+ const t = {};
610
+ let n, r, s;
611
+ return e && e.split(`
612
+ `).forEach(function(i) {
613
+ s = i.indexOf(":"), n = i.substring(0, s).trim().toLowerCase(), r = i.substring(s + 1).trim(), !(!n || t[n] && Xt[n]) && (n === "set-cookie" ? t[n] ? t[n].push(r) : t[n] = [r] : t[n] = t[n] ? t[n] + ", " + r : r);
614
+ }), t;
615
+ }, ye = Symbol("internals");
616
+ function U(e) {
617
+ return e && String(e).trim().toLowerCase();
618
+ }
619
+ function H(e) {
620
+ return e === !1 || e == null ? e : a.isArray(e) ? e.map(H) : String(e);
621
+ }
622
+ function Zt(e) {
623
+ const t = /* @__PURE__ */ Object.create(null), n = /([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;
624
+ let r;
625
+ for (; r = n.exec(e); )
626
+ t[r[1]] = r[2];
627
+ return t;
628
+ }
629
+ const Yt = (e) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());
630
+ function G(e, t, n, r, s) {
631
+ if (a.isFunction(r))
632
+ return r.call(this, t, n);
633
+ if (s && (t = n), !!a.isString(t)) {
634
+ if (a.isString(r))
635
+ return t.indexOf(r) !== -1;
636
+ if (a.isRegExp(r))
637
+ return r.test(t);
638
+ }
639
+ }
640
+ function en(e) {
641
+ return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (t, n, r) => n.toUpperCase() + r);
642
+ }
643
+ function tn(e, t) {
644
+ const n = a.toCamelCase(" " + t);
645
+ ["get", "set", "has"].forEach((r) => {
646
+ Object.defineProperty(e, r + n, {
647
+ value: function(s, o, i) {
648
+ return this[r].call(this, t, s, o, i);
649
+ },
650
+ configurable: !0
651
+ });
652
+ });
653
+ }
654
+ class S {
655
+ constructor(t) {
656
+ t && this.set(t);
657
+ }
658
+ set(t, n, r) {
659
+ const s = this;
660
+ function o(c, f, l) {
661
+ const u = U(f);
662
+ if (!u)
663
+ throw new Error("header name must be a non-empty string");
664
+ const p = a.findKey(s, u);
665
+ (!p || s[p] === void 0 || l === !0 || l === void 0 && s[p] !== !1) && (s[p || f] = H(c));
666
+ }
667
+ const i = (c, f) => a.forEach(c, (l, u) => o(l, u, f));
668
+ if (a.isPlainObject(t) || t instanceof this.constructor)
669
+ i(t, n);
670
+ else if (a.isString(t) && (t = t.trim()) && !Yt(t))
671
+ i(Qt(t), n);
672
+ else if (a.isHeaders(t))
673
+ for (const [c, f] of t.entries())
674
+ o(f, c, r);
675
+ else
676
+ t != null && o(n, t, r);
677
+ return this;
678
+ }
679
+ get(t, n) {
680
+ if (t = U(t), t) {
681
+ const r = a.findKey(this, t);
682
+ if (r) {
683
+ const s = this[r];
684
+ if (!n)
685
+ return s;
686
+ if (n === !0)
687
+ return Zt(s);
688
+ if (a.isFunction(n))
689
+ return n.call(this, s, r);
690
+ if (a.isRegExp(n))
691
+ return n.exec(s);
692
+ throw new TypeError("parser must be boolean|regexp|function");
693
+ }
694
+ }
695
+ }
696
+ has(t, n) {
697
+ if (t = U(t), t) {
698
+ const r = a.findKey(this, t);
699
+ return !!(r && this[r] !== void 0 && (!n || G(this, this[r], r, n)));
700
+ }
701
+ return !1;
702
+ }
703
+ delete(t, n) {
704
+ const r = this;
705
+ let s = !1;
706
+ function o(i) {
707
+ if (i = U(i), i) {
708
+ const c = a.findKey(r, i);
709
+ c && (!n || G(r, r[c], c, n)) && (delete r[c], s = !0);
710
+ }
711
+ }
712
+ return a.isArray(t) ? t.forEach(o) : o(t), s;
713
+ }
714
+ clear(t) {
715
+ const n = Object.keys(this);
716
+ let r = n.length, s = !1;
717
+ for (; r--; ) {
718
+ const o = n[r];
719
+ (!t || G(this, this[o], o, t, !0)) && (delete this[o], s = !0);
720
+ }
721
+ return s;
722
+ }
723
+ normalize(t) {
724
+ const n = this, r = {};
725
+ return a.forEach(this, (s, o) => {
726
+ const i = a.findKey(r, o);
727
+ if (i) {
728
+ n[i] = H(s), delete n[o];
729
+ return;
730
+ }
731
+ const c = t ? en(o) : String(o).trim();
732
+ c !== o && delete n[o], n[c] = H(s), r[c] = !0;
733
+ }), this;
734
+ }
735
+ concat(...t) {
736
+ return this.constructor.concat(this, ...t);
737
+ }
738
+ toJSON(t) {
739
+ const n = /* @__PURE__ */ Object.create(null);
740
+ return a.forEach(this, (r, s) => {
741
+ r != null && r !== !1 && (n[s] = t && a.isArray(r) ? r.join(", ") : r);
742
+ }), n;
743
+ }
744
+ [Symbol.iterator]() {
745
+ return Object.entries(this.toJSON())[Symbol.iterator]();
746
+ }
747
+ toString() {
748
+ return Object.entries(this.toJSON()).map(([t, n]) => t + ": " + n).join(`
749
+ `);
750
+ }
751
+ get [Symbol.toStringTag]() {
752
+ return "AxiosHeaders";
753
+ }
754
+ static from(t) {
755
+ return t instanceof this ? t : new this(t);
756
+ }
757
+ static concat(t, ...n) {
758
+ const r = new this(t);
759
+ return n.forEach((s) => r.set(s)), r;
760
+ }
761
+ static accessor(t) {
762
+ const r = (this[ye] = this[ye] = {
763
+ accessors: {}
764
+ }).accessors, s = this.prototype;
765
+ function o(i) {
766
+ const c = U(i);
767
+ r[c] || (tn(s, i), r[c] = !0);
768
+ }
769
+ return a.isArray(t) ? t.forEach(o) : o(t), this;
770
+ }
771
+ }
772
+ S.accessor(["Content-Type", "Content-Length", "Accept", "Accept-Encoding", "User-Agent", "Authorization"]);
773
+ a.reduceDescriptors(S.prototype, ({ value: e }, t) => {
774
+ let n = t[0].toUpperCase() + t.slice(1);
775
+ return {
776
+ get: () => e,
777
+ set(r) {
778
+ this[n] = r;
779
+ }
780
+ };
781
+ });
782
+ a.freezeMethods(S);
783
+ function X(e, t) {
784
+ const n = this || q, r = t || n, s = S.from(r.headers);
785
+ let o = r.data;
786
+ return a.forEach(e, function(c) {
787
+ o = c.call(n, o, s.normalize(), t ? t.status : void 0);
788
+ }), s.normalize(), o;
789
+ }
790
+ function Ie(e) {
791
+ return !!(e && e.__CANCEL__);
792
+ }
793
+ function B(e, t, n) {
794
+ h.call(this, e ?? "canceled", h.ERR_CANCELED, t, n), this.name = "CanceledError";
795
+ }
796
+ a.inherits(B, h, {
797
+ __CANCEL__: !0
798
+ });
799
+ function He(e, t, n) {
800
+ const r = n.config.validateStatus;
801
+ !n.status || !r || r(n.status) ? e(n) : t(new h(
802
+ "Request failed with status code " + n.status,
803
+ [h.ERR_BAD_REQUEST, h.ERR_BAD_RESPONSE][Math.floor(n.status / 100) - 4],
804
+ n.config,
805
+ n.request,
806
+ n
807
+ ));
808
+ }
809
+ function nn(e) {
810
+ const t = /^([-+\w]{1,25})(:?\/\/|:)/.exec(e);
811
+ return t && t[1] || "";
812
+ }
813
+ function rn(e, t) {
814
+ e = e || 10;
815
+ const n = new Array(e), r = new Array(e);
816
+ let s = 0, o = 0, i;
817
+ return t = t !== void 0 ? t : 1e3, function(f) {
818
+ const l = Date.now(), u = r[o];
819
+ i || (i = l), n[s] = f, r[s] = l;
820
+ let p = o, b = 0;
821
+ for (; p !== s; )
822
+ b += n[p++], p = p % e;
823
+ if (s = (s + 1) % e, s === o && (o = (o + 1) % e), l - i < t)
824
+ return;
825
+ const y = u && l - u;
826
+ return y ? Math.round(b * 1e3 / y) : void 0;
827
+ };
828
+ }
829
+ function sn(e, t) {
830
+ let n = 0;
831
+ const r = 1e3 / t;
832
+ let s = null;
833
+ return function() {
834
+ const i = this === !0, c = Date.now();
835
+ if (i || c - n > r)
836
+ return s && (clearTimeout(s), s = null), n = c, e.apply(null, arguments);
837
+ s || (s = setTimeout(() => (s = null, n = Date.now(), e.apply(null, arguments)), r - (c - n)));
838
+ };
839
+ }
840
+ const M = (e, t, n = 3) => {
841
+ let r = 0;
842
+ const s = rn(50, 250);
843
+ return sn((o) => {
844
+ const i = o.loaded, c = o.lengthComputable ? o.total : void 0, f = i - r, l = s(f), u = i <= c;
845
+ r = i;
846
+ const p = {
847
+ loaded: i,
848
+ total: c,
849
+ progress: c ? i / c : void 0,
850
+ bytes: f,
851
+ rate: l || void 0,
852
+ estimated: l && c && u ? (c - i) / l : void 0,
853
+ event: o,
854
+ lengthComputable: c != null
855
+ };
856
+ p[t ? "download" : "upload"] = !0, e(p);
857
+ }, n);
858
+ }, on = T.hasStandardBrowserEnv ? (
859
+ // Standard browser envs have full support of the APIs needed to test
860
+ // whether the request URL is of the same origin as current location.
861
+ function() {
862
+ const t = /(msie|trident)/i.test(navigator.userAgent), n = document.createElement("a");
863
+ let r;
864
+ function s(o) {
865
+ let i = o;
866
+ return t && (n.setAttribute("href", i), i = n.href), n.setAttribute("href", i), {
867
+ href: n.href,
868
+ protocol: n.protocol ? n.protocol.replace(/:$/, "") : "",
869
+ host: n.host,
870
+ search: n.search ? n.search.replace(/^\?/, "") : "",
871
+ hash: n.hash ? n.hash.replace(/^#/, "") : "",
872
+ hostname: n.hostname,
873
+ port: n.port,
874
+ pathname: n.pathname.charAt(0) === "/" ? n.pathname : "/" + n.pathname
875
+ };
876
+ }
877
+ return r = s(window.location.href), function(i) {
878
+ const c = a.isString(i) ? s(i) : i;
879
+ return c.protocol === r.protocol && c.host === r.host;
880
+ };
881
+ }()
882
+ ) : (
883
+ // Non standard browser envs (web workers, react-native) lack needed support.
884
+ /* @__PURE__ */ function() {
885
+ return function() {
886
+ return !0;
887
+ };
888
+ }()
889
+ ), an = T.hasStandardBrowserEnv ? (
890
+ // Standard browser envs support document.cookie
891
+ {
892
+ write(e, t, n, r, s, o) {
893
+ const i = [e + "=" + encodeURIComponent(t)];
894
+ a.isNumber(n) && i.push("expires=" + new Date(n).toGMTString()), a.isString(r) && i.push("path=" + r), a.isString(s) && i.push("domain=" + s), o === !0 && i.push("secure"), document.cookie = i.join("; ");
895
+ },
896
+ read(e) {
897
+ const t = document.cookie.match(new RegExp("(^|;\\s*)(" + e + ")=([^;]*)"));
898
+ return t ? decodeURIComponent(t[3]) : null;
899
+ },
900
+ remove(e) {
901
+ this.write(e, "", Date.now() - 864e5);
902
+ }
903
+ }
904
+ ) : (
905
+ // Non-standard browser env (web workers, react-native) lack needed support.
906
+ {
907
+ write() {
908
+ },
909
+ read() {
910
+ return null;
911
+ },
912
+ remove() {
913
+ }
914
+ }
915
+ );
916
+ function cn(e) {
917
+ return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(e);
918
+ }
919
+ function un(e, t) {
920
+ return t ? e.replace(/\/?\/$/, "") + "/" + t.replace(/^\/+/, "") : e;
921
+ }
922
+ function Me(e, t) {
923
+ return e && !cn(t) ? un(e, t) : t;
924
+ }
925
+ const we = (e) => e instanceof S ? { ...e } : e;
926
+ function F(e, t) {
927
+ t = t || {};
928
+ const n = {};
929
+ function r(l, u, p) {
930
+ return a.isPlainObject(l) && a.isPlainObject(u) ? a.merge.call({ caseless: p }, l, u) : a.isPlainObject(u) ? a.merge({}, u) : a.isArray(u) ? u.slice() : u;
931
+ }
932
+ function s(l, u, p) {
933
+ if (a.isUndefined(u)) {
934
+ if (!a.isUndefined(l))
935
+ return r(void 0, l, p);
936
+ } else return r(l, u, p);
937
+ }
938
+ function o(l, u) {
939
+ if (!a.isUndefined(u))
940
+ return r(void 0, u);
941
+ }
942
+ function i(l, u) {
943
+ if (a.isUndefined(u)) {
944
+ if (!a.isUndefined(l))
945
+ return r(void 0, l);
946
+ } else return r(void 0, u);
947
+ }
948
+ function c(l, u, p) {
949
+ if (p in t)
950
+ return r(l, u);
951
+ if (p in e)
952
+ return r(void 0, l);
953
+ }
954
+ const f = {
955
+ url: o,
956
+ method: o,
957
+ data: o,
958
+ baseURL: i,
959
+ transformRequest: i,
960
+ transformResponse: i,
961
+ paramsSerializer: i,
962
+ timeout: i,
963
+ timeoutMessage: i,
964
+ withCredentials: i,
965
+ withXSRFToken: i,
966
+ adapter: i,
967
+ responseType: i,
968
+ xsrfCookieName: i,
969
+ xsrfHeaderName: i,
970
+ onUploadProgress: i,
971
+ onDownloadProgress: i,
972
+ decompress: i,
973
+ maxContentLength: i,
974
+ maxBodyLength: i,
975
+ beforeRedirect: i,
976
+ transport: i,
977
+ httpAgent: i,
978
+ httpsAgent: i,
979
+ cancelToken: i,
980
+ socketPath: i,
981
+ responseEncoding: i,
982
+ validateStatus: c,
983
+ headers: (l, u) => s(we(l), we(u), !0)
984
+ };
985
+ return a.forEach(Object.keys(Object.assign({}, e, t)), function(u) {
986
+ const p = f[u] || s, b = p(e[u], t[u], u);
987
+ a.isUndefined(b) && p !== c || (n[u] = b);
988
+ }), n;
989
+ }
990
+ const ze = (e) => {
991
+ const t = F({}, e);
992
+ let { data: n, withXSRFToken: r, xsrfHeaderName: s, xsrfCookieName: o, headers: i, auth: c } = t;
993
+ t.headers = i = S.from(i), t.url = ke(Me(t.baseURL, t.url), e.params, e.paramsSerializer), c && i.set(
994
+ "Authorization",
995
+ "Basic " + btoa((c.username || "") + ":" + (c.password ? unescape(encodeURIComponent(c.password)) : ""))
996
+ );
997
+ let f;
998
+ if (a.isFormData(n)) {
999
+ if (T.hasStandardBrowserEnv || T.hasStandardBrowserWebWorkerEnv)
1000
+ i.setContentType(void 0);
1001
+ else if ((f = i.getContentType()) !== !1) {
1002
+ const [l, ...u] = f ? f.split(";").map((p) => p.trim()).filter(Boolean) : [];
1003
+ i.setContentType([l || "multipart/form-data", ...u].join("; "));
1004
+ }
1005
+ }
1006
+ if (T.hasStandardBrowserEnv && (r && a.isFunction(r) && (r = r(t)), r || r !== !1 && on(t.url))) {
1007
+ const l = s && o && an.read(o);
1008
+ l && i.set(s, l);
1009
+ }
1010
+ return t;
1011
+ }, ln = typeof XMLHttpRequest < "u", fn = ln && function(e) {
1012
+ return new Promise(function(n, r) {
1013
+ const s = ze(e);
1014
+ let o = s.data;
1015
+ const i = S.from(s.headers).normalize();
1016
+ let { responseType: c } = s, f;
1017
+ function l() {
1018
+ s.cancelToken && s.cancelToken.unsubscribe(f), s.signal && s.signal.removeEventListener("abort", f);
1019
+ }
1020
+ let u = new XMLHttpRequest();
1021
+ u.open(s.method.toUpperCase(), s.url, !0), u.timeout = s.timeout;
1022
+ function p() {
1023
+ if (!u)
1024
+ return;
1025
+ const y = S.from(
1026
+ "getAllResponseHeaders" in u && u.getAllResponseHeaders()
1027
+ ), m = {
1028
+ data: !c || c === "text" || c === "json" ? u.responseText : u.response,
1029
+ status: u.status,
1030
+ statusText: u.statusText,
1031
+ headers: y,
1032
+ config: e,
1033
+ request: u
1034
+ };
1035
+ He(function(g) {
1036
+ n(g), l();
1037
+ }, function(g) {
1038
+ r(g), l();
1039
+ }, m), u = null;
1040
+ }
1041
+ "onloadend" in u ? u.onloadend = p : u.onreadystatechange = function() {
1042
+ !u || u.readyState !== 4 || u.status === 0 && !(u.responseURL && u.responseURL.indexOf("file:") === 0) || setTimeout(p);
1043
+ }, u.onabort = function() {
1044
+ u && (r(new h("Request aborted", h.ECONNABORTED, s, u)), u = null);
1045
+ }, u.onerror = function() {
1046
+ r(new h("Network Error", h.ERR_NETWORK, s, u)), u = null;
1047
+ }, u.ontimeout = function() {
1048
+ let d = s.timeout ? "timeout of " + s.timeout + "ms exceeded" : "timeout exceeded";
1049
+ const m = s.transitional || je;
1050
+ s.timeoutErrorMessage && (d = s.timeoutErrorMessage), r(new h(
1051
+ d,
1052
+ m.clarifyTimeoutError ? h.ETIMEDOUT : h.ECONNABORTED,
1053
+ s,
1054
+ u
1055
+ )), u = null;
1056
+ }, o === void 0 && i.setContentType(null), "setRequestHeader" in u && a.forEach(i.toJSON(), function(d, m) {
1057
+ u.setRequestHeader(m, d);
1058
+ }), a.isUndefined(s.withCredentials) || (u.withCredentials = !!s.withCredentials), c && c !== "json" && (u.responseType = s.responseType), typeof s.onDownloadProgress == "function" && u.addEventListener("progress", M(s.onDownloadProgress, !0)), typeof s.onUploadProgress == "function" && u.upload && u.upload.addEventListener("progress", M(s.onUploadProgress)), (s.cancelToken || s.signal) && (f = (y) => {
1059
+ u && (r(!y || y.type ? new B(null, e, u) : y), u.abort(), u = null);
1060
+ }, s.cancelToken && s.cancelToken.subscribe(f), s.signal && (s.signal.aborted ? f() : s.signal.addEventListener("abort", f)));
1061
+ const b = nn(s.url);
1062
+ if (b && T.protocols.indexOf(b) === -1) {
1063
+ r(new h("Unsupported protocol " + b + ":", h.ERR_BAD_REQUEST, e));
1064
+ return;
1065
+ }
1066
+ u.send(o || null);
1067
+ });
1068
+ }, dn = (e, t) => {
1069
+ let n = new AbortController(), r;
1070
+ const s = function(f) {
1071
+ if (!r) {
1072
+ r = !0, i();
1073
+ const l = f instanceof Error ? f : this.reason;
1074
+ n.abort(l instanceof h ? l : new B(l instanceof Error ? l.message : l));
1075
+ }
1076
+ };
1077
+ let o = t && setTimeout(() => {
1078
+ s(new h(`timeout ${t} of ms exceeded`, h.ETIMEDOUT));
1079
+ }, t);
1080
+ const i = () => {
1081
+ e && (o && clearTimeout(o), o = null, e.forEach((f) => {
1082
+ f && (f.removeEventListener ? f.removeEventListener("abort", s) : f.unsubscribe(s));
1083
+ }), e = null);
1084
+ };
1085
+ e.forEach((f) => f && f.addEventListener && f.addEventListener("abort", s));
1086
+ const { signal: c } = n;
1087
+ return c.unsubscribe = i, [c, () => {
1088
+ o && clearTimeout(o), o = null;
1089
+ }];
1090
+ }, pn = function* (e, t) {
1091
+ let n = e.byteLength;
1092
+ if (!t || n < t) {
1093
+ yield e;
1094
+ return;
1095
+ }
1096
+ let r = 0, s;
1097
+ for (; r < n; )
1098
+ s = r + t, yield e.slice(r, s), r = s;
1099
+ }, hn = async function* (e, t, n) {
1100
+ for await (const r of e)
1101
+ yield* pn(ArrayBuffer.isView(r) ? r : await n(String(r)), t);
1102
+ }, be = (e, t, n, r, s) => {
1103
+ const o = hn(e, t, s);
1104
+ let i = 0;
1105
+ return new ReadableStream({
1106
+ type: "bytes",
1107
+ async pull(c) {
1108
+ const { done: f, value: l } = await o.next();
1109
+ if (f) {
1110
+ c.close(), r();
1111
+ return;
1112
+ }
1113
+ let u = l.byteLength;
1114
+ n && n(i += u), c.enqueue(new Uint8Array(l));
1115
+ },
1116
+ cancel(c) {
1117
+ return r(c), o.return();
1118
+ }
1119
+ }, {
1120
+ highWaterMark: 2
1121
+ });
1122
+ }, Ee = (e, t) => {
1123
+ const n = e != null;
1124
+ return (r) => setTimeout(() => t({
1125
+ lengthComputable: n,
1126
+ total: e,
1127
+ loaded: r
1128
+ }));
1129
+ }, K = typeof fetch == "function" && typeof Request == "function" && typeof Response == "function", Je = K && typeof ReadableStream == "function", ee = K && (typeof TextEncoder == "function" ? /* @__PURE__ */ ((e) => (t) => e.encode(t))(new TextEncoder()) : async (e) => new Uint8Array(await new Response(e).arrayBuffer())), mn = Je && (() => {
1130
+ let e = !1;
1131
+ const t = new Request(T.origin, {
1132
+ body: new ReadableStream(),
1133
+ method: "POST",
1134
+ get duplex() {
1135
+ return e = !0, "half";
1136
+ }
1137
+ }).headers.has("Content-Type");
1138
+ return e && !t;
1139
+ })(), Re = 64 * 1024, te = Je && !!(() => {
1140
+ try {
1141
+ return a.isReadableStream(new Response("").body);
1142
+ } catch {
1143
+ }
1144
+ })(), z = {
1145
+ stream: te && ((e) => e.body)
1146
+ };
1147
+ K && ((e) => {
1148
+ ["text", "arrayBuffer", "blob", "formData", "stream"].forEach((t) => {
1149
+ !z[t] && (z[t] = a.isFunction(e[t]) ? (n) => n[t]() : (n, r) => {
1150
+ throw new h(`Response type '${t}' is not supported`, h.ERR_NOT_SUPPORT, r);
1151
+ });
1152
+ });
1153
+ })(new Response());
1154
+ const yn = async (e) => {
1155
+ if (e == null)
1156
+ return 0;
1157
+ if (a.isBlob(e))
1158
+ return e.size;
1159
+ if (a.isSpecCompliantForm(e))
1160
+ return (await new Request(e).arrayBuffer()).byteLength;
1161
+ if (a.isArrayBufferView(e))
1162
+ return e.byteLength;
1163
+ if (a.isURLSearchParams(e) && (e = e + ""), a.isString(e))
1164
+ return (await ee(e)).byteLength;
1165
+ }, wn = async (e, t) => {
1166
+ const n = a.toFiniteNumber(e.getContentLength());
1167
+ return n ?? yn(t);
1168
+ }, bn = K && (async (e) => {
1169
+ let {
1170
+ url: t,
1171
+ method: n,
1172
+ data: r,
1173
+ signal: s,
1174
+ cancelToken: o,
1175
+ timeout: i,
1176
+ onDownloadProgress: c,
1177
+ onUploadProgress: f,
1178
+ responseType: l,
1179
+ headers: u,
1180
+ withCredentials: p = "same-origin",
1181
+ fetchOptions: b
1182
+ } = ze(e);
1183
+ l = l ? (l + "").toLowerCase() : "text";
1184
+ let [y, d] = s || o || i ? dn([s, o], i) : [], m, R;
1185
+ const g = () => {
1186
+ !m && setTimeout(() => {
1187
+ y && y.unsubscribe();
1188
+ }), m = !0;
1189
+ };
1190
+ let x;
1191
+ try {
1192
+ if (f && mn && n !== "get" && n !== "head" && (x = await wn(u, r)) !== 0) {
1193
+ let C = new Request(t, {
1194
+ method: "POST",
1195
+ body: r,
1196
+ duplex: "half"
1197
+ }), L;
1198
+ a.isFormData(r) && (L = C.headers.get("content-type")) && u.setContentType(L), C.body && (r = be(C.body, Re, Ee(
1199
+ x,
1200
+ M(f)
1201
+ ), null, ee));
1202
+ }
1203
+ a.isString(p) || (p = p ? "cors" : "omit"), R = new Request(t, {
1204
+ ...b,
1205
+ signal: y,
1206
+ method: n.toUpperCase(),
1207
+ headers: u.normalize().toJSON(),
1208
+ body: r,
1209
+ duplex: "half",
1210
+ withCredentials: p
1211
+ });
1212
+ let w = await fetch(R);
1213
+ const D = te && (l === "stream" || l === "response");
1214
+ if (te && (c || D)) {
1215
+ const C = {};
1216
+ ["status", "statusText", "headers"].forEach((le) => {
1217
+ C[le] = w[le];
1218
+ });
1219
+ const L = a.toFiniteNumber(w.headers.get("content-length"));
1220
+ w = new Response(
1221
+ be(w.body, Re, c && Ee(
1222
+ L,
1223
+ M(c, !0)
1224
+ ), D && g, ee),
1225
+ C
1226
+ );
1227
+ }
1228
+ l = l || "text";
1229
+ let Ke = await z[a.findKey(z, l) || "text"](w, e);
1230
+ return !D && g(), d && d(), await new Promise((C, L) => {
1231
+ He(C, L, {
1232
+ data: Ke,
1233
+ headers: S.from(w.headers),
1234
+ status: w.status,
1235
+ statusText: w.statusText,
1236
+ config: e,
1237
+ request: R
1238
+ });
1239
+ });
1240
+ } catch (w) {
1241
+ throw g(), w && w.name === "TypeError" && /fetch/i.test(w.message) ? Object.assign(
1242
+ new h("Network Error", h.ERR_NETWORK, e, R),
1243
+ {
1244
+ cause: w.cause || w
1245
+ }
1246
+ ) : h.from(w, w && w.code, e, R);
1247
+ }
1248
+ }), ne = {
1249
+ http: Dt,
1250
+ xhr: fn,
1251
+ fetch: bn
1252
+ };
1253
+ a.forEach(ne, (e, t) => {
1254
+ if (e) {
1255
+ try {
1256
+ Object.defineProperty(e, "name", { value: t });
1257
+ } catch {
1258
+ }
1259
+ Object.defineProperty(e, "adapterName", { value: t });
1260
+ }
1261
+ });
1262
+ const ge = (e) => `- ${e}`, En = (e) => a.isFunction(e) || e === null || e === !1, Ve = {
1263
+ getAdapter: (e) => {
1264
+ e = a.isArray(e) ? e : [e];
1265
+ const { length: t } = e;
1266
+ let n, r;
1267
+ const s = {};
1268
+ for (let o = 0; o < t; o++) {
1269
+ n = e[o];
1270
+ let i;
1271
+ if (r = n, !En(n) && (r = ne[(i = String(n)).toLowerCase()], r === void 0))
1272
+ throw new h(`Unknown adapter '${i}'`);
1273
+ if (r)
1274
+ break;
1275
+ s[i || "#" + o] = r;
1276
+ }
1277
+ if (!r) {
1278
+ const o = Object.entries(s).map(
1279
+ ([c, f]) => `adapter ${c} ` + (f === !1 ? "is not supported by the environment" : "is not available in the build")
1280
+ );
1281
+ let i = t ? o.length > 1 ? `since :
1282
+ ` + o.map(ge).join(`
1283
+ `) : " " + ge(o[0]) : "as no adapter specified";
1284
+ throw new h(
1285
+ "There is no suitable adapter to dispatch the request " + i,
1286
+ "ERR_NOT_SUPPORT"
1287
+ );
1288
+ }
1289
+ return r;
1290
+ },
1291
+ adapters: ne
1292
+ };
1293
+ function Q(e) {
1294
+ if (e.cancelToken && e.cancelToken.throwIfRequested(), e.signal && e.signal.aborted)
1295
+ throw new B(null, e);
1296
+ }
1297
+ function Se(e) {
1298
+ return Q(e), e.headers = S.from(e.headers), e.data = X.call(
1299
+ e,
1300
+ e.transformRequest
1301
+ ), ["post", "put", "patch"].indexOf(e.method) !== -1 && e.headers.setContentType("application/x-www-form-urlencoded", !1), Ve.getAdapter(e.adapter || q.adapter)(e).then(function(r) {
1302
+ return Q(e), r.data = X.call(
1303
+ e,
1304
+ e.transformResponse,
1305
+ r
1306
+ ), r.headers = S.from(r.headers), r;
1307
+ }, function(r) {
1308
+ return Ie(r) || (Q(e), r && r.response && (r.response.data = X.call(
1309
+ e,
1310
+ e.transformResponse,
1311
+ r.response
1312
+ ), r.response.headers = S.from(r.response.headers))), Promise.reject(r);
1313
+ });
1314
+ }
1315
+ const We = "1.7.2", ce = {};
1316
+ ["object", "boolean", "number", "function", "string", "symbol"].forEach((e, t) => {
1317
+ ce[e] = function(r) {
1318
+ return typeof r === e || "a" + (t < 1 ? "n " : " ") + e;
1319
+ };
1320
+ });
1321
+ const Oe = {};
1322
+ ce.transitional = function(t, n, r) {
1323
+ function s(o, i) {
1324
+ return "[Axios v" + We + "] Transitional option '" + o + "'" + i + (r ? ". " + r : "");
1325
+ }
1326
+ return (o, i, c) => {
1327
+ if (t === !1)
1328
+ throw new h(
1329
+ s(i, " has been removed" + (n ? " in " + n : "")),
1330
+ h.ERR_DEPRECATED
1331
+ );
1332
+ return n && !Oe[i] && (Oe[i] = !0), t ? t(o, i, c) : !0;
1333
+ };
1334
+ };
1335
+ function Rn(e, t, n) {
1336
+ if (typeof e != "object")
1337
+ throw new h("options must be an object", h.ERR_BAD_OPTION_VALUE);
1338
+ const r = Object.keys(e);
1339
+ let s = r.length;
1340
+ for (; s-- > 0; ) {
1341
+ const o = r[s], i = t[o];
1342
+ if (i) {
1343
+ const c = e[o], f = c === void 0 || i(c, o, e);
1344
+ if (f !== !0)
1345
+ throw new h("option " + o + " must be " + f, h.ERR_BAD_OPTION_VALUE);
1346
+ continue;
1347
+ }
1348
+ if (n !== !0)
1349
+ throw new h("Unknown option " + o, h.ERR_BAD_OPTION);
1350
+ }
1351
+ }
1352
+ const re = {
1353
+ assertOptions: Rn,
1354
+ validators: ce
1355
+ }, N = re.validators;
1356
+ class P {
1357
+ constructor(t) {
1358
+ this.defaults = t, this.interceptors = {
1359
+ request: new me(),
1360
+ response: new me()
1361
+ };
1362
+ }
1363
+ /**
1364
+ * Dispatch a request
1365
+ *
1366
+ * @param {String|Object} configOrUrl The config specific for this request (merged with this.defaults)
1367
+ * @param {?Object} config
1368
+ *
1369
+ * @returns {Promise} The Promise to be fulfilled
1370
+ */
1371
+ async request(t, n) {
1372
+ try {
1373
+ return await this._request(t, n);
1374
+ } catch (r) {
1375
+ if (r instanceof Error) {
1376
+ let s;
1377
+ Error.captureStackTrace ? Error.captureStackTrace(s = {}) : s = new Error();
1378
+ const o = s.stack ? s.stack.replace(/^.+\n/, "") : "";
1379
+ try {
1380
+ r.stack ? o && !String(r.stack).endsWith(o.replace(/^.+\n.+\n/, "")) && (r.stack += `
1381
+ ` + o) : r.stack = o;
1382
+ } catch {
1383
+ }
1384
+ }
1385
+ throw r;
1386
+ }
1387
+ }
1388
+ _request(t, n) {
1389
+ typeof t == "string" ? (n = n || {}, n.url = t) : n = t || {}, n = F(this.defaults, n);
1390
+ const { transitional: r, paramsSerializer: s, headers: o } = n;
1391
+ r !== void 0 && re.assertOptions(r, {
1392
+ silentJSONParsing: N.transitional(N.boolean),
1393
+ forcedJSONParsing: N.transitional(N.boolean),
1394
+ clarifyTimeoutError: N.transitional(N.boolean)
1395
+ }, !1), s != null && (a.isFunction(s) ? n.paramsSerializer = {
1396
+ serialize: s
1397
+ } : re.assertOptions(s, {
1398
+ encode: N.function,
1399
+ serialize: N.function
1400
+ }, !0)), n.method = (n.method || this.defaults.method || "get").toLowerCase();
1401
+ let i = o && a.merge(
1402
+ o.common,
1403
+ o[n.method]
1404
+ );
1405
+ o && a.forEach(
1406
+ ["delete", "get", "head", "post", "put", "patch", "common"],
1407
+ (d) => {
1408
+ delete o[d];
1409
+ }
1410
+ ), n.headers = S.concat(i, o);
1411
+ const c = [];
1412
+ let f = !0;
1413
+ this.interceptors.request.forEach(function(m) {
1414
+ typeof m.runWhen == "function" && m.runWhen(n) === !1 || (f = f && m.synchronous, c.unshift(m.fulfilled, m.rejected));
1415
+ });
1416
+ const l = [];
1417
+ this.interceptors.response.forEach(function(m) {
1418
+ l.push(m.fulfilled, m.rejected);
1419
+ });
1420
+ let u, p = 0, b;
1421
+ if (!f) {
1422
+ const d = [Se.bind(this), void 0];
1423
+ for (d.unshift.apply(d, c), d.push.apply(d, l), b = d.length, u = Promise.resolve(n); p < b; )
1424
+ u = u.then(d[p++], d[p++]);
1425
+ return u;
1426
+ }
1427
+ b = c.length;
1428
+ let y = n;
1429
+ for (p = 0; p < b; ) {
1430
+ const d = c[p++], m = c[p++];
1431
+ try {
1432
+ y = d(y);
1433
+ } catch (R) {
1434
+ m.call(this, R);
1435
+ break;
1436
+ }
1437
+ }
1438
+ try {
1439
+ u = Se.call(this, y);
1440
+ } catch (d) {
1441
+ return Promise.reject(d);
1442
+ }
1443
+ for (p = 0, b = l.length; p < b; )
1444
+ u = u.then(l[p++], l[p++]);
1445
+ return u;
1446
+ }
1447
+ getUri(t) {
1448
+ t = F(this.defaults, t);
1449
+ const n = Me(t.baseURL, t.url);
1450
+ return ke(n, t.params, t.paramsSerializer);
1451
+ }
1452
+ }
1453
+ a.forEach(["delete", "get", "head", "options"], function(t) {
1454
+ P.prototype[t] = function(n, r) {
1455
+ return this.request(F(r || {}, {
1456
+ method: t,
1457
+ url: n,
1458
+ data: (r || {}).data
1459
+ }));
1460
+ };
1461
+ });
1462
+ a.forEach(["post", "put", "patch"], function(t) {
1463
+ function n(r) {
1464
+ return function(o, i, c) {
1465
+ return this.request(F(c || {}, {
1466
+ method: t,
1467
+ headers: r ? {
1468
+ "Content-Type": "multipart/form-data"
1469
+ } : {},
1470
+ url: o,
1471
+ data: i
1472
+ }));
1473
+ };
1474
+ }
1475
+ P.prototype[t] = n(), P.prototype[t + "Form"] = n(!0);
1476
+ });
1477
+ class ue {
1478
+ constructor(t) {
1479
+ if (typeof t != "function")
1480
+ throw new TypeError("executor must be a function.");
1481
+ let n;
1482
+ this.promise = new Promise(function(o) {
1483
+ n = o;
1484
+ });
1485
+ const r = this;
1486
+ this.promise.then((s) => {
1487
+ if (!r._listeners) return;
1488
+ let o = r._listeners.length;
1489
+ for (; o-- > 0; )
1490
+ r._listeners[o](s);
1491
+ r._listeners = null;
1492
+ }), this.promise.then = (s) => {
1493
+ let o;
1494
+ const i = new Promise((c) => {
1495
+ r.subscribe(c), o = c;
1496
+ }).then(s);
1497
+ return i.cancel = function() {
1498
+ r.unsubscribe(o);
1499
+ }, i;
1500
+ }, t(function(o, i, c) {
1501
+ r.reason || (r.reason = new B(o, i, c), n(r.reason));
1502
+ });
1503
+ }
1504
+ /**
1505
+ * Throws a `CanceledError` if cancellation has been requested.
1506
+ */
1507
+ throwIfRequested() {
1508
+ if (this.reason)
1509
+ throw this.reason;
1510
+ }
1511
+ /**
1512
+ * Subscribe to the cancel signal
1513
+ */
1514
+ subscribe(t) {
1515
+ if (this.reason) {
1516
+ t(this.reason);
1517
+ return;
1518
+ }
1519
+ this._listeners ? this._listeners.push(t) : this._listeners = [t];
1520
+ }
1521
+ /**
1522
+ * Unsubscribe from the cancel signal
1523
+ */
1524
+ unsubscribe(t) {
1525
+ if (!this._listeners)
1526
+ return;
1527
+ const n = this._listeners.indexOf(t);
1528
+ n !== -1 && this._listeners.splice(n, 1);
1529
+ }
1530
+ /**
1531
+ * Returns an object that contains a new `CancelToken` and a function that, when called,
1532
+ * cancels the `CancelToken`.
1533
+ */
1534
+ static source() {
1535
+ let t;
1536
+ return {
1537
+ token: new ue(function(s) {
1538
+ t = s;
1539
+ }),
1540
+ cancel: t
1541
+ };
1542
+ }
1543
+ }
1544
+ function gn(e) {
1545
+ return function(n) {
1546
+ return e.apply(null, n);
1547
+ };
1548
+ }
1549
+ function Sn(e) {
1550
+ return a.isObject(e) && e.isAxiosError === !0;
1551
+ }
1552
+ const se = {
1553
+ Continue: 100,
1554
+ SwitchingProtocols: 101,
1555
+ Processing: 102,
1556
+ EarlyHints: 103,
1557
+ Ok: 200,
1558
+ Created: 201,
1559
+ Accepted: 202,
1560
+ NonAuthoritativeInformation: 203,
1561
+ NoContent: 204,
1562
+ ResetContent: 205,
1563
+ PartialContent: 206,
1564
+ MultiStatus: 207,
1565
+ AlreadyReported: 208,
1566
+ ImUsed: 226,
1567
+ MultipleChoices: 300,
1568
+ MovedPermanently: 301,
1569
+ Found: 302,
1570
+ SeeOther: 303,
1571
+ NotModified: 304,
1572
+ UseProxy: 305,
1573
+ Unused: 306,
1574
+ TemporaryRedirect: 307,
1575
+ PermanentRedirect: 308,
1576
+ BadRequest: 400,
1577
+ Unauthorized: 401,
1578
+ PaymentRequired: 402,
1579
+ Forbidden: 403,
1580
+ NotFound: 404,
1581
+ MethodNotAllowed: 405,
1582
+ NotAcceptable: 406,
1583
+ ProxyAuthenticationRequired: 407,
1584
+ RequestTimeout: 408,
1585
+ Conflict: 409,
1586
+ Gone: 410,
1587
+ LengthRequired: 411,
1588
+ PreconditionFailed: 412,
1589
+ PayloadTooLarge: 413,
1590
+ UriTooLong: 414,
1591
+ UnsupportedMediaType: 415,
1592
+ RangeNotSatisfiable: 416,
1593
+ ExpectationFailed: 417,
1594
+ ImATeapot: 418,
1595
+ MisdirectedRequest: 421,
1596
+ UnprocessableEntity: 422,
1597
+ Locked: 423,
1598
+ FailedDependency: 424,
1599
+ TooEarly: 425,
1600
+ UpgradeRequired: 426,
1601
+ PreconditionRequired: 428,
1602
+ TooManyRequests: 429,
1603
+ RequestHeaderFieldsTooLarge: 431,
1604
+ UnavailableForLegalReasons: 451,
1605
+ InternalServerError: 500,
1606
+ NotImplemented: 501,
1607
+ BadGateway: 502,
1608
+ ServiceUnavailable: 503,
1609
+ GatewayTimeout: 504,
1610
+ HttpVersionNotSupported: 505,
1611
+ VariantAlsoNegotiates: 506,
1612
+ InsufficientStorage: 507,
1613
+ LoopDetected: 508,
1614
+ NotExtended: 510,
1615
+ NetworkAuthenticationRequired: 511
1616
+ };
1617
+ Object.entries(se).forEach(([e, t]) => {
1618
+ se[t] = e;
1619
+ });
1620
+ function $e(e) {
1621
+ const t = new P(e), n = Te(P.prototype.request, t);
1622
+ return a.extend(n, P.prototype, t, { allOwnKeys: !0 }), a.extend(n, t, null, { allOwnKeys: !0 }), n.create = function(s) {
1623
+ return $e(F(e, s));
1624
+ }, n;
1625
+ }
1626
+ const E = $e(q);
1627
+ E.Axios = P;
1628
+ E.CanceledError = B;
1629
+ E.CancelToken = ue;
1630
+ E.isCancel = Ie;
1631
+ E.VERSION = We;
1632
+ E.toFormData = $;
1633
+ E.AxiosError = h;
1634
+ E.Cancel = E.CanceledError;
1635
+ E.all = function(t) {
1636
+ return Promise.all(t);
1637
+ };
1638
+ E.spread = gn;
1639
+ E.isAxiosError = Sn;
1640
+ E.mergeConfig = F;
1641
+ E.AxiosHeaders = S;
1642
+ E.formToJSON = (e) => qe(a.isHTMLForm(e) ? new FormData(e) : e);
1643
+ E.getAdapter = Ve.getAdapter;
1644
+ E.HttpStatusCode = se;
1645
+ E.default = E;
1646
+ const On = {
1647
+ personalInfo: "/api/personal-center/personal-server/v1/info"
1648
+ }, xn = async (e) => {
1649
+ var n;
1650
+ const t = await E.create().get(On.personalInfo, {
1651
+ baseURL: Ge().baseURL,
1652
+ params: {
1653
+ project: ((n = ve()) == null ? void 0 : n.id) || "",
1654
+ timestamp: (/* @__PURE__ */ new Date()).getTime()
1655
+ },
1656
+ headers: {
1657
+ Authorization: `Bearer ${e}`
1658
+ }
1659
+ });
1660
+ t != null && t.data && sessionStorage.setItem("userInfo", JSON.stringify(t.data));
1661
+ };
1662
+ export {
1663
+ xn as setPersonalInfo
1664
+ };