@tarxemo/customer_support 1.0.2 → 1.0.3

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/index.es.js CHANGED
@@ -1,299 +1,22 @@
1
- var Ut = Object.defineProperty;
2
- var vt = (e, t, r) => t in e ? Ut(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r;
3
- var $e = (e, t, r) => vt(e, typeof t != "symbol" ? t + "" : t, r);
4
- import It, { forwardRef as lt, createElement as ke, useState as se, useRef as ut, useEffect as Ue, useCallback as he } from "react";
5
- var me = { exports: {} }, te = {};
6
- /**
7
- * @license React
8
- * react-jsx-runtime.production.js
9
- *
10
- * Copyright (c) Meta Platforms, Inc. and affiliates.
11
- *
12
- * This source code is licensed under the MIT license found in the
13
- * LICENSE file in the root directory of this source tree.
14
- */
15
- var qe;
16
- function Bt() {
17
- if (qe) return te;
18
- qe = 1;
19
- var e = Symbol.for("react.transitional.element"), t = Symbol.for("react.fragment");
20
- function r(n, s, o) {
21
- var i = null;
22
- if (o !== void 0 && (i = "" + o), s.key !== void 0 && (i = "" + s.key), "key" in s) {
23
- o = {};
24
- for (var a in s)
25
- a !== "key" && (o[a] = s[a]);
26
- } else o = s;
27
- return s = o.ref, {
28
- $$typeof: e,
29
- type: n,
30
- key: i,
31
- ref: s !== void 0 ? s : null,
32
- props: o
33
- };
34
- }
35
- return te.Fragment = t, te.jsx = r, te.jsxs = r, te;
36
- }
37
- var re = {};
38
- /**
39
- * @license React
40
- * react-jsx-runtime.development.js
41
- *
42
- * Copyright (c) Meta Platforms, Inc. and affiliates.
43
- *
44
- * This source code is licensed under the MIT license found in the
45
- * LICENSE file in the root directory of this source tree.
46
- */
47
- var He;
48
- function Mt() {
49
- return He || (He = 1, process.env.NODE_ENV !== "production" && (function() {
50
- function e(l) {
51
- if (l == null) return null;
52
- if (typeof l == "function")
53
- return l.$$typeof === de ? null : l.displayName || l.name || null;
54
- if (typeof l == "string") return l;
55
- switch (l) {
56
- case h:
57
- return "Fragment";
58
- case x:
59
- return "Profiler";
60
- case S:
61
- return "StrictMode";
62
- case U:
63
- return "Suspense";
64
- case j:
65
- return "SuspenseList";
66
- case fe:
67
- return "Activity";
68
- }
69
- if (typeof l == "object")
70
- switch (typeof l.tag == "number" && console.error(
71
- "Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."
72
- ), l.$$typeof) {
73
- case y:
74
- return "Portal";
75
- case _:
76
- return l.displayName || "Context";
77
- case w:
78
- return (l._context.displayName || "Context") + ".Consumer";
79
- case P:
80
- var E = l.render;
81
- return l = l.displayName, l || (l = E.displayName || E.name || "", l = l !== "" ? "ForwardRef(" + l + ")" : "ForwardRef"), l;
82
- case Z:
83
- return E = l.displayName || null, E !== null ? E : e(l.type) || "Memo";
84
- case $:
85
- E = l._payload, l = l._init;
86
- try {
87
- return e(l(E));
88
- } catch {
89
- }
90
- }
91
- return null;
92
- }
93
- function t(l) {
94
- return "" + l;
95
- }
96
- function r(l) {
97
- try {
98
- t(l);
99
- var E = !1;
100
- } catch {
101
- E = !0;
102
- }
103
- if (E) {
104
- E = console;
105
- var T = E.error, A = typeof Symbol == "function" && Symbol.toStringTag && l[Symbol.toStringTag] || l.constructor.name || "Object";
106
- return T.call(
107
- E,
108
- "The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
109
- A
110
- ), t(l);
111
- }
112
- }
113
- function n(l) {
114
- if (l === h) return "<>";
115
- if (typeof l == "object" && l !== null && l.$$typeof === $)
116
- return "<...>";
117
- try {
118
- var E = e(l);
119
- return E ? "<" + E + ">" : "<...>";
120
- } catch {
121
- return "<...>";
122
- }
123
- }
124
- function s() {
125
- var l = q.A;
126
- return l === null ? null : l.getOwner();
127
- }
128
- function o() {
129
- return Error("react-stack-top-frame");
130
- }
131
- function i(l) {
132
- if (H.call(l, "key")) {
133
- var E = Object.getOwnPropertyDescriptor(l, "key").get;
134
- if (E && E.isReactWarning) return !1;
135
- }
136
- return l.key !== void 0;
137
- }
138
- function a(l, E) {
139
- function T() {
140
- L || (L = !0, console.error(
141
- "%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",
142
- E
143
- ));
144
- }
145
- T.isReactWarning = !0, Object.defineProperty(l, "key", {
146
- get: T,
147
- configurable: !0
148
- });
149
- }
150
- function p() {
151
- var l = e(this.type);
152
- return Q[l] || (Q[l] = !0, console.error(
153
- "Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
154
- )), l = this.props.ref, l !== void 0 ? l : null;
155
- }
156
- function f(l, E, T, A, z, Ae) {
157
- var N = T.ref;
158
- return l = {
159
- $$typeof: d,
160
- type: l,
161
- key: E,
162
- props: T,
163
- _owner: A
164
- }, (N !== void 0 ? N : null) !== null ? Object.defineProperty(l, "ref", {
165
- enumerable: !1,
166
- get: p
167
- }) : Object.defineProperty(l, "ref", { enumerable: !1, value: null }), l._store = {}, Object.defineProperty(l._store, "validated", {
168
- configurable: !1,
169
- enumerable: !1,
170
- writable: !0,
171
- value: 0
172
- }), Object.defineProperty(l, "_debugInfo", {
173
- configurable: !1,
174
- enumerable: !1,
175
- writable: !0,
176
- value: null
177
- }), Object.defineProperty(l, "_debugStack", {
178
- configurable: !1,
179
- enumerable: !1,
180
- writable: !0,
181
- value: z
182
- }), Object.defineProperty(l, "_debugTask", {
183
- configurable: !1,
184
- enumerable: !1,
185
- writable: !0,
186
- value: Ae
187
- }), Object.freeze && (Object.freeze(l.props), Object.freeze(l)), l;
188
- }
189
- function u(l, E, T, A, z, Ae) {
190
- var N = E.children;
191
- if (N !== void 0)
192
- if (A)
193
- if (M(N)) {
194
- for (A = 0; A < N.length; A++)
195
- m(N[A]);
196
- Object.freeze && Object.freeze(N);
197
- } else
198
- console.error(
199
- "React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead."
200
- );
201
- else m(N);
202
- if (H.call(E, "key")) {
203
- N = e(l);
204
- var Y = Object.keys(E).filter(function(Lt) {
205
- return Lt !== "key";
206
- });
207
- A = 0 < Y.length ? "{key: someKey, " + Y.join(": ..., ") + ": ...}" : "{key: someKey}", pe[N + A] || (Y = 0 < Y.length ? "{" + Y.join(": ..., ") + ": ...}" : "{}", console.error(
208
- `A props object containing a "key" prop is being spread into JSX:
209
- let props = %s;
210
- <%s {...props} />
211
- React keys must be passed directly to JSX without using spread:
212
- let props = %s;
213
- <%s key={someKey} {...props} />`,
214
- A,
215
- N,
216
- Y,
217
- N
218
- ), pe[N + A] = !0);
219
- }
220
- if (N = null, T !== void 0 && (r(T), N = "" + T), i(E) && (r(E.key), N = "" + E.key), "key" in E) {
221
- T = {};
222
- for (var xe in E)
223
- xe !== "key" && (T[xe] = E[xe]);
224
- } else T = E;
225
- return N && a(
226
- T,
227
- typeof l == "function" ? l.displayName || l.name || "Unknown" : l
228
- ), f(
229
- l,
230
- N,
231
- T,
232
- s(),
233
- z,
234
- Ae
235
- );
236
- }
237
- function m(l) {
238
- g(l) ? l._store && (l._store.validated = 1) : typeof l == "object" && l !== null && l.$$typeof === $ && (l._payload.status === "fulfilled" ? g(l._payload.value) && l._payload.value._store && (l._payload.value._store.validated = 1) : l._store && (l._store.validated = 1));
239
- }
240
- function g(l) {
241
- return typeof l == "object" && l !== null && l.$$typeof === d;
242
- }
243
- var O = It, d = Symbol.for("react.transitional.element"), y = Symbol.for("react.portal"), h = Symbol.for("react.fragment"), S = Symbol.for("react.strict_mode"), x = Symbol.for("react.profiler"), w = Symbol.for("react.consumer"), _ = Symbol.for("react.context"), P = Symbol.for("react.forward_ref"), U = Symbol.for("react.suspense"), j = Symbol.for("react.suspense_list"), Z = Symbol.for("react.memo"), $ = Symbol.for("react.lazy"), fe = Symbol.for("react.activity"), de = Symbol.for("react.client.reference"), q = O.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, H = Object.prototype.hasOwnProperty, M = Array.isArray, K = console.createTask ? console.createTask : function() {
244
- return null;
245
- };
246
- O = {
247
- react_stack_bottom_frame: function(l) {
248
- return l();
249
- }
250
- };
251
- var L, Q = {}, v = O.react_stack_bottom_frame.bind(
252
- O,
253
- o
254
- )(), ee = K(n(o)), pe = {};
255
- re.Fragment = h, re.jsx = function(l, E, T) {
256
- var A = 1e4 > q.recentlyCreatedOwnerStacks++;
257
- return u(
258
- l,
259
- E,
260
- T,
261
- !1,
262
- A ? Error("react-stack-top-frame") : v,
263
- A ? K(n(l)) : ee
264
- );
265
- }, re.jsxs = function(l, E, T) {
266
- var A = 1e4 > q.recentlyCreatedOwnerStacks++;
267
- return u(
268
- l,
269
- E,
270
- T,
271
- !0,
272
- A ? Error("react-stack-top-frame") : v,
273
- A ? K(n(l)) : ee
274
- );
275
- };
276
- })()), re;
277
- }
278
- var ze;
279
- function $t() {
280
- return ze || (ze = 1, process.env.NODE_ENV === "production" ? me.exports = Bt() : me.exports = Mt()), me.exports;
281
- }
282
- var R = $t();
1
+ var Tt = Object.defineProperty;
2
+ var Ct = (e, t, n) => t in e ? Tt(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
3
+ var Le = (e, t, n) => Ct(e, typeof t != "symbol" ? t + "" : t, n);
4
+ import { jsxs as x, jsx as S } from "react/jsx-runtime";
5
+ import { forwardRef as Ye, createElement as be, useState as K, useRef as et, useEffect as Oe, useCallback as ne } from "react";
283
6
  /**
284
7
  * @license lucide-react v0.469.0 - ISC
285
8
  *
286
9
  * This source code is licensed under the ISC license.
287
10
  * See the LICENSE file in the root directory of this source tree.
288
11
  */
289
- const qt = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase(), ft = (...e) => e.filter((t, r, n) => !!t && t.trim() !== "" && n.indexOf(t) === r).join(" ").trim();
12
+ const Nt = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase(), tt = (...e) => e.filter((t, n, r) => !!t && t.trim() !== "" && r.indexOf(t) === n).join(" ").trim();
290
13
  /**
291
14
  * @license lucide-react v0.469.0 - ISC
292
15
  *
293
16
  * This source code is licensed under the ISC license.
294
17
  * See the LICENSE file in the root directory of this source tree.
295
18
  */
296
- var Ht = {
19
+ var xt = {
297
20
  xmlns: "http://www.w3.org/2000/svg",
298
21
  width: 24,
299
22
  height: 24,
@@ -310,30 +33,30 @@ var Ht = {
310
33
  * This source code is licensed under the ISC license.
311
34
  * See the LICENSE file in the root directory of this source tree.
312
35
  */
313
- const zt = lt(
36
+ const Pt = Ye(
314
37
  ({
315
38
  color: e = "currentColor",
316
39
  size: t = 24,
317
- strokeWidth: r = 2,
318
- absoluteStrokeWidth: n,
40
+ strokeWidth: n = 2,
41
+ absoluteStrokeWidth: r,
319
42
  className: s = "",
320
43
  children: o,
321
44
  iconNode: i,
322
45
  ...a
323
- }, p) => ke(
46
+ }, d) => be(
324
47
  "svg",
325
48
  {
326
- ref: p,
327
- ...Ht,
49
+ ref: d,
50
+ ...xt,
328
51
  width: t,
329
52
  height: t,
330
53
  stroke: e,
331
- strokeWidth: n ? Number(r) * 24 / Number(t) : r,
332
- className: ft("lucide", s),
54
+ strokeWidth: r ? Number(n) * 24 / Number(t) : n,
55
+ className: tt("lucide", s),
333
56
  ...a
334
57
  },
335
58
  [
336
- ...i.map(([f, u]) => ke(f, u)),
59
+ ...i.map(([u, l]) => be(u, l)),
337
60
  ...Array.isArray(o) ? o : [o]
338
61
  ]
339
62
  )
@@ -344,16 +67,16 @@ const zt = lt(
344
67
  * This source code is licensed under the ISC license.
345
68
  * See the LICENSE file in the root directory of this source tree.
346
69
  */
347
- const oe = (e, t) => {
348
- const r = lt(
349
- ({ className: n, ...s }, o) => ke(zt, {
70
+ const V = (e, t) => {
71
+ const n = Ye(
72
+ ({ className: r, ...s }, o) => be(Pt, {
350
73
  ref: o,
351
74
  iconNode: t,
352
- className: ft(`lucide-${qt(e)}`, n),
75
+ className: tt(`lucide-${Nt(e)}`, r),
353
76
  ...s
354
77
  })
355
78
  );
356
- return r.displayName = `${e}`, r;
79
+ return n.displayName = `${e}`, n;
357
80
  };
358
81
  /**
359
82
  * @license lucide-react v0.469.0 - ISC
@@ -361,7 +84,7 @@ const oe = (e, t) => {
361
84
  * This source code is licensed under the ISC license.
362
85
  * See the LICENSE file in the root directory of this source tree.
363
86
  */
364
- const Jt = oe("ExternalLink", [
87
+ const Dt = V("ExternalLink", [
365
88
  ["path", { d: "M15 3h6v6", key: "1q9fwt" }],
366
89
  ["path", { d: "M10 14 21 3", key: "gplh6r" }],
367
90
  ["path", { d: "M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6", key: "a6xqqp" }]
@@ -372,7 +95,7 @@ const Jt = oe("ExternalLink", [
372
95
  * This source code is licensed under the ISC license.
373
96
  * See the LICENSE file in the root directory of this source tree.
374
97
  */
375
- const Vt = oe("LoaderCircle", [
98
+ const Ft = V("LoaderCircle", [
376
99
  ["path", { d: "M21 12a9 9 0 1 1-6.219-8.56", key: "13zald" }]
377
100
  ]);
378
101
  /**
@@ -381,7 +104,7 @@ const Vt = oe("LoaderCircle", [
381
104
  * This source code is licensed under the ISC license.
382
105
  * See the LICENSE file in the root directory of this source tree.
383
106
  */
384
- const Wt = oe("MessageCircle", [
107
+ const Ut = V("MessageCircle", [
385
108
  ["path", { d: "M7.9 20A9 9 0 1 0 4 16.1L2 22Z", key: "vv11sd" }]
386
109
  ]);
387
110
  /**
@@ -390,7 +113,7 @@ const Wt = oe("MessageCircle", [
390
113
  * This source code is licensed under the ISC license.
391
114
  * See the LICENSE file in the root directory of this source tree.
392
115
  */
393
- const Kt = oe("Send", [
116
+ const Lt = V("Send", [
394
117
  [
395
118
  "path",
396
119
  {
@@ -406,85 +129,85 @@ const Kt = oe("Send", [
406
129
  * This source code is licensed under the ISC license.
407
130
  * See the LICENSE file in the root directory of this source tree.
408
131
  */
409
- const Yt = oe("X", [
132
+ const kt = V("X", [
410
133
  ["path", { d: "M18 6 6 18", key: "1bl5f8" }],
411
134
  ["path", { d: "m6 6 12 12", key: "d8bk6v" }]
412
135
  ]);
413
- function dt(e, t) {
136
+ function nt(e, t) {
414
137
  return function() {
415
138
  return e.apply(t, arguments);
416
139
  };
417
140
  }
418
- const { toString: Xt } = Object.prototype, { getPrototypeOf: ve } = Object, { iterator: Re, toStringTag: pt } = Symbol, Se = /* @__PURE__ */ ((e) => (t) => {
419
- const r = Xt.call(t);
420
- return e[r] || (e[r] = r.slice(8, -1).toLowerCase());
421
- })(/* @__PURE__ */ Object.create(null)), I = (e) => (e = e.toLowerCase(), (t) => Se(t) === e), _e = (e) => (t) => typeof t === e, { isArray: G } = Array, X = _e("undefined");
422
- function ie(e) {
423
- return e !== null && !X(e) && e.constructor !== null && !X(e.constructor) && F(e.constructor.isBuffer) && e.constructor.isBuffer(e);
141
+ const { toString: Bt } = Object.prototype, { getPrototypeOf: _e } = Object, { iterator: ce, toStringTag: rt } = Symbol, le = /* @__PURE__ */ ((e) => (t) => {
142
+ const n = Bt.call(t);
143
+ return e[n] || (e[n] = n.slice(8, -1).toLowerCase());
144
+ })(/* @__PURE__ */ Object.create(null)), D = (e) => (e = e.toLowerCase(), (t) => le(t) === e), ue = (e) => (t) => typeof t === e, { isArray: z } = Array, H = ue("undefined");
145
+ function W(e) {
146
+ return e !== null && !H(e) && e.constructor !== null && !H(e.constructor) && C(e.constructor.isBuffer) && e.constructor.isBuffer(e);
424
147
  }
425
- const ht = I("ArrayBuffer");
426
- function Gt(e) {
148
+ const st = D("ArrayBuffer");
149
+ function It(e) {
427
150
  let t;
428
- return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? t = ArrayBuffer.isView(e) : t = e && e.buffer && ht(e.buffer), t;
151
+ return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? t = ArrayBuffer.isView(e) : t = e && e.buffer && st(e.buffer), t;
429
152
  }
430
- const Zt = _e("string"), F = _e("function"), mt = _e("number"), ae = (e) => e !== null && typeof e == "object", Qt = (e) => e === !0 || e === !1, we = (e) => {
431
- if (Se(e) !== "object")
153
+ const jt = ue("string"), C = ue("function"), ot = ue("number"), X = (e) => e !== null && typeof e == "object", Mt = (e) => e === !0 || e === !1, se = (e) => {
154
+ if (le(e) !== "object")
432
155
  return !1;
433
- const t = ve(e);
434
- return (t === null || t === Object.prototype || Object.getPrototypeOf(t) === null) && !(pt in e) && !(Re in e);
435
- }, er = (e) => {
436
- if (!ae(e) || ie(e))
156
+ const t = _e(e);
157
+ return (t === null || t === Object.prototype || Object.getPrototypeOf(t) === null) && !(rt in e) && !(ce in e);
158
+ }, $t = (e) => {
159
+ if (!X(e) || W(e))
437
160
  return !1;
438
161
  try {
439
162
  return Object.keys(e).length === 0 && Object.getPrototypeOf(e) === Object.prototype;
440
163
  } catch {
441
164
  return !1;
442
165
  }
443
- }, tr = I("Date"), rr = I("File"), nr = I("Blob"), sr = I("FileList"), or = (e) => ae(e) && F(e.pipe), ir = (e) => {
166
+ }, qt = D("Date"), Ht = D("File"), zt = D("Blob"), vt = D("FileList"), Jt = (e) => X(e) && C(e.pipe), Kt = (e) => {
444
167
  let t;
445
- return e && (typeof FormData == "function" && e instanceof FormData || F(e.append) && ((t = Se(e)) === "formdata" || // detect form-data instance
446
- t === "object" && F(e.toString) && e.toString() === "[object FormData]"));
447
- }, ar = I("URLSearchParams"), [cr, lr, ur, fr] = ["ReadableStream", "Request", "Response", "Headers"].map(I), dr = (e) => e.trim ? e.trim() : e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
448
- function ce(e, t, { allOwnKeys: r = !1 } = {}) {
168
+ return e && (typeof FormData == "function" && e instanceof FormData || C(e.append) && ((t = le(e)) === "formdata" || // detect form-data instance
169
+ t === "object" && C(e.toString) && e.toString() === "[object FormData]"));
170
+ }, Vt = D("URLSearchParams"), [Wt, Xt, Gt, Zt] = ["ReadableStream", "Request", "Response", "Headers"].map(D), Qt = (e) => e.trim ? e.trim() : e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
171
+ function G(e, t, { allOwnKeys: n = !1 } = {}) {
449
172
  if (e === null || typeof e > "u")
450
173
  return;
451
- let n, s;
452
- if (typeof e != "object" && (e = [e]), G(e))
453
- for (n = 0, s = e.length; n < s; n++)
454
- t.call(null, e[n], n, e);
174
+ let r, s;
175
+ if (typeof e != "object" && (e = [e]), z(e))
176
+ for (r = 0, s = e.length; r < s; r++)
177
+ t.call(null, e[r], r, e);
455
178
  else {
456
- if (ie(e))
179
+ if (W(e))
457
180
  return;
458
- const o = r ? Object.getOwnPropertyNames(e) : Object.keys(e), i = o.length;
181
+ const o = n ? Object.getOwnPropertyNames(e) : Object.keys(e), i = o.length;
459
182
  let a;
460
- for (n = 0; n < i; n++)
461
- a = o[n], t.call(null, e[a], a, e);
183
+ for (r = 0; r < i; r++)
184
+ a = o[r], t.call(null, e[a], a, e);
462
185
  }
463
186
  }
464
- function yt(e, t) {
465
- if (ie(e))
187
+ function it(e, t) {
188
+ if (W(e))
466
189
  return null;
467
190
  t = t.toLowerCase();
468
- const r = Object.keys(e);
469
- let n = r.length, s;
470
- for (; n-- > 0; )
471
- if (s = r[n], t === s.toLowerCase())
191
+ const n = Object.keys(e);
192
+ let r = n.length, s;
193
+ for (; r-- > 0; )
194
+ if (s = n[r], t === s.toLowerCase())
472
195
  return s;
473
196
  return null;
474
197
  }
475
- const J = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : global, wt = (e) => !X(e) && e !== J;
476
- function je() {
477
- const { caseless: e, skipUndefined: t } = wt(this) && this || {}, r = {}, n = (s, o) => {
478
- const i = e && yt(r, o) || o;
479
- we(r[i]) && we(s) ? r[i] = je(r[i], s) : we(s) ? r[i] = je({}, s) : G(s) ? r[i] = s.slice() : (!t || !X(s)) && (r[i] = s);
198
+ const j = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : global, at = (e) => !H(e) && e !== j;
199
+ function ge() {
200
+ const { caseless: e, skipUndefined: t } = at(this) && this || {}, n = {}, r = (s, o) => {
201
+ const i = e && it(n, o) || o;
202
+ se(n[i]) && se(s) ? n[i] = ge(n[i], s) : se(s) ? n[i] = ge({}, s) : z(s) ? n[i] = s.slice() : (!t || !H(s)) && (n[i] = s);
480
203
  };
481
204
  for (let s = 0, o = arguments.length; s < o; s++)
482
- arguments[s] && ce(arguments[s], n);
483
- return r;
205
+ arguments[s] && G(arguments[s], r);
206
+ return n;
484
207
  }
485
- const pr = (e, t, r, { allOwnKeys: n } = {}) => (ce(t, (s, o) => {
486
- r && F(s) ? Object.defineProperty(e, o, {
487
- value: dt(s, r),
208
+ const Yt = (e, t, n, { allOwnKeys: r } = {}) => (G(t, (s, o) => {
209
+ n && C(s) ? Object.defineProperty(e, o, {
210
+ value: nt(s, n),
488
211
  writable: !0,
489
212
  enumerable: !0,
490
213
  configurable: !0
@@ -494,178 +217,178 @@ const pr = (e, t, r, { allOwnKeys: n } = {}) => (ce(t, (s, o) => {
494
217
  enumerable: !0,
495
218
  configurable: !0
496
219
  });
497
- }, { allOwnKeys: n }), e), hr = (e) => (e.charCodeAt(0) === 65279 && (e = e.slice(1)), e), mr = (e, t, r, n) => {
498
- e.prototype = Object.create(t.prototype, n), Object.defineProperty(e.prototype, "constructor", {
220
+ }, { allOwnKeys: r }), e), en = (e) => (e.charCodeAt(0) === 65279 && (e = e.slice(1)), e), tn = (e, t, n, r) => {
221
+ e.prototype = Object.create(t.prototype, r), Object.defineProperty(e.prototype, "constructor", {
499
222
  value: e,
500
223
  writable: !0,
501
224
  enumerable: !1,
502
225
  configurable: !0
503
226
  }), Object.defineProperty(e, "super", {
504
227
  value: t.prototype
505
- }), r && Object.assign(e.prototype, r);
506
- }, yr = (e, t, r, n) => {
228
+ }), n && Object.assign(e.prototype, n);
229
+ }, nn = (e, t, n, r) => {
507
230
  let s, o, i;
508
231
  const a = {};
509
232
  if (t = t || {}, e == null) return t;
510
233
  do {
511
234
  for (s = Object.getOwnPropertyNames(e), o = s.length; o-- > 0; )
512
- i = s[o], (!n || n(i, e, t)) && !a[i] && (t[i] = e[i], a[i] = !0);
513
- e = r !== !1 && ve(e);
514
- } while (e && (!r || r(e, t)) && e !== Object.prototype);
235
+ i = s[o], (!r || r(i, e, t)) && !a[i] && (t[i] = e[i], a[i] = !0);
236
+ e = n !== !1 && _e(e);
237
+ } while (e && (!n || n(e, t)) && e !== Object.prototype);
515
238
  return t;
516
- }, wr = (e, t, r) => {
517
- e = String(e), (r === void 0 || r > e.length) && (r = e.length), r -= t.length;
518
- const n = e.indexOf(t, r);
519
- return n !== -1 && n === r;
520
- }, br = (e) => {
239
+ }, rn = (e, t, n) => {
240
+ e = String(e), (n === void 0 || n > e.length) && (n = e.length), n -= t.length;
241
+ const r = e.indexOf(t, n);
242
+ return r !== -1 && r === n;
243
+ }, sn = (e) => {
521
244
  if (!e) return null;
522
- if (G(e)) return e;
245
+ if (z(e)) return e;
523
246
  let t = e.length;
524
- if (!mt(t)) return null;
525
- const r = new Array(t);
247
+ if (!ot(t)) return null;
248
+ const n = new Array(t);
526
249
  for (; t-- > 0; )
527
- r[t] = e[t];
528
- return r;
529
- }, Er = /* @__PURE__ */ ((e) => (t) => e && t instanceof e)(typeof Uint8Array < "u" && ve(Uint8Array)), gr = (e, t) => {
530
- const n = (e && e[Re]).call(e);
250
+ n[t] = e[t];
251
+ return n;
252
+ }, on = /* @__PURE__ */ ((e) => (t) => e && t instanceof e)(typeof Uint8Array < "u" && _e(Uint8Array)), an = (e, t) => {
253
+ const r = (e && e[ce]).call(e);
531
254
  let s;
532
- for (; (s = n.next()) && !s.done; ) {
255
+ for (; (s = r.next()) && !s.done; ) {
533
256
  const o = s.value;
534
257
  t.call(e, o[0], o[1]);
535
258
  }
536
- }, Rr = (e, t) => {
537
- let r;
538
- const n = [];
539
- for (; (r = e.exec(t)) !== null; )
540
- n.push(r);
541
- return n;
542
- }, Sr = I("HTMLFormElement"), _r = (e) => e.toLowerCase().replace(
259
+ }, cn = (e, t) => {
260
+ let n;
261
+ const r = [];
262
+ for (; (n = e.exec(t)) !== null; )
263
+ r.push(n);
264
+ return r;
265
+ }, ln = D("HTMLFormElement"), un = (e) => e.toLowerCase().replace(
543
266
  /[-_\s]([a-z\d])(\w*)/g,
544
- function(r, n, s) {
545
- return n.toUpperCase() + s;
267
+ function(n, r, s) {
268
+ return r.toUpperCase() + s;
546
269
  }
547
- ), Je = (({ hasOwnProperty: e }) => (t, r) => e.call(t, r))(Object.prototype), Tr = I("RegExp"), bt = (e, t) => {
548
- const r = Object.getOwnPropertyDescriptors(e), n = {};
549
- ce(r, (s, o) => {
270
+ ), ke = (({ hasOwnProperty: e }) => (t, n) => e.call(t, n))(Object.prototype), fn = D("RegExp"), ct = (e, t) => {
271
+ const n = Object.getOwnPropertyDescriptors(e), r = {};
272
+ G(n, (s, o) => {
550
273
  let i;
551
- (i = t(s, o, e)) !== !1 && (n[o] = i || s);
552
- }), Object.defineProperties(e, n);
553
- }, Or = (e) => {
554
- bt(e, (t, r) => {
555
- if (F(e) && ["arguments", "caller", "callee"].indexOf(r) !== -1)
274
+ (i = t(s, o, e)) !== !1 && (r[o] = i || s);
275
+ }), Object.defineProperties(e, r);
276
+ }, dn = (e) => {
277
+ ct(e, (t, n) => {
278
+ if (C(e) && ["arguments", "caller", "callee"].indexOf(n) !== -1)
556
279
  return !1;
557
- const n = e[r];
558
- if (F(n)) {
280
+ const r = e[n];
281
+ if (C(r)) {
559
282
  if (t.enumerable = !1, "writable" in t) {
560
283
  t.writable = !1;
561
284
  return;
562
285
  }
563
286
  t.set || (t.set = () => {
564
- throw Error("Can not rewrite read-only method '" + r + "'");
287
+ throw Error("Can not rewrite read-only method '" + n + "'");
565
288
  });
566
289
  }
567
290
  });
568
- }, Ar = (e, t) => {
569
- const r = {}, n = (s) => {
291
+ }, pn = (e, t) => {
292
+ const n = {}, r = (s) => {
570
293
  s.forEach((o) => {
571
- r[o] = !0;
294
+ n[o] = !0;
572
295
  });
573
296
  };
574
- return G(e) ? n(e) : n(String(e).split(t)), r;
575
- }, xr = () => {
576
- }, Cr = (e, t) => e != null && Number.isFinite(e = +e) ? e : t;
577
- function Nr(e) {
578
- return !!(e && F(e.append) && e[pt] === "FormData" && e[Re]);
297
+ return z(e) ? r(e) : r(String(e).split(t)), n;
298
+ }, hn = () => {
299
+ }, mn = (e, t) => e != null && Number.isFinite(e = +e) ? e : t;
300
+ function yn(e) {
301
+ return !!(e && C(e.append) && e[rt] === "FormData" && e[ce]);
579
302
  }
580
- const Pr = (e) => {
581
- const t = new Array(10), r = (n, s) => {
582
- if (ae(n)) {
583
- if (t.indexOf(n) >= 0)
303
+ const wn = (e) => {
304
+ const t = new Array(10), n = (r, s) => {
305
+ if (X(r)) {
306
+ if (t.indexOf(r) >= 0)
584
307
  return;
585
- if (ie(n))
586
- return n;
587
- if (!("toJSON" in n)) {
588
- t[s] = n;
589
- const o = G(n) ? [] : {};
590
- return ce(n, (i, a) => {
591
- const p = r(i, s + 1);
592
- !X(p) && (o[a] = p);
308
+ if (W(r))
309
+ return r;
310
+ if (!("toJSON" in r)) {
311
+ t[s] = r;
312
+ const o = z(r) ? [] : {};
313
+ return G(r, (i, a) => {
314
+ const d = n(i, s + 1);
315
+ !H(d) && (o[a] = d);
593
316
  }), t[s] = void 0, o;
594
317
  }
595
318
  }
596
- return n;
319
+ return r;
597
320
  };
598
- return r(e, 0);
599
- }, kr = I("AsyncFunction"), jr = (e) => e && (ae(e) || F(e)) && F(e.then) && F(e.catch), Et = ((e, t) => e ? setImmediate : t ? ((r, n) => (J.addEventListener("message", ({ source: s, data: o }) => {
600
- s === J && o === r && n.length && n.shift()();
321
+ return n(e, 0);
322
+ }, bn = D("AsyncFunction"), gn = (e) => e && (X(e) || C(e)) && C(e.then) && C(e.catch), lt = ((e, t) => e ? setImmediate : t ? ((n, r) => (j.addEventListener("message", ({ source: s, data: o }) => {
323
+ s === j && o === n && r.length && r.shift()();
601
324
  }, !1), (s) => {
602
- n.push(s), J.postMessage(r, "*");
603
- }))(`axios@${Math.random()}`, []) : (r) => setTimeout(r))(
325
+ r.push(s), j.postMessage(n, "*");
326
+ }))(`axios@${Math.random()}`, []) : (n) => setTimeout(n))(
604
327
  typeof setImmediate == "function",
605
- F(J.postMessage)
606
- ), Fr = typeof queueMicrotask < "u" ? queueMicrotask.bind(J) : typeof process < "u" && process.nextTick || Et, Dr = (e) => e != null && F(e[Re]), c = {
607
- isArray: G,
608
- isArrayBuffer: ht,
609
- isBuffer: ie,
610
- isFormData: ir,
611
- isArrayBufferView: Gt,
612
- isString: Zt,
613
- isNumber: mt,
614
- isBoolean: Qt,
615
- isObject: ae,
616
- isPlainObject: we,
617
- isEmptyObject: er,
618
- isReadableStream: cr,
619
- isRequest: lr,
620
- isResponse: ur,
621
- isHeaders: fr,
622
- isUndefined: X,
623
- isDate: tr,
624
- isFile: rr,
625
- isBlob: nr,
626
- isRegExp: Tr,
627
- isFunction: F,
628
- isStream: or,
629
- isURLSearchParams: ar,
630
- isTypedArray: Er,
631
- isFileList: sr,
632
- forEach: ce,
633
- merge: je,
634
- extend: pr,
635
- trim: dr,
636
- stripBOM: hr,
637
- inherits: mr,
638
- toFlatObject: yr,
639
- kindOf: Se,
640
- kindOfTest: I,
641
- endsWith: wr,
642
- toArray: br,
643
- forEachEntry: gr,
644
- matchAll: Rr,
645
- isHTMLForm: Sr,
646
- hasOwnProperty: Je,
647
- hasOwnProp: Je,
328
+ C(j.postMessage)
329
+ ), En = typeof queueMicrotask < "u" ? queueMicrotask.bind(j) : typeof process < "u" && process.nextTick || lt, Sn = (e) => e != null && C(e[ce]), c = {
330
+ isArray: z,
331
+ isArrayBuffer: st,
332
+ isBuffer: W,
333
+ isFormData: Kt,
334
+ isArrayBufferView: It,
335
+ isString: jt,
336
+ isNumber: ot,
337
+ isBoolean: Mt,
338
+ isObject: X,
339
+ isPlainObject: se,
340
+ isEmptyObject: $t,
341
+ isReadableStream: Wt,
342
+ isRequest: Xt,
343
+ isResponse: Gt,
344
+ isHeaders: Zt,
345
+ isUndefined: H,
346
+ isDate: qt,
347
+ isFile: Ht,
348
+ isBlob: zt,
349
+ isRegExp: fn,
350
+ isFunction: C,
351
+ isStream: Jt,
352
+ isURLSearchParams: Vt,
353
+ isTypedArray: on,
354
+ isFileList: vt,
355
+ forEach: G,
356
+ merge: ge,
357
+ extend: Yt,
358
+ trim: Qt,
359
+ stripBOM: en,
360
+ inherits: tn,
361
+ toFlatObject: nn,
362
+ kindOf: le,
363
+ kindOfTest: D,
364
+ endsWith: rn,
365
+ toArray: sn,
366
+ forEachEntry: an,
367
+ matchAll: cn,
368
+ isHTMLForm: ln,
369
+ hasOwnProperty: ke,
370
+ hasOwnProp: ke,
648
371
  // an alias to avoid ESLint no-prototype-builtins detection
649
- reduceDescriptors: bt,
650
- freezeMethods: Or,
651
- toObjectSet: Ar,
652
- toCamelCase: _r,
653
- noop: xr,
654
- toFiniteNumber: Cr,
655
- findKey: yt,
656
- global: J,
657
- isContextDefined: wt,
658
- isSpecCompliantForm: Nr,
659
- toJSONObject: Pr,
660
- isAsyncFn: kr,
661
- isThenable: jr,
662
- setImmediate: Et,
663
- asap: Fr,
664
- isIterable: Dr
372
+ reduceDescriptors: ct,
373
+ freezeMethods: dn,
374
+ toObjectSet: pn,
375
+ toCamelCase: un,
376
+ noop: hn,
377
+ toFiniteNumber: mn,
378
+ findKey: it,
379
+ global: j,
380
+ isContextDefined: at,
381
+ isSpecCompliantForm: yn,
382
+ toJSONObject: wn,
383
+ isAsyncFn: bn,
384
+ isThenable: gn,
385
+ setImmediate: lt,
386
+ asap: En,
387
+ isIterable: Sn
665
388
  };
666
- let b = class gt extends Error {
667
- static from(t, r, n, s, o, i) {
668
- const a = new gt(t.message, r || t.code, n, s, o);
389
+ let w = class ut extends Error {
390
+ static from(t, n, r, s, o, i) {
391
+ const a = new ut(t.message, n || t.code, r, s, o);
669
392
  return a.cause = t, a.name = t.name, i && Object.assign(a, i), a;
670
393
  }
671
394
  /**
@@ -679,8 +402,8 @@ let b = class gt extends Error {
679
402
  *
680
403
  * @returns {Error} The created error.
681
404
  */
682
- constructor(t, r, n, s, o) {
683
- super(t), this.name = "AxiosError", this.isAxiosError = !0, r && (this.code = r), n && (this.config = n), s && (this.request = s), o && (this.response = o, this.status = o.status);
405
+ constructor(t, n, r, s, o) {
406
+ super(t), this.name = "AxiosError", this.isAxiosError = !0, n && (this.code = n), r && (this.config = r), s && (this.request = s), o && (this.response = o, this.status = o.status);
684
407
  }
685
408
  toJSON() {
686
409
  return {
@@ -702,100 +425,100 @@ let b = class gt extends Error {
702
425
  };
703
426
  }
704
427
  };
705
- b.ERR_BAD_OPTION_VALUE = "ERR_BAD_OPTION_VALUE";
706
- b.ERR_BAD_OPTION = "ERR_BAD_OPTION";
707
- b.ECONNABORTED = "ECONNABORTED";
708
- b.ETIMEDOUT = "ETIMEDOUT";
709
- b.ERR_NETWORK = "ERR_NETWORK";
710
- b.ERR_FR_TOO_MANY_REDIRECTS = "ERR_FR_TOO_MANY_REDIRECTS";
711
- b.ERR_DEPRECATED = "ERR_DEPRECATED";
712
- b.ERR_BAD_RESPONSE = "ERR_BAD_RESPONSE";
713
- b.ERR_BAD_REQUEST = "ERR_BAD_REQUEST";
714
- b.ERR_CANCELED = "ERR_CANCELED";
715
- b.ERR_NOT_SUPPORT = "ERR_NOT_SUPPORT";
716
- b.ERR_INVALID_URL = "ERR_INVALID_URL";
717
- const Lr = null;
718
- function Fe(e) {
428
+ w.ERR_BAD_OPTION_VALUE = "ERR_BAD_OPTION_VALUE";
429
+ w.ERR_BAD_OPTION = "ERR_BAD_OPTION";
430
+ w.ECONNABORTED = "ECONNABORTED";
431
+ w.ETIMEDOUT = "ETIMEDOUT";
432
+ w.ERR_NETWORK = "ERR_NETWORK";
433
+ w.ERR_FR_TOO_MANY_REDIRECTS = "ERR_FR_TOO_MANY_REDIRECTS";
434
+ w.ERR_DEPRECATED = "ERR_DEPRECATED";
435
+ w.ERR_BAD_RESPONSE = "ERR_BAD_RESPONSE";
436
+ w.ERR_BAD_REQUEST = "ERR_BAD_REQUEST";
437
+ w.ERR_CANCELED = "ERR_CANCELED";
438
+ w.ERR_NOT_SUPPORT = "ERR_NOT_SUPPORT";
439
+ w.ERR_INVALID_URL = "ERR_INVALID_URL";
440
+ const Rn = null;
441
+ function Ee(e) {
719
442
  return c.isPlainObject(e) || c.isArray(e);
720
443
  }
721
- function Rt(e) {
444
+ function ft(e) {
722
445
  return c.endsWith(e, "[]") ? e.slice(0, -2) : e;
723
446
  }
724
- function Ve(e, t, r) {
447
+ function Be(e, t, n) {
725
448
  return e ? e.concat(t).map(function(s, o) {
726
- return s = Rt(s), !r && o ? "[" + s + "]" : s;
727
- }).join(r ? "." : "") : t;
449
+ return s = ft(s), !n && o ? "[" + s + "]" : s;
450
+ }).join(n ? "." : "") : t;
728
451
  }
729
- function Ur(e) {
730
- return c.isArray(e) && !e.some(Fe);
452
+ function On(e) {
453
+ return c.isArray(e) && !e.some(Ee);
731
454
  }
732
- const vr = c.toFlatObject(c, {}, null, function(t) {
455
+ const _n = c.toFlatObject(c, {}, null, function(t) {
733
456
  return /^is[A-Z]/.test(t);
734
457
  });
735
- function Te(e, t, r) {
458
+ function fe(e, t, n) {
736
459
  if (!c.isObject(e))
737
460
  throw new TypeError("target must be an object");
738
- t = t || new FormData(), r = c.toFlatObject(r, {
461
+ t = t || new FormData(), n = c.toFlatObject(n, {
739
462
  metaTokens: !0,
740
463
  dots: !1,
741
464
  indexes: !1
742
- }, !1, function(y, h) {
743
- return !c.isUndefined(h[y]);
465
+ }, !1, function(m, h) {
466
+ return !c.isUndefined(h[m]);
744
467
  });
745
- const n = r.metaTokens, s = r.visitor || u, o = r.dots, i = r.indexes, p = (r.Blob || typeof Blob < "u" && Blob) && c.isSpecCompliantForm(t);
468
+ const r = n.metaTokens, s = n.visitor || l, o = n.dots, i = n.indexes, d = (n.Blob || typeof Blob < "u" && Blob) && c.isSpecCompliantForm(t);
746
469
  if (!c.isFunction(s))
747
470
  throw new TypeError("visitor must be a function");
748
- function f(d) {
749
- if (d === null) return "";
750
- if (c.isDate(d))
751
- return d.toISOString();
752
- if (c.isBoolean(d))
753
- return d.toString();
754
- if (!p && c.isBlob(d))
755
- throw new b("Blob is not supported. Use a Buffer instead.");
756
- return c.isArrayBuffer(d) || c.isTypedArray(d) ? p && typeof Blob == "function" ? new Blob([d]) : Buffer.from(d) : d;
757
- }
758
- function u(d, y, h) {
759
- let S = d;
760
- if (d && !h && typeof d == "object") {
761
- if (c.endsWith(y, "{}"))
762
- y = n ? y : y.slice(0, -2), d = JSON.stringify(d);
763
- else if (c.isArray(d) && Ur(d) || (c.isFileList(d) || c.endsWith(y, "[]")) && (S = c.toArray(d)))
764
- return y = Rt(y), S.forEach(function(w, _) {
765
- !(c.isUndefined(w) || w === null) && t.append(
471
+ function u(f) {
472
+ if (f === null) return "";
473
+ if (c.isDate(f))
474
+ return f.toISOString();
475
+ if (c.isBoolean(f))
476
+ return f.toString();
477
+ if (!d && c.isBlob(f))
478
+ throw new w("Blob is not supported. Use a Buffer instead.");
479
+ return c.isArrayBuffer(f) || c.isTypedArray(f) ? d && typeof Blob == "function" ? new Blob([f]) : Buffer.from(f) : f;
480
+ }
481
+ function l(f, m, h) {
482
+ let g = f;
483
+ if (f && !h && typeof f == "object") {
484
+ if (c.endsWith(m, "{}"))
485
+ m = r ? m : m.slice(0, -2), f = JSON.stringify(f);
486
+ else if (c.isArray(f) && On(f) || (c.isFileList(f) || c.endsWith(m, "[]")) && (g = c.toArray(f)))
487
+ return m = ft(m), g.forEach(function(y, E) {
488
+ !(c.isUndefined(y) || y === null) && t.append(
766
489
  // eslint-disable-next-line no-nested-ternary
767
- i === !0 ? Ve([y], _, o) : i === null ? y : y + "[]",
768
- f(w)
490
+ i === !0 ? Be([m], E, o) : i === null ? m : m + "[]",
491
+ u(y)
769
492
  );
770
493
  }), !1;
771
494
  }
772
- return Fe(d) ? !0 : (t.append(Ve(h, y, o), f(d)), !1);
495
+ return Ee(f) ? !0 : (t.append(Be(h, m, o), u(f)), !1);
773
496
  }
774
- const m = [], g = Object.assign(vr, {
775
- defaultVisitor: u,
776
- convertValue: f,
777
- isVisitable: Fe
497
+ const p = [], b = Object.assign(_n, {
498
+ defaultVisitor: l,
499
+ convertValue: u,
500
+ isVisitable: Ee
778
501
  });
779
- function O(d, y) {
780
- if (!c.isUndefined(d)) {
781
- if (m.indexOf(d) !== -1)
782
- throw Error("Circular reference detected in " + y.join("."));
783
- m.push(d), c.forEach(d, function(S, x) {
784
- (!(c.isUndefined(S) || S === null) && s.call(
502
+ function _(f, m) {
503
+ if (!c.isUndefined(f)) {
504
+ if (p.indexOf(f) !== -1)
505
+ throw Error("Circular reference detected in " + m.join("."));
506
+ p.push(f), c.forEach(f, function(g, R) {
507
+ (!(c.isUndefined(g) || g === null) && s.call(
785
508
  t,
786
- S,
787
- c.isString(x) ? x.trim() : x,
788
- y,
789
- g
790
- )) === !0 && O(S, y ? y.concat(x) : [x]);
791
- }), m.pop();
509
+ g,
510
+ c.isString(R) ? R.trim() : R,
511
+ m,
512
+ b
513
+ )) === !0 && _(g, m ? m.concat(R) : [R]);
514
+ }), p.pop();
792
515
  }
793
516
  }
794
517
  if (!c.isObject(e))
795
518
  throw new TypeError("data must be an object");
796
- return O(e), t;
519
+ return _(e), t;
797
520
  }
798
- function We(e) {
521
+ function Ie(e) {
799
522
  const t = {
800
523
  "!": "%21",
801
524
  "'": "%27",
@@ -805,42 +528,42 @@ function We(e) {
805
528
  "%20": "+",
806
529
  "%00": "\0"
807
530
  };
808
- return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g, function(n) {
809
- return t[n];
531
+ return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g, function(r) {
532
+ return t[r];
810
533
  });
811
534
  }
812
- function Ie(e, t) {
813
- this._pairs = [], e && Te(e, this, t);
535
+ function Ae(e, t) {
536
+ this._pairs = [], e && fe(e, this, t);
814
537
  }
815
- const St = Ie.prototype;
816
- St.append = function(t, r) {
817
- this._pairs.push([t, r]);
538
+ const dt = Ae.prototype;
539
+ dt.append = function(t, n) {
540
+ this._pairs.push([t, n]);
818
541
  };
819
- St.toString = function(t) {
820
- const r = t ? function(n) {
821
- return t.call(this, n, We);
822
- } : We;
542
+ dt.toString = function(t) {
543
+ const n = t ? function(r) {
544
+ return t.call(this, r, Ie);
545
+ } : Ie;
823
546
  return this._pairs.map(function(s) {
824
- return r(s[0]) + "=" + r(s[1]);
547
+ return n(s[0]) + "=" + n(s[1]);
825
548
  }, "").join("&");
826
549
  };
827
- function Ir(e) {
550
+ function An(e) {
828
551
  return encodeURIComponent(e).replace(/%3A/gi, ":").replace(/%24/g, "$").replace(/%2C/gi, ",").replace(/%20/g, "+");
829
552
  }
830
- function _t(e, t, r) {
553
+ function pt(e, t, n) {
831
554
  if (!t)
832
555
  return e;
833
- const n = r && r.encode || Ir, s = c.isFunction(r) ? {
834
- serialize: r
835
- } : r, o = s && s.serialize;
556
+ const r = n && n.encode || An, s = c.isFunction(n) ? {
557
+ serialize: n
558
+ } : n, o = s && s.serialize;
836
559
  let i;
837
- if (o ? i = o(t, s) : i = c.isURLSearchParams(t) ? t.toString() : new Ie(t, s).toString(n), i) {
560
+ if (o ? i = o(t, s) : i = c.isURLSearchParams(t) ? t.toString() : new Ae(t, s).toString(r), i) {
838
561
  const a = e.indexOf("#");
839
562
  a !== -1 && (e = e.slice(0, a)), e += (e.indexOf("?") === -1 ? "?" : "&") + i;
840
563
  }
841
564
  return e;
842
565
  }
843
- class Ke {
566
+ class je {
844
567
  constructor() {
845
568
  this.handlers = [];
846
569
  }
@@ -853,12 +576,12 @@ class Ke {
853
576
  *
854
577
  * @return {Number} An ID used to remove interceptor later
855
578
  */
856
- use(t, r, n) {
579
+ use(t, n, r) {
857
580
  return this.handlers.push({
858
581
  fulfilled: t,
859
- rejected: r,
860
- synchronous: n ? n.synchronous : !1,
861
- runWhen: n ? n.runWhen : null
582
+ rejected: n,
583
+ synchronous: r ? r.synchronous : !1,
584
+ runWhen: r ? r.runWhen : null
862
585
  }), this.handlers.length - 1;
863
586
  }
864
587
  /**
@@ -890,119 +613,119 @@ class Ke {
890
613
  * @returns {void}
891
614
  */
892
615
  forEach(t) {
893
- c.forEach(this.handlers, function(n) {
894
- n !== null && t(n);
616
+ c.forEach(this.handlers, function(r) {
617
+ r !== null && t(r);
895
618
  });
896
619
  }
897
620
  }
898
- const Tt = {
621
+ const ht = {
899
622
  silentJSONParsing: !0,
900
623
  forcedJSONParsing: !0,
901
624
  clarifyTimeoutError: !1
902
- }, Br = typeof URLSearchParams < "u" ? URLSearchParams : Ie, Mr = typeof FormData < "u" ? FormData : null, $r = typeof Blob < "u" ? Blob : null, qr = {
625
+ }, Tn = typeof URLSearchParams < "u" ? URLSearchParams : Ae, Cn = typeof FormData < "u" ? FormData : null, Nn = typeof Blob < "u" ? Blob : null, xn = {
903
626
  isBrowser: !0,
904
627
  classes: {
905
- URLSearchParams: Br,
906
- FormData: Mr,
907
- Blob: $r
628
+ URLSearchParams: Tn,
629
+ FormData: Cn,
630
+ Blob: Nn
908
631
  },
909
632
  protocols: ["http", "https", "file", "blob", "url", "data"]
910
- }, Be = typeof window < "u" && typeof document < "u", De = typeof navigator == "object" && navigator || void 0, Hr = Be && (!De || ["ReactNative", "NativeScript", "NS"].indexOf(De.product) < 0), zr = typeof WorkerGlobalScope < "u" && // eslint-disable-next-line no-undef
911
- self instanceof WorkerGlobalScope && typeof self.importScripts == "function", Jr = Be && window.location.href || "http://localhost", Vr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
633
+ }, Te = typeof window < "u" && typeof document < "u", Se = typeof navigator == "object" && navigator || void 0, Pn = Te && (!Se || ["ReactNative", "NativeScript", "NS"].indexOf(Se.product) < 0), Dn = typeof WorkerGlobalScope < "u" && // eslint-disable-next-line no-undef
634
+ self instanceof WorkerGlobalScope && typeof self.importScripts == "function", Fn = Te && window.location.href || "http://localhost", Un = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
912
635
  __proto__: null,
913
- hasBrowserEnv: Be,
914
- hasStandardBrowserEnv: Hr,
915
- hasStandardBrowserWebWorkerEnv: zr,
916
- navigator: De,
917
- origin: Jr
918
- }, Symbol.toStringTag, { value: "Module" })), k = {
919
- ...Vr,
920
- ...qr
636
+ hasBrowserEnv: Te,
637
+ hasStandardBrowserEnv: Pn,
638
+ hasStandardBrowserWebWorkerEnv: Dn,
639
+ navigator: Se,
640
+ origin: Fn
641
+ }, Symbol.toStringTag, { value: "Module" })), A = {
642
+ ...Un,
643
+ ...xn
921
644
  };
922
- function Wr(e, t) {
923
- return Te(e, new k.classes.URLSearchParams(), {
924
- visitor: function(r, n, s, o) {
925
- return k.isNode && c.isBuffer(r) ? (this.append(n, r.toString("base64")), !1) : o.defaultVisitor.apply(this, arguments);
645
+ function Ln(e, t) {
646
+ return fe(e, new A.classes.URLSearchParams(), {
647
+ visitor: function(n, r, s, o) {
648
+ return A.isNode && c.isBuffer(n) ? (this.append(r, n.toString("base64")), !1) : o.defaultVisitor.apply(this, arguments);
926
649
  },
927
650
  ...t
928
651
  });
929
652
  }
930
- function Kr(e) {
653
+ function kn(e) {
931
654
  return c.matchAll(/\w+|\[(\w*)]/g, e).map((t) => t[0] === "[]" ? "" : t[1] || t[0]);
932
655
  }
933
- function Yr(e) {
934
- const t = {}, r = Object.keys(e);
935
- let n;
936
- const s = r.length;
656
+ function Bn(e) {
657
+ const t = {}, n = Object.keys(e);
658
+ let r;
659
+ const s = n.length;
937
660
  let o;
938
- for (n = 0; n < s; n++)
939
- o = r[n], t[o] = e[o];
661
+ for (r = 0; r < s; r++)
662
+ o = n[r], t[o] = e[o];
940
663
  return t;
941
664
  }
942
- function Ot(e) {
943
- function t(r, n, s, o) {
944
- let i = r[o++];
665
+ function mt(e) {
666
+ function t(n, r, s, o) {
667
+ let i = n[o++];
945
668
  if (i === "__proto__") return !0;
946
- const a = Number.isFinite(+i), p = o >= r.length;
947
- return i = !i && c.isArray(s) ? s.length : i, p ? (c.hasOwnProp(s, i) ? s[i] = [s[i], n] : s[i] = n, !a) : ((!s[i] || !c.isObject(s[i])) && (s[i] = []), t(r, n, s[i], o) && c.isArray(s[i]) && (s[i] = Yr(s[i])), !a);
669
+ const a = Number.isFinite(+i), d = o >= n.length;
670
+ return i = !i && c.isArray(s) ? s.length : i, d ? (c.hasOwnProp(s, i) ? s[i] = [s[i], r] : s[i] = r, !a) : ((!s[i] || !c.isObject(s[i])) && (s[i] = []), t(n, r, s[i], o) && c.isArray(s[i]) && (s[i] = Bn(s[i])), !a);
948
671
  }
949
672
  if (c.isFormData(e) && c.isFunction(e.entries)) {
950
- const r = {};
951
- return c.forEachEntry(e, (n, s) => {
952
- t(Kr(n), s, r, 0);
953
- }), r;
673
+ const n = {};
674
+ return c.forEachEntry(e, (r, s) => {
675
+ t(kn(r), s, n, 0);
676
+ }), n;
954
677
  }
955
678
  return null;
956
679
  }
957
- function Xr(e, t, r) {
680
+ function In(e, t, n) {
958
681
  if (c.isString(e))
959
682
  try {
960
683
  return (t || JSON.parse)(e), c.trim(e);
961
- } catch (n) {
962
- if (n.name !== "SyntaxError")
963
- throw n;
684
+ } catch (r) {
685
+ if (r.name !== "SyntaxError")
686
+ throw r;
964
687
  }
965
- return (r || JSON.stringify)(e);
688
+ return (n || JSON.stringify)(e);
966
689
  }
967
- const le = {
968
- transitional: Tt,
690
+ const Z = {
691
+ transitional: ht,
969
692
  adapter: ["xhr", "http", "fetch"],
970
- transformRequest: [function(t, r) {
971
- const n = r.getContentType() || "", s = n.indexOf("application/json") > -1, o = c.isObject(t);
693
+ transformRequest: [function(t, n) {
694
+ const r = n.getContentType() || "", s = r.indexOf("application/json") > -1, o = c.isObject(t);
972
695
  if (o && c.isHTMLForm(t) && (t = new FormData(t)), c.isFormData(t))
973
- return s ? JSON.stringify(Ot(t)) : t;
696
+ return s ? JSON.stringify(mt(t)) : t;
974
697
  if (c.isArrayBuffer(t) || c.isBuffer(t) || c.isStream(t) || c.isFile(t) || c.isBlob(t) || c.isReadableStream(t))
975
698
  return t;
976
699
  if (c.isArrayBufferView(t))
977
700
  return t.buffer;
978
701
  if (c.isURLSearchParams(t))
979
- return r.setContentType("application/x-www-form-urlencoded;charset=utf-8", !1), t.toString();
702
+ return n.setContentType("application/x-www-form-urlencoded;charset=utf-8", !1), t.toString();
980
703
  let a;
981
704
  if (o) {
982
- if (n.indexOf("application/x-www-form-urlencoded") > -1)
983
- return Wr(t, this.formSerializer).toString();
984
- if ((a = c.isFileList(t)) || n.indexOf("multipart/form-data") > -1) {
985
- const p = this.env && this.env.FormData;
986
- return Te(
705
+ if (r.indexOf("application/x-www-form-urlencoded") > -1)
706
+ return Ln(t, this.formSerializer).toString();
707
+ if ((a = c.isFileList(t)) || r.indexOf("multipart/form-data") > -1) {
708
+ const d = this.env && this.env.FormData;
709
+ return fe(
987
710
  a ? { "files[]": t } : t,
988
- p && new p(),
711
+ d && new d(),
989
712
  this.formSerializer
990
713
  );
991
714
  }
992
715
  }
993
- return o || s ? (r.setContentType("application/json", !1), Xr(t)) : t;
716
+ return o || s ? (n.setContentType("application/json", !1), In(t)) : t;
994
717
  }],
995
718
  transformResponse: [function(t) {
996
- const r = this.transitional || le.transitional, n = r && r.forcedJSONParsing, s = this.responseType === "json";
719
+ const n = this.transitional || Z.transitional, r = n && n.forcedJSONParsing, s = this.responseType === "json";
997
720
  if (c.isResponse(t) || c.isReadableStream(t))
998
721
  return t;
999
- if (t && c.isString(t) && (n && !this.responseType || s)) {
1000
- const i = !(r && r.silentJSONParsing) && s;
722
+ if (t && c.isString(t) && (r && !this.responseType || s)) {
723
+ const i = !(n && n.silentJSONParsing) && s;
1001
724
  try {
1002
725
  return JSON.parse(t, this.parseReviver);
1003
726
  } catch (a) {
1004
727
  if (i)
1005
- throw a.name === "SyntaxError" ? b.from(a, b.ERR_BAD_RESPONSE, this, null, this.response) : a;
728
+ throw a.name === "SyntaxError" ? w.from(a, w.ERR_BAD_RESPONSE, this, null, this.response) : a;
1006
729
  }
1007
730
  }
1008
731
  return t;
@@ -1017,8 +740,8 @@ const le = {
1017
740
  maxContentLength: -1,
1018
741
  maxBodyLength: -1,
1019
742
  env: {
1020
- FormData: k.classes.FormData,
1021
- Blob: k.classes.Blob
743
+ FormData: A.classes.FormData,
744
+ Blob: A.classes.Blob
1022
745
  },
1023
746
  validateStatus: function(t) {
1024
747
  return t >= 200 && t < 300;
@@ -1031,9 +754,9 @@ const le = {
1031
754
  }
1032
755
  };
1033
756
  c.forEach(["delete", "get", "head", "post", "put", "patch"], (e) => {
1034
- le.headers[e] = {};
757
+ Z.headers[e] = {};
1035
758
  });
1036
- const Gr = c.toObjectSet([
759
+ const jn = c.toObjectSet([
1037
760
  "age",
1038
761
  "authorization",
1039
762
  "content-length",
@@ -1051,152 +774,152 @@ const Gr = c.toObjectSet([
1051
774
  "referer",
1052
775
  "retry-after",
1053
776
  "user-agent"
1054
- ]), Zr = (e) => {
777
+ ]), Mn = (e) => {
1055
778
  const t = {};
1056
- let r, n, s;
779
+ let n, r, s;
1057
780
  return e && e.split(`
1058
781
  `).forEach(function(i) {
1059
- s = i.indexOf(":"), r = i.substring(0, s).trim().toLowerCase(), n = i.substring(s + 1).trim(), !(!r || t[r] && Gr[r]) && (r === "set-cookie" ? t[r] ? t[r].push(n) : t[r] = [n] : t[r] = t[r] ? t[r] + ", " + n : n);
782
+ s = i.indexOf(":"), n = i.substring(0, s).trim().toLowerCase(), r = i.substring(s + 1).trim(), !(!n || t[n] && jn[n]) && (n === "set-cookie" ? t[n] ? t[n].push(r) : t[n] = [r] : t[n] = t[n] ? t[n] + ", " + r : r);
1060
783
  }), t;
1061
- }, Ye = Symbol("internals");
1062
- function ne(e) {
784
+ }, Me = Symbol("internals");
785
+ function J(e) {
1063
786
  return e && String(e).trim().toLowerCase();
1064
787
  }
1065
- function be(e) {
1066
- return e === !1 || e == null ? e : c.isArray(e) ? e.map(be) : String(e);
788
+ function oe(e) {
789
+ return e === !1 || e == null ? e : c.isArray(e) ? e.map(oe) : String(e);
1067
790
  }
1068
- function Qr(e) {
1069
- const t = /* @__PURE__ */ Object.create(null), r = /([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;
1070
- let n;
1071
- for (; n = r.exec(e); )
1072
- t[n[1]] = n[2];
791
+ function $n(e) {
792
+ const t = /* @__PURE__ */ Object.create(null), n = /([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;
793
+ let r;
794
+ for (; r = n.exec(e); )
795
+ t[r[1]] = r[2];
1073
796
  return t;
1074
797
  }
1075
- const en = (e) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());
1076
- function Ce(e, t, r, n, s) {
1077
- if (c.isFunction(n))
1078
- return n.call(this, t, r);
1079
- if (s && (t = r), !!c.isString(t)) {
1080
- if (c.isString(n))
1081
- return t.indexOf(n) !== -1;
1082
- if (c.isRegExp(n))
1083
- return n.test(t);
798
+ const qn = (e) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());
799
+ function me(e, t, n, r, s) {
800
+ if (c.isFunction(r))
801
+ return r.call(this, t, n);
802
+ if (s && (t = n), !!c.isString(t)) {
803
+ if (c.isString(r))
804
+ return t.indexOf(r) !== -1;
805
+ if (c.isRegExp(r))
806
+ return r.test(t);
1084
807
  }
1085
808
  }
1086
- function tn(e) {
1087
- return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (t, r, n) => r.toUpperCase() + n);
809
+ function Hn(e) {
810
+ return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (t, n, r) => n.toUpperCase() + r);
1088
811
  }
1089
- function rn(e, t) {
1090
- const r = c.toCamelCase(" " + t);
1091
- ["get", "set", "has"].forEach((n) => {
1092
- Object.defineProperty(e, n + r, {
812
+ function zn(e, t) {
813
+ const n = c.toCamelCase(" " + t);
814
+ ["get", "set", "has"].forEach((r) => {
815
+ Object.defineProperty(e, r + n, {
1093
816
  value: function(s, o, i) {
1094
- return this[n].call(this, t, s, o, i);
817
+ return this[r].call(this, t, s, o, i);
1095
818
  },
1096
819
  configurable: !0
1097
820
  });
1098
821
  });
1099
822
  }
1100
- let D = class {
823
+ let N = class {
1101
824
  constructor(t) {
1102
825
  t && this.set(t);
1103
826
  }
1104
- set(t, r, n) {
827
+ set(t, n, r) {
1105
828
  const s = this;
1106
- function o(a, p, f) {
1107
- const u = ne(p);
1108
- if (!u)
829
+ function o(a, d, u) {
830
+ const l = J(d);
831
+ if (!l)
1109
832
  throw new Error("header name must be a non-empty string");
1110
- const m = c.findKey(s, u);
1111
- (!m || s[m] === void 0 || f === !0 || f === void 0 && s[m] !== !1) && (s[m || p] = be(a));
833
+ const p = c.findKey(s, l);
834
+ (!p || s[p] === void 0 || u === !0 || u === void 0 && s[p] !== !1) && (s[p || d] = oe(a));
1112
835
  }
1113
- const i = (a, p) => c.forEach(a, (f, u) => o(f, u, p));
836
+ const i = (a, d) => c.forEach(a, (u, l) => o(u, l, d));
1114
837
  if (c.isPlainObject(t) || t instanceof this.constructor)
1115
- i(t, r);
1116
- else if (c.isString(t) && (t = t.trim()) && !en(t))
1117
- i(Zr(t), r);
838
+ i(t, n);
839
+ else if (c.isString(t) && (t = t.trim()) && !qn(t))
840
+ i(Mn(t), n);
1118
841
  else if (c.isObject(t) && c.isIterable(t)) {
1119
- let a = {}, p, f;
1120
- for (const u of t) {
1121
- if (!c.isArray(u))
842
+ let a = {}, d, u;
843
+ for (const l of t) {
844
+ if (!c.isArray(l))
1122
845
  throw TypeError("Object iterator must return a key-value pair");
1123
- a[f = u[0]] = (p = a[f]) ? c.isArray(p) ? [...p, u[1]] : [p, u[1]] : u[1];
846
+ a[u = l[0]] = (d = a[u]) ? c.isArray(d) ? [...d, l[1]] : [d, l[1]] : l[1];
1124
847
  }
1125
- i(a, r);
848
+ i(a, n);
1126
849
  } else
1127
- t != null && o(r, t, n);
850
+ t != null && o(n, t, r);
1128
851
  return this;
1129
852
  }
1130
- get(t, r) {
1131
- if (t = ne(t), t) {
1132
- const n = c.findKey(this, t);
1133
- if (n) {
1134
- const s = this[n];
1135
- if (!r)
853
+ get(t, n) {
854
+ if (t = J(t), t) {
855
+ const r = c.findKey(this, t);
856
+ if (r) {
857
+ const s = this[r];
858
+ if (!n)
1136
859
  return s;
1137
- if (r === !0)
1138
- return Qr(s);
1139
- if (c.isFunction(r))
1140
- return r.call(this, s, n);
1141
- if (c.isRegExp(r))
1142
- return r.exec(s);
860
+ if (n === !0)
861
+ return $n(s);
862
+ if (c.isFunction(n))
863
+ return n.call(this, s, r);
864
+ if (c.isRegExp(n))
865
+ return n.exec(s);
1143
866
  throw new TypeError("parser must be boolean|regexp|function");
1144
867
  }
1145
868
  }
1146
869
  }
1147
- has(t, r) {
1148
- if (t = ne(t), t) {
1149
- const n = c.findKey(this, t);
1150
- return !!(n && this[n] !== void 0 && (!r || Ce(this, this[n], n, r)));
870
+ has(t, n) {
871
+ if (t = J(t), t) {
872
+ const r = c.findKey(this, t);
873
+ return !!(r && this[r] !== void 0 && (!n || me(this, this[r], r, n)));
1151
874
  }
1152
875
  return !1;
1153
876
  }
1154
- delete(t, r) {
1155
- const n = this;
877
+ delete(t, n) {
878
+ const r = this;
1156
879
  let s = !1;
1157
880
  function o(i) {
1158
- if (i = ne(i), i) {
1159
- const a = c.findKey(n, i);
1160
- a && (!r || Ce(n, n[a], a, r)) && (delete n[a], s = !0);
881
+ if (i = J(i), i) {
882
+ const a = c.findKey(r, i);
883
+ a && (!n || me(r, r[a], a, n)) && (delete r[a], s = !0);
1161
884
  }
1162
885
  }
1163
886
  return c.isArray(t) ? t.forEach(o) : o(t), s;
1164
887
  }
1165
888
  clear(t) {
1166
- const r = Object.keys(this);
1167
- let n = r.length, s = !1;
1168
- for (; n--; ) {
1169
- const o = r[n];
1170
- (!t || Ce(this, this[o], o, t, !0)) && (delete this[o], s = !0);
889
+ const n = Object.keys(this);
890
+ let r = n.length, s = !1;
891
+ for (; r--; ) {
892
+ const o = n[r];
893
+ (!t || me(this, this[o], o, t, !0)) && (delete this[o], s = !0);
1171
894
  }
1172
895
  return s;
1173
896
  }
1174
897
  normalize(t) {
1175
- const r = this, n = {};
898
+ const n = this, r = {};
1176
899
  return c.forEach(this, (s, o) => {
1177
- const i = c.findKey(n, o);
900
+ const i = c.findKey(r, o);
1178
901
  if (i) {
1179
- r[i] = be(s), delete r[o];
902
+ n[i] = oe(s), delete n[o];
1180
903
  return;
1181
904
  }
1182
- const a = t ? tn(o) : String(o).trim();
1183
- a !== o && delete r[o], r[a] = be(s), n[a] = !0;
905
+ const a = t ? Hn(o) : String(o).trim();
906
+ a !== o && delete n[o], n[a] = oe(s), r[a] = !0;
1184
907
  }), this;
1185
908
  }
1186
909
  concat(...t) {
1187
910
  return this.constructor.concat(this, ...t);
1188
911
  }
1189
912
  toJSON(t) {
1190
- const r = /* @__PURE__ */ Object.create(null);
1191
- return c.forEach(this, (n, s) => {
1192
- n != null && n !== !1 && (r[s] = t && c.isArray(n) ? n.join(", ") : n);
1193
- }), r;
913
+ const n = /* @__PURE__ */ Object.create(null);
914
+ return c.forEach(this, (r, s) => {
915
+ r != null && r !== !1 && (n[s] = t && c.isArray(r) ? r.join(", ") : r);
916
+ }), n;
1194
917
  }
1195
918
  [Symbol.iterator]() {
1196
919
  return Object.entries(this.toJSON())[Symbol.iterator]();
1197
920
  }
1198
921
  toString() {
1199
- return Object.entries(this.toJSON()).map(([t, r]) => t + ": " + r).join(`
922
+ return Object.entries(this.toJSON()).map(([t, n]) => t + ": " + n).join(`
1200
923
  `);
1201
924
  }
1202
925
  getSetCookie() {
@@ -1208,43 +931,43 @@ let D = class {
1208
931
  static from(t) {
1209
932
  return t instanceof this ? t : new this(t);
1210
933
  }
1211
- static concat(t, ...r) {
1212
- const n = new this(t);
1213
- return r.forEach((s) => n.set(s)), n;
934
+ static concat(t, ...n) {
935
+ const r = new this(t);
936
+ return n.forEach((s) => r.set(s)), r;
1214
937
  }
1215
938
  static accessor(t) {
1216
- const n = (this[Ye] = this[Ye] = {
939
+ const r = (this[Me] = this[Me] = {
1217
940
  accessors: {}
1218
941
  }).accessors, s = this.prototype;
1219
942
  function o(i) {
1220
- const a = ne(i);
1221
- n[a] || (rn(s, i), n[a] = !0);
943
+ const a = J(i);
944
+ r[a] || (zn(s, i), r[a] = !0);
1222
945
  }
1223
946
  return c.isArray(t) ? t.forEach(o) : o(t), this;
1224
947
  }
1225
948
  };
1226
- D.accessor(["Content-Type", "Content-Length", "Accept", "Accept-Encoding", "User-Agent", "Authorization"]);
1227
- c.reduceDescriptors(D.prototype, ({ value: e }, t) => {
1228
- let r = t[0].toUpperCase() + t.slice(1);
949
+ N.accessor(["Content-Type", "Content-Length", "Accept", "Accept-Encoding", "User-Agent", "Authorization"]);
950
+ c.reduceDescriptors(N.prototype, ({ value: e }, t) => {
951
+ let n = t[0].toUpperCase() + t.slice(1);
1229
952
  return {
1230
953
  get: () => e,
1231
- set(n) {
1232
- this[r] = n;
954
+ set(r) {
955
+ this[n] = r;
1233
956
  }
1234
957
  };
1235
958
  });
1236
- c.freezeMethods(D);
1237
- function Ne(e, t) {
1238
- const r = this || le, n = t || r, s = D.from(n.headers);
1239
- let o = n.data;
959
+ c.freezeMethods(N);
960
+ function ye(e, t) {
961
+ const n = this || Z, r = t || n, s = N.from(r.headers);
962
+ let o = r.data;
1240
963
  return c.forEach(e, function(a) {
1241
- o = a.call(r, o, s.normalize(), t ? t.status : void 0);
964
+ o = a.call(n, o, s.normalize(), t ? t.status : void 0);
1242
965
  }), s.normalize(), o;
1243
966
  }
1244
- function At(e) {
967
+ function yt(e) {
1245
968
  return !!(e && e.__CANCEL__);
1246
969
  }
1247
- let ue = class extends b {
970
+ let Q = class extends w {
1248
971
  /**
1249
972
  * A `CanceledError` is an object that is thrown when an operation is canceled.
1250
973
  *
@@ -1254,88 +977,88 @@ let ue = class extends b {
1254
977
  *
1255
978
  * @returns {CanceledError} The created error.
1256
979
  */
1257
- constructor(t, r, n) {
1258
- super(t ?? "canceled", b.ERR_CANCELED, r, n), this.name = "CanceledError", this.__CANCEL__ = !0;
980
+ constructor(t, n, r) {
981
+ super(t ?? "canceled", w.ERR_CANCELED, n, r), this.name = "CanceledError", this.__CANCEL__ = !0;
1259
982
  }
1260
983
  };
1261
- function xt(e, t, r) {
1262
- const n = r.config.validateStatus;
1263
- !r.status || !n || n(r.status) ? e(r) : t(new b(
1264
- "Request failed with status code " + r.status,
1265
- [b.ERR_BAD_REQUEST, b.ERR_BAD_RESPONSE][Math.floor(r.status / 100) - 4],
1266
- r.config,
1267
- r.request,
1268
- r
984
+ function wt(e, t, n) {
985
+ const r = n.config.validateStatus;
986
+ !n.status || !r || r(n.status) ? e(n) : t(new w(
987
+ "Request failed with status code " + n.status,
988
+ [w.ERR_BAD_REQUEST, w.ERR_BAD_RESPONSE][Math.floor(n.status / 100) - 4],
989
+ n.config,
990
+ n.request,
991
+ n
1269
992
  ));
1270
993
  }
1271
- function nn(e) {
994
+ function vn(e) {
1272
995
  const t = /^([-+\w]{1,25})(:?\/\/|:)/.exec(e);
1273
996
  return t && t[1] || "";
1274
997
  }
1275
- function sn(e, t) {
998
+ function Jn(e, t) {
1276
999
  e = e || 10;
1277
- const r = new Array(e), n = new Array(e);
1000
+ const n = new Array(e), r = new Array(e);
1278
1001
  let s = 0, o = 0, i;
1279
- return t = t !== void 0 ? t : 1e3, function(p) {
1280
- const f = Date.now(), u = n[o];
1281
- i || (i = f), r[s] = p, n[s] = f;
1282
- let m = o, g = 0;
1283
- for (; m !== s; )
1284
- g += r[m++], m = m % e;
1285
- if (s = (s + 1) % e, s === o && (o = (o + 1) % e), f - i < t)
1002
+ return t = t !== void 0 ? t : 1e3, function(d) {
1003
+ const u = Date.now(), l = r[o];
1004
+ i || (i = u), n[s] = d, r[s] = u;
1005
+ let p = o, b = 0;
1006
+ for (; p !== s; )
1007
+ b += n[p++], p = p % e;
1008
+ if (s = (s + 1) % e, s === o && (o = (o + 1) % e), u - i < t)
1286
1009
  return;
1287
- const O = u && f - u;
1288
- return O ? Math.round(g * 1e3 / O) : void 0;
1010
+ const _ = l && u - l;
1011
+ return _ ? Math.round(b * 1e3 / _) : void 0;
1289
1012
  };
1290
1013
  }
1291
- function on(e, t) {
1292
- let r = 0, n = 1e3 / t, s, o;
1293
- const i = (f, u = Date.now()) => {
1294
- r = u, s = null, o && (clearTimeout(o), o = null), e(...f);
1014
+ function Kn(e, t) {
1015
+ let n = 0, r = 1e3 / t, s, o;
1016
+ const i = (u, l = Date.now()) => {
1017
+ n = l, s = null, o && (clearTimeout(o), o = null), e(...u);
1295
1018
  };
1296
- return [(...f) => {
1297
- const u = Date.now(), m = u - r;
1298
- m >= n ? i(f, u) : (s = f, o || (o = setTimeout(() => {
1019
+ return [(...u) => {
1020
+ const l = Date.now(), p = l - n;
1021
+ p >= r ? i(u, l) : (s = u, o || (o = setTimeout(() => {
1299
1022
  o = null, i(s);
1300
- }, n - m)));
1023
+ }, r - p)));
1301
1024
  }, () => s && i(s)];
1302
1025
  }
1303
- const ge = (e, t, r = 3) => {
1304
- let n = 0;
1305
- const s = sn(50, 250);
1306
- return on((o) => {
1307
- const i = o.loaded, a = o.lengthComputable ? o.total : void 0, p = i - n, f = s(p), u = i <= a;
1308
- n = i;
1309
- const m = {
1026
+ const ae = (e, t, n = 3) => {
1027
+ let r = 0;
1028
+ const s = Jn(50, 250);
1029
+ return Kn((o) => {
1030
+ const i = o.loaded, a = o.lengthComputable ? o.total : void 0, d = i - r, u = s(d), l = i <= a;
1031
+ r = i;
1032
+ const p = {
1310
1033
  loaded: i,
1311
1034
  total: a,
1312
1035
  progress: a ? i / a : void 0,
1313
- bytes: p,
1314
- rate: f || void 0,
1315
- estimated: f && a && u ? (a - i) / f : void 0,
1036
+ bytes: d,
1037
+ rate: u || void 0,
1038
+ estimated: u && a && l ? (a - i) / u : void 0,
1316
1039
  event: o,
1317
1040
  lengthComputable: a != null,
1318
1041
  [t ? "download" : "upload"]: !0
1319
1042
  };
1320
- e(m);
1321
- }, r);
1322
- }, Xe = (e, t) => {
1323
- const r = e != null;
1324
- return [(n) => t[0]({
1325
- lengthComputable: r,
1043
+ e(p);
1044
+ }, n);
1045
+ }, $e = (e, t) => {
1046
+ const n = e != null;
1047
+ return [(r) => t[0]({
1048
+ lengthComputable: n,
1326
1049
  total: e,
1327
- loaded: n
1050
+ loaded: r
1328
1051
  }), t[1]];
1329
- }, Ge = (e) => (...t) => c.asap(() => e(...t)), an = k.hasStandardBrowserEnv ? /* @__PURE__ */ ((e, t) => (r) => (r = new URL(r, k.origin), e.protocol === r.protocol && e.host === r.host && (t || e.port === r.port)))(
1330
- new URL(k.origin),
1331
- k.navigator && /(msie|trident)/i.test(k.navigator.userAgent)
1332
- ) : () => !0, cn = k.hasStandardBrowserEnv ? (
1052
+ }, qe = (e) => (...t) => c.asap(() => e(...t)), Vn = A.hasStandardBrowserEnv ? /* @__PURE__ */ ((e, t) => (n) => (n = new URL(n, A.origin), e.protocol === n.protocol && e.host === n.host && (t || e.port === n.port)))(
1053
+ new URL(A.origin),
1054
+ A.navigator && /(msie|trident)/i.test(A.navigator.userAgent)
1055
+ ) : () => !0, Wn = A.hasStandardBrowserEnv ? (
1333
1056
  // Standard browser envs support document.cookie
1334
1057
  {
1335
- write(e, t, r, n, s, o, i) {
1058
+ write(e, t, n, r, s, o, i) {
1336
1059
  if (typeof document > "u") return;
1337
1060
  const a = [`${e}=${encodeURIComponent(t)}`];
1338
- c.isNumber(r) && a.push(`expires=${new Date(r).toUTCString()}`), c.isString(n) && a.push(`path=${n}`), c.isString(s) && a.push(`domain=${s}`), o === !0 && a.push("secure"), c.isString(i) && a.push(`SameSite=${i}`), document.cookie = a.join("; ");
1061
+ c.isNumber(n) && a.push(`expires=${new Date(n).toUTCString()}`), c.isString(r) && a.push(`path=${r}`), c.isString(s) && a.push(`domain=${s}`), o === !0 && a.push("secure"), c.isString(i) && a.push(`SameSite=${i}`), document.cookie = a.join("; ");
1339
1062
  },
1340
1063
  read(e) {
1341
1064
  if (typeof document > "u") return null;
@@ -1358,46 +1081,46 @@ const ge = (e, t, r = 3) => {
1358
1081
  }
1359
1082
  }
1360
1083
  );
1361
- function ln(e) {
1084
+ function Xn(e) {
1362
1085
  return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(e);
1363
1086
  }
1364
- function un(e, t) {
1087
+ function Gn(e, t) {
1365
1088
  return t ? e.replace(/\/?\/$/, "") + "/" + t.replace(/^\/+/, "") : e;
1366
1089
  }
1367
- function Ct(e, t, r) {
1368
- let n = !ln(t);
1369
- return e && (n || r == !1) ? un(e, t) : t;
1090
+ function bt(e, t, n) {
1091
+ let r = !Xn(t);
1092
+ return e && (r || n == !1) ? Gn(e, t) : t;
1370
1093
  }
1371
- const Ze = (e) => e instanceof D ? { ...e } : e;
1372
- function W(e, t) {
1094
+ const He = (e) => e instanceof N ? { ...e } : e;
1095
+ function $(e, t) {
1373
1096
  t = t || {};
1374
- const r = {};
1375
- function n(f, u, m, g) {
1376
- return c.isPlainObject(f) && c.isPlainObject(u) ? c.merge.call({ caseless: g }, f, u) : c.isPlainObject(u) ? c.merge({}, u) : c.isArray(u) ? u.slice() : u;
1377
- }
1378
- function s(f, u, m, g) {
1379
- if (c.isUndefined(u)) {
1380
- if (!c.isUndefined(f))
1381
- return n(void 0, f, m, g);
1382
- } else return n(f, u, m, g);
1383
- }
1384
- function o(f, u) {
1385
- if (!c.isUndefined(u))
1386
- return n(void 0, u);
1387
- }
1388
- function i(f, u) {
1389
- if (c.isUndefined(u)) {
1390
- if (!c.isUndefined(f))
1391
- return n(void 0, f);
1392
- } else return n(void 0, u);
1393
- }
1394
- function a(f, u, m) {
1395
- if (m in t)
1396
- return n(f, u);
1397
- if (m in e)
1398
- return n(void 0, f);
1399
- }
1400
- const p = {
1097
+ const n = {};
1098
+ function r(u, l, p, b) {
1099
+ return c.isPlainObject(u) && c.isPlainObject(l) ? c.merge.call({ caseless: b }, u, l) : c.isPlainObject(l) ? c.merge({}, l) : c.isArray(l) ? l.slice() : l;
1100
+ }
1101
+ function s(u, l, p, b) {
1102
+ if (c.isUndefined(l)) {
1103
+ if (!c.isUndefined(u))
1104
+ return r(void 0, u, p, b);
1105
+ } else return r(u, l, p, b);
1106
+ }
1107
+ function o(u, l) {
1108
+ if (!c.isUndefined(l))
1109
+ return r(void 0, l);
1110
+ }
1111
+ function i(u, l) {
1112
+ if (c.isUndefined(l)) {
1113
+ if (!c.isUndefined(u))
1114
+ return r(void 0, u);
1115
+ } else return r(void 0, l);
1116
+ }
1117
+ function a(u, l, p) {
1118
+ if (p in t)
1119
+ return r(u, l);
1120
+ if (p in e)
1121
+ return r(void 0, u);
1122
+ }
1123
+ const d = {
1401
1124
  url: o,
1402
1125
  method: o,
1403
1126
  data: o,
@@ -1426,128 +1149,128 @@ function W(e, t) {
1426
1149
  socketPath: i,
1427
1150
  responseEncoding: i,
1428
1151
  validateStatus: a,
1429
- headers: (f, u, m) => s(Ze(f), Ze(u), m, !0)
1152
+ headers: (u, l, p) => s(He(u), He(l), p, !0)
1430
1153
  };
1431
- return c.forEach(Object.keys({ ...e, ...t }), function(u) {
1432
- const m = p[u] || s, g = m(e[u], t[u], u);
1433
- c.isUndefined(g) && m !== a || (r[u] = g);
1434
- }), r;
1154
+ return c.forEach(Object.keys({ ...e, ...t }), function(l) {
1155
+ const p = d[l] || s, b = p(e[l], t[l], l);
1156
+ c.isUndefined(b) && p !== a || (n[l] = b);
1157
+ }), n;
1435
1158
  }
1436
- const Nt = (e) => {
1437
- const t = W({}, e);
1438
- let { data: r, withXSRFToken: n, xsrfHeaderName: s, xsrfCookieName: o, headers: i, auth: a } = t;
1439
- if (t.headers = i = D.from(i), t.url = _t(Ct(t.baseURL, t.url, t.allowAbsoluteUrls), e.params, e.paramsSerializer), a && i.set(
1159
+ const gt = (e) => {
1160
+ const t = $({}, e);
1161
+ let { data: n, withXSRFToken: r, xsrfHeaderName: s, xsrfCookieName: o, headers: i, auth: a } = t;
1162
+ if (t.headers = i = N.from(i), t.url = pt(bt(t.baseURL, t.url, t.allowAbsoluteUrls), e.params, e.paramsSerializer), a && i.set(
1440
1163
  "Authorization",
1441
1164
  "Basic " + btoa((a.username || "") + ":" + (a.password ? unescape(encodeURIComponent(a.password)) : ""))
1442
- ), c.isFormData(r)) {
1443
- if (k.hasStandardBrowserEnv || k.hasStandardBrowserWebWorkerEnv)
1165
+ ), c.isFormData(n)) {
1166
+ if (A.hasStandardBrowserEnv || A.hasStandardBrowserWebWorkerEnv)
1444
1167
  i.setContentType(void 0);
1445
- else if (c.isFunction(r.getHeaders)) {
1446
- const p = r.getHeaders(), f = ["content-type", "content-length"];
1447
- Object.entries(p).forEach(([u, m]) => {
1448
- f.includes(u.toLowerCase()) && i.set(u, m);
1168
+ else if (c.isFunction(n.getHeaders)) {
1169
+ const d = n.getHeaders(), u = ["content-type", "content-length"];
1170
+ Object.entries(d).forEach(([l, p]) => {
1171
+ u.includes(l.toLowerCase()) && i.set(l, p);
1449
1172
  });
1450
1173
  }
1451
1174
  }
1452
- if (k.hasStandardBrowserEnv && (n && c.isFunction(n) && (n = n(t)), n || n !== !1 && an(t.url))) {
1453
- const p = s && o && cn.read(o);
1454
- p && i.set(s, p);
1175
+ if (A.hasStandardBrowserEnv && (r && c.isFunction(r) && (r = r(t)), r || r !== !1 && Vn(t.url))) {
1176
+ const d = s && o && Wn.read(o);
1177
+ d && i.set(s, d);
1455
1178
  }
1456
1179
  return t;
1457
- }, fn = typeof XMLHttpRequest < "u", dn = fn && function(e) {
1458
- return new Promise(function(r, n) {
1459
- const s = Nt(e);
1180
+ }, Zn = typeof XMLHttpRequest < "u", Qn = Zn && function(e) {
1181
+ return new Promise(function(n, r) {
1182
+ const s = gt(e);
1460
1183
  let o = s.data;
1461
- const i = D.from(s.headers).normalize();
1462
- let { responseType: a, onUploadProgress: p, onDownloadProgress: f } = s, u, m, g, O, d;
1463
- function y() {
1464
- O && O(), d && d(), s.cancelToken && s.cancelToken.unsubscribe(u), s.signal && s.signal.removeEventListener("abort", u);
1184
+ const i = N.from(s.headers).normalize();
1185
+ let { responseType: a, onUploadProgress: d, onDownloadProgress: u } = s, l, p, b, _, f;
1186
+ function m() {
1187
+ _ && _(), f && f(), s.cancelToken && s.cancelToken.unsubscribe(l), s.signal && s.signal.removeEventListener("abort", l);
1465
1188
  }
1466
1189
  let h = new XMLHttpRequest();
1467
1190
  h.open(s.method.toUpperCase(), s.url, !0), h.timeout = s.timeout;
1468
- function S() {
1191
+ function g() {
1469
1192
  if (!h)
1470
1193
  return;
1471
- const w = D.from(
1194
+ const y = N.from(
1472
1195
  "getAllResponseHeaders" in h && h.getAllResponseHeaders()
1473
- ), P = {
1196
+ ), T = {
1474
1197
  data: !a || a === "text" || a === "json" ? h.responseText : h.response,
1475
1198
  status: h.status,
1476
1199
  statusText: h.statusText,
1477
- headers: w,
1200
+ headers: y,
1478
1201
  config: e,
1479
1202
  request: h
1480
1203
  };
1481
- xt(function(j) {
1482
- r(j), y();
1483
- }, function(j) {
1484
- n(j), y();
1485
- }, P), h = null;
1204
+ wt(function(P) {
1205
+ n(P), m();
1206
+ }, function(P) {
1207
+ r(P), m();
1208
+ }, T), h = null;
1486
1209
  }
1487
- "onloadend" in h ? h.onloadend = S : h.onreadystatechange = function() {
1488
- !h || h.readyState !== 4 || h.status === 0 && !(h.responseURL && h.responseURL.indexOf("file:") === 0) || setTimeout(S);
1210
+ "onloadend" in h ? h.onloadend = g : h.onreadystatechange = function() {
1211
+ !h || h.readyState !== 4 || h.status === 0 && !(h.responseURL && h.responseURL.indexOf("file:") === 0) || setTimeout(g);
1489
1212
  }, h.onabort = function() {
1490
- h && (n(new b("Request aborted", b.ECONNABORTED, e, h)), h = null);
1491
- }, h.onerror = function(_) {
1492
- const P = _ && _.message ? _.message : "Network Error", U = new b(P, b.ERR_NETWORK, e, h);
1493
- U.event = _ || null, n(U), h = null;
1213
+ h && (r(new w("Request aborted", w.ECONNABORTED, e, h)), h = null);
1214
+ }, h.onerror = function(E) {
1215
+ const T = E && E.message ? E.message : "Network Error", L = new w(T, w.ERR_NETWORK, e, h);
1216
+ L.event = E || null, r(L), h = null;
1494
1217
  }, h.ontimeout = function() {
1495
- let _ = s.timeout ? "timeout of " + s.timeout + "ms exceeded" : "timeout exceeded";
1496
- const P = s.transitional || Tt;
1497
- s.timeoutErrorMessage && (_ = s.timeoutErrorMessage), n(new b(
1498
- _,
1499
- P.clarifyTimeoutError ? b.ETIMEDOUT : b.ECONNABORTED,
1218
+ let E = s.timeout ? "timeout of " + s.timeout + "ms exceeded" : "timeout exceeded";
1219
+ const T = s.transitional || ht;
1220
+ s.timeoutErrorMessage && (E = s.timeoutErrorMessage), r(new w(
1221
+ E,
1222
+ T.clarifyTimeoutError ? w.ETIMEDOUT : w.ECONNABORTED,
1500
1223
  e,
1501
1224
  h
1502
1225
  )), h = null;
1503
- }, o === void 0 && i.setContentType(null), "setRequestHeader" in h && c.forEach(i.toJSON(), function(_, P) {
1504
- h.setRequestHeader(P, _);
1505
- }), c.isUndefined(s.withCredentials) || (h.withCredentials = !!s.withCredentials), a && a !== "json" && (h.responseType = s.responseType), f && ([g, d] = ge(f, !0), h.addEventListener("progress", g)), p && h.upload && ([m, O] = ge(p), h.upload.addEventListener("progress", m), h.upload.addEventListener("loadend", O)), (s.cancelToken || s.signal) && (u = (w) => {
1506
- h && (n(!w || w.type ? new ue(null, e, h) : w), h.abort(), h = null);
1507
- }, s.cancelToken && s.cancelToken.subscribe(u), s.signal && (s.signal.aborted ? u() : s.signal.addEventListener("abort", u)));
1508
- const x = nn(s.url);
1509
- if (x && k.protocols.indexOf(x) === -1) {
1510
- n(new b("Unsupported protocol " + x + ":", b.ERR_BAD_REQUEST, e));
1226
+ }, o === void 0 && i.setContentType(null), "setRequestHeader" in h && c.forEach(i.toJSON(), function(E, T) {
1227
+ h.setRequestHeader(T, E);
1228
+ }), c.isUndefined(s.withCredentials) || (h.withCredentials = !!s.withCredentials), a && a !== "json" && (h.responseType = s.responseType), u && ([b, f] = ae(u, !0), h.addEventListener("progress", b)), d && h.upload && ([p, _] = ae(d), h.upload.addEventListener("progress", p), h.upload.addEventListener("loadend", _)), (s.cancelToken || s.signal) && (l = (y) => {
1229
+ h && (r(!y || y.type ? new Q(null, e, h) : y), h.abort(), h = null);
1230
+ }, s.cancelToken && s.cancelToken.subscribe(l), s.signal && (s.signal.aborted ? l() : s.signal.addEventListener("abort", l)));
1231
+ const R = vn(s.url);
1232
+ if (R && A.protocols.indexOf(R) === -1) {
1233
+ r(new w("Unsupported protocol " + R + ":", w.ERR_BAD_REQUEST, e));
1511
1234
  return;
1512
1235
  }
1513
1236
  h.send(o || null);
1514
1237
  });
1515
- }, pn = (e, t) => {
1516
- const { length: r } = e = e ? e.filter(Boolean) : [];
1517
- if (t || r) {
1518
- let n = new AbortController(), s;
1519
- const o = function(f) {
1238
+ }, Yn = (e, t) => {
1239
+ const { length: n } = e = e ? e.filter(Boolean) : [];
1240
+ if (t || n) {
1241
+ let r = new AbortController(), s;
1242
+ const o = function(u) {
1520
1243
  if (!s) {
1521
1244
  s = !0, a();
1522
- const u = f instanceof Error ? f : this.reason;
1523
- n.abort(u instanceof b ? u : new ue(u instanceof Error ? u.message : u));
1245
+ const l = u instanceof Error ? u : this.reason;
1246
+ r.abort(l instanceof w ? l : new Q(l instanceof Error ? l.message : l));
1524
1247
  }
1525
1248
  };
1526
1249
  let i = t && setTimeout(() => {
1527
- i = null, o(new b(`timeout of ${t}ms exceeded`, b.ETIMEDOUT));
1250
+ i = null, o(new w(`timeout of ${t}ms exceeded`, w.ETIMEDOUT));
1528
1251
  }, t);
1529
1252
  const a = () => {
1530
- e && (i && clearTimeout(i), i = null, e.forEach((f) => {
1531
- f.unsubscribe ? f.unsubscribe(o) : f.removeEventListener("abort", o);
1253
+ e && (i && clearTimeout(i), i = null, e.forEach((u) => {
1254
+ u.unsubscribe ? u.unsubscribe(o) : u.removeEventListener("abort", o);
1532
1255
  }), e = null);
1533
1256
  };
1534
- e.forEach((f) => f.addEventListener("abort", o));
1535
- const { signal: p } = n;
1536
- return p.unsubscribe = () => c.asap(a), p;
1257
+ e.forEach((u) => u.addEventListener("abort", o));
1258
+ const { signal: d } = r;
1259
+ return d.unsubscribe = () => c.asap(a), d;
1537
1260
  }
1538
- }, hn = function* (e, t) {
1539
- let r = e.byteLength;
1540
- if (r < t) {
1261
+ }, er = function* (e, t) {
1262
+ let n = e.byteLength;
1263
+ if (n < t) {
1541
1264
  yield e;
1542
1265
  return;
1543
1266
  }
1544
- let n = 0, s;
1545
- for (; n < r; )
1546
- s = n + t, yield e.slice(n, s), n = s;
1547
- }, mn = async function* (e, t) {
1548
- for await (const r of yn(e))
1549
- yield* hn(r, t);
1550
- }, yn = async function* (e) {
1267
+ let r = 0, s;
1268
+ for (; r < n; )
1269
+ s = r + t, yield e.slice(r, s), r = s;
1270
+ }, tr = async function* (e, t) {
1271
+ for await (const n of nr(e))
1272
+ yield* er(n, t);
1273
+ }, nr = async function* (e) {
1551
1274
  if (e[Symbol.asyncIterator]) {
1552
1275
  yield* e;
1553
1276
  return;
@@ -1555,208 +1278,208 @@ const Nt = (e) => {
1555
1278
  const t = e.getReader();
1556
1279
  try {
1557
1280
  for (; ; ) {
1558
- const { done: r, value: n } = await t.read();
1559
- if (r)
1281
+ const { done: n, value: r } = await t.read();
1282
+ if (n)
1560
1283
  break;
1561
- yield n;
1284
+ yield r;
1562
1285
  }
1563
1286
  } finally {
1564
1287
  await t.cancel();
1565
1288
  }
1566
- }, Qe = (e, t, r, n) => {
1567
- const s = mn(e, t);
1568
- let o = 0, i, a = (p) => {
1569
- i || (i = !0, n && n(p));
1289
+ }, ze = (e, t, n, r) => {
1290
+ const s = tr(e, t);
1291
+ let o = 0, i, a = (d) => {
1292
+ i || (i = !0, r && r(d));
1570
1293
  };
1571
1294
  return new ReadableStream({
1572
- async pull(p) {
1295
+ async pull(d) {
1573
1296
  try {
1574
- const { done: f, value: u } = await s.next();
1575
- if (f) {
1576
- a(), p.close();
1297
+ const { done: u, value: l } = await s.next();
1298
+ if (u) {
1299
+ a(), d.close();
1577
1300
  return;
1578
1301
  }
1579
- let m = u.byteLength;
1580
- if (r) {
1581
- let g = o += m;
1582
- r(g);
1302
+ let p = l.byteLength;
1303
+ if (n) {
1304
+ let b = o += p;
1305
+ n(b);
1583
1306
  }
1584
- p.enqueue(new Uint8Array(u));
1585
- } catch (f) {
1586
- throw a(f), f;
1307
+ d.enqueue(new Uint8Array(l));
1308
+ } catch (u) {
1309
+ throw a(u), u;
1587
1310
  }
1588
1311
  },
1589
- cancel(p) {
1590
- return a(p), s.return();
1312
+ cancel(d) {
1313
+ return a(d), s.return();
1591
1314
  }
1592
1315
  }, {
1593
1316
  highWaterMark: 2
1594
1317
  });
1595
- }, et = 64 * 1024, { isFunction: ye } = c, wn = (({ Request: e, Response: t }) => ({
1318
+ }, ve = 64 * 1024, { isFunction: re } = c, rr = (({ Request: e, Response: t }) => ({
1596
1319
  Request: e,
1597
1320
  Response: t
1598
1321
  }))(c.global), {
1599
- ReadableStream: tt,
1600
- TextEncoder: rt
1601
- } = c.global, nt = (e, ...t) => {
1322
+ ReadableStream: Je,
1323
+ TextEncoder: Ke
1324
+ } = c.global, Ve = (e, ...t) => {
1602
1325
  try {
1603
1326
  return !!e(...t);
1604
1327
  } catch {
1605
1328
  return !1;
1606
1329
  }
1607
- }, bn = (e) => {
1330
+ }, sr = (e) => {
1608
1331
  e = c.merge.call({
1609
1332
  skipUndefined: !0
1610
- }, wn, e);
1611
- const { fetch: t, Request: r, Response: n } = e, s = t ? ye(t) : typeof fetch == "function", o = ye(r), i = ye(n);
1333
+ }, rr, e);
1334
+ const { fetch: t, Request: n, Response: r } = e, s = t ? re(t) : typeof fetch == "function", o = re(n), i = re(r);
1612
1335
  if (!s)
1613
1336
  return !1;
1614
- const a = s && ye(tt), p = s && (typeof rt == "function" ? /* @__PURE__ */ ((d) => (y) => d.encode(y))(new rt()) : async (d) => new Uint8Array(await new r(d).arrayBuffer())), f = o && a && nt(() => {
1615
- let d = !1;
1616
- const y = new r(k.origin, {
1617
- body: new tt(),
1337
+ const a = s && re(Je), d = s && (typeof Ke == "function" ? /* @__PURE__ */ ((f) => (m) => f.encode(m))(new Ke()) : async (f) => new Uint8Array(await new n(f).arrayBuffer())), u = o && a && Ve(() => {
1338
+ let f = !1;
1339
+ const m = new n(A.origin, {
1340
+ body: new Je(),
1618
1341
  method: "POST",
1619
1342
  get duplex() {
1620
- return d = !0, "half";
1343
+ return f = !0, "half";
1621
1344
  }
1622
1345
  }).headers.has("Content-Type");
1623
- return d && !y;
1624
- }), u = i && a && nt(() => c.isReadableStream(new n("").body)), m = {
1625
- stream: u && ((d) => d.body)
1346
+ return f && !m;
1347
+ }), l = i && a && Ve(() => c.isReadableStream(new r("").body)), p = {
1348
+ stream: l && ((f) => f.body)
1626
1349
  };
1627
- s && ["text", "arrayBuffer", "blob", "formData", "stream"].forEach((d) => {
1628
- !m[d] && (m[d] = (y, h) => {
1629
- let S = y && y[d];
1630
- if (S)
1631
- return S.call(y);
1632
- throw new b(`Response type '${d}' is not supported`, b.ERR_NOT_SUPPORT, h);
1350
+ s && ["text", "arrayBuffer", "blob", "formData", "stream"].forEach((f) => {
1351
+ !p[f] && (p[f] = (m, h) => {
1352
+ let g = m && m[f];
1353
+ if (g)
1354
+ return g.call(m);
1355
+ throw new w(`Response type '${f}' is not supported`, w.ERR_NOT_SUPPORT, h);
1633
1356
  });
1634
1357
  });
1635
- const g = async (d) => {
1636
- if (d == null)
1358
+ const b = async (f) => {
1359
+ if (f == null)
1637
1360
  return 0;
1638
- if (c.isBlob(d))
1639
- return d.size;
1640
- if (c.isSpecCompliantForm(d))
1641
- return (await new r(k.origin, {
1361
+ if (c.isBlob(f))
1362
+ return f.size;
1363
+ if (c.isSpecCompliantForm(f))
1364
+ return (await new n(A.origin, {
1642
1365
  method: "POST",
1643
- body: d
1366
+ body: f
1644
1367
  }).arrayBuffer()).byteLength;
1645
- if (c.isArrayBufferView(d) || c.isArrayBuffer(d))
1646
- return d.byteLength;
1647
- if (c.isURLSearchParams(d) && (d = d + ""), c.isString(d))
1648
- return (await p(d)).byteLength;
1649
- }, O = async (d, y) => {
1650
- const h = c.toFiniteNumber(d.getContentLength());
1651
- return h ?? g(y);
1368
+ if (c.isArrayBufferView(f) || c.isArrayBuffer(f))
1369
+ return f.byteLength;
1370
+ if (c.isURLSearchParams(f) && (f = f + ""), c.isString(f))
1371
+ return (await d(f)).byteLength;
1372
+ }, _ = async (f, m) => {
1373
+ const h = c.toFiniteNumber(f.getContentLength());
1374
+ return h ?? b(m);
1652
1375
  };
1653
- return async (d) => {
1376
+ return async (f) => {
1654
1377
  let {
1655
- url: y,
1378
+ url: m,
1656
1379
  method: h,
1657
- data: S,
1658
- signal: x,
1659
- cancelToken: w,
1660
- timeout: _,
1661
- onDownloadProgress: P,
1662
- onUploadProgress: U,
1663
- responseType: j,
1664
- headers: Z,
1665
- withCredentials: $ = "same-origin",
1666
- fetchOptions: fe
1667
- } = Nt(d), de = t || fetch;
1668
- j = j ? (j + "").toLowerCase() : "text";
1669
- let q = pn([x, w && w.toAbortSignal()], _), H = null;
1670
- const M = q && q.unsubscribe && (() => {
1671
- q.unsubscribe();
1380
+ data: g,
1381
+ signal: R,
1382
+ cancelToken: y,
1383
+ timeout: E,
1384
+ onDownloadProgress: T,
1385
+ onUploadProgress: L,
1386
+ responseType: P,
1387
+ headers: pe,
1388
+ withCredentials: Y = "same-origin",
1389
+ fetchOptions: Ne
1390
+ } = gt(f), xe = t || fetch;
1391
+ P = P ? (P + "").toLowerCase() : "text";
1392
+ let ee = Yn([R, y && y.toAbortSignal()], E), v = null;
1393
+ const I = ee && ee.unsubscribe && (() => {
1394
+ ee.unsubscribe();
1672
1395
  });
1673
- let K;
1396
+ let Pe;
1674
1397
  try {
1675
- if (U && f && h !== "get" && h !== "head" && (K = await O(Z, S)) !== 0) {
1676
- let l = new r(y, {
1398
+ if (L && u && h !== "get" && h !== "head" && (Pe = await _(pe, g)) !== 0) {
1399
+ let B = new n(m, {
1677
1400
  method: "POST",
1678
- body: S,
1401
+ body: g,
1679
1402
  duplex: "half"
1680
- }), E;
1681
- if (c.isFormData(S) && (E = l.headers.get("content-type")) && Z.setContentType(E), l.body) {
1682
- const [T, A] = Xe(
1683
- K,
1684
- ge(Ge(U))
1403
+ }), q;
1404
+ if (c.isFormData(g) && (q = B.headers.get("content-type")) && pe.setContentType(q), B.body) {
1405
+ const [he, te] = $e(
1406
+ Pe,
1407
+ ae(qe(L))
1685
1408
  );
1686
- S = Qe(l.body, et, T, A);
1409
+ g = ze(B.body, ve, he, te);
1687
1410
  }
1688
1411
  }
1689
- c.isString($) || ($ = $ ? "include" : "omit");
1690
- const L = o && "credentials" in r.prototype, Q = {
1691
- ...fe,
1692
- signal: q,
1412
+ c.isString(Y) || (Y = Y ? "include" : "omit");
1413
+ const F = o && "credentials" in n.prototype, De = {
1414
+ ...Ne,
1415
+ signal: ee,
1693
1416
  method: h.toUpperCase(),
1694
- headers: Z.normalize().toJSON(),
1695
- body: S,
1417
+ headers: pe.normalize().toJSON(),
1418
+ body: g,
1696
1419
  duplex: "half",
1697
- credentials: L ? $ : void 0
1420
+ credentials: F ? Y : void 0
1698
1421
  };
1699
- H = o && new r(y, Q);
1700
- let v = await (o ? de(H, fe) : de(y, Q));
1701
- const ee = u && (j === "stream" || j === "response");
1702
- if (u && (P || ee && M)) {
1703
- const l = {};
1704
- ["status", "statusText", "headers"].forEach((z) => {
1705
- l[z] = v[z];
1422
+ v = o && new n(m, De);
1423
+ let k = await (o ? xe(v, Ne) : xe(m, De));
1424
+ const Fe = l && (P === "stream" || P === "response");
1425
+ if (l && (T || Fe && I)) {
1426
+ const B = {};
1427
+ ["status", "statusText", "headers"].forEach((Ue) => {
1428
+ B[Ue] = k[Ue];
1706
1429
  });
1707
- const E = c.toFiniteNumber(v.headers.get("content-length")), [T, A] = P && Xe(
1708
- E,
1709
- ge(Ge(P), !0)
1430
+ const q = c.toFiniteNumber(k.headers.get("content-length")), [he, te] = T && $e(
1431
+ q,
1432
+ ae(qe(T), !0)
1710
1433
  ) || [];
1711
- v = new n(
1712
- Qe(v.body, et, T, () => {
1713
- A && A(), M && M();
1434
+ k = new r(
1435
+ ze(k.body, ve, he, () => {
1436
+ te && te(), I && I();
1714
1437
  }),
1715
- l
1438
+ B
1716
1439
  );
1717
1440
  }
1718
- j = j || "text";
1719
- let pe = await m[c.findKey(m, j) || "text"](v, d);
1720
- return !ee && M && M(), await new Promise((l, E) => {
1721
- xt(l, E, {
1722
- data: pe,
1723
- headers: D.from(v.headers),
1724
- status: v.status,
1725
- statusText: v.statusText,
1726
- config: d,
1727
- request: H
1441
+ P = P || "text";
1442
+ let At = await p[c.findKey(p, P) || "text"](k, f);
1443
+ return !Fe && I && I(), await new Promise((B, q) => {
1444
+ wt(B, q, {
1445
+ data: At,
1446
+ headers: N.from(k.headers),
1447
+ status: k.status,
1448
+ statusText: k.statusText,
1449
+ config: f,
1450
+ request: v
1728
1451
  });
1729
1452
  });
1730
- } catch (L) {
1731
- throw M && M(), L && L.name === "TypeError" && /Load failed|fetch/i.test(L.message) ? Object.assign(
1732
- new b("Network Error", b.ERR_NETWORK, d, H),
1453
+ } catch (F) {
1454
+ throw I && I(), F && F.name === "TypeError" && /Load failed|fetch/i.test(F.message) ? Object.assign(
1455
+ new w("Network Error", w.ERR_NETWORK, f, v),
1733
1456
  {
1734
- cause: L.cause || L
1457
+ cause: F.cause || F
1735
1458
  }
1736
- ) : b.from(L, L && L.code, d, H);
1459
+ ) : w.from(F, F && F.code, f, v);
1737
1460
  }
1738
1461
  };
1739
- }, En = /* @__PURE__ */ new Map(), Pt = (e) => {
1462
+ }, or = /* @__PURE__ */ new Map(), Et = (e) => {
1740
1463
  let t = e && e.env || {};
1741
- const { fetch: r, Request: n, Response: s } = t, o = [
1742
- n,
1464
+ const { fetch: n, Request: r, Response: s } = t, o = [
1465
+ r,
1743
1466
  s,
1744
- r
1467
+ n
1745
1468
  ];
1746
- let i = o.length, a = i, p, f, u = En;
1469
+ let i = o.length, a = i, d, u, l = or;
1747
1470
  for (; a--; )
1748
- p = o[a], f = u.get(p), f === void 0 && u.set(p, f = a ? /* @__PURE__ */ new Map() : bn(t)), u = f;
1749
- return f;
1471
+ d = o[a], u = l.get(d), u === void 0 && l.set(d, u = a ? /* @__PURE__ */ new Map() : sr(t)), l = u;
1472
+ return u;
1750
1473
  };
1751
- Pt();
1752
- const Me = {
1753
- http: Lr,
1754
- xhr: dn,
1474
+ Et();
1475
+ const Ce = {
1476
+ http: Rn,
1477
+ xhr: Qn,
1755
1478
  fetch: {
1756
- get: Pt
1479
+ get: Et
1757
1480
  }
1758
1481
  };
1759
- c.forEach(Me, (e, t) => {
1482
+ c.forEach(Ce, (e, t) => {
1760
1483
  if (e) {
1761
1484
  try {
1762
1485
  Object.defineProperty(e, "name", { value: t });
@@ -1765,123 +1488,123 @@ c.forEach(Me, (e, t) => {
1765
1488
  Object.defineProperty(e, "adapterName", { value: t });
1766
1489
  }
1767
1490
  });
1768
- const st = (e) => `- ${e}`, gn = (e) => c.isFunction(e) || e === null || e === !1;
1769
- function Rn(e, t) {
1491
+ const We = (e) => `- ${e}`, ir = (e) => c.isFunction(e) || e === null || e === !1;
1492
+ function ar(e, t) {
1770
1493
  e = c.isArray(e) ? e : [e];
1771
- const { length: r } = e;
1772
- let n, s;
1494
+ const { length: n } = e;
1495
+ let r, s;
1773
1496
  const o = {};
1774
- for (let i = 0; i < r; i++) {
1775
- n = e[i];
1497
+ for (let i = 0; i < n; i++) {
1498
+ r = e[i];
1776
1499
  let a;
1777
- if (s = n, !gn(n) && (s = Me[(a = String(n)).toLowerCase()], s === void 0))
1778
- throw new b(`Unknown adapter '${a}'`);
1500
+ if (s = r, !ir(r) && (s = Ce[(a = String(r)).toLowerCase()], s === void 0))
1501
+ throw new w(`Unknown adapter '${a}'`);
1779
1502
  if (s && (c.isFunction(s) || (s = s.get(t))))
1780
1503
  break;
1781
1504
  o[a || "#" + i] = s;
1782
1505
  }
1783
1506
  if (!s) {
1784
1507
  const i = Object.entries(o).map(
1785
- ([p, f]) => `adapter ${p} ` + (f === !1 ? "is not supported by the environment" : "is not available in the build")
1508
+ ([d, u]) => `adapter ${d} ` + (u === !1 ? "is not supported by the environment" : "is not available in the build")
1786
1509
  );
1787
- let a = r ? i.length > 1 ? `since :
1788
- ` + i.map(st).join(`
1789
- `) : " " + st(i[0]) : "as no adapter specified";
1790
- throw new b(
1510
+ let a = n ? i.length > 1 ? `since :
1511
+ ` + i.map(We).join(`
1512
+ `) : " " + We(i[0]) : "as no adapter specified";
1513
+ throw new w(
1791
1514
  "There is no suitable adapter to dispatch the request " + a,
1792
1515
  "ERR_NOT_SUPPORT"
1793
1516
  );
1794
1517
  }
1795
1518
  return s;
1796
1519
  }
1797
- const kt = {
1520
+ const St = {
1798
1521
  /**
1799
1522
  * Resolve an adapter from a list of adapter names or functions.
1800
1523
  * @type {Function}
1801
1524
  */
1802
- getAdapter: Rn,
1525
+ getAdapter: ar,
1803
1526
  /**
1804
1527
  * Exposes all known adapters
1805
1528
  * @type {Object<string, Function|Object>}
1806
1529
  */
1807
- adapters: Me
1530
+ adapters: Ce
1808
1531
  };
1809
- function Pe(e) {
1532
+ function we(e) {
1810
1533
  if (e.cancelToken && e.cancelToken.throwIfRequested(), e.signal && e.signal.aborted)
1811
- throw new ue(null, e);
1534
+ throw new Q(null, e);
1812
1535
  }
1813
- function ot(e) {
1814
- return Pe(e), e.headers = D.from(e.headers), e.data = Ne.call(
1536
+ function Xe(e) {
1537
+ return we(e), e.headers = N.from(e.headers), e.data = ye.call(
1815
1538
  e,
1816
1539
  e.transformRequest
1817
- ), ["post", "put", "patch"].indexOf(e.method) !== -1 && e.headers.setContentType("application/x-www-form-urlencoded", !1), kt.getAdapter(e.adapter || le.adapter, e)(e).then(function(n) {
1818
- return Pe(e), n.data = Ne.call(
1540
+ ), ["post", "put", "patch"].indexOf(e.method) !== -1 && e.headers.setContentType("application/x-www-form-urlencoded", !1), St.getAdapter(e.adapter || Z.adapter, e)(e).then(function(r) {
1541
+ return we(e), r.data = ye.call(
1819
1542
  e,
1820
1543
  e.transformResponse,
1821
- n
1822
- ), n.headers = D.from(n.headers), n;
1823
- }, function(n) {
1824
- return At(n) || (Pe(e), n && n.response && (n.response.data = Ne.call(
1544
+ r
1545
+ ), r.headers = N.from(r.headers), r;
1546
+ }, function(r) {
1547
+ return yt(r) || (we(e), r && r.response && (r.response.data = ye.call(
1825
1548
  e,
1826
1549
  e.transformResponse,
1827
- n.response
1828
- ), n.response.headers = D.from(n.response.headers))), Promise.reject(n);
1550
+ r.response
1551
+ ), r.response.headers = N.from(r.response.headers))), Promise.reject(r);
1829
1552
  });
1830
1553
  }
1831
- const jt = "1.13.4", Oe = {};
1554
+ const Rt = "1.13.4", de = {};
1832
1555
  ["object", "boolean", "number", "function", "string", "symbol"].forEach((e, t) => {
1833
- Oe[e] = function(n) {
1834
- return typeof n === e || "a" + (t < 1 ? "n " : " ") + e;
1556
+ de[e] = function(r) {
1557
+ return typeof r === e || "a" + (t < 1 ? "n " : " ") + e;
1835
1558
  };
1836
1559
  });
1837
- const it = {};
1838
- Oe.transitional = function(t, r, n) {
1560
+ const Ge = {};
1561
+ de.transitional = function(t, n, r) {
1839
1562
  function s(o, i) {
1840
- return "[Axios v" + jt + "] Transitional option '" + o + "'" + i + (n ? ". " + n : "");
1563
+ return "[Axios v" + Rt + "] Transitional option '" + o + "'" + i + (r ? ". " + r : "");
1841
1564
  }
1842
1565
  return (o, i, a) => {
1843
1566
  if (t === !1)
1844
- throw new b(
1845
- s(i, " has been removed" + (r ? " in " + r : "")),
1846
- b.ERR_DEPRECATED
1567
+ throw new w(
1568
+ s(i, " has been removed" + (n ? " in " + n : "")),
1569
+ w.ERR_DEPRECATED
1847
1570
  );
1848
- return r && !it[i] && (it[i] = !0, console.warn(
1571
+ return n && !Ge[i] && (Ge[i] = !0, console.warn(
1849
1572
  s(
1850
1573
  i,
1851
- " has been deprecated since v" + r + " and will be removed in the near future"
1574
+ " has been deprecated since v" + n + " and will be removed in the near future"
1852
1575
  )
1853
1576
  )), t ? t(o, i, a) : !0;
1854
1577
  };
1855
1578
  };
1856
- Oe.spelling = function(t) {
1857
- return (r, n) => (console.warn(`${n} is likely a misspelling of ${t}`), !0);
1579
+ de.spelling = function(t) {
1580
+ return (n, r) => (console.warn(`${r} is likely a misspelling of ${t}`), !0);
1858
1581
  };
1859
- function Sn(e, t, r) {
1582
+ function cr(e, t, n) {
1860
1583
  if (typeof e != "object")
1861
- throw new b("options must be an object", b.ERR_BAD_OPTION_VALUE);
1862
- const n = Object.keys(e);
1863
- let s = n.length;
1584
+ throw new w("options must be an object", w.ERR_BAD_OPTION_VALUE);
1585
+ const r = Object.keys(e);
1586
+ let s = r.length;
1864
1587
  for (; s-- > 0; ) {
1865
- const o = n[s], i = t[o];
1588
+ const o = r[s], i = t[o];
1866
1589
  if (i) {
1867
- const a = e[o], p = a === void 0 || i(a, o, e);
1868
- if (p !== !0)
1869
- throw new b("option " + o + " must be " + p, b.ERR_BAD_OPTION_VALUE);
1590
+ const a = e[o], d = a === void 0 || i(a, o, e);
1591
+ if (d !== !0)
1592
+ throw new w("option " + o + " must be " + d, w.ERR_BAD_OPTION_VALUE);
1870
1593
  continue;
1871
1594
  }
1872
- if (r !== !0)
1873
- throw new b("Unknown option " + o, b.ERR_BAD_OPTION);
1595
+ if (n !== !0)
1596
+ throw new w("Unknown option " + o, w.ERR_BAD_OPTION);
1874
1597
  }
1875
1598
  }
1876
- const Ee = {
1877
- assertOptions: Sn,
1878
- validators: Oe
1879
- }, B = Ee.validators;
1880
- let V = class {
1599
+ const ie = {
1600
+ assertOptions: cr,
1601
+ validators: de
1602
+ }, U = ie.validators;
1603
+ let M = class {
1881
1604
  constructor(t) {
1882
1605
  this.defaults = t || {}, this.interceptors = {
1883
- request: new Ke(),
1884
- response: new Ke()
1606
+ request: new je(),
1607
+ response: new je()
1885
1608
  };
1886
1609
  }
1887
1610
  /**
@@ -1892,106 +1615,106 @@ let V = class {
1892
1615
  *
1893
1616
  * @returns {Promise} The Promise to be fulfilled
1894
1617
  */
1895
- async request(t, r) {
1618
+ async request(t, n) {
1896
1619
  try {
1897
- return await this._request(t, r);
1898
- } catch (n) {
1899
- if (n instanceof Error) {
1620
+ return await this._request(t, n);
1621
+ } catch (r) {
1622
+ if (r instanceof Error) {
1900
1623
  let s = {};
1901
1624
  Error.captureStackTrace ? Error.captureStackTrace(s) : s = new Error();
1902
1625
  const o = s.stack ? s.stack.replace(/^.+\n/, "") : "";
1903
1626
  try {
1904
- n.stack ? o && !String(n.stack).endsWith(o.replace(/^.+\n.+\n/, "")) && (n.stack += `
1905
- ` + o) : n.stack = o;
1627
+ r.stack ? o && !String(r.stack).endsWith(o.replace(/^.+\n.+\n/, "")) && (r.stack += `
1628
+ ` + o) : r.stack = o;
1906
1629
  } catch {
1907
1630
  }
1908
1631
  }
1909
- throw n;
1632
+ throw r;
1910
1633
  }
1911
1634
  }
1912
- _request(t, r) {
1913
- typeof t == "string" ? (r = r || {}, r.url = t) : r = t || {}, r = W(this.defaults, r);
1914
- const { transitional: n, paramsSerializer: s, headers: o } = r;
1915
- n !== void 0 && Ee.assertOptions(n, {
1916
- silentJSONParsing: B.transitional(B.boolean),
1917
- forcedJSONParsing: B.transitional(B.boolean),
1918
- clarifyTimeoutError: B.transitional(B.boolean)
1919
- }, !1), s != null && (c.isFunction(s) ? r.paramsSerializer = {
1635
+ _request(t, n) {
1636
+ typeof t == "string" ? (n = n || {}, n.url = t) : n = t || {}, n = $(this.defaults, n);
1637
+ const { transitional: r, paramsSerializer: s, headers: o } = n;
1638
+ r !== void 0 && ie.assertOptions(r, {
1639
+ silentJSONParsing: U.transitional(U.boolean),
1640
+ forcedJSONParsing: U.transitional(U.boolean),
1641
+ clarifyTimeoutError: U.transitional(U.boolean)
1642
+ }, !1), s != null && (c.isFunction(s) ? n.paramsSerializer = {
1920
1643
  serialize: s
1921
- } : Ee.assertOptions(s, {
1922
- encode: B.function,
1923
- serialize: B.function
1924
- }, !0)), r.allowAbsoluteUrls !== void 0 || (this.defaults.allowAbsoluteUrls !== void 0 ? r.allowAbsoluteUrls = this.defaults.allowAbsoluteUrls : r.allowAbsoluteUrls = !0), Ee.assertOptions(r, {
1925
- baseUrl: B.spelling("baseURL"),
1926
- withXsrfToken: B.spelling("withXSRFToken")
1927
- }, !0), r.method = (r.method || this.defaults.method || "get").toLowerCase();
1644
+ } : ie.assertOptions(s, {
1645
+ encode: U.function,
1646
+ serialize: U.function
1647
+ }, !0)), n.allowAbsoluteUrls !== void 0 || (this.defaults.allowAbsoluteUrls !== void 0 ? n.allowAbsoluteUrls = this.defaults.allowAbsoluteUrls : n.allowAbsoluteUrls = !0), ie.assertOptions(n, {
1648
+ baseUrl: U.spelling("baseURL"),
1649
+ withXsrfToken: U.spelling("withXSRFToken")
1650
+ }, !0), n.method = (n.method || this.defaults.method || "get").toLowerCase();
1928
1651
  let i = o && c.merge(
1929
1652
  o.common,
1930
- o[r.method]
1653
+ o[n.method]
1931
1654
  );
1932
1655
  o && c.forEach(
1933
1656
  ["delete", "get", "head", "post", "put", "patch", "common"],
1934
- (d) => {
1935
- delete o[d];
1657
+ (f) => {
1658
+ delete o[f];
1936
1659
  }
1937
- ), r.headers = D.concat(i, o);
1660
+ ), n.headers = N.concat(i, o);
1938
1661
  const a = [];
1939
- let p = !0;
1940
- this.interceptors.request.forEach(function(y) {
1941
- typeof y.runWhen == "function" && y.runWhen(r) === !1 || (p = p && y.synchronous, a.unshift(y.fulfilled, y.rejected));
1662
+ let d = !0;
1663
+ this.interceptors.request.forEach(function(m) {
1664
+ typeof m.runWhen == "function" && m.runWhen(n) === !1 || (d = d && m.synchronous, a.unshift(m.fulfilled, m.rejected));
1942
1665
  });
1943
- const f = [];
1944
- this.interceptors.response.forEach(function(y) {
1945
- f.push(y.fulfilled, y.rejected);
1666
+ const u = [];
1667
+ this.interceptors.response.forEach(function(m) {
1668
+ u.push(m.fulfilled, m.rejected);
1946
1669
  });
1947
- let u, m = 0, g;
1948
- if (!p) {
1949
- const d = [ot.bind(this), void 0];
1950
- for (d.unshift(...a), d.push(...f), g = d.length, u = Promise.resolve(r); m < g; )
1951
- u = u.then(d[m++], d[m++]);
1952
- return u;
1670
+ let l, p = 0, b;
1671
+ if (!d) {
1672
+ const f = [Xe.bind(this), void 0];
1673
+ for (f.unshift(...a), f.push(...u), b = f.length, l = Promise.resolve(n); p < b; )
1674
+ l = l.then(f[p++], f[p++]);
1675
+ return l;
1953
1676
  }
1954
- g = a.length;
1955
- let O = r;
1956
- for (; m < g; ) {
1957
- const d = a[m++], y = a[m++];
1677
+ b = a.length;
1678
+ let _ = n;
1679
+ for (; p < b; ) {
1680
+ const f = a[p++], m = a[p++];
1958
1681
  try {
1959
- O = d(O);
1682
+ _ = f(_);
1960
1683
  } catch (h) {
1961
- y.call(this, h);
1684
+ m.call(this, h);
1962
1685
  break;
1963
1686
  }
1964
1687
  }
1965
1688
  try {
1966
- u = ot.call(this, O);
1967
- } catch (d) {
1968
- return Promise.reject(d);
1689
+ l = Xe.call(this, _);
1690
+ } catch (f) {
1691
+ return Promise.reject(f);
1969
1692
  }
1970
- for (m = 0, g = f.length; m < g; )
1971
- u = u.then(f[m++], f[m++]);
1972
- return u;
1693
+ for (p = 0, b = u.length; p < b; )
1694
+ l = l.then(u[p++], u[p++]);
1695
+ return l;
1973
1696
  }
1974
1697
  getUri(t) {
1975
- t = W(this.defaults, t);
1976
- const r = Ct(t.baseURL, t.url, t.allowAbsoluteUrls);
1977
- return _t(r, t.params, t.paramsSerializer);
1698
+ t = $(this.defaults, t);
1699
+ const n = bt(t.baseURL, t.url, t.allowAbsoluteUrls);
1700
+ return pt(n, t.params, t.paramsSerializer);
1978
1701
  }
1979
1702
  };
1980
1703
  c.forEach(["delete", "get", "head", "options"], function(t) {
1981
- V.prototype[t] = function(r, n) {
1982
- return this.request(W(n || {}, {
1704
+ M.prototype[t] = function(n, r) {
1705
+ return this.request($(r || {}, {
1983
1706
  method: t,
1984
- url: r,
1985
- data: (n || {}).data
1707
+ url: n,
1708
+ data: (r || {}).data
1986
1709
  }));
1987
1710
  };
1988
1711
  });
1989
1712
  c.forEach(["post", "put", "patch"], function(t) {
1990
- function r(n) {
1713
+ function n(r) {
1991
1714
  return function(o, i, a) {
1992
- return this.request(W(a || {}, {
1715
+ return this.request($(a || {}, {
1993
1716
  method: t,
1994
- headers: n ? {
1717
+ headers: r ? {
1995
1718
  "Content-Type": "multipart/form-data"
1996
1719
  } : {},
1997
1720
  url: o,
@@ -1999,33 +1722,33 @@ c.forEach(["post", "put", "patch"], function(t) {
1999
1722
  }));
2000
1723
  };
2001
1724
  }
2002
- V.prototype[t] = r(), V.prototype[t + "Form"] = r(!0);
1725
+ M.prototype[t] = n(), M.prototype[t + "Form"] = n(!0);
2003
1726
  });
2004
- let _n = class Ft {
1727
+ let lr = class Ot {
2005
1728
  constructor(t) {
2006
1729
  if (typeof t != "function")
2007
1730
  throw new TypeError("executor must be a function.");
2008
- let r;
1731
+ let n;
2009
1732
  this.promise = new Promise(function(o) {
2010
- r = o;
1733
+ n = o;
2011
1734
  });
2012
- const n = this;
1735
+ const r = this;
2013
1736
  this.promise.then((s) => {
2014
- if (!n._listeners) return;
2015
- let o = n._listeners.length;
1737
+ if (!r._listeners) return;
1738
+ let o = r._listeners.length;
2016
1739
  for (; o-- > 0; )
2017
- n._listeners[o](s);
2018
- n._listeners = null;
1740
+ r._listeners[o](s);
1741
+ r._listeners = null;
2019
1742
  }), this.promise.then = (s) => {
2020
1743
  let o;
2021
1744
  const i = new Promise((a) => {
2022
- n.subscribe(a), o = a;
1745
+ r.subscribe(a), o = a;
2023
1746
  }).then(s);
2024
1747
  return i.cancel = function() {
2025
- n.unsubscribe(o);
1748
+ r.unsubscribe(o);
2026
1749
  }, i;
2027
1750
  }, t(function(o, i, a) {
2028
- n.reason || (n.reason = new ue(o, i, a), r(n.reason));
1751
+ r.reason || (r.reason = new Q(o, i, a), n(r.reason));
2029
1752
  });
2030
1753
  }
2031
1754
  /**
@@ -2051,14 +1774,14 @@ let _n = class Ft {
2051
1774
  unsubscribe(t) {
2052
1775
  if (!this._listeners)
2053
1776
  return;
2054
- const r = this._listeners.indexOf(t);
2055
- r !== -1 && this._listeners.splice(r, 1);
1777
+ const n = this._listeners.indexOf(t);
1778
+ n !== -1 && this._listeners.splice(n, 1);
2056
1779
  }
2057
1780
  toAbortSignal() {
2058
- const t = new AbortController(), r = (n) => {
2059
- t.abort(n);
1781
+ const t = new AbortController(), n = (r) => {
1782
+ t.abort(r);
2060
1783
  };
2061
- return this.subscribe(r), t.signal.unsubscribe = () => this.unsubscribe(r), t.signal;
1784
+ return this.subscribe(n), t.signal.unsubscribe = () => this.unsubscribe(n), t.signal;
2062
1785
  }
2063
1786
  /**
2064
1787
  * Returns an object that contains a new `CancelToken` and a function that, when called,
@@ -2067,22 +1790,22 @@ let _n = class Ft {
2067
1790
  static source() {
2068
1791
  let t;
2069
1792
  return {
2070
- token: new Ft(function(s) {
1793
+ token: new Ot(function(s) {
2071
1794
  t = s;
2072
1795
  }),
2073
1796
  cancel: t
2074
1797
  };
2075
1798
  }
2076
1799
  };
2077
- function Tn(e) {
2078
- return function(r) {
2079
- return e.apply(null, r);
1800
+ function ur(e) {
1801
+ return function(n) {
1802
+ return e.apply(null, n);
2080
1803
  };
2081
1804
  }
2082
- function On(e) {
1805
+ function fr(e) {
2083
1806
  return c.isObject(e) && e.isAxiosError === !0;
2084
1807
  }
2085
- const Le = {
1808
+ const Re = {
2086
1809
  Continue: 100,
2087
1810
  SwitchingProtocols: 101,
2088
1811
  Processing: 102,
@@ -2153,58 +1876,58 @@ const Le = {
2153
1876
  SslHandshakeFailed: 525,
2154
1877
  InvalidSslCertificate: 526
2155
1878
  };
2156
- Object.entries(Le).forEach(([e, t]) => {
2157
- Le[t] = e;
1879
+ Object.entries(Re).forEach(([e, t]) => {
1880
+ Re[t] = e;
2158
1881
  });
2159
- function Dt(e) {
2160
- const t = new V(e), r = dt(V.prototype.request, t);
2161
- return c.extend(r, V.prototype, t, { allOwnKeys: !0 }), c.extend(r, t, null, { allOwnKeys: !0 }), r.create = function(s) {
2162
- return Dt(W(e, s));
2163
- }, r;
1882
+ function _t(e) {
1883
+ const t = new M(e), n = nt(M.prototype.request, t);
1884
+ return c.extend(n, M.prototype, t, { allOwnKeys: !0 }), c.extend(n, t, null, { allOwnKeys: !0 }), n.create = function(s) {
1885
+ return _t($(e, s));
1886
+ }, n;
2164
1887
  }
2165
- const C = Dt(le);
2166
- C.Axios = V;
2167
- C.CanceledError = ue;
2168
- C.CancelToken = _n;
2169
- C.isCancel = At;
2170
- C.VERSION = jt;
2171
- C.toFormData = Te;
2172
- C.AxiosError = b;
2173
- C.Cancel = C.CanceledError;
2174
- C.all = function(t) {
1888
+ const O = _t(Z);
1889
+ O.Axios = M;
1890
+ O.CanceledError = Q;
1891
+ O.CancelToken = lr;
1892
+ O.isCancel = yt;
1893
+ O.VERSION = Rt;
1894
+ O.toFormData = fe;
1895
+ O.AxiosError = w;
1896
+ O.Cancel = O.CanceledError;
1897
+ O.all = function(t) {
2175
1898
  return Promise.all(t);
2176
1899
  };
2177
- C.spread = Tn;
2178
- C.isAxiosError = On;
2179
- C.mergeConfig = W;
2180
- C.AxiosHeaders = D;
2181
- C.formToJSON = (e) => Ot(c.isHTMLForm(e) ? new FormData(e) : e);
2182
- C.getAdapter = kt.getAdapter;
2183
- C.HttpStatusCode = Le;
2184
- C.default = C;
1900
+ O.spread = ur;
1901
+ O.isAxiosError = fr;
1902
+ O.mergeConfig = $;
1903
+ O.AxiosHeaders = N;
1904
+ O.formToJSON = (e) => mt(c.isHTMLForm(e) ? new FormData(e) : e);
1905
+ O.getAdapter = St.getAdapter;
1906
+ O.HttpStatusCode = Re;
1907
+ O.default = O;
2185
1908
  const {
2186
- Axios: Bn,
2187
- AxiosError: Mn,
2188
- CanceledError: $n,
2189
- isCancel: qn,
2190
- CancelToken: Hn,
2191
- VERSION: zn,
2192
- all: Jn,
2193
- Cancel: Vn,
2194
- isAxiosError: Wn,
2195
- spread: Kn,
2196
- toFormData: Yn,
2197
- AxiosHeaders: Xn,
2198
- HttpStatusCode: Gn,
2199
- formToJSON: Zn,
2200
- getAdapter: Qn,
2201
- mergeConfig: es
2202
- } = C, An = "http://localhost:8000/api";
2203
- class xn {
2204
- constructor(t, r = An) {
2205
- $e(this, "client");
2206
- this.client = C.create({
2207
- baseURL: r,
1909
+ Axios: Tr,
1910
+ AxiosError: Cr,
1911
+ CanceledError: Nr,
1912
+ isCancel: xr,
1913
+ CancelToken: Pr,
1914
+ VERSION: Dr,
1915
+ all: Fr,
1916
+ Cancel: Ur,
1917
+ isAxiosError: Lr,
1918
+ spread: kr,
1919
+ toFormData: Br,
1920
+ AxiosHeaders: Ir,
1921
+ HttpStatusCode: jr,
1922
+ formToJSON: Mr,
1923
+ getAdapter: $r,
1924
+ mergeConfig: qr
1925
+ } = O, dr = "http://localhost:8000/api";
1926
+ class pr {
1927
+ constructor(t, n = dr) {
1928
+ Le(this, "client");
1929
+ this.client = O.create({
1930
+ baseURL: n,
2208
1931
  headers: {
2209
1932
  "Content-Type": "application/json",
2210
1933
  "X-API-Key": t
@@ -2212,30 +1935,30 @@ class xn {
2212
1935
  timeout: 3e4
2213
1936
  // 30 seconds
2214
1937
  }), this.client.interceptors.response.use(
2215
- (n) => n,
2216
- (n) => {
1938
+ (r) => r,
1939
+ (r) => {
2217
1940
  var s, o;
2218
- if ((s = n.response) != null && s.data) {
2219
- const a = ((o = n.response.data.response) == null ? void 0 : o.message) || "An unknown error occurred";
1941
+ if ((s = r.response) != null && s.data) {
1942
+ const a = ((o = r.response.data.response) == null ? void 0 : o.message) || "An unknown error occurred";
2220
1943
  throw new Error(a);
2221
- } else throw n.request ? new Error("No response from server. Please check your connection.") : new Error(n.message || "Request failed");
1944
+ } else throw r.request ? new Error("No response from server. Please check your connection.") : new Error(r.message || "Request failed");
2222
1945
  }
2223
1946
  );
2224
1947
  }
2225
1948
  /**
2226
1949
  * Send a message to the customer support API
2227
1950
  */
2228
- async sendMessage(t, r) {
1951
+ async sendMessage(t, n) {
2229
1952
  try {
2230
- const n = await this.client.post("/chat/", {
1953
+ const r = await this.client.post("/chat/", {
2231
1954
  question: t,
2232
- session_id: r
1955
+ session_id: n
2233
1956
  });
2234
- if (n.data.response.status !== "success")
2235
- throw new Error(n.data.response.message);
2236
- return n.data.data;
2237
- } catch (n) {
2238
- throw n instanceof Error ? n : new Error("Failed to send message");
1957
+ if (r.data.response.status !== "success")
1958
+ throw new Error(r.data.response.message);
1959
+ return r.data.data;
1960
+ } catch (r) {
1961
+ throw r instanceof Error ? r : new Error("Failed to send message");
2239
1962
  }
2240
1963
  }
2241
1964
  /**
@@ -2243,14 +1966,14 @@ class xn {
2243
1966
  */
2244
1967
  async getConversationHistory(t) {
2245
1968
  try {
2246
- const r = await this.client.get(
1969
+ const n = await this.client.get(
2247
1970
  `/chat/history/${t}/`
2248
1971
  );
2249
- if (r.data.response.status !== "success")
2250
- throw new Error(r.data.response.message);
2251
- return r.data.data;
2252
- } catch (r) {
2253
- throw r instanceof Error ? r : new Error("Failed to load conversation history");
1972
+ if (n.data.response.status !== "success")
1973
+ throw new Error(n.data.response.message);
1974
+ return n.data.data;
1975
+ } catch (n) {
1976
+ throw n instanceof Error ? n : new Error("Failed to load conversation history");
2254
1977
  }
2255
1978
  }
2256
1979
  /**
@@ -2266,8 +1989,8 @@ class xn {
2266
1989
  this.client.defaults.baseURL = t;
2267
1990
  }
2268
1991
  }
2269
- function at(e, t) {
2270
- const [r, n] = se(() => {
1992
+ function Ze(e, t) {
1993
+ const [n, r] = K(() => {
2271
1994
  try {
2272
1995
  const o = window.localStorage.getItem(e);
2273
1996
  return o ? JSON.parse(o) : t;
@@ -2275,283 +1998,283 @@ function at(e, t) {
2275
1998
  return console.warn(`Error reading localStorage key "${e}":`, o), t;
2276
1999
  }
2277
2000
  });
2278
- return [r, (o) => {
2001
+ return [n, (o) => {
2279
2002
  try {
2280
- const i = o instanceof Function ? o(r) : o;
2281
- n(i), window.localStorage.setItem(e, JSON.stringify(i));
2003
+ const i = o instanceof Function ? o(n) : o;
2004
+ r(i), window.localStorage.setItem(e, JSON.stringify(i));
2282
2005
  } catch (i) {
2283
2006
  console.warn(`Error setting localStorage key "${e}":`, i);
2284
2007
  }
2285
2008
  }];
2286
2009
  }
2287
- function ct() {
2010
+ function Qe() {
2288
2011
  return `session_${Date.now()}_${Math.random().toString(36).substring(2, 9)}`;
2289
2012
  }
2290
- const Cn = "customer_support_session_id", Nn = "customer_support_messages";
2291
- function Pn(e) {
2292
- const { apiKey: t, baseUrl: r, onError: n } = e, [s, o] = at(Nn, []), [i, a] = at(
2293
- Cn,
2294
- ct()
2295
- ), [p, f] = se(!1), [u, m] = se(null), g = ut(null);
2296
- Ue(() => {
2297
- g.current = new xn(t, r);
2298
- }, [t, r]);
2299
- const O = he(() => {
2300
- m(null);
2301
- }, []), d = he(
2302
- async (S) => {
2303
- if (!g.current) {
2304
- const w = new Error("API client not initialized");
2305
- m(w), n == null || n(w);
2013
+ const hr = "customer_support_session_id", mr = "customer_support_messages";
2014
+ function yr(e) {
2015
+ const { apiKey: t, baseUrl: n, onError: r } = e, [s, o] = Ze(mr, []), [i, a] = Ze(
2016
+ hr,
2017
+ Qe()
2018
+ ), [d, u] = K(!1), [l, p] = K(null), b = et(null);
2019
+ Oe(() => {
2020
+ b.current = new pr(t, n);
2021
+ }, [t, n]);
2022
+ const _ = ne(() => {
2023
+ p(null);
2024
+ }, []), f = ne(
2025
+ async (g) => {
2026
+ if (!b.current) {
2027
+ const y = new Error("API client not initialized");
2028
+ p(y), r == null || r(y);
2306
2029
  return;
2307
2030
  }
2308
- if (!S.trim())
2031
+ if (!g.trim())
2309
2032
  return;
2310
- const x = {
2033
+ const R = {
2311
2034
  id: `user_${Date.now()}`,
2312
2035
  role: "USER",
2313
- content: S,
2036
+ content: g,
2314
2037
  timestamp: /* @__PURE__ */ new Date()
2315
2038
  };
2316
- o((w) => [...w, x]), f(!0), m(null);
2039
+ o((y) => [...y, R]), u(!0), p(null);
2317
2040
  try {
2318
- const w = await g.current.sendMessage(S, i), _ = {
2041
+ const y = await b.current.sendMessage(g, i), E = {
2319
2042
  id: `assistant_${Date.now()}`,
2320
2043
  role: "ASSISTANT",
2321
- content: w.answer,
2044
+ content: y.answer,
2322
2045
  timestamp: /* @__PURE__ */ new Date(),
2323
- sources: w.sources
2046
+ sources: y.sources
2324
2047
  };
2325
- o((P) => [...P, _]), w.session_id !== i && a(w.session_id);
2326
- } catch (w) {
2327
- const _ = w instanceof Error ? w : new Error("Failed to send message");
2328
- m(_), n == null || n(_);
2329
- const P = {
2048
+ o((T) => [...T, E]), y.session_id !== i && a(y.session_id);
2049
+ } catch (y) {
2050
+ const E = y instanceof Error ? y : new Error("Failed to send message");
2051
+ p(E), r == null || r(E);
2052
+ const T = {
2330
2053
  id: `error_${Date.now()}`,
2331
2054
  role: "ASSISTANT",
2332
- content: `Sorry, I encountered an error: ${_.message}`,
2055
+ content: `Sorry, I encountered an error: ${E.message}`,
2333
2056
  timestamp: /* @__PURE__ */ new Date()
2334
2057
  };
2335
- o((U) => [...U, P]);
2058
+ o((L) => [...L, T]);
2336
2059
  } finally {
2337
- f(!1);
2060
+ u(!1);
2338
2061
  }
2339
2062
  },
2340
- [i, n, o, a]
2341
- ), y = he(async () => {
2342
- if (!(!g.current || !i)) {
2343
- f(!0), m(null);
2063
+ [i, r, o, a]
2064
+ ), m = ne(async () => {
2065
+ if (!(!b.current || !i)) {
2066
+ u(!0), p(null);
2344
2067
  try {
2345
- const x = (await g.current.getConversationHistory(i)).messages.map((w, _) => ({
2346
- id: `${w.role.toLowerCase()}_${_}_${Date.now()}`,
2347
- role: w.role,
2348
- content: w.content,
2349
- timestamp: new Date(w.created_at)
2068
+ const R = (await b.current.getConversationHistory(i)).messages.map((y, E) => ({
2069
+ id: `${y.role.toLowerCase()}_${E}_${Date.now()}`,
2070
+ role: y.role,
2071
+ content: y.content,
2072
+ timestamp: new Date(y.created_at)
2350
2073
  }));
2351
- o(x);
2352
- } catch (S) {
2353
- const x = S instanceof Error ? S : new Error("Failed to load history");
2354
- m(x), n == null || n(x);
2074
+ o(R);
2075
+ } catch (g) {
2076
+ const R = g instanceof Error ? g : new Error("Failed to load history");
2077
+ p(R), r == null || r(R);
2355
2078
  } finally {
2356
- f(!1);
2079
+ u(!1);
2357
2080
  }
2358
2081
  }
2359
- }, [i, n, o]), h = he(() => {
2360
- o([]), a(ct());
2082
+ }, [i, r, o]), h = ne(() => {
2083
+ o([]), a(Qe());
2361
2084
  }, [o, a]);
2362
2085
  return {
2363
2086
  messages: s,
2364
- sendMessage: d,
2365
- isLoading: p,
2366
- error: u,
2367
- clearError: O,
2087
+ sendMessage: f,
2088
+ isLoading: d,
2089
+ error: l,
2090
+ clearError: _,
2368
2091
  sessionId: i,
2369
- loadHistory: y,
2092
+ loadHistory: m,
2370
2093
  clearHistory: h
2371
2094
  };
2372
2095
  }
2373
- const kn = ({ message: e }) => {
2374
- const t = e.role === "USER", r = e.timestamp instanceof Date ? e.timestamp : new Date(e.timestamp);
2375
- return /* @__PURE__ */ R.jsxs("div", { className: `cs-message ${t ? "cs-message--user" : "cs-message--assistant"}`, children: [
2376
- /* @__PURE__ */ R.jsxs("div", { className: "cs-message__content", children: [
2377
- /* @__PURE__ */ R.jsx("p", { className: "cs-message__text", children: e.content }),
2378
- e.sources && e.sources.length > 0 && /* @__PURE__ */ R.jsxs("div", { className: "cs-message__sources", children: [
2379
- /* @__PURE__ */ R.jsx("p", { className: "cs-message__sources-title", children: "Sources:" }),
2380
- /* @__PURE__ */ R.jsx("ul", { className: "cs-message__sources-list", children: e.sources.map((n, s) => /* @__PURE__ */ R.jsxs("li", { className: "cs-message__source-item", children: [
2381
- /* @__PURE__ */ R.jsxs(
2096
+ const wr = ({ message: e }) => {
2097
+ const t = e.role === "USER", n = e.timestamp instanceof Date ? e.timestamp : new Date(e.timestamp);
2098
+ return /* @__PURE__ */ x("div", { className: `cs-message ${t ? "cs-message--user" : "cs-message--assistant"}`, children: [
2099
+ /* @__PURE__ */ x("div", { className: "cs-message__content", children: [
2100
+ /* @__PURE__ */ S("p", { className: "cs-message__text", children: e.content }),
2101
+ e.sources && e.sources.length > 0 && /* @__PURE__ */ x("div", { className: "cs-message__sources", children: [
2102
+ /* @__PURE__ */ S("p", { className: "cs-message__sources-title", children: "Sources:" }),
2103
+ /* @__PURE__ */ S("ul", { className: "cs-message__sources-list", children: e.sources.map((r, s) => /* @__PURE__ */ x("li", { className: "cs-message__source-item", children: [
2104
+ /* @__PURE__ */ x(
2382
2105
  "a",
2383
2106
  {
2384
- href: n.url,
2107
+ href: r.url,
2385
2108
  target: "_blank",
2386
2109
  rel: "noopener noreferrer",
2387
2110
  className: "cs-message__source-link",
2388
2111
  children: [
2389
- /* @__PURE__ */ R.jsx(Jt, { size: 12 }),
2390
- /* @__PURE__ */ R.jsx("span", { children: n.title })
2112
+ /* @__PURE__ */ S(Dt, { size: 12 }),
2113
+ /* @__PURE__ */ S("span", { children: r.title })
2391
2114
  ]
2392
2115
  }
2393
2116
  ),
2394
- /* @__PURE__ */ R.jsxs("span", { className: "cs-message__source-similarity", children: [
2395
- Math.round(n.similarity * 100),
2117
+ /* @__PURE__ */ x("span", { className: "cs-message__source-similarity", children: [
2118
+ Math.round(r.similarity * 100),
2396
2119
  "% match"
2397
2120
  ] })
2398
2121
  ] }, s)) })
2399
2122
  ] })
2400
2123
  ] }),
2401
- /* @__PURE__ */ R.jsx("time", { className: "cs-message__time", dateTime: r.toISOString(), children: r.toLocaleTimeString([], { hour: "2-digit", minute: "2-digit" }) })
2124
+ /* @__PURE__ */ S("time", { className: "cs-message__time", dateTime: n.toISOString(), children: n.toLocaleTimeString([], { hour: "2-digit", minute: "2-digit" }) })
2402
2125
  ] });
2403
- }, jn = ({
2126
+ }, br = ({
2404
2127
  onSendMessage: e,
2405
2128
  isLoading: t,
2406
- placeholder: r = "Type your message..."
2129
+ placeholder: n = "Type your message..."
2407
2130
  }) => {
2408
- const [n, s] = se(""), o = (a) => {
2409
- a.preventDefault(), n.trim() && !t && (e(n), s(""));
2410
- }, i = (a) => {
2411
- a.key === "Enter" && !a.shiftKey && (a.preventDefault(), o(a));
2131
+ const [r, s] = K(""), o = (a) => {
2132
+ a.preventDefault(), r.trim() && !t && (e(r), s(""));
2412
2133
  };
2413
- return /* @__PURE__ */ R.jsxs("form", { className: "cs-input", onSubmit: o, children: [
2414
- /* @__PURE__ */ R.jsx(
2134
+ return /* @__PURE__ */ x("form", { className: "cs-input", onSubmit: o, children: [
2135
+ /* @__PURE__ */ S(
2415
2136
  "textarea",
2416
2137
  {
2417
2138
  className: "cs-input__textarea",
2418
- value: n,
2139
+ value: r,
2419
2140
  onChange: (a) => s(a.target.value),
2420
- onKeyDown: i,
2421
- placeholder: r,
2141
+ onKeyDown: (a) => {
2142
+ a.key === "Enter" && !a.shiftKey && (a.preventDefault(), o(a));
2143
+ },
2144
+ placeholder: n,
2422
2145
  disabled: t,
2423
2146
  rows: 1,
2424
2147
  "aria-label": "Message input"
2425
2148
  }
2426
2149
  ),
2427
- /* @__PURE__ */ R.jsx(
2150
+ /* @__PURE__ */ S(
2428
2151
  "button",
2429
2152
  {
2430
2153
  type: "submit",
2431
2154
  className: "cs-input__button",
2432
- disabled: !n.trim() || t,
2155
+ disabled: !r.trim() || t,
2433
2156
  "aria-label": "Send message",
2434
- children: /* @__PURE__ */ R.jsx(Kt, { size: 20 })
2157
+ children: /* @__PURE__ */ S(Lt, { size: 20 })
2435
2158
  }
2436
2159
  )
2437
2160
  ] });
2438
- }, Fn = ({
2161
+ }, gr = ({
2439
2162
  messages: e,
2440
2163
  onSendMessage: t,
2441
- onClose: r,
2442
- isLoading: n,
2164
+ onClose: n,
2165
+ isLoading: r,
2443
2166
  error: s,
2444
2167
  placeholder: o,
2445
2168
  welcomeMessage: i = "Hi! How can I help you today?"
2446
2169
  }) => {
2447
- const a = ut(null);
2448
- return Ue(() => {
2449
- var p;
2450
- (p = a.current) == null || p.scrollIntoView({ behavior: "smooth" });
2451
- }, [e]), /* @__PURE__ */ R.jsxs("div", { className: "cs-window", children: [
2452
- /* @__PURE__ */ R.jsxs("div", { className: "cs-window__header", children: [
2453
- /* @__PURE__ */ R.jsx("h3", { className: "cs-window__title", children: "Customer Support" }),
2454
- /* @__PURE__ */ R.jsx(
2170
+ const a = et(null);
2171
+ return Oe(() => {
2172
+ var d;
2173
+ (d = a.current) == null || d.scrollIntoView({ behavior: "smooth" });
2174
+ }, [e]), /* @__PURE__ */ x("div", { className: "cs-window", children: [
2175
+ /* @__PURE__ */ x("div", { className: "cs-window__header", children: [
2176
+ /* @__PURE__ */ S("h3", { className: "cs-window__title", children: "Customer Support" }),
2177
+ /* @__PURE__ */ S(
2455
2178
  "button",
2456
2179
  {
2457
2180
  className: "cs-window__close",
2458
- onClick: r,
2181
+ onClick: n,
2459
2182
  "aria-label": "Close chat",
2460
- children: /* @__PURE__ */ R.jsx(Yt, { size: 20 })
2183
+ children: /* @__PURE__ */ S(kt, { size: 20 })
2461
2184
  }
2462
2185
  )
2463
2186
  ] }),
2464
- /* @__PURE__ */ R.jsxs("div", { className: "cs-window__messages", children: [
2465
- e.length === 0 && !n && /* @__PURE__ */ R.jsx("div", { className: "cs-window__welcome", children: /* @__PURE__ */ R.jsx("p", { children: i }) }),
2466
- e.map((p) => /* @__PURE__ */ R.jsx(kn, { message: p }, p.id)),
2467
- n && /* @__PURE__ */ R.jsxs("div", { className: "cs-window__typing", children: [
2468
- /* @__PURE__ */ R.jsx(Vt, { size: 20, className: "cs-window__typing-icon" }),
2469
- /* @__PURE__ */ R.jsx("span", { children: "Thinking..." })
2187
+ /* @__PURE__ */ x("div", { className: "cs-window__messages", children: [
2188
+ e.length === 0 && !r && /* @__PURE__ */ S("div", { className: "cs-window__welcome", children: /* @__PURE__ */ S("p", { children: i }) }),
2189
+ e.map((d) => /* @__PURE__ */ S(wr, { message: d }, d.id)),
2190
+ r && /* @__PURE__ */ x("div", { className: "cs-window__typing", children: [
2191
+ /* @__PURE__ */ S(Ft, { size: 20, className: "cs-window__typing-icon" }),
2192
+ /* @__PURE__ */ S("span", { children: "Thinking..." })
2470
2193
  ] }),
2471
- s && /* @__PURE__ */ R.jsx("div", { className: "cs-window__error", children: /* @__PURE__ */ R.jsx("p", { children: s.message }) }),
2472
- /* @__PURE__ */ R.jsx("div", { ref: a })
2194
+ s && /* @__PURE__ */ S("div", { className: "cs-window__error", children: /* @__PURE__ */ S("p", { children: s.message }) }),
2195
+ /* @__PURE__ */ S("div", { ref: a })
2473
2196
  ] }),
2474
- /* @__PURE__ */ R.jsx("div", { className: "cs-window__input-wrapper", children: /* @__PURE__ */ R.jsx(
2475
- jn,
2197
+ /* @__PURE__ */ S("div", { className: "cs-window__input-wrapper", children: /* @__PURE__ */ S(
2198
+ br,
2476
2199
  {
2477
2200
  onSendMessage: t,
2478
- isLoading: n,
2201
+ isLoading: r,
2479
2202
  placeholder: o
2480
2203
  }
2481
2204
  ) })
2482
2205
  ] });
2483
- }, ts = ({
2206
+ }, Hr = ({
2484
2207
  apiKey: e,
2485
2208
  baseUrl: t,
2486
- theme: r,
2487
- position: n = "bottom-right",
2209
+ theme: n,
2210
+ position: r = "bottom-right",
2488
2211
  welcomeMessage: s,
2489
2212
  placeholder: o,
2490
2213
  className: i = "",
2491
2214
  onError: a,
2492
- onMessageSent: p,
2493
- onMessageReceived: f
2215
+ onMessageSent: d,
2216
+ onMessageReceived: u
2494
2217
  }) => {
2495
- const [u, m] = se(!1), {
2496
- messages: g,
2497
- sendMessage: O,
2498
- isLoading: d,
2499
- error: y,
2218
+ const [l, p] = K(!1), {
2219
+ messages: b,
2220
+ sendMessage: _,
2221
+ isLoading: f,
2222
+ error: m,
2500
2223
  clearError: h
2501
- } = Pn({
2224
+ } = yr({
2502
2225
  apiKey: e,
2503
2226
  baseUrl: t,
2504
2227
  onError: a
2505
2228
  });
2506
- Ue(() => {
2507
- if (r) {
2508
- const w = document.documentElement;
2509
- r.primaryColor && w.style.setProperty("--cs-primary-color", r.primaryColor), r.secondaryColor && w.style.setProperty("--cs-secondary-color", r.secondaryColor), r.backgroundColor && w.style.setProperty("--cs-bg-color", r.backgroundColor), r.textColor && w.style.setProperty("--cs-text-color", r.textColor), r.fontFamily && w.style.setProperty("--cs-font-family", r.fontFamily), r.borderRadius && w.style.setProperty("--cs-border-radius", r.borderRadius), r.buttonColor && w.style.setProperty("--cs-button-color", r.buttonColor), r.userMessageColor && w.style.setProperty("--cs-user-message-color", r.userMessageColor), r.assistantMessageColor && w.style.setProperty("--cs-assistant-message-color", r.assistantMessageColor);
2229
+ Oe(() => {
2230
+ if (n) {
2231
+ const y = document.documentElement;
2232
+ n.primaryColor && y.style.setProperty("--cs-primary-color", n.primaryColor), n.secondaryColor && y.style.setProperty("--cs-secondary-color", n.secondaryColor), n.backgroundColor && y.style.setProperty("--cs-bg-color", n.backgroundColor), n.textColor && y.style.setProperty("--cs-text-color", n.textColor), n.fontFamily && y.style.setProperty("--cs-font-family", n.fontFamily), n.borderRadius && y.style.setProperty("--cs-border-radius", n.borderRadius), n.buttonColor && y.style.setProperty("--cs-button-color", n.buttonColor), n.userMessageColor && y.style.setProperty("--cs-user-message-color", n.userMessageColor), n.assistantMessageColor && y.style.setProperty("--cs-assistant-message-color", n.assistantMessageColor);
2510
2233
  }
2511
- }, [r]);
2512
- const S = async (w) => {
2513
- if (p == null || p(w), await O(w), !y) {
2514
- const _ = g[g.length - 1];
2515
- (_ == null ? void 0 : _.role) === "ASSISTANT" && (f == null || f(_.content));
2234
+ }, [n]);
2235
+ const g = async (y) => {
2236
+ if (d == null || d(y), await _(y), !m) {
2237
+ const E = b[b.length - 1];
2238
+ (E == null ? void 0 : E.role) === "ASSISTANT" && (u == null || u(E.content));
2516
2239
  }
2517
- }, x = () => {
2518
- m(!u), y && h();
2240
+ }, R = () => {
2241
+ p(!l), m && h();
2519
2242
  };
2520
- return /* @__PURE__ */ R.jsxs("div", { className: `cs-widget cs-widget--${n} ${i}`, children: [
2521
- u && /* @__PURE__ */ R.jsx(
2522
- Fn,
2243
+ return /* @__PURE__ */ x("div", { className: `cs-widget cs-widget--${r} ${i}`, children: [
2244
+ l && /* @__PURE__ */ S(
2245
+ gr,
2523
2246
  {
2524
- messages: g,
2525
- onSendMessage: S,
2526
- onClose: () => m(!1),
2527
- isLoading: d,
2528
- error: y,
2247
+ messages: b,
2248
+ onSendMessage: g,
2249
+ onClose: () => p(!1),
2250
+ isLoading: f,
2251
+ error: m,
2529
2252
  placeholder: o,
2530
2253
  welcomeMessage: s
2531
2254
  }
2532
2255
  ),
2533
- /* @__PURE__ */ R.jsxs(
2256
+ /* @__PURE__ */ x(
2534
2257
  "button",
2535
2258
  {
2536
- className: `cs-widget__toggle ${u ? "cs-widget__toggle--open" : ""}`,
2537
- onClick: x,
2538
- "aria-label": u ? "Close chat" : "Open chat",
2539
- "aria-expanded": u,
2259
+ className: `cs-widget__toggle ${l ? "cs-widget__toggle--open" : ""}`,
2260
+ onClick: R,
2261
+ "aria-label": l ? "Close chat" : "Open chat",
2262
+ "aria-expanded": l,
2540
2263
  children: [
2541
- /* @__PURE__ */ R.jsx(Wt, { size: 24 }),
2542
- !u && g.length > 0 && /* @__PURE__ */ R.jsx("span", { className: "cs-widget__badge", children: g.filter((w) => w.role === "ASSISTANT").length })
2264
+ /* @__PURE__ */ S(Ut, { size: 24 }),
2265
+ !l && b.length > 0 && /* @__PURE__ */ S("span", { className: "cs-widget__badge", children: b.filter((y) => y.role === "ASSISTANT").length })
2543
2266
  ]
2544
2267
  }
2545
2268
  )
2546
2269
  ] });
2547
2270
  };
2548
2271
  export {
2549
- jn as ChatInput,
2550
- kn as ChatMessage,
2551
- Fn as ChatWindow,
2552
- xn as CustomerSupportAPIClient,
2553
- ts as CustomerSupportWidget,
2554
- Pn as useCustomerSupport,
2555
- at as useLocalStorage
2272
+ br as ChatInput,
2273
+ wr as ChatMessage,
2274
+ gr as ChatWindow,
2275
+ pr as CustomerSupportAPIClient,
2276
+ Hr as CustomerSupportWidget,
2277
+ yr as useCustomerSupport,
2278
+ Ze as useLocalStorage
2556
2279
  };
2557
2280
  //# sourceMappingURL=index.es.js.map