@flyfish-group/file-viewer3 1.0.0 → 1.0.1

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 (66) hide show
  1. package/README.md +1 -1
  2. package/dist/components/ImageViewer.js +795 -743
  3. package/dist/components/MarkdownViewer.js +990 -1099
  4. package/dist/components/PdfView.js +20049 -19079
  5. package/dist/components/PptxRender.js +7101 -6518
  6. package/dist/components/XlsxTable.js +48841 -64918
  7. package/dist/components/_commonjsHelpers.js +15 -21
  8. package/dist/components/docx-preview.js +5622 -0
  9. package/dist/components/index.js +819 -702
  10. package/dist/components/utils.d.ts +3 -0
  11. package/dist/index.umd.js +193 -382
  12. package/dist/main.d.ts +0 -0
  13. package/dist/package/components/FileViewer/FileViewer.vue.d.ts +18 -0
  14. package/dist/package/vendors/image/ImageViewer.vue.d.ts +15 -0
  15. package/dist/package/vendors/md/MarkdownViewer.vue.d.ts +15 -0
  16. package/dist/package/vendors/pdf/PdfView.vue.d.ts +15 -0
  17. package/dist/package/vendors/pptx/PptxRender.vue.d.ts +87 -0
  18. package/dist/{src/package → package}/vendors/pptx/index.d.ts +1 -1
  19. package/dist/{src/package → package}/vendors/renders.d.ts +1 -1
  20. package/dist/package/vendors/text/CodeViewer.vue.d.ts +15 -0
  21. package/dist/package/vendors/xlsx/XlsxTable.vue.d.ts +17 -0
  22. package/dist/package/vendors/xlsx/worker/xls/sheet.worker.d.ts +1 -0
  23. package/dist/package/vendors/xlsx/worker/xlsx/xlsx.worker.d.ts +2 -0
  24. package/dist/style.css +23 -23
  25. package/dist/worker/pdf.worker.js +37 -45
  26. package/dist/worker/pptx.worker.js +7 -7
  27. package/dist/worker/sheet.worker.js +24 -24
  28. package/dist/worker/xlsx.worker.js +43 -46
  29. package/package.json +21 -20
  30. package/dist/components/docx-preview.min.js +0 -5287
  31. package/dist/src/package/components/FileViewer/FileViewer.vue.d.ts +0 -25
  32. package/dist/src/package/vendors/image/ImageViewer.vue.d.ts +0 -13
  33. package/dist/src/package/vendors/md/MarkdownViewer.vue.d.ts +0 -13
  34. package/dist/src/package/vendors/pdf/PdfView.vue.d.ts +0 -13
  35. package/dist/src/package/vendors/pptx/PptxRender.vue.d.ts +0 -81
  36. package/dist/src/package/vendors/text/CodeViewer.vue.d.ts +0 -13
  37. package/dist/src/package/vendors/xlsx/XlsxTable.vue.d.ts +0 -21
  38. /package/dist/{src/package → package}/common/type.d.ts +0 -0
  39. /package/dist/{src/package → package}/common/util.d.ts +0 -0
  40. /package/dist/{src/package → package}/common/worker-ref.d.ts +0 -0
  41. /package/dist/{src/package → package}/components/FileViewer/index.d.ts +0 -0
  42. /package/dist/{src/package → package}/components/FileViewer/util.d.ts +0 -0
  43. /package/dist/{src/package → package}/index.d.ts +0 -0
  44. /package/dist/{src/package → package}/use/index.d.ts +0 -0
  45. /package/dist/{src/package → package}/use/worker.d.ts +0 -0
  46. /package/dist/{src/package → package}/vendors/docx/index.d.ts +0 -0
  47. /package/dist/{src/package → package}/vendors/image/index.d.ts +0 -0
  48. /package/dist/{src/package → package}/vendors/md/index.d.ts +0 -0
  49. /package/dist/{src/package → package}/vendors/mp4/index.d.ts +0 -0
  50. /package/dist/{src/package → package}/vendors/pdf/index.d.ts +0 -0
  51. /package/dist/{src/package → package}/vendors/pdf/worker/index.d.ts +0 -0
  52. /package/dist/{src/package → package}/vendors/pptx/options.d.ts +0 -0
  53. /package/dist/{src/package → package}/vendors/pptx/support/chart.d.ts +0 -0
  54. /package/dist/{src/package → package}/vendors/pptx/worker/index.d.ts +0 -0
  55. /package/dist/{src/package → package}/vendors/text/index.d.ts +0 -0
  56. /package/dist/{src/package → package}/vendors/xlsx/index.d.ts +0 -0
  57. /package/dist/{src/package → package}/vendors/xlsx/render.d.ts +0 -0
  58. /package/dist/{src/package → package}/vendors/xlsx/util.d.ts +0 -0
  59. /package/dist/{src/package → package}/vendors/xlsx/worker/index.d.ts +0 -0
  60. /package/dist/{src/package → package}/vendors/xlsx/worker/xls/SheetJsModel.d.ts +0 -0
  61. /package/dist/{src/package → package}/vendors/xlsx/worker/xls/index.d.ts +0 -0
  62. /package/dist/{src/package → package}/vendors/xlsx/worker/xlsx/ExcelJsModel.d.ts +0 -0
  63. /package/dist/{src/package → package}/vendors/xlsx/worker/xlsx/color.d.ts +0 -0
  64. /package/dist/{src/package → package}/vendors/xlsx/worker/xlsx/context.d.ts +0 -0
  65. /package/dist/{src/package → package}/vendors/xlsx/worker/xlsx/index.d.ts +0 -0
  66. /package/dist/{src/package → package}/vendors/xlsx/worker/xlsx/util.d.ts +0 -0
