@haus-storefront-react/vendure-plugin-configs 0.0.50 → 0.0.52-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.
Files changed (5) hide show
  1. package/CHANGELOG.md +47 -7
  2. package/badge.js +21 -21
  3. package/badge.mjs +1522 -1439
  4. package/package.json +4 -4
  5. package/README.md +0 -176
package/badge.mjs CHANGED
@@ -1,19 +1,19 @@
1
- import { V as wn, l as Qe } from "./index-CmJlRqDZ.mjs";
2
- import { c as U, j as q, r as Bt } from "./index-BvvwuQM_.mjs";
3
- import * as A from "react";
4
- import Sn, { createContext as It, useContext as vn, useRef as An } from "react";
5
- import { QueryClient as Ut } from "@tanstack/react-query";
6
- const ee = new wn({
1
+ import { V as yn, l as Ge } from "./index-CmJlRqDZ.mjs";
2
+ import { c as U, j as F, r as Mt } from "./index-BvvwuQM_.mjs";
3
+ import * as v from "react";
4
+ import gn, { createContext as bn, useContext as wn, useRef as Sn } from "react";
5
+ import { QueryClient as Re } from "@tanstack/react-query";
6
+ const ee = new yn({
7
7
  name: "badges",
8
8
  enableFeatures: {
9
9
  showBadges: ({
10
10
  badges: t = [],
11
11
  parentComponent: e
12
12
  }) => {
13
- const r = e ? ee.getSettings().availablePositions[e] : ee.getSettings().defaultPositions;
13
+ const n = e ? ee.getSettings().availablePositions[e] : ee.getSettings().defaultPositions;
14
14
  return {
15
- badges: Qe.filter(t, (o) => r ? r.includes(o.position) : !0),
16
- availablePositions: r
15
+ badges: Ge.filter(t, (i) => n ? n.includes(i.position) : !0),
16
+ availablePositions: n
17
17
  };
18
18
  }
19
19
  },
@@ -90,39 +90,39 @@ ee.setRequests({
90
90
  errorCode: t.code || "unknown"
91
91
  }))
92
92
  });
93
- function En(t) {
93
+ function An(t) {
94
94
  const e = [];
95
- function r(o, i) {
96
- const s = A.createContext(i), a = e.length;
95
+ function n(i, o) {
96
+ const s = v.createContext(o), a = e.length;
97
97
  e.push(s);
98
- const c = (l) => {
98
+ const c = (u) => {
99
99
  const f = U.c(8);
100
100
  let h, g, p;
101
- f[0] !== l ? ({
101
+ f[0] !== u ? ({
102
102
  scope: p,
103
103
  children: h,
104
104
  ...g
105
- } = l, f[0] = l, f[1] = h, f[2] = g, f[3] = p) : (h = f[1], g = f[2], p = f[3]);
105
+ } = u, f[0] = u, f[1] = h, f[2] = g, f[3] = p) : (h = f[1], g = f[2], p = f[3]);
106
106
  const y = p?.[t]?.[a] || s, m = g;
107
107
  let w;
108
- return f[4] !== y.Provider || f[5] !== h || f[6] !== m ? (w = /* @__PURE__ */ q.jsx(y.Provider, { value: m, children: h }), f[4] = y.Provider, f[5] = h, f[6] = m, f[7] = w) : w = f[7], w;
108
+ return f[4] !== y.Provider || f[5] !== h || f[6] !== m ? (w = /* @__PURE__ */ F.jsx(y.Provider, { value: m, children: h }), f[4] = y.Provider, f[5] = h, f[6] = m, f[7] = w) : w = f[7], w;
109
109
  };
110
- c.displayName = o + "Provider";
111
- function u(l, f) {
112
- const h = f?.[t]?.[a] || s, g = A.useContext(h);
110
+ c.displayName = i + "Provider";
111
+ function l(u, f) {
112
+ const h = f?.[t]?.[a] || s, g = v.useContext(h);
113
113
  if (g)
114
114
  return g;
115
- if (i !== void 0)
116
- return i;
117
- throw new Error(`\`${l}\` must be used within \`${o}\``);
115
+ if (o !== void 0)
116
+ return o;
117
+ throw new Error(`\`${u}\` must be used within \`${i}\``);
118
118
  }
119
- return [c, u];
119
+ return [c, l];
120
120
  }
121
- function n() {
122
- const o = e.map((i) => A.createContext(i));
121
+ function r() {
122
+ const i = e.map((o) => v.createContext(o));
123
123
  return function(s) {
124
- const a = s?.[t] || o;
125
- return A.useMemo(() => ({
124
+ const a = s?.[t] || i;
125
+ return v.useMemo(() => ({
126
126
  [`__scope${t}`]: {
127
127
  ...s,
128
128
  [t]: a
@@ -130,27 +130,27 @@ function En(t) {
130
130
  }), [s, a]);
131
131
  };
132
132
  }
133
- return n.scopeName = t, [r, n];
133
+ return r.scopeName = t, [n, r];
134
134
  }
135
- function On(t, e) {
135
+ function vn(t, e) {
136
136
  if (e === "web")
137
137
  return t;
138
138
  const {
139
- src: r,
140
- alt: n,
141
- width: o,
142
- height: i,
139
+ src: n,
140
+ alt: r,
141
+ width: i,
142
+ height: o,
143
143
  ...s
144
- } = t, a = [typeof o == "number" ? {
145
- width: o
146
- } : void 0, typeof i == "number" ? {
147
- height: i
144
+ } = t, a = [typeof i == "number" ? {
145
+ width: i
146
+ } : void 0, typeof o == "number" ? {
147
+ height: o
148
148
  } : void 0].filter(Boolean);
149
149
  let c;
150
150
  return a.length === 1 ? c = a[0] : a.length > 1 && (c = a), {
151
151
  ...s,
152
152
  source: {
153
- uri: r
153
+ uri: n
154
154
  },
155
155
  ...c ? {
156
156
  style: c
@@ -158,20 +158,20 @@ function On(t, e) {
158
158
  // alt tas bort, finns inte i RN
159
159
  };
160
160
  }
161
- function Tn(t) {
161
+ function En(t) {
162
162
  const {
163
163
  src: e,
164
- alt: r,
165
- ...n
164
+ alt: n,
165
+ ...r
166
166
  } = t;
167
167
  return e ? {
168
- ...n,
168
+ ...r,
169
169
  source: {
170
170
  uri: e
171
171
  }
172
- } : n;
172
+ } : r;
173
173
  }
174
- const Nn = {
174
+ const On = {
175
175
  div: "View",
176
176
  span: "Text",
177
177
  p: "Text",
@@ -201,208 +201,208 @@ const Nn = {
201
201
  select: "Pressable",
202
202
  option: "Text"
203
203
  };
204
- function Rn(t, e) {
204
+ function Tn(t, e) {
205
205
  if (e === "web")
206
206
  return t;
207
- let r = null;
207
+ let n = null;
208
208
  try {
209
- r = require("react-native");
209
+ n = require("react-native");
210
210
  } catch {
211
- r = null;
211
+ n = null;
212
212
  }
213
- if (!r)
214
- return console.warn(`react-native is not available at runtime; falling back to 'View' for '${t}'`), "div";
215
- const n = Nn[t];
216
213
  if (!n)
217
- return console.warn(`No native component mapping found for '${t}', falling back to View`), r.View;
218
- if (n === "Image") {
219
- const i = Sn.forwardRef((s, a) => {
214
+ return console.warn(`react-native is not available at runtime; falling back to 'View' for '${t}'`), "div";
215
+ const r = On[t];
216
+ if (!r)
217
+ return console.warn(`No native component mapping found for '${t}', falling back to View`), n.View;
218
+ if (r === "Image") {
219
+ const o = gn.forwardRef((s, a) => {
220
220
  const c = U.c(5);
221
221
  if (!s.src)
222
222
  return null;
223
- let u;
224
- c[0] !== s ? (u = Tn(s), c[0] = s, c[1] = u) : u = c[1];
225
223
  let l;
226
- return c[2] !== a || c[3] !== u ? (l = /* @__PURE__ */ q.jsx(r.Image, { ref: a, ...u }), c[2] = a, c[3] = u, c[4] = l) : l = c[4], l;
224
+ c[0] !== s ? (l = En(s), c[0] = s, c[1] = l) : l = c[1];
225
+ let u;
226
+ return c[2] !== a || c[3] !== l ? (u = /* @__PURE__ */ F.jsx(n.Image, { ref: a, ...l }), c[2] = a, c[3] = l, c[4] = u) : u = c[4], u;
227
227
  });
228
- return i.displayName = "PlatformPrimitiveImage", i;
228
+ return o.displayName = "PlatformPrimitiveImage", o;
229
229
  }
230
- const o = r[n];
231
- return o || (console.warn(`Native component '${n}' not found, falling back to View`), r.View);
230
+ const i = n[r];
231
+ return i || (console.warn(`Native component '${r}' not found, falling back to View`), n.View);
232
232
  }
233
233
  const kn = Symbol("radix.slottable");
234
- function _n(...t) {
235
- return (e) => t.forEach((r) => {
236
- typeof r == "function" ? r(e) : r != null && (r.current = e);
234
+ function Rn(...t) {
235
+ return (e) => t.forEach((n) => {
236
+ typeof n == "function" ? n(e) : n != null && (n.current = e);
237
237
  });
238
238
  }
239
- function Pn(t, e) {
240
- const r = {
239
+ function Nn(t, e) {
240
+ const n = {
241
241
  ...e
242
242
  };
243
- for (const n in e) {
244
- const o = t[n], i = e[n];
245
- /^on[A-Z]/.test(n) ? o && i ? r[n] = (...a) => {
246
- const c = i(...a);
247
- return o(...a), c;
248
- } : o && (r[n] = o) : n === "style" ? r[n] = Cn(o, i) : n === "className" && (r[n] = [o, i].filter(Boolean).join(" "));
243
+ for (const r in e) {
244
+ const i = t[r], o = e[r];
245
+ /^on[A-Z]/.test(r) ? i && o ? n[r] = (...a) => {
246
+ const c = o(...a);
247
+ return i(...a), c;
248
+ } : i && (n[r] = i) : r === "style" ? n[r] = xn(i, o) : r === "className" && (n[r] = [i, o].filter(Boolean).join(" "));
249
249
  }
250
250
  return {
251
251
  ...t,
252
- ...r
252
+ ...n
253
253
  };
254
254
  }
255
- function Cn(t, e) {
256
- let r = null;
255
+ function xn(t, e) {
256
+ let n = null;
257
257
  try {
258
- r = require("react-native");
258
+ n = require("react-native");
259
259
  } catch {
260
- r = null;
260
+ n = null;
261
261
  }
262
- const n = r?.StyleSheet?.flatten;
262
+ const r = n?.StyleSheet?.flatten;
263
263
  if (typeof t == "function" && typeof e == "function")
264
- return (i) => {
265
- const s = [t(i), e(i)];
266
- return n ? n(s) : s;
264
+ return (o) => {
265
+ const s = [t(o), e(o)];
266
+ return r ? r(s) : s;
267
267
  };
268
268
  if (typeof t == "function")
269
- return (i) => {
270
- const s = e ? [t(i), e] : t(i);
271
- return n ? n(s) : s;
269
+ return (o) => {
270
+ const s = e ? [t(o), e] : t(o);
271
+ return r ? r(s) : s;
272
272
  };
273
273
  if (typeof e == "function")
274
- return (i) => {
275
- const s = t ? [t, e(i)] : e(i);
276
- return n ? n(s) : s;
274
+ return (o) => {
275
+ const s = t ? [t, e(o)] : e(o);
276
+ return r ? r(s) : s;
277
277
  };
278
- const o = [t, e].filter(Boolean);
279
- return n ? n(o) : o;
278
+ const i = [t, e].filter(Boolean);
279
+ return r ? r(i) : i;
280
280
  }
281
- function xn(t) {
282
- return A.isValidElement(t) && typeof t.type == "function" && "__radixId" in t.type && t.type.__radixId === kn;
281
+ function _n(t) {
282
+ return v.isValidElement(t) && typeof t.type == "function" && "__radixId" in t.type && t.type.__radixId === kn;
283
283
  }
284
- function Dn(t) {
285
- let e = Object.getOwnPropertyDescriptor(t.props, "ref")?.get, r = e && "isReactWarning" in e && e.isReactWarning;
286
- return r ? t.ref : (e = Object.getOwnPropertyDescriptor(t, "ref")?.get, r = e && "isReactWarning" in e && e.isReactWarning, r ? t.props.ref : t.props.ref || t.ref);
284
+ function Cn(t) {
285
+ let e = Object.getOwnPropertyDescriptor(t.props, "ref")?.get, n = e && "isReactWarning" in e && e.isReactWarning;
286
+ return n ? t.ref : (e = Object.getOwnPropertyDescriptor(t, "ref")?.get, n = e && "isReactWarning" in e && e.isReactWarning, n ? t.props.ref : t.props.ref || t.ref);
287
287
  }
288
- function Fn(t, e) {
289
- const r = A.forwardRef((n, o) => {
288
+ function Pn(t, e) {
289
+ const n = v.forwardRef((r, i) => {
290
290
  const {
291
- children: i,
291
+ children: o,
292
292
  ...s
293
- } = n;
294
- if (A.isValidElement(i)) {
295
- const a = Dn(i), c = Pn(s, i.props);
296
- return i.type !== A.Fragment && (c.ref = o ? _n(o, a) : a), A.cloneElement(i, c);
293
+ } = r;
294
+ if (v.isValidElement(o)) {
295
+ const a = Cn(o), c = Nn(s, o.props);
296
+ return o.type !== v.Fragment && (c.ref = i ? Rn(i, a) : a), v.cloneElement(o, c);
297
297
  }
298
- return A.Children.count(i) > 1 ? A.Children.only(null) : null;
298
+ return v.Children.count(o) > 1 ? v.Children.only(null) : null;
299
299
  });
300
- return r.displayName = `${t}.SlotClone`, r;
300
+ return n.displayName = `${t}.SlotClone`, n;
301
301
  }
302
- function Re(t, e = !1, r = "div") {
302
+ function Ne(t, e = !1, n = "div") {
303
303
  if (!e)
304
- return Rn(r, t);
305
- const n = Fn("Slot"), o = A.forwardRef((i, s) => {
304
+ return Tn(n, t);
305
+ const r = Pn("Slot"), i = v.forwardRef((o, s) => {
306
306
  const a = U.c(15);
307
- let c, u;
308
- a[0] !== i ? ({
307
+ let c, l;
308
+ a[0] !== o ? ({
309
309
  children: c,
310
- ...u
311
- } = i, a[0] = i, a[1] = c, a[2] = u) : (c = a[1], u = a[2]);
312
- let l;
313
- if (a[3] !== c || a[4] !== s || a[5] !== u) {
314
- l = Symbol.for("react.early_return_sentinel");
310
+ ...l
311
+ } = o, a[0] = o, a[1] = c, a[2] = l) : (c = a[1], l = a[2]);
312
+ let u;
313
+ if (a[3] !== c || a[4] !== s || a[5] !== l) {
314
+ u = Symbol.for("react.early_return_sentinel");
315
315
  e: {
316
- const h = A.Children.toArray(c), g = h.find(xn);
316
+ const h = v.Children.toArray(c), g = h.find(_n);
317
317
  if (g) {
318
- const p = g.props.children, y = h.map((O) => O === g ? A.Children.count(p) > 1 ? A.Children.only(null) : A.isValidElement(p) ? p.props.children : null : O), m = A.isValidElement(p) ? A.cloneElement(p, void 0, y) : null;
318
+ const p = g.props.children, y = h.map((O) => O === g ? v.Children.count(p) > 1 ? v.Children.only(null) : v.isValidElement(p) ? p.props.children : null : O), m = v.isValidElement(p) ? v.cloneElement(p, void 0, y) : null;
319
319
  let w;
320
- a[7] !== s || a[8] !== u || a[9] !== m ? (w = /* @__PURE__ */ q.jsx(n, { ...u, ref: s, children: m }), a[7] = s, a[8] = u, a[9] = m, a[10] = w) : w = a[10], l = w;
320
+ a[7] !== s || a[8] !== l || a[9] !== m ? (w = /* @__PURE__ */ F.jsx(r, { ...l, ref: s, children: m }), a[7] = s, a[8] = l, a[9] = m, a[10] = w) : w = a[10], u = w;
321
321
  break e;
322
322
  }
323
323
  }
324
- a[3] = c, a[4] = s, a[5] = u, a[6] = l;
324
+ a[3] = c, a[4] = s, a[5] = l, a[6] = u;
325
325
  } else
326
- l = a[6];
327
- if (l !== Symbol.for("react.early_return_sentinel"))
328
- return l;
326
+ u = a[6];
327
+ if (u !== Symbol.for("react.early_return_sentinel"))
328
+ return u;
329
329
  let f;
330
- return a[11] !== c || a[12] !== s || a[13] !== u ? (f = /* @__PURE__ */ q.jsx(n, { ...u, ref: s, children: c }), a[11] = c, a[12] = s, a[13] = u, a[14] = f) : f = a[14], f;
330
+ return a[11] !== c || a[12] !== s || a[13] !== l ? (f = /* @__PURE__ */ F.jsx(r, { ...l, ref: s, children: c }), a[11] = c, a[12] = s, a[13] = l, a[14] = f) : f = a[14], f;
331
331
  });
332
- return o.displayName = "Slot", o;
332
+ return i.displayName = "Slot", i;
333
333
  }
334
- const qn = "debug", P = () => {
334
+ const Dn = "debug", _ = () => {
335
335
  try {
336
336
  if (typeof window > "u" || typeof localStorage > "u")
337
337
  return !1;
338
- const t = localStorage.getItem(qn);
338
+ const t = localStorage.getItem(Dn);
339
339
  return t === "true" || t === "1";
340
340
  } catch {
341
341
  return !1;
342
342
  }
343
- }, jn = () => {
344
- const t = (e, r, n = []) => r ? typeof e == "string" ? [`<${r}> ${e}`, ...n] : [`<${r}>`, e, ...n] : Array.isArray(e) ? [...e, ...n] : [e, ...n];
343
+ }, qn = () => {
344
+ const t = (e, n, r = []) => n ? typeof e == "string" ? [`<${n}> ${e}`, ...r] : [`<${n}>`, e, ...r] : Array.isArray(e) ? [...e, ...r] : [e, ...r];
345
345
  return {
346
- log: (e, r, ...n) => {
347
- P() && console.log(...t(e, r, n));
346
+ log: (e, n, ...r) => {
347
+ _() && console.log(...t(e, n, r));
348
348
  },
349
- info: (e, r, ...n) => {
350
- P() && console.info(...t(e, r, n));
349
+ info: (e, n, ...r) => {
350
+ _() && console.info(...t(e, n, r));
351
351
  },
352
- warn: (e, r, ...n) => {
353
- P() && console.warn(...t(e, r, n));
352
+ warn: (e, n, ...r) => {
353
+ _() && console.warn(...t(e, n, r));
354
354
  },
355
- error: (e, r, ...n) => {
356
- P() && console.error(...t(e, r, n));
355
+ error: (e, n, ...r) => {
356
+ _() && console.error(...t(e, n, r));
357
357
  },
358
- debug: (e, r, ...n) => {
359
- P() && console.debug(...t(e, r, n));
358
+ debug: (e, n, ...r) => {
359
+ _() && console.debug(...t(e, n, r));
360
360
  },
361
- group: (e, r) => {
362
- if (P()) {
363
- const n = typeof e == "string" ? e : void 0;
364
- console.group(r ? n ? `<${r}> ${n}` : `<${r}>` : n);
361
+ group: (e, n) => {
362
+ if (_()) {
363
+ const r = typeof e == "string" ? e : void 0;
364
+ console.group(n ? r ? `<${n}> ${r}` : `<${n}>` : r);
365
365
  }
366
366
  },
367
- groupCollapsed: (e, r) => {
368
- if (P()) {
369
- const n = typeof e == "string" ? e : void 0;
370
- console.groupCollapsed(r ? n ? `<${r}> ${n}` : `<${r}>` : n);
367
+ groupCollapsed: (e, n) => {
368
+ if (_()) {
369
+ const r = typeof e == "string" ? e : void 0;
370
+ console.groupCollapsed(n ? r ? `<${n}> ${r}` : `<${n}>` : r);
371
371
  }
372
372
  },
373
373
  groupEnd: () => {
374
- P() && console.groupEnd();
374
+ _() && console.groupEnd();
375
375
  },
376
- table: (e, r, n) => {
377
- P() && (r && console.log(`<${r}>`), console.table(e, n));
376
+ table: (e, n, r) => {
377
+ _() && (n && console.log(`<${n}>`), console.table(e, r));
378
378
  },
379
- time: (e, r) => {
380
- if (P()) {
381
- const n = typeof e == "string" ? e : void 0;
382
- console.time(r ? n ? `<${r}> ${n}` : `<${r}>` : n);
379
+ time: (e, n) => {
380
+ if (_()) {
381
+ const r = typeof e == "string" ? e : void 0;
382
+ console.time(n ? r ? `<${n}> ${r}` : `<${n}>` : r);
383
383
  }
384
384
  },
385
- timeEnd: (e, r) => {
386
- if (P()) {
387
- const n = typeof e == "string" ? e : void 0;
388
- console.timeEnd(r ? n ? `<${r}> ${n}` : `<${r}>` : n);
385
+ timeEnd: (e, n) => {
386
+ if (_()) {
387
+ const r = typeof e == "string" ? e : void 0;
388
+ console.timeEnd(n ? r ? `<${n}> ${r}` : `<${n}>` : r);
389
389
  }
390
390
  }
391
391
  };
392
- }, $t = jn();
392
+ }, Fn = qn();
393
393
  function Mn(t) {
394
- return { all: t = t || /* @__PURE__ */ new Map(), on: function(e, r) {
395
- var n = t.get(e);
396
- n ? n.push(r) : t.set(e, [r]);
397
- }, off: function(e, r) {
398
- var n = t.get(e);
399
- n && (r ? n.splice(n.indexOf(r) >>> 0, 1) : t.set(e, []));
400
- }, emit: function(e, r) {
401
- var n = t.get(e);
402
- n && n.slice().map(function(o) {
403
- o(r);
404
- }), (n = t.get("*")) && n.slice().map(function(o) {
405
- o(e, r);
394
+ return { all: t = t || /* @__PURE__ */ new Map(), on: function(e, n) {
395
+ var r = t.get(e);
396
+ r ? r.push(n) : t.set(e, [n]);
397
+ }, off: function(e, n) {
398
+ var r = t.get(e);
399
+ r && (n ? r.splice(r.indexOf(n) >>> 0, 1) : t.set(e, []));
400
+ }, emit: function(e, n) {
401
+ var r = t.get(e);
402
+ r && r.slice().map(function(i) {
403
+ i(n);
404
+ }), (r = t.get("*")) && r.slice().map(function(i) {
405
+ i(e, n);
406
406
  });
407
407
  } };
408
408
  }
@@ -412,69 +412,69 @@ try {
412
412
  } catch {
413
413
  Z = null;
414
414
  }
415
- let Ve = null;
415
+ let We = null;
416
416
  try {
417
417
  const {
418
418
  AsyncLocalStorage: t
419
419
  } = require("node:async_hooks");
420
- Ve = new t();
420
+ We = new t();
421
421
  } catch {
422
- Ve = null;
422
+ We = null;
423
423
  }
424
- const Q = typeof window < "u" && typeof window.localStorage < "u", K = !!Z, ye = {}, Be = {
424
+ const K = typeof window < "u" && typeof window.localStorage < "u", J = !!Z, ye = {}, Ue = {
425
425
  getItem: async () => null,
426
426
  setItem: async () => {
427
427
  },
428
428
  removeItem: async () => {
429
429
  }
430
- }, Ie = () => {
430
+ }, $e = () => {
431
431
  try {
432
- return Ve?.getStore?.() ?? null;
432
+ return We?.getStore?.() ?? null;
433
433
  } catch {
434
434
  return null;
435
435
  }
436
- }, B = {
436
+ }, I = {
437
437
  getItem: async (t) => {
438
- const e = !Q && !K ? Ie() : null;
439
- return e ? e.getItem(t) : K ? Z.getItem(t) : Q ? new Promise((r) => {
438
+ const e = !K && !J ? $e() : null;
439
+ return e ? e.getItem(t) : J ? Z.getItem(t) : K ? new Promise((n) => {
440
440
  Promise.resolve().then(() => {
441
- const n = window.localStorage.getItem(t), o = ye[t];
442
- n !== o && (ye[t] = n || ""), r(n);
441
+ const r = window.localStorage.getItem(t), i = ye[t];
442
+ r !== i && (ye[t] = r || ""), n(r);
443
443
  });
444
- }) : Be.getItem(t);
444
+ }) : Ue.getItem(t);
445
445
  },
446
446
  setItem: async (t, e) => {
447
- const r = !Q && !K ? Ie() : null;
448
- return r ? r.setItem(t, e) : K ? Z.setItem(t, e) : Q ? new Promise((n, o) => {
447
+ const n = !K && !J ? $e() : null;
448
+ return n ? n.setItem(t, e) : J ? Z.setItem(t, e) : K ? new Promise((r, i) => {
449
449
  Promise.resolve().then(() => {
450
450
  try {
451
451
  window.localStorage.setItem(t, e);
452
- const i = window.localStorage.getItem(t);
453
- i === e ? (ye[t] = e, n()) : o(new Error(`Failed to set localStorage item: expected "${e}", got "${i}"`));
454
- } catch (i) {
455
- o(i);
452
+ const o = window.localStorage.getItem(t);
453
+ o === e ? (ye[t] = e, r()) : i(new Error(`Failed to set localStorage item: expected "${e}", got "${o}"`));
454
+ } catch (o) {
455
+ i(o);
456
456
  }
457
457
  });
458
- }) : Be.setItem(t, e);
458
+ }) : Ue.setItem(t, e);
459
459
  },
460
460
  removeItem: async (t) => {
461
- const e = !Q && !K ? Ie() : null;
462
- return e ? e.removeItem(t) : K ? Z.removeItem(t) : Q ? new Promise((r, n) => {
461
+ const e = !K && !J ? $e() : null;
462
+ return e ? e.removeItem(t) : J ? Z.removeItem(t) : K ? new Promise((n, r) => {
463
463
  Promise.resolve().then(() => {
464
464
  try {
465
465
  window.localStorage.removeItem(t);
466
- const o = window.localStorage.getItem(t);
467
- o === null ? (delete ye[t], r()) : n(new Error(`Failed to remove localStorage item: key "${t}" still exists with value "${o}"`));
468
- } catch (o) {
469
- n(o);
466
+ const i = window.localStorage.getItem(t);
467
+ i === null ? (delete ye[t], n()) : r(new Error(`Failed to remove localStorage item: key "${t}" still exists with value "${i}"`));
468
+ } catch (i) {
469
+ r(i);
470
470
  }
471
471
  });
472
- }) : Be.removeItem(t);
472
+ }) : Ue.removeItem(t);
473
473
  }
474
- }, it = 50, I = {
474
+ }, at = 50, B = {
475
475
  get: async () => {
476
476
  try {
477
- const t = await B.getItem("eventHistory");
477
+ const t = await I.getItem("eventHistory");
478
478
  return t ? JSON.parse(t) : [];
479
479
  } catch (t) {
480
480
  return console.error("Error getting event history", t), [];
@@ -482,45 +482,45 @@ const Q = typeof window < "u" && typeof window.localStorage < "u", K = !!Z, ye =
482
482
  },
483
483
  set: async (t) => {
484
484
  try {
485
- await B.setItem("eventHistory", JSON.stringify(t.slice(-it)));
485
+ await I.setItem("eventHistory", JSON.stringify(t.slice(-at)));
486
486
  } catch (e) {
487
487
  console.error("Error setting event history", e);
488
488
  }
489
489
  },
490
490
  clear: async () => {
491
491
  try {
492
- await B.removeItem("eventHistory");
492
+ await I.removeItem("eventHistory");
493
493
  } catch (t) {
494
494
  console.error("Error clearing event history", t);
495
495
  }
496
496
  },
497
497
  push: async (t) => {
498
- const e = await I.get();
499
- await I.set([{
498
+ const e = await B.get();
499
+ await B.set([{
500
500
  ...t,
501
501
  timestamp: Date.now()
502
- }, ...e].slice(-it));
502
+ }, ...e].slice(-at));
503
503
  },
504
- find: async (t) => (await I.get()).find((r) => r.key === t.key && r.identifier === t.identifier),
504
+ find: async (t) => (await B.get()).find((n) => n.key === t.key && n.identifier === t.identifier),
505
505
  filter: async (t, e) => {
506
- const r = await I.get();
507
- return e ? r.filter(e) : r.filter(({
508
- key: n,
509
- identifier: o
510
- }) => (!n || t.key === n) && (!o || t.identifier === o));
506
+ const n = await B.get();
507
+ return e ? n.filter(e) : n.filter(({
508
+ key: r,
509
+ identifier: i
510
+ }) => (!r || t.key === r) && (!i || t.identifier === i));
511
511
  }
512
512
  };
513
- function Bn() {
513
+ function jn() {
514
514
  const t = globalThis;
515
515
  return t.__HAUS_EVENT_EMITTER__ ||= Mn(), t.__HAUS_EVENT_EMITTER__;
516
516
  }
517
- function z(t) {
518
- const e = Bn(), r = (...c) => console.error(...c);
519
- I.get().then((c) => {
520
- const l = Qe.first(c)?.timestamp;
521
- l && l < Date.now() - 1e3 * 60 * 60 && ($t.info("Clearing event history since it is older than 1 hour:", "eventBus", l), I.clear());
517
+ function Q(t) {
518
+ const e = jn(), n = (...c) => console.error(...c);
519
+ B.get().then((c) => {
520
+ const u = Ge.first(c)?.timestamp;
521
+ u && u < Date.now() - 1e3 * 60 * 60 && (Fn.info("Clearing event history since it is older than 1 hour:", "eventBus", u), B.clear());
522
522
  });
523
- const n = (c, u, l) => {
523
+ const r = (c, l, u) => {
524
524
  const f = (h) => {
525
525
  try {
526
526
  if (typeof h == "object" && h !== null) {
@@ -528,31 +528,31 @@ function z(t) {
528
528
  identifier: g,
529
529
  data: p
530
530
  } = h;
531
- (!g || g === l) && u(p);
531
+ (!g || g === u) && l(p);
532
532
  } else
533
- u(h);
533
+ l(h);
534
534
  } catch (g) {
535
- r(g);
535
+ n(g);
536
536
  }
537
537
  };
538
538
  return e.on(c, f), () => {
539
- o(c, u, l);
539
+ i(c, l, u);
540
540
  };
541
- }, o = (c, u, l) => {
541
+ }, i = (c, l, u) => {
542
542
  const f = (h) => {
543
543
  if (typeof h == "object" && h !== null) {
544
544
  const {
545
545
  identifier: g
546
546
  } = h;
547
- (!g || g === l) && e.off(c, u);
547
+ (!g || g === u) && e.off(c, l);
548
548
  }
549
549
  };
550
550
  e.off(c, f);
551
551
  };
552
552
  return {
553
- on: n,
554
- off: o,
555
- once: (c, u, l) => {
553
+ on: r,
554
+ off: i,
555
+ once: (c, l, u) => {
556
556
  const f = (h) => {
557
557
  try {
558
558
  if (typeof h == "object" && h !== null) {
@@ -560,63 +560,63 @@ function z(t) {
560
560
  identifier: g,
561
561
  data: p
562
562
  } = h;
563
- (!g || g === l) && u(p);
563
+ (!g || g === u) && l(p);
564
564
  } else
565
- u(h);
565
+ l(h);
566
566
  } finally {
567
- o(c, f, l);
567
+ i(c, f, u);
568
568
  }
569
569
  };
570
570
  e.on(c, f);
571
571
  },
572
- emit: (c, u, ...l) => {
572
+ emit: (c, l, ...u) => {
573
573
  const f = {
574
- identifier: u,
575
- data: l.length === 1 ? l[0] : l
574
+ identifier: l,
575
+ data: u.length === 1 ? u[0] : u
576
576
  };
577
- I.push({
577
+ B.push({
578
578
  key: c,
579
- identifier: u,
579
+ identifier: l,
580
580
  payload: f.data
581
581
  }), e.emit(c, f);
582
582
  },
583
- getEventHistory: (c, u) => I.filter({
583
+ getEventHistory: (c, l) => B.filter({
584
584
  key: c,
585
- identifier: u
585
+ identifier: l
586
586
  })
587
587
  };
588
588
  }
589
- z();
590
- z();
591
- z();
592
- z();
593
- z();
594
- z();
595
- z();
596
- new Ut();
597
- function Lt(t, e) {
589
+ Q();
590
+ Q();
591
+ Q();
592
+ Q();
593
+ Q();
594
+ Q();
595
+ Q();
596
+ new Re();
597
+ function jt(t, e) {
598
598
  return function() {
599
599
  return t.apply(e, arguments);
600
600
  };
601
601
  }
602
- const { toString: In } = Object.prototype, { getPrototypeOf: Ke } = Object, { iterator: ke, toStringTag: Vt } = Symbol, _e = /* @__PURE__ */ ((t) => (e) => {
603
- const r = In.call(e);
604
- return t[r] || (t[r] = r.slice(8, -1).toLowerCase());
605
- })(/* @__PURE__ */ Object.create(null)), x = (t) => (t = t.toLowerCase(), (e) => _e(e) === t), Pe = (t) => (e) => typeof e === t, { isArray: ne } = Array, te = Pe("undefined");
602
+ const { toString: In } = Object.prototype, { getPrototypeOf: Xe } = Object, { iterator: xe, toStringTag: It } = Symbol, _e = /* @__PURE__ */ ((t) => (e) => {
603
+ const n = In.call(e);
604
+ return t[n] || (t[n] = n.slice(8, -1).toLowerCase());
605
+ })(/* @__PURE__ */ Object.create(null)), P = (t) => (t = t.toLowerCase(), (e) => _e(e) === t), Ce = (t) => (e) => typeof e === t, { isArray: ne } = Array, te = Ce("undefined");
606
606
  function ae(t) {
607
- return t !== null && !te(t) && t.constructor !== null && !te(t.constructor) && N(t.constructor.isBuffer) && t.constructor.isBuffer(t);
607
+ return t !== null && !te(t) && t.constructor !== null && !te(t.constructor) && k(t.constructor.isBuffer) && t.constructor.isBuffer(t);
608
608
  }
609
- const Ht = x("ArrayBuffer");
610
- function Un(t) {
609
+ const Bt = P("ArrayBuffer");
610
+ function Bn(t) {
611
611
  let e;
612
- return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? e = ArrayBuffer.isView(t) : e = t && t.buffer && Ht(t.buffer), e;
612
+ return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? e = ArrayBuffer.isView(t) : e = t && t.buffer && Bt(t.buffer), e;
613
613
  }
614
- const $n = Pe("string"), N = Pe("function"), Wt = Pe("number"), ce = (t) => t !== null && typeof t == "object", Ln = (t) => t === !0 || t === !1, Ee = (t) => {
614
+ const Un = Ce("string"), k = Ce("function"), Ut = Ce("number"), ce = (t) => t !== null && typeof t == "object", $n = (t) => t === !0 || t === !1, Ee = (t) => {
615
615
  if (_e(t) !== "object")
616
616
  return !1;
617
- const e = Ke(t);
618
- return (e === null || e === Object.prototype || Object.getPrototypeOf(e) === null) && !(Vt in t) && !(ke in t);
619
- }, Vn = (t) => {
617
+ const e = Xe(t);
618
+ return (e === null || e === Object.prototype || Object.getPrototypeOf(e) === null) && !(It in t) && !(xe in t);
619
+ }, Ln = (t) => {
620
620
  if (!ce(t) || ae(t))
621
621
  return !1;
622
622
  try {
@@ -624,216 +624,216 @@ const $n = Pe("string"), N = Pe("function"), Wt = Pe("number"), ce = (t) => t !=
624
624
  } catch {
625
625
  return !1;
626
626
  }
627
- }, Hn = x("Date"), Wn = x("File"), zn = x("Blob"), Jn = x("FileList"), Qn = (t) => ce(t) && N(t.pipe), Kn = (t) => {
627
+ }, Vn = P("Date"), Hn = P("File"), Wn = P("Blob"), Qn = P("FileList"), zn = (t) => ce(t) && k(t.pipe), Kn = (t) => {
628
628
  let e;
629
- return t && (typeof FormData == "function" && t instanceof FormData || N(t.append) && ((e = _e(t)) === "formdata" || // detect form-data instance
630
- e === "object" && N(t.toString) && t.toString() === "[object FormData]"));
631
- }, Xn = x("URLSearchParams"), [Gn, Yn, Zn, er] = ["ReadableStream", "Request", "Response", "Headers"].map(x), tr = (t) => t.trim ? t.trim() : t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
632
- function ue(t, e, { allOwnKeys: r = !1 } = {}) {
629
+ return t && (typeof FormData == "function" && t instanceof FormData || k(t.append) && ((e = _e(t)) === "formdata" || // detect form-data instance
630
+ e === "object" && k(t.toString) && t.toString() === "[object FormData]"));
631
+ }, Jn = P("URLSearchParams"), [Gn, Xn, Yn, Zn] = ["ReadableStream", "Request", "Response", "Headers"].map(P), er = (t) => t.trim ? t.trim() : t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
632
+ function le(t, e, { allOwnKeys: n = !1 } = {}) {
633
633
  if (t === null || typeof t > "u")
634
634
  return;
635
- let n, o;
635
+ let r, i;
636
636
  if (typeof t != "object" && (t = [t]), ne(t))
637
- for (n = 0, o = t.length; n < o; n++)
638
- e.call(null, t[n], n, t);
637
+ for (r = 0, i = t.length; r < i; r++)
638
+ e.call(null, t[r], r, t);
639
639
  else {
640
640
  if (ae(t))
641
641
  return;
642
- const i = r ? Object.getOwnPropertyNames(t) : Object.keys(t), s = i.length;
642
+ const o = n ? Object.getOwnPropertyNames(t) : Object.keys(t), s = o.length;
643
643
  let a;
644
- for (n = 0; n < s; n++)
645
- a = i[n], e.call(null, t[a], a, t);
644
+ for (r = 0; r < s; r++)
645
+ a = o[r], e.call(null, t[a], a, t);
646
646
  }
647
647
  }
648
- function zt(t, e) {
648
+ function $t(t, e) {
649
649
  if (ae(t))
650
650
  return null;
651
651
  e = e.toLowerCase();
652
- const r = Object.keys(t);
653
- let n = r.length, o;
654
- for (; n-- > 0; )
655
- if (o = r[n], e === o.toLowerCase())
656
- return o;
652
+ const n = Object.keys(t);
653
+ let r = n.length, i;
654
+ for (; r-- > 0; )
655
+ if (i = n[r], e === i.toLowerCase())
656
+ return i;
657
657
  return null;
658
658
  }
659
- const V = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : global, Jt = (t) => !te(t) && t !== V;
660
- function He() {
661
- const { caseless: t, skipUndefined: e } = Jt(this) && this || {}, r = {}, n = (o, i) => {
662
- const s = t && zt(r, i) || i;
663
- Ee(r[s]) && Ee(o) ? r[s] = He(r[s], o) : Ee(o) ? r[s] = He({}, o) : ne(o) ? r[s] = o.slice() : (!e || !te(o)) && (r[s] = o);
659
+ const V = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : global, Lt = (t) => !te(t) && t !== V;
660
+ function Qe() {
661
+ const { caseless: t, skipUndefined: e } = Lt(this) && this || {}, n = {}, r = (i, o) => {
662
+ const s = t && $t(n, o) || o;
663
+ Ee(n[s]) && Ee(i) ? n[s] = Qe(n[s], i) : Ee(i) ? n[s] = Qe({}, i) : ne(i) ? n[s] = i.slice() : (!e || !te(i)) && (n[s] = i);
664
664
  };
665
- for (let o = 0, i = arguments.length; o < i; o++)
666
- arguments[o] && ue(arguments[o], n);
667
- return r;
665
+ for (let i = 0, o = arguments.length; i < o; i++)
666
+ arguments[i] && le(arguments[i], r);
667
+ return n;
668
668
  }
669
- const nr = (t, e, r, { allOwnKeys: n } = {}) => (ue(e, (o, i) => {
670
- r && N(o) ? t[i] = Lt(o, r) : t[i] = o;
671
- }, { allOwnKeys: n }), t), rr = (t) => (t.charCodeAt(0) === 65279 && (t = t.slice(1)), t), or = (t, e, r, n) => {
672
- t.prototype = Object.create(e.prototype, n), t.prototype.constructor = t, Object.defineProperty(t, "super", {
669
+ const tr = (t, e, n, { allOwnKeys: r } = {}) => (le(e, (i, o) => {
670
+ n && k(i) ? t[o] = jt(i, n) : t[o] = i;
671
+ }, { allOwnKeys: r }), t), nr = (t) => (t.charCodeAt(0) === 65279 && (t = t.slice(1)), t), rr = (t, e, n, r) => {
672
+ t.prototype = Object.create(e.prototype, r), t.prototype.constructor = t, Object.defineProperty(t, "super", {
673
673
  value: e.prototype
674
- }), r && Object.assign(t.prototype, r);
675
- }, ir = (t, e, r, n) => {
676
- let o, i, s;
674
+ }), n && Object.assign(t.prototype, n);
675
+ }, ir = (t, e, n, r) => {
676
+ let i, o, s;
677
677
  const a = {};
678
678
  if (e = e || {}, t == null) return e;
679
679
  do {
680
- for (o = Object.getOwnPropertyNames(t), i = o.length; i-- > 0; )
681
- s = o[i], (!n || n(s, t, e)) && !a[s] && (e[s] = t[s], a[s] = !0);
682
- t = r !== !1 && Ke(t);
683
- } while (t && (!r || r(t, e)) && t !== Object.prototype);
680
+ for (i = Object.getOwnPropertyNames(t), o = i.length; o-- > 0; )
681
+ s = i[o], (!r || r(s, t, e)) && !a[s] && (e[s] = t[s], a[s] = !0);
682
+ t = n !== !1 && Xe(t);
683
+ } while (t && (!n || n(t, e)) && t !== Object.prototype);
684
684
  return e;
685
- }, sr = (t, e, r) => {
686
- t = String(t), (r === void 0 || r > t.length) && (r = t.length), r -= e.length;
687
- const n = t.indexOf(e, r);
688
- return n !== -1 && n === r;
689
- }, ar = (t) => {
685
+ }, or = (t, e, n) => {
686
+ t = String(t), (n === void 0 || n > t.length) && (n = t.length), n -= e.length;
687
+ const r = t.indexOf(e, n);
688
+ return r !== -1 && r === n;
689
+ }, sr = (t) => {
690
690
  if (!t) return null;
691
691
  if (ne(t)) return t;
692
692
  let e = t.length;
693
- if (!Wt(e)) return null;
694
- const r = new Array(e);
693
+ if (!Ut(e)) return null;
694
+ const n = new Array(e);
695
695
  for (; e-- > 0; )
696
- r[e] = t[e];
697
- return r;
698
- }, cr = /* @__PURE__ */ ((t) => (e) => t && e instanceof t)(typeof Uint8Array < "u" && Ke(Uint8Array)), ur = (t, e) => {
699
- const n = (t && t[ke]).call(t);
700
- let o;
701
- for (; (o = n.next()) && !o.done; ) {
702
- const i = o.value;
703
- e.call(t, i[0], i[1]);
696
+ n[e] = t[e];
697
+ return n;
698
+ }, ar = /* @__PURE__ */ ((t) => (e) => t && e instanceof t)(typeof Uint8Array < "u" && Xe(Uint8Array)), cr = (t, e) => {
699
+ const r = (t && t[xe]).call(t);
700
+ let i;
701
+ for (; (i = r.next()) && !i.done; ) {
702
+ const o = i.value;
703
+ e.call(t, o[0], o[1]);
704
704
  }
705
705
  }, lr = (t, e) => {
706
- let r;
707
- const n = [];
708
- for (; (r = t.exec(e)) !== null; )
709
- n.push(r);
710
- return n;
711
- }, dr = x("HTMLFormElement"), fr = (t) => t.toLowerCase().replace(
706
+ let n;
707
+ const r = [];
708
+ for (; (n = t.exec(e)) !== null; )
709
+ r.push(n);
710
+ return r;
711
+ }, ur = P("HTMLFormElement"), dr = (t) => t.toLowerCase().replace(
712
712
  /[-_\s]([a-z\d])(\w*)/g,
713
- function(r, n, o) {
714
- return n.toUpperCase() + o;
713
+ function(n, r, i) {
714
+ return r.toUpperCase() + i;
715
715
  }
716
- ), st = (({ hasOwnProperty: t }) => (e, r) => t.call(e, r))(Object.prototype), pr = x("RegExp"), Qt = (t, e) => {
717
- const r = Object.getOwnPropertyDescriptors(t), n = {};
718
- ue(r, (o, i) => {
716
+ ), ct = (({ hasOwnProperty: t }) => (e, n) => t.call(e, n))(Object.prototype), fr = P("RegExp"), Vt = (t, e) => {
717
+ const n = Object.getOwnPropertyDescriptors(t), r = {};
718
+ le(n, (i, o) => {
719
719
  let s;
720
- (s = e(o, i, t)) !== !1 && (n[i] = s || o);
721
- }), Object.defineProperties(t, n);
722
- }, mr = (t) => {
723
- Qt(t, (e, r) => {
724
- if (N(t) && ["arguments", "caller", "callee"].indexOf(r) !== -1)
720
+ (s = e(i, o, t)) !== !1 && (r[o] = s || i);
721
+ }), Object.defineProperties(t, r);
722
+ }, pr = (t) => {
723
+ Vt(t, (e, n) => {
724
+ if (k(t) && ["arguments", "caller", "callee"].indexOf(n) !== -1)
725
725
  return !1;
726
- const n = t[r];
727
- if (N(n)) {
726
+ const r = t[n];
727
+ if (k(r)) {
728
728
  if (e.enumerable = !1, "writable" in e) {
729
729
  e.writable = !1;
730
730
  return;
731
731
  }
732
732
  e.set || (e.set = () => {
733
- throw Error("Can not rewrite read-only method '" + r + "'");
733
+ throw Error("Can not rewrite read-only method '" + n + "'");
734
734
  });
735
735
  }
736
736
  });
737
- }, hr = (t, e) => {
738
- const r = {}, n = (o) => {
739
- o.forEach((i) => {
740
- r[i] = !0;
737
+ }, mr = (t, e) => {
738
+ const n = {}, r = (i) => {
739
+ i.forEach((o) => {
740
+ n[o] = !0;
741
741
  });
742
742
  };
743
- return ne(t) ? n(t) : n(String(t).split(e)), r;
744
- }, yr = () => {
745
- }, gr = (t, e) => t != null && Number.isFinite(t = +t) ? t : e;
746
- function br(t) {
747
- return !!(t && N(t.append) && t[Vt] === "FormData" && t[ke]);
748
- }
749
- const wr = (t) => {
750
- const e = new Array(10), r = (n, o) => {
751
- if (ce(n)) {
752
- if (e.indexOf(n) >= 0)
743
+ return ne(t) ? r(t) : r(String(t).split(e)), n;
744
+ }, hr = () => {
745
+ }, yr = (t, e) => t != null && Number.isFinite(t = +t) ? t : e;
746
+ function gr(t) {
747
+ return !!(t && k(t.append) && t[It] === "FormData" && t[xe]);
748
+ }
749
+ const br = (t) => {
750
+ const e = new Array(10), n = (r, i) => {
751
+ if (ce(r)) {
752
+ if (e.indexOf(r) >= 0)
753
753
  return;
754
- if (ae(n))
755
- return n;
756
- if (!("toJSON" in n)) {
757
- e[o] = n;
758
- const i = ne(n) ? [] : {};
759
- return ue(n, (s, a) => {
760
- const c = r(s, o + 1);
761
- !te(c) && (i[a] = c);
762
- }), e[o] = void 0, i;
754
+ if (ae(r))
755
+ return r;
756
+ if (!("toJSON" in r)) {
757
+ e[i] = r;
758
+ const o = ne(r) ? [] : {};
759
+ return le(r, (s, a) => {
760
+ const c = n(s, i + 1);
761
+ !te(c) && (o[a] = c);
762
+ }), e[i] = void 0, o;
763
763
  }
764
764
  }
765
- return n;
765
+ return r;
766
766
  };
767
- return r(t, 0);
768
- }, Sr = x("AsyncFunction"), vr = (t) => t && (ce(t) || N(t)) && N(t.then) && N(t.catch), Kt = ((t, e) => t ? setImmediate : e ? ((r, n) => (V.addEventListener("message", ({ source: o, data: i }) => {
769
- o === V && i === r && n.length && n.shift()();
770
- }, !1), (o) => {
771
- n.push(o), V.postMessage(r, "*");
772
- }))(`axios@${Math.random()}`, []) : (r) => setTimeout(r))(
767
+ return n(t, 0);
768
+ }, wr = P("AsyncFunction"), Sr = (t) => t && (ce(t) || k(t)) && k(t.then) && k(t.catch), Ht = ((t, e) => t ? setImmediate : e ? ((n, r) => (V.addEventListener("message", ({ source: i, data: o }) => {
769
+ i === V && o === n && r.length && r.shift()();
770
+ }, !1), (i) => {
771
+ r.push(i), V.postMessage(n, "*");
772
+ }))(`axios@${Math.random()}`, []) : (n) => setTimeout(n))(
773
773
  typeof setImmediate == "function",
774
- N(V.postMessage)
775
- ), Ar = typeof queueMicrotask < "u" ? queueMicrotask.bind(V) : typeof process < "u" && process.nextTick || Kt, Er = (t) => t != null && N(t[ke]), d = {
774
+ k(V.postMessage)
775
+ ), Ar = typeof queueMicrotask < "u" ? queueMicrotask.bind(V) : typeof process < "u" && process.nextTick || Ht, vr = (t) => t != null && k(t[xe]), d = {
776
776
  isArray: ne,
777
- isArrayBuffer: Ht,
777
+ isArrayBuffer: Bt,
778
778
  isBuffer: ae,
779
779
  isFormData: Kn,
780
- isArrayBufferView: Un,
781
- isString: $n,
782
- isNumber: Wt,
783
- isBoolean: Ln,
780
+ isArrayBufferView: Bn,
781
+ isString: Un,
782
+ isNumber: Ut,
783
+ isBoolean: $n,
784
784
  isObject: ce,
785
785
  isPlainObject: Ee,
786
- isEmptyObject: Vn,
786
+ isEmptyObject: Ln,
787
787
  isReadableStream: Gn,
788
- isRequest: Yn,
789
- isResponse: Zn,
790
- isHeaders: er,
788
+ isRequest: Xn,
789
+ isResponse: Yn,
790
+ isHeaders: Zn,
791
791
  isUndefined: te,
792
- isDate: Hn,
793
- isFile: Wn,
794
- isBlob: zn,
795
- isRegExp: pr,
796
- isFunction: N,
797
- isStream: Qn,
798
- isURLSearchParams: Xn,
799
- isTypedArray: cr,
800
- isFileList: Jn,
801
- forEach: ue,
802
- merge: He,
803
- extend: nr,
804
- trim: tr,
805
- stripBOM: rr,
806
- inherits: or,
792
+ isDate: Vn,
793
+ isFile: Hn,
794
+ isBlob: Wn,
795
+ isRegExp: fr,
796
+ isFunction: k,
797
+ isStream: zn,
798
+ isURLSearchParams: Jn,
799
+ isTypedArray: ar,
800
+ isFileList: Qn,
801
+ forEach: le,
802
+ merge: Qe,
803
+ extend: tr,
804
+ trim: er,
805
+ stripBOM: nr,
806
+ inherits: rr,
807
807
  toFlatObject: ir,
808
808
  kindOf: _e,
809
- kindOfTest: x,
810
- endsWith: sr,
811
- toArray: ar,
812
- forEachEntry: ur,
809
+ kindOfTest: P,
810
+ endsWith: or,
811
+ toArray: sr,
812
+ forEachEntry: cr,
813
813
  matchAll: lr,
814
- isHTMLForm: dr,
815
- hasOwnProperty: st,
816
- hasOwnProp: st,
814
+ isHTMLForm: ur,
815
+ hasOwnProperty: ct,
816
+ hasOwnProp: ct,
817
817
  // an alias to avoid ESLint no-prototype-builtins detection
818
- reduceDescriptors: Qt,
819
- freezeMethods: mr,
820
- toObjectSet: hr,
821
- toCamelCase: fr,
822
- noop: yr,
823
- toFiniteNumber: gr,
824
- findKey: zt,
818
+ reduceDescriptors: Vt,
819
+ freezeMethods: pr,
820
+ toObjectSet: mr,
821
+ toCamelCase: dr,
822
+ noop: hr,
823
+ toFiniteNumber: yr,
824
+ findKey: $t,
825
825
  global: V,
826
- isContextDefined: Jt,
827
- isSpecCompliantForm: br,
828
- toJSONObject: wr,
829
- isAsyncFn: Sr,
830
- isThenable: vr,
831
- setImmediate: Kt,
826
+ isContextDefined: Lt,
827
+ isSpecCompliantForm: gr,
828
+ toJSONObject: br,
829
+ isAsyncFn: wr,
830
+ isThenable: Sr,
831
+ setImmediate: Ht,
832
832
  asap: Ar,
833
- isIterable: Er
833
+ isIterable: vr
834
834
  };
835
- function b(t, e, r, n, o) {
836
- Error.call(this), Error.captureStackTrace ? Error.captureStackTrace(this, this.constructor) : this.stack = new Error().stack, this.message = t, this.name = "AxiosError", e && (this.code = e), r && (this.config = r), n && (this.request = n), o && (this.response = o, this.status = o.status ? o.status : null);
835
+ function b(t, e, n, r, i) {
836
+ Error.call(this), Error.captureStackTrace ? Error.captureStackTrace(this, this.constructor) : this.stack = new Error().stack, this.message = t, this.name = "AxiosError", e && (this.code = e), n && (this.config = n), r && (this.request = r), i && (this.response = i, this.status = i.status ? i.status : null);
837
837
  }
838
838
  d.inherits(b, Error, {
839
839
  toJSON: function() {
@@ -856,7 +856,7 @@ d.inherits(b, Error, {
856
856
  };
857
857
  }
858
858
  });
859
- const Xt = b.prototype, Gt = {};
859
+ const Wt = b.prototype, Qt = {};
860
860
  [
861
861
  "ERR_BAD_OPTION_VALUE",
862
862
  "ERR_BAD_OPTION",
@@ -872,50 +872,50 @@ const Xt = b.prototype, Gt = {};
872
872
  "ERR_INVALID_URL"
873
873
  // eslint-disable-next-line func-names
874
874
  ].forEach((t) => {
875
- Gt[t] = { value: t };
875
+ Qt[t] = { value: t };
876
876
  });
877
- Object.defineProperties(b, Gt);
878
- Object.defineProperty(Xt, "isAxiosError", { value: !0 });
879
- b.from = (t, e, r, n, o, i) => {
880
- const s = Object.create(Xt);
881
- d.toFlatObject(t, s, function(l) {
882
- return l !== Error.prototype;
883
- }, (u) => u !== "isAxiosError");
877
+ Object.defineProperties(b, Qt);
878
+ Object.defineProperty(Wt, "isAxiosError", { value: !0 });
879
+ b.from = (t, e, n, r, i, o) => {
880
+ const s = Object.create(Wt);
881
+ d.toFlatObject(t, s, function(u) {
882
+ return u !== Error.prototype;
883
+ }, (l) => l !== "isAxiosError");
884
884
  const a = t && t.message ? t.message : "Error", c = e == null && t ? t.code : e;
885
- return b.call(s, a, c, r, n, o), t && s.cause == null && Object.defineProperty(s, "cause", { value: t, configurable: !0 }), s.name = t && t.name || "Error", i && Object.assign(s, i), s;
885
+ return b.call(s, a, c, n, r, i), t && s.cause == null && Object.defineProperty(s, "cause", { value: t, configurable: !0 }), s.name = t && t.name || "Error", o && Object.assign(s, o), s;
886
886
  };
887
- const Or = null;
888
- function We(t) {
887
+ const Er = null;
888
+ function ze(t) {
889
889
  return d.isPlainObject(t) || d.isArray(t);
890
890
  }
891
- function Yt(t) {
891
+ function zt(t) {
892
892
  return d.endsWith(t, "[]") ? t.slice(0, -2) : t;
893
893
  }
894
- function at(t, e, r) {
895
- return t ? t.concat(e).map(function(o, i) {
896
- return o = Yt(o), !r && i ? "[" + o + "]" : o;
897
- }).join(r ? "." : "") : e;
894
+ function lt(t, e, n) {
895
+ return t ? t.concat(e).map(function(i, o) {
896
+ return i = zt(i), !n && o ? "[" + i + "]" : i;
897
+ }).join(n ? "." : "") : e;
898
898
  }
899
- function Tr(t) {
900
- return d.isArray(t) && !t.some(We);
899
+ function Or(t) {
900
+ return d.isArray(t) && !t.some(ze);
901
901
  }
902
- const Nr = d.toFlatObject(d, {}, null, function(e) {
902
+ const Tr = d.toFlatObject(d, {}, null, function(e) {
903
903
  return /^is[A-Z]/.test(e);
904
904
  });
905
- function Ce(t, e, r) {
905
+ function Pe(t, e, n) {
906
906
  if (!d.isObject(t))
907
907
  throw new TypeError("target must be an object");
908
- e = e || new FormData(), r = d.toFlatObject(r, {
908
+ e = e || new FormData(), n = d.toFlatObject(n, {
909
909
  metaTokens: !0,
910
910
  dots: !1,
911
911
  indexes: !1
912
912
  }, !1, function(y, m) {
913
913
  return !d.isUndefined(m[y]);
914
914
  });
915
- const n = r.metaTokens, o = r.visitor || l, i = r.dots, s = r.indexes, c = (r.Blob || typeof Blob < "u" && Blob) && d.isSpecCompliantForm(e);
916
- if (!d.isFunction(o))
915
+ const r = n.metaTokens, i = n.visitor || u, o = n.dots, s = n.indexes, c = (n.Blob || typeof Blob < "u" && Blob) && d.isSpecCompliantForm(e);
916
+ if (!d.isFunction(i))
917
917
  throw new TypeError("visitor must be a function");
918
- function u(p) {
918
+ function l(p) {
919
919
  if (p === null) return "";
920
920
  if (d.isDate(p))
921
921
  return p.toISOString();
@@ -925,33 +925,33 @@ function Ce(t, e, r) {
925
925
  throw new b("Blob is not supported. Use a Buffer instead.");
926
926
  return d.isArrayBuffer(p) || d.isTypedArray(p) ? c && typeof Blob == "function" ? new Blob([p]) : Buffer.from(p) : p;
927
927
  }
928
- function l(p, y, m) {
928
+ function u(p, y, m) {
929
929
  let w = p;
930
930
  if (p && !m && typeof p == "object") {
931
931
  if (d.endsWith(y, "{}"))
932
- y = n ? y : y.slice(0, -2), p = JSON.stringify(p);
933
- else if (d.isArray(p) && Tr(p) || (d.isFileList(p) || d.endsWith(y, "[]")) && (w = d.toArray(p)))
934
- return y = Yt(y), w.forEach(function(v, T) {
935
- !(d.isUndefined(v) || v === null) && e.append(
932
+ y = r ? y : y.slice(0, -2), p = JSON.stringify(p);
933
+ else if (d.isArray(p) && Or(p) || (d.isFileList(p) || d.endsWith(y, "[]")) && (w = d.toArray(p)))
934
+ return y = zt(y), w.forEach(function(A, T) {
935
+ !(d.isUndefined(A) || A === null) && e.append(
936
936
  // eslint-disable-next-line no-nested-ternary
937
- s === !0 ? at([y], T, i) : s === null ? y : y + "[]",
938
- u(v)
937
+ s === !0 ? lt([y], T, o) : s === null ? y : y + "[]",
938
+ l(A)
939
939
  );
940
940
  }), !1;
941
941
  }
942
- return We(p) ? !0 : (e.append(at(m, y, i), u(p)), !1);
942
+ return ze(p) ? !0 : (e.append(lt(m, y, o), l(p)), !1);
943
943
  }
944
- const f = [], h = Object.assign(Nr, {
945
- defaultVisitor: l,
946
- convertValue: u,
947
- isVisitable: We
944
+ const f = [], h = Object.assign(Tr, {
945
+ defaultVisitor: u,
946
+ convertValue: l,
947
+ isVisitable: ze
948
948
  });
949
949
  function g(p, y) {
950
950
  if (!d.isUndefined(p)) {
951
951
  if (f.indexOf(p) !== -1)
952
952
  throw Error("Circular reference detected in " + y.join("."));
953
953
  f.push(p), d.forEach(p, function(w, O) {
954
- (!(d.isUndefined(w) || w === null) && o.call(
954
+ (!(d.isUndefined(w) || w === null) && i.call(
955
955
  e,
956
956
  w,
957
957
  d.isString(O) ? O.trim() : O,
@@ -965,7 +965,7 @@ function Ce(t, e, r) {
965
965
  throw new TypeError("data must be an object");
966
966
  return g(t), e;
967
967
  }
968
- function ct(t) {
968
+ function ut(t) {
969
969
  const e = {
970
970
  "!": "%21",
971
971
  "'": "%27",
@@ -975,44 +975,44 @@ function ct(t) {
975
975
  "%20": "+",
976
976
  "%00": "\0"
977
977
  };
978
- return encodeURIComponent(t).replace(/[!'()~]|%20|%00/g, function(n) {
979
- return e[n];
978
+ return encodeURIComponent(t).replace(/[!'()~]|%20|%00/g, function(r) {
979
+ return e[r];
980
980
  });
981
981
  }
982
- function Xe(t, e) {
983
- this._pairs = [], t && Ce(t, this, e);
982
+ function Ye(t, e) {
983
+ this._pairs = [], t && Pe(t, this, e);
984
984
  }
985
- const Zt = Xe.prototype;
986
- Zt.append = function(e, r) {
987
- this._pairs.push([e, r]);
985
+ const Kt = Ye.prototype;
986
+ Kt.append = function(e, n) {
987
+ this._pairs.push([e, n]);
988
988
  };
989
- Zt.toString = function(e) {
990
- const r = e ? function(n) {
991
- return e.call(this, n, ct);
992
- } : ct;
993
- return this._pairs.map(function(o) {
994
- return r(o[0]) + "=" + r(o[1]);
989
+ Kt.toString = function(e) {
990
+ const n = e ? function(r) {
991
+ return e.call(this, r, ut);
992
+ } : ut;
993
+ return this._pairs.map(function(i) {
994
+ return n(i[0]) + "=" + n(i[1]);
995
995
  }, "").join("&");
996
996
  };
997
- function Rr(t) {
997
+ function kr(t) {
998
998
  return encodeURIComponent(t).replace(/%3A/gi, ":").replace(/%24/g, "$").replace(/%2C/gi, ",").replace(/%20/g, "+");
999
999
  }
1000
- function en(t, e, r) {
1000
+ function Jt(t, e, n) {
1001
1001
  if (!e)
1002
1002
  return t;
1003
- const n = r && r.encode || Rr;
1004
- d.isFunction(r) && (r = {
1005
- serialize: r
1003
+ const r = n && n.encode || kr;
1004
+ d.isFunction(n) && (n = {
1005
+ serialize: n
1006
1006
  });
1007
- const o = r && r.serialize;
1008
- let i;
1009
- if (o ? i = o(e, r) : i = d.isURLSearchParams(e) ? e.toString() : new Xe(e, r).toString(n), i) {
1007
+ const i = n && n.serialize;
1008
+ let o;
1009
+ if (i ? o = i(e, n) : o = d.isURLSearchParams(e) ? e.toString() : new Ye(e, n).toString(r), o) {
1010
1010
  const s = t.indexOf("#");
1011
- s !== -1 && (t = t.slice(0, s)), t += (t.indexOf("?") === -1 ? "?" : "&") + i;
1011
+ s !== -1 && (t = t.slice(0, s)), t += (t.indexOf("?") === -1 ? "?" : "&") + o;
1012
1012
  }
1013
1013
  return t;
1014
1014
  }
1015
- class ut {
1015
+ class dt {
1016
1016
  constructor() {
1017
1017
  this.handlers = [];
1018
1018
  }
@@ -1024,12 +1024,12 @@ class ut {
1024
1024
  *
1025
1025
  * @return {Number} An ID used to remove interceptor later
1026
1026
  */
1027
- use(e, r, n) {
1027
+ use(e, n, r) {
1028
1028
  return this.handlers.push({
1029
1029
  fulfilled: e,
1030
- rejected: r,
1031
- synchronous: n ? n.synchronous : !1,
1032
- runWhen: n ? n.runWhen : null
1030
+ rejected: n,
1031
+ synchronous: r ? r.synchronous : !1,
1032
+ runWhen: r ? r.runWhen : null
1033
1033
  }), this.handlers.length - 1;
1034
1034
  }
1035
1035
  /**
@@ -1061,39 +1061,39 @@ class ut {
1061
1061
  * @returns {void}
1062
1062
  */
1063
1063
  forEach(e) {
1064
- d.forEach(this.handlers, function(n) {
1065
- n !== null && e(n);
1064
+ d.forEach(this.handlers, function(r) {
1065
+ r !== null && e(r);
1066
1066
  });
1067
1067
  }
1068
1068
  }
1069
- const tn = {
1069
+ const Gt = {
1070
1070
  silentJSONParsing: !0,
1071
1071
  forcedJSONParsing: !0,
1072
1072
  clarifyTimeoutError: !1
1073
- }, kr = typeof URLSearchParams < "u" ? URLSearchParams : Xe, _r = typeof FormData < "u" ? FormData : null, Pr = typeof Blob < "u" ? Blob : null, Cr = {
1073
+ }, Rr = typeof URLSearchParams < "u" ? URLSearchParams : Ye, Nr = typeof FormData < "u" ? FormData : null, xr = typeof Blob < "u" ? Blob : null, _r = {
1074
1074
  isBrowser: !0,
1075
1075
  classes: {
1076
- URLSearchParams: kr,
1077
- FormData: _r,
1078
- Blob: Pr
1076
+ URLSearchParams: Rr,
1077
+ FormData: Nr,
1078
+ Blob: xr
1079
1079
  },
1080
1080
  protocols: ["http", "https", "file", "blob", "url", "data"]
1081
- }, Ge = typeof window < "u" && typeof document < "u", ze = typeof navigator == "object" && navigator || void 0, xr = Ge && (!ze || ["ReactNative", "NativeScript", "NS"].indexOf(ze.product) < 0), Dr = typeof WorkerGlobalScope < "u" && // eslint-disable-next-line no-undef
1082
- self instanceof WorkerGlobalScope && typeof self.importScripts == "function", Fr = Ge && window.location.href || "http://localhost", qr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1081
+ }, Ze = typeof window < "u" && typeof document < "u", Ke = typeof navigator == "object" && navigator || void 0, Cr = Ze && (!Ke || ["ReactNative", "NativeScript", "NS"].indexOf(Ke.product) < 0), Pr = typeof WorkerGlobalScope < "u" && // eslint-disable-next-line no-undef
1082
+ self instanceof WorkerGlobalScope && typeof self.importScripts == "function", Dr = Ze && window.location.href || "http://localhost", qr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1083
1083
  __proto__: null,
1084
- hasBrowserEnv: Ge,
1085
- hasStandardBrowserEnv: xr,
1086
- hasStandardBrowserWebWorkerEnv: Dr,
1087
- navigator: ze,
1088
- origin: Fr
1084
+ hasBrowserEnv: Ze,
1085
+ hasStandardBrowserEnv: Cr,
1086
+ hasStandardBrowserWebWorkerEnv: Pr,
1087
+ navigator: Ke,
1088
+ origin: Dr
1089
1089
  }, Symbol.toStringTag, { value: "Module" })), E = {
1090
1090
  ...qr,
1091
- ...Cr
1091
+ ..._r
1092
1092
  };
1093
- function jr(t, e) {
1094
- return Ce(t, new E.classes.URLSearchParams(), {
1095
- visitor: function(r, n, o, i) {
1096
- return E.isNode && d.isBuffer(r) ? (this.append(n, r.toString("base64")), !1) : i.defaultVisitor.apply(this, arguments);
1093
+ function Fr(t, e) {
1094
+ return Pe(t, new E.classes.URLSearchParams(), {
1095
+ visitor: function(n, r, i, o) {
1096
+ return E.isNode && d.isBuffer(n) ? (this.append(r, n.toString("base64")), !1) : o.defaultVisitor.apply(this, arguments);
1097
1097
  },
1098
1098
  ...e
1099
1099
  });
@@ -1101,74 +1101,74 @@ function jr(t, e) {
1101
1101
  function Mr(t) {
1102
1102
  return d.matchAll(/\w+|\[(\w*)]/g, t).map((e) => e[0] === "[]" ? "" : e[1] || e[0]);
1103
1103
  }
1104
- function Br(t) {
1105
- const e = {}, r = Object.keys(t);
1106
- let n;
1107
- const o = r.length;
1108
- let i;
1109
- for (n = 0; n < o; n++)
1110
- i = r[n], e[i] = t[i];
1104
+ function jr(t) {
1105
+ const e = {}, n = Object.keys(t);
1106
+ let r;
1107
+ const i = n.length;
1108
+ let o;
1109
+ for (r = 0; r < i; r++)
1110
+ o = n[r], e[o] = t[o];
1111
1111
  return e;
1112
1112
  }
1113
- function nn(t) {
1114
- function e(r, n, o, i) {
1115
- let s = r[i++];
1113
+ function Xt(t) {
1114
+ function e(n, r, i, o) {
1115
+ let s = n[o++];
1116
1116
  if (s === "__proto__") return !0;
1117
- const a = Number.isFinite(+s), c = i >= r.length;
1118
- return s = !s && d.isArray(o) ? o.length : s, c ? (d.hasOwnProp(o, s) ? o[s] = [o[s], n] : o[s] = n, !a) : ((!o[s] || !d.isObject(o[s])) && (o[s] = []), e(r, n, o[s], i) && d.isArray(o[s]) && (o[s] = Br(o[s])), !a);
1117
+ const a = Number.isFinite(+s), c = o >= n.length;
1118
+ return s = !s && d.isArray(i) ? i.length : s, c ? (d.hasOwnProp(i, s) ? i[s] = [i[s], r] : i[s] = r, !a) : ((!i[s] || !d.isObject(i[s])) && (i[s] = []), e(n, r, i[s], o) && d.isArray(i[s]) && (i[s] = jr(i[s])), !a);
1119
1119
  }
1120
1120
  if (d.isFormData(t) && d.isFunction(t.entries)) {
1121
- const r = {};
1122
- return d.forEachEntry(t, (n, o) => {
1123
- e(Mr(n), o, r, 0);
1124
- }), r;
1121
+ const n = {};
1122
+ return d.forEachEntry(t, (r, i) => {
1123
+ e(Mr(r), i, n, 0);
1124
+ }), n;
1125
1125
  }
1126
1126
  return null;
1127
1127
  }
1128
- function Ir(t, e, r) {
1128
+ function Ir(t, e, n) {
1129
1129
  if (d.isString(t))
1130
1130
  try {
1131
1131
  return (e || JSON.parse)(t), d.trim(t);
1132
- } catch (n) {
1133
- if (n.name !== "SyntaxError")
1134
- throw n;
1132
+ } catch (r) {
1133
+ if (r.name !== "SyntaxError")
1134
+ throw r;
1135
1135
  }
1136
- return (r || JSON.stringify)(t);
1136
+ return (n || JSON.stringify)(t);
1137
1137
  }
1138
- const le = {
1139
- transitional: tn,
1138
+ const ue = {
1139
+ transitional: Gt,
1140
1140
  adapter: ["xhr", "http", "fetch"],
1141
- transformRequest: [function(e, r) {
1142
- const n = r.getContentType() || "", o = n.indexOf("application/json") > -1, i = d.isObject(e);
1143
- if (i && d.isHTMLForm(e) && (e = new FormData(e)), d.isFormData(e))
1144
- return o ? JSON.stringify(nn(e)) : e;
1141
+ transformRequest: [function(e, n) {
1142
+ const r = n.getContentType() || "", i = r.indexOf("application/json") > -1, o = d.isObject(e);
1143
+ if (o && d.isHTMLForm(e) && (e = new FormData(e)), d.isFormData(e))
1144
+ return i ? JSON.stringify(Xt(e)) : e;
1145
1145
  if (d.isArrayBuffer(e) || d.isBuffer(e) || d.isStream(e) || d.isFile(e) || d.isBlob(e) || d.isReadableStream(e))
1146
1146
  return e;
1147
1147
  if (d.isArrayBufferView(e))
1148
1148
  return e.buffer;
1149
1149
  if (d.isURLSearchParams(e))
1150
- return r.setContentType("application/x-www-form-urlencoded;charset=utf-8", !1), e.toString();
1150
+ return n.setContentType("application/x-www-form-urlencoded;charset=utf-8", !1), e.toString();
1151
1151
  let a;
1152
- if (i) {
1153
- if (n.indexOf("application/x-www-form-urlencoded") > -1)
1154
- return jr(e, this.formSerializer).toString();
1155
- if ((a = d.isFileList(e)) || n.indexOf("multipart/form-data") > -1) {
1152
+ if (o) {
1153
+ if (r.indexOf("application/x-www-form-urlencoded") > -1)
1154
+ return Fr(e, this.formSerializer).toString();
1155
+ if ((a = d.isFileList(e)) || r.indexOf("multipart/form-data") > -1) {
1156
1156
  const c = this.env && this.env.FormData;
1157
- return Ce(
1157
+ return Pe(
1158
1158
  a ? { "files[]": e } : e,
1159
1159
  c && new c(),
1160
1160
  this.formSerializer
1161
1161
  );
1162
1162
  }
1163
1163
  }
1164
- return i || o ? (r.setContentType("application/json", !1), Ir(e)) : e;
1164
+ return o || i ? (n.setContentType("application/json", !1), Ir(e)) : e;
1165
1165
  }],
1166
1166
  transformResponse: [function(e) {
1167
- const r = this.transitional || le.transitional, n = r && r.forcedJSONParsing, o = this.responseType === "json";
1167
+ const n = this.transitional || ue.transitional, r = n && n.forcedJSONParsing, i = this.responseType === "json";
1168
1168
  if (d.isResponse(e) || d.isReadableStream(e))
1169
1169
  return e;
1170
- if (e && d.isString(e) && (n && !this.responseType || o)) {
1171
- const s = !(r && r.silentJSONParsing) && o;
1170
+ if (e && d.isString(e) && (r && !this.responseType || i)) {
1171
+ const s = !(n && n.silentJSONParsing) && i;
1172
1172
  try {
1173
1173
  return JSON.parse(e, this.parseReviver);
1174
1174
  } catch (a) {
@@ -1202,9 +1202,9 @@ const le = {
1202
1202
  }
1203
1203
  };
1204
1204
  d.forEach(["delete", "get", "head", "post", "put", "patch"], (t) => {
1205
- le.headers[t] = {};
1205
+ ue.headers[t] = {};
1206
1206
  });
1207
- const Ur = d.toObjectSet([
1207
+ const Br = d.toObjectSet([
1208
1208
  "age",
1209
1209
  "authorization",
1210
1210
  "content-length",
@@ -1222,47 +1222,47 @@ const Ur = d.toObjectSet([
1222
1222
  "referer",
1223
1223
  "retry-after",
1224
1224
  "user-agent"
1225
- ]), $r = (t) => {
1225
+ ]), Ur = (t) => {
1226
1226
  const e = {};
1227
- let r, n, o;
1227
+ let n, r, i;
1228
1228
  return t && t.split(`
1229
1229
  `).forEach(function(s) {
1230
- o = s.indexOf(":"), r = s.substring(0, o).trim().toLowerCase(), n = s.substring(o + 1).trim(), !(!r || e[r] && Ur[r]) && (r === "set-cookie" ? e[r] ? e[r].push(n) : e[r] = [n] : e[r] = e[r] ? e[r] + ", " + n : n);
1230
+ i = s.indexOf(":"), n = s.substring(0, i).trim().toLowerCase(), r = s.substring(i + 1).trim(), !(!n || e[n] && Br[n]) && (n === "set-cookie" ? e[n] ? e[n].push(r) : e[n] = [r] : e[n] = e[n] ? e[n] + ", " + r : r);
1231
1231
  }), e;
1232
- }, lt = Symbol("internals");
1233
- function ie(t) {
1232
+ }, ft = Symbol("internals");
1233
+ function oe(t) {
1234
1234
  return t && String(t).trim().toLowerCase();
1235
1235
  }
1236
1236
  function Oe(t) {
1237
1237
  return t === !1 || t == null ? t : d.isArray(t) ? t.map(Oe) : String(t);
1238
1238
  }
1239
- function Lr(t) {
1240
- const e = /* @__PURE__ */ Object.create(null), r = /([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;
1241
- let n;
1242
- for (; n = r.exec(t); )
1243
- e[n[1]] = n[2];
1239
+ function $r(t) {
1240
+ const e = /* @__PURE__ */ Object.create(null), n = /([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;
1241
+ let r;
1242
+ for (; r = n.exec(t); )
1243
+ e[r[1]] = r[2];
1244
1244
  return e;
1245
1245
  }
1246
- const Vr = (t) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(t.trim());
1247
- function Ue(t, e, r, n, o) {
1248
- if (d.isFunction(n))
1249
- return n.call(this, e, r);
1250
- if (o && (e = r), !!d.isString(e)) {
1251
- if (d.isString(n))
1252
- return e.indexOf(n) !== -1;
1253
- if (d.isRegExp(n))
1254
- return n.test(e);
1255
- }
1256
- }
1257
- function Hr(t) {
1258
- return t.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (e, r, n) => r.toUpperCase() + n);
1259
- }
1260
- function Wr(t, e) {
1261
- const r = d.toCamelCase(" " + e);
1262
- ["get", "set", "has"].forEach((n) => {
1263
- Object.defineProperty(t, n + r, {
1264
- value: function(o, i, s) {
1265
- return this[n].call(this, e, o, i, s);
1246
+ const Lr = (t) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(t.trim());
1247
+ function Le(t, e, n, r, i) {
1248
+ if (d.isFunction(r))
1249
+ return r.call(this, e, n);
1250
+ if (i && (e = n), !!d.isString(e)) {
1251
+ if (d.isString(r))
1252
+ return e.indexOf(r) !== -1;
1253
+ if (d.isRegExp(r))
1254
+ return r.test(e);
1255
+ }
1256
+ }
1257
+ function Vr(t) {
1258
+ return t.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (e, n, r) => n.toUpperCase() + r);
1259
+ }
1260
+ function Hr(t, e) {
1261
+ const n = d.toCamelCase(" " + e);
1262
+ ["get", "set", "has"].forEach((r) => {
1263
+ Object.defineProperty(t, r + n, {
1264
+ value: function(i, o, s) {
1265
+ return this[r].call(this, e, i, o, s);
1266
1266
  },
1267
1267
  configurable: !0
1268
1268
  });
@@ -1272,102 +1272,102 @@ let R = class {
1272
1272
  constructor(e) {
1273
1273
  e && this.set(e);
1274
1274
  }
1275
- set(e, r, n) {
1276
- const o = this;
1277
- function i(a, c, u) {
1278
- const l = ie(c);
1279
- if (!l)
1275
+ set(e, n, r) {
1276
+ const i = this;
1277
+ function o(a, c, l) {
1278
+ const u = oe(c);
1279
+ if (!u)
1280
1280
  throw new Error("header name must be a non-empty string");
1281
- const f = d.findKey(o, l);
1282
- (!f || o[f] === void 0 || u === !0 || u === void 0 && o[f] !== !1) && (o[f || c] = Oe(a));
1281
+ const f = d.findKey(i, u);
1282
+ (!f || i[f] === void 0 || l === !0 || l === void 0 && i[f] !== !1) && (i[f || c] = Oe(a));
1283
1283
  }
1284
- const s = (a, c) => d.forEach(a, (u, l) => i(u, l, c));
1284
+ const s = (a, c) => d.forEach(a, (l, u) => o(l, u, c));
1285
1285
  if (d.isPlainObject(e) || e instanceof this.constructor)
1286
- s(e, r);
1287
- else if (d.isString(e) && (e = e.trim()) && !Vr(e))
1288
- s($r(e), r);
1286
+ s(e, n);
1287
+ else if (d.isString(e) && (e = e.trim()) && !Lr(e))
1288
+ s(Ur(e), n);
1289
1289
  else if (d.isObject(e) && d.isIterable(e)) {
1290
- let a = {}, c, u;
1291
- for (const l of e) {
1292
- if (!d.isArray(l))
1290
+ let a = {}, c, l;
1291
+ for (const u of e) {
1292
+ if (!d.isArray(u))
1293
1293
  throw TypeError("Object iterator must return a key-value pair");
1294
- a[u = l[0]] = (c = a[u]) ? d.isArray(c) ? [...c, l[1]] : [c, l[1]] : l[1];
1294
+ a[l = u[0]] = (c = a[l]) ? d.isArray(c) ? [...c, u[1]] : [c, u[1]] : u[1];
1295
1295
  }
1296
- s(a, r);
1296
+ s(a, n);
1297
1297
  } else
1298
- e != null && i(r, e, n);
1298
+ e != null && o(n, e, r);
1299
1299
  return this;
1300
1300
  }
1301
- get(e, r) {
1302
- if (e = ie(e), e) {
1303
- const n = d.findKey(this, e);
1304
- if (n) {
1305
- const o = this[n];
1306
- if (!r)
1307
- return o;
1308
- if (r === !0)
1309
- return Lr(o);
1310
- if (d.isFunction(r))
1311
- return r.call(this, o, n);
1312
- if (d.isRegExp(r))
1313
- return r.exec(o);
1301
+ get(e, n) {
1302
+ if (e = oe(e), e) {
1303
+ const r = d.findKey(this, e);
1304
+ if (r) {
1305
+ const i = this[r];
1306
+ if (!n)
1307
+ return i;
1308
+ if (n === !0)
1309
+ return $r(i);
1310
+ if (d.isFunction(n))
1311
+ return n.call(this, i, r);
1312
+ if (d.isRegExp(n))
1313
+ return n.exec(i);
1314
1314
  throw new TypeError("parser must be boolean|regexp|function");
1315
1315
  }
1316
1316
  }
1317
1317
  }
1318
- has(e, r) {
1319
- if (e = ie(e), e) {
1320
- const n = d.findKey(this, e);
1321
- return !!(n && this[n] !== void 0 && (!r || Ue(this, this[n], n, r)));
1318
+ has(e, n) {
1319
+ if (e = oe(e), e) {
1320
+ const r = d.findKey(this, e);
1321
+ return !!(r && this[r] !== void 0 && (!n || Le(this, this[r], r, n)));
1322
1322
  }
1323
1323
  return !1;
1324
1324
  }
1325
- delete(e, r) {
1326
- const n = this;
1327
- let o = !1;
1328
- function i(s) {
1329
- if (s = ie(s), s) {
1330
- const a = d.findKey(n, s);
1331
- a && (!r || Ue(n, n[a], a, r)) && (delete n[a], o = !0);
1325
+ delete(e, n) {
1326
+ const r = this;
1327
+ let i = !1;
1328
+ function o(s) {
1329
+ if (s = oe(s), s) {
1330
+ const a = d.findKey(r, s);
1331
+ a && (!n || Le(r, r[a], a, n)) && (delete r[a], i = !0);
1332
1332
  }
1333
1333
  }
1334
- return d.isArray(e) ? e.forEach(i) : i(e), o;
1334
+ return d.isArray(e) ? e.forEach(o) : o(e), i;
1335
1335
  }
1336
1336
  clear(e) {
1337
- const r = Object.keys(this);
1338
- let n = r.length, o = !1;
1339
- for (; n--; ) {
1340
- const i = r[n];
1341
- (!e || Ue(this, this[i], i, e, !0)) && (delete this[i], o = !0);
1337
+ const n = Object.keys(this);
1338
+ let r = n.length, i = !1;
1339
+ for (; r--; ) {
1340
+ const o = n[r];
1341
+ (!e || Le(this, this[o], o, e, !0)) && (delete this[o], i = !0);
1342
1342
  }
1343
- return o;
1343
+ return i;
1344
1344
  }
1345
1345
  normalize(e) {
1346
- const r = this, n = {};
1347
- return d.forEach(this, (o, i) => {
1348
- const s = d.findKey(n, i);
1346
+ const n = this, r = {};
1347
+ return d.forEach(this, (i, o) => {
1348
+ const s = d.findKey(r, o);
1349
1349
  if (s) {
1350
- r[s] = Oe(o), delete r[i];
1350
+ n[s] = Oe(i), delete n[o];
1351
1351
  return;
1352
1352
  }
1353
- const a = e ? Hr(i) : String(i).trim();
1354
- a !== i && delete r[i], r[a] = Oe(o), n[a] = !0;
1353
+ const a = e ? Vr(o) : String(o).trim();
1354
+ a !== o && delete n[o], n[a] = Oe(i), r[a] = !0;
1355
1355
  }), this;
1356
1356
  }
1357
1357
  concat(...e) {
1358
1358
  return this.constructor.concat(this, ...e);
1359
1359
  }
1360
1360
  toJSON(e) {
1361
- const r = /* @__PURE__ */ Object.create(null);
1362
- return d.forEach(this, (n, o) => {
1363
- n != null && n !== !1 && (r[o] = e && d.isArray(n) ? n.join(", ") : n);
1364
- }), r;
1361
+ const n = /* @__PURE__ */ Object.create(null);
1362
+ return d.forEach(this, (r, i) => {
1363
+ r != null && r !== !1 && (n[i] = e && d.isArray(r) ? r.join(", ") : r);
1364
+ }), n;
1365
1365
  }
1366
1366
  [Symbol.iterator]() {
1367
1367
  return Object.entries(this.toJSON())[Symbol.iterator]();
1368
1368
  }
1369
1369
  toString() {
1370
- return Object.entries(this.toJSON()).map(([e, r]) => e + ": " + r).join(`
1370
+ return Object.entries(this.toJSON()).map(([e, n]) => e + ": " + n).join(`
1371
1371
  `);
1372
1372
  }
1373
1373
  getSetCookie() {
@@ -1379,126 +1379,126 @@ let R = class {
1379
1379
  static from(e) {
1380
1380
  return e instanceof this ? e : new this(e);
1381
1381
  }
1382
- static concat(e, ...r) {
1383
- const n = new this(e);
1384
- return r.forEach((o) => n.set(o)), n;
1382
+ static concat(e, ...n) {
1383
+ const r = new this(e);
1384
+ return n.forEach((i) => r.set(i)), r;
1385
1385
  }
1386
1386
  static accessor(e) {
1387
- const n = (this[lt] = this[lt] = {
1387
+ const r = (this[ft] = this[ft] = {
1388
1388
  accessors: {}
1389
- }).accessors, o = this.prototype;
1390
- function i(s) {
1391
- const a = ie(s);
1392
- n[a] || (Wr(o, s), n[a] = !0);
1389
+ }).accessors, i = this.prototype;
1390
+ function o(s) {
1391
+ const a = oe(s);
1392
+ r[a] || (Hr(i, s), r[a] = !0);
1393
1393
  }
1394
- return d.isArray(e) ? e.forEach(i) : i(e), this;
1394
+ return d.isArray(e) ? e.forEach(o) : o(e), this;
1395
1395
  }
1396
1396
  };
1397
1397
  R.accessor(["Content-Type", "Content-Length", "Accept", "Accept-Encoding", "User-Agent", "Authorization"]);
1398
1398
  d.reduceDescriptors(R.prototype, ({ value: t }, e) => {
1399
- let r = e[0].toUpperCase() + e.slice(1);
1399
+ let n = e[0].toUpperCase() + e.slice(1);
1400
1400
  return {
1401
1401
  get: () => t,
1402
- set(n) {
1403
- this[r] = n;
1402
+ set(r) {
1403
+ this[n] = r;
1404
1404
  }
1405
1405
  };
1406
1406
  });
1407
1407
  d.freezeMethods(R);
1408
- function $e(t, e) {
1409
- const r = this || le, n = e || r, o = R.from(n.headers);
1410
- let i = n.data;
1408
+ function Ve(t, e) {
1409
+ const n = this || ue, r = e || n, i = R.from(r.headers);
1410
+ let o = r.data;
1411
1411
  return d.forEach(t, function(a) {
1412
- i = a.call(r, i, o.normalize(), e ? e.status : void 0);
1413
- }), o.normalize(), i;
1412
+ o = a.call(n, o, i.normalize(), e ? e.status : void 0);
1413
+ }), i.normalize(), o;
1414
1414
  }
1415
- function rn(t) {
1415
+ function Yt(t) {
1416
1416
  return !!(t && t.__CANCEL__);
1417
1417
  }
1418
- function re(t, e, r) {
1419
- b.call(this, t ?? "canceled", b.ERR_CANCELED, e, r), this.name = "CanceledError";
1418
+ function re(t, e, n) {
1419
+ b.call(this, t ?? "canceled", b.ERR_CANCELED, e, n), this.name = "CanceledError";
1420
1420
  }
1421
1421
  d.inherits(re, b, {
1422
1422
  __CANCEL__: !0
1423
1423
  });
1424
- function on(t, e, r) {
1425
- const n = r.config.validateStatus;
1426
- !r.status || !n || n(r.status) ? t(r) : e(new b(
1427
- "Request failed with status code " + r.status,
1428
- [b.ERR_BAD_REQUEST, b.ERR_BAD_RESPONSE][Math.floor(r.status / 100) - 4],
1429
- r.config,
1430
- r.request,
1431
- r
1424
+ function Zt(t, e, n) {
1425
+ const r = n.config.validateStatus;
1426
+ !n.status || !r || r(n.status) ? t(n) : e(new b(
1427
+ "Request failed with status code " + n.status,
1428
+ [b.ERR_BAD_REQUEST, b.ERR_BAD_RESPONSE][Math.floor(n.status / 100) - 4],
1429
+ n.config,
1430
+ n.request,
1431
+ n
1432
1432
  ));
1433
1433
  }
1434
- function zr(t) {
1434
+ function Wr(t) {
1435
1435
  const e = /^([-+\w]{1,25})(:?\/\/|:)/.exec(t);
1436
1436
  return e && e[1] || "";
1437
1437
  }
1438
- function Jr(t, e) {
1438
+ function Qr(t, e) {
1439
1439
  t = t || 10;
1440
- const r = new Array(t), n = new Array(t);
1441
- let o = 0, i = 0, s;
1440
+ const n = new Array(t), r = new Array(t);
1441
+ let i = 0, o = 0, s;
1442
1442
  return e = e !== void 0 ? e : 1e3, function(c) {
1443
- const u = Date.now(), l = n[i];
1444
- s || (s = u), r[o] = c, n[o] = u;
1445
- let f = i, h = 0;
1446
- for (; f !== o; )
1447
- h += r[f++], f = f % t;
1448
- if (o = (o + 1) % t, o === i && (i = (i + 1) % t), u - s < e)
1443
+ const l = Date.now(), u = r[o];
1444
+ s || (s = l), n[i] = c, r[i] = l;
1445
+ let f = o, h = 0;
1446
+ for (; f !== i; )
1447
+ h += n[f++], f = f % t;
1448
+ if (i = (i + 1) % t, i === o && (o = (o + 1) % t), l - s < e)
1449
1449
  return;
1450
- const g = l && u - l;
1450
+ const g = u && l - u;
1451
1451
  return g ? Math.round(h * 1e3 / g) : void 0;
1452
1452
  };
1453
1453
  }
1454
- function Qr(t, e) {
1455
- let r = 0, n = 1e3 / e, o, i;
1456
- const s = (u, l = Date.now()) => {
1457
- r = l, o = null, i && (clearTimeout(i), i = null), t(...u);
1454
+ function zr(t, e) {
1455
+ let n = 0, r = 1e3 / e, i, o;
1456
+ const s = (l, u = Date.now()) => {
1457
+ n = u, i = null, o && (clearTimeout(o), o = null), t(...l);
1458
1458
  };
1459
- return [(...u) => {
1460
- const l = Date.now(), f = l - r;
1461
- f >= n ? s(u, l) : (o = u, i || (i = setTimeout(() => {
1462
- i = null, s(o);
1463
- }, n - f)));
1464
- }, () => o && s(o)];
1465
- }
1466
- const Ne = (t, e, r = 3) => {
1467
- let n = 0;
1468
- const o = Jr(50, 250);
1469
- return Qr((i) => {
1470
- const s = i.loaded, a = i.lengthComputable ? i.total : void 0, c = s - n, u = o(c), l = s <= a;
1471
- n = s;
1459
+ return [(...l) => {
1460
+ const u = Date.now(), f = u - n;
1461
+ f >= r ? s(l, u) : (i = l, o || (o = setTimeout(() => {
1462
+ o = null, s(i);
1463
+ }, r - f)));
1464
+ }, () => i && s(i)];
1465
+ }
1466
+ const ke = (t, e, n = 3) => {
1467
+ let r = 0;
1468
+ const i = Qr(50, 250);
1469
+ return zr((o) => {
1470
+ const s = o.loaded, a = o.lengthComputable ? o.total : void 0, c = s - r, l = i(c), u = s <= a;
1471
+ r = s;
1472
1472
  const f = {
1473
1473
  loaded: s,
1474
1474
  total: a,
1475
1475
  progress: a ? s / a : void 0,
1476
1476
  bytes: c,
1477
- rate: u || void 0,
1478
- estimated: u && a && l ? (a - s) / u : void 0,
1479
- event: i,
1477
+ rate: l || void 0,
1478
+ estimated: l && a && u ? (a - s) / l : void 0,
1479
+ event: o,
1480
1480
  lengthComputable: a != null,
1481
1481
  [e ? "download" : "upload"]: !0
1482
1482
  };
1483
1483
  t(f);
1484
- }, r);
1485
- }, dt = (t, e) => {
1486
- const r = t != null;
1487
- return [(n) => e[0]({
1488
- lengthComputable: r,
1484
+ }, n);
1485
+ }, pt = (t, e) => {
1486
+ const n = t != null;
1487
+ return [(r) => e[0]({
1488
+ lengthComputable: n,
1489
1489
  total: t,
1490
- loaded: n
1490
+ loaded: r
1491
1491
  }), e[1]];
1492
- }, ft = (t) => (...e) => d.asap(() => t(...e)), Kr = E.hasStandardBrowserEnv ? /* @__PURE__ */ ((t, e) => (r) => (r = new URL(r, E.origin), t.protocol === r.protocol && t.host === r.host && (e || t.port === r.port)))(
1492
+ }, mt = (t) => (...e) => d.asap(() => t(...e)), Kr = E.hasStandardBrowserEnv ? /* @__PURE__ */ ((t, e) => (n) => (n = new URL(n, E.origin), t.protocol === n.protocol && t.host === n.host && (e || t.port === n.port)))(
1493
1493
  new URL(E.origin),
1494
1494
  E.navigator && /(msie|trident)/i.test(E.navigator.userAgent)
1495
- ) : () => !0, Xr = E.hasStandardBrowserEnv ? (
1495
+ ) : () => !0, Jr = E.hasStandardBrowserEnv ? (
1496
1496
  // Standard browser envs support document.cookie
1497
1497
  {
1498
- write(t, e, r, n, o, i, s) {
1498
+ write(t, e, n, r, i, o, s) {
1499
1499
  if (typeof document > "u") return;
1500
1500
  const a = [`${t}=${encodeURIComponent(e)}`];
1501
- d.isNumber(r) && a.push(`expires=${new Date(r).toUTCString()}`), d.isString(n) && a.push(`path=${n}`), d.isString(o) && a.push(`domain=${o}`), i === !0 && a.push("secure"), d.isString(s) && a.push(`SameSite=${s}`), document.cookie = a.join("; ");
1501
+ d.isNumber(n) && a.push(`expires=${new Date(n).toUTCString()}`), d.isString(r) && a.push(`path=${r}`), d.isString(i) && a.push(`domain=${i}`), o === !0 && a.push("secure"), d.isString(s) && a.push(`SameSite=${s}`), document.cookie = a.join("; ");
1502
1502
  },
1503
1503
  read(t) {
1504
1504
  if (typeof document > "u") return null;
@@ -1524,46 +1524,46 @@ const Ne = (t, e, r = 3) => {
1524
1524
  function Gr(t) {
1525
1525
  return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(t);
1526
1526
  }
1527
- function Yr(t, e) {
1527
+ function Xr(t, e) {
1528
1528
  return e ? t.replace(/\/?\/$/, "") + "/" + e.replace(/^\/+/, "") : t;
1529
1529
  }
1530
- function sn(t, e, r) {
1531
- let n = !Gr(e);
1532
- return t && (n || r == !1) ? Yr(t, e) : e;
1530
+ function en(t, e, n) {
1531
+ let r = !Gr(e);
1532
+ return t && (r || n == !1) ? Xr(t, e) : e;
1533
1533
  }
1534
- const pt = (t) => t instanceof R ? { ...t } : t;
1534
+ const ht = (t) => t instanceof R ? { ...t } : t;
1535
1535
  function W(t, e) {
1536
1536
  e = e || {};
1537
- const r = {};
1538
- function n(u, l, f, h) {
1539
- return d.isPlainObject(u) && d.isPlainObject(l) ? d.merge.call({ caseless: h }, u, l) : d.isPlainObject(l) ? d.merge({}, l) : d.isArray(l) ? l.slice() : l;
1540
- }
1541
- function o(u, l, f, h) {
1542
- if (d.isUndefined(l)) {
1543
- if (!d.isUndefined(u))
1544
- return n(void 0, u, f, h);
1545
- } else return n(u, l, f, h);
1546
- }
1547
- function i(u, l) {
1548
- if (!d.isUndefined(l))
1549
- return n(void 0, l);
1550
- }
1551
- function s(u, l) {
1552
- if (d.isUndefined(l)) {
1553
- if (!d.isUndefined(u))
1554
- return n(void 0, u);
1555
- } else return n(void 0, l);
1556
- }
1557
- function a(u, l, f) {
1537
+ const n = {};
1538
+ function r(l, u, f, h) {
1539
+ return d.isPlainObject(l) && d.isPlainObject(u) ? d.merge.call({ caseless: h }, l, u) : d.isPlainObject(u) ? d.merge({}, u) : d.isArray(u) ? u.slice() : u;
1540
+ }
1541
+ function i(l, u, f, h) {
1542
+ if (d.isUndefined(u)) {
1543
+ if (!d.isUndefined(l))
1544
+ return r(void 0, l, f, h);
1545
+ } else return r(l, u, f, h);
1546
+ }
1547
+ function o(l, u) {
1548
+ if (!d.isUndefined(u))
1549
+ return r(void 0, u);
1550
+ }
1551
+ function s(l, u) {
1552
+ if (d.isUndefined(u)) {
1553
+ if (!d.isUndefined(l))
1554
+ return r(void 0, l);
1555
+ } else return r(void 0, u);
1556
+ }
1557
+ function a(l, u, f) {
1558
1558
  if (f in e)
1559
- return n(u, l);
1559
+ return r(l, u);
1560
1560
  if (f in t)
1561
- return n(void 0, u);
1561
+ return r(void 0, l);
1562
1562
  }
1563
1563
  const c = {
1564
- url: i,
1565
- method: i,
1566
- data: i,
1564
+ url: o,
1565
+ method: o,
1566
+ data: o,
1567
1567
  baseURL: s,
1568
1568
  transformRequest: s,
1569
1569
  transformResponse: s,
@@ -1589,128 +1589,128 @@ function W(t, e) {
1589
1589
  socketPath: s,
1590
1590
  responseEncoding: s,
1591
1591
  validateStatus: a,
1592
- headers: (u, l, f) => o(pt(u), pt(l), f, !0)
1592
+ headers: (l, u, f) => i(ht(l), ht(u), f, !0)
1593
1593
  };
1594
- return d.forEach(Object.keys({ ...t, ...e }), function(l) {
1595
- const f = c[l] || o, h = f(t[l], e[l], l);
1596
- d.isUndefined(h) && f !== a || (r[l] = h);
1597
- }), r;
1594
+ return d.forEach(Object.keys({ ...t, ...e }), function(u) {
1595
+ const f = c[u] || i, h = f(t[u], e[u], u);
1596
+ d.isUndefined(h) && f !== a || (n[u] = h);
1597
+ }), n;
1598
1598
  }
1599
- const an = (t) => {
1599
+ const tn = (t) => {
1600
1600
  const e = W({}, t);
1601
- let { data: r, withXSRFToken: n, xsrfHeaderName: o, xsrfCookieName: i, headers: s, auth: a } = e;
1602
- if (e.headers = s = R.from(s), e.url = en(sn(e.baseURL, e.url, e.allowAbsoluteUrls), t.params, t.paramsSerializer), a && s.set(
1601
+ let { data: n, withXSRFToken: r, xsrfHeaderName: i, xsrfCookieName: o, headers: s, auth: a } = e;
1602
+ if (e.headers = s = R.from(s), e.url = Jt(en(e.baseURL, e.url, e.allowAbsoluteUrls), t.params, t.paramsSerializer), a && s.set(
1603
1603
  "Authorization",
1604
1604
  "Basic " + btoa((a.username || "") + ":" + (a.password ? unescape(encodeURIComponent(a.password)) : ""))
1605
- ), d.isFormData(r)) {
1605
+ ), d.isFormData(n)) {
1606
1606
  if (E.hasStandardBrowserEnv || E.hasStandardBrowserWebWorkerEnv)
1607
1607
  s.setContentType(void 0);
1608
- else if (d.isFunction(r.getHeaders)) {
1609
- const c = r.getHeaders(), u = ["content-type", "content-length"];
1610
- Object.entries(c).forEach(([l, f]) => {
1611
- u.includes(l.toLowerCase()) && s.set(l, f);
1608
+ else if (d.isFunction(n.getHeaders)) {
1609
+ const c = n.getHeaders(), l = ["content-type", "content-length"];
1610
+ Object.entries(c).forEach(([u, f]) => {
1611
+ l.includes(u.toLowerCase()) && s.set(u, f);
1612
1612
  });
1613
1613
  }
1614
1614
  }
1615
- if (E.hasStandardBrowserEnv && (n && d.isFunction(n) && (n = n(e)), n || n !== !1 && Kr(e.url))) {
1616
- const c = o && i && Xr.read(i);
1617
- c && s.set(o, c);
1615
+ if (E.hasStandardBrowserEnv && (r && d.isFunction(r) && (r = r(e)), r || r !== !1 && Kr(e.url))) {
1616
+ const c = i && o && Jr.read(o);
1617
+ c && s.set(i, c);
1618
1618
  }
1619
1619
  return e;
1620
- }, Zr = typeof XMLHttpRequest < "u", eo = Zr && function(t) {
1621
- return new Promise(function(r, n) {
1622
- const o = an(t);
1623
- let i = o.data;
1624
- const s = R.from(o.headers).normalize();
1625
- let { responseType: a, onUploadProgress: c, onDownloadProgress: u } = o, l, f, h, g, p;
1620
+ }, Yr = typeof XMLHttpRequest < "u", Zr = Yr && function(t) {
1621
+ return new Promise(function(n, r) {
1622
+ const i = tn(t);
1623
+ let o = i.data;
1624
+ const s = R.from(i.headers).normalize();
1625
+ let { responseType: a, onUploadProgress: c, onDownloadProgress: l } = i, u, f, h, g, p;
1626
1626
  function y() {
1627
- g && g(), p && p(), o.cancelToken && o.cancelToken.unsubscribe(l), o.signal && o.signal.removeEventListener("abort", l);
1627
+ g && g(), p && p(), i.cancelToken && i.cancelToken.unsubscribe(u), i.signal && i.signal.removeEventListener("abort", u);
1628
1628
  }
1629
1629
  let m = new XMLHttpRequest();
1630
- m.open(o.method.toUpperCase(), o.url, !0), m.timeout = o.timeout;
1630
+ m.open(i.method.toUpperCase(), i.url, !0), m.timeout = i.timeout;
1631
1631
  function w() {
1632
1632
  if (!m)
1633
1633
  return;
1634
- const v = R.from(
1634
+ const A = R.from(
1635
1635
  "getAllResponseHeaders" in m && m.getAllResponseHeaders()
1636
- ), _ = {
1636
+ ), x = {
1637
1637
  data: !a || a === "text" || a === "json" ? m.responseText : m.response,
1638
1638
  status: m.status,
1639
1639
  statusText: m.statusText,
1640
- headers: v,
1640
+ headers: A,
1641
1641
  config: t,
1642
1642
  request: m
1643
1643
  };
1644
- on(function(k) {
1645
- r(k), y();
1646
- }, function(k) {
1647
- n(k), y();
1648
- }, _), m = null;
1644
+ Zt(function(N) {
1645
+ n(N), y();
1646
+ }, function(N) {
1647
+ r(N), y();
1648
+ }, x), m = null;
1649
1649
  }
1650
1650
  "onloadend" in m ? m.onloadend = w : m.onreadystatechange = function() {
1651
1651
  !m || m.readyState !== 4 || m.status === 0 && !(m.responseURL && m.responseURL.indexOf("file:") === 0) || setTimeout(w);
1652
1652
  }, m.onabort = function() {
1653
- m && (n(new b("Request aborted", b.ECONNABORTED, t, m)), m = null);
1653
+ m && (r(new b("Request aborted", b.ECONNABORTED, t, m)), m = null);
1654
1654
  }, m.onerror = function(T) {
1655
- const _ = T && T.message ? T.message : "Network Error", $ = new b(_, b.ERR_NETWORK, t, m);
1656
- $.event = T || null, n($), m = null;
1655
+ const x = T && T.message ? T.message : "Network Error", $ = new b(x, b.ERR_NETWORK, t, m);
1656
+ $.event = T || null, r($), m = null;
1657
1657
  }, m.ontimeout = function() {
1658
- let T = o.timeout ? "timeout of " + o.timeout + "ms exceeded" : "timeout exceeded";
1659
- const _ = o.transitional || tn;
1660
- o.timeoutErrorMessage && (T = o.timeoutErrorMessage), n(new b(
1658
+ let T = i.timeout ? "timeout of " + i.timeout + "ms exceeded" : "timeout exceeded";
1659
+ const x = i.transitional || Gt;
1660
+ i.timeoutErrorMessage && (T = i.timeoutErrorMessage), r(new b(
1661
1661
  T,
1662
- _.clarifyTimeoutError ? b.ETIMEDOUT : b.ECONNABORTED,
1662
+ x.clarifyTimeoutError ? b.ETIMEDOUT : b.ECONNABORTED,
1663
1663
  t,
1664
1664
  m
1665
1665
  )), m = null;
1666
- }, i === void 0 && s.setContentType(null), "setRequestHeader" in m && d.forEach(s.toJSON(), function(T, _) {
1667
- m.setRequestHeader(_, T);
1668
- }), d.isUndefined(o.withCredentials) || (m.withCredentials = !!o.withCredentials), a && a !== "json" && (m.responseType = o.responseType), u && ([h, p] = Ne(u, !0), m.addEventListener("progress", h)), c && m.upload && ([f, g] = Ne(c), m.upload.addEventListener("progress", f), m.upload.addEventListener("loadend", g)), (o.cancelToken || o.signal) && (l = (v) => {
1669
- m && (n(!v || v.type ? new re(null, t, m) : v), m.abort(), m = null);
1670
- }, o.cancelToken && o.cancelToken.subscribe(l), o.signal && (o.signal.aborted ? l() : o.signal.addEventListener("abort", l)));
1671
- const O = zr(o.url);
1666
+ }, o === void 0 && s.setContentType(null), "setRequestHeader" in m && d.forEach(s.toJSON(), function(T, x) {
1667
+ m.setRequestHeader(x, T);
1668
+ }), d.isUndefined(i.withCredentials) || (m.withCredentials = !!i.withCredentials), a && a !== "json" && (m.responseType = i.responseType), l && ([h, p] = ke(l, !0), m.addEventListener("progress", h)), c && m.upload && ([f, g] = ke(c), m.upload.addEventListener("progress", f), m.upload.addEventListener("loadend", g)), (i.cancelToken || i.signal) && (u = (A) => {
1669
+ m && (r(!A || A.type ? new re(null, t, m) : A), m.abort(), m = null);
1670
+ }, i.cancelToken && i.cancelToken.subscribe(u), i.signal && (i.signal.aborted ? u() : i.signal.addEventListener("abort", u)));
1671
+ const O = Wr(i.url);
1672
1672
  if (O && E.protocols.indexOf(O) === -1) {
1673
- n(new b("Unsupported protocol " + O + ":", b.ERR_BAD_REQUEST, t));
1673
+ r(new b("Unsupported protocol " + O + ":", b.ERR_BAD_REQUEST, t));
1674
1674
  return;
1675
1675
  }
1676
- m.send(i || null);
1676
+ m.send(o || null);
1677
1677
  });
1678
- }, to = (t, e) => {
1679
- const { length: r } = t = t ? t.filter(Boolean) : [];
1680
- if (e || r) {
1681
- let n = new AbortController(), o;
1682
- const i = function(u) {
1683
- if (!o) {
1684
- o = !0, a();
1685
- const l = u instanceof Error ? u : this.reason;
1686
- n.abort(l instanceof b ? l : new re(l instanceof Error ? l.message : l));
1678
+ }, ei = (t, e) => {
1679
+ const { length: n } = t = t ? t.filter(Boolean) : [];
1680
+ if (e || n) {
1681
+ let r = new AbortController(), i;
1682
+ const o = function(l) {
1683
+ if (!i) {
1684
+ i = !0, a();
1685
+ const u = l instanceof Error ? l : this.reason;
1686
+ r.abort(u instanceof b ? u : new re(u instanceof Error ? u.message : u));
1687
1687
  }
1688
1688
  };
1689
1689
  let s = e && setTimeout(() => {
1690
- s = null, i(new b(`timeout ${e} of ms exceeded`, b.ETIMEDOUT));
1690
+ s = null, o(new b(`timeout ${e} of ms exceeded`, b.ETIMEDOUT));
1691
1691
  }, e);
1692
1692
  const a = () => {
1693
- t && (s && clearTimeout(s), s = null, t.forEach((u) => {
1694
- u.unsubscribe ? u.unsubscribe(i) : u.removeEventListener("abort", i);
1693
+ t && (s && clearTimeout(s), s = null, t.forEach((l) => {
1694
+ l.unsubscribe ? l.unsubscribe(o) : l.removeEventListener("abort", o);
1695
1695
  }), t = null);
1696
1696
  };
1697
- t.forEach((u) => u.addEventListener("abort", i));
1698
- const { signal: c } = n;
1697
+ t.forEach((l) => l.addEventListener("abort", o));
1698
+ const { signal: c } = r;
1699
1699
  return c.unsubscribe = () => d.asap(a), c;
1700
1700
  }
1701
- }, no = function* (t, e) {
1702
- let r = t.byteLength;
1703
- if (r < e) {
1701
+ }, ti = function* (t, e) {
1702
+ let n = t.byteLength;
1703
+ if (n < e) {
1704
1704
  yield t;
1705
1705
  return;
1706
1706
  }
1707
- let n = 0, o;
1708
- for (; n < r; )
1709
- o = n + e, yield t.slice(n, o), n = o;
1710
- }, ro = async function* (t, e) {
1711
- for await (const r of oo(t))
1712
- yield* no(r, e);
1713
- }, oo = async function* (t) {
1707
+ let r = 0, i;
1708
+ for (; r < n; )
1709
+ i = r + e, yield t.slice(r, i), r = i;
1710
+ }, ni = async function* (t, e) {
1711
+ for await (const n of ri(t))
1712
+ yield* ti(n, e);
1713
+ }, ri = async function* (t) {
1714
1714
  if (t[Symbol.asyncIterator]) {
1715
1715
  yield* t;
1716
1716
  return;
@@ -1718,76 +1718,76 @@ const an = (t) => {
1718
1718
  const e = t.getReader();
1719
1719
  try {
1720
1720
  for (; ; ) {
1721
- const { done: r, value: n } = await e.read();
1722
- if (r)
1721
+ const { done: n, value: r } = await e.read();
1722
+ if (n)
1723
1723
  break;
1724
- yield n;
1724
+ yield r;
1725
1725
  }
1726
1726
  } finally {
1727
1727
  await e.cancel();
1728
1728
  }
1729
- }, mt = (t, e, r, n) => {
1730
- const o = ro(t, e);
1731
- let i = 0, s, a = (c) => {
1732
- s || (s = !0, n && n(c));
1729
+ }, yt = (t, e, n, r) => {
1730
+ const i = ni(t, e);
1731
+ let o = 0, s, a = (c) => {
1732
+ s || (s = !0, r && r(c));
1733
1733
  };
1734
1734
  return new ReadableStream({
1735
1735
  async pull(c) {
1736
1736
  try {
1737
- const { done: u, value: l } = await o.next();
1738
- if (u) {
1737
+ const { done: l, value: u } = await i.next();
1738
+ if (l) {
1739
1739
  a(), c.close();
1740
1740
  return;
1741
1741
  }
1742
- let f = l.byteLength;
1743
- if (r) {
1744
- let h = i += f;
1745
- r(h);
1742
+ let f = u.byteLength;
1743
+ if (n) {
1744
+ let h = o += f;
1745
+ n(h);
1746
1746
  }
1747
- c.enqueue(new Uint8Array(l));
1748
- } catch (u) {
1749
- throw a(u), u;
1747
+ c.enqueue(new Uint8Array(u));
1748
+ } catch (l) {
1749
+ throw a(l), l;
1750
1750
  }
1751
1751
  },
1752
1752
  cancel(c) {
1753
- return a(c), o.return();
1753
+ return a(c), i.return();
1754
1754
  }
1755
1755
  }, {
1756
1756
  highWaterMark: 2
1757
1757
  });
1758
- }, ht = 64 * 1024, { isFunction: ge } = d, io = (({ Request: t, Response: e }) => ({
1758
+ }, gt = 64 * 1024, { isFunction: ge } = d, ii = (({ Request: t, Response: e }) => ({
1759
1759
  Request: t,
1760
1760
  Response: e
1761
1761
  }))(d.global), {
1762
- ReadableStream: yt,
1763
- TextEncoder: gt
1764
- } = d.global, bt = (t, ...e) => {
1762
+ ReadableStream: bt,
1763
+ TextEncoder: wt
1764
+ } = d.global, St = (t, ...e) => {
1765
1765
  try {
1766
1766
  return !!t(...e);
1767
1767
  } catch {
1768
1768
  return !1;
1769
1769
  }
1770
- }, so = (t) => {
1770
+ }, oi = (t) => {
1771
1771
  t = d.merge.call({
1772
1772
  skipUndefined: !0
1773
- }, io, t);
1774
- const { fetch: e, Request: r, Response: n } = t, o = e ? ge(e) : typeof fetch == "function", i = ge(r), s = ge(n);
1775
- if (!o)
1773
+ }, ii, t);
1774
+ const { fetch: e, Request: n, Response: r } = t, i = e ? ge(e) : typeof fetch == "function", o = ge(n), s = ge(r);
1775
+ if (!i)
1776
1776
  return !1;
1777
- const a = o && ge(yt), c = o && (typeof gt == "function" ? /* @__PURE__ */ ((p) => (y) => p.encode(y))(new gt()) : async (p) => new Uint8Array(await new r(p).arrayBuffer())), u = i && a && bt(() => {
1777
+ const a = i && ge(bt), c = i && (typeof wt == "function" ? /* @__PURE__ */ ((p) => (y) => p.encode(y))(new wt()) : async (p) => new Uint8Array(await new n(p).arrayBuffer())), l = o && a && St(() => {
1778
1778
  let p = !1;
1779
- const y = new r(E.origin, {
1780
- body: new yt(),
1779
+ const y = new n(E.origin, {
1780
+ body: new bt(),
1781
1781
  method: "POST",
1782
1782
  get duplex() {
1783
1783
  return p = !0, "half";
1784
1784
  }
1785
1785
  }).headers.has("Content-Type");
1786
1786
  return p && !y;
1787
- }), l = s && a && bt(() => d.isReadableStream(new n("").body)), f = {
1788
- stream: l && ((p) => p.body)
1787
+ }), u = s && a && St(() => d.isReadableStream(new r("").body)), f = {
1788
+ stream: u && ((p) => p.body)
1789
1789
  };
1790
- o && ["text", "arrayBuffer", "blob", "formData", "stream"].forEach((p) => {
1790
+ i && ["text", "arrayBuffer", "blob", "formData", "stream"].forEach((p) => {
1791
1791
  !f[p] && (f[p] = (y, m) => {
1792
1792
  let w = y && y[p];
1793
1793
  if (w)
@@ -1801,7 +1801,7 @@ const an = (t) => {
1801
1801
  if (d.isBlob(p))
1802
1802
  return p.size;
1803
1803
  if (d.isSpecCompliantForm(p))
1804
- return (await new r(E.origin, {
1804
+ return (await new n(E.origin, {
1805
1805
  method: "POST",
1806
1806
  body: p
1807
1807
  }).arrayBuffer()).byteLength;
@@ -1819,107 +1819,107 @@ const an = (t) => {
1819
1819
  method: m,
1820
1820
  data: w,
1821
1821
  signal: O,
1822
- cancelToken: v,
1822
+ cancelToken: A,
1823
1823
  timeout: T,
1824
- onDownloadProgress: _,
1824
+ onDownloadProgress: x,
1825
1825
  onUploadProgress: $,
1826
- responseType: k,
1827
- headers: je,
1826
+ responseType: N,
1827
+ headers: Ie,
1828
1828
  withCredentials: pe = "same-origin",
1829
- fetchOptions: Ze
1830
- } = an(p), et = e || fetch;
1831
- k = k ? (k + "").toLowerCase() : "text";
1832
- let me = to([O, v && v.toAbortSignal()], T), oe = null;
1829
+ fetchOptions: tt
1830
+ } = tn(p), nt = e || fetch;
1831
+ N = N ? (N + "").toLowerCase() : "text";
1832
+ let me = ei([O, A && A.toAbortSignal()], T), ie = null;
1833
1833
  const L = me && me.unsubscribe && (() => {
1834
1834
  me.unsubscribe();
1835
1835
  });
1836
- let tt;
1836
+ let rt;
1837
1837
  try {
1838
- if ($ && u && m !== "get" && m !== "head" && (tt = await g(je, w)) !== 0) {
1839
- let M = new r(y, {
1838
+ if ($ && l && m !== "get" && m !== "head" && (rt = await g(Ie, w)) !== 0) {
1839
+ let j = new n(y, {
1840
1840
  method: "POST",
1841
1841
  body: w,
1842
1842
  duplex: "half"
1843
- }), J;
1844
- if (d.isFormData(w) && (J = M.headers.get("content-type")) && je.setContentType(J), M.body) {
1845
- const [Me, he] = dt(
1846
- tt,
1847
- Ne(ft($))
1843
+ }), z;
1844
+ if (d.isFormData(w) && (z = j.headers.get("content-type")) && Ie.setContentType(z), j.body) {
1845
+ const [Be, he] = pt(
1846
+ rt,
1847
+ ke(mt($))
1848
1848
  );
1849
- w = mt(M.body, ht, Me, he);
1849
+ w = yt(j.body, gt, Be, he);
1850
1850
  }
1851
1851
  }
1852
1852
  d.isString(pe) || (pe = pe ? "include" : "omit");
1853
- const D = i && "credentials" in r.prototype, nt = {
1854
- ...Ze,
1853
+ const D = o && "credentials" in n.prototype, it = {
1854
+ ...tt,
1855
1855
  signal: me,
1856
1856
  method: m.toUpperCase(),
1857
- headers: je.normalize().toJSON(),
1857
+ headers: Ie.normalize().toJSON(),
1858
1858
  body: w,
1859
1859
  duplex: "half",
1860
1860
  credentials: D ? pe : void 0
1861
1861
  };
1862
- oe = i && new r(y, nt);
1863
- let j = await (i ? et(oe, Ze) : et(y, nt));
1864
- const rt = l && (k === "stream" || k === "response");
1865
- if (l && (_ || rt && L)) {
1866
- const M = {};
1867
- ["status", "statusText", "headers"].forEach((ot) => {
1868
- M[ot] = j[ot];
1862
+ ie = o && new n(y, it);
1863
+ let M = await (o ? nt(ie, tt) : nt(y, it));
1864
+ const ot = u && (N === "stream" || N === "response");
1865
+ if (u && (x || ot && L)) {
1866
+ const j = {};
1867
+ ["status", "statusText", "headers"].forEach((st) => {
1868
+ j[st] = M[st];
1869
1869
  });
1870
- const J = d.toFiniteNumber(j.headers.get("content-length")), [Me, he] = _ && dt(
1871
- J,
1872
- Ne(ft(_), !0)
1870
+ const z = d.toFiniteNumber(M.headers.get("content-length")), [Be, he] = x && pt(
1871
+ z,
1872
+ ke(mt(x), !0)
1873
1873
  ) || [];
1874
- j = new n(
1875
- mt(j.body, ht, Me, () => {
1874
+ M = new r(
1875
+ yt(M.body, gt, Be, () => {
1876
1876
  he && he(), L && L();
1877
1877
  }),
1878
- M
1878
+ j
1879
1879
  );
1880
1880
  }
1881
- k = k || "text";
1882
- let bn = await f[d.findKey(f, k) || "text"](j, p);
1883
- return !rt && L && L(), await new Promise((M, J) => {
1884
- on(M, J, {
1885
- data: bn,
1886
- headers: R.from(j.headers),
1887
- status: j.status,
1888
- statusText: j.statusText,
1881
+ N = N || "text";
1882
+ let hn = await f[d.findKey(f, N) || "text"](M, p);
1883
+ return !ot && L && L(), await new Promise((j, z) => {
1884
+ Zt(j, z, {
1885
+ data: hn,
1886
+ headers: R.from(M.headers),
1887
+ status: M.status,
1888
+ statusText: M.statusText,
1889
1889
  config: p,
1890
- request: oe
1890
+ request: ie
1891
1891
  });
1892
1892
  });
1893
1893
  } catch (D) {
1894
1894
  throw L && L(), D && D.name === "TypeError" && /Load failed|fetch/i.test(D.message) ? Object.assign(
1895
- new b("Network Error", b.ERR_NETWORK, p, oe),
1895
+ new b("Network Error", b.ERR_NETWORK, p, ie),
1896
1896
  {
1897
1897
  cause: D.cause || D
1898
1898
  }
1899
- ) : b.from(D, D && D.code, p, oe);
1899
+ ) : b.from(D, D && D.code, p, ie);
1900
1900
  }
1901
1901
  };
1902
- }, ao = /* @__PURE__ */ new Map(), cn = (t) => {
1902
+ }, si = /* @__PURE__ */ new Map(), nn = (t) => {
1903
1903
  let e = t && t.env || {};
1904
- const { fetch: r, Request: n, Response: o } = e, i = [
1905
- n,
1906
- o,
1907
- r
1904
+ const { fetch: n, Request: r, Response: i } = e, o = [
1905
+ r,
1906
+ i,
1907
+ n
1908
1908
  ];
1909
- let s = i.length, a = s, c, u, l = ao;
1909
+ let s = o.length, a = s, c, l, u = si;
1910
1910
  for (; a--; )
1911
- c = i[a], u = l.get(c), u === void 0 && l.set(c, u = a ? /* @__PURE__ */ new Map() : so(e)), l = u;
1912
- return u;
1911
+ c = o[a], l = u.get(c), l === void 0 && u.set(c, l = a ? /* @__PURE__ */ new Map() : oi(e)), u = l;
1912
+ return l;
1913
1913
  };
1914
- cn();
1915
- const Ye = {
1916
- http: Or,
1917
- xhr: eo,
1914
+ nn();
1915
+ const et = {
1916
+ http: Er,
1917
+ xhr: Zr,
1918
1918
  fetch: {
1919
- get: cn
1919
+ get: nn
1920
1920
  }
1921
1921
  };
1922
- d.forEach(Ye, (t, e) => {
1922
+ d.forEach(et, (t, e) => {
1923
1923
  if (t) {
1924
1924
  try {
1925
1925
  Object.defineProperty(t, "name", { value: e });
@@ -1928,123 +1928,123 @@ d.forEach(Ye, (t, e) => {
1928
1928
  Object.defineProperty(t, "adapterName", { value: e });
1929
1929
  }
1930
1930
  });
1931
- const wt = (t) => `- ${t}`, co = (t) => d.isFunction(t) || t === null || t === !1;
1932
- function uo(t, e) {
1931
+ const At = (t) => `- ${t}`, ai = (t) => d.isFunction(t) || t === null || t === !1;
1932
+ function ci(t, e) {
1933
1933
  t = d.isArray(t) ? t : [t];
1934
- const { length: r } = t;
1935
- let n, o;
1936
- const i = {};
1937
- for (let s = 0; s < r; s++) {
1938
- n = t[s];
1934
+ const { length: n } = t;
1935
+ let r, i;
1936
+ const o = {};
1937
+ for (let s = 0; s < n; s++) {
1938
+ r = t[s];
1939
1939
  let a;
1940
- if (o = n, !co(n) && (o = Ye[(a = String(n)).toLowerCase()], o === void 0))
1940
+ if (i = r, !ai(r) && (i = et[(a = String(r)).toLowerCase()], i === void 0))
1941
1941
  throw new b(`Unknown adapter '${a}'`);
1942
- if (o && (d.isFunction(o) || (o = o.get(e))))
1942
+ if (i && (d.isFunction(i) || (i = i.get(e))))
1943
1943
  break;
1944
- i[a || "#" + s] = o;
1944
+ o[a || "#" + s] = i;
1945
1945
  }
1946
- if (!o) {
1947
- const s = Object.entries(i).map(
1948
- ([c, u]) => `adapter ${c} ` + (u === !1 ? "is not supported by the environment" : "is not available in the build")
1946
+ if (!i) {
1947
+ const s = Object.entries(o).map(
1948
+ ([c, l]) => `adapter ${c} ` + (l === !1 ? "is not supported by the environment" : "is not available in the build")
1949
1949
  );
1950
- let a = r ? s.length > 1 ? `since :
1951
- ` + s.map(wt).join(`
1952
- `) : " " + wt(s[0]) : "as no adapter specified";
1950
+ let a = n ? s.length > 1 ? `since :
1951
+ ` + s.map(At).join(`
1952
+ `) : " " + At(s[0]) : "as no adapter specified";
1953
1953
  throw new b(
1954
1954
  "There is no suitable adapter to dispatch the request " + a,
1955
1955
  "ERR_NOT_SUPPORT"
1956
1956
  );
1957
1957
  }
1958
- return o;
1958
+ return i;
1959
1959
  }
1960
- const un = {
1960
+ const rn = {
1961
1961
  /**
1962
1962
  * Resolve an adapter from a list of adapter names or functions.
1963
1963
  * @type {Function}
1964
1964
  */
1965
- getAdapter: uo,
1965
+ getAdapter: ci,
1966
1966
  /**
1967
1967
  * Exposes all known adapters
1968
1968
  * @type {Object<string, Function|Object>}
1969
1969
  */
1970
- adapters: Ye
1970
+ adapters: et
1971
1971
  };
1972
- function Le(t) {
1972
+ function He(t) {
1973
1973
  if (t.cancelToken && t.cancelToken.throwIfRequested(), t.signal && t.signal.aborted)
1974
1974
  throw new re(null, t);
1975
1975
  }
1976
- function St(t) {
1977
- return Le(t), t.headers = R.from(t.headers), t.data = $e.call(
1976
+ function vt(t) {
1977
+ return He(t), t.headers = R.from(t.headers), t.data = Ve.call(
1978
1978
  t,
1979
1979
  t.transformRequest
1980
- ), ["post", "put", "patch"].indexOf(t.method) !== -1 && t.headers.setContentType("application/x-www-form-urlencoded", !1), un.getAdapter(t.adapter || le.adapter, t)(t).then(function(n) {
1981
- return Le(t), n.data = $e.call(
1980
+ ), ["post", "put", "patch"].indexOf(t.method) !== -1 && t.headers.setContentType("application/x-www-form-urlencoded", !1), rn.getAdapter(t.adapter || ue.adapter, t)(t).then(function(r) {
1981
+ return He(t), r.data = Ve.call(
1982
1982
  t,
1983
1983
  t.transformResponse,
1984
- n
1985
- ), n.headers = R.from(n.headers), n;
1986
- }, function(n) {
1987
- return rn(n) || (Le(t), n && n.response && (n.response.data = $e.call(
1984
+ r
1985
+ ), r.headers = R.from(r.headers), r;
1986
+ }, function(r) {
1987
+ return Yt(r) || (He(t), r && r.response && (r.response.data = Ve.call(
1988
1988
  t,
1989
1989
  t.transformResponse,
1990
- n.response
1991
- ), n.response.headers = R.from(n.response.headers))), Promise.reject(n);
1990
+ r.response
1991
+ ), r.response.headers = R.from(r.response.headers))), Promise.reject(r);
1992
1992
  });
1993
1993
  }
1994
- const ln = "1.13.2", xe = {};
1994
+ const on = "1.13.2", De = {};
1995
1995
  ["object", "boolean", "number", "function", "string", "symbol"].forEach((t, e) => {
1996
- xe[t] = function(n) {
1997
- return typeof n === t || "a" + (e < 1 ? "n " : " ") + t;
1996
+ De[t] = function(r) {
1997
+ return typeof r === t || "a" + (e < 1 ? "n " : " ") + t;
1998
1998
  };
1999
1999
  });
2000
- const vt = {};
2001
- xe.transitional = function(e, r, n) {
2002
- function o(i, s) {
2003
- return "[Axios v" + ln + "] Transitional option '" + i + "'" + s + (n ? ". " + n : "");
2000
+ const Et = {};
2001
+ De.transitional = function(e, n, r) {
2002
+ function i(o, s) {
2003
+ return "[Axios v" + on + "] Transitional option '" + o + "'" + s + (r ? ". " + r : "");
2004
2004
  }
2005
- return (i, s, a) => {
2005
+ return (o, s, a) => {
2006
2006
  if (e === !1)
2007
2007
  throw new b(
2008
- o(s, " has been removed" + (r ? " in " + r : "")),
2008
+ i(s, " has been removed" + (n ? " in " + n : "")),
2009
2009
  b.ERR_DEPRECATED
2010
2010
  );
2011
- return r && !vt[s] && (vt[s] = !0, console.warn(
2012
- o(
2011
+ return n && !Et[s] && (Et[s] = !0, console.warn(
2012
+ i(
2013
2013
  s,
2014
- " has been deprecated since v" + r + " and will be removed in the near future"
2014
+ " has been deprecated since v" + n + " and will be removed in the near future"
2015
2015
  )
2016
- )), e ? e(i, s, a) : !0;
2016
+ )), e ? e(o, s, a) : !0;
2017
2017
  };
2018
2018
  };
2019
- xe.spelling = function(e) {
2020
- return (r, n) => (console.warn(`${n} is likely a misspelling of ${e}`), !0);
2019
+ De.spelling = function(e) {
2020
+ return (n, r) => (console.warn(`${r} is likely a misspelling of ${e}`), !0);
2021
2021
  };
2022
- function lo(t, e, r) {
2022
+ function li(t, e, n) {
2023
2023
  if (typeof t != "object")
2024
2024
  throw new b("options must be an object", b.ERR_BAD_OPTION_VALUE);
2025
- const n = Object.keys(t);
2026
- let o = n.length;
2027
- for (; o-- > 0; ) {
2028
- const i = n[o], s = e[i];
2025
+ const r = Object.keys(t);
2026
+ let i = r.length;
2027
+ for (; i-- > 0; ) {
2028
+ const o = r[i], s = e[o];
2029
2029
  if (s) {
2030
- const a = t[i], c = a === void 0 || s(a, i, t);
2030
+ const a = t[o], c = a === void 0 || s(a, o, t);
2031
2031
  if (c !== !0)
2032
- throw new b("option " + i + " must be " + c, b.ERR_BAD_OPTION_VALUE);
2032
+ throw new b("option " + o + " must be " + c, b.ERR_BAD_OPTION_VALUE);
2033
2033
  continue;
2034
2034
  }
2035
- if (r !== !0)
2036
- throw new b("Unknown option " + i, b.ERR_BAD_OPTION);
2035
+ if (n !== !0)
2036
+ throw new b("Unknown option " + o, b.ERR_BAD_OPTION);
2037
2037
  }
2038
2038
  }
2039
2039
  const Te = {
2040
- assertOptions: lo,
2041
- validators: xe
2042
- }, F = Te.validators;
2040
+ assertOptions: li,
2041
+ validators: De
2042
+ }, q = Te.validators;
2043
2043
  let H = class {
2044
2044
  constructor(e) {
2045
2045
  this.defaults = e || {}, this.interceptors = {
2046
- request: new ut(),
2047
- response: new ut()
2046
+ request: new dt(),
2047
+ response: new dt()
2048
2048
  };
2049
2049
  }
2050
2050
  /**
@@ -2055,67 +2055,67 @@ let H = class {
2055
2055
  *
2056
2056
  * @returns {Promise} The Promise to be fulfilled
2057
2057
  */
2058
- async request(e, r) {
2058
+ async request(e, n) {
2059
2059
  try {
2060
- return await this._request(e, r);
2061
- } catch (n) {
2062
- if (n instanceof Error) {
2063
- let o = {};
2064
- Error.captureStackTrace ? Error.captureStackTrace(o) : o = new Error();
2065
- const i = o.stack ? o.stack.replace(/^.+\n/, "") : "";
2060
+ return await this._request(e, n);
2061
+ } catch (r) {
2062
+ if (r instanceof Error) {
2063
+ let i = {};
2064
+ Error.captureStackTrace ? Error.captureStackTrace(i) : i = new Error();
2065
+ const o = i.stack ? i.stack.replace(/^.+\n/, "") : "";
2066
2066
  try {
2067
- n.stack ? i && !String(n.stack).endsWith(i.replace(/^.+\n.+\n/, "")) && (n.stack += `
2068
- ` + i) : n.stack = i;
2067
+ r.stack ? o && !String(r.stack).endsWith(o.replace(/^.+\n.+\n/, "")) && (r.stack += `
2068
+ ` + o) : r.stack = o;
2069
2069
  } catch {
2070
2070
  }
2071
2071
  }
2072
- throw n;
2072
+ throw r;
2073
2073
  }
2074
2074
  }
2075
- _request(e, r) {
2076
- typeof e == "string" ? (r = r || {}, r.url = e) : r = e || {}, r = W(this.defaults, r);
2077
- const { transitional: n, paramsSerializer: o, headers: i } = r;
2078
- n !== void 0 && Te.assertOptions(n, {
2079
- silentJSONParsing: F.transitional(F.boolean),
2080
- forcedJSONParsing: F.transitional(F.boolean),
2081
- clarifyTimeoutError: F.transitional(F.boolean)
2082
- }, !1), o != null && (d.isFunction(o) ? r.paramsSerializer = {
2083
- serialize: o
2084
- } : Te.assertOptions(o, {
2085
- encode: F.function,
2086
- serialize: F.function
2087
- }, !0)), r.allowAbsoluteUrls !== void 0 || (this.defaults.allowAbsoluteUrls !== void 0 ? r.allowAbsoluteUrls = this.defaults.allowAbsoluteUrls : r.allowAbsoluteUrls = !0), Te.assertOptions(r, {
2088
- baseUrl: F.spelling("baseURL"),
2089
- withXsrfToken: F.spelling("withXSRFToken")
2090
- }, !0), r.method = (r.method || this.defaults.method || "get").toLowerCase();
2091
- let s = i && d.merge(
2092
- i.common,
2093
- i[r.method]
2075
+ _request(e, n) {
2076
+ typeof e == "string" ? (n = n || {}, n.url = e) : n = e || {}, n = W(this.defaults, n);
2077
+ const { transitional: r, paramsSerializer: i, headers: o } = n;
2078
+ r !== void 0 && Te.assertOptions(r, {
2079
+ silentJSONParsing: q.transitional(q.boolean),
2080
+ forcedJSONParsing: q.transitional(q.boolean),
2081
+ clarifyTimeoutError: q.transitional(q.boolean)
2082
+ }, !1), i != null && (d.isFunction(i) ? n.paramsSerializer = {
2083
+ serialize: i
2084
+ } : Te.assertOptions(i, {
2085
+ encode: q.function,
2086
+ serialize: q.function
2087
+ }, !0)), n.allowAbsoluteUrls !== void 0 || (this.defaults.allowAbsoluteUrls !== void 0 ? n.allowAbsoluteUrls = this.defaults.allowAbsoluteUrls : n.allowAbsoluteUrls = !0), Te.assertOptions(n, {
2088
+ baseUrl: q.spelling("baseURL"),
2089
+ withXsrfToken: q.spelling("withXSRFToken")
2090
+ }, !0), n.method = (n.method || this.defaults.method || "get").toLowerCase();
2091
+ let s = o && d.merge(
2092
+ o.common,
2093
+ o[n.method]
2094
2094
  );
2095
- i && d.forEach(
2095
+ o && d.forEach(
2096
2096
  ["delete", "get", "head", "post", "put", "patch", "common"],
2097
2097
  (p) => {
2098
- delete i[p];
2098
+ delete o[p];
2099
2099
  }
2100
- ), r.headers = R.concat(s, i);
2100
+ ), n.headers = R.concat(s, o);
2101
2101
  const a = [];
2102
2102
  let c = !0;
2103
2103
  this.interceptors.request.forEach(function(y) {
2104
- typeof y.runWhen == "function" && y.runWhen(r) === !1 || (c = c && y.synchronous, a.unshift(y.fulfilled, y.rejected));
2104
+ typeof y.runWhen == "function" && y.runWhen(n) === !1 || (c = c && y.synchronous, a.unshift(y.fulfilled, y.rejected));
2105
2105
  });
2106
- const u = [];
2106
+ const l = [];
2107
2107
  this.interceptors.response.forEach(function(y) {
2108
- u.push(y.fulfilled, y.rejected);
2108
+ l.push(y.fulfilled, y.rejected);
2109
2109
  });
2110
- let l, f = 0, h;
2110
+ let u, f = 0, h;
2111
2111
  if (!c) {
2112
- const p = [St.bind(this), void 0];
2113
- for (p.unshift(...a), p.push(...u), h = p.length, l = Promise.resolve(r); f < h; )
2114
- l = l.then(p[f++], p[f++]);
2115
- return l;
2112
+ const p = [vt.bind(this), void 0];
2113
+ for (p.unshift(...a), p.push(...l), h = p.length, u = Promise.resolve(n); f < h; )
2114
+ u = u.then(p[f++], p[f++]);
2115
+ return u;
2116
2116
  }
2117
2117
  h = a.length;
2118
- let g = r;
2118
+ let g = n;
2119
2119
  for (; f < h; ) {
2120
2120
  const p = a[f++], y = a[f++];
2121
2121
  try {
@@ -2126,69 +2126,69 @@ let H = class {
2126
2126
  }
2127
2127
  }
2128
2128
  try {
2129
- l = St.call(this, g);
2129
+ u = vt.call(this, g);
2130
2130
  } catch (p) {
2131
2131
  return Promise.reject(p);
2132
2132
  }
2133
- for (f = 0, h = u.length; f < h; )
2134
- l = l.then(u[f++], u[f++]);
2135
- return l;
2133
+ for (f = 0, h = l.length; f < h; )
2134
+ u = u.then(l[f++], l[f++]);
2135
+ return u;
2136
2136
  }
2137
2137
  getUri(e) {
2138
2138
  e = W(this.defaults, e);
2139
- const r = sn(e.baseURL, e.url, e.allowAbsoluteUrls);
2140
- return en(r, e.params, e.paramsSerializer);
2139
+ const n = en(e.baseURL, e.url, e.allowAbsoluteUrls);
2140
+ return Jt(n, e.params, e.paramsSerializer);
2141
2141
  }
2142
2142
  };
2143
2143
  d.forEach(["delete", "get", "head", "options"], function(e) {
2144
- H.prototype[e] = function(r, n) {
2145
- return this.request(W(n || {}, {
2144
+ H.prototype[e] = function(n, r) {
2145
+ return this.request(W(r || {}, {
2146
2146
  method: e,
2147
- url: r,
2148
- data: (n || {}).data
2147
+ url: n,
2148
+ data: (r || {}).data
2149
2149
  }));
2150
2150
  };
2151
2151
  });
2152
2152
  d.forEach(["post", "put", "patch"], function(e) {
2153
- function r(n) {
2154
- return function(i, s, a) {
2153
+ function n(r) {
2154
+ return function(o, s, a) {
2155
2155
  return this.request(W(a || {}, {
2156
2156
  method: e,
2157
- headers: n ? {
2157
+ headers: r ? {
2158
2158
  "Content-Type": "multipart/form-data"
2159
2159
  } : {},
2160
- url: i,
2160
+ url: o,
2161
2161
  data: s
2162
2162
  }));
2163
2163
  };
2164
2164
  }
2165
- H.prototype[e] = r(), H.prototype[e + "Form"] = r(!0);
2165
+ H.prototype[e] = n(), H.prototype[e + "Form"] = n(!0);
2166
2166
  });
2167
- let fo = class dn {
2167
+ let ui = class sn {
2168
2168
  constructor(e) {
2169
2169
  if (typeof e != "function")
2170
2170
  throw new TypeError("executor must be a function.");
2171
- let r;
2172
- this.promise = new Promise(function(i) {
2173
- r = i;
2171
+ let n;
2172
+ this.promise = new Promise(function(o) {
2173
+ n = o;
2174
2174
  });
2175
- const n = this;
2176
- this.promise.then((o) => {
2177
- if (!n._listeners) return;
2178
- let i = n._listeners.length;
2179
- for (; i-- > 0; )
2180
- n._listeners[i](o);
2181
- n._listeners = null;
2182
- }), this.promise.then = (o) => {
2183
- let i;
2175
+ const r = this;
2176
+ this.promise.then((i) => {
2177
+ if (!r._listeners) return;
2178
+ let o = r._listeners.length;
2179
+ for (; o-- > 0; )
2180
+ r._listeners[o](i);
2181
+ r._listeners = null;
2182
+ }), this.promise.then = (i) => {
2183
+ let o;
2184
2184
  const s = new Promise((a) => {
2185
- n.subscribe(a), i = a;
2186
- }).then(o);
2185
+ r.subscribe(a), o = a;
2186
+ }).then(i);
2187
2187
  return s.cancel = function() {
2188
- n.unsubscribe(i);
2188
+ r.unsubscribe(o);
2189
2189
  }, s;
2190
- }, e(function(i, s, a) {
2191
- n.reason || (n.reason = new re(i, s, a), r(n.reason));
2190
+ }, e(function(o, s, a) {
2191
+ r.reason || (r.reason = new re(o, s, a), n(r.reason));
2192
2192
  });
2193
2193
  }
2194
2194
  /**
@@ -2214,14 +2214,14 @@ let fo = class dn {
2214
2214
  unsubscribe(e) {
2215
2215
  if (!this._listeners)
2216
2216
  return;
2217
- const r = this._listeners.indexOf(e);
2218
- r !== -1 && this._listeners.splice(r, 1);
2217
+ const n = this._listeners.indexOf(e);
2218
+ n !== -1 && this._listeners.splice(n, 1);
2219
2219
  }
2220
2220
  toAbortSignal() {
2221
- const e = new AbortController(), r = (n) => {
2222
- e.abort(n);
2221
+ const e = new AbortController(), n = (r) => {
2222
+ e.abort(r);
2223
2223
  };
2224
- return this.subscribe(r), e.signal.unsubscribe = () => this.unsubscribe(r), e.signal;
2224
+ return this.subscribe(n), e.signal.unsubscribe = () => this.unsubscribe(n), e.signal;
2225
2225
  }
2226
2226
  /**
2227
2227
  * Returns an object that contains a new `CancelToken` and a function that, when called,
@@ -2230,19 +2230,19 @@ let fo = class dn {
2230
2230
  static source() {
2231
2231
  let e;
2232
2232
  return {
2233
- token: new dn(function(o) {
2234
- e = o;
2233
+ token: new sn(function(i) {
2234
+ e = i;
2235
2235
  }),
2236
2236
  cancel: e
2237
2237
  };
2238
2238
  }
2239
2239
  };
2240
- function po(t) {
2241
- return function(r) {
2242
- return t.apply(null, r);
2240
+ function di(t) {
2241
+ return function(n) {
2242
+ return t.apply(null, n);
2243
2243
  };
2244
2244
  }
2245
- function mo(t) {
2245
+ function fi(t) {
2246
2246
  return d.isObject(t) && t.isAxiosError === !0;
2247
2247
  }
2248
2248
  const Je = {
@@ -2319,52 +2319,145 @@ const Je = {
2319
2319
  Object.entries(Je).forEach(([t, e]) => {
2320
2320
  Je[e] = t;
2321
2321
  });
2322
- function fn(t) {
2323
- const e = new H(t), r = Lt(H.prototype.request, e);
2324
- return d.extend(r, H.prototype, e, { allOwnKeys: !0 }), d.extend(r, e, null, { allOwnKeys: !0 }), r.create = function(o) {
2325
- return fn(W(t, o));
2326
- }, r;
2322
+ function an(t) {
2323
+ const e = new H(t), n = jt(H.prototype.request, e);
2324
+ return d.extend(n, H.prototype, e, { allOwnKeys: !0 }), d.extend(n, e, null, { allOwnKeys: !0 }), n.create = function(i) {
2325
+ return an(W(t, i));
2326
+ }, n;
2327
2327
  }
2328
- const S = fn(le);
2328
+ const S = an(ue);
2329
2329
  S.Axios = H;
2330
2330
  S.CanceledError = re;
2331
- S.CancelToken = fo;
2332
- S.isCancel = rn;
2333
- S.VERSION = ln;
2334
- S.toFormData = Ce;
2331
+ S.CancelToken = ui;
2332
+ S.isCancel = Yt;
2333
+ S.VERSION = on;
2334
+ S.toFormData = Pe;
2335
2335
  S.AxiosError = b;
2336
2336
  S.Cancel = S.CanceledError;
2337
2337
  S.all = function(e) {
2338
2338
  return Promise.all(e);
2339
2339
  };
2340
- S.spread = po;
2341
- S.isAxiosError = mo;
2340
+ S.spread = di;
2341
+ S.isAxiosError = fi;
2342
2342
  S.mergeConfig = W;
2343
2343
  S.AxiosHeaders = R;
2344
- S.formToJSON = (t) => nn(d.isHTMLForm(t) ? new FormData(t) : t);
2345
- S.getAdapter = un.getAdapter;
2344
+ S.formToJSON = (t) => Xt(d.isHTMLForm(t) ? new FormData(t) : t);
2345
+ S.getAdapter = rn.getAdapter;
2346
2346
  S.HttpStatusCode = Je;
2347
2347
  S.default = S;
2348
2348
  const {
2349
- Axios: Xo,
2350
- AxiosError: At,
2351
- CanceledError: Go,
2352
- isCancel: Yo,
2353
- CancelToken: Zo,
2354
- VERSION: ei,
2355
- all: ti,
2356
- Cancel: ni,
2357
- isAxiosError: ri,
2358
- spread: oi,
2359
- toFormData: ii,
2360
- AxiosHeaders: si,
2361
- HttpStatusCode: ai,
2362
- formToJSON: ci,
2363
- getAdapter: ui,
2364
- mergeConfig: li
2365
- } = S, ho = (t) => Qe.some(t, (e) => e && e.errorCode !== void 0) || t?.errorCode !== void 0;
2366
- function Et() {
2367
- return new Ut({
2349
+ Axios: Hi,
2350
+ AxiosError: Ot,
2351
+ CanceledError: Wi,
2352
+ isCancel: Qi,
2353
+ CancelToken: zi,
2354
+ VERSION: Ki,
2355
+ all: Ji,
2356
+ Cancel: Gi,
2357
+ isAxiosError: Xi,
2358
+ spread: Yi,
2359
+ toFormData: Zi,
2360
+ AxiosHeaders: eo,
2361
+ HttpStatusCode: to,
2362
+ formToJSON: no,
2363
+ getAdapter: ro,
2364
+ mergeConfig: io
2365
+ } = S, pi = (t) => Ge.some(t, (e) => e && e.errorCode !== void 0) || t?.errorCode !== void 0, Tt = typeof window < "u";
2366
+ class cn {
2367
+ constructor(e = {}) {
2368
+ this.requestStrategy = async (n, r) => {
2369
+ await r(n);
2370
+ }, this.responseStrategy = async (n, r) => {
2371
+ await r(n);
2372
+ }, this.defaultBaseUrl = e.defaultBaseUrl, this.useGlobalSingletons = e.useGlobalSingletons ?? !1, this.globalQueryClientKey = e.globalQueryClientKey || "__STORE_QUERY_CLIENT__", this.globalAxiosKey = e.globalAxiosKey || "__STORE_API_CLIENT__", this.createQueryClientImpl = e.createQueryClient || (() => new Re({
2373
+ defaultOptions: {
2374
+ queries: {
2375
+ refetchOnWindowFocus: !0,
2376
+ refetchOnMount: !1,
2377
+ retry: 3,
2378
+ staleTime: 1e3 * 60 * 5
2379
+ }
2380
+ }
2381
+ })), this.createAxiosImpl = e.createAxios || ((n) => {
2382
+ const r = S.create({
2383
+ baseURL: n || this.defaultBaseUrl,
2384
+ withCredentials: !0
2385
+ });
2386
+ return this.configureAxios(r);
2387
+ });
2388
+ }
2389
+ getQueryClient(e) {
2390
+ if (Tt) {
2391
+ if (e?.client) return e.client;
2392
+ if (this.useGlobalSingletons) {
2393
+ const n = globalThis, r = n[this.globalQueryClientKey];
2394
+ if (r)
2395
+ return r;
2396
+ const i = this.createQueryClientImpl();
2397
+ return n[this.globalQueryClientKey] = i, i;
2398
+ }
2399
+ return this.queryClientSingleton || (this.queryClientSingleton = this.createQueryClientImpl()), this.queryClientSingleton;
2400
+ }
2401
+ return this.createQueryClientImpl();
2402
+ }
2403
+ getAxiosInstance() {
2404
+ if (Tt) {
2405
+ if (this.useGlobalSingletons) {
2406
+ const e = globalThis, n = e[this.globalAxiosKey];
2407
+ if (n)
2408
+ return n;
2409
+ const r = this.configureAxios(this.createAxiosImpl());
2410
+ return e[this.globalAxiosKey] = r, r;
2411
+ }
2412
+ return this.axiosSingleton || (this.axiosSingleton = this.configureAxios(this.createAxiosImpl())), this.axiosSingleton;
2413
+ }
2414
+ return this.configureAxios(this.createAxiosImpl());
2415
+ }
2416
+ setDefaultApiBaseUrl(e) {
2417
+ this.defaultBaseUrl = e;
2418
+ }
2419
+ async setApiUrl(e) {
2420
+ const n = this.getAxiosInstance();
2421
+ n.defaults.baseURL = e;
2422
+ }
2423
+ setRequestInterceptorStrategy(e) {
2424
+ this.requestStrategy = e, this.axiosSingleton && (this.axiosSingleton = this.configureAxios(this.axiosSingleton));
2425
+ }
2426
+ setResponseInterceptorStrategy(e) {
2427
+ this.responseStrategy = e, this.axiosSingleton && (this.axiosSingleton = this.configureAxios(this.axiosSingleton));
2428
+ }
2429
+ getAxiosProxy() {
2430
+ return new Proxy({}, {
2431
+ get: (e, n) => {
2432
+ const r = this.getAxiosInstance(), i = Reflect.get(r, n);
2433
+ return typeof i == "function" ? i.bind(r) : i;
2434
+ },
2435
+ set: (e, n, r) => Reflect.set(this.getAxiosInstance(), n, r)
2436
+ });
2437
+ }
2438
+ getQueryClientProxy() {
2439
+ return new Proxy({}, {
2440
+ get: (e, n) => {
2441
+ const r = this.getQueryClient(), i = Reflect.get(r, n);
2442
+ return typeof i == "function" ? i.bind(r) : i;
2443
+ },
2444
+ set: (e, n, r) => Reflect.set(this.getQueryClient(), n, r)
2445
+ });
2446
+ }
2447
+ configureAxios(e) {
2448
+ return e.interceptors.request.clear(), e.interceptors.response.clear(), e.interceptors.request.use(async (n) => {
2449
+ const r = async (i) => {
2450
+ };
2451
+ return await this.requestStrategy(n, r), n;
2452
+ }), e.interceptors.response.use(async (n) => {
2453
+ const r = async (i) => {
2454
+ };
2455
+ return await this.responseStrategy(n, r), n;
2456
+ }), e;
2457
+ }
2458
+ }
2459
+ const ln = "auth_token", mi = "lang", hi = "currencyCode", qe = new cn({
2460
+ createQueryClient: () => new Re({
2368
2461
  defaultOptions: {
2369
2462
  queries: {
2370
2463
  refetchOnWindowFocus: !0,
@@ -2373,65 +2466,39 @@ function Et() {
2373
2466
  staleTime: 1e3 * 60 * 5
2374
2467
  }
2375
2468
  }
2376
- });
2377
- }
2378
- function Ot(t) {
2379
- return pn ? (globalThis.__STORE_QUERY_CLIENT__ || (globalThis.__STORE_QUERY_CLIENT__ = Et()), globalThis.__STORE_QUERY_CLIENT__) : Et();
2380
- }
2381
- const pn = typeof window < "u";
2382
- let yo;
2383
- const Tt = "auth_token", go = "lang", bo = "currencyCode";
2384
- let wo = async (t, e) => {
2385
- await e(t);
2386
- };
2387
- function So(t) {
2388
- return t.interceptors.request.use(async (e) => (await wo(e, async (n) => {
2389
- const o = await B.getItem(Tt), i = await B.getItem("channelToken"), s = await B.getItem(bo), a = await B.getItem(go);
2390
- o && (n.headers.Authorization = `Bearer ${o}`), i && (n.headers["vendure-token"] = i), n.params = n.params || {}, s && (n.params.currencyCode = s), a && (n.params.languageCode = a);
2391
- }), e)), t.interceptors.response.use(async (e) => (await vo(e, async (n) => {
2392
- const o = n.headers["vendure-auth-token"];
2393
- if (o && B.setItem(Tt, o), ho(n.data.data)) {
2394
- const i = Object.values(n.data.data)[0], s = new At(i.errorCode);
2395
- return s.response = n, s.request = n.request, s.config = n.config, Promise.reject(s);
2396
- }
2397
- if (n.data.errors?.length > 0) {
2398
- const i = n.data.errors[0], s = new At(i.message);
2399
- return s.response = n, s.request = n.request, s.config = n.config, Promise.reject(s);
2400
- }
2401
- }), e), (e) => ($t.error("Axios error", "vendure/axiosClient", e), Promise.reject(e))), t;
2402
- }
2403
- function Nt(t) {
2404
- const e = S.create({
2405
- baseURL: yo,
2469
+ }),
2470
+ createAxios: (t) => S.create({
2471
+ baseURL: t,
2406
2472
  withCredentials: !0,
2407
2473
  headers: {
2408
2474
  "vendure-token": ""
2409
2475
  }
2410
- });
2411
- return So(e);
2412
- }
2413
- function Rt() {
2414
- return pn ? (globalThis.__STORE_API_CLIENT__ || (globalThis.__STORE_API_CLIENT__ = Nt()), globalThis.__STORE_API_CLIENT__) : Nt();
2415
- }
2416
- let vo = async (t, e) => {
2417
- await e(t);
2418
- };
2419
- new Proxy({}, {
2420
- get: (t, e) => {
2421
- const r = Rt(), n = Reflect.get(r, e);
2422
- return typeof n == "function" ? n.bind(r) : n;
2423
- },
2424
- set: (t, e, r) => Reflect.set(Rt(), e, r)
2476
+ }),
2477
+ // Preserve cross-tree sharing behavior (e.g., WordPress blocks with separate trees)
2478
+ useGlobalSingletons: !0,
2479
+ globalQueryClientKey: "__STORE_QUERY_CLIENT__",
2480
+ globalAxiosKey: "__STORE_API_CLIENT__"
2425
2481
  });
2426
- new Proxy({}, {
2427
- get: (t, e) => {
2428
- const r = Ot(), n = Reflect.get(r, e);
2429
- return typeof n == "function" ? n.bind(r) : n;
2430
- },
2431
- set: (t, e, r) => Reflect.set(Ot(), e, r)
2482
+ qe.setRequestInterceptorStrategy(async (t, e) => {
2483
+ const n = await I.getItem(ln), r = await I.getItem("channelToken"), i = await I.getItem(hi), o = await I.getItem(mi);
2484
+ n && (t.headers.Authorization = `Bearer ${n}`), r && (t.headers["vendure-token"] = r), t.params = t.params || {}, i && (t.params.currencyCode = i), o && (t.params.languageCode = o), await e(t);
2432
2485
  });
2433
- const Ao = globalThis.__STORE_SDK_CONTEXT__ ||= It(void 0), Eo = () => {
2434
- const e = vn(Ao)?.sdk;
2486
+ qe.setResponseInterceptorStrategy(async (t, e) => {
2487
+ const n = t.headers["vendure-auth-token"];
2488
+ if (n && I.setItem(ln, n), pi(t.data.data)) {
2489
+ const r = Object.values(t.data.data)[0], i = new Ot(r.errorCode);
2490
+ return i.response = t, i.config = t.config, Promise.reject(i);
2491
+ }
2492
+ if (t.data.errors?.length > 0) {
2493
+ const r = t.data.errors[0], i = new Ot(r.message);
2494
+ return i.response = t, i.config = t.config, Promise.reject(i);
2495
+ }
2496
+ await e(t);
2497
+ });
2498
+ qe.getAxiosProxy();
2499
+ qe.getQueryClientProxy();
2500
+ const yi = globalThis.__STORE_SDK_CONTEXT__ ||= bn(void 0), gi = () => {
2501
+ const e = wn(yi)?.sdk;
2435
2502
  return e || console.error("You must wrap your component in a <DataProvider>"), e?.sdkType === "dummy" || e?.sdkType === "vendure", e;
2436
2503
  };
2437
2504
  var C = {}, be = {}, we = {}, Se = {}, kt;
@@ -2443,176 +2510,176 @@ function de() {
2443
2510
  e.Mutation = "mutation", e.Query = "query", e.Subscription = "subscription";
2444
2511
  }(t || (t = {})), Se.default = t, Se;
2445
2512
  }
2446
- var X = {}, se = {}, _t;
2447
- function Oo() {
2448
- if (_t) return se;
2449
- _t = 1, Object.defineProperty(se, "__esModule", { value: !0 }), se.isNestedField = void 0;
2513
+ var G = {}, se = {}, Rt;
2514
+ function bi() {
2515
+ if (Rt) return se;
2516
+ Rt = 1, Object.defineProperty(se, "__esModule", { value: !0 }), se.isNestedField = void 0;
2450
2517
  function t(e) {
2451
2518
  return typeof e == "object" && e.hasOwnProperty("operation") && e.hasOwnProperty("variables") && e.hasOwnProperty("fields") || typeof e == "object" && e.hasOwnProperty("operation") && e.hasOwnProperty("fragment") && e.hasOwnProperty("fields");
2452
2519
  }
2453
2520
  return se.isNestedField = t, se;
2454
2521
  }
2455
- var Pt;
2522
+ var Nt;
2456
2523
  function fe() {
2457
- if (Pt) return X;
2458
- Pt = 1;
2459
- var t = X && X.__assign || function() {
2460
- return t = Object.assign || function(n) {
2461
- for (var o, i = 1, s = arguments.length; i < s; i++) {
2462
- o = arguments[i];
2463
- for (var a in o) Object.prototype.hasOwnProperty.call(o, a) && (n[a] = o[a]);
2524
+ if (Nt) return G;
2525
+ Nt = 1;
2526
+ var t = G && G.__assign || function() {
2527
+ return t = Object.assign || function(r) {
2528
+ for (var i, o = 1, s = arguments.length; o < s; o++) {
2529
+ i = arguments[o];
2530
+ for (var a in i) Object.prototype.hasOwnProperty.call(i, a) && (r[a] = i[a]);
2464
2531
  }
2465
- return n;
2532
+ return r;
2466
2533
  }, t.apply(this, arguments);
2467
2534
  };
2468
- Object.defineProperty(X, "__esModule", { value: !0 });
2469
- var e = Oo(), r = (
2535
+ Object.defineProperty(G, "__esModule", { value: !0 });
2536
+ var e = bi(), n = (
2470
2537
  /** @class */
2471
2538
  function() {
2472
- function n() {
2539
+ function r() {
2473
2540
  }
2474
- return n.resolveVariables = function(o) {
2475
- for (var i = {}, s = 0, a = o; s < a.length; s++) {
2476
- var c = a[s], u = c.variables, l = c.fields;
2477
- i = t(t(t({}, i), u), l && n.getNestedVariables(l) || {});
2541
+ return r.resolveVariables = function(i) {
2542
+ for (var o = {}, s = 0, a = i; s < a.length; s++) {
2543
+ var c = a[s], l = c.variables, u = c.fields;
2544
+ o = t(t(t({}, o), l), u && r.getNestedVariables(u) || {});
2478
2545
  }
2479
- return i;
2480
- }, n.queryDataNameAndArgumentMap = function(o) {
2481
- return o && Object.keys(o).length ? "(".concat(Object.entries(o).reduce(function(i, s, a) {
2482
- var c = s[0], u = s[1];
2483
- return "".concat(i).concat(a !== 0 ? ", " : "").concat(u && u.name ? u.name : c, ": $").concat(c);
2546
+ return o;
2547
+ }, r.queryDataNameAndArgumentMap = function(i) {
2548
+ return i && Object.keys(i).length ? "(".concat(Object.entries(i).reduce(function(o, s, a) {
2549
+ var c = s[0], l = s[1];
2550
+ return "".concat(o).concat(a !== 0 ? ", " : "").concat(l && l.name ? l.name : c, ": $").concat(c);
2484
2551
  }, ""), ")") : "";
2485
- }, n.queryFieldsMap = function(o) {
2486
- var i = this;
2487
- return o ? o.map(function(s) {
2552
+ }, r.queryFieldsMap = function(i) {
2553
+ var o = this;
2554
+ return i ? i.map(function(s) {
2488
2555
  if ((0, e.isNestedField)(s))
2489
- return n.queryNestedFieldMap(s);
2556
+ return r.queryNestedFieldMap(s);
2490
2557
  if (typeof s == "object") {
2491
2558
  var a = "";
2492
- return Object.entries(s).forEach(function(c, u, l) {
2559
+ return Object.entries(s).forEach(function(c, l, u) {
2493
2560
  var f = c[0], h = c[1];
2494
- a += "".concat(f, " ").concat(h.length > 0 ? "{ " + i.queryFieldsMap(h) + " }" : ""), u < l.length - 1 && (a += ", ");
2561
+ a += "".concat(f, " ").concat(h.length > 0 ? "{ " + o.queryFieldsMap(h) + " }" : ""), l < u.length - 1 && (a += ", ");
2495
2562
  }), a;
2496
2563
  } else
2497
2564
  return "".concat(s);
2498
2565
  }).join(", ") : "";
2499
- }, n.operationOrAlias = function(o) {
2500
- return typeof o == "string" ? o : "".concat(o.alias, ": ").concat(o.name);
2501
- }, n.isFragment = function(o) {
2502
- var i;
2503
- return (i = o?.fragment === !0) !== null && i !== void 0 ? i : !1;
2504
- }, n.operationOrFragment = function(o) {
2505
- return n.isFragment(o) ? o.operation : n.operationOrAlias(o.operation);
2506
- }, n.getFragment = function(o) {
2507
- return n.isFragment(o) ? "... on " : "";
2508
- }, n.queryNestedFieldMap = function(o) {
2509
- return "".concat(n.getFragment(o)).concat(n.operationOrFragment(o), " ").concat(this.isFragment(o) ? "" : this.queryDataNameAndArgumentMap(o.variables), " ").concat(o.fields.length > 0 ? "{ " + this.queryFieldsMap(o.fields) + " }" : "");
2510
- }, n.queryVariablesMap = function(o, i) {
2566
+ }, r.operationOrAlias = function(i) {
2567
+ return typeof i == "string" ? i : "".concat(i.alias, ": ").concat(i.name);
2568
+ }, r.isFragment = function(i) {
2569
+ var o;
2570
+ return (o = i?.fragment === !0) !== null && o !== void 0 ? o : !1;
2571
+ }, r.operationOrFragment = function(i) {
2572
+ return r.isFragment(i) ? i.operation : r.operationOrAlias(i.operation);
2573
+ }, r.getFragment = function(i) {
2574
+ return r.isFragment(i) ? "... on " : "";
2575
+ }, r.queryNestedFieldMap = function(i) {
2576
+ return "".concat(r.getFragment(i)).concat(r.operationOrFragment(i), " ").concat(this.isFragment(i) ? "" : this.queryDataNameAndArgumentMap(i.variables), " ").concat(i.fields.length > 0 ? "{ " + this.queryFieldsMap(i.fields) + " }" : "");
2577
+ }, r.queryVariablesMap = function(i, o) {
2511
2578
  var s = {}, a = function(c) {
2512
- c && Object.keys(c).map(function(u) {
2513
- s[u] = typeof c[u] == "object" ? c[u].value : c[u];
2579
+ c && Object.keys(c).map(function(l) {
2580
+ s[l] = typeof c[l] == "object" ? c[l].value : c[l];
2514
2581
  });
2515
2582
  };
2516
- return a(o), i && typeof i == "object" && a(n.getNestedVariables(i)), s;
2517
- }, n.getNestedVariables = function(o) {
2518
- var i = {};
2583
+ return a(i), o && typeof o == "object" && a(r.getNestedVariables(o)), s;
2584
+ }, r.getNestedVariables = function(i) {
2585
+ var o = {};
2519
2586
  function s(a) {
2520
2587
  return a?.forEach(function(c) {
2521
2588
  if ((0, e.isNestedField)(c))
2522
- i = t(t(t({}, c.variables), i), c.fields && s(c.fields));
2589
+ o = t(t(t({}, c.variables), o), c.fields && s(c.fields));
2523
2590
  else if (typeof c == "object")
2524
- for (var u = 0, l = Object.entries(c); u < l.length; u++) {
2525
- var f = l[u], h = f[1];
2591
+ for (var l = 0, u = Object.entries(c); l < u.length; l++) {
2592
+ var f = u[l], h = f[1];
2526
2593
  s(h);
2527
2594
  }
2528
- }), i;
2595
+ }), o;
2529
2596
  }
2530
- return s(o), i;
2531
- }, n.queryDataType = function(o) {
2532
- var i = "String", s = typeof o == "object" ? o.value : o;
2533
- if (o?.type != null)
2534
- i = o.type;
2597
+ return s(i), o;
2598
+ }, r.queryDataType = function(i) {
2599
+ var o = "String", s = typeof i == "object" ? i.value : i;
2600
+ if (i?.type != null)
2601
+ o = i.type;
2535
2602
  else {
2536
2603
  var a = Array.isArray(s) ? s[0] : s;
2537
2604
  switch (typeof a) {
2538
2605
  case "object":
2539
- i = "Object";
2606
+ o = "Object";
2540
2607
  break;
2541
2608
  case "boolean":
2542
- i = "Boolean";
2609
+ o = "Boolean";
2543
2610
  break;
2544
2611
  case "number":
2545
- i = a % 1 === 0 ? "Int" : "Float";
2612
+ o = a % 1 === 0 ? "Int" : "Float";
2546
2613
  break;
2547
2614
  }
2548
2615
  }
2549
- return typeof o == "object" && (o.list === !0 ? i = "[".concat(i, "]") : Array.isArray(o.list) && (i = "[".concat(i).concat(o.list[0] ? "!" : "", "]")), o.required && (i += "!")), i;
2550
- }, n;
2616
+ return typeof i == "object" && (i.list === !0 ? o = "[".concat(o, "]") : Array.isArray(i.list) && (o = "[".concat(o).concat(i.list[0] ? "!" : "", "]")), i.required && (o += "!")), o;
2617
+ }, r;
2551
2618
  }()
2552
2619
  );
2553
- return X.default = r, X;
2620
+ return G.default = n, G;
2554
2621
  }
2555
- var Ct;
2556
- function To() {
2557
- if (Ct) return we;
2558
- Ct = 1, Object.defineProperty(we, "__esModule", { value: !0 });
2559
- var t = de(), e = fe(), r = (
2622
+ var xt;
2623
+ function wi() {
2624
+ if (xt) return we;
2625
+ xt = 1, Object.defineProperty(we, "__esModule", { value: !0 });
2626
+ var t = de(), e = fe(), n = (
2560
2627
  /** @class */
2561
2628
  function() {
2562
- function n(o) {
2563
- Array.isArray(o) ? this.variables = e.default.resolveVariables(o) : (this.variables = o.variables, this.fields = o.fields, this.operation = o.operation);
2629
+ function r(i) {
2630
+ Array.isArray(i) ? this.variables = e.default.resolveVariables(i) : (this.variables = i.variables, this.fields = i.fields, this.operation = i.operation);
2564
2631
  }
2565
- return n.prototype.mutationBuilder = function() {
2632
+ return r.prototype.mutationBuilder = function() {
2566
2633
  return this.operationWrapperTemplate(this.variables, this.operationTemplate(this.operation));
2567
- }, n.prototype.mutationsBuilder = function(o) {
2568
- var i = this, s = o.map(function(a) {
2569
- return i.operation = a.operation, i.variables = a.variables, i.fields = a.fields, i.operationTemplate(a.operation);
2634
+ }, r.prototype.mutationsBuilder = function(i) {
2635
+ var o = this, s = i.map(function(a) {
2636
+ return o.operation = a.operation, o.variables = a.variables, o.fields = a.fields, o.operationTemplate(a.operation);
2570
2637
  });
2571
- return this.operationWrapperTemplate(e.default.resolveVariables(o), s.join(`
2638
+ return this.operationWrapperTemplate(e.default.resolveVariables(i), s.join(`
2572
2639
  `));
2573
- }, n.prototype.queryDataNameAndArgumentMap = function() {
2574
- return this.variables && Object.keys(this.variables).length ? "(".concat(Object.keys(this.variables).reduce(function(o, i, s) {
2575
- return "".concat(o).concat(s !== 0 ? ", " : "").concat(i, ": $").concat(i);
2640
+ }, r.prototype.queryDataNameAndArgumentMap = function() {
2641
+ return this.variables && Object.keys(this.variables).length ? "(".concat(Object.keys(this.variables).reduce(function(i, o, s) {
2642
+ return "".concat(i).concat(s !== 0 ? ", " : "").concat(o, ": $").concat(o);
2576
2643
  }, ""), ")") : "";
2577
- }, n.prototype.queryDataArgumentAndTypeMap = function(o) {
2578
- return Object.keys(o).length ? "(".concat(Object.keys(o).reduce(function(i, s, a) {
2579
- return "".concat(i).concat(a !== 0 ? ", " : "", "$").concat(s, ": ").concat(e.default.queryDataType(o[s]));
2644
+ }, r.prototype.queryDataArgumentAndTypeMap = function(i) {
2645
+ return Object.keys(i).length ? "(".concat(Object.keys(i).reduce(function(o, s, a) {
2646
+ return "".concat(o).concat(a !== 0 ? ", " : "", "$").concat(s, ": ").concat(e.default.queryDataType(i[s]));
2580
2647
  }, ""), ")") : "";
2581
- }, n.prototype.operationWrapperTemplate = function(o, i) {
2648
+ }, r.prototype.operationWrapperTemplate = function(i, o) {
2582
2649
  var s = typeof this.operation == "string" ? this.operation : this.operation.name;
2583
2650
  return {
2584
- query: "".concat(t.default.Mutation, " ").concat(s.charAt(0).toUpperCase() + s.slice(1), " ").concat(this.queryDataArgumentAndTypeMap(o), ` {
2585
- `).concat(i, `
2651
+ query: "".concat(t.default.Mutation, " ").concat(s.charAt(0).toUpperCase() + s.slice(1), " ").concat(this.queryDataArgumentAndTypeMap(i), ` {
2652
+ `).concat(o, `
2586
2653
  }`),
2587
- variables: e.default.queryVariablesMap(o)
2654
+ variables: e.default.queryVariablesMap(i)
2588
2655
  };
2589
- }, n.prototype.operationTemplate = function(o) {
2590
- var i = typeof o == "string" ? o : "".concat(o.alias, ": ").concat(o.name);
2591
- return "".concat(i, " ").concat(this.queryDataNameAndArgumentMap(), ` {
2656
+ }, r.prototype.operationTemplate = function(i) {
2657
+ var o = typeof i == "string" ? i : "".concat(i.alias, ": ").concat(i.name);
2658
+ return "".concat(o, " ").concat(this.queryDataNameAndArgumentMap(), ` {
2592
2659
  `).concat(this.queryFieldsMap(this.fields), `
2593
2660
  }`);
2594
- }, n.prototype.queryFieldsMap = function(o) {
2595
- var i = this;
2596
- return Array.isArray(o) ? o.map(function(s) {
2597
- return typeof s == "object" ? "".concat(Object.keys(s)[0], " { ").concat(i.queryFieldsMap(Object.values(s)[0]), " }") : "".concat(s);
2661
+ }, r.prototype.queryFieldsMap = function(i) {
2662
+ var o = this;
2663
+ return Array.isArray(i) ? i.map(function(s) {
2664
+ return typeof s == "object" ? "".concat(Object.keys(s)[0], " { ").concat(o.queryFieldsMap(Object.values(s)[0]), " }") : "".concat(s);
2598
2665
  }).join(", ") : "";
2599
- }, n;
2666
+ }, r;
2600
2667
  }()
2601
2668
  );
2602
- return we.default = r, we;
2669
+ return we.default = n, we;
2603
2670
  }
2604
- var ve = {}, xt;
2605
- function No() {
2606
- if (xt) return ve;
2607
- xt = 1, Object.defineProperty(ve, "__esModule", { value: !0 });
2608
- var t = de(), e = fe(), r = (
2671
+ var Ae = {}, _t;
2672
+ function Si() {
2673
+ if (_t) return Ae;
2674
+ _t = 1, Object.defineProperty(Ae, "__esModule", { value: !0 });
2675
+ var t = de(), e = fe(), n = (
2609
2676
  /** @class */
2610
2677
  function() {
2611
- function n(o) {
2612
- this.queryDataType = function(i) {
2613
- var s = "String", a = typeof i == "object" ? i.value : i;
2614
- if (i.type !== void 0)
2615
- s = i.type;
2678
+ function r(i) {
2679
+ this.queryDataType = function(o) {
2680
+ var s = "String", a = typeof o == "object" ? o.value : o;
2681
+ if (o.type !== void 0)
2682
+ s = o.type;
2616
2683
  else
2617
2684
  switch (typeof a) {
2618
2685
  case "object":
@@ -2625,244 +2692,244 @@ function No() {
2625
2692
  s = a % 1 === 0 ? "Int" : "Float";
2626
2693
  break;
2627
2694
  }
2628
- return typeof i == "object" && i.required && (s += "!"), s;
2629
- }, Array.isArray(o) ? this.variables = e.default.resolveVariables(o) : (this.variables = o.variables, this.fields = o.fields || [], this.operation = o.operation);
2695
+ return typeof o == "object" && o.required && (s += "!"), s;
2696
+ }, Array.isArray(i) ? this.variables = e.default.resolveVariables(i) : (this.variables = i.variables, this.fields = i.fields || [], this.operation = i.operation);
2630
2697
  }
2631
- return n.prototype.queryBuilder = function() {
2698
+ return r.prototype.queryBuilder = function() {
2632
2699
  return this.operationWrapperTemplate(this.operationTemplate());
2633
- }, n.prototype.queriesBuilder = function(o) {
2634
- var i = this, s = function() {
2700
+ }, r.prototype.queriesBuilder = function(i) {
2701
+ var o = this, s = function() {
2635
2702
  var a = [];
2636
- return o.forEach(function(c) {
2637
- c && (i.operation = c.operation, i.fields = c.fields, i.variables = c.variables, a.push(i.operationTemplate()));
2703
+ return i.forEach(function(c) {
2704
+ c && (o.operation = c.operation, o.fields = c.fields, o.variables = c.variables, a.push(o.operationTemplate()));
2638
2705
  }), a.join(" ");
2639
2706
  };
2640
2707
  return this.operationWrapperTemplate(s());
2641
- }, n.prototype.queryDataNameAndArgumentMap = function() {
2642
- return this.variables && Object.keys(this.variables).length ? "(".concat(Object.keys(this.variables).reduce(function(o, i, s) {
2643
- return "".concat(o).concat(s !== 0 ? ", " : "").concat(i, ": $").concat(i);
2708
+ }, r.prototype.queryDataNameAndArgumentMap = function() {
2709
+ return this.variables && Object.keys(this.variables).length ? "(".concat(Object.keys(this.variables).reduce(function(i, o, s) {
2710
+ return "".concat(i).concat(s !== 0 ? ", " : "").concat(o, ": $").concat(o);
2644
2711
  }, ""), ")") : "";
2645
- }, n.prototype.queryDataArgumentAndTypeMap = function() {
2646
- var o = this;
2647
- return this.variables && Object.keys(this.variables).length ? "(".concat(Object.keys(this.variables).reduce(function(i, s, a) {
2648
- return "".concat(i).concat(a !== 0 ? ", " : "", "$").concat(s, ": ").concat(o.queryDataType(o.variables[s]));
2712
+ }, r.prototype.queryDataArgumentAndTypeMap = function() {
2713
+ var i = this;
2714
+ return this.variables && Object.keys(this.variables).length ? "(".concat(Object.keys(this.variables).reduce(function(o, s, a) {
2715
+ return "".concat(o).concat(a !== 0 ? ", " : "", "$").concat(s, ": ").concat(i.queryDataType(i.variables[s]));
2649
2716
  }, ""), ")") : "";
2650
- }, n.prototype.operationWrapperTemplate = function(o) {
2651
- var i = typeof this.operation == "string" ? this.operation : this.operation.name;
2717
+ }, r.prototype.operationWrapperTemplate = function(i) {
2718
+ var o = typeof this.operation == "string" ? this.operation : this.operation.name;
2652
2719
  return {
2653
- query: "".concat(t.default.Query, " ").concat(i.charAt(0).toUpperCase()).concat(i.slice(1), " ").concat(this.queryDataArgumentAndTypeMap(), " { ").concat(o, " }"),
2720
+ query: "".concat(t.default.Query, " ").concat(o.charAt(0).toUpperCase()).concat(o.slice(1), " ").concat(this.queryDataArgumentAndTypeMap(), " { ").concat(i, " }"),
2654
2721
  variables: e.default.queryVariablesMap(this.variables)
2655
2722
  };
2656
- }, n.prototype.operationTemplate = function() {
2657
- var o = typeof this.operation == "string" ? this.operation : "".concat(this.operation.alias, ": ").concat(this.operation.name);
2658
- return "".concat(o, " ").concat(this.queryDataNameAndArgumentMap(), " { nodes { ").concat(e.default.queryFieldsMap(this.fields), " } }");
2659
- }, n;
2723
+ }, r.prototype.operationTemplate = function() {
2724
+ var i = typeof this.operation == "string" ? this.operation : "".concat(this.operation.alias, ": ").concat(this.operation.name);
2725
+ return "".concat(i, " ").concat(this.queryDataNameAndArgumentMap(), " { nodes { ").concat(e.default.queryFieldsMap(this.fields), " } }");
2726
+ }, r;
2660
2727
  }()
2661
2728
  );
2662
- return ve.default = r, ve;
2729
+ return Ae.default = n, Ae;
2663
2730
  }
2664
- var Dt;
2665
- function Ro() {
2666
- if (Dt) return be;
2667
- Dt = 1, Object.defineProperty(be, "__esModule", { value: !0 });
2668
- var t = To(), e = No();
2731
+ var Ct;
2732
+ function Ai() {
2733
+ if (Ct) return be;
2734
+ Ct = 1, Object.defineProperty(be, "__esModule", { value: !0 });
2735
+ var t = wi(), e = Si();
2669
2736
  return be.default = { DefaultAppSyncQueryAdapter: e.default, DefaultAppSyncMutationAdapter: t.default }, be;
2670
2737
  }
2671
- var G = {}, Ft;
2672
- function ko() {
2673
- if (Ft) return G;
2674
- Ft = 1;
2675
- var t = G && G.__assign || function() {
2676
- return t = Object.assign || function(o) {
2677
- for (var i, s = 1, a = arguments.length; s < a; s++) {
2678
- i = arguments[s];
2679
- for (var c in i) Object.prototype.hasOwnProperty.call(i, c) && (o[c] = i[c]);
2738
+ var X = {}, Pt;
2739
+ function vi() {
2740
+ if (Pt) return X;
2741
+ Pt = 1;
2742
+ var t = X && X.__assign || function() {
2743
+ return t = Object.assign || function(i) {
2744
+ for (var o, s = 1, a = arguments.length; s < a; s++) {
2745
+ o = arguments[s];
2746
+ for (var c in o) Object.prototype.hasOwnProperty.call(o, c) && (i[c] = o[c]);
2680
2747
  }
2681
- return o;
2748
+ return i;
2682
2749
  }, t.apply(this, arguments);
2683
2750
  };
2684
- Object.defineProperty(G, "__esModule", { value: !0 });
2685
- var e = de(), r = fe(), n = (
2751
+ Object.defineProperty(X, "__esModule", { value: !0 });
2752
+ var e = de(), n = fe(), r = (
2686
2753
  /** @class */
2687
2754
  function() {
2688
- function o(i, s) {
2755
+ function i(o, s) {
2689
2756
  var a = this;
2690
- Array.isArray(i) ? this.variables = r.default.resolveVariables(i) : (this.variables = i.variables, this.fields = i.fields, this.operation = i.operation), this.config = {
2757
+ Array.isArray(o) ? this.variables = n.default.resolveVariables(o) : (this.variables = o.variables, this.fields = o.fields, this.operation = o.operation), this.config = {
2691
2758
  operationName: ""
2692
2759
  }, s && Object.entries(s).forEach(function(c) {
2693
- var u = c[0], l = c[1];
2694
- a.config[u] = l;
2760
+ var l = c[0], u = c[1];
2761
+ a.config[l] = u;
2695
2762
  });
2696
2763
  }
2697
- return o.prototype.mutationBuilder = function() {
2764
+ return i.prototype.mutationBuilder = function() {
2698
2765
  return this.operationWrapperTemplate(e.default.Mutation, this.variables, this.operationTemplate(this.operation));
2699
- }, o.prototype.mutationsBuilder = function(i) {
2700
- var s = this, a = i.map(function(c) {
2766
+ }, i.prototype.mutationsBuilder = function(o) {
2767
+ var s = this, a = o.map(function(c) {
2701
2768
  return s.operation = c.operation, s.variables = c.variables, s.fields = c.fields, s.operationTemplate(c.operation);
2702
2769
  });
2703
- return this.operationWrapperTemplate(e.default.Mutation, r.default.resolveVariables(i), a.join(`
2770
+ return this.operationWrapperTemplate(e.default.Mutation, n.default.resolveVariables(o), a.join(`
2704
2771
  `));
2705
- }, o.prototype.queryDataArgumentAndTypeMap = function(i) {
2706
- return this.fields && typeof this.fields == "object" && (i = t(t({}, r.default.getNestedVariables(this.fields)), i)), i && Object.keys(i).length > 0 ? "(".concat(Object.keys(i).reduce(function(s, a, c) {
2707
- return "".concat(s).concat(c !== 0 ? ", " : "", "$").concat(a, ": ").concat(r.default.queryDataType(i[a]));
2772
+ }, i.prototype.queryDataArgumentAndTypeMap = function(o) {
2773
+ return this.fields && typeof this.fields == "object" && (o = t(t({}, n.default.getNestedVariables(this.fields)), o)), o && Object.keys(o).length > 0 ? "(".concat(Object.keys(o).reduce(function(s, a, c) {
2774
+ return "".concat(s).concat(c !== 0 ? ", " : "", "$").concat(a, ": ").concat(n.default.queryDataType(o[a]));
2708
2775
  }, ""), ")") : "";
2709
- }, o.prototype.operationWrapperTemplate = function(i, s, a) {
2710
- var c = "".concat(i, " ").concat(this.queryDataArgumentAndTypeMap(s), ` {
2776
+ }, i.prototype.operationWrapperTemplate = function(o, s, a) {
2777
+ var c = "".concat(o, " ").concat(this.queryDataArgumentAndTypeMap(s), ` {
2711
2778
  `).concat(a, `
2712
2779
  }`);
2713
2780
  return this.config.operationName && (c = c.replace("mutation", "mutation ".concat(this.config.operationName))), {
2714
2781
  query: c,
2715
- variables: r.default.queryVariablesMap(s, this.fields)
2782
+ variables: n.default.queryVariablesMap(s, this.fields)
2716
2783
  };
2717
- }, o.prototype.operationTemplate = function(i) {
2718
- var s = typeof i == "string" ? i : "".concat(i.alias, ": ").concat(i.name);
2719
- return "".concat(s, " ").concat(r.default.queryDataNameAndArgumentMap(this.variables), " ").concat(this.fields && this.fields.length > 0 ? `{
2720
- `.concat(r.default.queryFieldsMap(this.fields), `
2784
+ }, i.prototype.operationTemplate = function(o) {
2785
+ var s = typeof o == "string" ? o : "".concat(o.alias, ": ").concat(o.name);
2786
+ return "".concat(s, " ").concat(n.default.queryDataNameAndArgumentMap(this.variables), " ").concat(this.fields && this.fields.length > 0 ? `{
2787
+ `.concat(n.default.queryFieldsMap(this.fields), `
2721
2788
  }`) : "");
2722
- }, o;
2789
+ }, i;
2723
2790
  }()
2724
2791
  );
2725
- return G.default = n, G;
2792
+ return X.default = r, X;
2726
2793
  }
2727
- var Y = {}, qt;
2728
- function _o() {
2729
- if (qt) return Y;
2730
- qt = 1;
2794
+ var Y = {}, Dt;
2795
+ function Ei() {
2796
+ if (Dt) return Y;
2797
+ Dt = 1;
2731
2798
  var t = Y && Y.__assign || function() {
2732
- return t = Object.assign || function(o) {
2733
- for (var i, s = 1, a = arguments.length; s < a; s++) {
2734
- i = arguments[s];
2735
- for (var c in i) Object.prototype.hasOwnProperty.call(i, c) && (o[c] = i[c]);
2799
+ return t = Object.assign || function(i) {
2800
+ for (var o, s = 1, a = arguments.length; s < a; s++) {
2801
+ o = arguments[s];
2802
+ for (var c in o) Object.prototype.hasOwnProperty.call(o, c) && (i[c] = o[c]);
2736
2803
  }
2737
- return o;
2804
+ return i;
2738
2805
  }, t.apply(this, arguments);
2739
2806
  };
2740
2807
  Object.defineProperty(Y, "__esModule", { value: !0 });
2741
- var e = de(), r = fe(), n = (
2808
+ var e = de(), n = fe(), r = (
2742
2809
  /** @class */
2743
2810
  function() {
2744
- function o(i, s) {
2811
+ function i(o, s) {
2745
2812
  var a = this;
2746
2813
  this.config = {
2747
2814
  operationName: ""
2748
2815
  }, s && Object.entries(s).forEach(function(c) {
2749
- var u = c[0], l = c[1];
2750
- a.config[u] = l;
2751
- }), Array.isArray(i) ? this.variables = r.default.resolveVariables(i) : (this.variables = i.variables, this.fields = i.fields || [], this.operation = i.operation);
2816
+ var l = c[0], u = c[1];
2817
+ a.config[l] = u;
2818
+ }), Array.isArray(o) ? this.variables = n.default.resolveVariables(o) : (this.variables = o.variables, this.fields = o.fields || [], this.operation = o.operation);
2752
2819
  }
2753
- return o.prototype.queryBuilder = function() {
2820
+ return i.prototype.queryBuilder = function() {
2754
2821
  return this.operationWrapperTemplate(this.operationTemplate(this.variables));
2755
- }, o.prototype.queriesBuilder = function(i) {
2822
+ }, i.prototype.queriesBuilder = function(o) {
2756
2823
  var s = this, a = function() {
2757
2824
  var c = [];
2758
- return i.forEach(function(u) {
2759
- u && (s.operation = u.operation, s.fields = u.fields, c.push(s.operationTemplate(u.variables)));
2825
+ return o.forEach(function(l) {
2826
+ l && (s.operation = l.operation, s.fields = l.fields, c.push(s.operationTemplate(l.variables)));
2760
2827
  }), c.join(" ");
2761
2828
  };
2762
2829
  return this.operationWrapperTemplate(a());
2763
- }, o.prototype.queryDataArgumentAndTypeMap = function() {
2764
- var i = this.variables;
2765
- return this.fields && typeof this.fields == "object" && (i = t(t({}, r.default.getNestedVariables(this.fields)), i)), i && Object.keys(i).length > 0 ? "(".concat(Object.keys(i).reduce(function(s, a, c) {
2766
- return "".concat(s).concat(c !== 0 ? ", " : "", "$").concat(a, ": ").concat(r.default.queryDataType(i[a]));
2830
+ }, i.prototype.queryDataArgumentAndTypeMap = function() {
2831
+ var o = this.variables;
2832
+ return this.fields && typeof this.fields == "object" && (o = t(t({}, n.default.getNestedVariables(this.fields)), o)), o && Object.keys(o).length > 0 ? "(".concat(Object.keys(o).reduce(function(s, a, c) {
2833
+ return "".concat(s).concat(c !== 0 ? ", " : "", "$").concat(a, ": ").concat(n.default.queryDataType(o[a]));
2767
2834
  }, ""), ")") : "";
2768
- }, o.prototype.operationWrapperTemplate = function(i) {
2769
- var s = "".concat(e.default.Query, " ").concat(this.queryDataArgumentAndTypeMap(), " { ").concat(i, " }");
2835
+ }, i.prototype.operationWrapperTemplate = function(o) {
2836
+ var s = "".concat(e.default.Query, " ").concat(this.queryDataArgumentAndTypeMap(), " { ").concat(o, " }");
2770
2837
  return s = s.replace("query", "query".concat(this.config.operationName !== "" ? " " + this.config.operationName : "")), {
2771
2838
  query: s,
2772
- variables: r.default.queryVariablesMap(this.variables, this.fields)
2839
+ variables: n.default.queryVariablesMap(this.variables, this.fields)
2773
2840
  };
2774
- }, o.prototype.operationTemplate = function(i) {
2841
+ }, i.prototype.operationTemplate = function(o) {
2775
2842
  var s = typeof this.operation == "string" ? this.operation : "".concat(this.operation.alias, ": ").concat(this.operation.name);
2776
- return "".concat(s, " ").concat(i ? r.default.queryDataNameAndArgumentMap(i) : "", " ").concat(this.fields && this.fields.length > 0 ? "{ " + r.default.queryFieldsMap(this.fields) + " }" : "");
2777
- }, o;
2843
+ return "".concat(s, " ").concat(o ? n.default.queryDataNameAndArgumentMap(o) : "", " ").concat(this.fields && this.fields.length > 0 ? "{ " + n.default.queryFieldsMap(this.fields) + " }" : "");
2844
+ }, i;
2778
2845
  }()
2779
2846
  );
2780
- return Y.default = n, Y;
2847
+ return Y.default = r, Y;
2781
2848
  }
2782
- var Ae = {}, jt;
2783
- function Po() {
2784
- if (jt) return Ae;
2785
- jt = 1, Object.defineProperty(Ae, "__esModule", { value: !0 });
2786
- var t = de(), e = fe(), r = (
2849
+ var ve = {}, qt;
2850
+ function Oi() {
2851
+ if (qt) return ve;
2852
+ qt = 1, Object.defineProperty(ve, "__esModule", { value: !0 });
2853
+ var t = de(), e = fe(), n = (
2787
2854
  /** @class */
2788
2855
  function() {
2789
- function n(o) {
2790
- Array.isArray(o) ? this.variables = e.default.resolveVariables(o) : (this.variables = o.variables, this.fields = o.fields, this.operation = o.operation);
2856
+ function r(i) {
2857
+ Array.isArray(i) ? this.variables = e.default.resolveVariables(i) : (this.variables = i.variables, this.fields = i.fields, this.operation = i.operation);
2791
2858
  }
2792
- return n.prototype.subscriptionBuilder = function() {
2859
+ return r.prototype.subscriptionBuilder = function() {
2793
2860
  return this.operationWrapperTemplate(t.default.Subscription, this.variables, this.operationTemplate(this.operation));
2794
- }, n.prototype.subscriptionsBuilder = function(o) {
2795
- var i = this, s = o.map(function(a) {
2796
- return i.operation = a.operation, i.variables = a.variables, i.fields = a.fields, i.operationTemplate(a.operation);
2861
+ }, r.prototype.subscriptionsBuilder = function(i) {
2862
+ var o = this, s = i.map(function(a) {
2863
+ return o.operation = a.operation, o.variables = a.variables, o.fields = a.fields, o.operationTemplate(a.operation);
2797
2864
  });
2798
- return this.operationWrapperTemplate(t.default.Subscription, e.default.resolveVariables(o), s.join(`
2865
+ return this.operationWrapperTemplate(t.default.Subscription, e.default.resolveVariables(i), s.join(`
2799
2866
  `));
2800
- }, n.prototype.queryDataNameAndArgumentMap = function() {
2801
- return this.variables && Object.keys(this.variables).length ? "(".concat(Object.keys(this.variables).reduce(function(o, i, s) {
2802
- return "".concat(o).concat(s !== 0 ? ", " : "").concat(i, ": $").concat(i);
2867
+ }, r.prototype.queryDataNameAndArgumentMap = function() {
2868
+ return this.variables && Object.keys(this.variables).length ? "(".concat(Object.keys(this.variables).reduce(function(i, o, s) {
2869
+ return "".concat(i).concat(s !== 0 ? ", " : "").concat(o, ": $").concat(o);
2803
2870
  }, ""), ")") : "";
2804
- }, n.prototype.queryDataArgumentAndTypeMap = function(o) {
2805
- return Object.keys(o).length ? "(".concat(Object.keys(o).reduce(function(i, s, a) {
2806
- return "".concat(i).concat(a !== 0 ? ", " : "", "$").concat(s, ": ").concat(e.default.queryDataType(o[s]));
2871
+ }, r.prototype.queryDataArgumentAndTypeMap = function(i) {
2872
+ return Object.keys(i).length ? "(".concat(Object.keys(i).reduce(function(o, s, a) {
2873
+ return "".concat(o).concat(a !== 0 ? ", " : "", "$").concat(s, ": ").concat(e.default.queryDataType(i[s]));
2807
2874
  }, ""), ")") : "";
2808
- }, n.prototype.operationWrapperTemplate = function(o, i, s) {
2875
+ }, r.prototype.operationWrapperTemplate = function(i, o, s) {
2809
2876
  return {
2810
- query: "".concat(o, " ").concat(this.queryDataArgumentAndTypeMap(i), ` {
2877
+ query: "".concat(i, " ").concat(this.queryDataArgumentAndTypeMap(o), ` {
2811
2878
  `).concat(s, `
2812
2879
  }`),
2813
- variables: e.default.queryVariablesMap(i)
2880
+ variables: e.default.queryVariablesMap(o)
2814
2881
  };
2815
- }, n.prototype.operationTemplate = function(o) {
2816
- var i = typeof this.operation == "string" ? this.operation : "".concat(this.operation.alias, ": ").concat(this.operation.name);
2817
- return "".concat(i, " ").concat(this.queryDataNameAndArgumentMap(), ` {
2882
+ }, r.prototype.operationTemplate = function(i) {
2883
+ var o = typeof this.operation == "string" ? this.operation : "".concat(this.operation.alias, ": ").concat(this.operation.name);
2884
+ return "".concat(o, " ").concat(this.queryDataNameAndArgumentMap(), ` {
2818
2885
  `).concat(this.queryFieldsMap(this.fields), `
2819
2886
  }`);
2820
- }, n.prototype.queryFieldsMap = function(o) {
2821
- var i = this;
2822
- return o ? o.map(function(s) {
2823
- return typeof s == "object" ? "".concat(Object.keys(s)[0], " { ").concat(i.queryFieldsMap(Object.values(s)[0]), " }") : "".concat(s);
2887
+ }, r.prototype.queryFieldsMap = function(i) {
2888
+ var o = this;
2889
+ return i ? i.map(function(s) {
2890
+ return typeof s == "object" ? "".concat(Object.keys(s)[0], " { ").concat(o.queryFieldsMap(Object.values(s)[0]), " }") : "".concat(s);
2824
2891
  }).join(", ") : "";
2825
- }, n;
2892
+ }, r;
2826
2893
  }()
2827
2894
  );
2828
- return Ae.default = r, Ae;
2895
+ return ve.default = n, ve;
2829
2896
  }
2830
- var Mt;
2831
- function Co() {
2832
- if (Mt) return C;
2833
- Mt = 1, Object.defineProperty(C, "__esModule", { value: !0 }), C.adapters = C.query = C.mutation = C.subscription = void 0;
2834
- var t = Ro();
2897
+ var Ft;
2898
+ function Ti() {
2899
+ if (Ft) return C;
2900
+ Ft = 1, Object.defineProperty(C, "__esModule", { value: !0 }), C.adapters = C.query = C.mutation = C.subscription = void 0;
2901
+ var t = Ai();
2835
2902
  C.adapters = t.default;
2836
- var e = ko(), r = _o(), n = Po();
2837
- function o(a, c, u) {
2838
- var l;
2903
+ var e = vi(), n = Ei(), r = Oi();
2904
+ function i(a, c, l) {
2905
+ var u;
2839
2906
  if (Array.isArray(a)) {
2840
2907
  if (c) {
2841
- var f = new c(a, u);
2908
+ var f = new c(a, l);
2842
2909
  return f.queriesBuilder(a);
2843
2910
  }
2844
- return l = new r.default(a, u), l.queriesBuilder(a);
2911
+ return u = new n.default(a, l), u.queriesBuilder(a);
2845
2912
  }
2846
2913
  if (c) {
2847
- var f = new c(a, u);
2914
+ var f = new c(a, l);
2848
2915
  return f.queryBuilder();
2849
2916
  }
2850
- return l = new r.default(a, u), l.queryBuilder();
2917
+ return u = new n.default(a, l), u.queryBuilder();
2851
2918
  }
2852
- C.query = o;
2853
- function i(a, c, u) {
2854
- var l, f;
2855
- return Array.isArray(a) ? c ? (l = new c(a, u), l.mutationsBuilder(a)) : (f = new e.default(a, u), f.mutationsBuilder(a)) : c ? (l = new c(a, u), l.mutationBuilder()) : (f = new e.default(a, u), f.mutationBuilder());
2919
+ C.query = i;
2920
+ function o(a, c, l) {
2921
+ var u, f;
2922
+ return Array.isArray(a) ? c ? (u = new c(a, l), u.mutationsBuilder(a)) : (f = new e.default(a, l), f.mutationsBuilder(a)) : c ? (u = new c(a, l), u.mutationBuilder()) : (f = new e.default(a, l), f.mutationBuilder());
2856
2923
  }
2857
- C.mutation = i;
2924
+ C.mutation = o;
2858
2925
  function s(a, c) {
2859
- var u, l;
2860
- return Array.isArray(a) ? c ? (u = new c(a), u.subscriptionsBuilder(a)) : (l = new n.default(a), l.subscriptionsBuilder(a)) : c ? (u = new c(a), u.subscriptionBuilder()) : (l = new n.default(a), l.subscriptionBuilder());
2926
+ var l, u;
2927
+ return Array.isArray(a) ? c ? (l = new c(a), l.subscriptionsBuilder(a)) : (u = new r.default(a), u.subscriptionsBuilder(a)) : c ? (l = new c(a), l.subscriptionBuilder()) : (u = new r.default(a), u.subscriptionBuilder());
2861
2928
  }
2862
2929
  return C.subscription = s, C;
2863
2930
  }
2864
- Co();
2865
- const xo = {
2931
+ Ti();
2932
+ const ki = {
2866
2933
  kind: "Document",
2867
2934
  definitions: [{
2868
2935
  kind: "FragmentDefinition",
@@ -2906,7 +2973,7 @@ const xo = {
2906
2973
  }]
2907
2974
  }
2908
2975
  }]
2909
- }, Do = {
2976
+ }, Ri = {
2910
2977
  kind: "Document",
2911
2978
  definitions: [{
2912
2979
  kind: "OperationDefinition",
@@ -3081,7 +3148,7 @@ const xo = {
3081
3148
  }]
3082
3149
  }
3083
3150
  }]
3084
- }, Fo = {
3151
+ }, Ni = {
3085
3152
  kind: "Document",
3086
3153
  definitions: [{
3087
3154
  kind: "OperationDefinition",
@@ -3111,7 +3178,7 @@ const xo = {
3111
3178
  }]
3112
3179
  }
3113
3180
  }]
3114
- }, qo = {
3181
+ }, xi = {
3115
3182
  kind: "Document",
3116
3183
  definitions: [{
3117
3184
  kind: "OperationDefinition",
@@ -3141,7 +3208,7 @@ const xo = {
3141
3208
  }]
3142
3209
  }
3143
3210
  }]
3144
- }, jo = {
3211
+ }, _i = {
3145
3212
  kind: "Document",
3146
3213
  definitions: [{
3147
3214
  kind: "OperationDefinition",
@@ -3224,7 +3291,7 @@ const xo = {
3224
3291
  }]
3225
3292
  }
3226
3293
  }]
3227
- }, Mo = {
3294
+ }, Ci = {
3228
3295
  kind: "Document",
3229
3296
  definitions: [{
3230
3297
  kind: "OperationDefinition",
@@ -3244,7 +3311,7 @@ const xo = {
3244
3311
  }]
3245
3312
  }
3246
3313
  }]
3247
- }, Bo = {
3314
+ }, Pi = {
3248
3315
  kind: "Document",
3249
3316
  definitions: [{
3250
3317
  kind: "OperationDefinition",
@@ -3315,19 +3382,19 @@ const xo = {
3315
3382
  }]
3316
3383
  }
3317
3384
  }]
3318
- }, Io = {
3319
- "\n mutation login($email: String!, $password: String!, $rememberMe: Boolean) {\n login(username: $email, password: $password, rememberMe: $rememberMe) {\n __typename\n ... on CurrentUser {\n id\n identifier\n }\n ... on ErrorResult {\n errorCode\n message\n }\n }\n }\n": Do,
3320
- "\n mutation logout {\n logout {\n success\n }\n }\n": Fo,
3321
- "\n query me {\n me {\n id\n }\n }\n": qo,
3322
- "\n mutation transitionOrderToState($input: String!) {\n transitionOrderToState(state: $input) {\n ... on ErrorResult {\n errorCode\n message\n }\n }\n }\n": jo,
3323
- "\n query nextOrderStates {\n nextOrderStates\n }\n": Mo,
3324
- "\n fragment EligiblePaymentMethods on PaymentMethodQuote {\n id\n name\n description\n code\n }\n": xo,
3325
- "\n query EligiblePaymentMethods {\n eligiblePaymentMethods {\n ...EligiblePaymentMethods\n }\n }\n": Bo
3385
+ }, Di = {
3386
+ "\n mutation login($email: String!, $password: String!, $rememberMe: Boolean) {\n login(username: $email, password: $password, rememberMe: $rememberMe) {\n __typename\n ... on CurrentUser {\n id\n identifier\n }\n ... on ErrorResult {\n errorCode\n message\n }\n }\n }\n": Ri,
3387
+ "\n mutation logout {\n logout {\n success\n }\n }\n": Ni,
3388
+ "\n query me {\n me {\n id\n }\n }\n": xi,
3389
+ "\n mutation transitionOrderToState($input: String!) {\n transitionOrderToState(state: $input) {\n ... on ErrorResult {\n errorCode\n message\n }\n }\n }\n": _i,
3390
+ "\n query nextOrderStates {\n nextOrderStates\n }\n": Ci,
3391
+ "\n fragment EligiblePaymentMethods on PaymentMethodQuote {\n id\n name\n description\n code\n }\n": ki,
3392
+ "\n query EligiblePaymentMethods {\n eligiblePaymentMethods {\n ...EligiblePaymentMethods\n }\n }\n": Pi
3326
3393
  };
3327
- function De(t) {
3328
- return Io[t] ?? {};
3394
+ function Fe(t) {
3395
+ return Di[t] ?? {};
3329
3396
  }
3330
- De(
3397
+ Fe(
3331
3398
  /* GraphQL */
3332
3399
  `
3333
3400
  mutation transitionOrderToState($input: String!) {
@@ -3340,7 +3407,7 @@ De(
3340
3407
  }
3341
3408
  `
3342
3409
  );
3343
- De(
3410
+ Fe(
3344
3411
  /* GraphQL */
3345
3412
  `
3346
3413
  query nextOrderStates {
@@ -3348,7 +3415,7 @@ De(
3348
3415
  }
3349
3416
  `
3350
3417
  );
3351
- De(
3418
+ Fe(
3352
3419
  /* GraphQL */
3353
3420
  `
3354
3421
  fragment EligiblePaymentMethods on PaymentMethodQuote {
@@ -3359,7 +3426,7 @@ De(
3359
3426
  }
3360
3427
  `
3361
3428
  );
3362
- De(
3429
+ Fe(
3363
3430
  /* GraphQL */
3364
3431
  `
3365
3432
  query EligiblePaymentMethods {
@@ -3369,108 +3436,124 @@ De(
3369
3436
  }
3370
3437
  `
3371
3438
  );
3372
- const Fe = () => {
3439
+ const un = new cn({
3440
+ createQueryClient: () => new Re({
3441
+ defaultOptions: {
3442
+ queries: {
3443
+ refetchOnWindowFocus: !0,
3444
+ refetchOnMount: !1,
3445
+ retry: 3,
3446
+ staleTime: 1e3 * 60 * 5
3447
+ }
3448
+ }
3449
+ }),
3450
+ createAxios: (t) => S.create({
3451
+ baseURL: t,
3452
+ withCredentials: !0
3453
+ })
3454
+ });
3455
+ un.getAxiosProxy();
3456
+ un.getQueryClientProxy();
3457
+ const Me = () => {
3373
3458
  const t = U.c(2), {
3374
3459
  getPlatform: e
3375
- } = Eo();
3376
- let r;
3377
- return t[0] !== e ? (r = e(), t[0] = e, t[1] = r) : r = t[1], r;
3378
- };
3379
- globalThis.__STORE_COMPONENT_PROVIDER_CONTEXT__ ||= It(void 0);
3380
- const qe = "ProductBadge", [Uo] = En(qe), [$o, Lo] = Uo(qe), mn = (t) => {
3460
+ } = gi();
3461
+ let n;
3462
+ return t[0] !== e ? (n = e(), t[0] = e, t[1] = n) : n = t[1], n;
3463
+ }, je = "ProductBadge", [qi] = An(je), [Fi, Mi] = qi(je), dn = (t) => {
3381
3464
  const e = U.c(13);
3382
- let r, n, o, i, s;
3465
+ let n, r, i, o, s;
3383
3466
  e[0] !== t ? ({
3384
- children: n,
3385
- product: o,
3386
- __scopeProductBadge: r,
3467
+ children: r,
3468
+ product: i,
3469
+ __scopeProductBadge: n,
3387
3470
  style: s,
3388
- ...i
3389
- } = t, e[0] = t, e[1] = r, e[2] = n, e[3] = o, e[4] = i, e[5] = s) : (r = e[1], n = e[2], o = e[3], i = e[4], s = e[5]);
3390
- const a = An(null), c = Fe();
3391
- let u;
3392
- e[6] !== c ? (u = Re(c), e[6] = c, e[7] = u) : u = e[7];
3393
- const l = u;
3471
+ ...o
3472
+ } = t, e[0] = t, e[1] = n, e[2] = r, e[3] = i, e[4] = o, e[5] = s) : (n = e[1], r = e[2], i = e[3], o = e[4], s = e[5]);
3473
+ const a = Sn(null), c = Me();
3474
+ let l;
3475
+ e[6] !== c ? (l = Ne(c), e[6] = c, e[7] = l) : l = e[7];
3476
+ const u = l;
3394
3477
  if (!ee.getEnabled())
3395
3478
  return null;
3396
3479
  const {
3397
3480
  badges: f
3398
- } = o;
3481
+ } = i;
3399
3482
  if (!f)
3400
3483
  return null;
3401
- const h = f.reduce(Vo, {}), g = Object.keys(h), p = {
3484
+ const h = f.reduce(ji, {}), g = Object.keys(h), p = {
3402
3485
  groupedBadges: h,
3403
3486
  badges: f,
3404
3487
  badgesRef: a,
3405
3488
  positions: g
3406
- }, y = Bt(n, p);
3489
+ }, y = Mt(r, p);
3407
3490
  let m;
3408
- return e[8] !== l || e[9] !== i || e[10] !== s || e[11] !== y ? (m = /* @__PURE__ */ q.jsx(l, { ...i, style: s, children: y }), e[8] = l, e[9] = i, e[10] = s, e[11] = y, e[12] = m) : m = e[12], /* @__PURE__ */ q.jsx($o, { scope: r, ...p, children: m });
3491
+ return e[8] !== u || e[9] !== o || e[10] !== s || e[11] !== y ? (m = /* @__PURE__ */ F.jsx(u, { ...o, style: s, children: y }), e[8] = u, e[9] = o, e[10] = s, e[11] = y, e[12] = m) : m = e[12], /* @__PURE__ */ F.jsx(Fi, { scope: n, ...p, children: m });
3409
3492
  };
3410
- mn.displayName = qe;
3411
- const hn = (t) => {
3493
+ dn.displayName = je;
3494
+ const fn = (t) => {
3412
3495
  const e = U.c(18);
3413
- let r, n, o, i, s;
3496
+ let n, r, i, o, s;
3414
3497
  e[0] !== t ? ({
3415
- children: o,
3416
- position: i,
3417
- asChild: n,
3418
- __scopeProductBadge: r,
3498
+ children: i,
3499
+ position: o,
3500
+ asChild: r,
3501
+ __scopeProductBadge: n,
3419
3502
  ...s
3420
- } = t, e[0] = t, e[1] = r, e[2] = n, e[3] = o, e[4] = i, e[5] = s) : (r = e[1], n = e[2], o = e[3], i = e[4], s = e[5]);
3421
- const a = Fe();
3503
+ } = t, e[0] = t, e[1] = n, e[2] = r, e[3] = i, e[4] = o, e[5] = s) : (n = e[1], r = e[2], i = e[3], o = e[4], s = e[5]);
3504
+ const a = Me();
3422
3505
  let c;
3423
- e[6] !== n || e[7] !== a ? (c = Re(a, n, "div"), e[6] = n, e[7] = a, e[8] = c) : c = e[8];
3424
- const u = c, {
3425
- groupedBadges: l
3426
- } = Lo(qe, r), f = l[i];
3506
+ e[6] !== r || e[7] !== a ? (c = Ne(a, r, "div"), e[6] = r, e[7] = a, e[8] = c) : c = e[8];
3507
+ const l = c, {
3508
+ groupedBadges: u
3509
+ } = Mi(je, n), f = u[o];
3427
3510
  let h;
3428
- e[9] !== f || e[10] !== o || e[11] !== i ? (h = Bt(o, {
3511
+ e[9] !== f || e[10] !== i || e[11] !== o ? (h = Mt(i, {
3429
3512
  badges: f,
3430
- position: i
3431
- }), e[9] = f, e[10] = o, e[11] = i, e[12] = h) : h = e[12];
3513
+ position: o
3514
+ }), e[9] = f, e[10] = i, e[11] = o, e[12] = h) : h = e[12];
3432
3515
  let g;
3433
- return e[13] !== u || e[14] !== i || e[15] !== s || e[16] !== h ? (g = /* @__PURE__ */ q.jsx(u, { ...s, "data-position": i, children: h }), e[13] = u, e[14] = i, e[15] = s, e[16] = h, e[17] = g) : g = e[17], g;
3434
- }, yn = (t) => {
3516
+ return e[13] !== l || e[14] !== o || e[15] !== s || e[16] !== h ? (g = /* @__PURE__ */ F.jsx(l, { ...s, "data-position": o, children: h }), e[13] = l, e[14] = o, e[15] = s, e[16] = h, e[17] = g) : g = e[17], g;
3517
+ }, pn = (t) => {
3435
3518
  const e = U.c(13);
3436
- let r, n, o, i;
3519
+ let n, r, i, o;
3437
3520
  e[0] !== t ? ({
3438
- children: o,
3439
- asChild: r,
3440
- badge: n,
3441
- ...i
3442
- } = t, e[0] = t, e[1] = r, e[2] = n, e[3] = o, e[4] = i) : (r = e[1], n = e[2], o = e[3], i = e[4]);
3443
- const s = Fe();
3444
- let a;
3445
- e[5] !== r || e[6] !== s ? (a = Re(s, r, "div"), e[5] = r, e[6] = s, e[7] = a) : a = e[7];
3446
- const c = a, u = n?.id;
3447
- let l;
3448
- return e[8] !== c || e[9] !== o || e[10] !== i || e[11] !== u ? (l = /* @__PURE__ */ q.jsx(c, { ...i, "data-badge-id": u, children: o }), e[8] = c, e[9] = o, e[10] = i, e[11] = u, e[12] = l) : l = e[12], l;
3449
- }, gn = (t) => {
3450
- const e = U.c(8), {
3451
- badge: r,
3521
+ children: i,
3452
3522
  asChild: n,
3523
+ badge: r,
3453
3524
  ...o
3454
- } = t, i = Fe();
3525
+ } = t, e[0] = t, e[1] = n, e[2] = r, e[3] = i, e[4] = o) : (n = e[1], r = e[2], i = e[3], o = e[4]);
3526
+ const s = Me();
3527
+ let a;
3528
+ e[5] !== n || e[6] !== s ? (a = Ne(s, n, "div"), e[5] = n, e[6] = s, e[7] = a) : a = e[7];
3529
+ const c = a, l = r?.id;
3530
+ let u;
3531
+ return e[8] !== c || e[9] !== i || e[10] !== o || e[11] !== l ? (u = /* @__PURE__ */ F.jsx(c, { ...o, "data-badge-id": l, children: i }), e[8] = c, e[9] = i, e[10] = o, e[11] = l, e[12] = u) : u = e[12], u;
3532
+ }, mn = (t) => {
3533
+ const e = U.c(8), {
3534
+ badge: n,
3535
+ asChild: r,
3536
+ ...i
3537
+ } = t, o = Me();
3455
3538
  let s;
3456
- e[0] !== n || e[1] !== i ? (s = Re(i, n, "img"), e[0] = n, e[1] = i, e[2] = s) : s = e[2];
3457
- const a = s, c = On(o, i), u = r.asset?.preview;
3458
- let l;
3459
- return e[3] !== a || e[4] !== r.collection.name || e[5] !== u || e[6] !== c ? (l = /* @__PURE__ */ q.jsx(a, { src: u, alt: r.collection.name, "data-badge-name": r.collection.name, ...c }), e[3] = a, e[4] = r.collection.name, e[5] = u, e[6] = c, e[7] = l) : l = e[7], l;
3539
+ e[0] !== r || e[1] !== o ? (s = Ne(o, r, "img"), e[0] = r, e[1] = o, e[2] = s) : s = e[2];
3540
+ const a = s, c = vn(i, o), l = n.asset?.preview;
3541
+ let u;
3542
+ return e[3] !== a || e[4] !== n.collection.name || e[5] !== l || e[6] !== c ? (u = /* @__PURE__ */ F.jsx(a, { src: l, alt: n.collection.name, "data-badge-name": n.collection.name, ...c }), e[3] = a, e[4] = n.collection.name, e[5] = l, e[6] = c, e[7] = u) : u = e[7], u;
3460
3543
  };
3461
- hn.displayName = "ProductBadgeGroup";
3462
- yn.displayName = "ProductBadgeItem";
3463
- gn.displayName = "ProductBadgeImage";
3464
- const di = {
3465
- Root: mn,
3466
- Group: hn,
3467
- Item: yn,
3468
- Image: gn
3544
+ fn.displayName = "ProductBadgeGroup";
3545
+ pn.displayName = "ProductBadgeItem";
3546
+ mn.displayName = "ProductBadgeImage";
3547
+ const oo = {
3548
+ Root: dn,
3549
+ Group: fn,
3550
+ Item: pn,
3551
+ Image: mn
3469
3552
  };
3470
- function Vo(t, e) {
3553
+ function ji(t, e) {
3471
3554
  return t[e.position] || (t[e.position] = []), t[e.position].push(e), t;
3472
3555
  }
3473
3556
  export {
3474
- di as ProductBadge,
3557
+ oo as ProductBadge,
3475
3558
  ee as VendureBadgePlugin
3476
3559
  };