@cccsaurora/clue-ui 1.2.3-dev.266 → 1.2.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 (183) hide show
  1. package/ActionForm-DlOXqMUx.js +4460 -0
  2. package/AnnotationDetails-Bk-p0F6h.js +160 -0
  3. package/AnnotationPreview-jzZvkCxJ.js +140 -0
  4. package/ClueEnrichContext-KqRuuWNS.js +418 -0
  5. package/FlexOne-BXWFOd1T.js +6 -0
  6. package/_MapCache-BiTi0iqu.js +180 -0
  7. package/_Uint8Array-BQNOM9Rr.js +101 -0
  8. package/_baseAssignValue-CNMLQZco.js +20 -0
  9. package/_baseClone-BnT-6pyM.js +207 -0
  10. package/_baseExtremum-Ca2EHgy2.js +16 -0
  11. package/_baseFlatten-Bfr_Molw.js +72 -0
  12. package/_baseGet-DSZygzyq.js +79 -0
  13. package/_baseIsEqual-VgvaAFZG.js +147 -0
  14. package/_baseIteratee-Dbfsw5z8.js +95 -0
  15. package/_baseSlice-M5RKzt1A.js +10 -0
  16. package/_baseSum-wEbgNeUs.js +10 -0
  17. package/_baseUniq-BJcj69PL.js +79 -0
  18. package/_commonjsHelpers-DaMA6jEr.js +8 -0
  19. package/_createAggregator-k3TuAnxT.js +53 -0
  20. package/_getPrototype-Cr1Mk7BC.js +5 -0
  21. package/_getTag-CK2Sffaq.js +90 -0
  22. package/_isIterateeCall-DkJP7Rbx.js +13 -0
  23. package/_setToArray-C7yMOeww.js +29 -0
  24. package/cloneDeep-CF8TtLHr.js +8 -0
  25. package/components/AnnotationBody.js +35 -49
  26. package/components/AnnotationDetailPopover.js +30 -36
  27. package/components/AnnotationDetails.js +7 -7
  28. package/components/AnnotationEntry.js +35 -35
  29. package/components/AnnotationPreview.js +5 -5
  30. package/components/ClassificationChip.js +23 -44
  31. package/components/CountBadge.js +26 -31
  32. package/components/EnrichedCard.js +97 -110
  33. package/components/EnrichedChip.js +105 -130
  34. package/components/EnrichedTypography.js +107 -133
  35. package/components/ErrorBoundary.js +24 -28
  36. package/components/RetryFailedEnrichments.js +9 -10
  37. package/components/SourcePicker.js +49 -57
  38. package/components/actions/ActionForm.js +4 -4
  39. package/components/actions/ExecutePopover.js +59 -75
  40. package/components/actions/ResultModal.js +4 -4
  41. package/components/actions/form/schemaAdapter.js +23 -39
  42. package/components/actions/formats/FileResult.js +59 -86
  43. package/components/actions/formats/index.js +10 -21
  44. package/components/display/graph/ExpandMoreButton.js +10 -10
  45. package/components/display/graph/elements/NodeCard.js +91 -111
  46. package/components/display/graph/elements/NodeTag.js +13 -15
  47. package/components/display/graph/index.js +202 -261
  48. package/components/display/graph/visualizations/Leaf.js +69 -88
  49. package/components/display/graph/visualizations/cloud/index.js +81 -98
  50. package/components/display/graph/visualizations/icons/BaseIcon.js +21 -26
  51. package/components/display/graph/visualizations/icons/BugIcon.js +12 -12
  52. package/components/display/graph/visualizations/icons/HostIcon.js +12 -12
  53. package/components/display/graph/visualizations/icons/NetworkIcon.js +12 -12
  54. package/components/display/graph/visualizations/icons/ProcessIcon.js +12 -12
  55. package/components/display/graph/visualizations/icons/TargetIcon.js +13 -13
  56. package/components/display/graph/visualizations/icons/index.js +13 -14
  57. package/components/display/graph/visualizations/panels/NodePanel.js +8 -10
  58. package/components/display/graph/visualizations/tree/BundleLine.js +81 -108
  59. package/components/display/graph/visualizations/tree/Triangle.js +13 -13
  60. package/components/display/graph/visualizations/tree/index.js +306 -408
  61. package/components/display/icons/Iconified.js +12 -27
  62. package/components/display/json/index.js +4 -4
  63. package/components/display/markdown/index.js +5770 -8678
  64. package/components/enrichment/EnrichPopover.js +46 -54
  65. package/components/fetchers/Fetcher.js +119 -158
  66. package/components/fetchers/PreviewModal.js +17 -20
  67. package/components/fetchers/StatusChip.js +17 -21
  68. package/components/group/Entry.js +11 -13
  69. package/components/group/Group.js +10 -13
  70. package/components/group/GroupControl.js +65 -76
  71. package/components/stats/QueryStatus.js +33 -43
  72. package/countBy-CdYegFSu.js +8 -0
  73. package/data/event.js +4 -6
  74. package/database/index.js +2 -2
  75. package/debounce-DryYcbJ4.js +56 -0
  76. package/get-CH7kz5Ix.js +8 -0
  77. package/groupBy-br8xmD2R.js +8 -0
  78. package/hooks/ClueActionContext.js +6 -6
  79. package/hooks/ClueComponentContext.js +23 -29
  80. package/hooks/ClueConfigProvider.js +12 -14
  81. package/hooks/ClueDatabaseContext.js +13 -19
  82. package/hooks/ClueEnrichContext.js +8 -8
  83. package/hooks/ClueFetcherContext.js +56 -83
  84. package/hooks/ClueGroupContext.js +14 -17
  85. package/hooks/CluePopupContext.js +5 -5
  86. package/hooks/ClueProvider.js +10 -12
  87. package/hooks/selectors.js +7 -7
  88. package/hooks/useActionResult.js +2 -2
  89. package/hooks/useAnnotations.js +31 -47
  90. package/hooks/useClue.js +4 -6
  91. package/hooks/useClueActions.js +3 -3
  92. package/hooks/useClueConfig.js +4 -6
  93. package/hooks/useClueTypeConfig.js +3 -3
  94. package/hooks/useComparator.js +435 -722
  95. package/hooks/useErrors.js +18 -22
  96. package/hooks/useFetcherResult.js +24 -33
  97. package/hooks/useMyHighlights.js +36 -66
  98. package/hooks/useMyLocalStorage.js +37 -66
  99. package/iconify-BBckr5AQ.js +1263 -0
  100. package/icons/Action.js +49 -66
  101. package/icons/Assessment.js +69 -85
  102. package/icons/Context.js +63 -77
  103. package/icons/Opinion.js +60 -76
  104. package/icons/iconMap.js +2 -2
  105. package/identity-ByMq8VxU.js +6 -0
  106. package/index-BHAe_V9n.js +12768 -0
  107. package/index-BK-zfYhR.js +358 -0
  108. package/index-CA5CUNZO.js +975 -0
  109. package/index-Dj5C04IX.js +568 -0
  110. package/index-p5_wX7q1.js +11729 -0
  111. package/isNil-CjWwlQS3.js +6 -0
  112. package/isObject-B53jY8Qg.js +7 -0
  113. package/isObjectLike-BatpeCIi.js +29 -0
  114. package/isSymbol-C3_SC0Qp.js +8 -0
  115. package/last-7CdUxN0r.js +7 -0
  116. package/main.js +60 -60
  117. package/maxBy-Bc0dYHcO.js +8 -0
  118. package/package.json +1 -1
  119. package/sortBy-DY2JBf9n.js +75 -0
  120. package/sumBy-DuMASLPd.js +8 -0
  121. package/text/Frequency.js +23 -42
  122. package/toFinite-BMy6GObD.js +14 -0
  123. package/toNumber-YVhnnJv4.js +31 -0
  124. package/useClueTypeConfig-Ct9Ygter.js +2292 -0
  125. package/utils/chain.js +65 -92
  126. package/utils/classificationParser.js +256 -519
  127. package/utils/constants.js +10 -35
  128. package/utils/graph.js +45 -72
  129. package/utils/hashUtil.js +7 -7
  130. package/utils/line.js +81 -131
  131. package/utils/loggerUtil.js +3 -5
  132. package/utils/sessionStorage.js +27 -41
  133. package/utils/time.js +423 -423
  134. package/utils/utils.js +9 -9
  135. package/utils/window.js +10 -21
  136. package/utils-DmwSUrum.js +129 -0
  137. package/ActionForm-uDp92tN2.js +0 -5941
  138. package/AnnotationDetails-DGYfOiWm.js +0 -175
  139. package/AnnotationPreview-bHObsb3P.js +0 -188
  140. package/ClueEnrichContext-CJEJxrgs.js +0 -541
  141. package/FlexOne-BSYAhhtG.js +0 -9
  142. package/_MapCache-WmuDdwuH.js +0 -222
  143. package/_Uint8Array-B7JqpgFX.js +0 -128
  144. package/_baseAssignValue-CGTuELqU.js +0 -25
  145. package/_baseClone-CkNrTyhm.js +0 -283
  146. package/_baseExtremum-kob8QXyt.js +0 -18
  147. package/_baseFlatten-jIR_sN_-.js +0 -92
  148. package/_baseGet-Bx3A4Qfp.js +0 -108
  149. package/_baseIsEqual-C5OTWzTk.js +0 -208
  150. package/_baseIteratee-avi7MX2o.js +0 -126
  151. package/_baseSlice-GAv_YFTT.js +0 -20
  152. package/_baseSum-D0WC1dN0.js +0 -13
  153. package/_baseUniq-BI9GIHMF.js +0 -115
  154. package/_commonjsHelpers-DWwsNxpa.js +0 -8
  155. package/_createAggregator-QD8MzKwe.js +0 -63
  156. package/_getPrototype-CU0j_POw.js +0 -5
  157. package/_getTag-Ckxxfr88.js +0 -126
  158. package/_isIterateeCall-Ds3sw2SF.js +0 -17
  159. package/_setToArray-CaPKQhcz.js +0 -33
  160. package/cloneDeep-DJrLSw8W.js +0 -8
  161. package/countBy-c6S3dvSW.js +0 -14
  162. package/debounce-bV0h5FC5.js +0 -92
  163. package/get-DSsNkRQs.js +0 -8
  164. package/groupBy-xqz-n0Vd.js +0 -14
  165. package/iconify-CXMreGTg.js +0 -1782
  166. package/identity-CPGTqrE4.js +0 -6
  167. package/index-AMfoEg_6.js +0 -696
  168. package/index-B6C2a_Lg.js +0 -1172
  169. package/index-C12gPw2W.js +0 -17698
  170. package/index-DCKkHTvx.js +0 -15750
  171. package/index-JcKyZeoY.js +0 -465
  172. package/isNil-CIubwp4T.js +0 -6
  173. package/isObject-FTY-5JQX.js +0 -7
  174. package/isObjectLike-OAgjjZye.js +0 -48
  175. package/isSymbol-Xd2FsJyp.js +0 -8
  176. package/last-CUCl67Im.js +0 -7
  177. package/maxBy-IKHzFrCS.js +0 -8
  178. package/sortBy-DfSj8IoJ.js +0 -96
  179. package/sumBy-D-hb_NY-.js +0 -8
  180. package/toFinite-Bc55msYj.js +0 -16
  181. package/toNumber-DPxy1FBy.js +0 -39
  182. package/useClueTypeConfig-Z1LFp01b.js +0 -3289
  183. package/utils-HmNPuoDB.js +0 -199