@@ -1,235 +1,307 @@
1
- var et = Object.defineProperty;
2
- var tt = (e, t, n) => t in e ? et(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
3
- var pe = (e, t, n) => (tt(e, typeof t != "symbol" ? t + "" : t, n), n);
4
- import { defineAsyncComponent as D, createApp as P, createVNode as N, defineComponent as Ne, openBlock as I, createElementBlock as M, toDisplayString as H, ref as F, onMounted as nt, watch as he, createElementVNode as Q, Fragment as rt, withDirectives as me, vShow as ye } from "vue";
5
- const st = (() => {
1
+ var it = Object.defineProperty;
2
+ var ye = Object.getOwnPropertySymbols;
3
+ var at = Object.prototype.hasOwnProperty, ct = Object.prototype.propertyIsEnumerable;
4
+ var Z = (e, t, n) => t in e ? it(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, Y = (e, t) => {
5
+ for (var n in t || (t = {}))
6
+ at.call(t, n) && Z(e, n, t[n]);
7
+ if (ye)
8
+ for (var n of ye(t))
9
+ ct.call(t, n) && Z(e, n, t[n]);
10
+ return e;
11
+ };
12
+ var we = (e, t, n) => (Z(e, typeof t != "symbol" ? t + "" : t, n), n);
13
+ var w = (e, t, n) => new Promise((r, s) => {
14
+ var o = (u) => {
15
+ try {
16
+ l(n.next(u));
17
+ } catch (p) {
18
+ s(p);
19
+ }
20
+ }, i = (u) => {
21
+ try {
22
+ l(n.throw(u));
23
+ } catch (p) {
24
+ s(p);
25
+ }
26
+ }, l = (u) => u.done ? r(u.value) : Promise.resolve(u.value).then(o, i);
27
+ l((n = n.apply(e, t)).next());
28
+ });
29
+ import { defineAsyncComponent as k, createApp as N, createVNode as F, defineComponent as Ue, openBlock as H, createElementBlock as M, toDisplayString as q, ref as B, onMounted as lt, watch as Ee, createElementVNode as ee, Fragment as ut, withDirectives as be, vShow as Re } from "vue";
30
+ const ft = (() => {
6
31
  const e = {
7
32
  module: null,
8
- async load() {
9
- return this.module || (this.module = import("./docx-preview.min.js").then((t) => t.d)), this.module;
33
+ load() {
34
+ return w(this, null, function* () {
35
+ return this.module || (this.module = import("./docx-preview.js")), this.module;
36
+ });
10
37
  }
11
38
  };
12
- return async () => await e.load();
39
+ return () => w(void 0, null, function* () {
40
+ return yield e.load();
41
+ });
13
42
  })();
14
- async function ot(e, t) {
15
- const { defaultOptions: n, renderAsync: r } = await st(), s = Object.assign(n, {
16
- debug: !0,
17
- experimental: !0
43
+ function dt(e, t) {
44
+ return w(this, null, function* () {
45
+ const { defaultOptions: n, renderAsync: r } = yield ft(), s = Object.assign(n, {
46
+ debug: !0,
47
+ experimental: !0
48
+ });
49
+ yield r(e, t, void 0, s);
18
50
  });
19
- await r(e, t, void 0, s);
20
51
  }
21
- const it = D(() => import("./PptxRender.js"));
22
- async function at(e, t) {
23
- return P({
24
- render: () => N(it, {
25
- data: e
26
- }, null)
27
- }).mount(t);
52
+ const pt = k(() => import("./PptxRender.js"));
53
+ function ht(e, t) {
54
+ return w(this, null, function* () {
55
+ return N({
56
+ render: () => F(pt, {
57
+ data: e
58
+ }, null)
59
+ }).mount(t);
60
+ });
28
61
  }
29
- const ct = D(() => import("./XlsxTable.js"));
30
- async function we(e, t, n) {
31
- const r = P({
32
- render: () => N(ct, {
33
- data: e,
34
- type: n
35
- }, null)
62
+ const mt = k(() => import("./XlsxTable.js"));
63
+ function Se(e, t, n) {
64
+ return w(this, null, function* () {
65
+ const r = N({
66
+ render: () => F(mt, {
67
+ data: e,
68
+ type: n
69
+ }, null)
70
+ });
71
+ return r.mount(t), r;
36
72
  });
37
- return r.mount(t), r;
38
73
  }
39
- const ut = D(() => import("./PdfView.js"));
40
- async function lt(e, t) {
41
- const n = P({
42
- render: () => N(ut, {
43
- data: e
44
- }, null)
74
+ const yt = k(() => import("./PdfView.js"));
75
+ function wt(e, t) {
76
+ return w(this, null, function* () {
77
+ const n = N({
78
+ render: () => F(yt, {
79
+ data: e
80
+ }, null)
81
+ });
82
+ return n.mount(t), n;
45
83
  });
46
- return n.mount(t), n;
47
84
  }
48
- async function ft(e) {
49
- return new Promise((t, n) => {
50
- const r = new FileReader();
51
- r.onload = (s) => {
52
- var o;
53
- return t((o = s.target) == null ? void 0 : o.result);
54
- }, r.onerror = (s) => n(s), r.readAsArrayBuffer(e);
85
+ function Et(e) {
86
+ return w(this, null, function* () {
87
+ return new Promise((t, n) => {
88
+ const r = new FileReader();
89
+ r.onload = (s) => {
90
+ var o;
91
+ return t((o = s.target) == null ? void 0 : o.result);
92
+ }, r.onerror = (s) => n(s), r.readAsArrayBuffer(e);
93
+ });
55
94
  });
56
95
  }
57
- async function dt(e) {
58
- return new Promise((t, n) => {
59
- const r = new FileReader();
60
- r.onload = (s) => {
61
- var i;
62
- const o = (i = s.target) == null ? void 0 : i.result;
63
- typeof o == "string" && t(o);
64
- }, r.onerror = (s) => n(s), r.readAsDataURL(new Blob([e]));
96
+ function bt(e) {
97
+ return w(this, null, function* () {
98
+ return new Promise((t, n) => {
99
+ const r = new FileReader();
100
+ r.onload = (s) => {
101
+ var i;
102
+ const o = (i = s.target) == null ? void 0 : i.result;
103
+ typeof o == "string" && t(o);
104
+ }, r.onerror = (s) => n(s), r.readAsDataURL(new Blob([e]));
105
+ });
65
106
  });
66
107
  }
67
- async function Ce(e) {
68
- return new Promise((t, n) => {
69
- const r = new FileReader();
70
- r.onload = (s) => {
71
- var i;
72
- const o = (i = s.target) == null ? void 0 : i.result;
73
- typeof o == "string" && t(o);
74
- }, r.onerror = (s) => n(s), r.readAsText(new Blob([e]), "utf-8");
108
+ function De(e) {
109
+ return w(this, null, function* () {
110
+ return new Promise((t, n) => {
111
+ const r = new FileReader();
112
+ r.onload = (s) => {
113
+ var i;
114
+ const o = (i = s.target) == null ? void 0 : i.result;
115
+ typeof o == "string" && t(o);
116
+ }, r.onerror = (s) => n(s), r.readAsText(new Blob([e]), "utf-8");
117
+ });
75
118
  });
76
119
  }
77
- const pt = D(() => import("./ImageViewer.js"));
78
- async function ht(e, t) {
79
- const n = await dt(e), r = P({
80
- render: () => N(pt, {
81
- image: n
82
- }, null)
120
+ const Rt = k(() => import("./ImageViewer.js"));
121
+ function St(e, t) {
122
+ return w(this, null, function* () {
123
+ const n = yield bt(e), r = N({
124
+ render: () => F(Rt, {
125
+ image: n
126
+ }, null)
127
+ });
128
+ return r.mount(t), r;
83
129
  });
84
- return r.mount(t), r;
85
130
  }
86
- const mt = D(() => import("./MarkdownViewer.js"));
87
- async function yt(e, t) {
88
- const n = await Ce(e), r = P({
89
- render: () => N(mt, {
90
- data: n
91
- }, null)
131
+ const gt = k(() => import("./MarkdownViewer.js"));
132
+ function Ot(e, t) {
133
+ return w(this, null, function* () {
134
+ const n = yield De(e), r = N({
135
+ render: () => F(gt, {
136
+ data: n
137
+ }, null)
138
+ });
139
+ return r.mount(t), r;
92
140
  });
93
- return r.mount(t), r;
94
141
  }
95
- const wt = { class: "code-area" }, Et = /* @__PURE__ */ Ne({
142
+ const xt = { class: "code-area" }, At = /* @__PURE__ */ Ue({
96
143
  __name: "CodeViewer",
97
144
  props: {
98
- value: null
145
+ value: {}
99
146
  },
100
147
  setup(e) {
101
- return (t, n) => (I(), M("pre", wt, " " + H(e.value) + `
148
+ return (t, n) => (H(), M("pre", xt, " " + q(t.value) + `
102
149
  `, 1));
103
150
  }
104
151
  });
105
- const Fe = (e, t) => {
152
+ const ke = (e, t) => {
106
153
  const n = e.__vccOpts || e;
107
154
  for (const [r, s] of t)
108
155
  n[r] = s;
109
156
  return n;
110
- }, bt = /* @__PURE__ */ Fe(Et, [["__scopeId", "data-v-3be501eb"]]);
111
- async function Rt(e, t) {
112
- const n = await Ce(e), r = P({
113
- render: () => N(bt, {
114
- value: n
115
- }, null)
157
+ }, _t = /* @__PURE__ */ ke(At, [["__scopeId", "data-v-3be501eb"]]);
158
+ function Tt(e, t) {
159
+ return w(this, null, function* () {
160
+ const n = yield De(e), r = N({
161
+ render: () => F(_t, {
162
+ value: n
163
+ }, null)
164
+ });
165
+ return r.mount(t), r;
116
166
  });
117
- return r.mount(t), r;
118
167
  }
119
- function St(e, t) {
168
+ function Pt(e, t) {
120
169
  const n = document.createElement("video");
121
170
  n.width = 840, n.height = 480, n.controls = !0;
122
171
  const r = document.createElement("source");
123
172
  r.src = URL.createObjectURL(new Blob([e])), n.appendChild(r), t.appendChild(n);
124
173
  }
125
- const v = (e) => ({
174
+ const I = (e) => ({
126
175
  $el: e,
127
176
  unmount() {
128
177
  }
129
- }), gt = [
178
+ }), Ct = [
130
179
  // 使用docxjs支持,目前效果最好的渲染器
131
180
  {
132
181
  accepts: ["docx"],
133
- handler: async (e, t) => (await ot(e, t), window.dispatchEvent(new Event("resize")), v(t))
182
+ handler: (e, t) => w(void 0, null, function* () {
183
+ return yield dt(e, t), window.dispatchEvent(new Event("resize")), I(t);
184
+ })
134
185
  },
135
186
  // 使用pptx2html,已通过默认值更替
136
187
  {
137
188
  accepts: ["pptx"],
138
- handler: async (e, t) => (await at(e, t), window.dispatchEvent(new Event("resize")), v(t))
189
+ handler: (e, t) => w(void 0, null, function* () {
190
+ return yield ht(e, t), window.dispatchEvent(new Event("resize")), I(t);
191
+ })
139
192
  },
140
193
  // 使用exceljs + handsontable,全部样式
141
194
  {
142
195
  accepts: ["xlsx"],
143
- handler: async (e, t) => we(e, t, "xml")
196
+ handler: (e, t) => w(void 0, null, function* () {
197
+ return Se(e, t, "xml");
198
+ })
144
199
  },
145
200
  // 使用js-xlsx + handsontable,无样式
146
201
  {
147
202
  accepts: ["xlsm", "xlsb", "xls", "csv", "ods", "fods", "numbers"],
148
- handler: async (e, t) => we(e, t, "binary")
203
+ handler: (e, t) => w(void 0, null, function* () {
204
+ return Se(e, t, "binary");
205
+ })
149
206
  },
150
207
  // 使用pdfjs,渲染pdf,效果最好
151
208
  {
152
209
  accepts: ["pdf"],
153
- handler: async (e, t) => lt(e, t)
210
+ handler: (e, t) => w(void 0, null, function* () {
211
+ return wt(e, t);
212
+ })
154
213
  },
155
214
  // 图片过滤器
156
215
  {
157
216
  accepts: ["gif", "jpg", "jpeg", "bmp", "tiff", "tif", "png", "svg"],
158
- handler: async (e, t) => ht(e, t)
217
+ handler: (e, t) => w(void 0, null, function* () {
218
+ return St(e, t);
219
+ })
159
220
  },
160
221
  {
161
222
  accepts: ["md", "markdown"],
162
- handler: async (e, t) => yt(e, t)
223
+ handler: (e, t) => w(void 0, null, function* () {
224
+ return Ot(e, t);
225
+ })
163
226
  },
164
227
  // 纯文本预览
165
228
  {
166
229
  accepts: ["txt", "json", "js", "css", "java", "py", "html", "jsx", "ts", "tsx", "xml", "log"],
167
- handler: async (e, t) => Rt(e, t)
230
+ handler: (e, t) => w(void 0, null, function* () {
231
+ return Tt(e, t);
232
+ })
168
233
  },
169
234
  // 视频预览,仅支持MP4
170
235
  {
171
236
  accepts: ["mp4"],
172
- handler: async (e, t) => (St(e, t), v(t))
237
+ handler: (e, t) => w(void 0, null, function* () {
238
+ return Pt(e, t), I(t);
239
+ })
173
240
  },
174
241
  // 错误处理
175
242
  {
176
243
  accepts: ["error"],
177
- handler: async (e, t, n) => (t.innerHTML = `<div style='text-align: center; margin-top: 80px'>不支持.${n}格式的在线预览,请下载后预览或转换为支持的格式</div>
178
- <div style='text-align: center'>支持docx, xlsx, pptx, pdf, 以及纯文本格式和各种图片格式的在线预览</div>`, v(t))
244
+ handler: (e, t, n) => w(void 0, null, function* () {
245
+ return t.innerHTML = `<div style='text-align: center; margin-top: 80px'>不支持.${n}格式的在线预览,请下载后预览或转换为支持的格式</div>
246
+ <div style='text-align: center'>支持docx, xlsx, pptx, pdf, 以及纯文本格式和各种图片格式的在线预览</div>`, I(t);
247
+ })
179
248
  }
180
- ], Le = gt.reduce((e, { accepts: t, handler: n }) => (t.forEach((r) => e.set(r, n)), e), /* @__PURE__ */ new Map()), Ee = Le.get("error");
181
- function Ot(e) {
249
+ ], je = Ct.reduce((e, { accepts: t, handler: n }) => (t.forEach((r) => e.set(r, n)), e), /* @__PURE__ */ new Map()), ge = je.get("error");
250
+ function Nt(e) {
182
251
  const t = e.lastIndexOf(".");
183
252
  return e.substring(t + 1);
184
253
  }
185
- async function xt(e, t, n) {
186
- const r = Le.get(t.toLowerCase());
187
- if (r)
188
- return r(e, n);
189
- if (Ee)
190
- return Ee(e, n, t);
254
+ function Ft(e, t, n) {
255
+ return w(this, null, function* () {
256
+ const r = je.get(t.toLowerCase());
257
+ if (r)
258
+ return r(e, n);
259
+ if (ge)
260
+ return ge(e, n, t);
261
+ });
191
262
  }
192
- function Be(e, t) {
263
+ function ve(e, t) {
193
264
  return function() {
194
265
  return e.apply(t, arguments);
195
266
  };
196
267
  }
197
- const { toString: De } = Object.prototype, { getPrototypeOf: ie } = Object, ae = ((e) => (t) => {
198
- const n = De.call(t);
268
+ const { toString: Lt } = Object.prototype, { getPrototypeOf: ue } = Object, W = ((e) => (t) => {
269
+ const n = Lt.call(t);
199
270
  return e[n] || (e[n] = n.slice(8, -1).toLowerCase());
200
- })(/* @__PURE__ */ Object.create(null)), O = (e) => (e = e.toLowerCase(), (t) => ae(t) === e), W = (e) => (t) => typeof t === e, { isArray: C } = Array, B = W("undefined");
201
- function At(e) {
202
- return e !== null && !B(e) && e.constructor !== null && !B(e.constructor) && _(e.constructor.isBuffer) && e.constructor.isBuffer(e);
271
+ })(/* @__PURE__ */ Object.create(null)), _ = (e) => (e = e.toLowerCase(), (t) => W(t) === e), K = (e) => (t) => typeof t === e, { isArray: L } = Array, D = K("undefined");
272
+ function Bt(e) {
273
+ return e !== null && !D(e) && e.constructor !== null && !D(e.constructor) && g(e.constructor.isBuffer) && e.constructor.isBuffer(e);
203
274
  }
204
- const Ue = O("ArrayBuffer");
205
- function _t(e) {
275
+ const Ie = _("ArrayBuffer");
276
+ function Ut(e) {
206
277
  let t;
207
- return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? t = ArrayBuffer.isView(e) : t = e && e.buffer && Ue(e.buffer), t;
278
+ return typeof ArrayBuffer != "undefined" && ArrayBuffer.isView ? t = ArrayBuffer.isView(e) : t = e && e.buffer && Ie(e.buffer), t;
208
279
  }
209
- const Tt = W("string"), _ = W("function"), je = W("number"), ce = (e) => e !== null && typeof e == "object", Pt = (e) => e === !0 || e === !1, q = (e) => {
210
- if (ae(e) !== "object")
280
+ const Dt = K("string"), g = K("function"), He = K("number"), X = (e) => e !== null && typeof e == "object", kt = (e) => e === !0 || e === !1, z = (e) => {
281
+ if (W(e) !== "object")
211
282
  return !1;
212
- const t = ie(e);
283
+ const t = ue(e);
213
284
  return (t === null || t === Object.prototype || Object.getPrototypeOf(t) === null) && !(Symbol.toStringTag in e) && !(Symbol.iterator in e);
214
- }, Nt = O("Date"), Ct = O("File"), Ft = O("Blob"), Lt = O("FileList"), Bt = (e) => ce(e) && _(e.pipe), Dt = (e) => {
215
- const t = "[object FormData]";
216
- return e && (typeof FormData == "function" && e instanceof FormData || De.call(e) === t || _(e.toString) && e.toString() === t);
217
- }, Ut = O("URLSearchParams"), jt = (e) => e.trim ? e.trim() : e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
218
- function U(e, t, { allOwnKeys: n = !1 } = {}) {
219
- if (e === null || typeof e > "u")
285
+ }, jt = _("Date"), vt = _("File"), It = _("Blob"), Ht = _("FileList"), Mt = (e) => X(e) && g(e.pipe), qt = (e) => {
286
+ let t;
287
+ return e && (typeof FormData == "function" && e instanceof FormData || g(e.append) && ((t = W(e)) === "formdata" || // detect form-data instance
288
+ t === "object" && g(e.toString) && e.toString() === "[object FormData]"));
289
+ }, zt = _("URLSearchParams"), Vt = (e) => e.trim ? e.trim() : e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
290
+ function j(e, t, { allOwnKeys: n = !1 } = {}) {
291
+ if (e === null || typeof e == "undefined")
220
292
  return;
221
293
  let r, s;
222
- if (typeof e != "object" && (e = [e]), C(e))
294
+ if (typeof e != "object" && (e = [e]), L(e))
223
295
  for (r = 0, s = e.length; r < s; r++)
224
296
  t.call(null, e[r], r, e);
225
297
  else {
226
298
  const o = n ? Object.getOwnPropertyNames(e) : Object.keys(e), i = o.length;
227
- let u;
299
+ let l;
228
300
  for (r = 0; r < i; r++)
229
- u = o[r], t.call(null, e[u], u, e);
301
+ l = o[r], t.call(null, e[l], l, e);
230
302
  }
231
303
  }
232
- function ke(e, t) {
304
+ function Me(e, t) {
233
305
  t = t.toLowerCase();
234
306
  const n = Object.keys(e);
235
307
  let r = n.length, s;
@@ -238,78 +310,79 @@ function ke(e, t) {
238
310
  return s;
239
311
  return null;
240
312
  }
241
- const ve = (() => typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : global)(), Ie = (e) => !B(e) && e !== ve;
242
- function ne() {
243
- const { caseless: e } = Ie(this) && this || {}, t = {}, n = (r, s) => {
244
- const o = e && ke(t, s) || s;
245
- q(t[o]) && q(r) ? t[o] = ne(t[o], r) : q(r) ? t[o] = ne({}, r) : C(r) ? t[o] = r.slice() : t[o] = r;
313
+ const qe = (() => typeof globalThis != "undefined" ? globalThis : typeof self != "undefined" ? self : typeof window != "undefined" ? window : global)(), ze = (e) => !D(e) && e !== qe;
314
+ function oe() {
315
+ const { caseless: e } = ze(this) && this || {}, t = {}, n = (r, s) => {
316
+ const o = e && Me(t, s) || s;
317
+ z(t[o]) && z(r) ? t[o] = oe(t[o], r) : z(r) ? t[o] = oe({}, r) : L(r) ? t[o] = r.slice() : t[o] = r;
246
318
  };
247
319
  for (let r = 0, s = arguments.length; r < s; r++)
248
- arguments[r] && U(arguments[r], n);
320
+ arguments[r] && j(arguments[r], n);
249
321
  return t;
250
322
  }
251
- const kt = (e, t, n, { allOwnKeys: r } = {}) => (U(t, (s, o) => {
252
- n && _(s) ? e[o] = Be(s, n) : e[o] = s;
253
- }, { allOwnKeys: r }), e), vt = (e) => (e.charCodeAt(0) === 65279 && (e = e.slice(1)), e), It = (e, t, n, r) => {
323
+ const $t = (e, t, n, { allOwnKeys: r } = {}) => (j(t, (s, o) => {
324
+ n && g(s) ? e[o] = ve(s, n) : e[o] = s;
325
+ }, { allOwnKeys: r }), e), Jt = (e) => (e.charCodeAt(0) === 65279 && (e = e.slice(1)), e), Wt = (e, t, n, r) => {
254
326
  e.prototype = Object.create(t.prototype, r), e.prototype.constructor = e, Object.defineProperty(e, "super", {
255
327
  value: t.prototype
256
328
  }), n && Object.assign(e.prototype, n);
257
- }, Mt = (e, t, n, r) => {
329
+ }, Kt = (e, t, n, r) => {
258
330
  let s, o, i;
259
- const u = {};
331
+ const l = {};
260
332
  if (t = t || {}, e == null)
261
333
  return t;
262
334
  do {
263
335
  for (s = Object.getOwnPropertyNames(e), o = s.length; o-- > 0; )
264
- i = s[o], (!r || r(i, e, t)) && !u[i] && (t[i] = e[i], u[i] = !0);
265
- e = n !== !1 && ie(e);
336
+ i = s[o], (!r || r(i, e, t)) && !l[i] && (t[i] = e[i], l[i] = !0);
337
+ e = n !== !1 && ue(e);
266
338
  } while (e && (!n || n(e, t)) && e !== Object.prototype);
267
339
  return t;
268
- }, Ht = (e, t, n) => {
340
+ }, Xt = (e, t, n) => {
269
341
  e = String(e), (n === void 0 || n > e.length) && (n = e.length), n -= t.length;
270
342
  const r = e.indexOf(t, n);
271
343
  return r !== -1 && r === n;
272
- }, qt = (e) => {
344
+ }, Gt = (e) => {
273
345
  if (!e)
274
346
  return null;
275
- if (C(e))
347
+ if (L(e))
276
348
  return e;
277
349
  let t = e.length;
278
- if (!je(t))
350
+ if (!He(t))
279
351
  return null;
280
352
  const n = new Array(t);
281
353
  for (; t-- > 0; )
282
354
  n[t] = e[t];
283
355
  return n;
284
- }, Vt = ((e) => (t) => e && t instanceof e)(typeof Uint8Array < "u" && ie(Uint8Array)), zt = (e, t) => {
356
+ }, Qt = ((e) => (t) => e && t instanceof e)(typeof Uint8Array != "undefined" && ue(Uint8Array)), Zt = (e, t) => {
285
357
  const r = (e && e[Symbol.iterator]).call(e);
286
358
  let s;
287
359
  for (; (s = r.next()) && !s.done; ) {
288
360
  const o = s.value;
289
361
  t.call(e, o[0], o[1]);
290
362
  }
291
- }, Jt = (e, t) => {
363
+ }, Yt = (e, t) => {
292
364
  let n;
293
365
  const r = [];
294
366
  for (; (n = e.exec(t)) !== null; )
295
367
  r.push(n);
296
368
  return r;
297
- }, $t = O("HTMLFormElement"), Wt = (e) => e.toLowerCase().replace(
369
+ }, en = _("HTMLFormElement"), tn = (e) => e.toLowerCase().replace(
298
370
  /[-_\s]([a-z\d])(\w*)/g,
299
371
  function(n, r, s) {
300
372
  return r.toUpperCase() + s;
301
373
  }
302
- ), be = (({ hasOwnProperty: e }) => (t, n) => e.call(t, n))(Object.prototype), Kt = O("RegExp"), Me = (e, t) => {
374
+ ), Oe = (({ hasOwnProperty: e }) => (t, n) => e.call(t, n))(Object.prototype), nn = _("RegExp"), Ve = (e, t) => {
303
375
  const n = Object.getOwnPropertyDescriptors(e), r = {};
304
- U(n, (s, o) => {
305
- t(s, o, e) !== !1 && (r[o] = s);
376
+ j(n, (s, o) => {
377
+ let i;
378
+ (i = t(s, o, e)) !== !1 && (r[o] = i || s);
306
379
  }), Object.defineProperties(e, r);
307
- }, Gt = (e) => {
308
- Me(e, (t, n) => {
309
- if (_(e) && ["arguments", "caller", "callee"].indexOf(n) !== -1)
380
+ }, rn = (e) => {
381
+ Ve(e, (t, n) => {
382
+ if (g(e) && ["arguments", "caller", "callee"].indexOf(n) !== -1)
310
383
  return !1;
311
384
  const r = e[n];
312
- if (_(r)) {
385
+ if (g(r)) {
313
386
  if (t.enumerable = !1, "writable" in t) {
314
387
  t.writable = !1;
315
388
  return;
@@ -319,96 +392,98 @@ const kt = (e, t, n, { allOwnKeys: r } = {}) => (U(t, (s, o) => {
319
392
  });
320
393
  }
321
394
  });
322
- }, Xt = (e, t) => {
395
+ }, sn = (e, t) => {
323
396
  const n = {}, r = (s) => {
324
397
  s.forEach((o) => {
325
398
  n[o] = !0;
326
399
  });
327
400
  };
328
- return C(e) ? r(e) : r(String(e).split(t)), n;
329
- }, Qt = () => {
330
- }, Yt = (e, t) => (e = +e, Number.isFinite(e) ? e : t), Y = "abcdefghijklmnopqrstuvwxyz", Re = "0123456789", He = {
331
- DIGIT: Re,
332
- ALPHA: Y,
333
- ALPHA_DIGIT: Y + Y.toUpperCase() + Re
334
- }, Zt = (e = 16, t = He.ALPHA_DIGIT) => {
401
+ return L(e) ? r(e) : r(String(e).split(t)), n;
402
+ }, on = () => {
403
+ }, an = (e, t) => (e = +e, Number.isFinite(e) ? e : t), te = "abcdefghijklmnopqrstuvwxyz", xe = "0123456789", $e = {
404
+ DIGIT: xe,
405
+ ALPHA: te,
406
+ ALPHA_DIGIT: te + te.toUpperCase() + xe
407
+ }, cn = (e = 16, t = $e.ALPHA_DIGIT) => {
335
408
  let n = "";
336
409
  const { length: r } = t;
337
410
  for (; e--; )
338
411
  n += t[Math.random() * r | 0];
339
412
  return n;
340
413
  };
341
- function en(e) {
342
- return !!(e && _(e.append) && e[Symbol.toStringTag] === "FormData" && e[Symbol.iterator]);
414
+ function ln(e) {
415
+ return !!(e && g(e.append) && e[Symbol.toStringTag] === "FormData" && e[Symbol.iterator]);
343
416
  }
344
- const tn = (e) => {
417
+ const un = (e) => {
345
418
  const t = new Array(10), n = (r, s) => {
346
- if (ce(r)) {
419
+ if (X(r)) {
347
420
  if (t.indexOf(r) >= 0)
348
421
  return;
349
422
  if (!("toJSON" in r)) {
350
423
  t[s] = r;
351
- const o = C(r) ? [] : {};
352
- return U(r, (i, u) => {
353
- const p = n(i, s + 1);
354
- !B(p) && (o[u] = p);
424
+ const o = L(r) ? [] : {};
425
+ return j(r, (i, l) => {
426
+ const u = n(i, s + 1);
427
+ !D(u) && (o[l] = u);
355
428
  }), t[s] = void 0, o;
356
429
  }
357
430
  }
358
431
  return r;
359
432
  };
360
433
  return n(e, 0);
361
- }, a = {
362
- isArray: C,
363
- isArrayBuffer: Ue,
364
- isBuffer: At,
365
- isFormData: Dt,
366
- isArrayBufferView: _t,
367
- isString: Tt,
368
- isNumber: je,
369
- isBoolean: Pt,
370
- isObject: ce,
371
- isPlainObject: q,
372
- isUndefined: B,
373
- isDate: Nt,
374
- isFile: Ct,
375
- isBlob: Ft,
376
- isRegExp: Kt,
377
- isFunction: _,
378
- isStream: Bt,
379
- isURLSearchParams: Ut,
380
- isTypedArray: Vt,
381
- isFileList: Lt,
382
- forEach: U,
383
- merge: ne,
384
- extend: kt,
385
- trim: jt,
386
- stripBOM: vt,
387
- inherits: It,
388
- toFlatObject: Mt,
389
- kindOf: ae,
390
- kindOfTest: O,
391
- endsWith: Ht,
392
- toArray: qt,
393
- forEachEntry: zt,
394
- matchAll: Jt,
395
- isHTMLForm: $t,
396
- hasOwnProperty: be,
397
- hasOwnProp: be,
434
+ }, fn = _("AsyncFunction"), dn = (e) => e && (X(e) || g(e)) && g(e.then) && g(e.catch), a = {
435
+ isArray: L,
436
+ isArrayBuffer: Ie,
437
+ isBuffer: Bt,
438
+ isFormData: qt,
439
+ isArrayBufferView: Ut,
440
+ isString: Dt,
441
+ isNumber: He,
442
+ isBoolean: kt,
443
+ isObject: X,
444
+ isPlainObject: z,
445
+ isUndefined: D,
446
+ isDate: jt,
447
+ isFile: vt,
448
+ isBlob: It,
449
+ isRegExp: nn,
450
+ isFunction: g,
451
+ isStream: Mt,
452
+ isURLSearchParams: zt,
453
+ isTypedArray: Qt,
454
+ isFileList: Ht,
455
+ forEach: j,
456
+ merge: oe,
457
+ extend: $t,
458
+ trim: Vt,
459
+ stripBOM: Jt,
460
+ inherits: Wt,
461
+ toFlatObject: Kt,
462
+ kindOf: W,
463
+ kindOfTest: _,
464
+ endsWith: Xt,
465
+ toArray: Gt,
466
+ forEachEntry: Zt,
467
+ matchAll: Yt,
468
+ isHTMLForm: en,
469
+ hasOwnProperty: Oe,
470
+ hasOwnProp: Oe,
398
471
  // an alias to avoid ESLint no-prototype-builtins detection
399
- reduceDescriptors: Me,
400
- freezeMethods: Gt,
401
- toObjectSet: Xt,
402
- toCamelCase: Wt,
403
- noop: Qt,
404
- toFiniteNumber: Yt,
405
- findKey: ke,
406
- global: ve,
407
- isContextDefined: Ie,
408
- ALPHABET: He,
409
- generateString: Zt,
410
- isSpecCompliantForm: en,
411
- toJSONObject: tn
472
+ reduceDescriptors: Ve,
473
+ freezeMethods: rn,
474
+ toObjectSet: sn,
475
+ toCamelCase: tn,
476
+ noop: on,
477
+ toFiniteNumber: an,
478
+ findKey: Me,
479
+ global: qe,
480
+ isContextDefined: ze,
481
+ ALPHABET: $e,
482
+ generateString: cn,
483
+ isSpecCompliantForm: ln,
484
+ toJSONObject: un,
485
+ isAsyncFn: fn,
486
+ isThenable: dn
412
487
  };
413
488
  function m(e, t, n, r, s) {
414
489
  Error.call(this), Error.captureStackTrace ? Error.captureStackTrace(this, this.constructor) : this.stack = new Error().stack, this.message = e, this.name = "AxiosError", t && (this.code = t), n && (this.config = n), r && (this.request = r), s && (this.response = s);
@@ -434,7 +509,7 @@ a.inherits(m, Error, {
434
509
  };
435
510
  }
436
511
  });
437
- const qe = m.prototype, Ve = {};
512
+ const Je = m.prototype, We = {};
438
513
  [
439
514
  "ERR_BAD_OPTION_VALUE",
440
515
  "ERR_BAD_OPTION",
@@ -450,97 +525,97 @@ const qe = m.prototype, Ve = {};
450
525
  "ERR_INVALID_URL"
451
526
  // eslint-disable-next-line func-names
452
527
  ].forEach((e) => {
453
- Ve[e] = { value: e };
528
+ We[e] = { value: e };
454
529
  });
455
- Object.defineProperties(m, Ve);
456
- Object.defineProperty(qe, "isAxiosError", { value: !0 });
530
+ Object.defineProperties(m, We);
531
+ Object.defineProperty(Je, "isAxiosError", { value: !0 });
457
532
  m.from = (e, t, n, r, s, o) => {
458
- const i = Object.create(qe);
459
- return a.toFlatObject(e, i, function(p) {
460
- return p !== Error.prototype;
461
- }, (u) => u !== "isAxiosError"), m.call(i, e.message, t, n, r, s), i.cause = e, i.name = e.name, o && Object.assign(i, o), i;
533
+ const i = Object.create(Je);
534
+ return a.toFlatObject(e, i, function(u) {
535
+ return u !== Error.prototype;
536
+ }, (l) => l !== "isAxiosError"), m.call(i, e.message, t, n, r, s), i.cause = e, i.name = e.name, o && Object.assign(i, o), i;
462
537
  };
463
- const nn = null;
464
- function re(e) {
538
+ const pn = null;
539
+ function ie(e) {
465
540
  return a.isPlainObject(e) || a.isArray(e);
466
541
  }
467
- function ze(e) {
542
+ function Ke(e) {
468
543
  return a.endsWith(e, "[]") ? e.slice(0, -2) : e;
469
544
  }
470
- function Se(e, t, n) {
545
+ function Ae(e, t, n) {
471
546
  return e ? e.concat(t).map(function(s, o) {
472
- return s = ze(s), !n && o ? "[" + s + "]" : s;
547
+ return s = Ke(s), !n && o ? "[" + s + "]" : s;
473
548
  }).join(n ? "." : "") : t;
474
549
  }
475
- function rn(e) {
476
- return a.isArray(e) && !e.some(re);
550
+ function hn(e) {
551
+ return a.isArray(e) && !e.some(ie);
477
552
  }
478
- const sn = a.toFlatObject(a, {}, null, function(t) {
553
+ const mn = a.toFlatObject(a, {}, null, function(t) {
479
554
  return /^is[A-Z]/.test(t);
480
555
  });
481
- function K(e, t, n) {
556
+ function G(e, t, n) {
482
557
  if (!a.isObject(e))
483
558
  throw new TypeError("target must be an object");
484
559
  t = t || new FormData(), n = a.toFlatObject(n, {
485
560
  metaTokens: !0,
486
561
  dots: !1,
487
562
  indexes: !1
488
- }, !1, function(h, R) {
489
- return !a.isUndefined(R[h]);
563
+ }, !1, function(d, b) {
564
+ return !a.isUndefined(b[d]);
490
565
  });
491
- const r = n.metaTokens, s = n.visitor || l, o = n.dots, i = n.indexes, p = (n.Blob || typeof Blob < "u" && Blob) && a.isSpecCompliantForm(t);
566
+ const r = n.metaTokens, s = n.visitor || f, o = n.dots, i = n.indexes, u = (n.Blob || typeof Blob != "undefined" && Blob) && a.isSpecCompliantForm(t);
492
567
  if (!a.isFunction(s))
493
568
  throw new TypeError("visitor must be a function");
494
- function c(f) {
495
- if (f === null)
569
+ function p(h) {
570
+ if (h === null)
496
571
  return "";
497
- if (a.isDate(f))
498
- return f.toISOString();
499
- if (!p && a.isBlob(f))
572
+ if (a.isDate(h))
573
+ return h.toISOString();
574
+ if (!u && a.isBlob(h))
500
575
  throw new m("Blob is not supported. Use a Buffer instead.");
501
- return a.isArrayBuffer(f) || a.isTypedArray(f) ? p && typeof Blob == "function" ? new Blob([f]) : Buffer.from(f) : f;
576
+ return a.isArrayBuffer(h) || a.isTypedArray(h) ? u && typeof Blob == "function" ? new Blob([h]) : Buffer.from(h) : h;
502
577
  }
503
- function l(f, h, R) {
504
- let b = f;
505
- if (f && !R && typeof f == "object") {
506
- if (a.endsWith(h, "{}"))
507
- h = r ? h : h.slice(0, -2), f = JSON.stringify(f);
508
- else if (a.isArray(f) && rn(f) || (a.isFileList(f) || a.endsWith(h, "[]")) && (b = a.toArray(f)))
509
- return h = ze(h), b.forEach(function(k, Ze) {
510
- !(a.isUndefined(k) || k === null) && t.append(
578
+ function f(h, d, b) {
579
+ let S = h;
580
+ if (h && !b && typeof h == "object") {
581
+ if (a.endsWith(d, "{}"))
582
+ d = r ? d : d.slice(0, -2), h = JSON.stringify(h);
583
+ else if (a.isArray(h) && hn(h) || (a.isFileList(h) || a.endsWith(d, "[]")) && (S = a.toArray(h)))
584
+ return d = Ke(d), S.forEach(function(x, ot) {
585
+ !(a.isUndefined(x) || x === null) && t.append(
511
586
  // eslint-disable-next-line no-nested-ternary
512
- i === !0 ? Se([h], Ze, o) : i === null ? h : h + "[]",
513
- c(k)
587
+ i === !0 ? Ae([d], ot, o) : i === null ? d : d + "[]",
588
+ p(x)
514
589
  );
515
590
  }), !1;
516
591
  }
517
- return re(f) ? !0 : (t.append(Se(R, h, o), c(f)), !1);
592
+ return ie(h) ? !0 : (t.append(Ae(b, d, o), p(h)), !1);
518
593
  }
519
- const d = [], y = Object.assign(sn, {
520
- defaultVisitor: l,
521
- convertValue: c,
522
- isVisitable: re
594
+ const c = [], y = Object.assign(mn, {
595
+ defaultVisitor: f,
596
+ convertValue: p,
597
+ isVisitable: ie
523
598
  });
524
- function w(f, h) {
525
- if (!a.isUndefined(f)) {
526
- if (d.indexOf(f) !== -1)
527
- throw Error("Circular reference detected in " + h.join("."));
528
- d.push(f), a.forEach(f, function(b, x) {
529
- (!(a.isUndefined(b) || b === null) && s.call(
599
+ function E(h, d) {
600
+ if (!a.isUndefined(h)) {
601
+ if (c.indexOf(h) !== -1)
602
+ throw Error("Circular reference detected in " + d.join("."));
603
+ c.push(h), a.forEach(h, function(S, O) {
604
+ (!(a.isUndefined(S) || S === null) && s.call(
530
605
  t,
531
- b,
532
- a.isString(x) ? x.trim() : x,
533
- h,
606
+ S,
607
+ a.isString(O) ? O.trim() : O,
608
+ d,
534
609
  y
535
- )) === !0 && w(b, h ? h.concat(x) : [x]);
536
- }), d.pop();
610
+ )) === !0 && E(S, d ? d.concat(O) : [O]);
611
+ }), c.pop();
537
612
  }
538
613
  }
539
614
  if (!a.isObject(e))
540
615
  throw new TypeError("data must be an object");
541
- return w(e), t;
616
+ return E(e), t;
542
617
  }
543
- function ge(e) {
618
+ function _e(e) {
544
619
  const t = {
545
620
  "!": "%21",
546
621
  "'": "%27",
@@ -554,36 +629,36 @@ function ge(e) {
554
629
  return t[r];
555
630
  });
556
631
  }
557
- function ue(e, t) {
558
- this._pairs = [], e && K(e, this, t);
632
+ function fe(e, t) {
633
+ this._pairs = [], e && G(e, this, t);
559
634
  }
560
- const Je = ue.prototype;
561
- Je.append = function(t, n) {
635
+ const Xe = fe.prototype;
636
+ Xe.append = function(t, n) {
562
637
  this._pairs.push([t, n]);
563
638
  };
564
- Je.toString = function(t) {
639
+ Xe.toString = function(t) {
565
640
  const n = t ? function(r) {
566
- return t.call(this, r, ge);
567
- } : ge;
641
+ return t.call(this, r, _e);
642
+ } : _e;
568
643
  return this._pairs.map(function(s) {
569
644
  return n(s[0]) + "=" + n(s[1]);
570
645
  }, "").join("&");
571
646
  };
572
- function on(e) {
647
+ function yn(e) {
573
648
  return encodeURIComponent(e).replace(/%3A/gi, ":").replace(/%24/g, "$").replace(/%2C/gi, ",").replace(/%20/g, "+").replace(/%5B/gi, "[").replace(/%5D/gi, "]");
574
649
  }
575
- function $e(e, t, n) {
650
+ function Ge(e, t, n) {
576
651
  if (!t)
577
652
  return e;
578
- const r = n && n.encode || on, s = n && n.serialize;
653
+ const r = n && n.encode || yn, s = n && n.serialize;
579
654
  let o;
580
- if (s ? o = s(t, n) : o = a.isURLSearchParams(t) ? t.toString() : new ue(t, n).toString(r), o) {
655
+ if (s ? o = s(t, n) : o = a.isURLSearchParams(t) ? t.toString() : new fe(t, n).toString(r), o) {
581
656
  const i = e.indexOf("#");
582
657
  i !== -1 && (e = e.slice(0, i)), e += (e.indexOf("?") === -1 ? "?" : "&") + o;
583
658
  }
584
659
  return e;
585
660
  }
586
- class an {
661
+ class wn {
587
662
  constructor() {
588
663
  this.handlers = [];
589
664
  }
@@ -637,36 +712,36 @@ class an {
637
712
  });
638
713
  }
639
714
  }
640
- const Oe = an, We = {
715
+ const Te = wn, Qe = {
641
716
  silentJSONParsing: !0,
642
717
  forcedJSONParsing: !0,
643
718
  clarifyTimeoutError: !1
644
- }, cn = typeof URLSearchParams < "u" ? URLSearchParams : ue, un = typeof FormData < "u" ? FormData : null, ln = typeof Blob < "u" ? Blob : null, fn = (() => {
645
- let e;
646
- return typeof navigator < "u" && ((e = navigator.product) === "ReactNative" || e === "NativeScript" || e === "NS") ? !1 : typeof window < "u" && typeof document < "u";
647
- })(), dn = (() => typeof WorkerGlobalScope < "u" && // eslint-disable-next-line no-undef
648
- self instanceof WorkerGlobalScope && typeof self.importScripts == "function")(), S = {
719
+ }, En = typeof URLSearchParams != "undefined" ? URLSearchParams : fe, bn = typeof FormData != "undefined" ? FormData : null, Rn = typeof Blob != "undefined" ? Blob : null, Sn = {
649
720
  isBrowser: !0,
650
721
  classes: {
651
- URLSearchParams: cn,
652
- FormData: un,
653
- Blob: ln
722
+ URLSearchParams: En,
723
+ FormData: bn,
724
+ Blob: Rn
654
725
  },
655
- isStandardBrowserEnv: fn,
656
- isStandardBrowserWebWorkerEnv: dn,
657
726
  protocols: ["http", "https", "file", "blob", "url", "data"]
658
- };
659
- function pn(e, t) {
660
- return K(e, new S.classes.URLSearchParams(), Object.assign({
727
+ }, Ze = typeof window != "undefined" && typeof document != "undefined", gn = ((e) => Ze && ["ReactNative", "NativeScript", "NS"].indexOf(e) < 0)(typeof navigator != "undefined" && navigator.product), On = (() => typeof WorkerGlobalScope != "undefined" && // eslint-disable-next-line no-undef
728
+ self instanceof WorkerGlobalScope && typeof self.importScripts == "function")(), xn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
729
+ __proto__: null,
730
+ hasBrowserEnv: Ze,
731
+ hasStandardBrowserEnv: gn,
732
+ hasStandardBrowserWebWorkerEnv: On
733
+ }, Symbol.toStringTag, { value: "Module" })), A = Y(Y({}, xn), Sn);
734
+ function An(e, t) {
735
+ return G(e, new A.classes.URLSearchParams(), Object.assign({
661
736
  visitor: function(n, r, s, o) {
662
- return S.isNode && a.isBuffer(n) ? (this.append(r, n.toString("base64")), !1) : o.defaultVisitor.apply(this, arguments);
737
+ return A.isNode && a.isBuffer(n) ? (this.append(r, n.toString("base64")), !1) : o.defaultVisitor.apply(this, arguments);
663
738
  }
664
739
  }, t));
665
740
  }
666
- function hn(e) {
741
+ function _n(e) {
667
742
  return a.matchAll(/\w+|\[(\w*)]/g, e).map((t) => t[0] === "[]" ? "" : t[1] || t[0]);
668
743
  }
669
- function mn(e) {
744
+ function Tn(e) {
670
745
  const t = {}, n = Object.keys(e);
671
746
  let r;
672
747
  const s = n.length;
@@ -675,24 +750,23 @@ function mn(e) {
675
750
  o = n[r], t[o] = e[o];
676
751
  return t;
677
752
  }
678
- function Ke(e) {
753
+ function Ye(e) {
679
754
  function t(n, r, s, o) {
680
755
  let i = n[o++];
681
- const u = Number.isFinite(+i), p = o >= n.length;
682
- return i = !i && a.isArray(s) ? s.length : i, p ? (a.hasOwnProp(s, i) ? s[i] = [s[i], r] : s[i] = r, !u) : ((!s[i] || !a.isObject(s[i])) && (s[i] = []), t(n, r, s[i], o) && a.isArray(s[i]) && (s[i] = mn(s[i])), !u);
756
+ if (i === "__proto__")
757
+ return !0;
758
+ const l = Number.isFinite(+i), u = o >= n.length;
759
+ return i = !i && a.isArray(s) ? s.length : i, u ? (a.hasOwnProp(s, i) ? s[i] = [s[i], r] : s[i] = r, !l) : ((!s[i] || !a.isObject(s[i])) && (s[i] = []), t(n, r, s[i], o) && a.isArray(s[i]) && (s[i] = Tn(s[i])), !l);
683
760
  }
684
761
  if (a.isFormData(e) && a.isFunction(e.entries)) {
685
762
  const n = {};
686
763
  return a.forEachEntry(e, (r, s) => {
687
- t(hn(r), s, n, 0);
764
+ t(_n(r), s, n, 0);
688
765
  }), n;
689
766
  }
690
767
  return null;
691
768
  }
692
- const yn = {
693
- "Content-Type": void 0
694
- };
695
- function wn(e, t, n) {
769
+ function Pn(e, t, n) {
696
770
  if (a.isString(e))
697
771
  try {
698
772
  return (t || JSON.parse)(e), a.trim(e);
@@ -702,43 +776,43 @@ function wn(e, t, n) {
702
776
  }
703
777
  return (n || JSON.stringify)(e);
704
778
  }
705
- const G = {
706
- transitional: We,
779
+ const de = {
780
+ transitional: Qe,
707
781
  adapter: ["xhr", "http"],
708
782
  transformRequest: [function(t, n) {
709
783
  const r = n.getContentType() || "", s = r.indexOf("application/json") > -1, o = a.isObject(t);
710
784
  if (o && a.isHTMLForm(t) && (t = new FormData(t)), a.isFormData(t))
711
- return s && s ? JSON.stringify(Ke(t)) : t;
785
+ return s ? JSON.stringify(Ye(t)) : t;
712
786
  if (a.isArrayBuffer(t) || a.isBuffer(t) || a.isStream(t) || a.isFile(t) || a.isBlob(t))
713
787
  return t;
714
788
  if (a.isArrayBufferView(t))
715
789
  return t.buffer;
716
790
  if (a.isURLSearchParams(t))
717
791
  return n.setContentType("application/x-www-form-urlencoded;charset=utf-8", !1), t.toString();
718
- let u;
792
+ let l;
719
793
  if (o) {
720
794
  if (r.indexOf("application/x-www-form-urlencoded") > -1)
721
- return pn(t, this.formSerializer).toString();
722
- if ((u = a.isFileList(t)) || r.indexOf("multipart/form-data") > -1) {
723
- const p = this.env && this.env.FormData;
724
- return K(
725
- u ? { "files[]": t } : t,
726
- p && new p(),
795
+ return An(t, this.formSerializer).toString();
796
+ if ((l = a.isFileList(t)) || r.indexOf("multipart/form-data") > -1) {
797
+ const u = this.env && this.env.FormData;
798
+ return G(
799
+ l ? { "files[]": t } : t,
800
+ u && new u(),
727
801
  this.formSerializer
728
802
  );
729
803
  }
730
804
  }
731
- return o || s ? (n.setContentType("application/json", !1), wn(t)) : t;
805
+ return o || s ? (n.setContentType("application/json", !1), Pn(t)) : t;
732
806
  }],
733
807
  transformResponse: [function(t) {
734
- const n = this.transitional || G.transitional, r = n && n.forcedJSONParsing, s = this.responseType === "json";
808
+ const n = this.transitional || de.transitional, r = n && n.forcedJSONParsing, s = this.responseType === "json";
735
809
  if (t && a.isString(t) && (r && !this.responseType || s)) {
736
810
  const i = !(n && n.silentJSONParsing) && s;
737
811
  try {
738
812
  return JSON.parse(t);
739
- } catch (u) {
813
+ } catch (l) {
740
814
  if (i)
741
- throw u.name === "SyntaxError" ? m.from(u, m.ERR_BAD_RESPONSE, this, null, this.response) : u;
815
+ throw l.name === "SyntaxError" ? m.from(l, m.ERR_BAD_RESPONSE, this, null, this.response) : l;
742
816
  }
743
817
  }
744
818
  return t;
@@ -753,25 +827,23 @@ const G = {
753
827
  maxContentLength: -1,
754
828
  maxBodyLength: -1,
755
829
  env: {
756
- FormData: S.classes.FormData,
757
- Blob: S.classes.Blob
830
+ FormData: A.classes.FormData,
831
+ Blob: A.classes.Blob
758
832
  },
759
833
  validateStatus: function(t) {
760
834
  return t >= 200 && t < 300;
761
835
  },
762
836
  headers: {
763
837
  common: {
764
- Accept: "application/json, text/plain, */*"
838
+ Accept: "application/json, text/plain, */*",
839
+ "Content-Type": void 0
765
840
  }
766
841
  }
767
842
  };
768
- a.forEach(["delete", "get", "head"], function(t) {
769
- G.headers[t] = {};
843
+ a.forEach(["delete", "get", "head", "post", "put", "patch"], (e) => {
844
+ de.headers[e] = {};
770
845
  });
771
- a.forEach(["post", "put", "patch"], function(t) {
772
- G.headers[t] = a.merge(yn);
773
- });
774
- const le = G, En = a.toObjectSet([
846
+ const pe = de, Cn = a.toObjectSet([
775
847
  "age",
776
848
  "authorization",
777
849
  "content-length",
@@ -789,31 +861,29 @@ const le = G, En = a.toObjectSet([
789
861
  "referer",
790
862
  "retry-after",
791
863
  "user-agent"
792
- ]), bn = (e) => {
864
+ ]), Nn = (e) => {
793
865
  const t = {};
794
866
  let n, r, s;
795
867
  return e && e.split(`
796
868
  `).forEach(function(i) {
797
- s = i.indexOf(":"), n = i.substring(0, s).trim().toLowerCase(), r = i.substring(s + 1).trim(), !(!n || t[n] && En[n]) && (n === "set-cookie" ? t[n] ? t[n].push(r) : t[n] = [r] : t[n] = t[n] ? t[n] + ", " + r : r);
869
+ s = i.indexOf(":"), n = i.substring(0, s).trim().toLowerCase(), r = i.substring(s + 1).trim(), !(!n || t[n] && Cn[n]) && (n === "set-cookie" ? t[n] ? t[n].push(r) : t[n] = [r] : t[n] = t[n] ? t[n] + ", " + r : r);
798
870
  }), t;
799
- }, xe = Symbol("internals");
800
- function L(e) {
871
+ }, Pe = Symbol("internals");
872
+ function U(e) {
801
873
  return e && String(e).trim().toLowerCase();
802
874
  }
803
875
  function V(e) {
804
876
  return e === !1 || e == null ? e : a.isArray(e) ? e.map(V) : String(e);
805
877
  }
806
- function Rn(e) {
878
+ function Fn(e) {
807
879
  const t = /* @__PURE__ */ Object.create(null), n = /([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;
808
880
  let r;
809
881
  for (; r = n.exec(e); )
810
882
  t[r[1]] = r[2];
811
883
  return t;
812
884
  }
813
- function Sn(e) {
814
- return /^[-_a-zA-Z]+$/.test(e.trim());
815
- }
816
- function Z(e, t, n, r, s) {
885
+ const Ln = (e) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());
886
+ function ne(e, t, n, r, s) {
817
887
  if (a.isFunction(r))
818
888
  return r.call(this, t, n);
819
889
  if (s && (t = n), !!a.isString(t)) {
@@ -823,10 +893,10 @@ function Z(e, t, n, r, s) {
823
893
  return r.test(t);
824
894
  }
825
895
  }
826
- function gn(e) {
896
+ function Bn(e) {
827
897
  return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (t, n, r) => n.toUpperCase() + r);
828
898
  }
829
- function On(e, t) {
899
+ function Un(e, t) {
830
900
  const n = a.toCamelCase(" " + t);
831
901
  ["get", "set", "has"].forEach((r) => {
832
902
  Object.defineProperty(e, r + n, {
@@ -837,31 +907,31 @@ function On(e, t) {
837
907
  });
838
908
  });
839
909
  }
840
- class X {
910
+ class Q {
841
911
  constructor(t) {
842
912
  t && this.set(t);
843
913
  }
844
914
  set(t, n, r) {
845
915
  const s = this;
846
- function o(u, p, c) {
847
- const l = L(p);
848
- if (!l)
916
+ function o(l, u, p) {
917
+ const f = U(u);
918
+ if (!f)
849
919
  throw new Error("header name must be a non-empty string");
850
- const d = a.findKey(s, l);
851
- (!d || s[d] === void 0 || c === !0 || c === void 0 && s[d] !== !1) && (s[d || p] = V(u));
920
+ const c = a.findKey(s, f);
921
+ (!c || s[c] === void 0 || p === !0 || p === void 0 && s[c] !== !1) && (s[c || u] = V(l));
852
922
  }
853
- const i = (u, p) => a.forEach(u, (c, l) => o(c, l, p));
854
- return a.isPlainObject(t) || t instanceof this.constructor ? i(t, n) : a.isString(t) && (t = t.trim()) && !Sn(t) ? i(bn(t), n) : t != null && o(n, t, r), this;
923
+ const i = (l, u) => a.forEach(l, (p, f) => o(p, f, u));
924
+ return a.isPlainObject(t) || t instanceof this.constructor ? i(t, n) : a.isString(t) && (t = t.trim()) && !Ln(t) ? i(Nn(t), n) : t != null && o(n, t, r), this;
855
925
  }
856
926
  get(t, n) {
857
- if (t = L(t), t) {
927
+ if (t = U(t), t) {
858
928
  const r = a.findKey(this, t);
859
929
  if (r) {
860
930
  const s = this[r];
861
931
  if (!n)
862
932
  return s;
863
933
  if (n === !0)
864
- return Rn(s);
934
+ return Fn(s);
865
935
  if (a.isFunction(n))
866
936
  return n.call(this, s, r);
867
937
  if (a.isRegExp(n))
@@ -871,9 +941,9 @@ class X {
871
941
  }
872
942
  }
873
943
  has(t, n) {
874
- if (t = L(t), t) {
944
+ if (t = U(t), t) {
875
945
  const r = a.findKey(this, t);
876
- return !!(r && this[r] !== void 0 && (!n || Z(this, this[r], r, n)));
946
+ return !!(r && this[r] !== void 0 && (!n || ne(this, this[r], r, n)));
877
947
  }
878
948
  return !1;
879
949
  }
@@ -881,9 +951,9 @@ class X {
881
951
  const r = this;
882
952
  let s = !1;
883
953
  function o(i) {
884
- if (i = L(i), i) {
885
- const u = a.findKey(r, i);
886
- u && (!n || Z(r, r[u], u, n)) && (delete r[u], s = !0);
954
+ if (i = U(i), i) {
955
+ const l = a.findKey(r, i);
956
+ l && (!n || ne(r, r[l], l, n)) && (delete r[l], s = !0);
887
957
  }
888
958
  }
889
959
  return a.isArray(t) ? t.forEach(o) : o(t), s;
@@ -893,7 +963,7 @@ class X {
893
963
  let r = n.length, s = !1;
894
964
  for (; r--; ) {
895
965
  const o = n[r];
896
- (!t || Z(this, this[o], o, t, !0)) && (delete this[o], s = !0);
966
+ (!t || ne(this, this[o], o, t, !0)) && (delete this[o], s = !0);
897
967
  }
898
968
  return s;
899
969
  }
@@ -905,8 +975,8 @@ class X {
905
975
  n[i] = V(s), delete n[o];
906
976
  return;
907
977
  }
908
- const u = t ? gn(o) : String(o).trim();
909
- u !== o && delete n[o], n[u] = V(s), r[u] = !0;
978
+ const l = t ? Bn(o) : String(o).trim();
979
+ l !== o && delete n[o], n[l] = V(s), r[l] = !0;
910
980
  }), this;
911
981
  }
912
982
  concat(...t) {
@@ -936,37 +1006,45 @@ class X {
936
1006
  return n.forEach((s) => r.set(s)), r;
937
1007
  }
938
1008
  static accessor(t) {
939
- const r = (this[xe] = this[xe] = {
1009
+ const r = (this[Pe] = this[Pe] = {
940
1010
  accessors: {}
941
1011
  }).accessors, s = this.prototype;
942
1012
  function o(i) {
943
- const u = L(i);
944
- r[u] || (On(s, i), r[u] = !0);
1013
+ const l = U(i);
1014
+ r[l] || (Un(s, i), r[l] = !0);
945
1015
  }
946
1016
  return a.isArray(t) ? t.forEach(o) : o(t), this;
947
1017
  }
948
1018
  }
949
- X.accessor(["Content-Type", "Content-Length", "Accept", "Accept-Encoding", "User-Agent", "Authorization"]);
950
- a.freezeMethods(X.prototype);
951
- a.freezeMethods(X);
952
- const g = X;
953
- function ee(e, t) {
954
- const n = this || le, r = t || n, s = g.from(r.headers);
1019
+ Q.accessor(["Content-Type", "Content-Length", "Accept", "Accept-Encoding", "User-Agent", "Authorization"]);
1020
+ a.reduceDescriptors(Q.prototype, ({ value: e }, t) => {
1021
+ let n = t[0].toUpperCase() + t.slice(1);
1022
+ return {
1023
+ get: () => e,
1024
+ set(r) {
1025
+ this[n] = r;
1026
+ }
1027
+ };
1028
+ });
1029
+ a.freezeMethods(Q);
1030
+ const T = Q;
1031
+ function re(e, t) {
1032
+ const n = this || pe, r = t || n, s = T.from(r.headers);
955
1033
  let o = r.data;
956
- return a.forEach(e, function(u) {
957
- o = u.call(n, o, s.normalize(), t ? t.status : void 0);
1034
+ return a.forEach(e, function(l) {
1035
+ o = l.call(n, o, s.normalize(), t ? t.status : void 0);
958
1036
  }), s.normalize(), o;
959
1037
  }
960
- function Ge(e) {
1038
+ function et(e) {
961
1039
  return !!(e && e.__CANCEL__);
962
1040
  }
963
- function j(e, t, n) {
964
- m.call(this, e ?? "canceled", m.ERR_CANCELED, t, n), this.name = "CanceledError";
1041
+ function v(e, t, n) {
1042
+ m.call(this, e == null ? "canceled" : e, m.ERR_CANCELED, t, n), this.name = "CanceledError";
965
1043
  }
966
- a.inherits(j, m, {
1044
+ a.inherits(v, m, {
967
1045
  __CANCEL__: !0
968
1046
  });
969
- function xn(e, t, n) {
1047
+ function Dn(e, t, n) {
970
1048
  const r = n.config.validateStatus;
971
1049
  !n.status || !r || r(n.status) ? e(n) : t(new m(
972
1050
  "Request failed with status code " + n.status,
@@ -976,47 +1054,43 @@ function xn(e, t, n) {
976
1054
  n
977
1055
  ));
978
1056
  }
979
- const An = S.isStandardBrowserEnv ? (
1057
+ const kn = A.hasStandardBrowserEnv ? (
980
1058
  // Standard browser envs support document.cookie
981
- function() {
982
- return {
983
- write: function(n, r, s, o, i, u) {
984
- const p = [];
985
- p.push(n + "=" + encodeURIComponent(r)), a.isNumber(s) && p.push("expires=" + new Date(s).toGMTString()), a.isString(o) && p.push("path=" + o), a.isString(i) && p.push("domain=" + i), u === !0 && p.push("secure"), document.cookie = p.join("; ");
986
- },
987
- read: function(n) {
988
- const r = document.cookie.match(new RegExp("(^|;\\s*)(" + n + ")=([^;]*)"));
989
- return r ? decodeURIComponent(r[3]) : null;
990
- },
991
- remove: function(n) {
992
- this.write(n, "", Date.now() - 864e5);
993
- }
994
- };
995
- }()
1059
+ {
1060
+ write(e, t, n, r, s, o) {
1061
+ const i = [e + "=" + encodeURIComponent(t)];
1062
+ a.isNumber(n) && i.push("expires=" + new Date(n).toGMTString()), a.isString(r) && i.push("path=" + r), a.isString(s) && i.push("domain=" + s), o === !0 && i.push("secure"), document.cookie = i.join("; ");
1063
+ },
1064
+ read(e) {
1065
+ const t = document.cookie.match(new RegExp("(^|;\\s*)(" + e + ")=([^;]*)"));
1066
+ return t ? decodeURIComponent(t[3]) : null;
1067
+ },
1068
+ remove(e) {
1069
+ this.write(e, "", Date.now() - 864e5);
1070
+ }
1071
+ }
996
1072
  ) : (
997
- // Non standard browser env (web workers, react-native) lack needed support.
998
- function() {
999
- return {
1000
- write: function() {
1001
- },
1002
- read: function() {
1003
- return null;
1004
- },
1005
- remove: function() {
1006
- }
1007
- };
1008
- }()
1073
+ // Non-standard browser env (web workers, react-native) lack needed support.
1074
+ {
1075
+ write() {
1076
+ },
1077
+ read() {
1078
+ return null;
1079
+ },
1080
+ remove() {
1081
+ }
1082
+ }
1009
1083
  );
1010
- function _n(e) {
1084
+ function jn(e) {
1011
1085
  return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(e);
1012
1086
  }
1013
- function Tn(e, t) {
1014
- return t ? e.replace(/\/+$/, "") + "/" + t.replace(/^\/+/, "") : e;
1087
+ function vn(e, t) {
1088
+ return t ? e.replace(/\/?\/$/, "") + "/" + t.replace(/^\/+/, "") : e;
1015
1089
  }
1016
- function Xe(e, t) {
1017
- return e && !_n(t) ? Tn(e, t) : t;
1090
+ function tt(e, t) {
1091
+ return e && !jn(t) ? vn(e, t) : t;
1018
1092
  }
1019
- const Pn = S.isStandardBrowserEnv ? (
1093
+ const In = A.hasStandardBrowserEnv ? (
1020
1094
  // Standard browser envs have full support of the APIs needed to test
1021
1095
  // whether the request URL is of the same origin as current location.
1022
1096
  function() {
@@ -1036,8 +1110,8 @@ const Pn = S.isStandardBrowserEnv ? (
1036
1110
  };
1037
1111
  }
1038
1112
  return r = s(window.location.href), function(i) {
1039
- const u = a.isString(i) ? s(i) : i;
1040
- return u.protocol === r.protocol && u.host === r.host;
1113
+ const l = a.isString(i) ? s(i) : i;
1114
+ return l.protocol === r.protocol && l.host === r.host;
1041
1115
  };
1042
1116
  }()
1043
1117
  ) : (
@@ -1048,197 +1122,216 @@ const Pn = S.isStandardBrowserEnv ? (
1048
1122
  };
1049
1123
  }()
1050
1124
  );
1051
- function Nn(e) {
1125
+ function Hn(e) {
1052
1126
  const t = /^([-+\w]{1,25})(:?\/\/|:)/.exec(e);
1053
1127
  return t && t[1] || "";
1054
1128
  }
1055
- function Cn(e, t) {
1129
+ function Mn(e, t) {
1056
1130
  e = e || 10;
1057
1131
  const n = new Array(e), r = new Array(e);
1058
1132
  let s = 0, o = 0, i;
1059
- return t = t !== void 0 ? t : 1e3, function(p) {
1060
- const c = Date.now(), l = r[o];
1061
- i || (i = c), n[s] = p, r[s] = c;
1062
- let d = o, y = 0;
1063
- for (; d !== s; )
1064
- y += n[d++], d = d % e;
1065
- if (s = (s + 1) % e, s === o && (o = (o + 1) % e), c - i < t)
1133
+ return t = t !== void 0 ? t : 1e3, function(u) {
1134
+ const p = Date.now(), f = r[o];
1135
+ i || (i = p), n[s] = u, r[s] = p;
1136
+ let c = o, y = 0;
1137
+ for (; c !== s; )
1138
+ y += n[c++], c = c % e;
1139
+ if (s = (s + 1) % e, s === o && (o = (o + 1) % e), p - i < t)
1066
1140
  return;
1067
- const w = l && c - l;
1068
- return w ? Math.round(y * 1e3 / w) : void 0;
1141
+ const E = f && p - f;
1142
+ return E ? Math.round(y * 1e3 / E) : void 0;
1069
1143
  };
1070
1144
  }
1071
- function Ae(e, t) {
1145
+ function Ce(e, t) {
1072
1146
  let n = 0;
1073
- const r = Cn(50, 250);
1147
+ const r = Mn(50, 250);
1074
1148
  return (s) => {
1075
- const o = s.loaded, i = s.lengthComputable ? s.total : void 0, u = o - n, p = r(u), c = o <= i;
1149
+ const o = s.loaded, i = s.lengthComputable ? s.total : void 0, l = o - n, u = r(l), p = o <= i;
1076
1150
  n = o;
1077
- const l = {
1151
+ const f = {
1078
1152
  loaded: o,
1079
1153
  total: i,
1080
1154
  progress: i ? o / i : void 0,
1081
- bytes: u,
1082
- rate: p || void 0,
1083
- estimated: p && i && c ? (i - o) / p : void 0,
1155
+ bytes: l,
1156
+ rate: u || void 0,
1157
+ estimated: u && i && p ? (i - o) / u : void 0,
1084
1158
  event: s
1085
1159
  };
1086
- l[t ? "download" : "upload"] = !0, e(l);
1160
+ f[t ? "download" : "upload"] = !0, e(f);
1087
1161
  };
1088
1162
  }
1089
- const Fn = typeof XMLHttpRequest < "u", Ln = Fn && function(e) {
1163
+ const qn = typeof XMLHttpRequest != "undefined", zn = qn && function(e) {
1090
1164
  return new Promise(function(n, r) {
1091
1165
  let s = e.data;
1092
- const o = g.from(e.headers).normalize(), i = e.responseType;
1093
- let u;
1166
+ const o = T.from(e.headers).normalize();
1167
+ let { responseType: i, withXSRFToken: l } = e, u;
1094
1168
  function p() {
1095
1169
  e.cancelToken && e.cancelToken.unsubscribe(u), e.signal && e.signal.removeEventListener("abort", u);
1096
1170
  }
1097
- a.isFormData(s) && (S.isStandardBrowserEnv || S.isStandardBrowserWebWorkerEnv) && o.setContentType(!1);
1171
+ let f;
1172
+ if (a.isFormData(s)) {
1173
+ if (A.hasStandardBrowserEnv || A.hasStandardBrowserWebWorkerEnv)
1174
+ o.setContentType(!1);
1175
+ else if ((f = o.getContentType()) !== !1) {
1176
+ const [d, ...b] = f ? f.split(";").map((S) => S.trim()).filter(Boolean) : [];
1177
+ o.setContentType([d || "multipart/form-data", ...b].join("; "));
1178
+ }
1179
+ }
1098
1180
  let c = new XMLHttpRequest();
1099
1181
  if (e.auth) {
1100
- const w = e.auth.username || "", f = e.auth.password ? unescape(encodeURIComponent(e.auth.password)) : "";
1101
- o.set("Authorization", "Basic " + btoa(w + ":" + f));
1182
+ const d = e.auth.username || "", b = e.auth.password ? unescape(encodeURIComponent(e.auth.password)) : "";
1183
+ o.set("Authorization", "Basic " + btoa(d + ":" + b));
1102
1184
  }
1103
- const l = Xe(e.baseURL, e.url);
1104
- c.open(e.method.toUpperCase(), $e(l, e.params, e.paramsSerializer), !0), c.timeout = e.timeout;
1105
- function d() {
1185
+ const y = tt(e.baseURL, e.url);
1186
+ c.open(e.method.toUpperCase(), Ge(y, e.params, e.paramsSerializer), !0), c.timeout = e.timeout;
1187
+ function E() {
1106
1188
  if (!c)
1107
1189
  return;
1108
- const w = g.from(
1190
+ const d = T.from(
1109
1191
  "getAllResponseHeaders" in c && c.getAllResponseHeaders()
1110
- ), h = {
1192
+ ), S = {
1111
1193
  data: !i || i === "text" || i === "json" ? c.responseText : c.response,
1112
1194
  status: c.status,
1113
1195
  statusText: c.statusText,
1114
- headers: w,
1196
+ headers: d,
1115
1197
  config: e,
1116
1198
  request: c
1117
1199
  };
1118
- xn(function(b) {
1119
- n(b), p();
1120
- }, function(b) {
1121
- r(b), p();
1122
- }, h), c = null;
1200
+ Dn(function(x) {
1201
+ n(x), p();
1202
+ }, function(x) {
1203
+ r(x), p();
1204
+ }, S), c = null;
1123
1205
  }
1124
- if ("onloadend" in c ? c.onloadend = d : c.onreadystatechange = function() {
1125
- !c || c.readyState !== 4 || c.status === 0 && !(c.responseURL && c.responseURL.indexOf("file:") === 0) || setTimeout(d);
1206
+ if ("onloadend" in c ? c.onloadend = E : c.onreadystatechange = function() {
1207
+ !c || c.readyState !== 4 || c.status === 0 && !(c.responseURL && c.responseURL.indexOf("file:") === 0) || setTimeout(E);
1126
1208
  }, c.onabort = function() {
1127
1209
  c && (r(new m("Request aborted", m.ECONNABORTED, e, c)), c = null);
1128
1210
  }, c.onerror = function() {
1129
1211
  r(new m("Network Error", m.ERR_NETWORK, e, c)), c = null;
1130
1212
  }, c.ontimeout = function() {
1131
- let f = e.timeout ? "timeout of " + e.timeout + "ms exceeded" : "timeout exceeded";
1132
- const h = e.transitional || We;
1133
- e.timeoutErrorMessage && (f = e.timeoutErrorMessage), r(new m(
1134
- f,
1135
- h.clarifyTimeoutError ? m.ETIMEDOUT : m.ECONNABORTED,
1213
+ let b = e.timeout ? "timeout of " + e.timeout + "ms exceeded" : "timeout exceeded";
1214
+ const S = e.transitional || Qe;
1215
+ e.timeoutErrorMessage && (b = e.timeoutErrorMessage), r(new m(
1216
+ b,
1217
+ S.clarifyTimeoutError ? m.ETIMEDOUT : m.ECONNABORTED,
1136
1218
  e,
1137
1219
  c
1138
1220
  )), c = null;
1139
- }, S.isStandardBrowserEnv) {
1140
- const w = (e.withCredentials || Pn(l)) && e.xsrfCookieName && An.read(e.xsrfCookieName);
1141
- w && o.set(e.xsrfHeaderName, w);
1221
+ }, A.hasStandardBrowserEnv && (l && a.isFunction(l) && (l = l(e)), l || l !== !1 && In(y))) {
1222
+ const d = e.xsrfHeaderName && e.xsrfCookieName && kn.read(e.xsrfCookieName);
1223
+ d && o.set(e.xsrfHeaderName, d);
1142
1224
  }
1143
- s === void 0 && o.setContentType(null), "setRequestHeader" in c && a.forEach(o.toJSON(), function(f, h) {
1144
- c.setRequestHeader(h, f);
1145
- }), a.isUndefined(e.withCredentials) || (c.withCredentials = !!e.withCredentials), i && i !== "json" && (c.responseType = e.responseType), typeof e.onDownloadProgress == "function" && c.addEventListener("progress", Ae(e.onDownloadProgress, !0)), typeof e.onUploadProgress == "function" && c.upload && c.upload.addEventListener("progress", Ae(e.onUploadProgress)), (e.cancelToken || e.signal) && (u = (w) => {
1146
- c && (r(!w || w.type ? new j(null, e, c) : w), c.abort(), c = null);
1225
+ s === void 0 && o.setContentType(null), "setRequestHeader" in c && a.forEach(o.toJSON(), function(b, S) {
1226
+ c.setRequestHeader(S, b);
1227
+ }), a.isUndefined(e.withCredentials) || (c.withCredentials = !!e.withCredentials), i && i !== "json" && (c.responseType = e.responseType), typeof e.onDownloadProgress == "function" && c.addEventListener("progress", Ce(e.onDownloadProgress, !0)), typeof e.onUploadProgress == "function" && c.upload && c.upload.addEventListener("progress", Ce(e.onUploadProgress)), (e.cancelToken || e.signal) && (u = (d) => {
1228
+ c && (r(!d || d.type ? new v(null, e, c) : d), c.abort(), c = null);
1147
1229
  }, e.cancelToken && e.cancelToken.subscribe(u), e.signal && (e.signal.aborted ? u() : e.signal.addEventListener("abort", u)));
1148
- const y = Nn(l);
1149
- if (y && S.protocols.indexOf(y) === -1) {
1150
- r(new m("Unsupported protocol " + y + ":", m.ERR_BAD_REQUEST, e));
1230
+ const h = Hn(y);
1231
+ if (h && A.protocols.indexOf(h) === -1) {
1232
+ r(new m("Unsupported protocol " + h + ":", m.ERR_BAD_REQUEST, e));
1151
1233
  return;
1152
1234
  }
1153
1235
  c.send(s || null);
1154
1236
  });
1155
- }, z = {
1156
- http: nn,
1157
- xhr: Ln
1237
+ }, ae = {
1238
+ http: pn,
1239
+ xhr: zn
1158
1240
  };
1159
- a.forEach(z, (e, t) => {
1241
+ a.forEach(ae, (e, t) => {
1160
1242
  if (e) {
1161
1243
  try {
1162
1244
  Object.defineProperty(e, "name", { value: t });
1163
- } catch {
1245
+ } catch (n) {
1164
1246
  }
1165
1247
  Object.defineProperty(e, "adapterName", { value: t });
1166
1248
  }
1167
1249
  });
1168
- const Bn = {
1250
+ const Ne = (e) => `- ${e}`, Vn = (e) => a.isFunction(e) || e === null || e === !1, nt = {
1169
1251
  getAdapter: (e) => {
1170
1252
  e = a.isArray(e) ? e : [e];
1171
1253
  const { length: t } = e;
1172
1254
  let n, r;
1173
- for (let s = 0; s < t && (n = e[s], !(r = a.isString(n) ? z[n.toLowerCase()] : n)); s++)
1174
- ;
1175
- if (!r)
1176
- throw r === !1 ? new m(
1177
- `Adapter ${n} is not supported by the environment`,
1255
+ const s = {};
1256
+ for (let o = 0; o < t; o++) {
1257
+ n = e[o];
1258
+ let i;
1259
+ if (r = n, !Vn(n) && (r = ae[(i = String(n)).toLowerCase()], r === void 0))
1260
+ throw new m(`Unknown adapter '${i}'`);
1261
+ if (r)
1262
+ break;
1263
+ s[i || "#" + o] = r;
1264
+ }
1265
+ if (!r) {
1266
+ const o = Object.entries(s).map(
1267
+ ([l, u]) => `adapter ${l} ` + (u === !1 ? "is not supported by the environment" : "is not available in the build")
1268
+ );
1269
+ let i = t ? o.length > 1 ? `since :
1270
+ ` + o.map(Ne).join(`
1271
+ `) : " " + Ne(o[0]) : "as no adapter specified";
1272
+ throw new m(
1273
+ "There is no suitable adapter to dispatch the request " + i,
1178
1274
  "ERR_NOT_SUPPORT"
1179
- ) : new Error(
1180
- a.hasOwnProp(z, n) ? `Adapter '${n}' is not available in the build` : `Unknown adapter '${n}'`
1181
1275
  );
1182
- if (!a.isFunction(r))
1183
- throw new TypeError("adapter is not a function");
1276
+ }
1184
1277
  return r;
1185
1278
  },
1186
- adapters: z
1279
+ adapters: ae
1187
1280
  };
1188
- function te(e) {
1281
+ function se(e) {
1189
1282
  if (e.cancelToken && e.cancelToken.throwIfRequested(), e.signal && e.signal.aborted)
1190
- throw new j(null, e);
1283
+ throw new v(null, e);
1191
1284
  }
1192
- function _e(e) {
1193
- return te(e), e.headers = g.from(e.headers), e.data = ee.call(
1285
+ function Fe(e) {
1286
+ return se(e), e.headers = T.from(e.headers), e.data = re.call(
1194
1287
  e,
1195
1288
  e.transformRequest
1196
- ), ["post", "put", "patch"].indexOf(e.method) !== -1 && e.headers.setContentType("application/x-www-form-urlencoded", !1), Bn.getAdapter(e.adapter || le.adapter)(e).then(function(r) {
1197
- return te(e), r.data = ee.call(
1289
+ ), ["post", "put", "patch"].indexOf(e.method) !== -1 && e.headers.setContentType("application/x-www-form-urlencoded", !1), nt.getAdapter(e.adapter || pe.adapter)(e).then(function(r) {
1290
+ return se(e), r.data = re.call(
1198
1291
  e,
1199
1292
  e.transformResponse,
1200
1293
  r
1201
- ), r.headers = g.from(r.headers), r;
1294
+ ), r.headers = T.from(r.headers), r;
1202
1295
  }, function(r) {
1203
- return Ge(r) || (te(e), r && r.response && (r.response.data = ee.call(
1296
+ return et(r) || (se(e), r && r.response && (r.response.data = re.call(
1204
1297
  e,
1205
1298
  e.transformResponse,
1206
1299
  r.response
1207
- ), r.response.headers = g.from(r.response.headers))), Promise.reject(r);
1300
+ ), r.response.headers = T.from(r.response.headers))), Promise.reject(r);
1208
1301
  });
1209
1302
  }
1210
- const Te = (e) => e instanceof g ? e.toJSON() : e;
1211
- function T(e, t) {
1303
+ const Le = (e) => e instanceof T ? e.toJSON() : e;
1304
+ function C(e, t) {
1212
1305
  t = t || {};
1213
1306
  const n = {};
1214
- function r(c, l, d) {
1215
- return a.isPlainObject(c) && a.isPlainObject(l) ? a.merge.call({ caseless: d }, c, l) : a.isPlainObject(l) ? a.merge({}, l) : a.isArray(l) ? l.slice() : l;
1307
+ function r(p, f, c) {
1308
+ return a.isPlainObject(p) && a.isPlainObject(f) ? a.merge.call({ caseless: c }, p, f) : a.isPlainObject(f) ? a.merge({}, f) : a.isArray(f) ? f.slice() : f;
1216
1309
  }
1217
- function s(c, l, d) {
1218
- if (a.isUndefined(l)) {
1219
- if (!a.isUndefined(c))
1220
- return r(void 0, c, d);
1310
+ function s(p, f, c) {
1311
+ if (a.isUndefined(f)) {
1312
+ if (!a.isUndefined(p))
1313
+ return r(void 0, p, c);
1221
1314
  } else
1222
- return r(c, l, d);
1315
+ return r(p, f, c);
1223
1316
  }
1224
- function o(c, l) {
1225
- if (!a.isUndefined(l))
1226
- return r(void 0, l);
1317
+ function o(p, f) {
1318
+ if (!a.isUndefined(f))
1319
+ return r(void 0, f);
1227
1320
  }
1228
- function i(c, l) {
1229
- if (a.isUndefined(l)) {
1230
- if (!a.isUndefined(c))
1231
- return r(void 0, c);
1321
+ function i(p, f) {
1322
+ if (a.isUndefined(f)) {
1323
+ if (!a.isUndefined(p))
1324
+ return r(void 0, p);
1232
1325
  } else
1233
- return r(void 0, l);
1326
+ return r(void 0, f);
1234
1327
  }
1235
- function u(c, l, d) {
1236
- if (d in t)
1237
- return r(c, l);
1238
- if (d in e)
1239
- return r(void 0, c);
1328
+ function l(p, f, c) {
1329
+ if (c in t)
1330
+ return r(p, f);
1331
+ if (c in e)
1332
+ return r(void 0, p);
1240
1333
  }
1241
- const p = {
1334
+ const u = {
1242
1335
  url: o,
1243
1336
  method: o,
1244
1337
  data: o,
@@ -1249,6 +1342,7 @@ function T(e, t) {
1249
1342
  timeout: i,
1250
1343
  timeoutMessage: i,
1251
1344
  withCredentials: i,
1345
+ withXSRFToken: i,
1252
1346
  adapter: i,
1253
1347
  responseType: i,
1254
1348
  xsrfCookieName: i,
@@ -1265,40 +1359,40 @@ function T(e, t) {
1265
1359
  cancelToken: i,
1266
1360
  socketPath: i,
1267
1361
  responseEncoding: i,
1268
- validateStatus: u,
1269
- headers: (c, l) => s(Te(c), Te(l), !0)
1362
+ validateStatus: l,
1363
+ headers: (p, f) => s(Le(p), Le(f), !0)
1270
1364
  };
1271
- return a.forEach(Object.keys(e).concat(Object.keys(t)), function(l) {
1272
- const d = p[l] || s, y = d(e[l], t[l], l);
1273
- a.isUndefined(y) && d !== u || (n[l] = y);
1365
+ return a.forEach(Object.keys(Object.assign({}, e, t)), function(f) {
1366
+ const c = u[f] || s, y = c(e[f], t[f], f);
1367
+ a.isUndefined(y) && c !== l || (n[f] = y);
1274
1368
  }), n;
1275
1369
  }
1276
- const Qe = "1.3.4", fe = {};
1370
+ const rt = "1.6.7", he = {};
1277
1371
  ["object", "boolean", "number", "function", "string", "symbol"].forEach((e, t) => {
1278
- fe[e] = function(r) {
1372
+ he[e] = function(r) {
1279
1373
  return typeof r === e || "a" + (t < 1 ? "n " : " ") + e;
1280
1374
  };
1281
1375
  });
1282
- const Pe = {};
1283
- fe.transitional = function(t, n, r) {
1376
+ const Be = {};
1377
+ he.transitional = function(t, n, r) {
1284
1378
  function s(o, i) {
1285
- return "[Axios v" + Qe + "] Transitional option '" + o + "'" + i + (r ? ". " + r : "");
1379
+ return "[Axios v" + rt + "] Transitional option '" + o + "'" + i + (r ? ". " + r : "");
1286
1380
  }
1287
- return (o, i, u) => {
1381
+ return (o, i, l) => {
1288
1382
  if (t === !1)
1289
1383
  throw new m(
1290
1384
  s(i, " has been removed" + (n ? " in " + n : "")),
1291
1385
  m.ERR_DEPRECATED
1292
1386
  );
1293
- return n && !Pe[i] && (Pe[i] = !0, console.warn(
1387
+ return n && !Be[i] && (Be[i] = !0, console.warn(
1294
1388
  s(
1295
1389
  i,
1296
1390
  " has been deprecated since v" + n + " and will be removed in the near future"
1297
1391
  )
1298
- )), t ? t(o, i, u) : !0;
1392
+ )), t ? t(o, i, l) : !0;
1299
1393
  };
1300
1394
  };
1301
- function Dn(e, t, n) {
1395
+ function $n(e, t, n) {
1302
1396
  if (typeof e != "object")
1303
1397
  throw new m("options must be an object", m.ERR_BAD_OPTION_VALUE);
1304
1398
  const r = Object.keys(e);
@@ -1306,24 +1400,24 @@ function Dn(e, t, n) {
1306
1400
  for (; s-- > 0; ) {
1307
1401
  const o = r[s], i = t[o];
1308
1402
  if (i) {
1309
- const u = e[o], p = u === void 0 || i(u, o, e);
1310
- if (p !== !0)
1311
- throw new m("option " + o + " must be " + p, m.ERR_BAD_OPTION_VALUE);
1403
+ const l = e[o], u = l === void 0 || i(l, o, e);
1404
+ if (u !== !0)
1405
+ throw new m("option " + o + " must be " + u, m.ERR_BAD_OPTION_VALUE);
1312
1406
  continue;
1313
1407
  }
1314
1408
  if (n !== !0)
1315
1409
  throw new m("Unknown option " + o, m.ERR_BAD_OPTION);
1316
1410
  }
1317
1411
  }
1318
- const se = {
1319
- assertOptions: Dn,
1320
- validators: fe
1321
- }, A = se.validators;
1322
- class $ {
1412
+ const ce = {
1413
+ assertOptions: $n,
1414
+ validators: he
1415
+ }, P = ce.validators;
1416
+ class J {
1323
1417
  constructor(t) {
1324
1418
  this.defaults = t, this.interceptors = {
1325
- request: new Oe(),
1326
- response: new Oe()
1419
+ request: new Te(),
1420
+ response: new Te()
1327
1421
  };
1328
1422
  }
1329
1423
  /**
@@ -1335,71 +1429,89 @@ class $ {
1335
1429
  * @returns {Promise} The Promise to be fulfilled
1336
1430
  */
1337
1431
  request(t, n) {
1338
- typeof t == "string" ? (n = n || {}, n.url = t) : n = t || {}, n = T(this.defaults, n);
1432
+ return w(this, null, function* () {
1433
+ try {
1434
+ return yield this._request(t, n);
1435
+ } catch (r) {
1436
+ if (r instanceof Error) {
1437
+ let s;
1438
+ Error.captureStackTrace ? Error.captureStackTrace(s = {}) : s = new Error();
1439
+ const o = s.stack ? s.stack.replace(/^.+\n/, "") : "";
1440
+ r.stack ? o && !String(r.stack).endsWith(o.replace(/^.+\n.+\n/, "")) && (r.stack += `
1441
+ ` + o) : r.stack = o;
1442
+ }
1443
+ throw r;
1444
+ }
1445
+ });
1446
+ }
1447
+ _request(t, n) {
1448
+ typeof t == "string" ? (n = n || {}, n.url = t) : n = t || {}, n = C(this.defaults, n);
1339
1449
  const { transitional: r, paramsSerializer: s, headers: o } = n;
1340
- r !== void 0 && se.assertOptions(r, {
1341
- silentJSONParsing: A.transitional(A.boolean),
1342
- forcedJSONParsing: A.transitional(A.boolean),
1343
- clarifyTimeoutError: A.transitional(A.boolean)
1344
- }, !1), s !== void 0 && se.assertOptions(s, {
1345
- encode: A.function,
1346
- serialize: A.function
1347
- }, !0), n.method = (n.method || this.defaults.method || "get").toLowerCase();
1348
- let i;
1349
- i = o && a.merge(
1450
+ r !== void 0 && ce.assertOptions(r, {
1451
+ silentJSONParsing: P.transitional(P.boolean),
1452
+ forcedJSONParsing: P.transitional(P.boolean),
1453
+ clarifyTimeoutError: P.transitional(P.boolean)
1454
+ }, !1), s != null && (a.isFunction(s) ? n.paramsSerializer = {
1455
+ serialize: s
1456
+ } : ce.assertOptions(s, {
1457
+ encode: P.function,
1458
+ serialize: P.function
1459
+ }, !0)), n.method = (n.method || this.defaults.method || "get").toLowerCase();
1460
+ let i = o && a.merge(
1350
1461
  o.common,
1351
1462
  o[n.method]
1352
- ), i && a.forEach(
1463
+ );
1464
+ o && a.forEach(
1353
1465
  ["delete", "get", "head", "post", "put", "patch", "common"],
1354
- (f) => {
1355
- delete o[f];
1466
+ (h) => {
1467
+ delete o[h];
1356
1468
  }
1357
- ), n.headers = g.concat(i, o);
1358
- const u = [];
1359
- let p = !0;
1360
- this.interceptors.request.forEach(function(h) {
1361
- typeof h.runWhen == "function" && h.runWhen(n) === !1 || (p = p && h.synchronous, u.unshift(h.fulfilled, h.rejected));
1469
+ ), n.headers = T.concat(i, o);
1470
+ const l = [];
1471
+ let u = !0;
1472
+ this.interceptors.request.forEach(function(d) {
1473
+ typeof d.runWhen == "function" && d.runWhen(n) === !1 || (u = u && d.synchronous, l.unshift(d.fulfilled, d.rejected));
1362
1474
  });
1363
- const c = [];
1364
- this.interceptors.response.forEach(function(h) {
1365
- c.push(h.fulfilled, h.rejected);
1475
+ const p = [];
1476
+ this.interceptors.response.forEach(function(d) {
1477
+ p.push(d.fulfilled, d.rejected);
1366
1478
  });
1367
- let l, d = 0, y;
1368
- if (!p) {
1369
- const f = [_e.bind(this), void 0];
1370
- for (f.unshift.apply(f, u), f.push.apply(f, c), y = f.length, l = Promise.resolve(n); d < y; )
1371
- l = l.then(f[d++], f[d++]);
1372
- return l;
1479
+ let f, c = 0, y;
1480
+ if (!u) {
1481
+ const h = [Fe.bind(this), void 0];
1482
+ for (h.unshift.apply(h, l), h.push.apply(h, p), y = h.length, f = Promise.resolve(n); c < y; )
1483
+ f = f.then(h[c++], h[c++]);
1484
+ return f;
1373
1485
  }
1374
- y = u.length;
1375
- let w = n;
1376
- for (d = 0; d < y; ) {
1377
- const f = u[d++], h = u[d++];
1486
+ y = l.length;
1487
+ let E = n;
1488
+ for (c = 0; c < y; ) {
1489
+ const h = l[c++], d = l[c++];
1378
1490
  try {
1379
- w = f(w);
1380
- } catch (R) {
1381
- h.call(this, R);
1491
+ E = h(E);
1492
+ } catch (b) {
1493
+ d.call(this, b);
1382
1494
  break;
1383
1495
  }
1384
1496
  }
1385
1497
  try {
1386
- l = _e.call(this, w);
1387
- } catch (f) {
1388
- return Promise.reject(f);
1498
+ f = Fe.call(this, E);
1499
+ } catch (h) {
1500
+ return Promise.reject(h);
1389
1501
  }
1390
- for (d = 0, y = c.length; d < y; )
1391
- l = l.then(c[d++], c[d++]);
1392
- return l;
1502
+ for (c = 0, y = p.length; c < y; )
1503
+ f = f.then(p[c++], p[c++]);
1504
+ return f;
1393
1505
  }
1394
1506
  getUri(t) {
1395
- t = T(this.defaults, t);
1396
- const n = Xe(t.baseURL, t.url);
1397
- return $e(n, t.params, t.paramsSerializer);
1507
+ t = C(this.defaults, t);
1508
+ const n = tt(t.baseURL, t.url);
1509
+ return Ge(n, t.params, t.paramsSerializer);
1398
1510
  }
1399
1511
  }
1400
1512
  a.forEach(["delete", "get", "head", "options"], function(t) {
1401
- $.prototype[t] = function(n, r) {
1402
- return this.request(T(r || {}, {
1513
+ J.prototype[t] = function(n, r) {
1514
+ return this.request(C(r || {}, {
1403
1515
  method: t,
1404
1516
  url: n,
1405
1517
  data: (r || {}).data
@@ -1408,8 +1520,8 @@ a.forEach(["delete", "get", "head", "options"], function(t) {
1408
1520
  });
1409
1521
  a.forEach(["post", "put", "patch"], function(t) {
1410
1522
  function n(r) {
1411
- return function(o, i, u) {
1412
- return this.request(T(u || {}, {
1523
+ return function(o, i, l) {
1524
+ return this.request(C(l || {}, {
1413
1525
  method: t,
1414
1526
  headers: r ? {
1415
1527
  "Content-Type": "multipart/form-data"
@@ -1419,10 +1531,10 @@ a.forEach(["post", "put", "patch"], function(t) {
1419
1531
  }));
1420
1532
  };
1421
1533
  }
1422
- $.prototype[t] = n(), $.prototype[t + "Form"] = n(!0);
1534
+ J.prototype[t] = n(), J.prototype[t + "Form"] = n(!0);
1423
1535
  });
1424
- const J = $;
1425
- class de {
1536
+ const $ = J;
1537
+ class me {
1426
1538
  constructor(t) {
1427
1539
  if (typeof t != "function")
1428
1540
  throw new TypeError("executor must be a function.");
@@ -1440,14 +1552,14 @@ class de {
1440
1552
  r._listeners = null;
1441
1553
  }), this.promise.then = (s) => {
1442
1554
  let o;
1443
- const i = new Promise((u) => {
1444
- r.subscribe(u), o = u;
1555
+ const i = new Promise((l) => {
1556
+ r.subscribe(l), o = l;
1445
1557
  }).then(s);
1446
1558
  return i.cancel = function() {
1447
1559
  r.unsubscribe(o);
1448
1560
  }, i;
1449
- }, t(function(o, i, u) {
1450
- r.reason || (r.reason = new j(o, i, u), n(r.reason));
1561
+ }, t(function(o, i, l) {
1562
+ r.reason || (r.reason = new v(o, i, l), n(r.reason));
1451
1563
  });
1452
1564
  }
1453
1565
  /**
@@ -1483,23 +1595,23 @@ class de {
1483
1595
  static source() {
1484
1596
  let t;
1485
1597
  return {
1486
- token: new de(function(s) {
1598
+ token: new me(function(s) {
1487
1599
  t = s;
1488
1600
  }),
1489
1601
  cancel: t
1490
1602
  };
1491
1603
  }
1492
1604
  }
1493
- const Un = de;
1494
- function jn(e) {
1605
+ const Jn = me;
1606
+ function Wn(e) {
1495
1607
  return function(n) {
1496
1608
  return e.apply(null, n);
1497
1609
  };
1498
1610
  }
1499
- function kn(e) {
1611
+ function Kn(e) {
1500
1612
  return a.isObject(e) && e.isAxiosError === !0;
1501
1613
  }
1502
- const oe = {
1614
+ const le = {
1503
1615
  Continue: 100,
1504
1616
  SwitchingProtocols: 101,
1505
1617
  Processing: 102,
@@ -1564,154 +1676,159 @@ const oe = {
1564
1676
  NotExtended: 510,
1565
1677
  NetworkAuthenticationRequired: 511
1566
1678
  };
1567
- Object.entries(oe).forEach(([e, t]) => {
1568
- oe[t] = e;
1679
+ Object.entries(le).forEach(([e, t]) => {
1680
+ le[t] = e;
1569
1681
  });
1570
- const vn = oe;
1571
- function Ye(e) {
1572
- const t = new J(e), n = Be(J.prototype.request, t);
1573
- return a.extend(n, J.prototype, t, { allOwnKeys: !0 }), a.extend(n, t, null, { allOwnKeys: !0 }), n.create = function(s) {
1574
- return Ye(T(e, s));
1682
+ const Xn = le;
1683
+ function st(e) {
1684
+ const t = new $(e), n = ve($.prototype.request, t);
1685
+ return a.extend(n, $.prototype, t, { allOwnKeys: !0 }), a.extend(n, t, null, { allOwnKeys: !0 }), n.create = function(s) {
1686
+ return st(C(e, s));
1575
1687
  }, n;
1576
1688
  }
1577
- const E = Ye(le);
1578
- E.Axios = J;
1579
- E.CanceledError = j;
1580
- E.CancelToken = Un;
1581
- E.isCancel = Ge;
1582
- E.VERSION = Qe;
1583
- E.toFormData = K;
1584
- E.AxiosError = m;
1585
- E.Cancel = E.CanceledError;
1586
- E.all = function(t) {
1689
+ const R = st(pe);
1690
+ R.Axios = $;
1691
+ R.CanceledError = v;
1692
+ R.CancelToken = Jn;
1693
+ R.isCancel = et;
1694
+ R.VERSION = rt;
1695
+ R.toFormData = G;
1696
+ R.AxiosError = m;
1697
+ R.Cancel = R.CanceledError;
1698
+ R.all = function(t) {
1587
1699
  return Promise.all(t);
1588
1700
  };
1589
- E.spread = jn;
1590
- E.isAxiosError = kn;
1591
- E.mergeConfig = T;
1592
- E.AxiosHeaders = g;
1593
- E.formToJSON = (e) => Ke(a.isHTMLForm(e) ? new FormData(e) : e);
1594
- E.HttpStatusCode = vn;
1595
- E.default = E;
1596
- const In = E, Mn = { class: "file-viewer" }, Hn = { class: "name" }, qn = {
1701
+ R.spread = Wn;
1702
+ R.isAxiosError = Kn;
1703
+ R.mergeConfig = C;
1704
+ R.AxiosHeaders = T;
1705
+ R.formToJSON = (e) => Ye(a.isHTMLForm(e) ? new FormData(e) : e);
1706
+ R.getAdapter = nt.getAdapter;
1707
+ R.HttpStatusCode = Xn;
1708
+ R.default = R;
1709
+ const Gn = R, Qn = { class: "file-viewer" }, Zn = { class: "name" }, Yn = {
1597
1710
  key: 0,
1598
1711
  class: "content loading"
1599
- }, Vn = /* @__PURE__ */ Ne({
1712
+ }, er = /* @__PURE__ */ Ue({
1600
1713
  __name: "FileViewer",
1601
1714
  props: {
1602
- file: null,
1603
- url: null
1715
+ file: {},
1716
+ url: {}
1604
1717
  },
1605
1718
  setup(e) {
1606
- const t = e, n = F(!1), r = F(""), s = F(""), o = F(""), i = F();
1719
+ const t = e, n = B(!1), r = B(""), s = B(""), o = B(""), i = B();
1607
1720
  return (() => {
1608
- const u = {
1721
+ const l = {
1609
1722
  loading: "正在加载中,请耐心等待...",
1610
1723
  reading: "正在努力解析文件...",
1611
- errorLoading: (l) => `加载文件异常:${l}`,
1612
- errorReading: (l) => `读取文件异常:${l}`
1724
+ errorLoading: (c) => `加载文件异常:${c}`,
1725
+ errorReading: (c) => `读取文件异常:${c}`
1613
1726
  };
1614
- let p;
1615
- const c = {
1727
+ let u;
1728
+ const p = {
1616
1729
  // 从url加载
1617
- async loadFromUrl() {
1618
- const { url: l } = t;
1619
- if (!l)
1620
- return;
1621
- this.startLoading(u.loading);
1622
- const d = l.substring(l.lastIndexOf("/") + 1);
1623
- try {
1624
- const { data: y } = await In({ url: l, method: "get", responseType: "blob" });
1625
- if (!y)
1626
- return this.showError("文件下载失败");
1627
- const w = this.wrap(y, d);
1628
- return this.resolveFile(w);
1629
- } catch (y) {
1630
- this.showError(u.errorLoading(y));
1631
- } finally {
1632
- this.endLoading();
1633
- }
1730
+ loadFromUrl() {
1731
+ return w(this, null, function* () {
1732
+ const { url: c } = t;
1733
+ if (!c)
1734
+ return;
1735
+ this.startLoading(l.loading);
1736
+ const y = c.substring(c.lastIndexOf("/") + 1);
1737
+ try {
1738
+ const { data: E } = yield Gn({ url: c, method: "get", responseType: "blob" });
1739
+ if (!E)
1740
+ return this.showError("文件下载失败");
1741
+ const h = this.wrap(E, y);
1742
+ return this.resolveFile(h);
1743
+ } catch (E) {
1744
+ this.showError(l.errorLoading(E));
1745
+ } finally {
1746
+ this.endLoading();
1747
+ }
1748
+ });
1634
1749
  },
1635
1750
  // 包装file
1636
- wrap(l, d) {
1637
- if (l instanceof File)
1638
- return l;
1639
- if (l instanceof Blob && d)
1640
- return new File([l], d, {});
1641
- if (l instanceof ArrayBuffer)
1642
- return this.wrap(new Blob([l]));
1751
+ wrap(c, y) {
1752
+ if (c instanceof File)
1753
+ return c;
1754
+ if (c instanceof Blob && y)
1755
+ return new File([c], y, {});
1756
+ if (c instanceof ArrayBuffer)
1757
+ return this.wrap(new Blob([c]));
1643
1758
  throw new Error("不支持的文件类型格式!");
1644
1759
  },
1645
1760
  // 处理并解析文件
1646
- async resolveFile(l) {
1647
- n.value && this.endLoading();
1648
- const d = this.wrap(l);
1649
- this.startLoading(u.reading);
1650
- try {
1651
- o.value = d.name && decodeURIComponent(d.name) || "";
1652
- const y = await ft(d);
1653
- y instanceof ArrayBuffer && (p = await this.displayResult(y, d));
1654
- } catch (y) {
1655
- console.error(y), this.showError(u.errorReading(y));
1656
- } finally {
1657
- this.endLoading();
1658
- }
1761
+ resolveFile(c) {
1762
+ return w(this, null, function* () {
1763
+ n.value && this.endLoading();
1764
+ const y = this.wrap(c);
1765
+ this.startLoading(l.reading);
1766
+ try {
1767
+ o.value = y.name && decodeURIComponent(y.name) || "";
1768
+ const E = yield Et(y);
1769
+ E instanceof ArrayBuffer && (u = yield this.displayResult(E, y));
1770
+ } catch (E) {
1771
+ console.error(E), this.showError(l.errorReading(E));
1772
+ } finally {
1773
+ this.endLoading();
1774
+ }
1775
+ });
1659
1776
  },
1660
1777
  // 展示渲染最终效果
1661
- displayResult(l, d) {
1662
- const { name: y } = d, w = Ot(y), f = i.value;
1663
- if (!f)
1778
+ displayResult(c, y) {
1779
+ const { name: E } = y, h = Nt(E), d = i.value;
1780
+ if (!d)
1664
1781
  return Promise.resolve();
1665
- p && (f.lastChild && f.removeChild(f.lastChild), p.unmount());
1666
- const h = document.createElement("div");
1667
- h.className = "file-render";
1668
- const R = f.appendChild(h);
1669
- return new Promise((b, x) => xt(l, w, R).then(b).catch(x));
1782
+ u && (d.lastChild && d.removeChild(d.lastChild), u.unmount());
1783
+ const b = document.createElement("div");
1784
+ b.className = "file-render";
1785
+ const S = d.appendChild(b);
1786
+ return new Promise((O, x) => Ft(c, h, S).then(O).catch(x));
1670
1787
  },
1671
- showError(l) {
1672
- r.value = l;
1788
+ showError(c) {
1789
+ r.value = c;
1673
1790
  },
1674
- startLoading(l) {
1675
- n.value = !0, s.value = l, r.value = "";
1791
+ startLoading(c) {
1792
+ n.value = !0, s.value = c, r.value = "";
1676
1793
  },
1677
1794
  endLoading() {
1678
1795
  n.value = !1, s.value = "";
1679
1796
  }
1680
1797
  };
1681
- nt(() => {
1682
- t.file && c.resolveFile(t.file), c.loadFromUrl();
1683
- }), he(() => t.url, () => c.loadFromUrl()), he(() => t.file, (l) => l && c.resolveFile(l));
1684
- })(), (u, p) => (I(), M("div", Mn, [
1685
- Q("div", Hn, H(o.value), 1),
1686
- r.value ? (I(), M("div", qn, H(r.value), 1)) : (I(), M(rt, { key: 1 }, [
1687
- me(Q("div", { class: "content loading" }, H(s.value), 513), [
1688
- [ye, n.value]
1798
+ lt(() => {
1799
+ t.file && p.resolveFile(t.file), p.loadFromUrl();
1800
+ }), Ee(() => t.url, () => p.loadFromUrl()), Ee(() => t.file, (c) => c && p.resolveFile(c));
1801
+ })(), (l, u) => (H(), M("div", Qn, [
1802
+ ee("div", Zn, q(o.value), 1),
1803
+ r.value ? (H(), M("div", Yn, q(r.value), 1)) : (H(), M(ut, { key: 1 }, [
1804
+ be(ee("div", { class: "content loading" }, q(s.value), 513), [
1805
+ [Re, n.value]
1689
1806
  ]),
1690
- me(Q("div", {
1807
+ be(ee("div", {
1691
1808
  class: "content",
1692
1809
  ref_key: "output",
1693
1810
  ref: i
1694
1811
  }, null, 512), [
1695
- [ye, !n.value]
1812
+ [Re, !n.value]
1696
1813
  ])
1697
1814
  ], 64))
1698
1815
  ]));
1699
1816
  }
1700
1817
  });
1701
- const zn = /* @__PURE__ */ Fe(Vn, [["__scopeId", "data-v-4732f9f2"]]), Jn = [
1702
- ["file-viewer", zn]
1818
+ const tr = /* @__PURE__ */ ke(er, [["__scopeId", "data-v-4732f9f2"]]), nr = [
1819
+ ["file-viewer", tr]
1703
1820
  ];
1704
- class $n {
1821
+ class rr {
1705
1822
  constructor() {
1706
- pe(this, "installed", !1);
1823
+ we(this, "installed", !1);
1707
1824
  }
1708
1825
  install(t) {
1709
- this.installed || (Jn.forEach(([n, r]) => t.component(n, r)), this.installed = !0);
1826
+ this.installed || (nr.forEach(([n, r]) => t.component(n, r)), this.installed = !0);
1710
1827
  }
1711
1828
  }
1712
- const Gn = new $n();
1829
+ const ir = new rr();
1713
1830
  export {
1714
- zn as F,
1715
- Fe as _,
1716
- Gn as i
1831
+ tr as F,
1832
+ ke as _,
1833
+ ir as i
1717
1834
  };