@@ -0,0 +1,2292 @@
1
+ var on = Object.defineProperty;
2
+ var an = (e, t, n) => t in e ? on(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
3
+ var Ye = (e, t, n) => an(e, typeof t != "symbol" ? t + "" : t, n);
4
+ import { i as pe } from "./isNil-CjWwlQS3.js";
5
+ import { MY_LOCAL_STORAGE_PREFIX as Ne, StorageKey as O } from "./utils/constants.js";
6
+ import { g as cn } from "./_commonjsHelpers-DaMA6jEr.js";
7
+ import { getAxiosCache as un, setAxiosCache as ln } from "./utils/sessionStorage.js";
8
+ import { clueDebugLogger as fn } from "./utils/loggerUtil.js";
9
+ import { b as dn, i as pn } from "./_baseUniq-BJcj69PL.js";
10
+ import { useState as Se, useEffect as hn } from "react";
11
+ function mn(e) {
12
+ return e && e.length ? dn(e) : [];
13
+ }
14
+ const En = (e, t, n = { timeout: null }, r) => {
15
+ const s = [];
16
+ return pe(n.timeout) || s.push(`max_timeout=${n.timeout}`), I(
17
+ w(Q(), `${e.replace(".", "/")}/status/${t}`),
18
+ s.length > 0 ? new URLSearchParams(s.join("&")) : null,
19
+ r
20
+ );
21
+ }, yn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
22
+ __proto__: null,
23
+ get: En
24
+ }, Symbol.toStringTag, { value: "Module" })), Q = () => w($(), "actions"), gn = (e) => I(Q(), null, e), Rn = (e, t, n, r, s = { timeout: null }, o) => {
25
+ const i = [];
26
+ pe(s.timeout) || i.push(`max_timeout=${s.timeout}`);
27
+ const a = { ...n };
28
+ return Array.isArray(t) ? t.length < 2 ? (a.selector = t[0], a.selectors = []) : a.selectors = t : (a.selector = t, a.selectors = []), a.context = r ?? null, be(
29
+ w(
30
+ w(Q(), "execute"),
31
+ e.replace(".", "/"),
32
+ i.length > 0 ? new URLSearchParams(i.join("&")) : null
33
+ ),
34
+ a,
35
+ o
36
+ );
37
+ }, bn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
38
+ __proto__: null,
39
+ get: gn,
40
+ post: Rn,
41
+ status: yn,
42
+ uri: Q
43
+ }, Symbol.toStringTag, { value: "Module" })), Ie = (e) => w(gt(), "login", e), _n = (e) => be(Ie(), e), On = (e) => {
44
+ const t = localStorage.getItem(`${Ne}.${O.LOGIN_NONCE}`);
45
+ return t && (e.set("nonce", JSON.parse(t)), localStorage.removeItem(`${Ne}.${O.LOGIN_NONCE}`)), I(Ie(), e);
46
+ }, Sn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
47
+ __proto__: null,
48
+ get: On,
49
+ post: _n,
50
+ uri: Ie
51
+ }, Symbol.toStringTag, { value: "Module" })), gt = () => w($(), "auth"), wn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
52
+ __proto__: null,
53
+ login: Sn,
54
+ uri: gt
55
+ }, Symbol.toStringTag, { value: "Module" })), Rt = () => w($(), "configs"), Tn = (e) => I(Rt(), null, e), An = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
56
+ __proto__: null,
57
+ get: Tn,
58
+ uri: Rt
59
+ }, Symbol.toStringTag, { value: "Module" })), Cn = (e, t, n = { timeout: null }, r) => {
60
+ const s = [];
61
+ return pe(n.timeout) || s.push(`max_timeout=${n.timeout}`), I(
62
+ w(Q(), `${e.replace(".", "/")}/status/${t}`),
63
+ s.length > 0 ? new URLSearchParams(s.join("&")) : null,
64
+ r
65
+ );
66
+ }, Nn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
67
+ __proto__: null,
68
+ get: Cn
69
+ }, Symbol.toStringTag, { value: "Module" })), Fe = () => w($(), "fetchers"), Pn = (e) => I(Fe(), null, e), Dn = (e, t, n) => be(rn(Fe(), e.replace(".", "/")), t, n), Ln = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
70
+ __proto__: null,
71
+ get: Pn,
72
+ post: Dn,
73
+ status: Nn,
74
+ uri: Fe
75
+ }, Symbol.toStringTag, { value: "Module" })), bt = () => w(he(), "enrich"), xn = (e, t = [], n = { timeout: null, includeRaw: !1, noCache: !1 }, r) => {
76
+ const s = [];
77
+ return (t == null ? void 0 : t.length) > 0 && s.push(`sources=${t.join()}`), n.classification && s.push(`classification=${encodeURIComponent(n.classification)}`), pe(n.timeout) || s.push(`max_timeout=${n.timeout}`), n.includeRaw && s.push("include_raw=true"), n.noCache && s.push("no_cache=true"), be(
78
+ w(bt(), "", s.length > 0 ? new URLSearchParams(s.join("&")) : null),
79
+ e,
80
+ r
81
+ );
82
+ }, Un = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
83
+ __proto__: null,
84
+ post: xn,
85
+ uri: bt
86
+ }, Symbol.toStringTag, { value: "Module" })), _t = () => w(he(), "types"), Ot = (e) => I(_t(), null, e), In = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
87
+ __proto__: null,
88
+ get: Ot,
89
+ uri: _t
90
+ }, Symbol.toStringTag, { value: "Module" })), St = () => w(he(), "types_detection"), wt = (e) => I(St(), null, e), Fn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
91
+ __proto__: null,
92
+ get: wt,
93
+ uri: St
94
+ }, Symbol.toStringTag, { value: "Module" })), he = () => w($(), "lookup"), jn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
95
+ __proto__: null,
96
+ enrich: Un,
97
+ types: In,
98
+ types_detection: Fn,
99
+ uri: he
100
+ }, Symbol.toStringTag, { value: "Module" })), Tt = (e) => w(je(), e ? "/docs?filter=" + e : "/docs"), $n = (e, t) => I(Tt(e), null, t), Bn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
101
+ __proto__: null,
102
+ get: $n,
103
+ uri: Tt
104
+ }, Symbol.toStringTag, { value: "Module" })), At = (e) => rn(je(), "docs", e), kn = (e, t) => I(At(e), null, t), vn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
105
+ __proto__: null,
106
+ get: kn,
107
+ uri: At
108
+ }, Symbol.toStringTag, { value: "Module" })), je = () => w($(), "static"), qn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
109
+ __proto__: null,
110
+ all_documentation: Bn,
111
+ documentation: vn,
112
+ uri: je
113
+ }, Symbol.toStringTag, { value: "Module" }));
114
+ function Ct(e, t) {
115
+ return function() {
116
+ return e.apply(t, arguments);
117
+ };
118
+ }
119
+ const { toString: Mn } = Object.prototype, { getPrototypeOf: $e } = Object, { iterator: me, toStringTag: Nt } = Symbol, Ee = /* @__PURE__ */ ((e) => (t) => {
120
+ const n = Mn.call(t);
121
+ return e[n] || (e[n] = n.slice(8, -1).toLowerCase());
122
+ })(/* @__PURE__ */ Object.create(null)), U = (e) => (e = e.toLowerCase(), (t) => Ee(t) === e), ye = (e) => (t) => typeof t === e, { isArray: V } = Array, J = ye("undefined");
123
+ function Z(e) {
124
+ return e !== null && !J(e) && e.constructor !== null && !J(e.constructor) && N(e.constructor.isBuffer) && e.constructor.isBuffer(e);
125
+ }
126
+ const Pt = U("ArrayBuffer");
127
+ function Hn(e) {
128
+ let t;
129
+ return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? t = ArrayBuffer.isView(e) : t = e && e.buffer && Pt(e.buffer), t;
130
+ }
131
+ const zn = ye("string"), N = ye("function"), Dt = ye("number"), ee = (e) => e !== null && typeof e == "object", Jn = (e) => e === !0 || e === !1, ce = (e) => {
132
+ if (Ee(e) !== "object")
133
+ return !1;
134
+ const t = $e(e);
135
+ return (t === null || t === Object.prototype || Object.getPrototypeOf(t) === null) && !(Nt in e) && !(me in e);
136
+ }, Vn = (e) => {
137
+ if (!ee(e) || Z(e))
138
+ return !1;
139
+ try {
140
+ return Object.keys(e).length === 0 && Object.getPrototypeOf(e) === Object.prototype;
141
+ } catch {
142
+ return !1;
143
+ }
144
+ }, Kn = U("Date"), Xn = U("File"), Wn = U("Blob"), Gn = U("FileList"), Yn = (e) => ee(e) && N(e.pipe), Qn = (e) => {
145
+ let t;
146
+ return e && (typeof FormData == "function" && e instanceof FormData || N(e.append) && ((t = Ee(e)) === "formdata" || // detect form-data instance
147
+ t === "object" && N(e.toString) && e.toString() === "[object FormData]"));
148
+ }, Zn = U("URLSearchParams"), [er, tr, nr, rr] = [
149
+ "ReadableStream",
150
+ "Request",
151
+ "Response",
152
+ "Headers"
153
+ ].map(U), sr = (e) => e.trim ? e.trim() : e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
154
+ function te(e, t, { allOwnKeys: n = !1 } = {}) {
155
+ if (e === null || typeof e > "u")
156
+ return;
157
+ let r, s;
158
+ if (typeof e != "object" && (e = [e]), V(e))
159
+ for (r = 0, s = e.length; r < s; r++)
160
+ t.call(null, e[r], r, e);
161
+ else {
162
+ if (Z(e))
163
+ return;
164
+ const o = n ? Object.getOwnPropertyNames(e) : Object.keys(e), i = o.length;
165
+ let a;
166
+ for (r = 0; r < i; r++)
167
+ a = o[r], t.call(null, e[a], a, e);
168
+ }
169
+ }
170
+ function Lt(e, t) {
171
+ if (Z(e))
172
+ return null;
173
+ t = t.toLowerCase();
174
+ const n = Object.keys(e);
175
+ let r = n.length, s;
176
+ for (; r-- > 0; )
177
+ if (s = n[r], t === s.toLowerCase())
178
+ return s;
179
+ return null;
180
+ }
181
+ const v = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : global, xt = (e) => !J(e) && e !== v;
182
+ function Pe() {
183
+ const { caseless: e, skipUndefined: t } = xt(this) && this || {}, n = {}, r = (s, o) => {
184
+ if (o === "__proto__" || o === "constructor" || o === "prototype")
185
+ return;
186
+ const i = e && Lt(n, o) || o;
187
+ ce(n[i]) && ce(s) ? n[i] = Pe(n[i], s) : ce(s) ? n[i] = Pe({}, s) : V(s) ? n[i] = s.slice() : (!t || !J(s)) && (n[i] = s);
188
+ };
189
+ for (let s = 0, o = arguments.length; s < o; s++)
190
+ arguments[s] && te(arguments[s], r);
191
+ return n;
192
+ }
193
+ const or = (e, t, n, { allOwnKeys: r } = {}) => (te(
194
+ t,
195
+ (s, o) => {
196
+ n && N(s) ? Object.defineProperty(e, o, {
197
+ value: Ct(s, n),
198
+ writable: !0,
199
+ enumerable: !0,
200
+ configurable: !0
201
+ }) : Object.defineProperty(e, o, {
202
+ value: s,
203
+ writable: !0,
204
+ enumerable: !0,
205
+ configurable: !0
206
+ });
207
+ },
208
+ { allOwnKeys: r }
209
+ ), e), ir = (e) => (e.charCodeAt(0) === 65279 && (e = e.slice(1)), e), ar = (e, t, n, r) => {
210
+ e.prototype = Object.create(
211
+ t.prototype,
212
+ r
213
+ ), Object.defineProperty(e.prototype, "constructor", {
214
+ value: e,
215
+ writable: !0,
216
+ enumerable: !1,
217
+ configurable: !0
218
+ }), Object.defineProperty(e, "super", {
219
+ value: t.prototype
220
+ }), n && Object.assign(e.prototype, n);
221
+ }, cr = (e, t, n, r) => {
222
+ let s, o, i;
223
+ const a = {};
224
+ if (t = t || {}, e == null) return t;
225
+ do {
226
+ for (s = Object.getOwnPropertyNames(e), o = s.length; o-- > 0; )
227
+ i = s[o], (!r || r(i, e, t)) && !a[i] && (t[i] = e[i], a[i] = !0);
228
+ e = n !== !1 && $e(e);
229
+ } while (e && (!n || n(e, t)) && e !== Object.prototype);
230
+ return t;
231
+ }, ur = (e, t, n) => {
232
+ e = String(e), (n === void 0 || n > e.length) && (n = e.length), n -= t.length;
233
+ const r = e.indexOf(t, n);
234
+ return r !== -1 && r === n;
235
+ }, lr = (e) => {
236
+ if (!e) return null;
237
+ if (V(e)) return e;
238
+ let t = e.length;
239
+ if (!Dt(t)) return null;
240
+ const n = new Array(t);
241
+ for (; t-- > 0; )
242
+ n[t] = e[t];
243
+ return n;
244
+ }, fr = /* @__PURE__ */ ((e) => (t) => e && t instanceof e)(typeof Uint8Array < "u" && $e(Uint8Array)), dr = (e, t) => {
245
+ const r = (e && e[me]).call(e);
246
+ let s;
247
+ for (; (s = r.next()) && !s.done; ) {
248
+ const o = s.value;
249
+ t.call(e, o[0], o[1]);
250
+ }
251
+ }, pr = (e, t) => {
252
+ let n;
253
+ const r = [];
254
+ for (; (n = e.exec(t)) !== null; )
255
+ r.push(n);
256
+ return r;
257
+ }, hr = U("HTMLFormElement"), mr = (e) => e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g, function(n, r, s) {
258
+ return r.toUpperCase() + s;
259
+ }), Qe = (({ hasOwnProperty: e }) => (t, n) => e.call(t, n))(Object.prototype), Er = U("RegExp"), Ut = (e, t) => {
260
+ const n = Object.getOwnPropertyDescriptors(e), r = {};
261
+ te(n, (s, o) => {
262
+ let i;
263
+ (i = t(s, o, e)) !== !1 && (r[o] = i || s);
264
+ }), Object.defineProperties(e, r);
265
+ }, yr = (e) => {
266
+ Ut(e, (t, n) => {
267
+ if (N(e) && ["arguments", "caller", "callee"].indexOf(n) !== -1)
268
+ return !1;
269
+ const r = e[n];
270
+ if (N(r)) {
271
+ if (t.enumerable = !1, "writable" in t) {
272
+ t.writable = !1;
273
+ return;
274
+ }
275
+ t.set || (t.set = () => {
276
+ throw Error("Can not rewrite read-only method '" + n + "'");
277
+ });
278
+ }
279
+ });
280
+ }, gr = (e, t) => {
281
+ const n = {}, r = (s) => {
282
+ s.forEach((o) => {
283
+ n[o] = !0;
284
+ });
285
+ };
286
+ return V(e) ? r(e) : r(String(e).split(t)), n;
287
+ }, Rr = () => {
288
+ }, br = (e, t) => e != null && Number.isFinite(e = +e) ? e : t;
289
+ function _r(e) {
290
+ return !!(e && N(e.append) && e[Nt] === "FormData" && e[me]);
291
+ }
292
+ const Or = (e) => {
293
+ const t = new Array(10), n = (r, s) => {
294
+ if (ee(r)) {
295
+ if (t.indexOf(r) >= 0)
296
+ return;
297
+ if (Z(r))
298
+ return r;
299
+ if (!("toJSON" in r)) {
300
+ t[s] = r;
301
+ const o = V(r) ? [] : {};
302
+ return te(r, (i, a) => {
303
+ const f = n(i, s + 1);
304
+ !J(f) && (o[a] = f);
305
+ }), t[s] = void 0, o;
306
+ }
307
+ }
308
+ return r;
309
+ };
310
+ return n(e, 0);
311
+ }, Sr = U("AsyncFunction"), wr = (e) => e && (ee(e) || N(e)) && N(e.then) && N(e.catch), It = ((e, t) => e ? setImmediate : t ? ((n, r) => (v.addEventListener(
312
+ "message",
313
+ ({ source: s, data: o }) => {
314
+ s === v && o === n && r.length && r.shift()();
315
+ },
316
+ !1
317
+ ), (s) => {
318
+ r.push(s), v.postMessage(n, "*");
319
+ }))(`axios@${Math.random()}`, []) : (n) => setTimeout(n))(typeof setImmediate == "function", N(v.postMessage)), Tr = typeof queueMicrotask < "u" ? queueMicrotask.bind(v) : typeof process < "u" && process.nextTick || It, Ar = (e) => e != null && N(e[me]), c = {
320
+ isArray: V,
321
+ isArrayBuffer: Pt,
322
+ isBuffer: Z,
323
+ isFormData: Qn,
324
+ isArrayBufferView: Hn,
325
+ isString: zn,
326
+ isNumber: Dt,
327
+ isBoolean: Jn,
328
+ isObject: ee,
329
+ isPlainObject: ce,
330
+ isEmptyObject: Vn,
331
+ isReadableStream: er,
332
+ isRequest: tr,
333
+ isResponse: nr,
334
+ isHeaders: rr,
335
+ isUndefined: J,
336
+ isDate: Kn,
337
+ isFile: Xn,
338
+ isBlob: Wn,
339
+ isRegExp: Er,
340
+ isFunction: N,
341
+ isStream: Yn,
342
+ isURLSearchParams: Zn,
343
+ isTypedArray: fr,
344
+ isFileList: Gn,
345
+ forEach: te,
346
+ merge: Pe,
347
+ extend: or,
348
+ trim: sr,
349
+ stripBOM: ir,
350
+ inherits: ar,
351
+ toFlatObject: cr,
352
+ kindOf: Ee,
353
+ kindOfTest: U,
354
+ endsWith: ur,
355
+ toArray: lr,
356
+ forEachEntry: dr,
357
+ matchAll: pr,
358
+ isHTMLForm: hr,
359
+ hasOwnProperty: Qe,
360
+ hasOwnProp: Qe,
361
+ // an alias to avoid ESLint no-prototype-builtins detection
362
+ reduceDescriptors: Ut,
363
+ freezeMethods: yr,
364
+ toObjectSet: gr,
365
+ toCamelCase: mr,
366
+ noop: Rr,
367
+ toFiniteNumber: br,
368
+ findKey: Lt,
369
+ global: v,
370
+ isContextDefined: xt,
371
+ isSpecCompliantForm: _r,
372
+ toJSONObject: Or,
373
+ isAsyncFn: Sr,
374
+ isThenable: wr,
375
+ setImmediate: It,
376
+ asap: Tr,
377
+ isIterable: Ar
378
+ };
379
+ let E = class Ft extends Error {
380
+ static from(t, n, r, s, o, i) {
381
+ const a = new Ft(t.message, n || t.code, r, s, o);
382
+ return a.cause = t, a.name = t.name, i && Object.assign(a, i), a;
383
+ }
384
+ /**
385
+ * Create an Error with the specified message, config, error code, request and response.
386
+ *
387
+ * @param {string} message The error message.
388
+ * @param {string} [code] The error code (for example, 'ECONNABORTED').
389
+ * @param {Object} [config] The config.
390
+ * @param {Object} [request] The request.
391
+ * @param {Object} [response] The response.
392
+ *
393
+ * @returns {Error} The created error.
394
+ */
395
+ constructor(t, n, r, s, o) {
396
+ super(t), this.name = "AxiosError", this.isAxiosError = !0, n && (this.code = n), r && (this.config = r), s && (this.request = s), o && (this.response = o, this.status = o.status);
397
+ }
398
+ toJSON() {
399
+ return {
400
+ // Standard
401
+ message: this.message,
402
+ name: this.name,
403
+ // Microsoft
404
+ description: this.description,
405
+ number: this.number,
406
+ // Mozilla
407
+ fileName: this.fileName,
408
+ lineNumber: this.lineNumber,
409
+ columnNumber: this.columnNumber,
410
+ stack: this.stack,
411
+ // Axios
412
+ config: c.toJSONObject(this.config),
413
+ code: this.code,
414
+ status: this.status
415
+ };
416
+ }
417
+ };
418
+ E.ERR_BAD_OPTION_VALUE = "ERR_BAD_OPTION_VALUE";
419
+ E.ERR_BAD_OPTION = "ERR_BAD_OPTION";
420
+ E.ECONNABORTED = "ECONNABORTED";
421
+ E.ETIMEDOUT = "ETIMEDOUT";
422
+ E.ERR_NETWORK = "ERR_NETWORK";
423
+ E.ERR_FR_TOO_MANY_REDIRECTS = "ERR_FR_TOO_MANY_REDIRECTS";
424
+ E.ERR_DEPRECATED = "ERR_DEPRECATED";
425
+ E.ERR_BAD_RESPONSE = "ERR_BAD_RESPONSE";
426
+ E.ERR_BAD_REQUEST = "ERR_BAD_REQUEST";
427
+ E.ERR_CANCELED = "ERR_CANCELED";
428
+ E.ERR_NOT_SUPPORT = "ERR_NOT_SUPPORT";
429
+ E.ERR_INVALID_URL = "ERR_INVALID_URL";
430
+ const Cr = null;
431
+ function De(e) {
432
+ return c.isPlainObject(e) || c.isArray(e);
433
+ }
434
+ function jt(e) {
435
+ return c.endsWith(e, "[]") ? e.slice(0, -2) : e;
436
+ }
437
+ function Ze(e, t, n) {
438
+ return e ? e.concat(t).map(function(s, o) {
439
+ return s = jt(s), !n && o ? "[" + s + "]" : s;
440
+ }).join(n ? "." : "") : t;
441
+ }
442
+ function Nr(e) {
443
+ return c.isArray(e) && !e.some(De);
444
+ }
445
+ const Pr = c.toFlatObject(c, {}, null, function(t) {
446
+ return /^is[A-Z]/.test(t);
447
+ });
448
+ function ge(e, t, n) {
449
+ if (!c.isObject(e))
450
+ throw new TypeError("target must be an object");
451
+ t = t || new FormData(), n = c.toFlatObject(n, {
452
+ metaTokens: !0,
453
+ dots: !1,
454
+ indexes: !1
455
+ }, !1, function(m, p) {
456
+ return !c.isUndefined(p[m]);
457
+ });
458
+ const r = n.metaTokens, s = n.visitor || u, o = n.dots, i = n.indexes, f = (n.Blob || typeof Blob < "u" && Blob) && c.isSpecCompliantForm(t);
459
+ if (!c.isFunction(s))
460
+ throw new TypeError("visitor must be a function");
461
+ function d(l) {
462
+ if (l === null) return "";
463
+ if (c.isDate(l))
464
+ return l.toISOString();
465
+ if (c.isBoolean(l))
466
+ return l.toString();
467
+ if (!f && c.isBlob(l))
468
+ throw new E("Blob is not supported. Use a Buffer instead.");
469
+ return c.isArrayBuffer(l) || c.isTypedArray(l) ? f && typeof Blob == "function" ? new Blob([l]) : Buffer.from(l) : l;
470
+ }
471
+ function u(l, m, p) {
472
+ let R = l;
473
+ if (l && !p && typeof l == "object") {
474
+ if (c.endsWith(m, "{}"))
475
+ m = r ? m : m.slice(0, -2), l = JSON.stringify(l);
476
+ else if (c.isArray(l) && Nr(l) || (c.isFileList(l) || c.endsWith(m, "[]")) && (R = c.toArray(l)))
477
+ return m = jt(m), R.forEach(function(_, A) {
478
+ !(c.isUndefined(_) || _ === null) && t.append(
479
+ // eslint-disable-next-line no-nested-ternary
480
+ i === !0 ? Ze([m], A, o) : i === null ? m : m + "[]",
481
+ d(_)
482
+ );
483
+ }), !1;
484
+ }
485
+ return De(l) ? !0 : (t.append(Ze(p, m, o), d(l)), !1);
486
+ }
487
+ const h = [], y = Object.assign(Pr, {
488
+ defaultVisitor: u,
489
+ convertValue: d,
490
+ isVisitable: De
491
+ });
492
+ function g(l, m) {
493
+ if (!c.isUndefined(l)) {
494
+ if (h.indexOf(l) !== -1)
495
+ throw Error("Circular reference detected in " + m.join("."));
496
+ h.push(l), c.forEach(l, function(R, T) {
497
+ (!(c.isUndefined(R) || R === null) && s.call(
498
+ t,
499
+ R,
500
+ c.isString(T) ? T.trim() : T,
501
+ m,
502
+ y
503
+ )) === !0 && g(R, m ? m.concat(T) : [T]);
504
+ }), h.pop();
505
+ }
506
+ }
507
+ if (!c.isObject(e))
508
+ throw new TypeError("data must be an object");
509
+ return g(e), t;
510
+ }
511
+ function et(e) {
512
+ const t = {
513
+ "!": "%21",
514
+ "'": "%27",
515
+ "(": "%28",
516
+ ")": "%29",
517
+ "~": "%7E",
518
+ "%20": "+",
519
+ "%00": "\0"
520
+ };
521
+ return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g, function(r) {
522
+ return t[r];
523
+ });
524
+ }
525
+ function Be(e, t) {
526
+ this._pairs = [], e && ge(e, this, t);
527
+ }
528
+ const $t = Be.prototype;
529
+ $t.append = function(t, n) {
530
+ this._pairs.push([t, n]);
531
+ };
532
+ $t.toString = function(t) {
533
+ const n = t ? function(r) {
534
+ return t.call(this, r, et);
535
+ } : et;
536
+ return this._pairs.map(function(s) {
537
+ return n(s[0]) + "=" + n(s[1]);
538
+ }, "").join("&");
539
+ };
540
+ function Dr(e) {
541
+ return encodeURIComponent(e).replace(/%3A/gi, ":").replace(/%24/g, "$").replace(/%2C/gi, ",").replace(/%20/g, "+");
542
+ }
543
+ function Bt(e, t, n) {
544
+ if (!t)
545
+ return e;
546
+ const r = n && n.encode || Dr, s = c.isFunction(n) ? {
547
+ serialize: n
548
+ } : n, o = s && s.serialize;
549
+ let i;
550
+ if (o ? i = o(t, s) : i = c.isURLSearchParams(t) ? t.toString() : new Be(t, s).toString(r), i) {
551
+ const a = e.indexOf("#");
552
+ a !== -1 && (e = e.slice(0, a)), e += (e.indexOf("?") === -1 ? "?" : "&") + i;
553
+ }
554
+ return e;
555
+ }
556
+ class tt {
557
+ constructor() {
558
+ this.handlers = [];
559
+ }
560
+ /**
561
+ * Add a new interceptor to the stack
562
+ *
563
+ * @param {Function} fulfilled The function to handle `then` for a `Promise`
564
+ * @param {Function} rejected The function to handle `reject` for a `Promise`
565
+ * @param {Object} options The options for the interceptor, synchronous and runWhen
566
+ *
567
+ * @return {Number} An ID used to remove interceptor later
568
+ */
569
+ use(t, n, r) {
570
+ return this.handlers.push({
571
+ fulfilled: t,
572
+ rejected: n,
573
+ synchronous: r ? r.synchronous : !1,
574
+ runWhen: r ? r.runWhen : null
575
+ }), this.handlers.length - 1;
576
+ }
577
+ /**
578
+ * Remove an interceptor from the stack
579
+ *
580
+ * @param {Number} id The ID that was returned by `use`
581
+ *
582
+ * @returns {void}
583
+ */
584
+ eject(t) {
585
+ this.handlers[t] && (this.handlers[t] = null);
586
+ }
587
+ /**
588
+ * Clear all interceptors from the stack
589
+ *
590
+ * @returns {void}
591
+ */
592
+ clear() {
593
+ this.handlers && (this.handlers = []);
594
+ }
595
+ /**
596
+ * Iterate over all the registered interceptors
597
+ *
598
+ * This method is particularly useful for skipping over any
599
+ * interceptors that may have become `null` calling `eject`.
600
+ *
601
+ * @param {Function} fn The function to call for each interceptor
602
+ *
603
+ * @returns {void}
604
+ */
605
+ forEach(t) {
606
+ c.forEach(this.handlers, function(r) {
607
+ r !== null && t(r);
608
+ });
609
+ }
610
+ }
611
+ const ke = {
612
+ silentJSONParsing: !0,
613
+ forcedJSONParsing: !0,
614
+ clarifyTimeoutError: !1,
615
+ legacyInterceptorReqResOrdering: !0
616
+ }, Lr = typeof URLSearchParams < "u" ? URLSearchParams : Be, xr = typeof FormData < "u" ? FormData : null, Ur = typeof Blob < "u" ? Blob : null, Ir = {
617
+ isBrowser: !0,
618
+ classes: {
619
+ URLSearchParams: Lr,
620
+ FormData: xr,
621
+ Blob: Ur
622
+ },
623
+ protocols: ["http", "https", "file", "blob", "url", "data"]
624
+ }, ve = typeof window < "u" && typeof document < "u", Le = typeof navigator == "object" && navigator || void 0, Fr = ve && (!Le || ["ReactNative", "NativeScript", "NS"].indexOf(Le.product) < 0), jr = typeof WorkerGlobalScope < "u" && // eslint-disable-next-line no-undef
625
+ self instanceof WorkerGlobalScope && typeof self.importScripts == "function", $r = ve && window.location.href || "http://localhost", Br = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
626
+ __proto__: null,
627
+ hasBrowserEnv: ve,
628
+ hasStandardBrowserEnv: Fr,
629
+ hasStandardBrowserWebWorkerEnv: jr,
630
+ navigator: Le,
631
+ origin: $r
632
+ }, Symbol.toStringTag, { value: "Module" })), S = {
633
+ ...Br,
634
+ ...Ir
635
+ };
636
+ function kr(e, t) {
637
+ return ge(e, new S.classes.URLSearchParams(), {
638
+ visitor: function(n, r, s, o) {
639
+ return S.isNode && c.isBuffer(n) ? (this.append(r, n.toString("base64")), !1) : o.defaultVisitor.apply(this, arguments);
640
+ },
641
+ ...t
642
+ });
643
+ }
644
+ function vr(e) {
645
+ return c.matchAll(/\w+|\[(\w*)]/g, e).map((t) => t[0] === "[]" ? "" : t[1] || t[0]);
646
+ }
647
+ function qr(e) {
648
+ const t = {}, n = Object.keys(e);
649
+ let r;
650
+ const s = n.length;
651
+ let o;
652
+ for (r = 0; r < s; r++)
653
+ o = n[r], t[o] = e[o];
654
+ return t;
655
+ }
656
+ function kt(e) {
657
+ function t(n, r, s, o) {
658
+ let i = n[o++];
659
+ if (i === "__proto__") return !0;
660
+ const a = Number.isFinite(+i), f = o >= n.length;
661
+ return i = !i && c.isArray(s) ? s.length : i, f ? (c.hasOwnProp(s, i) ? s[i] = [s[i], r] : s[i] = r, !a) : ((!s[i] || !c.isObject(s[i])) && (s[i] = []), t(n, r, s[i], o) && c.isArray(s[i]) && (s[i] = qr(s[i])), !a);
662
+ }
663
+ if (c.isFormData(e) && c.isFunction(e.entries)) {
664
+ const n = {};
665
+ return c.forEachEntry(e, (r, s) => {
666
+ t(vr(r), s, n, 0);
667
+ }), n;
668
+ }
669
+ return null;
670
+ }
671
+ function Mr(e, t, n) {
672
+ if (c.isString(e))
673
+ try {
674
+ return (t || JSON.parse)(e), c.trim(e);
675
+ } catch (r) {
676
+ if (r.name !== "SyntaxError")
677
+ throw r;
678
+ }
679
+ return (n || JSON.stringify)(e);
680
+ }
681
+ const ne = {
682
+ transitional: ke,
683
+ adapter: ["xhr", "http", "fetch"],
684
+ transformRequest: [function(t, n) {
685
+ const r = n.getContentType() || "", s = r.indexOf("application/json") > -1, o = c.isObject(t);
686
+ if (o && c.isHTMLForm(t) && (t = new FormData(t)), c.isFormData(t))
687
+ return s ? JSON.stringify(kt(t)) : t;
688
+ if (c.isArrayBuffer(t) || c.isBuffer(t) || c.isStream(t) || c.isFile(t) || c.isBlob(t) || c.isReadableStream(t))
689
+ return t;
690
+ if (c.isArrayBufferView(t))
691
+ return t.buffer;
692
+ if (c.isURLSearchParams(t))
693
+ return n.setContentType("application/x-www-form-urlencoded;charset=utf-8", !1), t.toString();
694
+ let a;
695
+ if (o) {
696
+ if (r.indexOf("application/x-www-form-urlencoded") > -1)
697
+ return kr(t, this.formSerializer).toString();
698
+ if ((a = c.isFileList(t)) || r.indexOf("multipart/form-data") > -1) {
699
+ const f = this.env && this.env.FormData;
700
+ return ge(
701
+ a ? { "files[]": t } : t,
702
+ f && new f(),
703
+ this.formSerializer
704
+ );
705
+ }
706
+ }
707
+ return o || s ? (n.setContentType("application/json", !1), Mr(t)) : t;
708
+ }],
709
+ transformResponse: [function(t) {
710
+ const n = this.transitional || ne.transitional, r = n && n.forcedJSONParsing, s = this.responseType === "json";
711
+ if (c.isResponse(t) || c.isReadableStream(t))
712
+ return t;
713
+ if (t && c.isString(t) && (r && !this.responseType || s)) {
714
+ const i = !(n && n.silentJSONParsing) && s;
715
+ try {
716
+ return JSON.parse(t, this.parseReviver);
717
+ } catch (a) {
718
+ if (i)
719
+ throw a.name === "SyntaxError" ? E.from(a, E.ERR_BAD_RESPONSE, this, null, this.response) : a;
720
+ }
721
+ }
722
+ return t;
723
+ }],
724
+ /**
725
+ * A timeout in milliseconds to abort a request. If set to 0 (default) a
726
+ * timeout is not created.
727
+ */
728
+ timeout: 0,
729
+ xsrfCookieName: "XSRF-TOKEN",
730
+ xsrfHeaderName: "X-XSRF-TOKEN",
731
+ maxContentLength: -1,
732
+ maxBodyLength: -1,
733
+ env: {
734
+ FormData: S.classes.FormData,
735
+ Blob: S.classes.Blob
736
+ },
737
+ validateStatus: function(t) {
738
+ return t >= 200 && t < 300;
739
+ },
740
+ headers: {
741
+ common: {
742
+ Accept: "application/json, text/plain, */*",
743
+ "Content-Type": void 0
744
+ }
745
+ }
746
+ };
747
+ c.forEach(["delete", "get", "head", "post", "put", "patch"], (e) => {
748
+ ne.headers[e] = {};
749
+ });
750
+ const Hr = c.toObjectSet([
751
+ "age",
752
+ "authorization",
753
+ "content-length",
754
+ "content-type",
755
+ "etag",
756
+ "expires",
757
+ "from",
758
+ "host",
759
+ "if-modified-since",
760
+ "if-unmodified-since",
761
+ "last-modified",
762
+ "location",
763
+ "max-forwards",
764
+ "proxy-authorization",
765
+ "referer",
766
+ "retry-after",
767
+ "user-agent"
768
+ ]), zr = (e) => {
769
+ const t = {};
770
+ let n, r, s;
771
+ return e && e.split(`
772
+ `).forEach(function(i) {
773
+ s = i.indexOf(":"), n = i.substring(0, s).trim().toLowerCase(), r = i.substring(s + 1).trim(), !(!n || t[n] && Hr[n]) && (n === "set-cookie" ? t[n] ? t[n].push(r) : t[n] = [r] : t[n] = t[n] ? t[n] + ", " + r : r);
774
+ }), t;
775
+ }, nt = Symbol("internals");
776
+ function X(e) {
777
+ return e && String(e).trim().toLowerCase();
778
+ }
779
+ function ue(e) {
780
+ return e === !1 || e == null ? e : c.isArray(e) ? e.map(ue) : String(e);
781
+ }
782
+ function Jr(e) {
783
+ const t = /* @__PURE__ */ Object.create(null), n = /([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;
784
+ let r;
785
+ for (; r = n.exec(e); )
786
+ t[r[1]] = r[2];
787
+ return t;
788
+ }
789
+ const Vr = (e) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());
790
+ function we(e, t, n, r, s) {
791
+ if (c.isFunction(r))
792
+ return r.call(this, t, n);
793
+ if (s && (t = n), !!c.isString(t)) {
794
+ if (c.isString(r))
795
+ return t.indexOf(r) !== -1;
796
+ if (c.isRegExp(r))
797
+ return r.test(t);
798
+ }
799
+ }
800
+ function Kr(e) {
801
+ return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (t, n, r) => n.toUpperCase() + r);
802
+ }
803
+ function Xr(e, t) {
804
+ const n = c.toCamelCase(" " + t);
805
+ ["get", "set", "has"].forEach((r) => {
806
+ Object.defineProperty(e, r + n, {
807
+ value: function(s, o, i) {
808
+ return this[r].call(this, t, s, o, i);
809
+ },
810
+ configurable: !0
811
+ });
812
+ });
813
+ }
814
+ let P = class {
815
+ constructor(t) {
816
+ t && this.set(t);
817
+ }
818
+ set(t, n, r) {
819
+ const s = this;
820
+ function o(a, f, d) {
821
+ const u = X(f);
822
+ if (!u)
823
+ throw new Error("header name must be a non-empty string");
824
+ const h = c.findKey(s, u);
825
+ (!h || s[h] === void 0 || d === !0 || d === void 0 && s[h] !== !1) && (s[h || f] = ue(a));
826
+ }
827
+ const i = (a, f) => c.forEach(a, (d, u) => o(d, u, f));
828
+ if (c.isPlainObject(t) || t instanceof this.constructor)
829
+ i(t, n);
830
+ else if (c.isString(t) && (t = t.trim()) && !Vr(t))
831
+ i(zr(t), n);
832
+ else if (c.isObject(t) && c.isIterable(t)) {
833
+ let a = {}, f, d;
834
+ for (const u of t) {
835
+ if (!c.isArray(u))
836
+ throw TypeError("Object iterator must return a key-value pair");
837
+ a[d = u[0]] = (f = a[d]) ? c.isArray(f) ? [...f, u[1]] : [f, u[1]] : u[1];
838
+ }
839
+ i(a, n);
840
+ } else
841
+ t != null && o(n, t, r);
842
+ return this;
843
+ }
844
+ get(t, n) {
845
+ if (t = X(t), t) {
846
+ const r = c.findKey(this, t);
847
+ if (r) {
848
+ const s = this[r];
849
+ if (!n)
850
+ return s;
851
+ if (n === !0)
852
+ return Jr(s);
853
+ if (c.isFunction(n))
854
+ return n.call(this, s, r);
855
+ if (c.isRegExp(n))
856
+ return n.exec(s);
857
+ throw new TypeError("parser must be boolean|regexp|function");
858
+ }
859
+ }
860
+ }
861
+ has(t, n) {
862
+ if (t = X(t), t) {
863
+ const r = c.findKey(this, t);
864
+ return !!(r && this[r] !== void 0 && (!n || we(this, this[r], r, n)));
865
+ }
866
+ return !1;
867
+ }
868
+ delete(t, n) {
869
+ const r = this;
870
+ let s = !1;
871
+ function o(i) {
872
+ if (i = X(i), i) {
873
+ const a = c.findKey(r, i);
874
+ a && (!n || we(r, r[a], a, n)) && (delete r[a], s = !0);
875
+ }
876
+ }
877
+ return c.isArray(t) ? t.forEach(o) : o(t), s;
878
+ }
879
+ clear(t) {
880
+ const n = Object.keys(this);
881
+ let r = n.length, s = !1;
882
+ for (; r--; ) {
883
+ const o = n[r];
884
+ (!t || we(this, this[o], o, t, !0)) && (delete this[o], s = !0);
885
+ }
886
+ return s;
887
+ }
888
+ normalize(t) {
889
+ const n = this, r = {};
890
+ return c.forEach(this, (s, o) => {
891
+ const i = c.findKey(r, o);
892
+ if (i) {
893
+ n[i] = ue(s), delete n[o];
894
+ return;
895
+ }
896
+ const a = t ? Kr(o) : String(o).trim();
897
+ a !== o && delete n[o], n[a] = ue(s), r[a] = !0;
898
+ }), this;
899
+ }
900
+ concat(...t) {
901
+ return this.constructor.concat(this, ...t);
902
+ }
903
+ toJSON(t) {
904
+ const n = /* @__PURE__ */ Object.create(null);
905
+ return c.forEach(this, (r, s) => {
906
+ r != null && r !== !1 && (n[s] = t && c.isArray(r) ? r.join(", ") : r);
907
+ }), n;
908
+ }
909
+ [Symbol.iterator]() {
910
+ return Object.entries(this.toJSON())[Symbol.iterator]();
911
+ }
912
+ toString() {
913
+ return Object.entries(this.toJSON()).map(([t, n]) => t + ": " + n).join(`
914
+ `);
915
+ }
916
+ getSetCookie() {
917
+ return this.get("set-cookie") || [];
918
+ }
919
+ get [Symbol.toStringTag]() {
920
+ return "AxiosHeaders";
921
+ }
922
+ static from(t) {
923
+ return t instanceof this ? t : new this(t);
924
+ }
925
+ static concat(t, ...n) {
926
+ const r = new this(t);
927
+ return n.forEach((s) => r.set(s)), r;
928
+ }
929
+ static accessor(t) {
930
+ const r = (this[nt] = this[nt] = {
931
+ accessors: {}
932
+ }).accessors, s = this.prototype;
933
+ function o(i) {
934
+ const a = X(i);
935
+ r[a] || (Xr(s, i), r[a] = !0);
936
+ }
937
+ return c.isArray(t) ? t.forEach(o) : o(t), this;
938
+ }
939
+ };
940
+ P.accessor(["Content-Type", "Content-Length", "Accept", "Accept-Encoding", "User-Agent", "Authorization"]);
941
+ c.reduceDescriptors(P.prototype, ({ value: e }, t) => {
942
+ let n = t[0].toUpperCase() + t.slice(1);
943
+ return {
944
+ get: () => e,
945
+ set(r) {
946
+ this[n] = r;
947
+ }
948
+ };
949
+ });
950
+ c.freezeMethods(P);
951
+ function Te(e, t) {
952
+ const n = this || ne, r = t || n, s = P.from(r.headers);
953
+ let o = r.data;
954
+ return c.forEach(e, function(a) {
955
+ o = a.call(n, o, s.normalize(), t ? t.status : void 0);
956
+ }), s.normalize(), o;
957
+ }
958
+ function vt(e) {
959
+ return !!(e && e.__CANCEL__);
960
+ }
961
+ let re = class extends E {
962
+ /**
963
+ * A `CanceledError` is an object that is thrown when an operation is canceled.
964
+ *
965
+ * @param {string=} message The message.
966
+ * @param {Object=} config The config.
967
+ * @param {Object=} request The request.
968
+ *
969
+ * @returns {CanceledError} The created error.
970
+ */
971
+ constructor(t, n, r) {
972
+ super(t ?? "canceled", E.ERR_CANCELED, n, r), this.name = "CanceledError", this.__CANCEL__ = !0;
973
+ }
974
+ };
975
+ function qt(e, t, n) {
976
+ const r = n.config.validateStatus;
977
+ !n.status || !r || r(n.status) ? e(n) : t(new E(
978
+ "Request failed with status code " + n.status,
979
+ [E.ERR_BAD_REQUEST, E.ERR_BAD_RESPONSE][Math.floor(n.status / 100) - 4],
980
+ n.config,
981
+ n.request,
982
+ n
983
+ ));
984
+ }
985
+ function Wr(e) {
986
+ const t = /^([-+\w]{1,25})(:?\/\/|:)/.exec(e);
987
+ return t && t[1] || "";
988
+ }
989
+ function Gr(e, t) {
990
+ e = e || 10;
991
+ const n = new Array(e), r = new Array(e);
992
+ let s = 0, o = 0, i;
993
+ return t = t !== void 0 ? t : 1e3, function(f) {
994
+ const d = Date.now(), u = r[o];
995
+ i || (i = d), n[s] = f, r[s] = d;
996
+ let h = o, y = 0;
997
+ for (; h !== s; )
998
+ y += n[h++], h = h % e;
999
+ if (s = (s + 1) % e, s === o && (o = (o + 1) % e), d - i < t)
1000
+ return;
1001
+ const g = u && d - u;
1002
+ return g ? Math.round(y * 1e3 / g) : void 0;
1003
+ };
1004
+ }
1005
+ function Yr(e, t) {
1006
+ let n = 0, r = 1e3 / t, s, o;
1007
+ const i = (d, u = Date.now()) => {
1008
+ n = u, s = null, o && (clearTimeout(o), o = null), e(...d);
1009
+ };
1010
+ return [(...d) => {
1011
+ const u = Date.now(), h = u - n;
1012
+ h >= r ? i(d, u) : (s = d, o || (o = setTimeout(() => {
1013
+ o = null, i(s);
1014
+ }, r - h)));
1015
+ }, () => s && i(s)];
1016
+ }
1017
+ const fe = (e, t, n = 3) => {
1018
+ let r = 0;
1019
+ const s = Gr(50, 250);
1020
+ return Yr((o) => {
1021
+ const i = o.loaded, a = o.lengthComputable ? o.total : void 0, f = i - r, d = s(f), u = i <= a;
1022
+ r = i;
1023
+ const h = {
1024
+ loaded: i,
1025
+ total: a,
1026
+ progress: a ? i / a : void 0,
1027
+ bytes: f,
1028
+ rate: d || void 0,
1029
+ estimated: d && a && u ? (a - i) / d : void 0,
1030
+ event: o,
1031
+ lengthComputable: a != null,
1032
+ [t ? "download" : "upload"]: !0
1033
+ };
1034
+ e(h);
1035
+ }, n);
1036
+ }, rt = (e, t) => {
1037
+ const n = e != null;
1038
+ return [(r) => t[0]({
1039
+ lengthComputable: n,
1040
+ total: e,
1041
+ loaded: r
1042
+ }), t[1]];
1043
+ }, st = (e) => (...t) => c.asap(() => e(...t)), Qr = S.hasStandardBrowserEnv ? /* @__PURE__ */ ((e, t) => (n) => (n = new URL(n, S.origin), e.protocol === n.protocol && e.host === n.host && (t || e.port === n.port)))(
1044
+ new URL(S.origin),
1045
+ S.navigator && /(msie|trident)/i.test(S.navigator.userAgent)
1046
+ ) : () => !0, Zr = S.hasStandardBrowserEnv ? (
1047
+ // Standard browser envs support document.cookie
1048
+ {
1049
+ write(e, t, n, r, s, o, i) {
1050
+ if (typeof document > "u") return;
1051
+ const a = [`${e}=${encodeURIComponent(t)}`];
1052
+ c.isNumber(n) && a.push(`expires=${new Date(n).toUTCString()}`), c.isString(r) && a.push(`path=${r}`), c.isString(s) && a.push(`domain=${s}`), o === !0 && a.push("secure"), c.isString(i) && a.push(`SameSite=${i}`), document.cookie = a.join("; ");
1053
+ },
1054
+ read(e) {
1055
+ if (typeof document > "u") return null;
1056
+ const t = document.cookie.match(new RegExp("(?:^|; )" + e + "=([^;]*)"));
1057
+ return t ? decodeURIComponent(t[1]) : null;
1058
+ },
1059
+ remove(e) {
1060
+ this.write(e, "", Date.now() - 864e5, "/");
1061
+ }
1062
+ }
1063
+ ) : (
1064
+ // Non-standard browser env (web workers, react-native) lack needed support.
1065
+ {
1066
+ write() {
1067
+ },
1068
+ read() {
1069
+ return null;
1070
+ },
1071
+ remove() {
1072
+ }
1073
+ }
1074
+ );
1075
+ function es(e) {
1076
+ return typeof e != "string" ? !1 : /^([a-z][a-z\d+\-.]*:)?\/\//i.test(e);
1077
+ }
1078
+ function ts(e, t) {
1079
+ return t ? e.replace(/\/?\/$/, "") + "/" + t.replace(/^\/+/, "") : e;
1080
+ }
1081
+ function Mt(e, t, n) {
1082
+ let r = !es(t);
1083
+ return e && (r || n == !1) ? ts(e, t) : t;
1084
+ }
1085
+ const ot = (e) => e instanceof P ? { ...e } : e;
1086
+ function M(e, t) {
1087
+ t = t || {};
1088
+ const n = {};
1089
+ function r(d, u, h, y) {
1090
+ return c.isPlainObject(d) && c.isPlainObject(u) ? c.merge.call({ caseless: y }, d, u) : c.isPlainObject(u) ? c.merge({}, u) : c.isArray(u) ? u.slice() : u;
1091
+ }
1092
+ function s(d, u, h, y) {
1093
+ if (c.isUndefined(u)) {
1094
+ if (!c.isUndefined(d))
1095
+ return r(void 0, d, h, y);
1096
+ } else return r(d, u, h, y);
1097
+ }
1098
+ function o(d, u) {
1099
+ if (!c.isUndefined(u))
1100
+ return r(void 0, u);
1101
+ }
1102
+ function i(d, u) {
1103
+ if (c.isUndefined(u)) {
1104
+ if (!c.isUndefined(d))
1105
+ return r(void 0, d);
1106
+ } else return r(void 0, u);
1107
+ }
1108
+ function a(d, u, h) {
1109
+ if (h in t)
1110
+ return r(d, u);
1111
+ if (h in e)
1112
+ return r(void 0, d);
1113
+ }
1114
+ const f = {
1115
+ url: o,
1116
+ method: o,
1117
+ data: o,
1118
+ baseURL: i,
1119
+ transformRequest: i,
1120
+ transformResponse: i,
1121
+ paramsSerializer: i,
1122
+ timeout: i,
1123
+ timeoutMessage: i,
1124
+ withCredentials: i,
1125
+ withXSRFToken: i,
1126
+ adapter: i,
1127
+ responseType: i,
1128
+ xsrfCookieName: i,
1129
+ xsrfHeaderName: i,
1130
+ onUploadProgress: i,
1131
+ onDownloadProgress: i,
1132
+ decompress: i,
1133
+ maxContentLength: i,
1134
+ maxBodyLength: i,
1135
+ beforeRedirect: i,
1136
+ transport: i,
1137
+ httpAgent: i,
1138
+ httpsAgent: i,
1139
+ cancelToken: i,
1140
+ socketPath: i,
1141
+ responseEncoding: i,
1142
+ validateStatus: a,
1143
+ headers: (d, u, h) => s(ot(d), ot(u), h, !0)
1144
+ };
1145
+ return c.forEach(
1146
+ Object.keys({ ...e, ...t }),
1147
+ function(u) {
1148
+ if (u === "__proto__" || u === "constructor" || u === "prototype")
1149
+ return;
1150
+ const h = c.hasOwnProp(f, u) ? f[u] : s, y = h(e[u], t[u], u);
1151
+ c.isUndefined(y) && h !== a || (n[u] = y);
1152
+ }
1153
+ ), n;
1154
+ }
1155
+ const Ht = (e) => {
1156
+ const t = M({}, e);
1157
+ let { data: n, withXSRFToken: r, xsrfHeaderName: s, xsrfCookieName: o, headers: i, auth: a } = t;
1158
+ if (t.headers = i = P.from(i), t.url = Bt(Mt(t.baseURL, t.url, t.allowAbsoluteUrls), e.params, e.paramsSerializer), a && i.set(
1159
+ "Authorization",
1160
+ "Basic " + btoa((a.username || "") + ":" + (a.password ? unescape(encodeURIComponent(a.password)) : ""))
1161
+ ), c.isFormData(n)) {
1162
+ if (S.hasStandardBrowserEnv || S.hasStandardBrowserWebWorkerEnv)
1163
+ i.setContentType(void 0);
1164
+ else if (c.isFunction(n.getHeaders)) {
1165
+ const f = n.getHeaders(), d = ["content-type", "content-length"];
1166
+ Object.entries(f).forEach(([u, h]) => {
1167
+ d.includes(u.toLowerCase()) && i.set(u, h);
1168
+ });
1169
+ }
1170
+ }
1171
+ if (S.hasStandardBrowserEnv && (r && c.isFunction(r) && (r = r(t)), r || r !== !1 && Qr(t.url))) {
1172
+ const f = s && o && Zr.read(o);
1173
+ f && i.set(s, f);
1174
+ }
1175
+ return t;
1176
+ }, ns = typeof XMLHttpRequest < "u", rs = ns && function(e) {
1177
+ return new Promise(function(n, r) {
1178
+ const s = Ht(e);
1179
+ let o = s.data;
1180
+ const i = P.from(s.headers).normalize();
1181
+ let { responseType: a, onUploadProgress: f, onDownloadProgress: d } = s, u, h, y, g, l;
1182
+ function m() {
1183
+ g && g(), l && l(), s.cancelToken && s.cancelToken.unsubscribe(u), s.signal && s.signal.removeEventListener("abort", u);
1184
+ }
1185
+ let p = new XMLHttpRequest();
1186
+ p.open(s.method.toUpperCase(), s.url, !0), p.timeout = s.timeout;
1187
+ function R() {
1188
+ if (!p)
1189
+ return;
1190
+ const _ = P.from(
1191
+ "getAllResponseHeaders" in p && p.getAllResponseHeaders()
1192
+ ), x = {
1193
+ data: !a || a === "text" || a === "json" ? p.responseText : p.response,
1194
+ status: p.status,
1195
+ statusText: p.statusText,
1196
+ headers: _,
1197
+ config: e,
1198
+ request: p
1199
+ };
1200
+ qt(function(D) {
1201
+ n(D), m();
1202
+ }, function(D) {
1203
+ r(D), m();
1204
+ }, x), p = null;
1205
+ }
1206
+ "onloadend" in p ? p.onloadend = R : p.onreadystatechange = function() {
1207
+ !p || p.readyState !== 4 || p.status === 0 && !(p.responseURL && p.responseURL.indexOf("file:") === 0) || setTimeout(R);
1208
+ }, p.onabort = function() {
1209
+ p && (r(new E("Request aborted", E.ECONNABORTED, e, p)), p = null);
1210
+ }, p.onerror = function(A) {
1211
+ const x = A && A.message ? A.message : "Network Error", B = new E(x, E.ERR_NETWORK, e, p);
1212
+ B.event = A || null, r(B), p = null;
1213
+ }, p.ontimeout = function() {
1214
+ let A = s.timeout ? "timeout of " + s.timeout + "ms exceeded" : "timeout exceeded";
1215
+ const x = s.transitional || ke;
1216
+ s.timeoutErrorMessage && (A = s.timeoutErrorMessage), r(new E(
1217
+ A,
1218
+ x.clarifyTimeoutError ? E.ETIMEDOUT : E.ECONNABORTED,
1219
+ e,
1220
+ p
1221
+ )), p = null;
1222
+ }, o === void 0 && i.setContentType(null), "setRequestHeader" in p && c.forEach(i.toJSON(), function(A, x) {
1223
+ p.setRequestHeader(x, A);
1224
+ }), c.isUndefined(s.withCredentials) || (p.withCredentials = !!s.withCredentials), a && a !== "json" && (p.responseType = s.responseType), d && ([y, l] = fe(d, !0), p.addEventListener("progress", y)), f && p.upload && ([h, g] = fe(f), p.upload.addEventListener("progress", h), p.upload.addEventListener("loadend", g)), (s.cancelToken || s.signal) && (u = (_) => {
1225
+ p && (r(!_ || _.type ? new re(null, e, p) : _), p.abort(), p = null);
1226
+ }, s.cancelToken && s.cancelToken.subscribe(u), s.signal && (s.signal.aborted ? u() : s.signal.addEventListener("abort", u)));
1227
+ const T = Wr(s.url);
1228
+ if (T && S.protocols.indexOf(T) === -1) {
1229
+ r(new E("Unsupported protocol " + T + ":", E.ERR_BAD_REQUEST, e));
1230
+ return;
1231
+ }
1232
+ p.send(o || null);
1233
+ });
1234
+ }, ss = (e, t) => {
1235
+ const { length: n } = e = e ? e.filter(Boolean) : [];
1236
+ if (t || n) {
1237
+ let r = new AbortController(), s;
1238
+ const o = function(d) {
1239
+ if (!s) {
1240
+ s = !0, a();
1241
+ const u = d instanceof Error ? d : this.reason;
1242
+ r.abort(u instanceof E ? u : new re(u instanceof Error ? u.message : u));
1243
+ }
1244
+ };
1245
+ let i = t && setTimeout(() => {
1246
+ i = null, o(new E(`timeout of ${t}ms exceeded`, E.ETIMEDOUT));
1247
+ }, t);
1248
+ const a = () => {
1249
+ e && (i && clearTimeout(i), i = null, e.forEach((d) => {
1250
+ d.unsubscribe ? d.unsubscribe(o) : d.removeEventListener("abort", o);
1251
+ }), e = null);
1252
+ };
1253
+ e.forEach((d) => d.addEventListener("abort", o));
1254
+ const { signal: f } = r;
1255
+ return f.unsubscribe = () => c.asap(a), f;
1256
+ }
1257
+ }, os = function* (e, t) {
1258
+ let n = e.byteLength;
1259
+ if (n < t) {
1260
+ yield e;
1261
+ return;
1262
+ }
1263
+ let r = 0, s;
1264
+ for (; r < n; )
1265
+ s = r + t, yield e.slice(r, s), r = s;
1266
+ }, is = async function* (e, t) {
1267
+ for await (const n of as(e))
1268
+ yield* os(n, t);
1269
+ }, as = async function* (e) {
1270
+ if (e[Symbol.asyncIterator]) {
1271
+ yield* e;
1272
+ return;
1273
+ }
1274
+ const t = e.getReader();
1275
+ try {
1276
+ for (; ; ) {
1277
+ const { done: n, value: r } = await t.read();
1278
+ if (n)
1279
+ break;
1280
+ yield r;
1281
+ }
1282
+ } finally {
1283
+ await t.cancel();
1284
+ }
1285
+ }, it = (e, t, n, r) => {
1286
+ const s = is(e, t);
1287
+ let o = 0, i, a = (f) => {
1288
+ i || (i = !0, r && r(f));
1289
+ };
1290
+ return new ReadableStream({
1291
+ async pull(f) {
1292
+ try {
1293
+ const { done: d, value: u } = await s.next();
1294
+ if (d) {
1295
+ a(), f.close();
1296
+ return;
1297
+ }
1298
+ let h = u.byteLength;
1299
+ if (n) {
1300
+ let y = o += h;
1301
+ n(y);
1302
+ }
1303
+ f.enqueue(new Uint8Array(u));
1304
+ } catch (d) {
1305
+ throw a(d), d;
1306
+ }
1307
+ },
1308
+ cancel(f) {
1309
+ return a(f), s.return();
1310
+ }
1311
+ }, {
1312
+ highWaterMark: 2
1313
+ });
1314
+ }, at = 64 * 1024, { isFunction: ae } = c, cs = (({ Request: e, Response: t }) => ({
1315
+ Request: e,
1316
+ Response: t
1317
+ }))(c.global), {
1318
+ ReadableStream: ct,
1319
+ TextEncoder: ut
1320
+ } = c.global, lt = (e, ...t) => {
1321
+ try {
1322
+ return !!e(...t);
1323
+ } catch {
1324
+ return !1;
1325
+ }
1326
+ }, us = (e) => {
1327
+ e = c.merge.call({
1328
+ skipUndefined: !0
1329
+ }, cs, e);
1330
+ const { fetch: t, Request: n, Response: r } = e, s = t ? ae(t) : typeof fetch == "function", o = ae(n), i = ae(r);
1331
+ if (!s)
1332
+ return !1;
1333
+ const a = s && ae(ct), f = s && (typeof ut == "function" ? /* @__PURE__ */ ((l) => (m) => l.encode(m))(new ut()) : async (l) => new Uint8Array(await new n(l).arrayBuffer())), d = o && a && lt(() => {
1334
+ let l = !1;
1335
+ const m = new n(S.origin, {
1336
+ body: new ct(),
1337
+ method: "POST",
1338
+ get duplex() {
1339
+ return l = !0, "half";
1340
+ }
1341
+ }).headers.has("Content-Type");
1342
+ return l && !m;
1343
+ }), u = i && a && lt(() => c.isReadableStream(new r("").body)), h = {
1344
+ stream: u && ((l) => l.body)
1345
+ };
1346
+ s && ["text", "arrayBuffer", "blob", "formData", "stream"].forEach((l) => {
1347
+ !h[l] && (h[l] = (m, p) => {
1348
+ let R = m && m[l];
1349
+ if (R)
1350
+ return R.call(m);
1351
+ throw new E(`Response type '${l}' is not supported`, E.ERR_NOT_SUPPORT, p);
1352
+ });
1353
+ });
1354
+ const y = async (l) => {
1355
+ if (l == null)
1356
+ return 0;
1357
+ if (c.isBlob(l))
1358
+ return l.size;
1359
+ if (c.isSpecCompliantForm(l))
1360
+ return (await new n(S.origin, {
1361
+ method: "POST",
1362
+ body: l
1363
+ }).arrayBuffer()).byteLength;
1364
+ if (c.isArrayBufferView(l) || c.isArrayBuffer(l))
1365
+ return l.byteLength;
1366
+ if (c.isURLSearchParams(l) && (l = l + ""), c.isString(l))
1367
+ return (await f(l)).byteLength;
1368
+ }, g = async (l, m) => {
1369
+ const p = c.toFiniteNumber(l.getContentLength());
1370
+ return p ?? y(m);
1371
+ };
1372
+ return async (l) => {
1373
+ let {
1374
+ url: m,
1375
+ method: p,
1376
+ data: R,
1377
+ signal: T,
1378
+ cancelToken: _,
1379
+ timeout: A,
1380
+ onDownloadProgress: x,
1381
+ onUploadProgress: B,
1382
+ responseType: D,
1383
+ headers: _e,
1384
+ withCredentials: se = "same-origin",
1385
+ fetchOptions: Je
1386
+ } = Ht(l), Ve = t || fetch;
1387
+ D = D ? (D + "").toLowerCase() : "text";
1388
+ let oe = ss([T, _ && _.toAbortSignal()], A), K = null;
1389
+ const k = oe && oe.unsubscribe && (() => {
1390
+ oe.unsubscribe();
1391
+ });
1392
+ let Ke;
1393
+ try {
1394
+ if (B && d && p !== "get" && p !== "head" && (Ke = await g(_e, R)) !== 0) {
1395
+ let j = new n(m, {
1396
+ method: "POST",
1397
+ body: R,
1398
+ duplex: "half"
1399
+ }), z;
1400
+ if (c.isFormData(R) && (z = j.headers.get("content-type")) && _e.setContentType(z), j.body) {
1401
+ const [Oe, ie] = rt(
1402
+ Ke,
1403
+ fe(st(B))
1404
+ );
1405
+ R = it(j.body, at, Oe, ie);
1406
+ }
1407
+ }
1408
+ c.isString(se) || (se = se ? "include" : "omit");
1409
+ const C = o && "credentials" in n.prototype, Xe = {
1410
+ ...Je,
1411
+ signal: oe,
1412
+ method: p.toUpperCase(),
1413
+ headers: _e.normalize().toJSON(),
1414
+ body: R,
1415
+ duplex: "half",
1416
+ credentials: C ? se : void 0
1417
+ };
1418
+ K = o && new n(m, Xe);
1419
+ let F = await (o ? Ve(K, Je) : Ve(m, Xe));
1420
+ const We = u && (D === "stream" || D === "response");
1421
+ if (u && (x || We && k)) {
1422
+ const j = {};
1423
+ ["status", "statusText", "headers"].forEach((Ge) => {
1424
+ j[Ge] = F[Ge];
1425
+ });
1426
+ const z = c.toFiniteNumber(F.headers.get("content-length")), [Oe, ie] = x && rt(
1427
+ z,
1428
+ fe(st(x), !0)
1429
+ ) || [];
1430
+ F = new r(
1431
+ it(F.body, at, Oe, () => {
1432
+ ie && ie(), k && k();
1433
+ }),
1434
+ j
1435
+ );
1436
+ }
1437
+ D = D || "text";
1438
+ let sn = await h[c.findKey(h, D) || "text"](F, l);
1439
+ return !We && k && k(), await new Promise((j, z) => {
1440
+ qt(j, z, {
1441
+ data: sn,
1442
+ headers: P.from(F.headers),
1443
+ status: F.status,
1444
+ statusText: F.statusText,
1445
+ config: l,
1446
+ request: K
1447
+ });
1448
+ });
1449
+ } catch (C) {
1450
+ throw k && k(), C && C.name === "TypeError" && /Load failed|fetch/i.test(C.message) ? Object.assign(
1451
+ new E("Network Error", E.ERR_NETWORK, l, K, C && C.response),
1452
+ {
1453
+ cause: C.cause || C
1454
+ }
1455
+ ) : E.from(C, C && C.code, l, K, C && C.response);
1456
+ }
1457
+ };
1458
+ }, ls = /* @__PURE__ */ new Map(), zt = (e) => {
1459
+ let t = e && e.env || {};
1460
+ const { fetch: n, Request: r, Response: s } = t, o = [
1461
+ r,
1462
+ s,
1463
+ n
1464
+ ];
1465
+ let i = o.length, a = i, f, d, u = ls;
1466
+ for (; a--; )
1467
+ f = o[a], d = u.get(f), d === void 0 && u.set(f, d = a ? /* @__PURE__ */ new Map() : us(t)), u = d;
1468
+ return d;
1469
+ };
1470
+ zt();
1471
+ const qe = {
1472
+ http: Cr,
1473
+ xhr: rs,
1474
+ fetch: {
1475
+ get: zt
1476
+ }
1477
+ };
1478
+ c.forEach(qe, (e, t) => {
1479
+ if (e) {
1480
+ try {
1481
+ Object.defineProperty(e, "name", { value: t });
1482
+ } catch {
1483
+ }
1484
+ Object.defineProperty(e, "adapterName", { value: t });
1485
+ }
1486
+ });
1487
+ const ft = (e) => `- ${e}`, fs = (e) => c.isFunction(e) || e === null || e === !1;
1488
+ function ds(e, t) {
1489
+ e = c.isArray(e) ? e : [e];
1490
+ const { length: n } = e;
1491
+ let r, s;
1492
+ const o = {};
1493
+ for (let i = 0; i < n; i++) {
1494
+ r = e[i];
1495
+ let a;
1496
+ if (s = r, !fs(r) && (s = qe[(a = String(r)).toLowerCase()], s === void 0))
1497
+ throw new E(`Unknown adapter '${a}'`);
1498
+ if (s && (c.isFunction(s) || (s = s.get(t))))
1499
+ break;
1500
+ o[a || "#" + i] = s;
1501
+ }
1502
+ if (!s) {
1503
+ const i = Object.entries(o).map(
1504
+ ([f, d]) => `adapter ${f} ` + (d === !1 ? "is not supported by the environment" : "is not available in the build")
1505
+ );
1506
+ let a = n ? i.length > 1 ? `since :
1507
+ ` + i.map(ft).join(`
1508
+ `) : " " + ft(i[0]) : "as no adapter specified";
1509
+ throw new E(
1510
+ "There is no suitable adapter to dispatch the request " + a,
1511
+ "ERR_NOT_SUPPORT"
1512
+ );
1513
+ }
1514
+ return s;
1515
+ }
1516
+ const Jt = {
1517
+ /**
1518
+ * Resolve an adapter from a list of adapter names or functions.
1519
+ * @type {Function}
1520
+ */
1521
+ getAdapter: ds,
1522
+ /**
1523
+ * Exposes all known adapters
1524
+ * @type {Object<string, Function|Object>}
1525
+ */
1526
+ adapters: qe
1527
+ };
1528
+ function Ae(e) {
1529
+ if (e.cancelToken && e.cancelToken.throwIfRequested(), e.signal && e.signal.aborted)
1530
+ throw new re(null, e);
1531
+ }
1532
+ function dt(e) {
1533
+ return Ae(e), e.headers = P.from(e.headers), e.data = Te.call(
1534
+ e,
1535
+ e.transformRequest
1536
+ ), ["post", "put", "patch"].indexOf(e.method) !== -1 && e.headers.setContentType("application/x-www-form-urlencoded", !1), Jt.getAdapter(e.adapter || ne.adapter, e)(e).then(function(r) {
1537
+ return Ae(e), r.data = Te.call(
1538
+ e,
1539
+ e.transformResponse,
1540
+ r
1541
+ ), r.headers = P.from(r.headers), r;
1542
+ }, function(r) {
1543
+ return vt(r) || (Ae(e), r && r.response && (r.response.data = Te.call(
1544
+ e,
1545
+ e.transformResponse,
1546
+ r.response
1547
+ ), r.response.headers = P.from(r.response.headers))), Promise.reject(r);
1548
+ });
1549
+ }
1550
+ const Vt = "1.13.5", Re = {};
1551
+ ["object", "boolean", "number", "function", "string", "symbol"].forEach((e, t) => {
1552
+ Re[e] = function(r) {
1553
+ return typeof r === e || "a" + (t < 1 ? "n " : " ") + e;
1554
+ };
1555
+ });
1556
+ const pt = {};
1557
+ Re.transitional = function(t, n, r) {
1558
+ function s(o, i) {
1559
+ return "[Axios v" + Vt + "] Transitional option '" + o + "'" + i + (r ? ". " + r : "");
1560
+ }
1561
+ return (o, i, a) => {
1562
+ if (t === !1)
1563
+ throw new E(
1564
+ s(i, " has been removed" + (n ? " in " + n : "")),
1565
+ E.ERR_DEPRECATED
1566
+ );
1567
+ return n && !pt[i] && (pt[i] = !0, console.warn(
1568
+ s(
1569
+ i,
1570
+ " has been deprecated since v" + n + " and will be removed in the near future"
1571
+ )
1572
+ )), t ? t(o, i, a) : !0;
1573
+ };
1574
+ };
1575
+ Re.spelling = function(t) {
1576
+ return (n, r) => (console.warn(`${r} is likely a misspelling of ${t}`), !0);
1577
+ };
1578
+ function ps(e, t, n) {
1579
+ if (typeof e != "object")
1580
+ throw new E("options must be an object", E.ERR_BAD_OPTION_VALUE);
1581
+ const r = Object.keys(e);
1582
+ let s = r.length;
1583
+ for (; s-- > 0; ) {
1584
+ const o = r[s], i = t[o];
1585
+ if (i) {
1586
+ const a = e[o], f = a === void 0 || i(a, o, e);
1587
+ if (f !== !0)
1588
+ throw new E("option " + o + " must be " + f, E.ERR_BAD_OPTION_VALUE);
1589
+ continue;
1590
+ }
1591
+ if (n !== !0)
1592
+ throw new E("Unknown option " + o, E.ERR_BAD_OPTION);
1593
+ }
1594
+ }
1595
+ const le = {
1596
+ assertOptions: ps,
1597
+ validators: Re
1598
+ }, L = le.validators;
1599
+ let q = class {
1600
+ constructor(t) {
1601
+ this.defaults = t || {}, this.interceptors = {
1602
+ request: new tt(),
1603
+ response: new tt()
1604
+ };
1605
+ }
1606
+ /**
1607
+ * Dispatch a request
1608
+ *
1609
+ * @param {String|Object} configOrUrl The config specific for this request (merged with this.defaults)
1610
+ * @param {?Object} config
1611
+ *
1612
+ * @returns {Promise} The Promise to be fulfilled
1613
+ */
1614
+ async request(t, n) {
1615
+ try {
1616
+ return await this._request(t, n);
1617
+ } catch (r) {
1618
+ if (r instanceof Error) {
1619
+ let s = {};
1620
+ Error.captureStackTrace ? Error.captureStackTrace(s) : s = new Error();
1621
+ const o = s.stack ? s.stack.replace(/^.+\n/, "") : "";
1622
+ try {
1623
+ r.stack ? o && !String(r.stack).endsWith(o.replace(/^.+\n.+\n/, "")) && (r.stack += `
1624
+ ` + o) : r.stack = o;
1625
+ } catch {
1626
+ }
1627
+ }
1628
+ throw r;
1629
+ }
1630
+ }
1631
+ _request(t, n) {
1632
+ typeof t == "string" ? (n = n || {}, n.url = t) : n = t || {}, n = M(this.defaults, n);
1633
+ const { transitional: r, paramsSerializer: s, headers: o } = n;
1634
+ r !== void 0 && le.assertOptions(r, {
1635
+ silentJSONParsing: L.transitional(L.boolean),
1636
+ forcedJSONParsing: L.transitional(L.boolean),
1637
+ clarifyTimeoutError: L.transitional(L.boolean),
1638
+ legacyInterceptorReqResOrdering: L.transitional(L.boolean)
1639
+ }, !1), s != null && (c.isFunction(s) ? n.paramsSerializer = {
1640
+ serialize: s
1641
+ } : le.assertOptions(s, {
1642
+ encode: L.function,
1643
+ serialize: L.function
1644
+ }, !0)), n.allowAbsoluteUrls !== void 0 || (this.defaults.allowAbsoluteUrls !== void 0 ? n.allowAbsoluteUrls = this.defaults.allowAbsoluteUrls : n.allowAbsoluteUrls = !0), le.assertOptions(n, {
1645
+ baseUrl: L.spelling("baseURL"),
1646
+ withXsrfToken: L.spelling("withXSRFToken")
1647
+ }, !0), n.method = (n.method || this.defaults.method || "get").toLowerCase();
1648
+ let i = o && c.merge(
1649
+ o.common,
1650
+ o[n.method]
1651
+ );
1652
+ o && c.forEach(
1653
+ ["delete", "get", "head", "post", "put", "patch", "common"],
1654
+ (l) => {
1655
+ delete o[l];
1656
+ }
1657
+ ), n.headers = P.concat(i, o);
1658
+ const a = [];
1659
+ let f = !0;
1660
+ this.interceptors.request.forEach(function(m) {
1661
+ if (typeof m.runWhen == "function" && m.runWhen(n) === !1)
1662
+ return;
1663
+ f = f && m.synchronous;
1664
+ const p = n.transitional || ke;
1665
+ p && p.legacyInterceptorReqResOrdering ? a.unshift(m.fulfilled, m.rejected) : a.push(m.fulfilled, m.rejected);
1666
+ });
1667
+ const d = [];
1668
+ this.interceptors.response.forEach(function(m) {
1669
+ d.push(m.fulfilled, m.rejected);
1670
+ });
1671
+ let u, h = 0, y;
1672
+ if (!f) {
1673
+ const l = [dt.bind(this), void 0];
1674
+ for (l.unshift(...a), l.push(...d), y = l.length, u = Promise.resolve(n); h < y; )
1675
+ u = u.then(l[h++], l[h++]);
1676
+ return u;
1677
+ }
1678
+ y = a.length;
1679
+ let g = n;
1680
+ for (; h < y; ) {
1681
+ const l = a[h++], m = a[h++];
1682
+ try {
1683
+ g = l(g);
1684
+ } catch (p) {
1685
+ m.call(this, p);
1686
+ break;
1687
+ }
1688
+ }
1689
+ try {
1690
+ u = dt.call(this, g);
1691
+ } catch (l) {
1692
+ return Promise.reject(l);
1693
+ }
1694
+ for (h = 0, y = d.length; h < y; )
1695
+ u = u.then(d[h++], d[h++]);
1696
+ return u;
1697
+ }
1698
+ getUri(t) {
1699
+ t = M(this.defaults, t);
1700
+ const n = Mt(t.baseURL, t.url, t.allowAbsoluteUrls);
1701
+ return Bt(n, t.params, t.paramsSerializer);
1702
+ }
1703
+ };
1704
+ c.forEach(["delete", "get", "head", "options"], function(t) {
1705
+ q.prototype[t] = function(n, r) {
1706
+ return this.request(M(r || {}, {
1707
+ method: t,
1708
+ url: n,
1709
+ data: (r || {}).data
1710
+ }));
1711
+ };
1712
+ });
1713
+ c.forEach(["post", "put", "patch"], function(t) {
1714
+ function n(r) {
1715
+ return function(o, i, a) {
1716
+ return this.request(M(a || {}, {
1717
+ method: t,
1718
+ headers: r ? {
1719
+ "Content-Type": "multipart/form-data"
1720
+ } : {},
1721
+ url: o,
1722
+ data: i
1723
+ }));
1724
+ };
1725
+ }
1726
+ q.prototype[t] = n(), q.prototype[t + "Form"] = n(!0);
1727
+ });
1728
+ let hs = class Kt {
1729
+ constructor(t) {
1730
+ if (typeof t != "function")
1731
+ throw new TypeError("executor must be a function.");
1732
+ let n;
1733
+ this.promise = new Promise(function(o) {
1734
+ n = o;
1735
+ });
1736
+ const r = this;
1737
+ this.promise.then((s) => {
1738
+ if (!r._listeners) return;
1739
+ let o = r._listeners.length;
1740
+ for (; o-- > 0; )
1741
+ r._listeners[o](s);
1742
+ r._listeners = null;
1743
+ }), this.promise.then = (s) => {
1744
+ let o;
1745
+ const i = new Promise((a) => {
1746
+ r.subscribe(a), o = a;
1747
+ }).then(s);
1748
+ return i.cancel = function() {
1749
+ r.unsubscribe(o);
1750
+ }, i;
1751
+ }, t(function(o, i, a) {
1752
+ r.reason || (r.reason = new re(o, i, a), n(r.reason));
1753
+ });
1754
+ }
1755
+ /**
1756
+ * Throws a `CanceledError` if cancellation has been requested.
1757
+ */
1758
+ throwIfRequested() {
1759
+ if (this.reason)
1760
+ throw this.reason;
1761
+ }
1762
+ /**
1763
+ * Subscribe to the cancel signal
1764
+ */
1765
+ subscribe(t) {
1766
+ if (this.reason) {
1767
+ t(this.reason);
1768
+ return;
1769
+ }
1770
+ this._listeners ? this._listeners.push(t) : this._listeners = [t];
1771
+ }
1772
+ /**
1773
+ * Unsubscribe from the cancel signal
1774
+ */
1775
+ unsubscribe(t) {
1776
+ if (!this._listeners)
1777
+ return;
1778
+ const n = this._listeners.indexOf(t);
1779
+ n !== -1 && this._listeners.splice(n, 1);
1780
+ }
1781
+ toAbortSignal() {
1782
+ const t = new AbortController(), n = (r) => {
1783
+ t.abort(r);
1784
+ };
1785
+ return this.subscribe(n), t.signal.unsubscribe = () => this.unsubscribe(n), t.signal;
1786
+ }
1787
+ /**
1788
+ * Returns an object that contains a new `CancelToken` and a function that, when called,
1789
+ * cancels the `CancelToken`.
1790
+ */
1791
+ static source() {
1792
+ let t;
1793
+ return {
1794
+ token: new Kt(function(s) {
1795
+ t = s;
1796
+ }),
1797
+ cancel: t
1798
+ };
1799
+ }
1800
+ };
1801
+ function ms(e) {
1802
+ return function(n) {
1803
+ return e.apply(null, n);
1804
+ };
1805
+ }
1806
+ function Es(e) {
1807
+ return c.isObject(e) && e.isAxiosError === !0;
1808
+ }
1809
+ const xe = {
1810
+ Continue: 100,
1811
+ SwitchingProtocols: 101,
1812
+ Processing: 102,
1813
+ EarlyHints: 103,
1814
+ Ok: 200,
1815
+ Created: 201,
1816
+ Accepted: 202,
1817
+ NonAuthoritativeInformation: 203,
1818
+ NoContent: 204,
1819
+ ResetContent: 205,
1820
+ PartialContent: 206,
1821
+ MultiStatus: 207,
1822
+ AlreadyReported: 208,
1823
+ ImUsed: 226,
1824
+ MultipleChoices: 300,
1825
+ MovedPermanently: 301,
1826
+ Found: 302,
1827
+ SeeOther: 303,
1828
+ NotModified: 304,
1829
+ UseProxy: 305,
1830
+ Unused: 306,
1831
+ TemporaryRedirect: 307,
1832
+ PermanentRedirect: 308,
1833
+ BadRequest: 400,
1834
+ Unauthorized: 401,
1835
+ PaymentRequired: 402,
1836
+ Forbidden: 403,
1837
+ NotFound: 404,
1838
+ MethodNotAllowed: 405,
1839
+ NotAcceptable: 406,
1840
+ ProxyAuthenticationRequired: 407,
1841
+ RequestTimeout: 408,
1842
+ Conflict: 409,
1843
+ Gone: 410,
1844
+ LengthRequired: 411,
1845
+ PreconditionFailed: 412,
1846
+ PayloadTooLarge: 413,
1847
+ UriTooLong: 414,
1848
+ UnsupportedMediaType: 415,
1849
+ RangeNotSatisfiable: 416,
1850
+ ExpectationFailed: 417,
1851
+ ImATeapot: 418,
1852
+ MisdirectedRequest: 421,
1853
+ UnprocessableEntity: 422,
1854
+ Locked: 423,
1855
+ FailedDependency: 424,
1856
+ TooEarly: 425,
1857
+ UpgradeRequired: 426,
1858
+ PreconditionRequired: 428,
1859
+ TooManyRequests: 429,
1860
+ RequestHeaderFieldsTooLarge: 431,
1861
+ UnavailableForLegalReasons: 451,
1862
+ InternalServerError: 500,
1863
+ NotImplemented: 501,
1864
+ BadGateway: 502,
1865
+ ServiceUnavailable: 503,
1866
+ GatewayTimeout: 504,
1867
+ HttpVersionNotSupported: 505,
1868
+ VariantAlsoNegotiates: 506,
1869
+ InsufficientStorage: 507,
1870
+ LoopDetected: 508,
1871
+ NotExtended: 510,
1872
+ NetworkAuthenticationRequired: 511,
1873
+ WebServerIsDown: 521,
1874
+ ConnectionTimedOut: 522,
1875
+ OriginIsUnreachable: 523,
1876
+ TimeoutOccurred: 524,
1877
+ SslHandshakeFailed: 525,
1878
+ InvalidSslCertificate: 526
1879
+ };
1880
+ Object.entries(xe).forEach(([e, t]) => {
1881
+ xe[t] = e;
1882
+ });
1883
+ function Xt(e) {
1884
+ const t = new q(e), n = Ct(q.prototype.request, t);
1885
+ return c.extend(n, q.prototype, t, { allOwnKeys: !0 }), c.extend(n, t, null, { allOwnKeys: !0 }), n.create = function(s) {
1886
+ return Xt(M(e, s));
1887
+ }, n;
1888
+ }
1889
+ const b = Xt(ne);
1890
+ b.Axios = q;
1891
+ b.CanceledError = re;
1892
+ b.CancelToken = hs;
1893
+ b.isCancel = vt;
1894
+ b.VERSION = Vt;
1895
+ b.toFormData = ge;
1896
+ b.AxiosError = E;
1897
+ b.Cancel = b.CanceledError;
1898
+ b.all = function(t) {
1899
+ return Promise.all(t);
1900
+ };
1901
+ b.spread = ms;
1902
+ b.isAxiosError = Es;
1903
+ b.mergeConfig = M;
1904
+ b.AxiosHeaders = P;
1905
+ b.formToJSON = (e) => kt(c.isHTMLForm(e) ? new FormData(e) : e);
1906
+ b.getAdapter = Jt.getAdapter;
1907
+ b.HttpStatusCode = xe;
1908
+ b.default = b;
1909
+ const {
1910
+ Axios: Ks,
1911
+ AxiosError: ys,
1912
+ CanceledError: Xs,
1913
+ isCancel: Ws,
1914
+ CancelToken: Gs,
1915
+ VERSION: Ys,
1916
+ all: Qs,
1917
+ Cancel: Zs,
1918
+ isAxiosError: eo,
1919
+ spread: to,
1920
+ toFormData: no,
1921
+ AxiosHeaders: ro,
1922
+ HttpStatusCode: so,
1923
+ formToJSON: oo,
1924
+ getAdapter: io,
1925
+ mergeConfig: ao
1926
+ } = b, gs = /* @__PURE__ */ new Set([
1927
+ "ENOTFOUND",
1928
+ "ENETUNREACH",
1929
+ // SSL errors from https://github.com/nodejs/node/blob/fc8e3e2cdc521978351de257030db0076d79e0ab/src/crypto/crypto_common.cc#L301-L328
1930
+ "UNABLE_TO_GET_ISSUER_CERT",
1931
+ "UNABLE_TO_GET_CRL",
1932
+ "UNABLE_TO_DECRYPT_CERT_SIGNATURE",
1933
+ "UNABLE_TO_DECRYPT_CRL_SIGNATURE",
1934
+ "UNABLE_TO_DECODE_ISSUER_PUBLIC_KEY",
1935
+ "CERT_SIGNATURE_FAILURE",
1936
+ "CRL_SIGNATURE_FAILURE",
1937
+ "CERT_NOT_YET_VALID",
1938
+ "CERT_HAS_EXPIRED",
1939
+ "CRL_NOT_YET_VALID",
1940
+ "CRL_HAS_EXPIRED",
1941
+ "ERROR_IN_CERT_NOT_BEFORE_FIELD",
1942
+ "ERROR_IN_CERT_NOT_AFTER_FIELD",
1943
+ "ERROR_IN_CRL_LAST_UPDATE_FIELD",
1944
+ "ERROR_IN_CRL_NEXT_UPDATE_FIELD",
1945
+ "OUT_OF_MEM",
1946
+ "DEPTH_ZERO_SELF_SIGNED_CERT",
1947
+ "SELF_SIGNED_CERT_IN_CHAIN",
1948
+ "UNABLE_TO_GET_ISSUER_CERT_LOCALLY",
1949
+ "UNABLE_TO_VERIFY_LEAF_SIGNATURE",
1950
+ "CERT_CHAIN_TOO_LONG",
1951
+ "CERT_REVOKED",
1952
+ "INVALID_CA",
1953
+ "PATH_LENGTH_EXCEEDED",
1954
+ "INVALID_PURPOSE",
1955
+ "CERT_UNTRUSTED",
1956
+ "CERT_REJECTED",
1957
+ "HOSTNAME_MISMATCH"
1958
+ ]);
1959
+ var Rs = (e) => !gs.has(e && e.code);
1960
+ const bs = /* @__PURE__ */ cn(Rs);
1961
+ function ht(e, t, n, r, s, o, i) {
1962
+ try {
1963
+ var a = e[o](i), f = a.value;
1964
+ } catch (d) {
1965
+ n(d);
1966
+ return;
1967
+ }
1968
+ a.done ? t(f) : Promise.resolve(f).then(r, s);
1969
+ }
1970
+ function Wt(e) {
1971
+ return function() {
1972
+ var t = this, n = arguments;
1973
+ return new Promise(function(r, s) {
1974
+ var o = e.apply(t, n);
1975
+ function i(f) {
1976
+ ht(o, r, s, i, a, "next", f);
1977
+ }
1978
+ function a(f) {
1979
+ ht(o, r, s, i, a, "throw", f);
1980
+ }
1981
+ i(void 0);
1982
+ });
1983
+ };
1984
+ }
1985
+ function mt(e, t) {
1986
+ var n = Object.keys(e);
1987
+ if (Object.getOwnPropertySymbols) {
1988
+ var r = Object.getOwnPropertySymbols(e);
1989
+ t && (r = r.filter(function(s) {
1990
+ return Object.getOwnPropertyDescriptor(e, s).enumerable;
1991
+ })), n.push.apply(n, r);
1992
+ }
1993
+ return n;
1994
+ }
1995
+ function Ce(e) {
1996
+ for (var t = 1; t < arguments.length; t++) {
1997
+ var n = arguments[t] != null ? arguments[t] : {};
1998
+ t % 2 ? mt(Object(n), !0).forEach(function(r) {
1999
+ _s(e, r, n[r]);
2000
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : mt(Object(n)).forEach(function(r) {
2001
+ Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(n, r));
2002
+ });
2003
+ }
2004
+ return e;
2005
+ }
2006
+ function _s(e, t, n) {
2007
+ return t in e ? Object.defineProperty(e, t, { value: n, enumerable: !0, configurable: !0, writable: !0 }) : e[t] = n, e;
2008
+ }
2009
+ var Gt = "axios-retry";
2010
+ function Me(e) {
2011
+ var t = ["ERR_CANCELED", "ECONNABORTED"];
2012
+ return !e.response && !!e.code && // Prevents retrying cancelled requests
2013
+ !t.includes(e.code) && // Prevents retrying timed out & cancelled requests
2014
+ bs(e);
2015
+ }
2016
+ var Yt = ["get", "head", "options"], Os = Yt.concat(["put", "delete"]);
2017
+ function He(e) {
2018
+ return e.code !== "ECONNABORTED" && (!e.response || e.response.status >= 500 && e.response.status <= 599);
2019
+ }
2020
+ function Ss(e) {
2021
+ return e.config ? He(e) && Yt.indexOf(e.config.method) !== -1 : !1;
2022
+ }
2023
+ function Qt(e) {
2024
+ return e.config ? He(e) && Os.indexOf(e.config.method) !== -1 : !1;
2025
+ }
2026
+ function Zt(e) {
2027
+ return Me(e) || Qt(e);
2028
+ }
2029
+ function ws() {
2030
+ return 0;
2031
+ }
2032
+ function en() {
2033
+ var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 0, t = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : 100, n = Math.pow(2, e) * t, r = n * 0.2 * Math.random();
2034
+ return n + r;
2035
+ }
2036
+ var Ts = {
2037
+ retries: 3,
2038
+ retryCondition: Zt,
2039
+ retryDelay: ws,
2040
+ shouldResetTimeout: !1,
2041
+ onRetry: () => {
2042
+ }
2043
+ };
2044
+ function As(e, t) {
2045
+ return Ce(Ce(Ce({}, Ts), t), e[Gt]);
2046
+ }
2047
+ function Et(e, t) {
2048
+ var n = As(e, t);
2049
+ return n.retryCount = n.retryCount || 0, e[Gt] = n, n;
2050
+ }
2051
+ function Cs(e, t) {
2052
+ e.defaults.agent === t.agent && delete t.agent, e.defaults.httpAgent === t.httpAgent && delete t.httpAgent, e.defaults.httpsAgent === t.httpsAgent && delete t.httpsAgent;
2053
+ }
2054
+ function Ns(e, t) {
2055
+ return Ue.apply(this, arguments);
2056
+ }
2057
+ function Ue() {
2058
+ return Ue = Wt(function* (e, t) {
2059
+ var {
2060
+ retries: n,
2061
+ retryCondition: r
2062
+ } = e, s = e.retryCount < n && r(t);
2063
+ if (typeof s == "object")
2064
+ try {
2065
+ var o = yield s;
2066
+ return o !== !1;
2067
+ } catch {
2068
+ return !1;
2069
+ }
2070
+ return s;
2071
+ }), Ue.apply(this, arguments);
2072
+ }
2073
+ function H(e, t) {
2074
+ var n = e.interceptors.request.use((s) => {
2075
+ var o = Et(s, t);
2076
+ return o.lastRequestTime = Date.now(), s;
2077
+ }), r = e.interceptors.response.use(null, /* @__PURE__ */ function() {
2078
+ var s = Wt(function* (o) {
2079
+ var {
2080
+ config: i
2081
+ } = o;
2082
+ if (!i)
2083
+ return Promise.reject(o);
2084
+ var a = Et(i, t);
2085
+ if (yield Ns(a, o)) {
2086
+ a.retryCount += 1;
2087
+ var {
2088
+ retryDelay: f,
2089
+ shouldResetTimeout: d,
2090
+ onRetry: u
2091
+ } = a, h = f(a.retryCount, o);
2092
+ if (Cs(e, i), !d && i.timeout && a.lastRequestTime) {
2093
+ var y = Date.now() - a.lastRequestTime, g = i.timeout - y - h;
2094
+ if (g <= 0)
2095
+ return Promise.reject(o);
2096
+ i.timeout = g;
2097
+ }
2098
+ return i.transformRequest = [(l) => l], yield u(a.retryCount, o, i), new Promise((l) => setTimeout(() => l(e(i)), h));
2099
+ }
2100
+ return Promise.reject(o);
2101
+ });
2102
+ return function(o) {
2103
+ return s.apply(this, arguments);
2104
+ };
2105
+ }());
2106
+ return {
2107
+ requestInterceptorId: n,
2108
+ responseInterceptorId: r
2109
+ };
2110
+ }
2111
+ H.isNetworkError = Me;
2112
+ H.isSafeRequestError = Ss;
2113
+ H.isIdempotentRequestError = Qt;
2114
+ H.isNetworkOrIdempotentRequestError = Zt;
2115
+ H.exponentialDelay = en;
2116
+ H.isRetryableError = He;
2117
+ class Ps {
2118
+ constructor(t) {
2119
+ t.interceptors.response.use(async (n) => {
2120
+ const r = un();
2121
+ if (n.status >= 200 && n.status < 300 && n.headers.etag && ln(n.headers.etag, n.data), n.status === 304) {
2122
+ const s = n.config.headers["If-Match"];
2123
+ s && (n.data = r[s]);
2124
+ }
2125
+ return n;
2126
+ });
2127
+ }
2128
+ }
2129
+ class Ds {
2130
+ constructor() {
2131
+ Ye(this, "client");
2132
+ this.client = b.create({
2133
+ validateStatus: (t) => t >= 200 && t < 300 || t === 304
2134
+ }), new Ps(this.client), H(this.client, {
2135
+ retries: 3,
2136
+ retryCondition: (t) => {
2137
+ var n, r, s;
2138
+ return (
2139
+ // Don't retry 502s, as we assume the server handles retries in those cases
2140
+ Me(t) || ((n = t == null ? void 0 : t.response) == null ? void 0 : n.status) >= 500 && ((r = t == null ? void 0 : t.response) == null ? void 0 : r.status) !== 502 || ((s = t == null ? void 0 : t.response) == null ? void 0 : s.status) === 429
2141
+ );
2142
+ },
2143
+ retryDelay: en
2144
+ });
2145
+ }
2146
+ async fetch(t, n = "get", r, s, o) {
2147
+ var a;
2148
+ const i = {
2149
+ url: t,
2150
+ params: s,
2151
+ method: n,
2152
+ withCredentials: !0,
2153
+ data: JSON.stringify(r),
2154
+ ...o ?? {}
2155
+ };
2156
+ try {
2157
+ const f = await this.client(i);
2158
+ return [f.data, f.status, f.headers];
2159
+ } catch (f) {
2160
+ if (f instanceof ys && ((a = f.response) != null && a.data))
2161
+ return [f.response.data, f.response.status, f.response.headers];
2162
+ throw f;
2163
+ }
2164
+ }
2165
+ }
2166
+ function Ls(e) {
2167
+ var t = [];
2168
+ if (e.length === 0)
2169
+ return "";
2170
+ if (typeof e[0] != "string")
2171
+ throw new TypeError("Url must be a string. Received " + e[0]);
2172
+ if (e[0].match(/^[^/:]+:\/*$/) && e.length > 1) {
2173
+ var n = e.shift();
2174
+ e[0] = n + e[0];
2175
+ }
2176
+ e[0].match(/^file:\/\/\//) ? e[0] = e[0].replace(/^([^/:]+):\/*/, "$1:///") : e[0] = e[0].replace(/^([^/:]+):\/*/, "$1://");
2177
+ for (var r = 0; r < e.length; r++) {
2178
+ var s = e[r];
2179
+ if (typeof s != "string")
2180
+ throw new TypeError("Url must be a string. Received " + s);
2181
+ s !== "" && (r > 0 && (s = s.replace(/^[\/]+/, "")), r < e.length - 1 ? s = s.replace(/[\/]+$/, "") : s = s.replace(/[\/]+$/, "/"), t.push(s));
2182
+ }
2183
+ var o = t.join("/");
2184
+ o = o.replace(/\/(\?|&|#[^!])/g, "$1");
2185
+ var i = o.split("?");
2186
+ return o = i.shift() + (i.length > 0 ? "?" : "") + i.join("&"), o;
2187
+ }
2188
+ function tn() {
2189
+ var e;
2190
+ return typeof arguments[0] == "object" ? e = arguments[0] : e = [].slice.call(arguments), Ls(e);
2191
+ }
2192
+ const de = (e) => `${Ne}.${e}`, G = (e) => {
2193
+ localStorage.removeItem(de(e));
2194
+ }, Y = (e, t) => {
2195
+ localStorage.setItem(de(e), JSON.stringify(t));
2196
+ }, W = (e) => {
2197
+ try {
2198
+ return JSON.parse(localStorage.getItem(de(e)));
2199
+ } catch {
2200
+ return localStorage.getItem(de(e));
2201
+ }
2202
+ }, yt = (e) => e != null && e.app_token ? (Y(O.APP_TOKEN, e.app_token), e.refresh_token && (Y(O.REFRESH_TOKEN, e.refresh_token), Y(O.PROVIDER, e.provider)), !0) : (G(O.REFRESH_TOKEN), G(O.APP_TOKEN), G(O.PROVIDER), !1), xs = () => {
2203
+ if (document.cookie !== void 0)
2204
+ try {
2205
+ return document.cookie.split("; ").find((e) => e.startsWith("XSRF-TOKEN")).split("=")[1];
2206
+ } catch {
2207
+ }
2208
+ return null;
2209
+ }, Us = new Ds(), Is = {
2210
+ auth: wn,
2211
+ configs: An,
2212
+ lookup: jn,
2213
+ actions: bn,
2214
+ fetchers: Ln,
2215
+ _static: qn
2216
+ }, $ = () => "/api/v1", nn = (e, t) => {
2217
+ const n = e.startsWith($()) ? e : `${$()}/${e.replace(/\/$/, "")}`.replace("//", "/");
2218
+ return t ? t + n : n;
2219
+ }, Fs = (e, t) => `${e}${t ? `${e.indexOf("?") > 0 ? "&" : "?"}${t.toString()}` : ""}`, w = (e, t, n) => {
2220
+ const r = nn(tn(e, t));
2221
+ return n ? Fs(r, n) : r;
2222
+ }, rn = (...e) => tn(...e), ze = async (e, t = "get", n, r, s) => {
2223
+ const o = W(O.APP_TOKEN), i = {
2224
+ ...s ?? {},
2225
+ headers: {
2226
+ ...(s == null ? void 0 : s.headers) ?? {},
2227
+ "Content-Type": "application/json",
2228
+ "X-XSRF-TOKEN": xs()
2229
+ }
2230
+ };
2231
+ o && !i.headers.Authorization && (i.headers.Authorization = `Bearer ${o}`);
2232
+ const [a, f] = await Us.fetch(
2233
+ nn(e, i.baseURL),
2234
+ t,
2235
+ n,
2236
+ r,
2237
+ i
2238
+ );
2239
+ if (!a)
2240
+ return null;
2241
+ if (f < 300 || f === 304)
2242
+ return a.api_response;
2243
+ if (f === 401) {
2244
+ if (W(O.NEXT_LOCATION) || (Y(O.NEXT_LOCATION, window.location.pathname), Y(O.NEXT_SEARCH, window.location.search)), !e.includes("/auth/login") && W(O.REFRESH_TOKEN)) {
2245
+ const d = W(O.REFRESH_TOKEN), u = W(O.PROVIDER), h = await Is.auth.login.post({
2246
+ refresh_token: d,
2247
+ provider: u
2248
+ });
2249
+ if (h) {
2250
+ yt(h);
2251
+ const y = await ze(e, t, n, r);
2252
+ return G(O.NEXT_LOCATION), G(O.NEXT_SEARCH), y;
2253
+ }
2254
+ }
2255
+ yt({});
2256
+ return;
2257
+ }
2258
+ throw new Error(
2259
+ a.api_error_message || a || `Error while fetching ${e} - ${t.toUpperCase()}`,
2260
+ {
2261
+ cause: a
2262
+ }
2263
+ );
2264
+ }, I = (e, t, n = {}) => ze(e, "get", null, t, n), be = (e, t, n = {}) => ze(e, "post", t, void 0, n), co = (e, t, n, r, s) => {
2265
+ const [o, i] = Se([]), [a, f] = Se({}), [d, u] = Se([]);
2266
+ return hn(() => {
2267
+ if (!e || (o == null ? void 0 : o.length) > 0 && !pn(a))
2268
+ return;
2269
+ const h = {}, y = r == null ? void 0 : r();
2270
+ y && (h.Authorization = `Bearer ${y}`), (async () => {
2271
+ let g = { baseURL: t, headers: h };
2272
+ s && (g = s(g)), fn("Executing types and type detection lookup", n);
2273
+ const [l, m] = await Promise.all([
2274
+ Ot(g),
2275
+ wt(g)
2276
+ ]);
2277
+ l && (i(Object.keys(l)), u(mn(Object.values(l).flat()))), m && f(
2278
+ Object.entries(m).reduce((p, [R, T]) => (T !== null && (p[R] = new RegExp(T)), p), {})
2279
+ );
2280
+ })();
2281
+ }, [t, e]), {
2282
+ availableSources: o,
2283
+ typesDetection: a,
2284
+ supportedTypes: d
2285
+ };
2286
+ };
2287
+ export {
2288
+ Is as a,
2289
+ co as b,
2290
+ xn as p,
2291
+ mn as u
2292
+ };