@opengis/bi 1.2.3 → 1.2.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bi.js +1 -1
- package/dist/bi.umd.cjs +40 -40
- package/dist/{import-file-D8jh74Dz.js → import-file-iZU4En2W.js} +1375 -1409
- package/dist/{vs-funnel-bar-T330oJNS.js → vs-funnel-bar-CyPcyYTP.js} +1 -1
- package/dist/{vs-list-DeHF_Oaf.js → vs-list-BoMIMCT2.js} +1 -1
- package/dist/{vs-map-Skt608pM.js → vs-map-DesSaN8x.js} +2 -2
- package/dist/{vs-map-cluster-BRUiY_90.js → vs-map-cluster-Br3XHcWM.js} +2 -2
- package/dist/{vs-number-Dd_21nn-.js → vs-number-sHlpEuZn.js} +1 -1
- package/dist/{vs-table-BwC29Zyc.js → vs-table-C8ibl5_z.js} +1 -1
- package/dist/{vs-text-DEJjWxDu.js → vs-text-CK4PX9CJ.js} +1 -1
- package/package.json +79 -78
- package/server/plugins/vite.js +69 -69
- package/server/routes/dashboard/controllers/utils/yaml.js +11 -11
- package/server/routes/data/controllers/data.js +1 -1
- package/server/routes/data/index.mjs +7 -1
- package/server/routes/map/controllers/cluster.js +125 -125
- package/server/routes/map/controllers/clusterVtile.js +166 -166
- package/server/routes/map/controllers/geojson.js +127 -127
- package/server/routes/map/controllers/map.js +69 -69
- package/server/routes/map/controllers/utils/downloadClusterData.js +44 -44
- package/server/routes/map/controllers/vtile.js +183 -183
- package/utils.js +12 -12
|
@@ -1,260 +1,260 @@
|
|
|
1
|
-
import { createElementBlock as _, openBlock as x, createElementVNode as
|
|
2
|
-
function
|
|
1
|
+
import { createElementBlock as _, openBlock as x, createElementVNode as m, Fragment as F, renderList as P, normalizeStyle as Re, normalizeClass as J, createCommentVNode as $, toDisplayString as E, ref as be, computed as Le, onUnmounted as vt, createTextVNode as Ze, defineAsyncComponent as T, defineComponent as Et, mergeModels as Pe, useModel as Ct, withDirectives as Rt, vModelCheckbox as Ot, resolveComponent as j, createBlock as I, createVNode as Oe, resolveDynamicComponent as Tt, createStaticVNode as Ye, withCtx as $t } from "vue";
|
|
2
|
+
function V(e, t) {
|
|
3
3
|
return e != null && e.value ? isNaN(e == null ? void 0 : e.value) ? e == null ? void 0 : e.value : new Intl.NumberFormat("en", t || {
|
|
4
4
|
notation: "compact"
|
|
5
5
|
}).format(e == null ? void 0 : e.value) : isNaN(e) ? e : new Intl.NumberFormat("en", t || {
|
|
6
6
|
notation: "compact"
|
|
7
7
|
}).format(e);
|
|
8
8
|
}
|
|
9
|
-
function
|
|
9
|
+
function Te(e) {
|
|
10
10
|
if (!(e != null && e.includes("T")))
|
|
11
11
|
return e;
|
|
12
|
-
const [t,
|
|
13
|
-
return `${
|
|
12
|
+
const [t, r, s] = e.split("T")[0].split("-");
|
|
13
|
+
return `${s}.${r}.${t}`;
|
|
14
14
|
}
|
|
15
|
-
function
|
|
15
|
+
function Bi(e) {
|
|
16
16
|
return Intl.NumberFormat("en").format(e);
|
|
17
17
|
}
|
|
18
|
-
function
|
|
18
|
+
function et(e, t) {
|
|
19
19
|
return function() {
|
|
20
20
|
return e.apply(t, arguments);
|
|
21
21
|
};
|
|
22
22
|
}
|
|
23
|
-
const { toString:
|
|
24
|
-
const
|
|
25
|
-
return e[
|
|
26
|
-
})(/* @__PURE__ */ Object.create(null)), B = (e) => (e = e.toLowerCase(), (t) =>
|
|
27
|
-
function
|
|
28
|
-
return e !== null && !
|
|
23
|
+
const { toString: Nt } = Object.prototype, { getPrototypeOf: $e } = Object, { iterator: de, toStringTag: tt } = Symbol, fe = /* @__PURE__ */ ((e) => (t) => {
|
|
24
|
+
const r = Nt.call(t);
|
|
25
|
+
return e[r] || (e[r] = r.slice(8, -1).toLowerCase());
|
|
26
|
+
})(/* @__PURE__ */ Object.create(null)), B = (e) => (e = e.toLowerCase(), (t) => fe(t) === e), he = (e) => (t) => typeof t === e, { isArray: X } = Array, Z = he("undefined");
|
|
27
|
+
function ee(e) {
|
|
28
|
+
return e !== null && !Z(e) && e.constructor !== null && !Z(e.constructor) && N(e.constructor.isBuffer) && e.constructor.isBuffer(e);
|
|
29
29
|
}
|
|
30
|
-
const
|
|
31
|
-
function
|
|
30
|
+
const rt = B("ArrayBuffer");
|
|
31
|
+
function At(e) {
|
|
32
32
|
let t;
|
|
33
|
-
return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? t = ArrayBuffer.isView(e) : t = e && e.buffer &&
|
|
33
|
+
return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? t = ArrayBuffer.isView(e) : t = e && e.buffer && rt(e.buffer), t;
|
|
34
34
|
}
|
|
35
|
-
const
|
|
36
|
-
if (
|
|
35
|
+
const Ft = he("string"), N = he("function"), st = he("number"), te = (e) => e !== null && typeof e == "object", Lt = (e) => e === !0 || e === !1, ie = (e) => {
|
|
36
|
+
if (fe(e) !== "object")
|
|
37
37
|
return !1;
|
|
38
|
-
const t =
|
|
39
|
-
return (t === null || t === Object.prototype || Object.getPrototypeOf(t) === null) && !(
|
|
40
|
-
},
|
|
41
|
-
if (!
|
|
38
|
+
const t = $e(e);
|
|
39
|
+
return (t === null || t === Object.prototype || Object.getPrototypeOf(t) === null) && !(tt in e) && !(de in e);
|
|
40
|
+
}, Pt = (e) => {
|
|
41
|
+
if (!te(e) || ee(e))
|
|
42
42
|
return !1;
|
|
43
43
|
try {
|
|
44
44
|
return Object.keys(e).length === 0 && Object.getPrototypeOf(e) === Object.prototype;
|
|
45
45
|
} catch {
|
|
46
46
|
return !1;
|
|
47
47
|
}
|
|
48
|
-
},
|
|
48
|
+
}, Bt = B("Date"), Ut = B("File"), jt = B("Blob"), Vt = B("FileList"), It = (e) => te(e) && N(e.pipe), zt = (e) => {
|
|
49
49
|
let t;
|
|
50
|
-
return e && (typeof FormData == "function" && e instanceof FormData ||
|
|
51
|
-
t === "object" &&
|
|
52
|
-
},
|
|
53
|
-
function
|
|
50
|
+
return e && (typeof FormData == "function" && e instanceof FormData || N(e.append) && ((t = fe(e)) === "formdata" || // detect form-data instance
|
|
51
|
+
t === "object" && N(e.toString) && e.toString() === "[object FormData]"));
|
|
52
|
+
}, Mt = B("URLSearchParams"), [qt, Ht, Wt, Jt] = ["ReadableStream", "Request", "Response", "Headers"].map(B), Kt = (e) => e.trim ? e.trim() : e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
|
|
53
|
+
function re(e, t, { allOwnKeys: r = !1 } = {}) {
|
|
54
54
|
if (e === null || typeof e > "u")
|
|
55
55
|
return;
|
|
56
|
-
let
|
|
57
|
-
if (typeof e != "object" && (e = [e]),
|
|
58
|
-
for (
|
|
59
|
-
t.call(null, e[
|
|
56
|
+
let s, n;
|
|
57
|
+
if (typeof e != "object" && (e = [e]), X(e))
|
|
58
|
+
for (s = 0, n = e.length; s < n; s++)
|
|
59
|
+
t.call(null, e[s], s, e);
|
|
60
60
|
else {
|
|
61
|
-
if (
|
|
61
|
+
if (ee(e))
|
|
62
62
|
return;
|
|
63
|
-
const i =
|
|
63
|
+
const i = r ? Object.getOwnPropertyNames(e) : Object.keys(e), o = i.length;
|
|
64
64
|
let a;
|
|
65
|
-
for (
|
|
66
|
-
a = i[
|
|
65
|
+
for (s = 0; s < o; s++)
|
|
66
|
+
a = i[s], t.call(null, e[a], a, e);
|
|
67
67
|
}
|
|
68
68
|
}
|
|
69
|
-
function
|
|
70
|
-
if (
|
|
69
|
+
function nt(e, t) {
|
|
70
|
+
if (ee(e))
|
|
71
71
|
return null;
|
|
72
72
|
t = t.toLowerCase();
|
|
73
|
-
const
|
|
74
|
-
let
|
|
75
|
-
for (;
|
|
76
|
-
if (n = s
|
|
73
|
+
const r = Object.keys(e);
|
|
74
|
+
let s = r.length, n;
|
|
75
|
+
for (; s-- > 0; )
|
|
76
|
+
if (n = r[s], t === n.toLowerCase())
|
|
77
77
|
return n;
|
|
78
78
|
return null;
|
|
79
79
|
}
|
|
80
|
-
const
|
|
81
|
-
function
|
|
82
|
-
const { caseless: e
|
|
83
|
-
const
|
|
84
|
-
|
|
80
|
+
const H = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : global, it = (e) => !Z(e) && e !== H;
|
|
81
|
+
function De() {
|
|
82
|
+
const { caseless: e } = it(this) && this || {}, t = {}, r = (s, n) => {
|
|
83
|
+
const i = e && nt(t, n) || n;
|
|
84
|
+
ie(t[i]) && ie(s) ? t[i] = De(t[i], s) : ie(s) ? t[i] = De({}, s) : X(s) ? t[i] = s.slice() : t[i] = s;
|
|
85
85
|
};
|
|
86
|
-
for (let
|
|
87
|
-
arguments[
|
|
88
|
-
return
|
|
86
|
+
for (let s = 0, n = arguments.length; s < n; s++)
|
|
87
|
+
arguments[s] && re(arguments[s], r);
|
|
88
|
+
return t;
|
|
89
89
|
}
|
|
90
|
-
const
|
|
91
|
-
|
|
92
|
-
}, { allOwnKeys:
|
|
93
|
-
e.prototype = Object.create(t.prototype,
|
|
90
|
+
const Xt = (e, t, r, { allOwnKeys: s } = {}) => (re(t, (n, i) => {
|
|
91
|
+
r && N(n) ? e[i] = et(n, r) : e[i] = n;
|
|
92
|
+
}, { allOwnKeys: s }), e), Gt = (e) => (e.charCodeAt(0) === 65279 && (e = e.slice(1)), e), Qt = (e, t, r, s) => {
|
|
93
|
+
e.prototype = Object.create(t.prototype, s), e.prototype.constructor = e, Object.defineProperty(e, "super", {
|
|
94
94
|
value: t.prototype
|
|
95
|
-
}),
|
|
96
|
-
},
|
|
95
|
+
}), r && Object.assign(e.prototype, r);
|
|
96
|
+
}, Zt = (e, t, r, s) => {
|
|
97
97
|
let n, i, o;
|
|
98
98
|
const a = {};
|
|
99
99
|
if (t = t || {}, e == null) return t;
|
|
100
100
|
do {
|
|
101
101
|
for (n = Object.getOwnPropertyNames(e), i = n.length; i-- > 0; )
|
|
102
|
-
o = n[i], (!
|
|
103
|
-
e =
|
|
104
|
-
} while (e && (!
|
|
102
|
+
o = n[i], (!s || s(o, e, t)) && !a[o] && (t[o] = e[o], a[o] = !0);
|
|
103
|
+
e = r !== !1 && $e(e);
|
|
104
|
+
} while (e && (!r || r(e, t)) && e !== Object.prototype);
|
|
105
105
|
return t;
|
|
106
|
-
},
|
|
107
|
-
e = String(e), (
|
|
108
|
-
const
|
|
109
|
-
return
|
|
110
|
-
},
|
|
106
|
+
}, Yt = (e, t, r) => {
|
|
107
|
+
e = String(e), (r === void 0 || r > e.length) && (r = e.length), r -= t.length;
|
|
108
|
+
const s = e.indexOf(t, r);
|
|
109
|
+
return s !== -1 && s === r;
|
|
110
|
+
}, er = (e) => {
|
|
111
111
|
if (!e) return null;
|
|
112
|
-
if (
|
|
112
|
+
if (X(e)) return e;
|
|
113
113
|
let t = e.length;
|
|
114
|
-
if (!
|
|
115
|
-
const
|
|
114
|
+
if (!st(t)) return null;
|
|
115
|
+
const r = new Array(t);
|
|
116
116
|
for (; t-- > 0; )
|
|
117
|
-
|
|
118
|
-
return
|
|
119
|
-
},
|
|
120
|
-
const
|
|
117
|
+
r[t] = e[t];
|
|
118
|
+
return r;
|
|
119
|
+
}, tr = /* @__PURE__ */ ((e) => (t) => e && t instanceof e)(typeof Uint8Array < "u" && $e(Uint8Array)), rr = (e, t) => {
|
|
120
|
+
const s = (e && e[de]).call(e);
|
|
121
121
|
let n;
|
|
122
|
-
for (; (n =
|
|
122
|
+
for (; (n = s.next()) && !n.done; ) {
|
|
123
123
|
const i = n.value;
|
|
124
124
|
t.call(e, i[0], i[1]);
|
|
125
125
|
}
|
|
126
|
-
},
|
|
127
|
-
let
|
|
128
|
-
const
|
|
129
|
-
for (; (
|
|
130
|
-
|
|
131
|
-
return
|
|
132
|
-
},
|
|
126
|
+
}, sr = (e, t) => {
|
|
127
|
+
let r;
|
|
128
|
+
const s = [];
|
|
129
|
+
for (; (r = e.exec(t)) !== null; )
|
|
130
|
+
s.push(r);
|
|
131
|
+
return s;
|
|
132
|
+
}, nr = B("HTMLFormElement"), ir = (e) => e.toLowerCase().replace(
|
|
133
133
|
/[-_\s]([a-z\d])(\w*)/g,
|
|
134
|
-
function(
|
|
135
|
-
return
|
|
134
|
+
function(r, s, n) {
|
|
135
|
+
return s.toUpperCase() + n;
|
|
136
136
|
}
|
|
137
|
-
),
|
|
138
|
-
const
|
|
139
|
-
|
|
137
|
+
), Be = (({ hasOwnProperty: e }) => (t, r) => e.call(t, r))(Object.prototype), or = B("RegExp"), ot = (e, t) => {
|
|
138
|
+
const r = Object.getOwnPropertyDescriptors(e), s = {};
|
|
139
|
+
re(r, (n, i) => {
|
|
140
140
|
let o;
|
|
141
|
-
(o = t(n, i, e)) !== !1 && (
|
|
142
|
-
}), Object.defineProperties(e,
|
|
143
|
-
},
|
|
144
|
-
|
|
145
|
-
if (
|
|
141
|
+
(o = t(n, i, e)) !== !1 && (s[i] = o || n);
|
|
142
|
+
}), Object.defineProperties(e, s);
|
|
143
|
+
}, ar = (e) => {
|
|
144
|
+
ot(e, (t, r) => {
|
|
145
|
+
if (N(e) && ["arguments", "caller", "callee"].indexOf(r) !== -1)
|
|
146
146
|
return !1;
|
|
147
|
-
const
|
|
148
|
-
if (
|
|
147
|
+
const s = e[r];
|
|
148
|
+
if (N(s)) {
|
|
149
149
|
if (t.enumerable = !1, "writable" in t) {
|
|
150
150
|
t.writable = !1;
|
|
151
151
|
return;
|
|
152
152
|
}
|
|
153
153
|
t.set || (t.set = () => {
|
|
154
|
-
throw Error("Can not rewrite read-only method '" +
|
|
154
|
+
throw Error("Can not rewrite read-only method '" + r + "'");
|
|
155
155
|
});
|
|
156
156
|
}
|
|
157
157
|
});
|
|
158
|
-
},
|
|
159
|
-
const
|
|
158
|
+
}, lr = (e, t) => {
|
|
159
|
+
const r = {}, s = (n) => {
|
|
160
160
|
n.forEach((i) => {
|
|
161
|
-
|
|
161
|
+
r[i] = !0;
|
|
162
162
|
});
|
|
163
163
|
};
|
|
164
|
-
return
|
|
165
|
-
},
|
|
166
|
-
},
|
|
167
|
-
function
|
|
168
|
-
return !!(e &&
|
|
169
|
-
}
|
|
170
|
-
const
|
|
171
|
-
const t = new Array(10),
|
|
172
|
-
if (
|
|
173
|
-
if (t.indexOf(
|
|
164
|
+
return X(e) ? s(e) : s(String(e).split(t)), r;
|
|
165
|
+
}, cr = () => {
|
|
166
|
+
}, ur = (e, t) => e != null && Number.isFinite(e = +e) ? e : t;
|
|
167
|
+
function dr(e) {
|
|
168
|
+
return !!(e && N(e.append) && e[tt] === "FormData" && e[de]);
|
|
169
|
+
}
|
|
170
|
+
const fr = (e) => {
|
|
171
|
+
const t = new Array(10), r = (s, n) => {
|
|
172
|
+
if (te(s)) {
|
|
173
|
+
if (t.indexOf(s) >= 0)
|
|
174
174
|
return;
|
|
175
|
-
if (
|
|
176
|
-
return
|
|
177
|
-
if (!("toJSON" in
|
|
178
|
-
t[n] =
|
|
179
|
-
const i =
|
|
180
|
-
return
|
|
181
|
-
const f =
|
|
182
|
-
!
|
|
175
|
+
if (ee(s))
|
|
176
|
+
return s;
|
|
177
|
+
if (!("toJSON" in s)) {
|
|
178
|
+
t[n] = s;
|
|
179
|
+
const i = X(s) ? [] : {};
|
|
180
|
+
return re(s, (o, a) => {
|
|
181
|
+
const f = r(o, n + 1);
|
|
182
|
+
!Z(f) && (i[a] = f);
|
|
183
183
|
}), t[n] = void 0, i;
|
|
184
184
|
}
|
|
185
185
|
}
|
|
186
|
-
return
|
|
186
|
+
return s;
|
|
187
187
|
};
|
|
188
|
-
return
|
|
189
|
-
},
|
|
190
|
-
n ===
|
|
188
|
+
return r(e, 0);
|
|
189
|
+
}, hr = B("AsyncFunction"), pr = (e) => e && (te(e) || N(e)) && N(e.then) && N(e.catch), at = ((e, t) => e ? setImmediate : t ? ((r, s) => (H.addEventListener("message", ({ source: n, data: i }) => {
|
|
190
|
+
n === H && i === r && s.length && s.shift()();
|
|
191
191
|
}, !1), (n) => {
|
|
192
|
-
|
|
193
|
-
}))(`axios@${Math.random()}`, []) : (
|
|
192
|
+
s.push(n), H.postMessage(r, "*");
|
|
193
|
+
}))(`axios@${Math.random()}`, []) : (r) => setTimeout(r))(
|
|
194
194
|
typeof setImmediate == "function",
|
|
195
|
-
|
|
196
|
-
),
|
|
197
|
-
isArray:
|
|
198
|
-
isArrayBuffer:
|
|
199
|
-
isBuffer:
|
|
200
|
-
isFormData:
|
|
201
|
-
isArrayBufferView:
|
|
202
|
-
isString:
|
|
203
|
-
isNumber:
|
|
204
|
-
isBoolean:
|
|
205
|
-
isObject:
|
|
206
|
-
isPlainObject:
|
|
207
|
-
isEmptyObject:
|
|
208
|
-
isReadableStream:
|
|
209
|
-
isRequest:
|
|
210
|
-
isResponse:
|
|
211
|
-
isHeaders:
|
|
212
|
-
isUndefined:
|
|
213
|
-
isDate:
|
|
214
|
-
isFile:
|
|
215
|
-
isBlob:
|
|
216
|
-
isRegExp:
|
|
217
|
-
isFunction:
|
|
218
|
-
isStream:
|
|
219
|
-
isURLSearchParams:
|
|
220
|
-
isTypedArray:
|
|
221
|
-
isFileList:
|
|
222
|
-
forEach:
|
|
223
|
-
merge:
|
|
224
|
-
extend:
|
|
225
|
-
trim:
|
|
226
|
-
stripBOM:
|
|
227
|
-
inherits:
|
|
228
|
-
toFlatObject:
|
|
229
|
-
kindOf:
|
|
195
|
+
N(H.postMessage)
|
|
196
|
+
), mr = typeof queueMicrotask < "u" ? queueMicrotask.bind(H) : typeof process < "u" && process.nextTick || at, gr = (e) => e != null && N(e[de]), l = {
|
|
197
|
+
isArray: X,
|
|
198
|
+
isArrayBuffer: rt,
|
|
199
|
+
isBuffer: ee,
|
|
200
|
+
isFormData: zt,
|
|
201
|
+
isArrayBufferView: At,
|
|
202
|
+
isString: Ft,
|
|
203
|
+
isNumber: st,
|
|
204
|
+
isBoolean: Lt,
|
|
205
|
+
isObject: te,
|
|
206
|
+
isPlainObject: ie,
|
|
207
|
+
isEmptyObject: Pt,
|
|
208
|
+
isReadableStream: qt,
|
|
209
|
+
isRequest: Ht,
|
|
210
|
+
isResponse: Wt,
|
|
211
|
+
isHeaders: Jt,
|
|
212
|
+
isUndefined: Z,
|
|
213
|
+
isDate: Bt,
|
|
214
|
+
isFile: Ut,
|
|
215
|
+
isBlob: jt,
|
|
216
|
+
isRegExp: or,
|
|
217
|
+
isFunction: N,
|
|
218
|
+
isStream: It,
|
|
219
|
+
isURLSearchParams: Mt,
|
|
220
|
+
isTypedArray: tr,
|
|
221
|
+
isFileList: Vt,
|
|
222
|
+
forEach: re,
|
|
223
|
+
merge: De,
|
|
224
|
+
extend: Xt,
|
|
225
|
+
trim: Kt,
|
|
226
|
+
stripBOM: Gt,
|
|
227
|
+
inherits: Qt,
|
|
228
|
+
toFlatObject: Zt,
|
|
229
|
+
kindOf: fe,
|
|
230
230
|
kindOfTest: B,
|
|
231
|
-
endsWith:
|
|
232
|
-
toArray:
|
|
233
|
-
forEachEntry:
|
|
234
|
-
matchAll:
|
|
235
|
-
isHTMLForm:
|
|
236
|
-
hasOwnProperty:
|
|
237
|
-
hasOwnProp:
|
|
231
|
+
endsWith: Yt,
|
|
232
|
+
toArray: er,
|
|
233
|
+
forEachEntry: rr,
|
|
234
|
+
matchAll: sr,
|
|
235
|
+
isHTMLForm: nr,
|
|
236
|
+
hasOwnProperty: Be,
|
|
237
|
+
hasOwnProp: Be,
|
|
238
238
|
// an alias to avoid ESLint no-prototype-builtins detection
|
|
239
|
-
reduceDescriptors:
|
|
240
|
-
freezeMethods:
|
|
241
|
-
toObjectSet:
|
|
242
|
-
toCamelCase:
|
|
243
|
-
noop:
|
|
244
|
-
toFiniteNumber:
|
|
245
|
-
findKey:
|
|
246
|
-
global:
|
|
247
|
-
isContextDefined:
|
|
248
|
-
isSpecCompliantForm:
|
|
249
|
-
toJSONObject:
|
|
250
|
-
isAsyncFn:
|
|
251
|
-
isThenable:
|
|
252
|
-
setImmediate:
|
|
253
|
-
asap:
|
|
254
|
-
isIterable:
|
|
239
|
+
reduceDescriptors: ot,
|
|
240
|
+
freezeMethods: ar,
|
|
241
|
+
toObjectSet: lr,
|
|
242
|
+
toCamelCase: ir,
|
|
243
|
+
noop: cr,
|
|
244
|
+
toFiniteNumber: ur,
|
|
245
|
+
findKey: nt,
|
|
246
|
+
global: H,
|
|
247
|
+
isContextDefined: it,
|
|
248
|
+
isSpecCompliantForm: dr,
|
|
249
|
+
toJSONObject: fr,
|
|
250
|
+
isAsyncFn: hr,
|
|
251
|
+
isThenable: pr,
|
|
252
|
+
setImmediate: at,
|
|
253
|
+
asap: mr,
|
|
254
|
+
isIterable: gr
|
|
255
255
|
};
|
|
256
|
-
function D(e, t,
|
|
257
|
-
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),
|
|
256
|
+
function D(e, t, r, s, n) {
|
|
257
|
+
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), r && (this.config = r), s && (this.request = s), n && (this.response = n, this.status = n.status ? n.status : null);
|
|
258
258
|
}
|
|
259
259
|
l.inherits(D, Error, {
|
|
260
260
|
toJSON: function() {
|
|
@@ -277,7 +277,7 @@ l.inherits(D, Error, {
|
|
|
277
277
|
};
|
|
278
278
|
}
|
|
279
279
|
});
|
|
280
|
-
const
|
|
280
|
+
const lt = D.prototype, ct = {};
|
|
281
281
|
[
|
|
282
282
|
"ERR_BAD_OPTION_VALUE",
|
|
283
283
|
"ERR_BAD_OPTION",
|
|
@@ -293,100 +293,98 @@ const kt = D.prototype, vt = {};
|
|
|
293
293
|
"ERR_INVALID_URL"
|
|
294
294
|
// eslint-disable-next-line func-names
|
|
295
295
|
].forEach((e) => {
|
|
296
|
-
|
|
296
|
+
ct[e] = { value: e };
|
|
297
297
|
});
|
|
298
|
-
Object.defineProperties(D,
|
|
299
|
-
Object.defineProperty(
|
|
300
|
-
D.from = (e, t,
|
|
301
|
-
const o = Object.create(
|
|
302
|
-
l.toFlatObject(e, o, function(
|
|
303
|
-
return
|
|
304
|
-
}, (
|
|
305
|
-
const a = e && e.message ? e.message : "Error", f = t == null && e ? e.code : t;
|
|
306
|
-
return D.call(o, a, f, s, r, n), e && o.cause == null && Object.defineProperty(o, "cause", { value: e, configurable: !0 }), o.name = e && e.name || "Error", i && Object.assign(o, i), o;
|
|
298
|
+
Object.defineProperties(D, ct);
|
|
299
|
+
Object.defineProperty(lt, "isAxiosError", { value: !0 });
|
|
300
|
+
D.from = (e, t, r, s, n, i) => {
|
|
301
|
+
const o = Object.create(lt);
|
|
302
|
+
return l.toFlatObject(e, o, function(f) {
|
|
303
|
+
return f !== Error.prototype;
|
|
304
|
+
}, (a) => a !== "isAxiosError"), D.call(o, e.message, t, r, s, n), o.cause = e, o.name = e.name, i && Object.assign(o, i), o;
|
|
307
305
|
};
|
|
308
|
-
const
|
|
309
|
-
function
|
|
306
|
+
const br = null;
|
|
307
|
+
function ke(e) {
|
|
310
308
|
return l.isPlainObject(e) || l.isArray(e);
|
|
311
309
|
}
|
|
312
|
-
function
|
|
310
|
+
function ut(e) {
|
|
313
311
|
return l.endsWith(e, "[]") ? e.slice(0, -2) : e;
|
|
314
312
|
}
|
|
315
|
-
function
|
|
313
|
+
function Ue(e, t, r) {
|
|
316
314
|
return e ? e.concat(t).map(function(n, i) {
|
|
317
|
-
return n =
|
|
318
|
-
}).join(
|
|
315
|
+
return n = ut(n), !r && i ? "[" + n + "]" : n;
|
|
316
|
+
}).join(r ? "." : "") : t;
|
|
319
317
|
}
|
|
320
|
-
function
|
|
321
|
-
return l.isArray(e) && !e.some(
|
|
318
|
+
function wr(e) {
|
|
319
|
+
return l.isArray(e) && !e.some(ke);
|
|
322
320
|
}
|
|
323
|
-
const
|
|
321
|
+
const yr = l.toFlatObject(l, {}, null, function(t) {
|
|
324
322
|
return /^is[A-Z]/.test(t);
|
|
325
323
|
});
|
|
326
|
-
function
|
|
324
|
+
function pe(e, t, r) {
|
|
327
325
|
if (!l.isObject(e))
|
|
328
326
|
throw new TypeError("target must be an object");
|
|
329
|
-
t = t || new FormData(),
|
|
327
|
+
t = t || new FormData(), r = l.toFlatObject(r, {
|
|
330
328
|
metaTokens: !0,
|
|
331
329
|
dots: !1,
|
|
332
330
|
indexes: !1
|
|
333
|
-
}, !1, function(p,
|
|
334
|
-
return !l.isUndefined(
|
|
331
|
+
}, !1, function(p, b) {
|
|
332
|
+
return !l.isUndefined(b[p]);
|
|
335
333
|
});
|
|
336
|
-
const
|
|
334
|
+
const s = r.metaTokens, n = r.visitor || c, i = r.dots, o = r.indexes, f = (r.Blob || typeof Blob < "u" && Blob) && l.isSpecCompliantForm(t);
|
|
337
335
|
if (!l.isFunction(n))
|
|
338
336
|
throw new TypeError("visitor must be a function");
|
|
339
|
-
function d
|
|
340
|
-
if (
|
|
341
|
-
if (l.isDate(
|
|
342
|
-
return
|
|
343
|
-
if (l.isBoolean(
|
|
344
|
-
return
|
|
345
|
-
if (!f && l.isBlob(
|
|
337
|
+
function u(d) {
|
|
338
|
+
if (d === null) return "";
|
|
339
|
+
if (l.isDate(d))
|
|
340
|
+
return d.toISOString();
|
|
341
|
+
if (l.isBoolean(d))
|
|
342
|
+
return d.toString();
|
|
343
|
+
if (!f && l.isBlob(d))
|
|
346
344
|
throw new D("Blob is not supported. Use a Buffer instead.");
|
|
347
|
-
return l.isArrayBuffer(
|
|
345
|
+
return l.isArrayBuffer(d) || l.isTypedArray(d) ? f && typeof Blob == "function" ? new Blob([d]) : Buffer.from(d) : d;
|
|
348
346
|
}
|
|
349
|
-
function
|
|
350
|
-
let
|
|
351
|
-
if (
|
|
347
|
+
function c(d, p, b) {
|
|
348
|
+
let S = d;
|
|
349
|
+
if (d && !b && typeof d == "object") {
|
|
352
350
|
if (l.endsWith(p, "{}"))
|
|
353
|
-
p =
|
|
354
|
-
else if (l.isArray(
|
|
355
|
-
return p =
|
|
351
|
+
p = s ? p : p.slice(0, -2), d = JSON.stringify(d);
|
|
352
|
+
else if (l.isArray(d) && wr(d) || (l.isFileList(d) || l.endsWith(p, "[]")) && (S = l.toArray(d)))
|
|
353
|
+
return p = ut(p), S.forEach(function(y, L) {
|
|
356
354
|
!(l.isUndefined(y) || y === null) && t.append(
|
|
357
355
|
// eslint-disable-next-line no-nested-ternary
|
|
358
|
-
o === !0 ?
|
|
359
|
-
|
|
356
|
+
o === !0 ? Ue([p], L, i) : o === null ? p : p + "[]",
|
|
357
|
+
u(y)
|
|
360
358
|
);
|
|
361
359
|
}), !1;
|
|
362
360
|
}
|
|
363
|
-
return
|
|
361
|
+
return ke(d) ? !0 : (t.append(Ue(b, p, i), u(d)), !1);
|
|
364
362
|
}
|
|
365
|
-
const h = [], w = Object.assign(
|
|
366
|
-
defaultVisitor:
|
|
367
|
-
convertValue:
|
|
368
|
-
isVisitable:
|
|
363
|
+
const h = [], w = Object.assign(yr, {
|
|
364
|
+
defaultVisitor: c,
|
|
365
|
+
convertValue: u,
|
|
366
|
+
isVisitable: ke
|
|
369
367
|
});
|
|
370
|
-
function
|
|
371
|
-
if (!l.isUndefined(
|
|
372
|
-
if (h.indexOf(
|
|
368
|
+
function g(d, p) {
|
|
369
|
+
if (!l.isUndefined(d)) {
|
|
370
|
+
if (h.indexOf(d) !== -1)
|
|
373
371
|
throw Error("Circular reference detected in " + p.join("."));
|
|
374
|
-
h.push(
|
|
375
|
-
(!(l.isUndefined(
|
|
372
|
+
h.push(d), l.forEach(d, function(S, k) {
|
|
373
|
+
(!(l.isUndefined(S) || S === null) && n.call(
|
|
376
374
|
t,
|
|
377
|
-
|
|
378
|
-
l.isString(
|
|
375
|
+
S,
|
|
376
|
+
l.isString(k) ? k.trim() : k,
|
|
379
377
|
p,
|
|
380
378
|
w
|
|
381
|
-
)) === !0 &&
|
|
379
|
+
)) === !0 && g(S, p ? p.concat(k) : [k]);
|
|
382
380
|
}), h.pop();
|
|
383
381
|
}
|
|
384
382
|
}
|
|
385
383
|
if (!l.isObject(e))
|
|
386
384
|
throw new TypeError("data must be an object");
|
|
387
|
-
return
|
|
385
|
+
return g(e), t;
|
|
388
386
|
}
|
|
389
|
-
function
|
|
387
|
+
function je(e) {
|
|
390
388
|
const t = {
|
|
391
389
|
"!": "%21",
|
|
392
390
|
"'": "%27",
|
|
@@ -396,44 +394,44 @@ function Ze(e) {
|
|
|
396
394
|
"%20": "+",
|
|
397
395
|
"%00": "\0"
|
|
398
396
|
};
|
|
399
|
-
return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g, function(
|
|
400
|
-
return t[
|
|
397
|
+
return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g, function(s) {
|
|
398
|
+
return t[s];
|
|
401
399
|
});
|
|
402
400
|
}
|
|
403
|
-
function
|
|
404
|
-
this._pairs = [], e &&
|
|
401
|
+
function Ne(e, t) {
|
|
402
|
+
this._pairs = [], e && pe(e, this, t);
|
|
405
403
|
}
|
|
406
|
-
const
|
|
407
|
-
|
|
408
|
-
this._pairs.push([t,
|
|
404
|
+
const dt = Ne.prototype;
|
|
405
|
+
dt.append = function(t, r) {
|
|
406
|
+
this._pairs.push([t, r]);
|
|
409
407
|
};
|
|
410
|
-
|
|
411
|
-
const
|
|
412
|
-
return t.call(this,
|
|
413
|
-
} :
|
|
408
|
+
dt.toString = function(t) {
|
|
409
|
+
const r = t ? function(s) {
|
|
410
|
+
return t.call(this, s, je);
|
|
411
|
+
} : je;
|
|
414
412
|
return this._pairs.map(function(n) {
|
|
415
|
-
return
|
|
413
|
+
return r(n[0]) + "=" + r(n[1]);
|
|
416
414
|
}, "").join("&");
|
|
417
415
|
};
|
|
418
|
-
function
|
|
419
|
-
return encodeURIComponent(e).replace(/%3A/gi, ":").replace(/%24/g, "$").replace(/%2C/gi, ",").replace(/%20/g, "+");
|
|
416
|
+
function xr(e) {
|
|
417
|
+
return encodeURIComponent(e).replace(/%3A/gi, ":").replace(/%24/g, "$").replace(/%2C/gi, ",").replace(/%20/g, "+").replace(/%5B/gi, "[").replace(/%5D/gi, "]");
|
|
420
418
|
}
|
|
421
|
-
function
|
|
419
|
+
function ft(e, t, r) {
|
|
422
420
|
if (!t)
|
|
423
421
|
return e;
|
|
424
|
-
const
|
|
425
|
-
l.isFunction(
|
|
426
|
-
serialize:
|
|
422
|
+
const s = r && r.encode || xr;
|
|
423
|
+
l.isFunction(r) && (r = {
|
|
424
|
+
serialize: r
|
|
427
425
|
});
|
|
428
|
-
const n =
|
|
426
|
+
const n = r && r.serialize;
|
|
429
427
|
let i;
|
|
430
|
-
if (n ? i = n(t,
|
|
428
|
+
if (n ? i = n(t, r) : i = l.isURLSearchParams(t) ? t.toString() : new Ne(t, r).toString(s), i) {
|
|
431
429
|
const o = e.indexOf("#");
|
|
432
430
|
o !== -1 && (e = e.slice(0, o)), e += (e.indexOf("?") === -1 ? "?" : "&") + i;
|
|
433
431
|
}
|
|
434
432
|
return e;
|
|
435
433
|
}
|
|
436
|
-
class
|
|
434
|
+
class Ve {
|
|
437
435
|
constructor() {
|
|
438
436
|
this.handlers = [];
|
|
439
437
|
}
|
|
@@ -445,12 +443,12 @@ class Ye {
|
|
|
445
443
|
*
|
|
446
444
|
* @return {Number} An ID used to remove interceptor later
|
|
447
445
|
*/
|
|
448
|
-
use(t,
|
|
446
|
+
use(t, r, s) {
|
|
449
447
|
return this.handlers.push({
|
|
450
448
|
fulfilled: t,
|
|
451
|
-
rejected:
|
|
452
|
-
synchronous:
|
|
453
|
-
runWhen:
|
|
449
|
+
rejected: r,
|
|
450
|
+
synchronous: s ? s.synchronous : !1,
|
|
451
|
+
runWhen: s ? s.runWhen : null
|
|
454
452
|
}), this.handlers.length - 1;
|
|
455
453
|
}
|
|
456
454
|
/**
|
|
@@ -482,116 +480,116 @@ class Ye {
|
|
|
482
480
|
* @returns {void}
|
|
483
481
|
*/
|
|
484
482
|
forEach(t) {
|
|
485
|
-
l.forEach(this.handlers, function(
|
|
486
|
-
|
|
483
|
+
l.forEach(this.handlers, function(s) {
|
|
484
|
+
s !== null && t(s);
|
|
487
485
|
});
|
|
488
486
|
}
|
|
489
487
|
}
|
|
490
|
-
const
|
|
488
|
+
const ht = {
|
|
491
489
|
silentJSONParsing: !0,
|
|
492
490
|
forcedJSONParsing: !0,
|
|
493
491
|
clarifyTimeoutError: !1
|
|
494
|
-
},
|
|
492
|
+
}, _r = typeof URLSearchParams < "u" ? URLSearchParams : Ne, Dr = typeof FormData < "u" ? FormData : null, kr = typeof Blob < "u" ? Blob : null, Sr = {
|
|
495
493
|
isBrowser: !0,
|
|
496
494
|
classes: {
|
|
497
|
-
URLSearchParams:
|
|
498
|
-
FormData:
|
|
499
|
-
Blob:
|
|
495
|
+
URLSearchParams: _r,
|
|
496
|
+
FormData: Dr,
|
|
497
|
+
Blob: kr
|
|
500
498
|
},
|
|
501
499
|
protocols: ["http", "https", "file", "blob", "url", "data"]
|
|
502
|
-
},
|
|
503
|
-
self instanceof WorkerGlobalScope && typeof self.importScripts == "function",
|
|
500
|
+
}, Ae = typeof window < "u" && typeof document < "u", Se = typeof navigator == "object" && navigator || void 0, vr = Ae && (!Se || ["ReactNative", "NativeScript", "NS"].indexOf(Se.product) < 0), Er = typeof WorkerGlobalScope < "u" && // eslint-disable-next-line no-undef
|
|
501
|
+
self instanceof WorkerGlobalScope && typeof self.importScripts == "function", Cr = Ae && window.location.href || "http://localhost", Rr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
504
502
|
__proto__: null,
|
|
505
|
-
hasBrowserEnv:
|
|
506
|
-
hasStandardBrowserEnv:
|
|
507
|
-
hasStandardBrowserWebWorkerEnv:
|
|
508
|
-
navigator:
|
|
509
|
-
origin:
|
|
510
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
511
|
-
...
|
|
512
|
-
...
|
|
503
|
+
hasBrowserEnv: Ae,
|
|
504
|
+
hasStandardBrowserEnv: vr,
|
|
505
|
+
hasStandardBrowserWebWorkerEnv: Er,
|
|
506
|
+
navigator: Se,
|
|
507
|
+
origin: Cr
|
|
508
|
+
}, Symbol.toStringTag, { value: "Module" })), O = {
|
|
509
|
+
...Rr,
|
|
510
|
+
...Sr
|
|
513
511
|
};
|
|
514
|
-
function
|
|
515
|
-
return
|
|
516
|
-
visitor: function(
|
|
517
|
-
return
|
|
512
|
+
function Or(e, t) {
|
|
513
|
+
return pe(e, new O.classes.URLSearchParams(), {
|
|
514
|
+
visitor: function(r, s, n, i) {
|
|
515
|
+
return O.isNode && l.isBuffer(r) ? (this.append(s, r.toString("base64")), !1) : i.defaultVisitor.apply(this, arguments);
|
|
518
516
|
},
|
|
519
517
|
...t
|
|
520
518
|
});
|
|
521
519
|
}
|
|
522
|
-
function
|
|
520
|
+
function Tr(e) {
|
|
523
521
|
return l.matchAll(/\w+|\[(\w*)]/g, e).map((t) => t[0] === "[]" ? "" : t[1] || t[0]);
|
|
524
522
|
}
|
|
525
|
-
function
|
|
526
|
-
const t = {},
|
|
527
|
-
let
|
|
528
|
-
const n =
|
|
523
|
+
function $r(e) {
|
|
524
|
+
const t = {}, r = Object.keys(e);
|
|
525
|
+
let s;
|
|
526
|
+
const n = r.length;
|
|
529
527
|
let i;
|
|
530
|
-
for (
|
|
531
|
-
i = s
|
|
528
|
+
for (s = 0; s < n; s++)
|
|
529
|
+
i = r[s], t[i] = e[i];
|
|
532
530
|
return t;
|
|
533
531
|
}
|
|
534
|
-
function
|
|
535
|
-
function t(
|
|
536
|
-
let o =
|
|
532
|
+
function pt(e) {
|
|
533
|
+
function t(r, s, n, i) {
|
|
534
|
+
let o = r[i++];
|
|
537
535
|
if (o === "__proto__") return !0;
|
|
538
|
-
const a = Number.isFinite(+o), f = i >=
|
|
539
|
-
return o = !o && l.isArray(n) ? n.length : o, f ? (l.hasOwnProp(n, o) ? n[o] = [n[o],
|
|
536
|
+
const a = Number.isFinite(+o), f = i >= r.length;
|
|
537
|
+
return o = !o && l.isArray(n) ? n.length : o, f ? (l.hasOwnProp(n, o) ? n[o] = [n[o], s] : n[o] = s, !a) : ((!n[o] || !l.isObject(n[o])) && (n[o] = []), t(r, s, n[o], i) && l.isArray(n[o]) && (n[o] = $r(n[o])), !a);
|
|
540
538
|
}
|
|
541
539
|
if (l.isFormData(e) && l.isFunction(e.entries)) {
|
|
542
|
-
const
|
|
543
|
-
return l.forEachEntry(e, (
|
|
544
|
-
t(
|
|
545
|
-
}),
|
|
540
|
+
const r = {};
|
|
541
|
+
return l.forEachEntry(e, (s, n) => {
|
|
542
|
+
t(Tr(s), n, r, 0);
|
|
543
|
+
}), r;
|
|
546
544
|
}
|
|
547
545
|
return null;
|
|
548
546
|
}
|
|
549
|
-
function
|
|
547
|
+
function Nr(e, t, r) {
|
|
550
548
|
if (l.isString(e))
|
|
551
549
|
try {
|
|
552
550
|
return (t || JSON.parse)(e), l.trim(e);
|
|
553
|
-
} catch (
|
|
554
|
-
if (
|
|
555
|
-
throw
|
|
551
|
+
} catch (s) {
|
|
552
|
+
if (s.name !== "SyntaxError")
|
|
553
|
+
throw s;
|
|
556
554
|
}
|
|
557
|
-
return (
|
|
555
|
+
return (r || JSON.stringify)(e);
|
|
558
556
|
}
|
|
559
|
-
const
|
|
560
|
-
transitional:
|
|
557
|
+
const se = {
|
|
558
|
+
transitional: ht,
|
|
561
559
|
adapter: ["xhr", "http", "fetch"],
|
|
562
|
-
transformRequest: [function(t,
|
|
563
|
-
const
|
|
560
|
+
transformRequest: [function(t, r) {
|
|
561
|
+
const s = r.getContentType() || "", n = s.indexOf("application/json") > -1, i = l.isObject(t);
|
|
564
562
|
if (i && l.isHTMLForm(t) && (t = new FormData(t)), l.isFormData(t))
|
|
565
|
-
return n ? JSON.stringify(
|
|
563
|
+
return n ? JSON.stringify(pt(t)) : t;
|
|
566
564
|
if (l.isArrayBuffer(t) || l.isBuffer(t) || l.isStream(t) || l.isFile(t) || l.isBlob(t) || l.isReadableStream(t))
|
|
567
565
|
return t;
|
|
568
566
|
if (l.isArrayBufferView(t))
|
|
569
567
|
return t.buffer;
|
|
570
568
|
if (l.isURLSearchParams(t))
|
|
571
|
-
return
|
|
569
|
+
return r.setContentType("application/x-www-form-urlencoded;charset=utf-8", !1), t.toString();
|
|
572
570
|
let a;
|
|
573
571
|
if (i) {
|
|
574
|
-
if (
|
|
575
|
-
return
|
|
576
|
-
if ((a = l.isFileList(t)) ||
|
|
572
|
+
if (s.indexOf("application/x-www-form-urlencoded") > -1)
|
|
573
|
+
return Or(t, this.formSerializer).toString();
|
|
574
|
+
if ((a = l.isFileList(t)) || s.indexOf("multipart/form-data") > -1) {
|
|
577
575
|
const f = this.env && this.env.FormData;
|
|
578
|
-
return
|
|
576
|
+
return pe(
|
|
579
577
|
a ? { "files[]": t } : t,
|
|
580
578
|
f && new f(),
|
|
581
579
|
this.formSerializer
|
|
582
580
|
);
|
|
583
581
|
}
|
|
584
582
|
}
|
|
585
|
-
return i || n ? (
|
|
583
|
+
return i || n ? (r.setContentType("application/json", !1), Nr(t)) : t;
|
|
586
584
|
}],
|
|
587
585
|
transformResponse: [function(t) {
|
|
588
|
-
const
|
|
586
|
+
const r = this.transitional || se.transitional, s = r && r.forcedJSONParsing, n = this.responseType === "json";
|
|
589
587
|
if (l.isResponse(t) || l.isReadableStream(t))
|
|
590
588
|
return t;
|
|
591
|
-
if (t && l.isString(t) && (
|
|
592
|
-
const o = !(
|
|
589
|
+
if (t && l.isString(t) && (s && !this.responseType || n)) {
|
|
590
|
+
const o = !(r && r.silentJSONParsing) && n;
|
|
593
591
|
try {
|
|
594
|
-
return JSON.parse(t
|
|
592
|
+
return JSON.parse(t);
|
|
595
593
|
} catch (a) {
|
|
596
594
|
if (o)
|
|
597
595
|
throw a.name === "SyntaxError" ? D.from(a, D.ERR_BAD_RESPONSE, this, null, this.response) : a;
|
|
@@ -609,8 +607,8 @@ const ce = {
|
|
|
609
607
|
maxContentLength: -1,
|
|
610
608
|
maxBodyLength: -1,
|
|
611
609
|
env: {
|
|
612
|
-
FormData:
|
|
613
|
-
Blob:
|
|
610
|
+
FormData: O.classes.FormData,
|
|
611
|
+
Blob: O.classes.Blob
|
|
614
612
|
},
|
|
615
613
|
validateStatus: function(t) {
|
|
616
614
|
return t >= 200 && t < 300;
|
|
@@ -623,9 +621,9 @@ const ce = {
|
|
|
623
621
|
}
|
|
624
622
|
};
|
|
625
623
|
l.forEach(["delete", "get", "head", "post", "put", "patch"], (e) => {
|
|
626
|
-
|
|
624
|
+
se.headers[e] = {};
|
|
627
625
|
});
|
|
628
|
-
const
|
|
626
|
+
const Ar = l.toObjectSet([
|
|
629
627
|
"age",
|
|
630
628
|
"authorization",
|
|
631
629
|
"content-length",
|
|
@@ -643,47 +641,47 @@ const Xs = l.toObjectSet([
|
|
|
643
641
|
"referer",
|
|
644
642
|
"retry-after",
|
|
645
643
|
"user-agent"
|
|
646
|
-
]),
|
|
644
|
+
]), Fr = (e) => {
|
|
647
645
|
const t = {};
|
|
648
|
-
let
|
|
646
|
+
let r, s, n;
|
|
649
647
|
return e && e.split(`
|
|
650
648
|
`).forEach(function(o) {
|
|
651
|
-
n = o.indexOf(":"),
|
|
649
|
+
n = o.indexOf(":"), r = o.substring(0, n).trim().toLowerCase(), s = o.substring(n + 1).trim(), !(!r || t[r] && Ar[r]) && (r === "set-cookie" ? t[r] ? t[r].push(s) : t[r] = [s] : t[r] = t[r] ? t[r] + ", " + s : s);
|
|
652
650
|
}), t;
|
|
653
|
-
},
|
|
654
|
-
function
|
|
651
|
+
}, Ie = Symbol("internals");
|
|
652
|
+
function Q(e) {
|
|
655
653
|
return e && String(e).trim().toLowerCase();
|
|
656
654
|
}
|
|
657
|
-
function
|
|
658
|
-
return e === !1 || e == null ? e : l.isArray(e) ? e.map(
|
|
655
|
+
function oe(e) {
|
|
656
|
+
return e === !1 || e == null ? e : l.isArray(e) ? e.map(oe) : String(e);
|
|
659
657
|
}
|
|
660
|
-
function
|
|
661
|
-
const t = /* @__PURE__ */ Object.create(null),
|
|
662
|
-
let
|
|
663
|
-
for (;
|
|
664
|
-
t[
|
|
658
|
+
function Lr(e) {
|
|
659
|
+
const t = /* @__PURE__ */ Object.create(null), r = /([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;
|
|
660
|
+
let s;
|
|
661
|
+
for (; s = r.exec(e); )
|
|
662
|
+
t[s[1]] = s[2];
|
|
665
663
|
return t;
|
|
666
664
|
}
|
|
667
|
-
const
|
|
668
|
-
function
|
|
669
|
-
if (l.isFunction(
|
|
670
|
-
return
|
|
671
|
-
if (n && (t =
|
|
672
|
-
if (l.isString(
|
|
673
|
-
return t.indexOf(
|
|
674
|
-
if (l.isRegExp(
|
|
675
|
-
return
|
|
665
|
+
const Pr = (e) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());
|
|
666
|
+
function we(e, t, r, s, n) {
|
|
667
|
+
if (l.isFunction(s))
|
|
668
|
+
return s.call(this, t, r);
|
|
669
|
+
if (n && (t = r), !!l.isString(t)) {
|
|
670
|
+
if (l.isString(s))
|
|
671
|
+
return t.indexOf(s) !== -1;
|
|
672
|
+
if (l.isRegExp(s))
|
|
673
|
+
return s.test(t);
|
|
676
674
|
}
|
|
677
675
|
}
|
|
678
|
-
function
|
|
679
|
-
return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (t,
|
|
676
|
+
function Br(e) {
|
|
677
|
+
return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (t, r, s) => r.toUpperCase() + s);
|
|
680
678
|
}
|
|
681
|
-
function
|
|
682
|
-
const
|
|
683
|
-
["get", "set", "has"].forEach((
|
|
684
|
-
Object.defineProperty(e,
|
|
679
|
+
function Ur(e, t) {
|
|
680
|
+
const r = l.toCamelCase(" " + t);
|
|
681
|
+
["get", "set", "has"].forEach((s) => {
|
|
682
|
+
Object.defineProperty(e, s + r, {
|
|
685
683
|
value: function(n, i, o) {
|
|
686
|
-
return this[
|
|
684
|
+
return this[s].call(this, t, n, i, o);
|
|
687
685
|
},
|
|
688
686
|
configurable: !0
|
|
689
687
|
});
|
|
@@ -693,102 +691,102 @@ let A = class {
|
|
|
693
691
|
constructor(t) {
|
|
694
692
|
t && this.set(t);
|
|
695
693
|
}
|
|
696
|
-
set(t,
|
|
694
|
+
set(t, r, s) {
|
|
697
695
|
const n = this;
|
|
698
|
-
function i(a, f,
|
|
699
|
-
const
|
|
700
|
-
if (!
|
|
696
|
+
function i(a, f, u) {
|
|
697
|
+
const c = Q(f);
|
|
698
|
+
if (!c)
|
|
701
699
|
throw new Error("header name must be a non-empty string");
|
|
702
|
-
const h = l.findKey(n,
|
|
703
|
-
(!h || n[h] === void 0 ||
|
|
700
|
+
const h = l.findKey(n, c);
|
|
701
|
+
(!h || n[h] === void 0 || u === !0 || u === void 0 && n[h] !== !1) && (n[h || f] = oe(a));
|
|
704
702
|
}
|
|
705
|
-
const o = (a, f) => l.forEach(a, (
|
|
703
|
+
const o = (a, f) => l.forEach(a, (u, c) => i(u, c, f));
|
|
706
704
|
if (l.isPlainObject(t) || t instanceof this.constructor)
|
|
707
|
-
o(t,
|
|
708
|
-
else if (l.isString(t) && (t = t.trim()) && !
|
|
709
|
-
o(
|
|
705
|
+
o(t, r);
|
|
706
|
+
else if (l.isString(t) && (t = t.trim()) && !Pr(t))
|
|
707
|
+
o(Fr(t), r);
|
|
710
708
|
else if (l.isObject(t) && l.isIterable(t)) {
|
|
711
|
-
let a = {}, f,
|
|
712
|
-
for (const
|
|
713
|
-
if (!l.isArray(
|
|
709
|
+
let a = {}, f, u;
|
|
710
|
+
for (const c of t) {
|
|
711
|
+
if (!l.isArray(c))
|
|
714
712
|
throw TypeError("Object iterator must return a key-value pair");
|
|
715
|
-
a[
|
|
713
|
+
a[u = c[0]] = (f = a[u]) ? l.isArray(f) ? [...f, c[1]] : [f, c[1]] : c[1];
|
|
716
714
|
}
|
|
717
|
-
o(a,
|
|
715
|
+
o(a, r);
|
|
718
716
|
} else
|
|
719
|
-
t != null && i(
|
|
717
|
+
t != null && i(r, t, s);
|
|
720
718
|
return this;
|
|
721
719
|
}
|
|
722
|
-
get(t,
|
|
723
|
-
if (t =
|
|
724
|
-
const
|
|
725
|
-
if (
|
|
726
|
-
const n = this[
|
|
727
|
-
if (!
|
|
720
|
+
get(t, r) {
|
|
721
|
+
if (t = Q(t), t) {
|
|
722
|
+
const s = l.findKey(this, t);
|
|
723
|
+
if (s) {
|
|
724
|
+
const n = this[s];
|
|
725
|
+
if (!r)
|
|
728
726
|
return n;
|
|
729
|
-
if (
|
|
730
|
-
return
|
|
731
|
-
if (l.isFunction(
|
|
732
|
-
return
|
|
733
|
-
if (l.isRegExp(
|
|
734
|
-
return
|
|
727
|
+
if (r === !0)
|
|
728
|
+
return Lr(n);
|
|
729
|
+
if (l.isFunction(r))
|
|
730
|
+
return r.call(this, n, s);
|
|
731
|
+
if (l.isRegExp(r))
|
|
732
|
+
return r.exec(n);
|
|
735
733
|
throw new TypeError("parser must be boolean|regexp|function");
|
|
736
734
|
}
|
|
737
735
|
}
|
|
738
736
|
}
|
|
739
|
-
has(t,
|
|
740
|
-
if (t =
|
|
741
|
-
const
|
|
742
|
-
return !!(
|
|
737
|
+
has(t, r) {
|
|
738
|
+
if (t = Q(t), t) {
|
|
739
|
+
const s = l.findKey(this, t);
|
|
740
|
+
return !!(s && this[s] !== void 0 && (!r || we(this, this[s], s, r)));
|
|
743
741
|
}
|
|
744
742
|
return !1;
|
|
745
743
|
}
|
|
746
|
-
delete(t,
|
|
747
|
-
const
|
|
744
|
+
delete(t, r) {
|
|
745
|
+
const s = this;
|
|
748
746
|
let n = !1;
|
|
749
747
|
function i(o) {
|
|
750
|
-
if (o =
|
|
751
|
-
const a = l.findKey(
|
|
752
|
-
a && (!
|
|
748
|
+
if (o = Q(o), o) {
|
|
749
|
+
const a = l.findKey(s, o);
|
|
750
|
+
a && (!r || we(s, s[a], a, r)) && (delete s[a], n = !0);
|
|
753
751
|
}
|
|
754
752
|
}
|
|
755
753
|
return l.isArray(t) ? t.forEach(i) : i(t), n;
|
|
756
754
|
}
|
|
757
755
|
clear(t) {
|
|
758
|
-
const
|
|
759
|
-
let
|
|
760
|
-
for (;
|
|
761
|
-
const i = s
|
|
762
|
-
(!t ||
|
|
756
|
+
const r = Object.keys(this);
|
|
757
|
+
let s = r.length, n = !1;
|
|
758
|
+
for (; s--; ) {
|
|
759
|
+
const i = r[s];
|
|
760
|
+
(!t || we(this, this[i], i, t, !0)) && (delete this[i], n = !0);
|
|
763
761
|
}
|
|
764
762
|
return n;
|
|
765
763
|
}
|
|
766
764
|
normalize(t) {
|
|
767
|
-
const
|
|
765
|
+
const r = this, s = {};
|
|
768
766
|
return l.forEach(this, (n, i) => {
|
|
769
|
-
const o = l.findKey(
|
|
767
|
+
const o = l.findKey(s, i);
|
|
770
768
|
if (o) {
|
|
771
|
-
|
|
769
|
+
r[o] = oe(n), delete r[i];
|
|
772
770
|
return;
|
|
773
771
|
}
|
|
774
|
-
const a = t ?
|
|
775
|
-
a !== i && delete
|
|
772
|
+
const a = t ? Br(i) : String(i).trim();
|
|
773
|
+
a !== i && delete r[i], r[a] = oe(n), s[a] = !0;
|
|
776
774
|
}), this;
|
|
777
775
|
}
|
|
778
776
|
concat(...t) {
|
|
779
777
|
return this.constructor.concat(this, ...t);
|
|
780
778
|
}
|
|
781
779
|
toJSON(t) {
|
|
782
|
-
const
|
|
783
|
-
return l.forEach(this, (
|
|
784
|
-
|
|
785
|
-
}),
|
|
780
|
+
const r = /* @__PURE__ */ Object.create(null);
|
|
781
|
+
return l.forEach(this, (s, n) => {
|
|
782
|
+
s != null && s !== !1 && (r[n] = t && l.isArray(s) ? s.join(", ") : s);
|
|
783
|
+
}), r;
|
|
786
784
|
}
|
|
787
785
|
[Symbol.iterator]() {
|
|
788
786
|
return Object.entries(this.toJSON())[Symbol.iterator]();
|
|
789
787
|
}
|
|
790
788
|
toString() {
|
|
791
|
-
return Object.entries(this.toJSON()).map(([t,
|
|
789
|
+
return Object.entries(this.toJSON()).map(([t, r]) => t + ": " + r).join(`
|
|
792
790
|
`);
|
|
793
791
|
}
|
|
794
792
|
getSetCookie() {
|
|
@@ -800,125 +798,125 @@ let A = class {
|
|
|
800
798
|
static from(t) {
|
|
801
799
|
return t instanceof this ? t : new this(t);
|
|
802
800
|
}
|
|
803
|
-
static concat(t, ...
|
|
804
|
-
const
|
|
805
|
-
return
|
|
801
|
+
static concat(t, ...r) {
|
|
802
|
+
const s = new this(t);
|
|
803
|
+
return r.forEach((n) => s.set(n)), s;
|
|
806
804
|
}
|
|
807
805
|
static accessor(t) {
|
|
808
|
-
const
|
|
806
|
+
const s = (this[Ie] = this[Ie] = {
|
|
809
807
|
accessors: {}
|
|
810
808
|
}).accessors, n = this.prototype;
|
|
811
809
|
function i(o) {
|
|
812
|
-
const a =
|
|
813
|
-
|
|
810
|
+
const a = Q(o);
|
|
811
|
+
s[a] || (Ur(n, o), s[a] = !0);
|
|
814
812
|
}
|
|
815
813
|
return l.isArray(t) ? t.forEach(i) : i(t), this;
|
|
816
814
|
}
|
|
817
815
|
};
|
|
818
816
|
A.accessor(["Content-Type", "Content-Length", "Accept", "Accept-Encoding", "User-Agent", "Authorization"]);
|
|
819
817
|
l.reduceDescriptors(A.prototype, ({ value: e }, t) => {
|
|
820
|
-
let
|
|
818
|
+
let r = t[0].toUpperCase() + t.slice(1);
|
|
821
819
|
return {
|
|
822
820
|
get: () => e,
|
|
823
|
-
set(
|
|
824
|
-
this[
|
|
821
|
+
set(s) {
|
|
822
|
+
this[r] = s;
|
|
825
823
|
}
|
|
826
824
|
};
|
|
827
825
|
});
|
|
828
826
|
l.freezeMethods(A);
|
|
829
|
-
function
|
|
830
|
-
const
|
|
831
|
-
let i =
|
|
827
|
+
function ye(e, t) {
|
|
828
|
+
const r = this || se, s = t || r, n = A.from(s.headers);
|
|
829
|
+
let i = s.data;
|
|
832
830
|
return l.forEach(e, function(a) {
|
|
833
|
-
i = a.call(
|
|
831
|
+
i = a.call(r, i, n.normalize(), t ? t.status : void 0);
|
|
834
832
|
}), n.normalize(), i;
|
|
835
833
|
}
|
|
836
|
-
function
|
|
834
|
+
function mt(e) {
|
|
837
835
|
return !!(e && e.__CANCEL__);
|
|
838
836
|
}
|
|
839
|
-
function
|
|
840
|
-
D.call(this, e ?? "canceled", D.ERR_CANCELED, t,
|
|
837
|
+
function G(e, t, r) {
|
|
838
|
+
D.call(this, e ?? "canceled", D.ERR_CANCELED, t, r), this.name = "CanceledError";
|
|
841
839
|
}
|
|
842
|
-
l.inherits(
|
|
840
|
+
l.inherits(G, D, {
|
|
843
841
|
__CANCEL__: !0
|
|
844
842
|
});
|
|
845
|
-
function
|
|
846
|
-
const
|
|
847
|
-
!
|
|
848
|
-
"Request failed with status code " +
|
|
849
|
-
[D.ERR_BAD_REQUEST, D.ERR_BAD_RESPONSE][Math.floor(
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
843
|
+
function gt(e, t, r) {
|
|
844
|
+
const s = r.config.validateStatus;
|
|
845
|
+
!r.status || !s || s(r.status) ? e(r) : t(new D(
|
|
846
|
+
"Request failed with status code " + r.status,
|
|
847
|
+
[D.ERR_BAD_REQUEST, D.ERR_BAD_RESPONSE][Math.floor(r.status / 100) - 4],
|
|
848
|
+
r.config,
|
|
849
|
+
r.request,
|
|
850
|
+
r
|
|
853
851
|
));
|
|
854
852
|
}
|
|
855
|
-
function
|
|
853
|
+
function jr(e) {
|
|
856
854
|
const t = /^([-+\w]{1,25})(:?\/\/|:)/.exec(e);
|
|
857
855
|
return t && t[1] || "";
|
|
858
856
|
}
|
|
859
|
-
function
|
|
857
|
+
function Vr(e, t) {
|
|
860
858
|
e = e || 10;
|
|
861
|
-
const
|
|
859
|
+
const r = new Array(e), s = new Array(e);
|
|
862
860
|
let n = 0, i = 0, o;
|
|
863
861
|
return t = t !== void 0 ? t : 1e3, function(f) {
|
|
864
|
-
const
|
|
865
|
-
o || (o =
|
|
862
|
+
const u = Date.now(), c = s[i];
|
|
863
|
+
o || (o = u), r[n] = f, s[n] = u;
|
|
866
864
|
let h = i, w = 0;
|
|
867
865
|
for (; h !== n; )
|
|
868
|
-
w +=
|
|
869
|
-
if (n = (n + 1) % e, n === i && (i = (i + 1) % e),
|
|
866
|
+
w += r[h++], h = h % e;
|
|
867
|
+
if (n = (n + 1) % e, n === i && (i = (i + 1) % e), u - o < t)
|
|
870
868
|
return;
|
|
871
|
-
const
|
|
872
|
-
return
|
|
869
|
+
const g = c && u - c;
|
|
870
|
+
return g ? Math.round(w * 1e3 / g) : void 0;
|
|
873
871
|
};
|
|
874
872
|
}
|
|
875
|
-
function
|
|
876
|
-
let
|
|
877
|
-
const o = (
|
|
878
|
-
|
|
873
|
+
function Ir(e, t) {
|
|
874
|
+
let r = 0, s = 1e3 / t, n, i;
|
|
875
|
+
const o = (u, c = Date.now()) => {
|
|
876
|
+
r = c, n = null, i && (clearTimeout(i), i = null), e(...u);
|
|
879
877
|
};
|
|
880
|
-
return [(...
|
|
881
|
-
const
|
|
882
|
-
h >=
|
|
878
|
+
return [(...u) => {
|
|
879
|
+
const c = Date.now(), h = c - r;
|
|
880
|
+
h >= s ? o(u, c) : (n = u, i || (i = setTimeout(() => {
|
|
883
881
|
i = null, o(n);
|
|
884
|
-
},
|
|
882
|
+
}, s - h)));
|
|
885
883
|
}, () => n && o(n)];
|
|
886
884
|
}
|
|
887
|
-
const
|
|
888
|
-
let
|
|
889
|
-
const n =
|
|
890
|
-
return
|
|
891
|
-
const o = i.loaded, a = i.lengthComputable ? i.total : void 0, f = o -
|
|
892
|
-
|
|
885
|
+
const le = (e, t, r = 3) => {
|
|
886
|
+
let s = 0;
|
|
887
|
+
const n = Vr(50, 250);
|
|
888
|
+
return Ir((i) => {
|
|
889
|
+
const o = i.loaded, a = i.lengthComputable ? i.total : void 0, f = o - s, u = n(f), c = o <= a;
|
|
890
|
+
s = o;
|
|
893
891
|
const h = {
|
|
894
892
|
loaded: o,
|
|
895
893
|
total: a,
|
|
896
894
|
progress: a ? o / a : void 0,
|
|
897
895
|
bytes: f,
|
|
898
|
-
rate:
|
|
899
|
-
estimated:
|
|
896
|
+
rate: u || void 0,
|
|
897
|
+
estimated: u && a && c ? (a - o) / u : void 0,
|
|
900
898
|
event: i,
|
|
901
899
|
lengthComputable: a != null,
|
|
902
900
|
[t ? "download" : "upload"]: !0
|
|
903
901
|
};
|
|
904
902
|
e(h);
|
|
905
|
-
},
|
|
906
|
-
},
|
|
907
|
-
const
|
|
908
|
-
return [(
|
|
909
|
-
lengthComputable:
|
|
903
|
+
}, r);
|
|
904
|
+
}, ze = (e, t) => {
|
|
905
|
+
const r = e != null;
|
|
906
|
+
return [(s) => t[0]({
|
|
907
|
+
lengthComputable: r,
|
|
910
908
|
total: e,
|
|
911
|
-
loaded:
|
|
909
|
+
loaded: s
|
|
912
910
|
}), t[1]];
|
|
913
|
-
},
|
|
914
|
-
new URL(
|
|
915
|
-
|
|
916
|
-
) : () => !0,
|
|
911
|
+
}, Me = (e) => (...t) => l.asap(() => e(...t)), zr = O.hasStandardBrowserEnv ? /* @__PURE__ */ ((e, t) => (r) => (r = new URL(r, O.origin), e.protocol === r.protocol && e.host === r.host && (t || e.port === r.port)))(
|
|
912
|
+
new URL(O.origin),
|
|
913
|
+
O.navigator && /(msie|trident)/i.test(O.navigator.userAgent)
|
|
914
|
+
) : () => !0, Mr = O.hasStandardBrowserEnv ? (
|
|
917
915
|
// Standard browser envs support document.cookie
|
|
918
916
|
{
|
|
919
|
-
write(e, t,
|
|
917
|
+
write(e, t, r, s, n, i) {
|
|
920
918
|
const o = [e + "=" + encodeURIComponent(t)];
|
|
921
|
-
l.isNumber(
|
|
919
|
+
l.isNumber(r) && o.push("expires=" + new Date(r).toGMTString()), l.isString(s) && o.push("path=" + s), l.isString(n) && o.push("domain=" + n), i === !0 && o.push("secure"), document.cookie = o.join("; ");
|
|
922
920
|
},
|
|
923
921
|
read(e) {
|
|
924
922
|
const t = document.cookie.match(new RegExp("(^|;\\s*)(" + e + ")=([^;]*)"));
|
|
@@ -940,44 +938,44 @@ const be = (e, t, s = 3) => {
|
|
|
940
938
|
}
|
|
941
939
|
}
|
|
942
940
|
);
|
|
943
|
-
function
|
|
941
|
+
function qr(e) {
|
|
944
942
|
return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(e);
|
|
945
943
|
}
|
|
946
|
-
function
|
|
944
|
+
function Hr(e, t) {
|
|
947
945
|
return t ? e.replace(/\/?\/$/, "") + "/" + t.replace(/^\/+/, "") : e;
|
|
948
946
|
}
|
|
949
|
-
function
|
|
950
|
-
let
|
|
951
|
-
return e && (
|
|
947
|
+
function bt(e, t, r) {
|
|
948
|
+
let s = !qr(t);
|
|
949
|
+
return e && (s || r == !1) ? Hr(e, t) : t;
|
|
952
950
|
}
|
|
953
|
-
const
|
|
954
|
-
function
|
|
951
|
+
const qe = (e) => e instanceof A ? { ...e } : e;
|
|
952
|
+
function K(e, t) {
|
|
955
953
|
t = t || {};
|
|
956
|
-
const
|
|
957
|
-
function
|
|
958
|
-
return l.isPlainObject(
|
|
959
|
-
}
|
|
960
|
-
function n(
|
|
961
|
-
if (l.isUndefined(
|
|
962
|
-
if (!l.isUndefined(
|
|
963
|
-
return
|
|
964
|
-
} else return
|
|
965
|
-
}
|
|
966
|
-
function i(
|
|
967
|
-
if (!l.isUndefined(
|
|
968
|
-
return
|
|
969
|
-
}
|
|
970
|
-
function o(
|
|
971
|
-
if (l.isUndefined(
|
|
972
|
-
if (!l.isUndefined(
|
|
973
|
-
return
|
|
974
|
-
} else return
|
|
975
|
-
}
|
|
976
|
-
function a(
|
|
954
|
+
const r = {};
|
|
955
|
+
function s(u, c, h, w) {
|
|
956
|
+
return l.isPlainObject(u) && l.isPlainObject(c) ? l.merge.call({ caseless: w }, u, c) : l.isPlainObject(c) ? l.merge({}, c) : l.isArray(c) ? c.slice() : c;
|
|
957
|
+
}
|
|
958
|
+
function n(u, c, h, w) {
|
|
959
|
+
if (l.isUndefined(c)) {
|
|
960
|
+
if (!l.isUndefined(u))
|
|
961
|
+
return s(void 0, u, h, w);
|
|
962
|
+
} else return s(u, c, h, w);
|
|
963
|
+
}
|
|
964
|
+
function i(u, c) {
|
|
965
|
+
if (!l.isUndefined(c))
|
|
966
|
+
return s(void 0, c);
|
|
967
|
+
}
|
|
968
|
+
function o(u, c) {
|
|
969
|
+
if (l.isUndefined(c)) {
|
|
970
|
+
if (!l.isUndefined(u))
|
|
971
|
+
return s(void 0, u);
|
|
972
|
+
} else return s(void 0, c);
|
|
973
|
+
}
|
|
974
|
+
function a(u, c, h) {
|
|
977
975
|
if (h in t)
|
|
978
|
-
return
|
|
976
|
+
return s(u, c);
|
|
979
977
|
if (h in e)
|
|
980
|
-
return
|
|
978
|
+
return s(void 0, u);
|
|
981
979
|
}
|
|
982
980
|
const f = {
|
|
983
981
|
url: i,
|
|
@@ -1008,128 +1006,127 @@ function Z(e, t) {
|
|
|
1008
1006
|
socketPath: o,
|
|
1009
1007
|
responseEncoding: o,
|
|
1010
1008
|
validateStatus: a,
|
|
1011
|
-
headers: (
|
|
1009
|
+
headers: (u, c, h) => n(qe(u), qe(c), h, !0)
|
|
1012
1010
|
};
|
|
1013
|
-
return l.forEach(Object.keys({ ...e, ...t }), function(
|
|
1014
|
-
const h = f[
|
|
1015
|
-
l.isUndefined(w) && h !== a || (
|
|
1016
|
-
}),
|
|
1017
|
-
}
|
|
1018
|
-
const
|
|
1019
|
-
const t =
|
|
1020
|
-
let { data:
|
|
1021
|
-
|
|
1011
|
+
return l.forEach(Object.keys({ ...e, ...t }), function(c) {
|
|
1012
|
+
const h = f[c] || n, w = h(e[c], t[c], c);
|
|
1013
|
+
l.isUndefined(w) && h !== a || (r[c] = w);
|
|
1014
|
+
}), r;
|
|
1015
|
+
}
|
|
1016
|
+
const wt = (e) => {
|
|
1017
|
+
const t = K({}, e);
|
|
1018
|
+
let { data: r, withXSRFToken: s, xsrfHeaderName: n, xsrfCookieName: i, headers: o, auth: a } = t;
|
|
1019
|
+
t.headers = o = A.from(o), t.url = ft(bt(t.baseURL, t.url, t.allowAbsoluteUrls), e.params, e.paramsSerializer), a && o.set(
|
|
1022
1020
|
"Authorization",
|
|
1023
1021
|
"Basic " + btoa((a.username || "") + ":" + (a.password ? unescape(encodeURIComponent(a.password)) : ""))
|
|
1024
|
-
)
|
|
1025
|
-
|
|
1022
|
+
);
|
|
1023
|
+
let f;
|
|
1024
|
+
if (l.isFormData(r)) {
|
|
1025
|
+
if (O.hasStandardBrowserEnv || O.hasStandardBrowserWebWorkerEnv)
|
|
1026
1026
|
o.setContentType(void 0);
|
|
1027
|
-
else if (
|
|
1028
|
-
const
|
|
1029
|
-
|
|
1030
|
-
d.includes(u.toLowerCase()) && o.set(u, h);
|
|
1031
|
-
});
|
|
1027
|
+
else if ((f = o.getContentType()) !== !1) {
|
|
1028
|
+
const [u, ...c] = f ? f.split(";").map((h) => h.trim()).filter(Boolean) : [];
|
|
1029
|
+
o.setContentType([u || "multipart/form-data", ...c].join("; "));
|
|
1032
1030
|
}
|
|
1033
1031
|
}
|
|
1034
|
-
if (
|
|
1035
|
-
const
|
|
1036
|
-
|
|
1032
|
+
if (O.hasStandardBrowserEnv && (s && l.isFunction(s) && (s = s(t)), s || s !== !1 && zr(t.url))) {
|
|
1033
|
+
const u = n && i && Mr.read(i);
|
|
1034
|
+
u && o.set(n, u);
|
|
1037
1035
|
}
|
|
1038
1036
|
return t;
|
|
1039
|
-
},
|
|
1040
|
-
return new Promise(function(
|
|
1041
|
-
const n =
|
|
1037
|
+
}, Wr = typeof XMLHttpRequest < "u", Jr = Wr && function(e) {
|
|
1038
|
+
return new Promise(function(r, s) {
|
|
1039
|
+
const n = wt(e);
|
|
1042
1040
|
let i = n.data;
|
|
1043
1041
|
const o = A.from(n.headers).normalize();
|
|
1044
|
-
let { responseType: a, onUploadProgress: f, onDownloadProgress:
|
|
1042
|
+
let { responseType: a, onUploadProgress: f, onDownloadProgress: u } = n, c, h, w, g, d;
|
|
1045
1043
|
function p() {
|
|
1046
|
-
|
|
1044
|
+
g && g(), d && d(), n.cancelToken && n.cancelToken.unsubscribe(c), n.signal && n.signal.removeEventListener("abort", c);
|
|
1047
1045
|
}
|
|
1048
|
-
let
|
|
1049
|
-
|
|
1050
|
-
function
|
|
1051
|
-
if (!
|
|
1046
|
+
let b = new XMLHttpRequest();
|
|
1047
|
+
b.open(n.method.toUpperCase(), n.url, !0), b.timeout = n.timeout;
|
|
1048
|
+
function S() {
|
|
1049
|
+
if (!b)
|
|
1052
1050
|
return;
|
|
1053
1051
|
const y = A.from(
|
|
1054
|
-
"getAllResponseHeaders" in
|
|
1055
|
-
),
|
|
1056
|
-
data: !a || a === "text" || a === "json" ?
|
|
1057
|
-
status:
|
|
1058
|
-
statusText:
|
|
1052
|
+
"getAllResponseHeaders" in b && b.getAllResponseHeaders()
|
|
1053
|
+
), C = {
|
|
1054
|
+
data: !a || a === "text" || a === "json" ? b.responseText : b.response,
|
|
1055
|
+
status: b.status,
|
|
1056
|
+
statusText: b.statusText,
|
|
1059
1057
|
headers: y,
|
|
1060
1058
|
config: e,
|
|
1061
|
-
request:
|
|
1059
|
+
request: b
|
|
1062
1060
|
};
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
}, function(
|
|
1066
|
-
|
|
1067
|
-
},
|
|
1061
|
+
gt(function(q) {
|
|
1062
|
+
r(q), p();
|
|
1063
|
+
}, function(q) {
|
|
1064
|
+
s(q), p();
|
|
1065
|
+
}, C), b = null;
|
|
1068
1066
|
}
|
|
1069
|
-
"onloadend" in
|
|
1070
|
-
!
|
|
1071
|
-
},
|
|
1072
|
-
|
|
1073
|
-
},
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
C,
|
|
1081
|
-
$.clarifyTimeoutError ? D.ETIMEDOUT : D.ECONNABORTED,
|
|
1067
|
+
"onloadend" in b ? b.onloadend = S : b.onreadystatechange = function() {
|
|
1068
|
+
!b || b.readyState !== 4 || b.status === 0 && !(b.responseURL && b.responseURL.indexOf("file:") === 0) || setTimeout(S);
|
|
1069
|
+
}, b.onabort = function() {
|
|
1070
|
+
b && (s(new D("Request aborted", D.ECONNABORTED, e, b)), b = null);
|
|
1071
|
+
}, b.onerror = function() {
|
|
1072
|
+
s(new D("Network Error", D.ERR_NETWORK, e, b)), b = null;
|
|
1073
|
+
}, b.ontimeout = function() {
|
|
1074
|
+
let L = n.timeout ? "timeout of " + n.timeout + "ms exceeded" : "timeout exceeded";
|
|
1075
|
+
const C = n.transitional || ht;
|
|
1076
|
+
n.timeoutErrorMessage && (L = n.timeoutErrorMessage), s(new D(
|
|
1077
|
+
L,
|
|
1078
|
+
C.clarifyTimeoutError ? D.ETIMEDOUT : D.ECONNABORTED,
|
|
1082
1079
|
e,
|
|
1083
|
-
|
|
1084
|
-
)),
|
|
1085
|
-
}, i === void 0 && o.setContentType(null), "setRequestHeader" in
|
|
1086
|
-
|
|
1087
|
-
}), l.isUndefined(n.withCredentials) || (
|
|
1088
|
-
|
|
1089
|
-
}, n.cancelToken && n.cancelToken.subscribe(
|
|
1090
|
-
const
|
|
1091
|
-
if (
|
|
1092
|
-
|
|
1080
|
+
b
|
|
1081
|
+
)), b = null;
|
|
1082
|
+
}, i === void 0 && o.setContentType(null), "setRequestHeader" in b && l.forEach(o.toJSON(), function(L, C) {
|
|
1083
|
+
b.setRequestHeader(C, L);
|
|
1084
|
+
}), l.isUndefined(n.withCredentials) || (b.withCredentials = !!n.withCredentials), a && a !== "json" && (b.responseType = n.responseType), u && ([w, d] = le(u, !0), b.addEventListener("progress", w)), f && b.upload && ([h, g] = le(f), b.upload.addEventListener("progress", h), b.upload.addEventListener("loadend", g)), (n.cancelToken || n.signal) && (c = (y) => {
|
|
1085
|
+
b && (s(!y || y.type ? new G(null, e, b) : y), b.abort(), b = null);
|
|
1086
|
+
}, n.cancelToken && n.cancelToken.subscribe(c), n.signal && (n.signal.aborted ? c() : n.signal.addEventListener("abort", c)));
|
|
1087
|
+
const k = jr(n.url);
|
|
1088
|
+
if (k && O.protocols.indexOf(k) === -1) {
|
|
1089
|
+
s(new D("Unsupported protocol " + k + ":", D.ERR_BAD_REQUEST, e));
|
|
1093
1090
|
return;
|
|
1094
1091
|
}
|
|
1095
|
-
|
|
1092
|
+
b.send(i || null);
|
|
1096
1093
|
});
|
|
1097
|
-
},
|
|
1098
|
-
const { length:
|
|
1099
|
-
if (t ||
|
|
1100
|
-
let
|
|
1101
|
-
const i = function(
|
|
1094
|
+
}, Kr = (e, t) => {
|
|
1095
|
+
const { length: r } = e = e ? e.filter(Boolean) : [];
|
|
1096
|
+
if (t || r) {
|
|
1097
|
+
let s = new AbortController(), n;
|
|
1098
|
+
const i = function(u) {
|
|
1102
1099
|
if (!n) {
|
|
1103
1100
|
n = !0, a();
|
|
1104
|
-
const
|
|
1105
|
-
|
|
1101
|
+
const c = u instanceof Error ? u : this.reason;
|
|
1102
|
+
s.abort(c instanceof D ? c : new G(c instanceof Error ? c.message : c));
|
|
1106
1103
|
}
|
|
1107
1104
|
};
|
|
1108
1105
|
let o = t && setTimeout(() => {
|
|
1109
1106
|
o = null, i(new D(`timeout ${t} of ms exceeded`, D.ETIMEDOUT));
|
|
1110
1107
|
}, t);
|
|
1111
1108
|
const a = () => {
|
|
1112
|
-
e && (o && clearTimeout(o), o = null, e.forEach((
|
|
1113
|
-
|
|
1109
|
+
e && (o && clearTimeout(o), o = null, e.forEach((u) => {
|
|
1110
|
+
u.unsubscribe ? u.unsubscribe(i) : u.removeEventListener("abort", i);
|
|
1114
1111
|
}), e = null);
|
|
1115
1112
|
};
|
|
1116
|
-
e.forEach((
|
|
1117
|
-
const { signal: f } =
|
|
1113
|
+
e.forEach((u) => u.addEventListener("abort", i));
|
|
1114
|
+
const { signal: f } = s;
|
|
1118
1115
|
return f.unsubscribe = () => l.asap(a), f;
|
|
1119
1116
|
}
|
|
1120
|
-
},
|
|
1121
|
-
let
|
|
1122
|
-
if (
|
|
1117
|
+
}, Xr = function* (e, t) {
|
|
1118
|
+
let r = e.byteLength;
|
|
1119
|
+
if (r < t) {
|
|
1123
1120
|
yield e;
|
|
1124
1121
|
return;
|
|
1125
1122
|
}
|
|
1126
|
-
let
|
|
1127
|
-
for (;
|
|
1128
|
-
n =
|
|
1129
|
-
},
|
|
1130
|
-
for await (const
|
|
1131
|
-
yield*
|
|
1132
|
-
},
|
|
1123
|
+
let s = 0, n;
|
|
1124
|
+
for (; s < r; )
|
|
1125
|
+
n = s + t, yield e.slice(s, n), s = n;
|
|
1126
|
+
}, Gr = async function* (e, t) {
|
|
1127
|
+
for await (const r of Qr(e))
|
|
1128
|
+
yield* Xr(r, t);
|
|
1129
|
+
}, Qr = async function* (e) {
|
|
1133
1130
|
if (e[Symbol.asyncIterator]) {
|
|
1134
1131
|
yield* e;
|
|
1135
1132
|
return;
|
|
@@ -1137,35 +1134,35 @@ const At = (e) => {
|
|
|
1137
1134
|
const t = e.getReader();
|
|
1138
1135
|
try {
|
|
1139
1136
|
for (; ; ) {
|
|
1140
|
-
const { done:
|
|
1141
|
-
if (
|
|
1137
|
+
const { done: r, value: s } = await t.read();
|
|
1138
|
+
if (r)
|
|
1142
1139
|
break;
|
|
1143
|
-
yield
|
|
1140
|
+
yield s;
|
|
1144
1141
|
}
|
|
1145
1142
|
} finally {
|
|
1146
1143
|
await t.cancel();
|
|
1147
1144
|
}
|
|
1148
|
-
},
|
|
1149
|
-
const n =
|
|
1145
|
+
}, He = (e, t, r, s) => {
|
|
1146
|
+
const n = Gr(e, t);
|
|
1150
1147
|
let i = 0, o, a = (f) => {
|
|
1151
|
-
o || (o = !0,
|
|
1148
|
+
o || (o = !0, s && s(f));
|
|
1152
1149
|
};
|
|
1153
1150
|
return new ReadableStream({
|
|
1154
1151
|
async pull(f) {
|
|
1155
1152
|
try {
|
|
1156
|
-
const { done:
|
|
1157
|
-
if (
|
|
1153
|
+
const { done: u, value: c } = await n.next();
|
|
1154
|
+
if (u) {
|
|
1158
1155
|
a(), f.close();
|
|
1159
1156
|
return;
|
|
1160
1157
|
}
|
|
1161
|
-
let h =
|
|
1162
|
-
if (
|
|
1158
|
+
let h = c.byteLength;
|
|
1159
|
+
if (r) {
|
|
1163
1160
|
let w = i += h;
|
|
1164
|
-
|
|
1161
|
+
r(w);
|
|
1165
1162
|
}
|
|
1166
|
-
f.enqueue(new Uint8Array(
|
|
1167
|
-
} catch (
|
|
1168
|
-
throw a(
|
|
1163
|
+
f.enqueue(new Uint8Array(c));
|
|
1164
|
+
} catch (u) {
|
|
1165
|
+
throw a(u), u;
|
|
1169
1166
|
}
|
|
1170
1167
|
},
|
|
1171
1168
|
cancel(f) {
|
|
@@ -1174,171 +1171,140 @@ const At = (e) => {
|
|
|
1174
1171
|
}, {
|
|
1175
1172
|
highWaterMark: 2
|
|
1176
1173
|
});
|
|
1177
|
-
},
|
|
1178
|
-
Request: e,
|
|
1179
|
-
Response: t
|
|
1180
|
-
}))(l.global), {
|
|
1181
|
-
ReadableStream: ot,
|
|
1182
|
-
TextEncoder: at
|
|
1183
|
-
} = l.global, lt = (e, ...t) => {
|
|
1174
|
+
}, me = typeof fetch == "function" && typeof Request == "function" && typeof Response == "function", yt = me && typeof ReadableStream == "function", Zr = me && (typeof TextEncoder == "function" ? /* @__PURE__ */ ((e) => (t) => e.encode(t))(new TextEncoder()) : async (e) => new Uint8Array(await new Response(e).arrayBuffer())), xt = (e, ...t) => {
|
|
1184
1175
|
try {
|
|
1185
1176
|
return !!e(...t);
|
|
1186
1177
|
} catch {
|
|
1187
1178
|
return !1;
|
|
1188
1179
|
}
|
|
1189
|
-
},
|
|
1190
|
-
e =
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
|
|
1194
|
-
|
|
1195
|
-
|
|
1196
|
-
|
|
1197
|
-
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
|
|
1206
|
-
}), u = o && a && lt(() => l.isReadableStream(new r("").body)), h = {
|
|
1207
|
-
stream: u && ((c) => c.body)
|
|
1208
|
-
};
|
|
1209
|
-
n && ["text", "arrayBuffer", "blob", "formData", "stream"].forEach((c) => {
|
|
1210
|
-
!h[c] && (h[c] = (p, m) => {
|
|
1211
|
-
let k = p && p[c];
|
|
1212
|
-
if (k)
|
|
1213
|
-
return k.call(p);
|
|
1214
|
-
throw new D(`Response type '${c}' is not supported`, D.ERR_NOT_SUPPORT, m);
|
|
1180
|
+
}, Yr = yt && xt(() => {
|
|
1181
|
+
let e = !1;
|
|
1182
|
+
const t = new Request(O.origin, {
|
|
1183
|
+
body: new ReadableStream(),
|
|
1184
|
+
method: "POST",
|
|
1185
|
+
get duplex() {
|
|
1186
|
+
return e = !0, "half";
|
|
1187
|
+
}
|
|
1188
|
+
}).headers.has("Content-Type");
|
|
1189
|
+
return e && !t;
|
|
1190
|
+
}), We = 64 * 1024, ve = yt && xt(() => l.isReadableStream(new Response("").body)), ce = {
|
|
1191
|
+
stream: ve && ((e) => e.body)
|
|
1192
|
+
};
|
|
1193
|
+
me && ((e) => {
|
|
1194
|
+
["text", "arrayBuffer", "blob", "formData", "stream"].forEach((t) => {
|
|
1195
|
+
!ce[t] && (ce[t] = l.isFunction(e[t]) ? (r) => r[t]() : (r, s) => {
|
|
1196
|
+
throw new D(`Response type '${t}' is not supported`, D.ERR_NOT_SUPPORT, s);
|
|
1215
1197
|
});
|
|
1216
1198
|
});
|
|
1217
|
-
|
|
1218
|
-
|
|
1219
|
-
|
|
1220
|
-
|
|
1221
|
-
|
|
1222
|
-
|
|
1223
|
-
|
|
1199
|
+
})(new Response());
|
|
1200
|
+
const es = async (e) => {
|
|
1201
|
+
if (e == null)
|
|
1202
|
+
return 0;
|
|
1203
|
+
if (l.isBlob(e))
|
|
1204
|
+
return e.size;
|
|
1205
|
+
if (l.isSpecCompliantForm(e))
|
|
1206
|
+
return (await new Request(O.origin, {
|
|
1207
|
+
method: "POST",
|
|
1208
|
+
body: e
|
|
1209
|
+
}).arrayBuffer()).byteLength;
|
|
1210
|
+
if (l.isArrayBufferView(e) || l.isArrayBuffer(e))
|
|
1211
|
+
return e.byteLength;
|
|
1212
|
+
if (l.isURLSearchParams(e) && (e = e + ""), l.isString(e))
|
|
1213
|
+
return (await Zr(e)).byteLength;
|
|
1214
|
+
}, ts = async (e, t) => {
|
|
1215
|
+
const r = l.toFiniteNumber(e.getContentLength());
|
|
1216
|
+
return r ?? es(t);
|
|
1217
|
+
}, rs = me && (async (e) => {
|
|
1218
|
+
let {
|
|
1219
|
+
url: t,
|
|
1220
|
+
method: r,
|
|
1221
|
+
data: s,
|
|
1222
|
+
signal: n,
|
|
1223
|
+
cancelToken: i,
|
|
1224
|
+
timeout: o,
|
|
1225
|
+
onDownloadProgress: a,
|
|
1226
|
+
onUploadProgress: f,
|
|
1227
|
+
responseType: u,
|
|
1228
|
+
headers: c,
|
|
1229
|
+
withCredentials: h = "same-origin",
|
|
1230
|
+
fetchOptions: w
|
|
1231
|
+
} = wt(e);
|
|
1232
|
+
u = u ? (u + "").toLowerCase() : "text";
|
|
1233
|
+
let g = Kr([n, i && i.toAbortSignal()], o), d;
|
|
1234
|
+
const p = g && g.unsubscribe && (() => {
|
|
1235
|
+
g.unsubscribe();
|
|
1236
|
+
});
|
|
1237
|
+
let b;
|
|
1238
|
+
try {
|
|
1239
|
+
if (f && Yr && r !== "get" && r !== "head" && (b = await ts(c, s)) !== 0) {
|
|
1240
|
+
let C = new Request(t, {
|
|
1224
1241
|
method: "POST",
|
|
1225
|
-
body:
|
|
1226
|
-
|
|
1227
|
-
|
|
1228
|
-
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
const m = l.toFiniteNumber(c.getContentLength());
|
|
1233
|
-
return m ?? w(p);
|
|
1234
|
-
};
|
|
1235
|
-
return async (c) => {
|
|
1236
|
-
let {
|
|
1237
|
-
url: p,
|
|
1238
|
-
method: m,
|
|
1239
|
-
data: k,
|
|
1240
|
-
signal: S,
|
|
1241
|
-
cancelToken: y,
|
|
1242
|
-
timeout: C,
|
|
1243
|
-
onDownloadProgress: $,
|
|
1244
|
-
onUploadProgress: J,
|
|
1245
|
-
responseType: L,
|
|
1246
|
-
headers: ke,
|
|
1247
|
-
withCredentials: ue = "same-origin",
|
|
1248
|
-
fetchOptions: ze
|
|
1249
|
-
} = At(c), Me = t || fetch;
|
|
1250
|
-
L = L ? (L + "").toLowerCase() : "text";
|
|
1251
|
-
let de = ur([S, y && y.toAbortSignal()], C), re = null;
|
|
1252
|
-
const K = de && de.unsubscribe && (() => {
|
|
1253
|
-
de.unsubscribe();
|
|
1254
|
-
});
|
|
1255
|
-
let He;
|
|
1256
|
-
try {
|
|
1257
|
-
if (J && d && m !== "get" && m !== "head" && (He = await b(ke, k)) !== 0) {
|
|
1258
|
-
let q = new s(p, {
|
|
1259
|
-
method: "POST",
|
|
1260
|
-
body: k,
|
|
1261
|
-
duplex: "half"
|
|
1262
|
-
}), Y;
|
|
1263
|
-
if (l.isFormData(k) && (Y = q.headers.get("content-type")) && ke.setContentType(Y), q.body) {
|
|
1264
|
-
const [ve, fe] = tt(
|
|
1265
|
-
He,
|
|
1266
|
-
be(st(J))
|
|
1267
|
-
);
|
|
1268
|
-
k = nt(q.body, it, ve, fe);
|
|
1269
|
-
}
|
|
1270
|
-
}
|
|
1271
|
-
l.isString(ue) || (ue = ue ? "include" : "omit");
|
|
1272
|
-
const j = i && "credentials" in s.prototype, qe = {
|
|
1273
|
-
...ze,
|
|
1274
|
-
signal: de,
|
|
1275
|
-
method: m.toUpperCase(),
|
|
1276
|
-
headers: ke.normalize().toJSON(),
|
|
1277
|
-
body: k,
|
|
1278
|
-
duplex: "half",
|
|
1279
|
-
credentials: j ? ue : void 0
|
|
1280
|
-
};
|
|
1281
|
-
re = i && new s(p, qe);
|
|
1282
|
-
let H = await (i ? Me(re, ze) : Me(p, qe));
|
|
1283
|
-
const We = u && (L === "stream" || L === "response");
|
|
1284
|
-
if (u && ($ || We && K)) {
|
|
1285
|
-
const q = {};
|
|
1286
|
-
["status", "statusText", "headers"].forEach((Je) => {
|
|
1287
|
-
q[Je] = H[Je];
|
|
1288
|
-
});
|
|
1289
|
-
const Y = l.toFiniteNumber(H.headers.get("content-length")), [ve, fe] = $ && tt(
|
|
1290
|
-
Y,
|
|
1291
|
-
be(st($), !0)
|
|
1292
|
-
) || [];
|
|
1293
|
-
H = new r(
|
|
1294
|
-
nt(H.body, it, ve, () => {
|
|
1295
|
-
fe && fe(), K && K();
|
|
1296
|
-
}),
|
|
1297
|
-
q
|
|
1242
|
+
body: s,
|
|
1243
|
+
duplex: "half"
|
|
1244
|
+
}), z;
|
|
1245
|
+
if (l.isFormData(s) && (z = C.headers.get("content-type")) && c.setContentType(z), C.body) {
|
|
1246
|
+
const [q, ne] = ze(
|
|
1247
|
+
b,
|
|
1248
|
+
le(Me(f))
|
|
1298
1249
|
);
|
|
1250
|
+
s = He(C.body, We, q, ne);
|
|
1299
1251
|
}
|
|
1300
|
-
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
|
|
1252
|
+
}
|
|
1253
|
+
l.isString(h) || (h = h ? "include" : "omit");
|
|
1254
|
+
const S = "credentials" in Request.prototype;
|
|
1255
|
+
d = new Request(t, {
|
|
1256
|
+
...w,
|
|
1257
|
+
signal: g,
|
|
1258
|
+
method: r.toUpperCase(),
|
|
1259
|
+
headers: c.normalize().toJSON(),
|
|
1260
|
+
body: s,
|
|
1261
|
+
duplex: "half",
|
|
1262
|
+
credentials: S ? h : void 0
|
|
1263
|
+
});
|
|
1264
|
+
let k = await fetch(d, w);
|
|
1265
|
+
const y = ve && (u === "stream" || u === "response");
|
|
1266
|
+
if (ve && (a || y && p)) {
|
|
1267
|
+
const C = {};
|
|
1268
|
+
["status", "statusText", "headers"].forEach((Fe) => {
|
|
1269
|
+
C[Fe] = k[Fe];
|
|
1311
1270
|
});
|
|
1312
|
-
|
|
1313
|
-
|
|
1314
|
-
|
|
1315
|
-
|
|
1316
|
-
|
|
1317
|
-
|
|
1318
|
-
|
|
1271
|
+
const z = l.toFiniteNumber(k.headers.get("content-length")), [q, ne] = a && ze(
|
|
1272
|
+
z,
|
|
1273
|
+
le(Me(a), !0)
|
|
1274
|
+
) || [];
|
|
1275
|
+
k = new Response(
|
|
1276
|
+
He(k.body, We, q, () => {
|
|
1277
|
+
ne && ne(), p && p();
|
|
1278
|
+
}),
|
|
1279
|
+
C
|
|
1280
|
+
);
|
|
1319
1281
|
}
|
|
1320
|
-
|
|
1321
|
-
|
|
1322
|
-
|
|
1323
|
-
|
|
1324
|
-
|
|
1325
|
-
|
|
1326
|
-
|
|
1327
|
-
|
|
1328
|
-
|
|
1329
|
-
|
|
1330
|
-
|
|
1331
|
-
|
|
1332
|
-
}
|
|
1333
|
-
|
|
1334
|
-
|
|
1335
|
-
|
|
1336
|
-
|
|
1337
|
-
|
|
1338
|
-
|
|
1282
|
+
u = u || "text";
|
|
1283
|
+
let L = await ce[l.findKey(ce, u) || "text"](k, e);
|
|
1284
|
+
return !y && p && p(), await new Promise((C, z) => {
|
|
1285
|
+
gt(C, z, {
|
|
1286
|
+
data: L,
|
|
1287
|
+
headers: A.from(k.headers),
|
|
1288
|
+
status: k.status,
|
|
1289
|
+
statusText: k.statusText,
|
|
1290
|
+
config: e,
|
|
1291
|
+
request: d
|
|
1292
|
+
});
|
|
1293
|
+
});
|
|
1294
|
+
} catch (S) {
|
|
1295
|
+
throw p && p(), S && S.name === "TypeError" && /Load failed|fetch/i.test(S.message) ? Object.assign(
|
|
1296
|
+
new D("Network Error", D.ERR_NETWORK, e, d),
|
|
1297
|
+
{
|
|
1298
|
+
cause: S.cause || S
|
|
1299
|
+
}
|
|
1300
|
+
) : D.from(S, S && S.code, e, d);
|
|
1339
1301
|
}
|
|
1302
|
+
}), Ee = {
|
|
1303
|
+
http: br,
|
|
1304
|
+
xhr: Jr,
|
|
1305
|
+
fetch: rs
|
|
1340
1306
|
};
|
|
1341
|
-
l.forEach(
|
|
1307
|
+
l.forEach(Ee, (e, t) => {
|
|
1342
1308
|
if (e) {
|
|
1343
1309
|
try {
|
|
1344
1310
|
Object.defineProperty(e, "name", { value: t });
|
|
@@ -1347,113 +1313,113 @@ l.forEach(Ae, (e, t) => {
|
|
|
1347
1313
|
Object.defineProperty(e, "adapterName", { value: t });
|
|
1348
1314
|
}
|
|
1349
1315
|
});
|
|
1350
|
-
const
|
|
1351
|
-
getAdapter: (e
|
|
1316
|
+
const Je = (e) => `- ${e}`, ss = (e) => l.isFunction(e) || e === null || e === !1, _t = {
|
|
1317
|
+
getAdapter: (e) => {
|
|
1352
1318
|
e = l.isArray(e) ? e : [e];
|
|
1353
|
-
const { length:
|
|
1354
|
-
let r,
|
|
1355
|
-
const
|
|
1356
|
-
for (let
|
|
1357
|
-
r = e[
|
|
1358
|
-
let
|
|
1359
|
-
if (
|
|
1360
|
-
throw new D(`Unknown adapter '${
|
|
1361
|
-
if (
|
|
1319
|
+
const { length: t } = e;
|
|
1320
|
+
let r, s;
|
|
1321
|
+
const n = {};
|
|
1322
|
+
for (let i = 0; i < t; i++) {
|
|
1323
|
+
r = e[i];
|
|
1324
|
+
let o;
|
|
1325
|
+
if (s = r, !ss(r) && (s = Ee[(o = String(r)).toLowerCase()], s === void 0))
|
|
1326
|
+
throw new D(`Unknown adapter '${o}'`);
|
|
1327
|
+
if (s)
|
|
1362
1328
|
break;
|
|
1363
|
-
|
|
1329
|
+
n[o || "#" + i] = s;
|
|
1364
1330
|
}
|
|
1365
|
-
if (!
|
|
1366
|
-
const
|
|
1367
|
-
([
|
|
1331
|
+
if (!s) {
|
|
1332
|
+
const i = Object.entries(n).map(
|
|
1333
|
+
([a, f]) => `adapter ${a} ` + (f === !1 ? "is not supported by the environment" : "is not available in the build")
|
|
1368
1334
|
);
|
|
1369
|
-
let
|
|
1370
|
-
` +
|
|
1371
|
-
`) : " " +
|
|
1335
|
+
let o = t ? i.length > 1 ? `since :
|
|
1336
|
+
` + i.map(Je).join(`
|
|
1337
|
+
`) : " " + Je(i[0]) : "as no adapter specified";
|
|
1372
1338
|
throw new D(
|
|
1373
|
-
"There is no suitable adapter to dispatch the request " +
|
|
1339
|
+
"There is no suitable adapter to dispatch the request " + o,
|
|
1374
1340
|
"ERR_NOT_SUPPORT"
|
|
1375
1341
|
);
|
|
1376
1342
|
}
|
|
1377
|
-
return
|
|
1343
|
+
return s;
|
|
1378
1344
|
},
|
|
1379
|
-
adapters:
|
|
1345
|
+
adapters: Ee
|
|
1380
1346
|
};
|
|
1381
|
-
function
|
|
1347
|
+
function xe(e) {
|
|
1382
1348
|
if (e.cancelToken && e.cancelToken.throwIfRequested(), e.signal && e.signal.aborted)
|
|
1383
|
-
throw new
|
|
1349
|
+
throw new G(null, e);
|
|
1384
1350
|
}
|
|
1385
|
-
function
|
|
1386
|
-
return
|
|
1351
|
+
function Ke(e) {
|
|
1352
|
+
return xe(e), e.headers = A.from(e.headers), e.data = ye.call(
|
|
1387
1353
|
e,
|
|
1388
1354
|
e.transformRequest
|
|
1389
|
-
), ["post", "put", "patch"].indexOf(e.method) !== -1 && e.headers.setContentType("application/x-www-form-urlencoded", !1),
|
|
1390
|
-
return
|
|
1355
|
+
), ["post", "put", "patch"].indexOf(e.method) !== -1 && e.headers.setContentType("application/x-www-form-urlencoded", !1), _t.getAdapter(e.adapter || se.adapter)(e).then(function(s) {
|
|
1356
|
+
return xe(e), s.data = ye.call(
|
|
1391
1357
|
e,
|
|
1392
1358
|
e.transformResponse,
|
|
1393
|
-
|
|
1394
|
-
),
|
|
1395
|
-
}, function(
|
|
1396
|
-
return
|
|
1359
|
+
s
|
|
1360
|
+
), s.headers = A.from(s.headers), s;
|
|
1361
|
+
}, function(s) {
|
|
1362
|
+
return mt(s) || (xe(e), s && s.response && (s.response.data = ye.call(
|
|
1397
1363
|
e,
|
|
1398
1364
|
e.transformResponse,
|
|
1399
|
-
|
|
1400
|
-
),
|
|
1365
|
+
s.response
|
|
1366
|
+
), s.response.headers = A.from(s.response.headers))), Promise.reject(s);
|
|
1401
1367
|
});
|
|
1402
1368
|
}
|
|
1403
|
-
const
|
|
1369
|
+
const Dt = "1.11.0", ge = {};
|
|
1404
1370
|
["object", "boolean", "number", "function", "string", "symbol"].forEach((e, t) => {
|
|
1405
|
-
|
|
1406
|
-
return typeof
|
|
1371
|
+
ge[e] = function(s) {
|
|
1372
|
+
return typeof s === e || "a" + (t < 1 ? "n " : " ") + e;
|
|
1407
1373
|
};
|
|
1408
1374
|
});
|
|
1409
|
-
const
|
|
1410
|
-
|
|
1375
|
+
const Xe = {};
|
|
1376
|
+
ge.transitional = function(t, r, s) {
|
|
1411
1377
|
function n(i, o) {
|
|
1412
|
-
return "[Axios v" +
|
|
1378
|
+
return "[Axios v" + Dt + "] Transitional option '" + i + "'" + o + (s ? ". " + s : "");
|
|
1413
1379
|
}
|
|
1414
1380
|
return (i, o, a) => {
|
|
1415
1381
|
if (t === !1)
|
|
1416
1382
|
throw new D(
|
|
1417
|
-
n(o, " has been removed" + (
|
|
1383
|
+
n(o, " has been removed" + (r ? " in " + r : "")),
|
|
1418
1384
|
D.ERR_DEPRECATED
|
|
1419
1385
|
);
|
|
1420
|
-
return
|
|
1386
|
+
return r && !Xe[o] && (Xe[o] = !0, console.warn(
|
|
1421
1387
|
n(
|
|
1422
1388
|
o,
|
|
1423
|
-
" has been deprecated since v" +
|
|
1389
|
+
" has been deprecated since v" + r + " and will be removed in the near future"
|
|
1424
1390
|
)
|
|
1425
1391
|
)), t ? t(i, o, a) : !0;
|
|
1426
1392
|
};
|
|
1427
1393
|
};
|
|
1428
|
-
|
|
1429
|
-
return (
|
|
1394
|
+
ge.spelling = function(t) {
|
|
1395
|
+
return (r, s) => (console.warn(`${s} is likely a misspelling of ${t}`), !0);
|
|
1430
1396
|
};
|
|
1431
|
-
function
|
|
1397
|
+
function ns(e, t, r) {
|
|
1432
1398
|
if (typeof e != "object")
|
|
1433
1399
|
throw new D("options must be an object", D.ERR_BAD_OPTION_VALUE);
|
|
1434
|
-
const
|
|
1435
|
-
let n =
|
|
1400
|
+
const s = Object.keys(e);
|
|
1401
|
+
let n = s.length;
|
|
1436
1402
|
for (; n-- > 0; ) {
|
|
1437
|
-
const i =
|
|
1403
|
+
const i = s[n], o = t[i];
|
|
1438
1404
|
if (o) {
|
|
1439
1405
|
const a = e[i], f = a === void 0 || o(a, i, e);
|
|
1440
1406
|
if (f !== !0)
|
|
1441
1407
|
throw new D("option " + i + " must be " + f, D.ERR_BAD_OPTION_VALUE);
|
|
1442
1408
|
continue;
|
|
1443
1409
|
}
|
|
1444
|
-
if (
|
|
1410
|
+
if (r !== !0)
|
|
1445
1411
|
throw new D("Unknown option " + i, D.ERR_BAD_OPTION);
|
|
1446
1412
|
}
|
|
1447
1413
|
}
|
|
1448
|
-
const
|
|
1449
|
-
assertOptions:
|
|
1450
|
-
validators:
|
|
1451
|
-
},
|
|
1452
|
-
let
|
|
1414
|
+
const ae = {
|
|
1415
|
+
assertOptions: ns,
|
|
1416
|
+
validators: ge
|
|
1417
|
+
}, U = ae.validators;
|
|
1418
|
+
let W = class {
|
|
1453
1419
|
constructor(t) {
|
|
1454
1420
|
this.defaults = t || {}, this.interceptors = {
|
|
1455
|
-
request: new
|
|
1456
|
-
response: new
|
|
1421
|
+
request: new Ve(),
|
|
1422
|
+
response: new Ve()
|
|
1457
1423
|
};
|
|
1458
1424
|
}
|
|
1459
1425
|
/**
|
|
@@ -1464,106 +1430,106 @@ let G = class {
|
|
|
1464
1430
|
*
|
|
1465
1431
|
* @returns {Promise} The Promise to be fulfilled
|
|
1466
1432
|
*/
|
|
1467
|
-
async request(t,
|
|
1433
|
+
async request(t, r) {
|
|
1468
1434
|
try {
|
|
1469
|
-
return await this._request(t,
|
|
1470
|
-
} catch (
|
|
1471
|
-
if (
|
|
1435
|
+
return await this._request(t, r);
|
|
1436
|
+
} catch (s) {
|
|
1437
|
+
if (s instanceof Error) {
|
|
1472
1438
|
let n = {};
|
|
1473
1439
|
Error.captureStackTrace ? Error.captureStackTrace(n) : n = new Error();
|
|
1474
1440
|
const i = n.stack ? n.stack.replace(/^.+\n/, "") : "";
|
|
1475
1441
|
try {
|
|
1476
|
-
|
|
1477
|
-
` + i) :
|
|
1442
|
+
s.stack ? i && !String(s.stack).endsWith(i.replace(/^.+\n.+\n/, "")) && (s.stack += `
|
|
1443
|
+
` + i) : s.stack = i;
|
|
1478
1444
|
} catch {
|
|
1479
1445
|
}
|
|
1480
1446
|
}
|
|
1481
|
-
throw
|
|
1447
|
+
throw s;
|
|
1482
1448
|
}
|
|
1483
1449
|
}
|
|
1484
|
-
_request(t,
|
|
1485
|
-
typeof t == "string" ? (
|
|
1486
|
-
const { transitional:
|
|
1487
|
-
|
|
1488
|
-
silentJSONParsing:
|
|
1489
|
-
forcedJSONParsing:
|
|
1490
|
-
clarifyTimeoutError:
|
|
1491
|
-
}, !1), n != null && (l.isFunction(n) ?
|
|
1450
|
+
_request(t, r) {
|
|
1451
|
+
typeof t == "string" ? (r = r || {}, r.url = t) : r = t || {}, r = K(this.defaults, r);
|
|
1452
|
+
const { transitional: s, paramsSerializer: n, headers: i } = r;
|
|
1453
|
+
s !== void 0 && ae.assertOptions(s, {
|
|
1454
|
+
silentJSONParsing: U.transitional(U.boolean),
|
|
1455
|
+
forcedJSONParsing: U.transitional(U.boolean),
|
|
1456
|
+
clarifyTimeoutError: U.transitional(U.boolean)
|
|
1457
|
+
}, !1), n != null && (l.isFunction(n) ? r.paramsSerializer = {
|
|
1492
1458
|
serialize: n
|
|
1493
|
-
} :
|
|
1494
|
-
encode:
|
|
1495
|
-
serialize:
|
|
1496
|
-
}, !0)),
|
|
1497
|
-
baseUrl:
|
|
1498
|
-
withXsrfToken:
|
|
1499
|
-
}, !0),
|
|
1459
|
+
} : ae.assertOptions(n, {
|
|
1460
|
+
encode: U.function,
|
|
1461
|
+
serialize: U.function
|
|
1462
|
+
}, !0)), r.allowAbsoluteUrls !== void 0 || (this.defaults.allowAbsoluteUrls !== void 0 ? r.allowAbsoluteUrls = this.defaults.allowAbsoluteUrls : r.allowAbsoluteUrls = !0), ae.assertOptions(r, {
|
|
1463
|
+
baseUrl: U.spelling("baseURL"),
|
|
1464
|
+
withXsrfToken: U.spelling("withXSRFToken")
|
|
1465
|
+
}, !0), r.method = (r.method || this.defaults.method || "get").toLowerCase();
|
|
1500
1466
|
let o = i && l.merge(
|
|
1501
1467
|
i.common,
|
|
1502
|
-
i[
|
|
1468
|
+
i[r.method]
|
|
1503
1469
|
);
|
|
1504
1470
|
i && l.forEach(
|
|
1505
1471
|
["delete", "get", "head", "post", "put", "patch", "common"],
|
|
1506
|
-
(
|
|
1507
|
-
delete i[
|
|
1472
|
+
(d) => {
|
|
1473
|
+
delete i[d];
|
|
1508
1474
|
}
|
|
1509
|
-
),
|
|
1475
|
+
), r.headers = A.concat(o, i);
|
|
1510
1476
|
const a = [];
|
|
1511
1477
|
let f = !0;
|
|
1512
1478
|
this.interceptors.request.forEach(function(p) {
|
|
1513
|
-
typeof p.runWhen == "function" && p.runWhen(
|
|
1479
|
+
typeof p.runWhen == "function" && p.runWhen(r) === !1 || (f = f && p.synchronous, a.unshift(p.fulfilled, p.rejected));
|
|
1514
1480
|
});
|
|
1515
|
-
const
|
|
1481
|
+
const u = [];
|
|
1516
1482
|
this.interceptors.response.forEach(function(p) {
|
|
1517
|
-
|
|
1483
|
+
u.push(p.fulfilled, p.rejected);
|
|
1518
1484
|
});
|
|
1519
|
-
let
|
|
1485
|
+
let c, h = 0, w;
|
|
1520
1486
|
if (!f) {
|
|
1521
|
-
const
|
|
1522
|
-
for (
|
|
1523
|
-
|
|
1524
|
-
return
|
|
1487
|
+
const d = [Ke.bind(this), void 0];
|
|
1488
|
+
for (d.unshift(...a), d.push(...u), w = d.length, c = Promise.resolve(r); h < w; )
|
|
1489
|
+
c = c.then(d[h++], d[h++]);
|
|
1490
|
+
return c;
|
|
1525
1491
|
}
|
|
1526
1492
|
w = a.length;
|
|
1527
|
-
let
|
|
1528
|
-
for (; h < w; ) {
|
|
1529
|
-
const
|
|
1493
|
+
let g = r;
|
|
1494
|
+
for (h = 0; h < w; ) {
|
|
1495
|
+
const d = a[h++], p = a[h++];
|
|
1530
1496
|
try {
|
|
1531
|
-
|
|
1532
|
-
} catch (
|
|
1533
|
-
p.call(this,
|
|
1497
|
+
g = d(g);
|
|
1498
|
+
} catch (b) {
|
|
1499
|
+
p.call(this, b);
|
|
1534
1500
|
break;
|
|
1535
1501
|
}
|
|
1536
1502
|
}
|
|
1537
1503
|
try {
|
|
1538
|
-
|
|
1539
|
-
} catch (
|
|
1540
|
-
return Promise.reject(
|
|
1504
|
+
c = Ke.call(this, g);
|
|
1505
|
+
} catch (d) {
|
|
1506
|
+
return Promise.reject(d);
|
|
1541
1507
|
}
|
|
1542
|
-
for (h = 0, w =
|
|
1543
|
-
|
|
1544
|
-
return
|
|
1508
|
+
for (h = 0, w = u.length; h < w; )
|
|
1509
|
+
c = c.then(u[h++], u[h++]);
|
|
1510
|
+
return c;
|
|
1545
1511
|
}
|
|
1546
1512
|
getUri(t) {
|
|
1547
|
-
t =
|
|
1548
|
-
const
|
|
1549
|
-
return
|
|
1513
|
+
t = K(this.defaults, t);
|
|
1514
|
+
const r = bt(t.baseURL, t.url, t.allowAbsoluteUrls);
|
|
1515
|
+
return ft(r, t.params, t.paramsSerializer);
|
|
1550
1516
|
}
|
|
1551
1517
|
};
|
|
1552
1518
|
l.forEach(["delete", "get", "head", "options"], function(t) {
|
|
1553
|
-
|
|
1554
|
-
return this.request(
|
|
1519
|
+
W.prototype[t] = function(r, s) {
|
|
1520
|
+
return this.request(K(s || {}, {
|
|
1555
1521
|
method: t,
|
|
1556
|
-
url:
|
|
1557
|
-
data: (
|
|
1522
|
+
url: r,
|
|
1523
|
+
data: (s || {}).data
|
|
1558
1524
|
}));
|
|
1559
1525
|
};
|
|
1560
1526
|
});
|
|
1561
1527
|
l.forEach(["post", "put", "patch"], function(t) {
|
|
1562
|
-
function s
|
|
1528
|
+
function r(s) {
|
|
1563
1529
|
return function(i, o, a) {
|
|
1564
|
-
return this.request(
|
|
1530
|
+
return this.request(K(a || {}, {
|
|
1565
1531
|
method: t,
|
|
1566
|
-
headers:
|
|
1532
|
+
headers: s ? {
|
|
1567
1533
|
"Content-Type": "multipart/form-data"
|
|
1568
1534
|
} : {},
|
|
1569
1535
|
url: i,
|
|
@@ -1571,33 +1537,33 @@ l.forEach(["post", "put", "patch"], function(t) {
|
|
|
1571
1537
|
}));
|
|
1572
1538
|
};
|
|
1573
1539
|
}
|
|
1574
|
-
|
|
1540
|
+
W.prototype[t] = r(), W.prototype[t + "Form"] = r(!0);
|
|
1575
1541
|
});
|
|
1576
|
-
let
|
|
1542
|
+
let is = class kt {
|
|
1577
1543
|
constructor(t) {
|
|
1578
1544
|
if (typeof t != "function")
|
|
1579
1545
|
throw new TypeError("executor must be a function.");
|
|
1580
|
-
let
|
|
1546
|
+
let r;
|
|
1581
1547
|
this.promise = new Promise(function(i) {
|
|
1582
|
-
|
|
1548
|
+
r = i;
|
|
1583
1549
|
});
|
|
1584
|
-
const
|
|
1550
|
+
const s = this;
|
|
1585
1551
|
this.promise.then((n) => {
|
|
1586
|
-
if (!
|
|
1587
|
-
let i =
|
|
1552
|
+
if (!s._listeners) return;
|
|
1553
|
+
let i = s._listeners.length;
|
|
1588
1554
|
for (; i-- > 0; )
|
|
1589
|
-
|
|
1590
|
-
|
|
1555
|
+
s._listeners[i](n);
|
|
1556
|
+
s._listeners = null;
|
|
1591
1557
|
}), this.promise.then = (n) => {
|
|
1592
1558
|
let i;
|
|
1593
1559
|
const o = new Promise((a) => {
|
|
1594
|
-
|
|
1560
|
+
s.subscribe(a), i = a;
|
|
1595
1561
|
}).then(n);
|
|
1596
1562
|
return o.cancel = function() {
|
|
1597
|
-
|
|
1563
|
+
s.unsubscribe(i);
|
|
1598
1564
|
}, o;
|
|
1599
1565
|
}, t(function(i, o, a) {
|
|
1600
|
-
|
|
1566
|
+
s.reason || (s.reason = new G(i, o, a), r(s.reason));
|
|
1601
1567
|
});
|
|
1602
1568
|
}
|
|
1603
1569
|
/**
|
|
@@ -1623,14 +1589,14 @@ let yr = class Bt {
|
|
|
1623
1589
|
unsubscribe(t) {
|
|
1624
1590
|
if (!this._listeners)
|
|
1625
1591
|
return;
|
|
1626
|
-
const
|
|
1627
|
-
|
|
1592
|
+
const r = this._listeners.indexOf(t);
|
|
1593
|
+
r !== -1 && this._listeners.splice(r, 1);
|
|
1628
1594
|
}
|
|
1629
1595
|
toAbortSignal() {
|
|
1630
|
-
const t = new AbortController(),
|
|
1631
|
-
t.abort(
|
|
1596
|
+
const t = new AbortController(), r = (s) => {
|
|
1597
|
+
t.abort(s);
|
|
1632
1598
|
};
|
|
1633
|
-
return this.subscribe(
|
|
1599
|
+
return this.subscribe(r), t.signal.unsubscribe = () => this.unsubscribe(r), t.signal;
|
|
1634
1600
|
}
|
|
1635
1601
|
/**
|
|
1636
1602
|
* Returns an object that contains a new `CancelToken` and a function that, when called,
|
|
@@ -1639,22 +1605,22 @@ let yr = class Bt {
|
|
|
1639
1605
|
static source() {
|
|
1640
1606
|
let t;
|
|
1641
1607
|
return {
|
|
1642
|
-
token: new
|
|
1608
|
+
token: new kt(function(n) {
|
|
1643
1609
|
t = n;
|
|
1644
1610
|
}),
|
|
1645
1611
|
cancel: t
|
|
1646
1612
|
};
|
|
1647
1613
|
}
|
|
1648
1614
|
};
|
|
1649
|
-
function
|
|
1650
|
-
return function(
|
|
1651
|
-
return e.apply(null,
|
|
1615
|
+
function os(e) {
|
|
1616
|
+
return function(r) {
|
|
1617
|
+
return e.apply(null, r);
|
|
1652
1618
|
};
|
|
1653
1619
|
}
|
|
1654
|
-
function
|
|
1620
|
+
function as(e) {
|
|
1655
1621
|
return l.isObject(e) && e.isAxiosError === !0;
|
|
1656
1622
|
}
|
|
1657
|
-
const
|
|
1623
|
+
const Ce = {
|
|
1658
1624
|
Continue: 100,
|
|
1659
1625
|
SwitchingProtocols: 101,
|
|
1660
1626
|
Processing: 102,
|
|
@@ -1719,54 +1685,54 @@ const Pe = {
|
|
|
1719
1685
|
NotExtended: 510,
|
|
1720
1686
|
NetworkAuthenticationRequired: 511
|
|
1721
1687
|
};
|
|
1722
|
-
Object.entries(
|
|
1723
|
-
|
|
1688
|
+
Object.entries(Ce).forEach(([e, t]) => {
|
|
1689
|
+
Ce[t] = e;
|
|
1724
1690
|
});
|
|
1725
|
-
function
|
|
1726
|
-
const t = new
|
|
1727
|
-
return l.extend(
|
|
1728
|
-
return
|
|
1729
|
-
},
|
|
1730
|
-
}
|
|
1731
|
-
const v =
|
|
1732
|
-
v.Axios =
|
|
1733
|
-
v.CanceledError =
|
|
1734
|
-
v.CancelToken =
|
|
1735
|
-
v.isCancel =
|
|
1736
|
-
v.VERSION =
|
|
1737
|
-
v.toFormData =
|
|
1691
|
+
function St(e) {
|
|
1692
|
+
const t = new W(e), r = et(W.prototype.request, t);
|
|
1693
|
+
return l.extend(r, W.prototype, t, { allOwnKeys: !0 }), l.extend(r, t, null, { allOwnKeys: !0 }), r.create = function(n) {
|
|
1694
|
+
return St(K(e, n));
|
|
1695
|
+
}, r;
|
|
1696
|
+
}
|
|
1697
|
+
const v = St(se);
|
|
1698
|
+
v.Axios = W;
|
|
1699
|
+
v.CanceledError = G;
|
|
1700
|
+
v.CancelToken = is;
|
|
1701
|
+
v.isCancel = mt;
|
|
1702
|
+
v.VERSION = Dt;
|
|
1703
|
+
v.toFormData = pe;
|
|
1738
1704
|
v.AxiosError = D;
|
|
1739
1705
|
v.Cancel = v.CanceledError;
|
|
1740
1706
|
v.all = function(t) {
|
|
1741
1707
|
return Promise.all(t);
|
|
1742
1708
|
};
|
|
1743
|
-
v.spread =
|
|
1744
|
-
v.isAxiosError =
|
|
1745
|
-
v.mergeConfig =
|
|
1709
|
+
v.spread = os;
|
|
1710
|
+
v.isAxiosError = as;
|
|
1711
|
+
v.mergeConfig = K;
|
|
1746
1712
|
v.AxiosHeaders = A;
|
|
1747
|
-
v.formToJSON = (e) =>
|
|
1748
|
-
v.getAdapter =
|
|
1749
|
-
v.HttpStatusCode =
|
|
1713
|
+
v.formToJSON = (e) => pt(l.isHTMLForm(e) ? new FormData(e) : e);
|
|
1714
|
+
v.getAdapter = _t.getAdapter;
|
|
1715
|
+
v.HttpStatusCode = Ce;
|
|
1750
1716
|
v.default = v;
|
|
1751
1717
|
const {
|
|
1752
|
-
Axios:
|
|
1753
|
-
AxiosError:
|
|
1754
|
-
CanceledError:
|
|
1755
|
-
isCancel:
|
|
1756
|
-
CancelToken:
|
|
1757
|
-
VERSION:
|
|
1758
|
-
all:
|
|
1759
|
-
Cancel:
|
|
1760
|
-
isAxiosError:
|
|
1761
|
-
spread:
|
|
1762
|
-
toFormData:
|
|
1763
|
-
AxiosHeaders:
|
|
1764
|
-
HttpStatusCode:
|
|
1765
|
-
formToJSON:
|
|
1766
|
-
getAdapter:
|
|
1767
|
-
mergeConfig:
|
|
1718
|
+
Axios: Vi,
|
|
1719
|
+
AxiosError: Ii,
|
|
1720
|
+
CanceledError: zi,
|
|
1721
|
+
isCancel: Mi,
|
|
1722
|
+
CancelToken: qi,
|
|
1723
|
+
VERSION: Hi,
|
|
1724
|
+
all: Wi,
|
|
1725
|
+
Cancel: Ji,
|
|
1726
|
+
isAxiosError: Ki,
|
|
1727
|
+
spread: Xi,
|
|
1728
|
+
toFormData: Gi,
|
|
1729
|
+
AxiosHeaders: Qi,
|
|
1730
|
+
HttpStatusCode: Zi,
|
|
1731
|
+
formToJSON: Yi,
|
|
1732
|
+
getAdapter: eo,
|
|
1733
|
+
mergeConfig: to
|
|
1768
1734
|
} = v;
|
|
1769
|
-
class
|
|
1735
|
+
class ls {
|
|
1770
1736
|
static getTooltipOptions(t = !0) {
|
|
1771
1737
|
return {
|
|
1772
1738
|
show: t,
|
|
@@ -1779,7 +1745,7 @@ class Dr {
|
|
|
1779
1745
|
};
|
|
1780
1746
|
}
|
|
1781
1747
|
}
|
|
1782
|
-
class
|
|
1748
|
+
class ue {
|
|
1783
1749
|
static getLabelOptions(t = {}) {
|
|
1784
1750
|
return {
|
|
1785
1751
|
show: (t == null ? void 0 : t.show_label) || (t == null ? void 0 : t.show) || !1,
|
|
@@ -1796,7 +1762,7 @@ class we {
|
|
|
1796
1762
|
};
|
|
1797
1763
|
}
|
|
1798
1764
|
}
|
|
1799
|
-
const
|
|
1765
|
+
const cs = {
|
|
1800
1766
|
show_label: !1,
|
|
1801
1767
|
show_legend: !1,
|
|
1802
1768
|
label: null,
|
|
@@ -1805,24 +1771,24 @@ const Sr = {
|
|
|
1805
1771
|
color: null,
|
|
1806
1772
|
title: null
|
|
1807
1773
|
};
|
|
1808
|
-
function
|
|
1774
|
+
function us() {
|
|
1809
1775
|
const e = "0123456789ABCDEF";
|
|
1810
1776
|
let t = "#";
|
|
1811
|
-
for (let
|
|
1777
|
+
for (let r = 0; r < 6; r += 1)
|
|
1812
1778
|
t += e[Math.floor(Math.random() * 16)];
|
|
1813
1779
|
return t;
|
|
1814
1780
|
}
|
|
1815
|
-
function
|
|
1816
|
-
var
|
|
1781
|
+
function Y(e = cs) {
|
|
1782
|
+
var r;
|
|
1817
1783
|
const t = {
|
|
1818
1784
|
label: {
|
|
1819
1785
|
show: e == null ? void 0 : e.show_label,
|
|
1820
|
-
formatter: (e == null ? void 0 : e.formatter) || ((
|
|
1786
|
+
formatter: (e == null ? void 0 : e.formatter) || ((s) => V(s)),
|
|
1821
1787
|
...(e == null ? void 0 : e.label) || {}
|
|
1822
1788
|
},
|
|
1823
1789
|
legend: {
|
|
1824
1790
|
...(e == null ? void 0 : e.legend) || {},
|
|
1825
|
-
[((
|
|
1791
|
+
[((r = e == null ? void 0 : e.legend) == null ? void 0 : r.position) || "bottom"]: "0",
|
|
1826
1792
|
show: (e == null ? void 0 : e.show_legend) || !1
|
|
1827
1793
|
},
|
|
1828
1794
|
barWidth: "70%",
|
|
@@ -1833,7 +1799,7 @@ function ie(e = Sr) {
|
|
|
1833
1799
|
};
|
|
1834
1800
|
return (e != null && e.colors || e != null && e.color) && (t.color = (e == null ? void 0 : e.colors) || (e == null ? void 0 : e.color) || null), t;
|
|
1835
1801
|
}
|
|
1836
|
-
function
|
|
1802
|
+
function Ge(e) {
|
|
1837
1803
|
return {
|
|
1838
1804
|
color: "#9ca3af",
|
|
1839
1805
|
fontSize: 10,
|
|
@@ -1841,13 +1807,13 @@ function ft(e) {
|
|
|
1841
1807
|
fontWeight: 400,
|
|
1842
1808
|
label: e == null ? void 0 : e.label,
|
|
1843
1809
|
show: !0,
|
|
1844
|
-
formatter: (e == null ? void 0 : e.formatter) || ((
|
|
1810
|
+
formatter: (e == null ? void 0 : e.formatter) || ((r) => V(r)),
|
|
1845
1811
|
margin: (e == null ? void 0 : e.margin) || 7,
|
|
1846
1812
|
interval: (e == null ? void 0 : e.interval) || "auto",
|
|
1847
1813
|
rotate: (e == null ? void 0 : e.rotate) || 0
|
|
1848
1814
|
};
|
|
1849
1815
|
}
|
|
1850
|
-
const
|
|
1816
|
+
const Qe = [
|
|
1851
1817
|
"#d3c7e6",
|
|
1852
1818
|
"#bedae3",
|
|
1853
1819
|
"#f8e9cb",
|
|
@@ -1858,7 +1824,7 @@ const ht = [
|
|
|
1858
1824
|
"#fff7c5",
|
|
1859
1825
|
"#d8ffc0",
|
|
1860
1826
|
"#d4f7ff"
|
|
1861
|
-
],
|
|
1827
|
+
], M = {
|
|
1862
1828
|
props: [
|
|
1863
1829
|
"source",
|
|
1864
1830
|
"style",
|
|
@@ -1906,10 +1872,10 @@ const ht = [
|
|
|
1906
1872
|
this.widgetInstance && this.widgetInstance.resize();
|
|
1907
1873
|
},
|
|
1908
1874
|
async getDataFromURL(e) {
|
|
1909
|
-
var t,
|
|
1875
|
+
var t, r, s, n;
|
|
1910
1876
|
try {
|
|
1911
1877
|
const i = await v.get(e);
|
|
1912
|
-
this.sourceData = ((t = i.data) == null ? void 0 : t.source) || [], this.$emit("update:widgetData", i.data), this.dimensions = Object.keys(((
|
|
1878
|
+
this.sourceData = ((t = i.data) == null ? void 0 : t.source) || [], this.$emit("update:widgetData", i.data), this.dimensions = Object.keys(((r = this.sourceData) == null ? void 0 : r[0]) || {}), this.titleCharts = this.style ? this.style : ((s = i.data) == null ? void 0 : s.title) || "", this.styleData = ((n = i.data) == null ? void 0 : n.style) || {};
|
|
1913
1879
|
} catch (i) {
|
|
1914
1880
|
const o = { message: "Дані не знайдено", title: "Помилка!", type: "error", status: 400, id: this.widgetName };
|
|
1915
1881
|
(i == null ? void 0 : i.status) == "404" && (o.status = 404, o.message = "Дані не знайдено"), (i == null ? void 0 : i.status) == "400" && (o.message = "Перевірте налаштування або зверніться до адміністратора"), (i == null ? void 0 : i.status) == "500" && (o.message = "Сталася помилка сервера"), this.$emit("update:widgetData", o);
|
|
@@ -1924,7 +1890,7 @@ const ht = [
|
|
|
1924
1890
|
formatDate(e) {
|
|
1925
1891
|
const t = new Date(e);
|
|
1926
1892
|
if (isNaN(t)) return e;
|
|
1927
|
-
const
|
|
1893
|
+
const r = String(t.getDate()).padStart(2, "0"), n = [
|
|
1928
1894
|
"січня",
|
|
1929
1895
|
"лютого",
|
|
1930
1896
|
"березня",
|
|
@@ -1938,7 +1904,7 @@ const ht = [
|
|
|
1938
1904
|
"листопада",
|
|
1939
1905
|
"грудня"
|
|
1940
1906
|
][t.getMonth()], i = t.getFullYear();
|
|
1941
|
-
return `${
|
|
1907
|
+
return `${r} ${n} ${i}`;
|
|
1942
1908
|
},
|
|
1943
1909
|
async getData() {
|
|
1944
1910
|
var e;
|
|
@@ -1954,11 +1920,11 @@ const ht = [
|
|
|
1954
1920
|
console.error(t);
|
|
1955
1921
|
}
|
|
1956
1922
|
},
|
|
1957
|
-
async initChart(e, t,
|
|
1958
|
-
var
|
|
1923
|
+
async initChart(e, t, r) {
|
|
1924
|
+
var s, n, i, o, a, f, u;
|
|
1959
1925
|
this.widgetInstance && this.widgetInstance.clear();
|
|
1960
1926
|
try {
|
|
1961
|
-
const
|
|
1927
|
+
const c = this.$refs.chart, h = echarts == null ? void 0 : echarts.init(c), w = {
|
|
1962
1928
|
tooltip: {
|
|
1963
1929
|
trigger: "axis",
|
|
1964
1930
|
axisPointer: { type: "shadow" },
|
|
@@ -1966,94 +1932,94 @@ const ht = [
|
|
|
1966
1932
|
shadowColor: "transparent",
|
|
1967
1933
|
padding: [0, 0, 0, 0],
|
|
1968
1934
|
borderWidth: 0,
|
|
1969
|
-
formatter: (
|
|
1970
|
-
var
|
|
1971
|
-
const
|
|
1972
|
-
let
|
|
1935
|
+
formatter: (g) => {
|
|
1936
|
+
var S;
|
|
1937
|
+
const d = (S = g[0]) == null ? void 0 : S.axisValue;
|
|
1938
|
+
let b = `
|
|
1973
1939
|
<div style="background-color: rgba(255, 255, 255, 0.7)" class="border border-gray-200 text-gray-800 rounded-lg shadow-md dark:bg-neutral-800 dark:border-neutral-700 min-w-28">
|
|
1974
1940
|
<div class="font-semibold text-sm border-b border-solid border-gray-200 text-gray-800 rounded-t-lg dark:bg-neutral-800 dark:border-neutral-700 dark:text-neutral-200 px-2 py-1">
|
|
1975
|
-
${
|
|
1941
|
+
${d ? this.formatDate(d) : "N/A"}
|
|
1976
1942
|
</div>
|
|
1977
1943
|
`;
|
|
1978
|
-
return
|
|
1979
|
-
|
|
1944
|
+
return g.forEach((k) => {
|
|
1945
|
+
b += `
|
|
1980
1946
|
<div class="flex justify-between items-center text-xs px-2 py-0.5 text-gray-500 dark:text-neutral-400">
|
|
1981
1947
|
<span class="flex items-center">
|
|
1982
|
-
<span class="w-2.5 h-2.5 me-1.5 rounded-sm" style="background-color: ${
|
|
1983
|
-
<span class="font-medium mr-[6px]">${(
|
|
1948
|
+
<span class="w-2.5 h-2.5 me-1.5 rounded-sm" style="background-color: ${k.color};"></span>
|
|
1949
|
+
<span class="font-medium mr-[6px]">${(k == null ? void 0 : k.seriesName) === "metric" ? "Значення" : k == null ? void 0 : k.seriesName}</span>
|
|
1984
1950
|
</span>
|
|
1985
|
-
<span>${this.getMetricValue(
|
|
1951
|
+
<span>${this.getMetricValue(k == null ? void 0 : k.data)}</span>
|
|
1986
1952
|
</div>
|
|
1987
1953
|
`;
|
|
1988
|
-
}),
|
|
1954
|
+
}), b += "</div>", b;
|
|
1989
1955
|
}
|
|
1990
1956
|
},
|
|
1991
1957
|
xAxis: {
|
|
1992
1958
|
data: t != null && t.length ? t : null,
|
|
1993
1959
|
type: t ? "category" : "value",
|
|
1994
|
-
name: ((n = (
|
|
1960
|
+
name: ((n = (s = this.styleData) == null ? void 0 : s.x_axis) == null ? void 0 : n.name) || "",
|
|
1995
1961
|
axisLabel: {
|
|
1996
|
-
...
|
|
1997
|
-
formatter: (
|
|
1998
|
-
var p,
|
|
1999
|
-
const
|
|
2000
|
-
return ((
|
|
1962
|
+
...Ge((i = this.styleData) == null ? void 0 : i.x_axis),
|
|
1963
|
+
formatter: (g) => {
|
|
1964
|
+
var p, b;
|
|
1965
|
+
const d = this.formatDate(g);
|
|
1966
|
+
return ((b = (p = this.styleData) == null ? void 0 : p.x_axis) == null ? void 0 : b.overflow) === "ellipsis" && d.length > 10 ? `${d.slice(0, 10)}...` : d;
|
|
2001
1967
|
}
|
|
2002
1968
|
}
|
|
2003
1969
|
},
|
|
2004
1970
|
yAxis: {
|
|
2005
|
-
data:
|
|
2006
|
-
type:
|
|
1971
|
+
data: r != null && r.length ? r : null,
|
|
1972
|
+
type: r ? "category" : "value",
|
|
2007
1973
|
name: ((a = (o = this.styleData) == null ? void 0 : o.y_axis) == null ? void 0 : a.name) || "",
|
|
2008
|
-
axisLabel:
|
|
1974
|
+
axisLabel: Ge((f = this.styleData) == null ? void 0 : f.y_axis)
|
|
2009
1975
|
},
|
|
2010
1976
|
series: e != null && e.length ? e : null,
|
|
2011
|
-
...
|
|
1977
|
+
...Y(this.styleData),
|
|
2012
1978
|
grid: {
|
|
2013
1979
|
bottom: "0%",
|
|
2014
1980
|
right: "0%",
|
|
2015
1981
|
left: "0%",
|
|
2016
1982
|
top: "20px",
|
|
2017
1983
|
containLabel: !0,
|
|
2018
|
-
...((
|
|
1984
|
+
...((u = this.styleData) == null ? void 0 : u.grid) || {}
|
|
2019
1985
|
}
|
|
2020
1986
|
};
|
|
2021
1987
|
await h.setOption(w), h.resize(), this.widgetInstance = h, this.$emit("update:currentWidget", h);
|
|
2022
|
-
} catch (
|
|
2023
|
-
console.error(
|
|
1988
|
+
} catch (c) {
|
|
1989
|
+
console.error(c);
|
|
2024
1990
|
}
|
|
2025
1991
|
},
|
|
2026
1992
|
async setSeriesOption(e, t) {
|
|
2027
|
-
const
|
|
1993
|
+
const r = e.getOption(), { series: s = [] } = r, n = s.map((i) => ({
|
|
2028
1994
|
...i,
|
|
2029
1995
|
...t
|
|
2030
1996
|
}));
|
|
2031
1997
|
e.setOption({
|
|
2032
|
-
...
|
|
1998
|
+
...r,
|
|
2033
1999
|
series: n
|
|
2034
2000
|
});
|
|
2035
2001
|
},
|
|
2036
2002
|
async changeOptionsByName(e, t) {
|
|
2037
|
-
const
|
|
2038
|
-
if (!s) return null;
|
|
2039
|
-
const r = echarts.getInstanceByDom(s);
|
|
2003
|
+
const r = document.getElementById(e);
|
|
2040
2004
|
if (!r) return null;
|
|
2041
|
-
const
|
|
2042
|
-
|
|
2005
|
+
const s = echarts.getInstanceByDom(r);
|
|
2006
|
+
if (!s) return null;
|
|
2007
|
+
const n = s.getOption();
|
|
2008
|
+
t.seriesOptions && this.setSeriesOption(s, t.seriesOptions), s.setOption({
|
|
2043
2009
|
...n,
|
|
2044
2010
|
...t.options,
|
|
2045
2011
|
tooltip: {
|
|
2046
|
-
...
|
|
2012
|
+
...ls.getTooltipOptions(t.options.tooltip.show)
|
|
2047
2013
|
}
|
|
2048
2014
|
});
|
|
2049
2015
|
},
|
|
2050
2016
|
async changeData(e) {
|
|
2051
2017
|
var t;
|
|
2052
2018
|
try {
|
|
2053
|
-
let
|
|
2054
|
-
(t = e == null ? void 0 : e.granularity) != null && t.length && (
|
|
2055
|
-
} catch (
|
|
2056
|
-
console.error(
|
|
2019
|
+
let r = this.dashboard ? `${this.prefix || ""}/bi-data?dashboard=${this.dashboard}&widget=${this.widget}` : `${this.prefix || ""}/bi-data?&widget=${this.widget}`;
|
|
2020
|
+
(t = e == null ? void 0 : e.granularity) != null && t.length && (r += `&granularity=${e.granularity}`), e != null && e.metrics && (r += `&metrics=${e.metrics}`), this.getDataFromURL(r);
|
|
2021
|
+
} catch (r) {
|
|
2022
|
+
console.error(r);
|
|
2057
2023
|
}
|
|
2058
2024
|
},
|
|
2059
2025
|
async setFilter(e) {
|
|
@@ -2064,17 +2030,17 @@ const ht = [
|
|
|
2064
2030
|
this.styleData[e] = t, this.onChangedData();
|
|
2065
2031
|
},
|
|
2066
2032
|
getMetricValue(e) {
|
|
2067
|
-
var
|
|
2033
|
+
var s;
|
|
2068
2034
|
const t = (e == null ? void 0 : e.metric) || e;
|
|
2069
|
-
return parseFloat(t) ? (
|
|
2035
|
+
return parseFloat(t) ? (s = V(t, { notation: "standard" })) == null ? void 0 : s.replaceAll(
|
|
2070
2036
|
",",
|
|
2071
2037
|
" "
|
|
2072
2038
|
) : t;
|
|
2073
2039
|
}
|
|
2074
2040
|
}
|
|
2075
|
-
},
|
|
2041
|
+
}, ds = {
|
|
2076
2042
|
name: "VsBar",
|
|
2077
|
-
mixins: [
|
|
2043
|
+
mixins: [M],
|
|
2078
2044
|
data() {
|
|
2079
2045
|
return {
|
|
2080
2046
|
resizeObserver: null
|
|
@@ -2090,8 +2056,8 @@ const ht = [
|
|
|
2090
2056
|
this.getData(), this.onChangedData();
|
|
2091
2057
|
const e = (t = this.$refs) == null ? void 0 : t.chart;
|
|
2092
2058
|
e && (this.resizeObserver = new ResizeObserver(() => {
|
|
2093
|
-
var
|
|
2094
|
-
this.widgetInstance && ((
|
|
2059
|
+
var r;
|
|
2060
|
+
this.widgetInstance && ((r = this.widgetInstance) == null || r.resize());
|
|
2095
2061
|
}), this.resizeObserver.observe(e));
|
|
2096
2062
|
},
|
|
2097
2063
|
unmounted() {
|
|
@@ -2102,15 +2068,15 @@ const ht = [
|
|
|
2102
2068
|
try {
|
|
2103
2069
|
if (this.sourceData) {
|
|
2104
2070
|
await this.$nextTick();
|
|
2105
|
-
const { series: e, xs: t, ys:
|
|
2106
|
-
e && (this == null || this.initChart(e, t,
|
|
2071
|
+
const { series: e, xs: t, ys: r } = this.prepareData();
|
|
2072
|
+
e && (this == null || this.initChart(e, t, r));
|
|
2107
2073
|
}
|
|
2108
2074
|
} catch (e) {
|
|
2109
2075
|
console.error(e);
|
|
2110
2076
|
}
|
|
2111
2077
|
},
|
|
2112
2078
|
prepareData() {
|
|
2113
|
-
var e, t,
|
|
2079
|
+
var e, t, r, s, n, i;
|
|
2114
2080
|
try {
|
|
2115
2081
|
if (!((e = this.sourceData) != null && e.length))
|
|
2116
2082
|
return { series: [], xs: [], ys: void 0 };
|
|
@@ -2120,26 +2086,26 @@ const ht = [
|
|
|
2120
2086
|
)
|
|
2121
2087
|
);
|
|
2122
2088
|
let a;
|
|
2123
|
-
this.dimensions[0].includes("date") ? a = o.map((w) =>
|
|
2124
|
-
let f,
|
|
2125
|
-
((t = this.styleData) == null ? void 0 : t.horizontal) === !0 ?
|
|
2126
|
-
const
|
|
2089
|
+
this.dimensions[0].includes("date") ? a = o.map((w) => Te(w)) : a = [...o];
|
|
2090
|
+
let f, u;
|
|
2091
|
+
((t = this.styleData) == null ? void 0 : t.horizontal) === !0 ? u = [...a] : f = [...a];
|
|
2092
|
+
const c = this.sourceData.filter(
|
|
2127
2093
|
(w) => parseFloat(w[this.dimensions[1]]) && w[this.dimensions[0]]
|
|
2128
2094
|
).map((w) => parseFloat(w[this.dimensions[1]]));
|
|
2129
2095
|
let h;
|
|
2130
|
-
return ((
|
|
2131
|
-
name:
|
|
2096
|
+
return ((r = this.styleData) == null ? void 0 : r.stack) !== !1 ? h = this.prepareStackData() : ((s = this.styleData) == null ? void 0 : s.negative_waterfall) === !0 ? h = this.prepareNegativeWaterfall() : ((n = this.styleData) == null ? void 0 : n.waterfall) === !0 ? h = this.prepareWaterfallData(c) : ((i = this.styleData) == null ? void 0 : i.accumulative) === !0 ? h = this.prepareAccumulative(c) : h = this.dimensions.slice(1).map((g, d) => ({
|
|
2097
|
+
name: g,
|
|
2132
2098
|
type: "bar",
|
|
2133
|
-
stack: `a${
|
|
2134
|
-
data: this.sourceData.filter((p) => parseFloat(p[
|
|
2135
|
-
})), { series: h, xs: f, ys:
|
|
2099
|
+
stack: `a${d}`,
|
|
2100
|
+
data: this.sourceData.filter((p) => parseFloat(p[g]) && g).map((p) => parseFloat(p[g]))
|
|
2101
|
+
})), { series: h, xs: f, ys: u };
|
|
2136
2102
|
} catch (o) {
|
|
2137
2103
|
return console.error(o), { series: [], xs: [], ys: [] };
|
|
2138
2104
|
}
|
|
2139
2105
|
},
|
|
2140
2106
|
prepareWaterfallData(e) {
|
|
2141
2107
|
let t = e.reduce((i, o) => i + o, 0);
|
|
2142
|
-
const
|
|
2108
|
+
const r = [t, ...e], s = r.map((i, o) => {
|
|
2143
2109
|
if (o === 0) return 0;
|
|
2144
2110
|
const a = t - i;
|
|
2145
2111
|
return t -= i, a >= 0 ? a : 0;
|
|
@@ -2152,7 +2118,7 @@ const ht = [
|
|
|
2152
2118
|
borderColor: "transparent",
|
|
2153
2119
|
color: "transparent"
|
|
2154
2120
|
},
|
|
2155
|
-
data:
|
|
2121
|
+
data: s,
|
|
2156
2122
|
tooltip: {
|
|
2157
2123
|
show: !1
|
|
2158
2124
|
}
|
|
@@ -2161,16 +2127,16 @@ const ht = [
|
|
|
2161
2127
|
name: this.title ? this.title : this.dimensions[0],
|
|
2162
2128
|
type: "bar",
|
|
2163
2129
|
stack: "Total",
|
|
2164
|
-
data:
|
|
2130
|
+
data: r
|
|
2165
2131
|
}
|
|
2166
2132
|
];
|
|
2167
2133
|
},
|
|
2168
2134
|
prepareStackData() {
|
|
2169
|
-
return this.dimensions.slice(1).map((
|
|
2170
|
-
name:
|
|
2135
|
+
return this.dimensions.slice(1).map((r) => ({
|
|
2136
|
+
name: r,
|
|
2171
2137
|
type: "bar",
|
|
2172
2138
|
stack: "a",
|
|
2173
|
-
data: this.sourceData.filter((
|
|
2139
|
+
data: this.sourceData.filter((s) => parseFloat(s[r]) && r).map((s) => parseFloat(s[r]))
|
|
2174
2140
|
}));
|
|
2175
2141
|
},
|
|
2176
2142
|
prepareNegativeWaterfall() {
|
|
@@ -2179,10 +2145,10 @@ const ht = [
|
|
|
2179
2145
|
), t = this.sourceData.map(
|
|
2180
2146
|
(i) => Number.isNaN(i[this.dimensions[2]]) ? 0 : Number(i[this.dimensions[2]])
|
|
2181
2147
|
);
|
|
2182
|
-
let
|
|
2183
|
-
const
|
|
2184
|
-
const a =
|
|
2185
|
-
return
|
|
2148
|
+
let r = 0;
|
|
2149
|
+
const s = e.map((i, o) => {
|
|
2150
|
+
const a = r;
|
|
2151
|
+
return r += Number.isNaN(i) ? 0 : i, o === 0 && (r -= Number.isNaN(t[o]) ? 0 : t[o]), r -= Number.isNaN(t[o + 1]) ? 0 : t[o + 1], a >= 0 ? a : 0;
|
|
2186
2152
|
});
|
|
2187
2153
|
return [
|
|
2188
2154
|
{
|
|
@@ -2192,7 +2158,7 @@ const ht = [
|
|
|
2192
2158
|
borderColor: "transparent",
|
|
2193
2159
|
color: "transparent"
|
|
2194
2160
|
},
|
|
2195
|
-
data:
|
|
2161
|
+
data: s,
|
|
2196
2162
|
tooltip: {
|
|
2197
2163
|
show: !1
|
|
2198
2164
|
}
|
|
@@ -2213,37 +2179,37 @@ const ht = [
|
|
|
2213
2179
|
},
|
|
2214
2180
|
prepareAccumulative(e) {
|
|
2215
2181
|
let t = 0;
|
|
2216
|
-
const
|
|
2182
|
+
const r = e.map((n) => (t += n, t));
|
|
2217
2183
|
return [
|
|
2218
2184
|
{
|
|
2219
2185
|
name: this.titleCharts,
|
|
2220
2186
|
type: "bar",
|
|
2221
2187
|
stack: "Total",
|
|
2222
|
-
data:
|
|
2188
|
+
data: r
|
|
2223
2189
|
}
|
|
2224
2190
|
];
|
|
2225
2191
|
}
|
|
2226
2192
|
}
|
|
2227
|
-
},
|
|
2228
|
-
const
|
|
2229
|
-
for (const [
|
|
2230
|
-
s
|
|
2231
|
-
return
|
|
2232
|
-
},
|
|
2233
|
-
function
|
|
2193
|
+
}, R = (e, t) => {
|
|
2194
|
+
const r = e.__vccOpts || e;
|
|
2195
|
+
for (const [s, n] of t)
|
|
2196
|
+
r[s] = n;
|
|
2197
|
+
return r;
|
|
2198
|
+
}, fs = ["id"];
|
|
2199
|
+
function hs(e, t, r, s, n, i) {
|
|
2234
2200
|
return x(), _("div", {
|
|
2235
2201
|
id: i.uniqueID,
|
|
2236
2202
|
ref: "chart",
|
|
2237
2203
|
class: "h-full w-full min-h-[200px]"
|
|
2238
|
-
}, null, 8,
|
|
2204
|
+
}, null, 8, fs);
|
|
2239
2205
|
}
|
|
2240
|
-
const
|
|
2206
|
+
const ps = /* @__PURE__ */ R(ds, [["render", hs]]), ms = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
2241
2207
|
__proto__: null,
|
|
2242
|
-
default:
|
|
2243
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
2208
|
+
default: ps
|
|
2209
|
+
}, Symbol.toStringTag, { value: "Module" })), gs = {
|
|
2244
2210
|
name: "VsPie",
|
|
2245
2211
|
props: ["currentWidget"],
|
|
2246
|
-
mixins: [
|
|
2212
|
+
mixins: [M],
|
|
2247
2213
|
data() {
|
|
2248
2214
|
return {
|
|
2249
2215
|
chartInstance: null,
|
|
@@ -2258,11 +2224,11 @@ const Or = /* @__PURE__ */ O(vr, [["render", Cr]]), Rr = /* @__PURE__ */ Object.
|
|
|
2258
2224
|
}
|
|
2259
2225
|
},
|
|
2260
2226
|
async mounted() {
|
|
2261
|
-
var
|
|
2227
|
+
var r;
|
|
2262
2228
|
await this.$nextTick(), await this.getData();
|
|
2263
2229
|
const { series: e } = this.prepareData() || {};
|
|
2264
2230
|
e && this.initChart(e);
|
|
2265
|
-
const t = (
|
|
2231
|
+
const t = (r = this.$refs) == null ? void 0 : r.chart;
|
|
2266
2232
|
t && (this.resizeObserver = new ResizeObserver(() => {
|
|
2267
2233
|
this.chartInstance && this.chartInstance.resize();
|
|
2268
2234
|
}), this.resizeObserver.observe(t));
|
|
@@ -2276,47 +2242,47 @@ const Or = /* @__PURE__ */ O(vr, [["render", Cr]]), Rr = /* @__PURE__ */ Object.
|
|
|
2276
2242
|
onChangedData() {
|
|
2277
2243
|
try {
|
|
2278
2244
|
if (this.sourceData) {
|
|
2279
|
-
const { series: e, xs: t, ys:
|
|
2280
|
-
e && this.initChart(e, t,
|
|
2245
|
+
const { series: e, xs: t, ys: r } = this.prepareData();
|
|
2246
|
+
e && this.initChart(e, t, r);
|
|
2281
2247
|
}
|
|
2282
2248
|
} catch (e) {
|
|
2283
2249
|
console.error(e);
|
|
2284
2250
|
}
|
|
2285
2251
|
},
|
|
2286
2252
|
buildTooltipForDonut(e, t) {
|
|
2287
|
-
const { name:
|
|
2253
|
+
const { name: r, value: s, percent: n } = e;
|
|
2288
2254
|
return `
|
|
2289
2255
|
<div style="background-color:${t[0]}; font-size:12px; font-family:Helvetica, Arial, sans-serif; color:#ffff; padding:5px; border-radius:5px;">
|
|
2290
|
-
${
|
|
2256
|
+
${r == null ? void 0 : r.replace("null", "Не визначено")}: ${V(s)} (${n}%)
|
|
2291
2257
|
</div>`;
|
|
2292
2258
|
},
|
|
2293
2259
|
prepareData() {
|
|
2294
|
-
var e, t,
|
|
2260
|
+
var e, t, r, s, n, i;
|
|
2295
2261
|
try {
|
|
2296
2262
|
if (this.styleData = this.styleData || {}, !((e = this.sourceData) != null && e.length))
|
|
2297
2263
|
return console.warn("No source data available"), null;
|
|
2298
2264
|
const o = Array.from(
|
|
2299
2265
|
new Set(
|
|
2300
|
-
(this.sourceData || []).map((
|
|
2266
|
+
(this.sourceData || []).map((d) => d[this.dimensions[0]])
|
|
2301
2267
|
)
|
|
2302
2268
|
), a = Array.from(
|
|
2303
2269
|
new Set(
|
|
2304
|
-
(this.sourceData || []).map((
|
|
2270
|
+
(this.sourceData || []).map((d) => d[this.dimensions[1]])
|
|
2305
2271
|
)
|
|
2306
2272
|
), f = parseInt(
|
|
2307
2273
|
(this.sourceData || []).reduce(
|
|
2308
|
-
(
|
|
2274
|
+
(d, p) => d + parseFloat((p == null ? void 0 : p.metric) || 0),
|
|
2309
2275
|
0
|
|
2310
2276
|
),
|
|
2311
2277
|
10
|
|
2312
|
-
),
|
|
2313
|
-
const
|
|
2278
|
+
), u = o.map((d, p) => {
|
|
2279
|
+
const b = (a[p] / f * 100).toFixed(2);
|
|
2314
2280
|
return {
|
|
2315
|
-
name: `${
|
|
2281
|
+
name: `${d} (${b}%)`,
|
|
2316
2282
|
value: a[p]
|
|
2317
2283
|
};
|
|
2318
|
-
}),
|
|
2319
|
-
return this.styleData.legend =
|
|
2284
|
+
}), c = ((t = this.styleData) == null ? void 0 : t.innerRadius) || "80%", h = ((r = this.styleData) == null ? void 0 : r.outerRadius) || "100%", w = [c, h];
|
|
2285
|
+
return this.styleData.legend = ue.getLegendOpions({
|
|
2320
2286
|
borderRadius: 10,
|
|
2321
2287
|
height: "100%",
|
|
2322
2288
|
padding: 10,
|
|
@@ -2324,12 +2290,12 @@ const Or = /* @__PURE__ */ O(vr, [["render", Cr]]), Rr = /* @__PURE__ */ Object.
|
|
|
2324
2290
|
type: "scroll",
|
|
2325
2291
|
itemWidth: 14,
|
|
2326
2292
|
itemHeight: 14,
|
|
2327
|
-
formatter: (
|
|
2293
|
+
formatter: (d) => {
|
|
2328
2294
|
var p;
|
|
2329
|
-
return (p =
|
|
2295
|
+
return (p = d == null ? void 0 : d.replace("null", "Не визначено")) == null ? void 0 : p.replace("NaN", "0.00");
|
|
2330
2296
|
},
|
|
2331
|
-
...((
|
|
2332
|
-
}), this.styleData.label =
|
|
2297
|
+
...((s = this.styleData) == null ? void 0 : s.legend) || {}
|
|
2298
|
+
}), this.styleData.label = ue.getLabelOptions(
|
|
2333
2299
|
(n = this.styleData) == null ? void 0 : n.label
|
|
2334
2300
|
), this.styleData.show_legend = ((i = this.styleData) == null ? void 0 : i.show_legend) ?? !0, { series: [
|
|
2335
2301
|
{
|
|
@@ -2338,8 +2304,8 @@ const Or = /* @__PURE__ */ O(vr, [["render", Cr]]), Rr = /* @__PURE__ */ Object.
|
|
|
2338
2304
|
radius: w,
|
|
2339
2305
|
center: ["50%", "60%"],
|
|
2340
2306
|
height: "75%",
|
|
2341
|
-
...
|
|
2342
|
-
data:
|
|
2307
|
+
...Y(this.styleData),
|
|
2308
|
+
data: u
|
|
2343
2309
|
}
|
|
2344
2310
|
] };
|
|
2345
2311
|
} catch (o) {
|
|
@@ -2358,13 +2324,13 @@ const Or = /* @__PURE__ */ O(vr, [["render", Cr]]), Rr = /* @__PURE__ */ Object.
|
|
|
2358
2324
|
return;
|
|
2359
2325
|
}
|
|
2360
2326
|
this.chartInstance = echarts.init(t);
|
|
2361
|
-
const
|
|
2327
|
+
const r = parseInt(
|
|
2362
2328
|
(this.sourceData || []).reduce(
|
|
2363
2329
|
(n, i) => n + parseFloat((i == null ? void 0 : i.metric) || 0),
|
|
2364
2330
|
0
|
|
2365
2331
|
),
|
|
2366
2332
|
10
|
|
2367
|
-
),
|
|
2333
|
+
), s = {
|
|
2368
2334
|
tooltip: {
|
|
2369
2335
|
trigger: "item",
|
|
2370
2336
|
formatter: (n) => this.buildTooltipForDonut(n, [n.color]),
|
|
@@ -2377,9 +2343,9 @@ const Or = /* @__PURE__ */ O(vr, [["render", Cr]]), Rr = /* @__PURE__ */ Object.
|
|
|
2377
2343
|
backgroundColor: "transparent"
|
|
2378
2344
|
},
|
|
2379
2345
|
series: e,
|
|
2380
|
-
...
|
|
2346
|
+
...Y(this.styleData || {}),
|
|
2381
2347
|
title: {
|
|
2382
|
-
text:
|
|
2348
|
+
text: V(r),
|
|
2383
2349
|
left: "center",
|
|
2384
2350
|
top: "41%",
|
|
2385
2351
|
textStyle: {
|
|
@@ -2389,7 +2355,7 @@ const Or = /* @__PURE__ */ O(vr, [["render", Cr]]), Rr = /* @__PURE__ */ Object.
|
|
|
2389
2355
|
}
|
|
2390
2356
|
}
|
|
2391
2357
|
};
|
|
2392
|
-
this.chartInstance.setOption(
|
|
2358
|
+
this.chartInstance.setOption(s), this.$emit("update:currentWidget", this.chartInstance), this.chartInstance.resize(), window.addEventListener("resize", () => {
|
|
2393
2359
|
var n;
|
|
2394
2360
|
(n = this.chartInstance) == null || n.resize();
|
|
2395
2361
|
});
|
|
@@ -2398,21 +2364,21 @@ const Or = /* @__PURE__ */ O(vr, [["render", Cr]]), Rr = /* @__PURE__ */ Object.
|
|
|
2398
2364
|
}
|
|
2399
2365
|
}
|
|
2400
2366
|
}
|
|
2401
|
-
},
|
|
2402
|
-
function
|
|
2367
|
+
}, bs = ["id"];
|
|
2368
|
+
function ws(e, t, r, s, n, i) {
|
|
2403
2369
|
return x(), _("div", {
|
|
2404
2370
|
id: i.uniqueID,
|
|
2405
2371
|
ref: "chart",
|
|
2406
2372
|
class: "h-full min-h-[200px] flex items-center"
|
|
2407
|
-
}, null, 8,
|
|
2373
|
+
}, null, 8, bs);
|
|
2408
2374
|
}
|
|
2409
|
-
const
|
|
2375
|
+
const ys = /* @__PURE__ */ R(gs, [["render", ws]]), xs = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
2410
2376
|
__proto__: null,
|
|
2411
|
-
default:
|
|
2412
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
2377
|
+
default: ys
|
|
2378
|
+
}, Symbol.toStringTag, { value: "Module" })), _s = {
|
|
2413
2379
|
name: "VsPie",
|
|
2414
2380
|
props: ["currentWidget"],
|
|
2415
|
-
mixins: [
|
|
2381
|
+
mixins: [M],
|
|
2416
2382
|
data() {
|
|
2417
2383
|
return {
|
|
2418
2384
|
chartInstance: null,
|
|
@@ -2427,11 +2393,11 @@ const Fr = /* @__PURE__ */ O($r, [["render", Nr]]), Ar = /* @__PURE__ */ Object.
|
|
|
2427
2393
|
}
|
|
2428
2394
|
},
|
|
2429
2395
|
async mounted() {
|
|
2430
|
-
var
|
|
2396
|
+
var r;
|
|
2431
2397
|
await this.$nextTick(), await this.getData();
|
|
2432
2398
|
const { series: e } = this.prepareData() || {};
|
|
2433
2399
|
e && this.initChart(e);
|
|
2434
|
-
const t = (
|
|
2400
|
+
const t = (r = this.$refs) == null ? void 0 : r.chart;
|
|
2435
2401
|
t && (this.resizeObserver = new ResizeObserver(() => {
|
|
2436
2402
|
this.chartInstance && this.chartInstance.resize();
|
|
2437
2403
|
}), this.resizeObserver.observe(t));
|
|
@@ -2445,57 +2411,57 @@ const Fr = /* @__PURE__ */ O($r, [["render", Nr]]), Ar = /* @__PURE__ */ Object.
|
|
|
2445
2411
|
onChangedData() {
|
|
2446
2412
|
try {
|
|
2447
2413
|
if (this.sourceData) {
|
|
2448
|
-
const { series: e, xs: t, ys:
|
|
2449
|
-
e && this.initChart(e, t,
|
|
2414
|
+
const { series: e, xs: t, ys: r } = this.prepareData();
|
|
2415
|
+
e && this.initChart(e, t, r);
|
|
2450
2416
|
}
|
|
2451
2417
|
} catch (e) {
|
|
2452
2418
|
console.error(e);
|
|
2453
2419
|
}
|
|
2454
2420
|
},
|
|
2455
2421
|
buildTooltipForDonut(e, t) {
|
|
2456
|
-
const { name:
|
|
2422
|
+
const { name: r, value: s, percent: n } = e;
|
|
2457
2423
|
return `
|
|
2458
2424
|
<div style="background-color:${t[0]}; font-size:12px; font-family:Helvetica, Arial, sans-serif; color:#ffff; padding:5px; border-radius:5px;">
|
|
2459
|
-
${
|
|
2425
|
+
${r == null ? void 0 : r.replace("null", "Не визначено")}: ${V(s)} (${n}%)
|
|
2460
2426
|
</div>`;
|
|
2461
2427
|
},
|
|
2462
2428
|
prepareData() {
|
|
2463
|
-
var e, t,
|
|
2429
|
+
var e, t, r, s, n;
|
|
2464
2430
|
try {
|
|
2465
2431
|
this.styleData = this.styleData || {};
|
|
2466
2432
|
const i = Array.from(
|
|
2467
2433
|
new Set(
|
|
2468
|
-
(this.sourceData || []).map((
|
|
2434
|
+
(this.sourceData || []).map((g) => g[this.dimensions[0]])
|
|
2469
2435
|
)
|
|
2470
2436
|
), o = Array.from(
|
|
2471
2437
|
new Set(
|
|
2472
|
-
(this.sourceData || []).map((
|
|
2438
|
+
(this.sourceData || []).map((g) => g[this.dimensions[1]])
|
|
2473
2439
|
)
|
|
2474
2440
|
), a = parseInt(
|
|
2475
2441
|
(this.sourceData || []).reduce(
|
|
2476
|
-
(
|
|
2442
|
+
(g, d) => g + parseFloat(d == null ? void 0 : d.metric),
|
|
2477
2443
|
0
|
|
2478
2444
|
),
|
|
2479
2445
|
10
|
|
2480
|
-
), f = i.map((
|
|
2481
|
-
const p = (o[
|
|
2446
|
+
), f = i.map((g, d) => {
|
|
2447
|
+
const p = (o[d] / a * 100).toFixed(2);
|
|
2482
2448
|
return {
|
|
2483
|
-
name: `${
|
|
2484
|
-
value: o[
|
|
2449
|
+
name: `${g} (${p}%)`,
|
|
2450
|
+
value: o[d]
|
|
2485
2451
|
};
|
|
2486
|
-
}),
|
|
2487
|
-
return this.styleData.legend =
|
|
2452
|
+
}), u = ((e = this.styleData) == null ? void 0 : e.innerRadius) || "0%", c = ((t = this.styleData) == null ? void 0 : t.outerRadius) || "100%", h = [u, c];
|
|
2453
|
+
return this.styleData.legend = ue.getLegendOpions({
|
|
2488
2454
|
borderRadius: 10,
|
|
2489
2455
|
height: "100%",
|
|
2490
2456
|
padding: 10,
|
|
2491
2457
|
type: "scroll",
|
|
2492
2458
|
itemWidth: 14,
|
|
2493
2459
|
itemHeight: 14,
|
|
2494
|
-
formatter: (
|
|
2460
|
+
formatter: (g) => g == null ? void 0 : g.replace("null", "Не визначено"),
|
|
2495
2461
|
textStyle: { fontSize: "14px" },
|
|
2496
|
-
...((
|
|
2497
|
-
}), this.styleData.label =
|
|
2498
|
-
(
|
|
2462
|
+
...((r = this.styleData) == null ? void 0 : r.legend) || {}
|
|
2463
|
+
}), this.styleData.label = ue.getLabelOptions(
|
|
2464
|
+
(s = this.styleData) == null ? void 0 : s.label
|
|
2499
2465
|
), this.styleData.show_legend = ((n = this.styleData) == null ? void 0 : n.show_legend) ?? !0, { series: [
|
|
2500
2466
|
{
|
|
2501
2467
|
name: this.titleCharts ? this.titleCharts : this.dimensions[0],
|
|
@@ -2503,7 +2469,7 @@ const Fr = /* @__PURE__ */ O($r, [["render", Nr]]), Ar = /* @__PURE__ */ Object.
|
|
|
2503
2469
|
radius: h,
|
|
2504
2470
|
center: ["50%", "60%"],
|
|
2505
2471
|
height: "75%",
|
|
2506
|
-
...
|
|
2472
|
+
...Y(this.styleData),
|
|
2507
2473
|
data: f
|
|
2508
2474
|
}
|
|
2509
2475
|
] };
|
|
@@ -2523,10 +2489,10 @@ const Fr = /* @__PURE__ */ O($r, [["render", Nr]]), Ar = /* @__PURE__ */ Object.
|
|
|
2523
2489
|
return;
|
|
2524
2490
|
}
|
|
2525
2491
|
this.chartInstance = echarts.init(t);
|
|
2526
|
-
const
|
|
2492
|
+
const r = {
|
|
2527
2493
|
tooltip: {
|
|
2528
2494
|
trigger: "item",
|
|
2529
|
-
formatter: (
|
|
2495
|
+
formatter: (s) => this.buildTooltipForDonut(s, [s.color]),
|
|
2530
2496
|
borderWidth: 0,
|
|
2531
2497
|
appendToBody: !0,
|
|
2532
2498
|
borderColor: "transparent",
|
|
@@ -2536,31 +2502,31 @@ const Fr = /* @__PURE__ */ O($r, [["render", Nr]]), Ar = /* @__PURE__ */ Object.
|
|
|
2536
2502
|
backgroundColor: "transparent"
|
|
2537
2503
|
},
|
|
2538
2504
|
series: e,
|
|
2539
|
-
...
|
|
2505
|
+
...Y(this.styleData || {})
|
|
2540
2506
|
};
|
|
2541
|
-
this.chartInstance.setOption(
|
|
2542
|
-
var
|
|
2543
|
-
(
|
|
2507
|
+
this.chartInstance.setOption(r), this.$emit("update:currentWidget", this.chartInstance), this.chartInstance.resize(), window.addEventListener("resize", () => {
|
|
2508
|
+
var s;
|
|
2509
|
+
(s = this.chartInstance) == null || s.resize();
|
|
2544
2510
|
});
|
|
2545
2511
|
} catch (t) {
|
|
2546
2512
|
console.error("Error in initChart:", t);
|
|
2547
2513
|
}
|
|
2548
2514
|
}
|
|
2549
2515
|
}
|
|
2550
|
-
},
|
|
2551
|
-
function
|
|
2516
|
+
}, Ds = ["id"];
|
|
2517
|
+
function ks(e, t, r, s, n, i) {
|
|
2552
2518
|
return x(), _("div", {
|
|
2553
2519
|
id: i.uniqueID,
|
|
2554
2520
|
ref: "chart",
|
|
2555
2521
|
class: "h-full min-h-[200px] flex items-center"
|
|
2556
|
-
}, null, 8,
|
|
2522
|
+
}, null, 8, Ds);
|
|
2557
2523
|
}
|
|
2558
|
-
const
|
|
2524
|
+
const Ss = /* @__PURE__ */ R(_s, [["render", ks]]), vs = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
2559
2525
|
__proto__: null,
|
|
2560
|
-
default:
|
|
2561
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
2526
|
+
default: Ss
|
|
2527
|
+
}, Symbol.toStringTag, { value: "Module" })), Es = {
|
|
2562
2528
|
name: "VsLine",
|
|
2563
|
-
mixins: [
|
|
2529
|
+
mixins: [M],
|
|
2564
2530
|
data() {
|
|
2565
2531
|
return {
|
|
2566
2532
|
chartInstance: null,
|
|
@@ -2576,8 +2542,8 @@ const Br = /* @__PURE__ */ O(Pr, [["render", Ur]]), jr = /* @__PURE__ */ Object.
|
|
|
2576
2542
|
onChangedData() {
|
|
2577
2543
|
try {
|
|
2578
2544
|
if (this.sourceData) {
|
|
2579
|
-
const { series: e, xs: t, ys:
|
|
2580
|
-
e && (this == null || this.initChart(e, t,
|
|
2545
|
+
const { series: e, xs: t, ys: r } = this.prepareData();
|
|
2546
|
+
e && (this == null || this.initChart(e, t, r));
|
|
2581
2547
|
}
|
|
2582
2548
|
} catch (e) {
|
|
2583
2549
|
console.error(e);
|
|
@@ -2586,11 +2552,11 @@ const Br = /* @__PURE__ */ O(Pr, [["render", Ur]]), jr = /* @__PURE__ */ Object.
|
|
|
2586
2552
|
prepareData() {
|
|
2587
2553
|
var e, t;
|
|
2588
2554
|
try {
|
|
2589
|
-
const
|
|
2555
|
+
const r = Array.from(
|
|
2590
2556
|
new Set(this.sourceData.map((o) => o[this.dimensions[0]]))
|
|
2591
2557
|
);
|
|
2592
|
-
let
|
|
2593
|
-
this.dimensions[0].includes("date") ?
|
|
2558
|
+
let s;
|
|
2559
|
+
this.dimensions[0].includes("date") ? s = r.map((o) => Te(o)) : s = [...r];
|
|
2594
2560
|
const n = this.sourceData.map(
|
|
2595
2561
|
(o) => parseFloat(o[this.dimensions[1]])
|
|
2596
2562
|
);
|
|
@@ -2609,26 +2575,26 @@ const Br = /* @__PURE__ */ O(Pr, [["render", Ur]]), jr = /* @__PURE__ */ Object.
|
|
|
2609
2575
|
data: n,
|
|
2610
2576
|
stack: "a"
|
|
2611
2577
|
}
|
|
2612
|
-
], { series: i, xs:
|
|
2613
|
-
} catch (
|
|
2614
|
-
return console.error(
|
|
2578
|
+
], { series: i, xs: s };
|
|
2579
|
+
} catch (r) {
|
|
2580
|
+
return console.error(r), null;
|
|
2615
2581
|
}
|
|
2616
2582
|
}
|
|
2617
2583
|
}
|
|
2618
|
-
},
|
|
2619
|
-
function
|
|
2584
|
+
}, Cs = ["id"];
|
|
2585
|
+
function Rs(e, t, r, s, n, i) {
|
|
2620
2586
|
return x(), _("div", {
|
|
2621
2587
|
id: n.uniqueID,
|
|
2622
2588
|
ref: "chart",
|
|
2623
2589
|
style: { height: "400px" }
|
|
2624
|
-
}, null, 8,
|
|
2590
|
+
}, null, 8, Cs);
|
|
2625
2591
|
}
|
|
2626
|
-
const
|
|
2592
|
+
const Os = /* @__PURE__ */ R(Es, [["render", Rs]]), Ts = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
2627
2593
|
__proto__: null,
|
|
2628
|
-
default:
|
|
2629
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
2594
|
+
default: Os
|
|
2595
|
+
}, Symbol.toStringTag, { value: "Module" })), $s = {
|
|
2630
2596
|
name: "VsStat",
|
|
2631
|
-
mixins: [
|
|
2597
|
+
mixins: [M],
|
|
2632
2598
|
data() {
|
|
2633
2599
|
return {
|
|
2634
2600
|
restDimensions: [],
|
|
@@ -2650,29 +2616,29 @@ const Mr = /* @__PURE__ */ O(Vr, [["render", zr]]), Hr = /* @__PURE__ */ Object.
|
|
|
2650
2616
|
prepareData() {
|
|
2651
2617
|
this.columns = Object.keys(this.sourceData[0]);
|
|
2652
2618
|
const e = this.getValues();
|
|
2653
|
-
this.sumValue = e.reduce((t,
|
|
2654
|
-
t.color =
|
|
2619
|
+
this.sumValue = e.reduce((t, r) => t + r, 0), this.sourceData.forEach((t, r) => {
|
|
2620
|
+
t.color = r < Qe.length - 1 ? Qe[r] : us();
|
|
2655
2621
|
});
|
|
2656
2622
|
},
|
|
2657
2623
|
formattedValue(e) {
|
|
2658
2624
|
const t = parseFloat(e);
|
|
2659
|
-
return
|
|
2625
|
+
return V(t);
|
|
2660
2626
|
}
|
|
2661
2627
|
}
|
|
2662
|
-
},
|
|
2628
|
+
}, Ns = { class: "flex flex-col w-full h-full pt-[16px] rounded-xl" }, As = { class: "flex flex-col justify-between w-full h-full" }, Fs = { class: "w-full h-full pb-6 space-y-4" }, Ls = { class: "flex w-full h-3 rounded-full gap-x-1 min-h-3 custom-x-scrollbar" }, Ps = ["onMouseover"], Bs = {
|
|
2663
2629
|
key: 0,
|
|
2664
2630
|
class: "absolute top-[-1] left-1/2 transform -translate-x-1/2 -translate-y-full bg-black text-white rounded px-2 py-1"
|
|
2665
|
-
},
|
|
2666
|
-
function
|
|
2667
|
-
return x(), _("div",
|
|
2668
|
-
|
|
2669
|
-
|
|
2670
|
-
|
|
2671
|
-
(x(!0), _(
|
|
2672
|
-
var f,
|
|
2631
|
+
}, Us = { class: "h-[calc(100%-20px)] w-full custom-scrollbar" }, js = { class: "grid items-center justify-between grid-cols-2 py-2 gap-x-4" }, Vs = { class: "flex items-center" }, Is = { class: "text-sm text-gray-800" }, zs = { class: "text-end" }, Ms = { class: "text-sm text-gray-500" };
|
|
2632
|
+
function qs(e, t, r, s, n, i) {
|
|
2633
|
+
return x(), _("div", Ns, [
|
|
2634
|
+
m("div", As, [
|
|
2635
|
+
m("div", Fs, [
|
|
2636
|
+
m("div", Ls, [
|
|
2637
|
+
(x(!0), _(F, null, P(e.sourceData, (o, a) => {
|
|
2638
|
+
var f, u, c, h;
|
|
2673
2639
|
return x(), _("div", {
|
|
2674
|
-
class:
|
|
2675
|
-
style:
|
|
2640
|
+
class: J(["flex flex-col min-w-[5px] justify-center min-h-2.5 h-2.5 text-xs text-white text-center whitespace-nowrap", `bg-[${o.color}]`]),
|
|
2641
|
+
style: Re({
|
|
2676
2642
|
width: `${parseFloat(o == null ? void 0 : o[(f = n.columns) == null ? void 0 : f[1]]) / n.sumValue * 100}%`
|
|
2677
2643
|
}),
|
|
2678
2644
|
role: "progressbar",
|
|
@@ -2682,22 +2648,22 @@ function nn(e, t, s, r, n, i) {
|
|
|
2682
2648
|
onMouseover: (w) => n.showTooltip = a,
|
|
2683
2649
|
onMouseleave: t[0] || (t[0] = (w) => n.showTooltip = -1)
|
|
2684
2650
|
}, [
|
|
2685
|
-
n.showTooltip > -1 ? (x(), _("div",
|
|
2686
|
-
], 46,
|
|
2651
|
+
n.showTooltip > -1 ? (x(), _("div", Bs, E(e.sourceData[n.showTooltip][n.columns[0]]) + " " + E((parseFloat((h = (u = e.sourceData) == null ? void 0 : u[n.showTooltip]) == null ? void 0 : h[(c = n.columns) == null ? void 0 : c[1]]) / n.sumValue * 100).toFixed(2)) + "% ", 1)) : $("", !0)
|
|
2652
|
+
], 46, Ps);
|
|
2687
2653
|
}), 256))
|
|
2688
2654
|
]),
|
|
2689
|
-
|
|
2690
|
-
(x(!0), _(
|
|
2655
|
+
m("ul", Us, [
|
|
2656
|
+
(x(!0), _(F, null, P(e.sourceData, (o) => {
|
|
2691
2657
|
var a, f;
|
|
2692
|
-
return x(), _("li",
|
|
2693
|
-
|
|
2694
|
-
|
|
2695
|
-
class:
|
|
2658
|
+
return x(), _("li", js, [
|
|
2659
|
+
m("div", Vs, [
|
|
2660
|
+
m("span", {
|
|
2661
|
+
class: J(["shrink-0 size-2.5 inline-block rounded-sm me-2.5 min-w-[10px] w-[10px] h-[10px] min-h-[10px]", `bg-[${o.color}]`])
|
|
2696
2662
|
}, null, 2),
|
|
2697
|
-
|
|
2663
|
+
m("span", Is, E((o == null ? void 0 : o[(a = n.columns) == null ? void 0 : a[0]]) || "Не визначено"), 1)
|
|
2698
2664
|
]),
|
|
2699
|
-
|
|
2700
|
-
|
|
2665
|
+
m("div", zs, [
|
|
2666
|
+
m("span", Ms, E(i.formattedValue(o == null ? void 0 : o[(f = n.columns) == null ? void 0 : f[1]]) || "-"), 1)
|
|
2701
2667
|
])
|
|
2702
2668
|
]);
|
|
2703
2669
|
}), 256))
|
|
@@ -2706,12 +2672,12 @@ function nn(e, t, s, r, n, i) {
|
|
|
2706
2672
|
])
|
|
2707
2673
|
]);
|
|
2708
2674
|
}
|
|
2709
|
-
const
|
|
2675
|
+
const Hs = /* @__PURE__ */ R($s, [["render", qs]]), Ws = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
2710
2676
|
__proto__: null,
|
|
2711
|
-
default:
|
|
2712
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
2677
|
+
default: Hs
|
|
2678
|
+
}, Symbol.toStringTag, { value: "Module" })), Js = {
|
|
2713
2679
|
name: "VsProgressBar",
|
|
2714
|
-
mixins: [
|
|
2680
|
+
mixins: [M],
|
|
2715
2681
|
data() {
|
|
2716
2682
|
return {
|
|
2717
2683
|
restDimensions: [],
|
|
@@ -2736,49 +2702,49 @@ const on = /* @__PURE__ */ O(qr, [["render", nn]]), an = /* @__PURE__ */ Object.
|
|
|
2736
2702
|
this.maxValue = Math.max(...e);
|
|
2737
2703
|
},
|
|
2738
2704
|
formattedValue(e) {
|
|
2739
|
-
return
|
|
2705
|
+
return V(e);
|
|
2740
2706
|
}
|
|
2741
2707
|
}
|
|
2742
|
-
},
|
|
2708
|
+
}, Ks = {
|
|
2743
2709
|
key: 0,
|
|
2744
2710
|
class: "flex flex-col h-full pt-[16px] rounded-xl"
|
|
2745
|
-
},
|
|
2711
|
+
}, Xs = { class: "h-full pt-0 pb-6 space-y-4" }, Gs = { class: "h-full space-y-4 custom-scrollbar" }, Qs = { class: "flex items-center justify-between mr-2 gap-x-2" }, Zs = { class: "grid items-center w-full grid-cols-2 gap-x-2" }, Ys = { class: "text-sm text-gray-800" }, en = {
|
|
2746
2712
|
class: "flex justify-end",
|
|
2747
2713
|
role: "progressbar",
|
|
2748
2714
|
"aria-valuenow": "100",
|
|
2749
2715
|
"aria-valuemin": "0",
|
|
2750
2716
|
"aria-valuemax": "100"
|
|
2751
|
-
},
|
|
2752
|
-
function
|
|
2753
|
-
return n.columns ? (x(), _("div",
|
|
2754
|
-
|
|
2755
|
-
|
|
2756
|
-
(x(!0), _(
|
|
2757
|
-
|
|
2758
|
-
|
|
2759
|
-
|
|
2760
|
-
|
|
2717
|
+
}, tn = { class: "min-w-[60px] text-end" }, rn = { class: "text-sm text-gray-500" };
|
|
2718
|
+
function sn(e, t, r, s, n, i) {
|
|
2719
|
+
return n.columns ? (x(), _("div", Ks, [
|
|
2720
|
+
m("div", Xs, [
|
|
2721
|
+
m("ul", Gs, [
|
|
2722
|
+
(x(!0), _(F, null, P(e.sourceData, (o, a) => (x(), _("li", Qs, [
|
|
2723
|
+
m("div", Zs, [
|
|
2724
|
+
m("span", Ys, E(o[n.columns[0]]), 1),
|
|
2725
|
+
m("div", en, [
|
|
2726
|
+
m("div", {
|
|
2761
2727
|
class: "h-1.5 flex flex-col justify-center overflow-hidden bg-indigo-500 rounded-full text-xs text-white text-center whitespace-nowrap",
|
|
2762
|
-
style:
|
|
2728
|
+
style: Re({
|
|
2763
2729
|
width: `${parseFloat(o[n.columns[1]]) / n.maxValue * 100}%`
|
|
2764
2730
|
})
|
|
2765
2731
|
}, null, 4)
|
|
2766
2732
|
])
|
|
2767
2733
|
]),
|
|
2768
|
-
|
|
2769
|
-
|
|
2734
|
+
m("div", tn, [
|
|
2735
|
+
m("span", rn, E(i.formattedValue(o[n.columns[1]])), 1)
|
|
2770
2736
|
])
|
|
2771
2737
|
]))), 256))
|
|
2772
2738
|
])
|
|
2773
2739
|
])
|
|
2774
|
-
])) :
|
|
2740
|
+
])) : $("", !0);
|
|
2775
2741
|
}
|
|
2776
|
-
const
|
|
2742
|
+
const nn = /* @__PURE__ */ R(Js, [["render", sn]]), on = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
2777
2743
|
__proto__: null,
|
|
2778
|
-
default:
|
|
2779
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
2744
|
+
default: nn
|
|
2745
|
+
}, Symbol.toStringTag, { value: "Module" })), an = {
|
|
2780
2746
|
name: "VsListbar",
|
|
2781
|
-
mixins: [
|
|
2747
|
+
mixins: [M],
|
|
2782
2748
|
props: ["source"],
|
|
2783
2749
|
data() {
|
|
2784
2750
|
return {
|
|
@@ -2799,58 +2765,58 @@ const yn = /* @__PURE__ */ O(ln, [["render", wn]]), xn = /* @__PURE__ */ Object.
|
|
|
2799
2765
|
}
|
|
2800
2766
|
},
|
|
2801
2767
|
prepareData() {
|
|
2802
|
-
var t,
|
|
2768
|
+
var t, r, s;
|
|
2803
2769
|
this.columns = Object.keys(((t = this.sourceData) == null ? void 0 : t[0]) || {});
|
|
2804
|
-
const e = (
|
|
2770
|
+
const e = (r = this.sourceData) == null ? void 0 : r.map((n) => {
|
|
2805
2771
|
var i;
|
|
2806
2772
|
return n == null ? void 0 : n[(i = this.columns) == null ? void 0 : i[1]];
|
|
2807
2773
|
});
|
|
2808
|
-
this.maxValue = Math.max(...e || []), this.restDimensions = (
|
|
2774
|
+
this.maxValue = Math.max(...e || []), this.restDimensions = (s = this.columns) == null ? void 0 : s.filter((n, i) => i !== 0);
|
|
2809
2775
|
},
|
|
2810
2776
|
formattedValue(e) {
|
|
2811
|
-
return
|
|
2777
|
+
return V(e);
|
|
2812
2778
|
},
|
|
2813
2779
|
getWidth(e) {
|
|
2814
2780
|
return `${e / this.maxValue * 100}%`;
|
|
2815
2781
|
}
|
|
2816
2782
|
}
|
|
2817
|
-
},
|
|
2818
|
-
function
|
|
2819
|
-
return x(), _("div",
|
|
2820
|
-
|
|
2821
|
-
(x(!0), _(
|
|
2822
|
-
var f,
|
|
2783
|
+
}, ln = { class: "h-full pt-[20px] list-bar" }, cn = { class: "space-y-2 custom-scrollbar h-full h-[calc(100%-20px)]" }, un = { class: "relative w-full truncate" }, dn = { class: "relative z-[1] text-sm block py-1 px-2 w-full text-sm truncate text-gray-800" }, fn = { class: "text-[14px] text-gray-500" };
|
|
2784
|
+
function hn(e, t, r, s, n, i) {
|
|
2785
|
+
return x(), _("div", ln, [
|
|
2786
|
+
m("ul", cn, [
|
|
2787
|
+
(x(!0), _(F, null, P(e.sourceData, (o, a) => {
|
|
2788
|
+
var f, u, c;
|
|
2823
2789
|
return x(), _("li", {
|
|
2824
2790
|
key: a,
|
|
2825
2791
|
class: "flex items-center justify-between w-full gap-x-2"
|
|
2826
2792
|
}, [
|
|
2827
|
-
|
|
2828
|
-
|
|
2829
|
-
|
|
2830
|
-
class:
|
|
2831
|
-
style:
|
|
2793
|
+
m("div", un, [
|
|
2794
|
+
m("span", dn, E((o == null ? void 0 : o[(f = n.columns) == null ? void 0 : f[0]]) || "Без категорії"), 1),
|
|
2795
|
+
m("div", {
|
|
2796
|
+
class: J(["absolute inset-y-0 h-full rounded start-0", o != null && o[(u = n.columns) == null ? void 0 : u[0]] ? "bg-indigo-100" : "bg-gray-100"]),
|
|
2797
|
+
style: Re({ width: i.getWidth(o == null ? void 0 : o[(c = n.columns) == null ? void 0 : c[1]]) })
|
|
2832
2798
|
}, null, 6)
|
|
2833
2799
|
]),
|
|
2834
|
-
(x(!0), _(
|
|
2800
|
+
(x(!0), _(F, null, P(n.restDimensions, (h, w) => (x(), _("div", {
|
|
2835
2801
|
key: w,
|
|
2836
2802
|
class: "w-20 mr-2 text-end"
|
|
2837
2803
|
}, [
|
|
2838
|
-
|
|
2804
|
+
m("span", fn, E(i.formattedValue(o == null ? void 0 : o[h])), 1)
|
|
2839
2805
|
]))), 128))
|
|
2840
2806
|
]);
|
|
2841
2807
|
}), 128))
|
|
2842
2808
|
])
|
|
2843
2809
|
]);
|
|
2844
2810
|
}
|
|
2845
|
-
const
|
|
2811
|
+
const pn = /* @__PURE__ */ R(an, [["render", hn]]), mn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
2846
2812
|
__proto__: null,
|
|
2847
|
-
default:
|
|
2848
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
2813
|
+
default: pn
|
|
2814
|
+
}, Symbol.toStringTag, { value: "Module" })), _e = {
|
|
2849
2815
|
week: "Тиждень",
|
|
2850
2816
|
month: "Місяць",
|
|
2851
2817
|
quarter: "Квартал",
|
|
2852
2818
|
year: "Рік"
|
|
2853
|
-
},
|
|
2819
|
+
}, gn = ["onClick"], bn = { class: "flex items-center justify-between w-full" }, wn = { key: 0 }, yn = {
|
|
2854
2820
|
__name: "vs-bi-dropdown",
|
|
2855
2821
|
props: {
|
|
2856
2822
|
title: String,
|
|
@@ -2859,31 +2825,31 @@ const On = /* @__PURE__ */ O(_n, [["render", Cn]]), Rn = /* @__PURE__ */ Object.
|
|
|
2859
2825
|
},
|
|
2860
2826
|
emits: ["selected"],
|
|
2861
2827
|
setup(e, { emit: t }) {
|
|
2862
|
-
const
|
|
2863
|
-
const
|
|
2864
|
-
(
|
|
2828
|
+
const r = e, s = t, n = be(!1), i = be(r.value || null), o = be(null), a = Le(() => typeof r.options == "string" ? r.options.split(",").map((g, d) => ({ id: d, text: g.trim() })) : r.options), f = Le(() => {
|
|
2829
|
+
const g = a.value.find(
|
|
2830
|
+
(d) => (d.id || d) === i.value
|
|
2865
2831
|
);
|
|
2866
|
-
return
|
|
2867
|
-
}),
|
|
2868
|
-
i.value =
|
|
2869
|
-
},
|
|
2870
|
-
o.value && !o.value.contains(
|
|
2832
|
+
return g ? g.text || g : r.title;
|
|
2833
|
+
}), u = (g) => {
|
|
2834
|
+
i.value = g.id || g, n.value = !1, s("selected", (g == null ? void 0 : g.id) || g), document.removeEventListener("click", c);
|
|
2835
|
+
}, c = (g) => {
|
|
2836
|
+
o.value && !o.value.contains(g.target) && (n.value = !1, document.removeEventListener("click", c));
|
|
2871
2837
|
}, h = () => {
|
|
2872
2838
|
n.value = !n.value, n.value ? setTimeout(() => {
|
|
2873
|
-
document.addEventListener("click",
|
|
2874
|
-
}, 200) : document.removeEventListener("click",
|
|
2875
|
-
}, w = (
|
|
2876
|
-
return
|
|
2877
|
-
document.removeEventListener("click",
|
|
2878
|
-
}), (
|
|
2879
|
-
|
|
2839
|
+
document.addEventListener("click", c);
|
|
2840
|
+
}, 200) : document.removeEventListener("click", c);
|
|
2841
|
+
}, w = (g) => (_e == null ? void 0 : _e[g]) || g;
|
|
2842
|
+
return vt(() => {
|
|
2843
|
+
document.removeEventListener("click", c);
|
|
2844
|
+
}), (g, d) => (x(), _(F, null, [
|
|
2845
|
+
m("button", {
|
|
2880
2846
|
type: "button",
|
|
2881
2847
|
"aria-expanded": "true",
|
|
2882
2848
|
class: "hs-select-disabled:pointer-events-none hs-select-disabled:opacity-50 relative group pr-2 -ms-2 py-1.5 pl-2.5 inline-flex shrink-0 justify-center items-center gap-x-1.5 text-sm text-gray-800 rounded-lg hover:bg-gray-100 focus:outline-none focus:bg-gray-100 before:absolute before:inset-0 before:z-[1] dark:text-neutral-400 dark:hover:bg-neutral-800 dark:focus:bg-neutral-700",
|
|
2883
2849
|
onClick: h
|
|
2884
2850
|
}, [
|
|
2885
|
-
|
|
2886
|
-
|
|
2851
|
+
Ze(E(w(f.value)) + " ", 1),
|
|
2852
|
+
d[0] || (d[0] = m("svg", {
|
|
2887
2853
|
class: "shrink-0 size-3.5 text-gray-600 dark:text-neutral-400",
|
|
2888
2854
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2889
2855
|
width: "16",
|
|
@@ -2895,7 +2861,7 @@ const On = /* @__PURE__ */ O(_n, [["render", Cn]]), Rn = /* @__PURE__ */ Object.
|
|
|
2895
2861
|
"stroke-linecap": "round",
|
|
2896
2862
|
"stroke-linejoin": "round"
|
|
2897
2863
|
}, [
|
|
2898
|
-
|
|
2864
|
+
m("path", { d: "m6 9 6 6 6-6" })
|
|
2899
2865
|
], -1))
|
|
2900
2866
|
]),
|
|
2901
2867
|
n.value ? (x(), _("div", {
|
|
@@ -2909,15 +2875,15 @@ const On = /* @__PURE__ */ O(_n, [["render", Cn]]), Rn = /* @__PURE__ */ Object.
|
|
|
2909
2875
|
"aria-orientation": "vertical",
|
|
2910
2876
|
style: { "margin-top": "10px" }
|
|
2911
2877
|
}, [
|
|
2912
|
-
(x(!0), _(
|
|
2878
|
+
(x(!0), _(F, null, P(a.value, (p) => (x(), _("div", {
|
|
2913
2879
|
key: p.id || p,
|
|
2914
2880
|
class: "cursor-pointer selected hs-selected:bg-gray-100 dark:hs-selected:bg-neutral-800 py-1.5 px-2 w-full text-[13px] text-gray-800 rounded-lg hover:bg-gray-100 focus:outline-none focus:bg-gray-100 dark:text-neutral-300 dark:hover:bg-neutral-700 dark:focus:bg-neutral-700",
|
|
2915
|
-
onClick: (
|
|
2881
|
+
onClick: (b) => u(p)
|
|
2916
2882
|
}, [
|
|
2917
|
-
|
|
2918
|
-
|
|
2919
|
-
i.value === (p.id || p) ? (x(), _("span",
|
|
2920
|
-
|
|
2883
|
+
m("div", bn, [
|
|
2884
|
+
m("span", null, E(w(p.text || p)), 1),
|
|
2885
|
+
i.value === (p.id || p) ? (x(), _("span", wn, [...d[1] || (d[1] = [
|
|
2886
|
+
m("svg", {
|
|
2921
2887
|
class: "shrink-0 h-3.5 w-3.5 text-gray-800 dark:text-neutral-200",
|
|
2922
2888
|
xmlns: "http:.w3.org/2000/svg",
|
|
2923
2889
|
width: "24",
|
|
@@ -2929,32 +2895,32 @@ const On = /* @__PURE__ */ O(_n, [["render", Cn]]), Rn = /* @__PURE__ */ Object.
|
|
|
2929
2895
|
"stroke-linecap": "round",
|
|
2930
2896
|
"stroke-linejoin": "round"
|
|
2931
2897
|
}, [
|
|
2932
|
-
|
|
2898
|
+
m("polyline", { points: "20 6 9 17 4 12" })
|
|
2933
2899
|
], -1)
|
|
2934
|
-
])])) :
|
|
2900
|
+
])])) : $("", !0)
|
|
2935
2901
|
])
|
|
2936
|
-
], 8,
|
|
2937
|
-
], 512)) :
|
|
2902
|
+
], 8, gn))), 128))
|
|
2903
|
+
], 512)) : $("", !0)
|
|
2938
2904
|
], 64));
|
|
2939
2905
|
}
|
|
2940
|
-
},
|
|
2941
|
-
"bi-bar": T(() => Promise.resolve().then(() =>
|
|
2942
|
-
"bi-number": T(() => import("./vs-number-
|
|
2943
|
-
"bi-text": T(() => import("./vs-text-
|
|
2944
|
-
"bi-listbar": T(() => Promise.resolve().then(() =>
|
|
2945
|
-
"bi-pie": T(() => Promise.resolve().then(() =>
|
|
2946
|
-
"bi-donut": T(() => Promise.resolve().then(() =>
|
|
2947
|
-
"bi-line": T(() => Promise.resolve().then(() =>
|
|
2948
|
-
"bi-stat": T(() => Promise.resolve().then(() =>
|
|
2949
|
-
"bi-pivot": T(() => Promise.resolve().then(() =>
|
|
2950
|
-
"bi-progress": T(() => Promise.resolve().then(() =>
|
|
2951
|
-
"bi-funnel": T(() => import("./vs-funnel-bar-
|
|
2952
|
-
"bi-map": T(() => import("./vs-map-
|
|
2953
|
-
"bi-cluster": T(() => import("./vs-map-cluster-
|
|
2954
|
-
"bi-table": T(() => import("./vs-table-
|
|
2955
|
-
},
|
|
2906
|
+
}, xn = {
|
|
2907
|
+
"bi-bar": T(() => Promise.resolve().then(() => ms)),
|
|
2908
|
+
"bi-number": T(() => import("./vs-number-sHlpEuZn.js")),
|
|
2909
|
+
"bi-text": T(() => import("./vs-text-CK4PX9CJ.js")),
|
|
2910
|
+
"bi-listbar": T(() => Promise.resolve().then(() => mn)),
|
|
2911
|
+
"bi-pie": T(() => Promise.resolve().then(() => vs)),
|
|
2912
|
+
"bi-donut": T(() => Promise.resolve().then(() => xs)),
|
|
2913
|
+
"bi-line": T(() => Promise.resolve().then(() => Ts)),
|
|
2914
|
+
"bi-stat": T(() => Promise.resolve().then(() => Ws)),
|
|
2915
|
+
"bi-pivot": T(() => Promise.resolve().then(() => Li)),
|
|
2916
|
+
"bi-progress": T(() => Promise.resolve().then(() => on)),
|
|
2917
|
+
"bi-funnel": T(() => import("./vs-funnel-bar-CyPcyYTP.js")),
|
|
2918
|
+
"bi-map": T(() => import("./vs-map-DesSaN8x.js")),
|
|
2919
|
+
"bi-cluster": T(() => import("./vs-map-cluster-Br3XHcWM.js")),
|
|
2920
|
+
"bi-table": T(() => import("./vs-table-C8ibl5_z.js"))
|
|
2921
|
+
}, _n = { class: "flex items-center space-x-2" }, Dn = /* @__PURE__ */ Et({
|
|
2956
2922
|
__name: "vs-bi-switch",
|
|
2957
|
-
props: /* @__PURE__ */
|
|
2923
|
+
props: /* @__PURE__ */ Pe({
|
|
2958
2924
|
leftLabel: {},
|
|
2959
2925
|
rightLabel: {},
|
|
2960
2926
|
modelValue: { type: Boolean }
|
|
@@ -2965,39 +2931,39 @@ const On = /* @__PURE__ */ O(_n, [["render", Cn]]), Rn = /* @__PURE__ */ Object.
|
|
|
2965
2931
|
},
|
|
2966
2932
|
modelModifiers: {}
|
|
2967
2933
|
}),
|
|
2968
|
-
emits: /* @__PURE__ */
|
|
2934
|
+
emits: /* @__PURE__ */ Pe(["update:is-enabled"], ["update:modelValue"]),
|
|
2969
2935
|
setup(e, { emit: t }) {
|
|
2970
|
-
const
|
|
2971
|
-
|
|
2936
|
+
const r = t, s = Ct(e, "modelValue"), n = () => {
|
|
2937
|
+
r("update:is-enabled", s);
|
|
2972
2938
|
};
|
|
2973
|
-
return (i, o) => (x(), _("div",
|
|
2974
|
-
|
|
2939
|
+
return (i, o) => (x(), _("div", _n, [
|
|
2940
|
+
i.leftLabel ? (x(), _("div", {
|
|
2975
2941
|
key: 0,
|
|
2976
|
-
class:
|
|
2977
|
-
}, E(
|
|
2978
|
-
|
|
2979
|
-
"onUpdate:modelValue": o[0] || (o[0] = (a) =>
|
|
2942
|
+
class: J(["transition-colors", { "text-blue-500": !s.value }])
|
|
2943
|
+
}, E(i.leftLabel), 3)) : $("", !0),
|
|
2944
|
+
Rt(m("input", {
|
|
2945
|
+
"onUpdate:modelValue": o[0] || (o[0] = (a) => s.value = a),
|
|
2980
2946
|
type: "checkbox",
|
|
2981
2947
|
class: "relative w-11 h-6 p-px bg-gray-100 border-transparent text-transparent rounded-full cursor-pointer transition-colors ease-in-out duration-200 focus:ring-blue-600 disabled:opacity-50 disabled:pointer-events-none checked:bg-none checked:text-blue-600 checked:border-blue-600 focus:checked:border-blue-600 dark:bg-neutral-800 dark:border-neutral-700 dark:checked:bg-blue-500 dark:checked:border-blue-500 dark:focus:ring-offset-gray-600 before:inline-block before:size-5 before:bg-white checked:before:bg-blue-200 before:translate-x-0 checked:before:translate-x-full before:rounded-full before:shadow before:h-5 before:w-5 before:transform before:ring-0 before:transition before:ease-in-out before:duration-200 dark:before:bg-neutral-400 dark:checked:before:bg-blue-200",
|
|
2982
2948
|
onChange: n
|
|
2983
2949
|
}, null, 544), [
|
|
2984
|
-
[
|
|
2950
|
+
[Ot, s.value]
|
|
2985
2951
|
]),
|
|
2986
|
-
|
|
2952
|
+
i.rightLabel ? (x(), _("div", {
|
|
2987
2953
|
key: 1,
|
|
2988
|
-
class:
|
|
2989
|
-
}, E(
|
|
2954
|
+
class: J(["transition-colors", { "text-blue-500": s.value }])
|
|
2955
|
+
}, E(i.rightLabel), 3)) : $("", !0)
|
|
2990
2956
|
]));
|
|
2991
2957
|
}
|
|
2992
|
-
}),
|
|
2993
|
-
function
|
|
2994
|
-
return x(), _("div",
|
|
2995
|
-
|
|
2996
|
-
|
|
2958
|
+
}), kn = {}, Sn = { class: "flex items-center justify-center h-full" };
|
|
2959
|
+
function vn(e, t) {
|
|
2960
|
+
return x(), _("div", Sn, [...t[0] || (t[0] = [
|
|
2961
|
+
m("div", { class: "text-center text-gray-500" }, [
|
|
2962
|
+
m("h2", { class: "text-2xl font-bold" }, "No data available")
|
|
2997
2963
|
], -1)
|
|
2998
2964
|
])]);
|
|
2999
2965
|
}
|
|
3000
|
-
const
|
|
2966
|
+
const En = /* @__PURE__ */ R(kn, [["render", vn]]), Cn = {}, Rn = {
|
|
3001
2967
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3002
2968
|
viewBox: "0 0 24 24",
|
|
3003
2969
|
fill: "none",
|
|
@@ -3007,25 +2973,25 @@ const Vn = /* @__PURE__ */ O(Un, [["render", jn]]), In = {}, zn = {
|
|
|
3007
2973
|
"stroke-linejoin": "round",
|
|
3008
2974
|
class: "icon icon-tabler icons-tabler-outline icon-tabler-download"
|
|
3009
2975
|
};
|
|
3010
|
-
function
|
|
3011
|
-
return x(), _("svg",
|
|
3012
|
-
|
|
2976
|
+
function On(e, t, r, s, n, i) {
|
|
2977
|
+
return x(), _("svg", Rn, [...t[0] || (t[0] = [
|
|
2978
|
+
m("path", {
|
|
3013
2979
|
stroke: "none",
|
|
3014
2980
|
d: "M0 0h24v24H0z",
|
|
3015
2981
|
fill: "none"
|
|
3016
2982
|
}, null, -1),
|
|
3017
|
-
|
|
3018
|
-
|
|
3019
|
-
|
|
2983
|
+
m("path", { d: "M4 17v2a2 2 0 0 0 2 2h12a2 2 0 0 0 2 -2v-2" }, null, -1),
|
|
2984
|
+
m("path", { d: "M7 11l5 5l5 -5" }, null, -1),
|
|
2985
|
+
m("path", { d: "M12 4l0 12" }, null, -1)
|
|
3020
2986
|
])]);
|
|
3021
2987
|
}
|
|
3022
|
-
const
|
|
2988
|
+
const Tn = /* @__PURE__ */ R(Cn, [["render", On]]), $n = {
|
|
3023
2989
|
components: {
|
|
3024
|
-
VsBiDropdown:
|
|
3025
|
-
VsBiSwitch:
|
|
3026
|
-
VsNoDataChart:
|
|
3027
|
-
IconDownload:
|
|
3028
|
-
...
|
|
2990
|
+
VsBiDropdown: yn,
|
|
2991
|
+
VsBiSwitch: Dn,
|
|
2992
|
+
VsNoDataChart: En,
|
|
2993
|
+
IconDownload: Tn,
|
|
2994
|
+
...xn
|
|
3029
2995
|
},
|
|
3030
2996
|
props: {
|
|
3031
2997
|
dashboard: { type: String },
|
|
@@ -3045,27 +3011,27 @@ const Hn = /* @__PURE__ */ O(In, [["render", Mn]]), qn = {
|
|
|
3045
3011
|
},
|
|
3046
3012
|
computed: {
|
|
3047
3013
|
computedTitle() {
|
|
3048
|
-
var t,
|
|
3014
|
+
var t, r;
|
|
3049
3015
|
const e = (t = this.dashboardWidgets) == null ? void 0 : t.find(
|
|
3050
|
-
(
|
|
3016
|
+
(s) => s.name === this.widget
|
|
3051
3017
|
);
|
|
3052
|
-
return ((
|
|
3018
|
+
return ((r = e == null ? void 0 : e.data) == null ? void 0 : r.title) || (e == null ? void 0 : e.title) || "";
|
|
3053
3019
|
},
|
|
3054
3020
|
computedType() {
|
|
3055
3021
|
var t;
|
|
3056
3022
|
const e = (t = this.dashboardWidgets) == null ? void 0 : t.find(
|
|
3057
|
-
(
|
|
3023
|
+
(r) => r.name === this.widget
|
|
3058
3024
|
);
|
|
3059
3025
|
return (e == null ? void 0 : e.type) || "text";
|
|
3060
3026
|
},
|
|
3061
3027
|
controls() {
|
|
3062
3028
|
var t;
|
|
3063
3029
|
return Object.keys(((t = this.widgetData) == null ? void 0 : t.controls) || {}).map(
|
|
3064
|
-
(
|
|
3065
|
-
var
|
|
3030
|
+
(r) => {
|
|
3031
|
+
var s, n, i;
|
|
3066
3032
|
return {
|
|
3067
|
-
name:
|
|
3068
|
-
options: typeof ((
|
|
3033
|
+
name: r,
|
|
3034
|
+
options: typeof ((s = this.widgetData) == null ? void 0 : s.controls) == "boolean" ? !1 : (i = (n = this.widgetData) == null ? void 0 : n.controls) == null ? void 0 : i[r]
|
|
3069
3035
|
};
|
|
3070
3036
|
}
|
|
3071
3037
|
);
|
|
@@ -3076,35 +3042,35 @@ const Hn = /* @__PURE__ */ O(In, [["render", Mn]]), qn = {
|
|
|
3076
3042
|
},
|
|
3077
3043
|
watch: {
|
|
3078
3044
|
filterURl(e) {
|
|
3079
|
-
var t,
|
|
3080
|
-
(
|
|
3045
|
+
var t, r;
|
|
3046
|
+
(r = (t = this.$refs) == null ? void 0 : t.chart) == null || r.setFilter(e);
|
|
3081
3047
|
},
|
|
3082
3048
|
selectedWidget(e, t) {
|
|
3083
|
-
var
|
|
3084
|
-
e !== t && e === ((
|
|
3049
|
+
var r;
|
|
3050
|
+
e !== t && e === ((r = this.widgetData) == null ? void 0 : r.id) && this.$emit("update:current-widget-data", this.widgetData);
|
|
3085
3051
|
},
|
|
3086
3052
|
widgetData(e, t) {
|
|
3087
3053
|
if ((e == null ? void 0 : e.id) === (t == null ? void 0 : t.id)) return;
|
|
3088
|
-
const
|
|
3089
|
-
|
|
3054
|
+
const s = new URLSearchParams(window.top.location.search).get("widget");
|
|
3055
|
+
s && s === (e == null ? void 0 : e.id) && this.$emit("update:current-widget-data", e);
|
|
3090
3056
|
}
|
|
3091
3057
|
},
|
|
3092
3058
|
methods: {
|
|
3093
3059
|
changeStyleHandler(e, t) {
|
|
3094
|
-
var
|
|
3095
|
-
(
|
|
3060
|
+
var r;
|
|
3061
|
+
(r = this.$refs.chart) == null || r.changeStyle(e, t);
|
|
3096
3062
|
},
|
|
3097
3063
|
selectedOptionHandler(e, t) {
|
|
3098
|
-
let
|
|
3099
|
-
this.selected.forEach((
|
|
3100
|
-
|
|
3101
|
-
}),
|
|
3064
|
+
let r = !0;
|
|
3065
|
+
this.selected.forEach((s) => {
|
|
3066
|
+
s.name === t && (s.option = e, r = !1);
|
|
3067
|
+
}), r && this.selected.push({ name: t, option: e }), this.makeUpUrl();
|
|
3102
3068
|
},
|
|
3103
3069
|
makeUpUrl() {
|
|
3104
3070
|
var t;
|
|
3105
3071
|
let e = `/bi-data?dashboard=${this.dashboard}&widget=${this.widget}`;
|
|
3106
|
-
this.selected.forEach((
|
|
3107
|
-
e += `&${
|
|
3072
|
+
this.selected.forEach((r, s) => {
|
|
3073
|
+
e += `&${r.name}=${r.option}`;
|
|
3108
3074
|
}), (t = this.$refs.chart) == null || t.getDataFromURL(e);
|
|
3109
3075
|
},
|
|
3110
3076
|
exportChart() {
|
|
@@ -3118,82 +3084,82 @@ const Hn = /* @__PURE__ */ O(In, [["render", Mn]]), qn = {
|
|
|
3118
3084
|
}
|
|
3119
3085
|
}
|
|
3120
3086
|
}
|
|
3121
|
-
},
|
|
3087
|
+
}, Nn = {
|
|
3122
3088
|
key: 0,
|
|
3123
3089
|
class: "text-[16px] flex max-w-full items-center min-h-0 flex justify-between max-h-[50px] h-fit shrink-0"
|
|
3124
|
-
},
|
|
3090
|
+
}, An = { class: "flex items-center justify-between w-full" }, Fn = { class: "grid" }, Ln = { class: "text-gray-800 max-h-[30px] inline-block line-clamp-1 font-semibold" }, Pn = { class: "flex flex-col justify-end" }, Bn = {
|
|
3125
3091
|
key: 0,
|
|
3126
3092
|
class: "flex items-center justify-end w-full gap-2"
|
|
3127
|
-
},
|
|
3128
|
-
function
|
|
3129
|
-
var
|
|
3130
|
-
const o =
|
|
3093
|
+
}, Un = { class: "w-full h-full" };
|
|
3094
|
+
function jn(e, t, r, s, n, i) {
|
|
3095
|
+
var c, h, w, g, d, p, b, S, k;
|
|
3096
|
+
const o = j("VsBiDropdown"), a = j("VsBiSwitch"), f = j("IconDownload"), u = j("VsNoDataChart");
|
|
3131
3097
|
return x(), _("div", {
|
|
3132
3098
|
ref: "widget",
|
|
3133
|
-
class:
|
|
3134
|
-
(h = (
|
|
3099
|
+
class: J(["box-border relative h-full p-4 bg-white border border-gray-200 select-auto rounded-xl", [
|
|
3100
|
+
(h = (c = n.widgetData) == null ? void 0 : c.style) != null && h.height ? `max-h-[${(g = (w = n.widgetData) == null ? void 0 : w.style) == null ? void 0 : g.height}px] h-[${(p = (d = n.widgetData) == null ? void 0 : d.style) == null ? void 0 : p.height}px]` : "max-h-[460px]"
|
|
3135
3101
|
]])
|
|
3136
3102
|
}, [
|
|
3137
|
-
["text", "cluster", "map"].includes(i.computedType) ?
|
|
3138
|
-
|
|
3139
|
-
|
|
3140
|
-
|
|
3103
|
+
["text", "cluster", "map"].includes(i.computedType) ? $("", !0) : (x(), _("div", Nn, [
|
|
3104
|
+
m("div", An, [
|
|
3105
|
+
m("div", Fn, [
|
|
3106
|
+
m("span", Ln, E(i.computedTitle), 1)
|
|
3141
3107
|
]),
|
|
3142
|
-
|
|
3143
|
-
(
|
|
3144
|
-
(x(!0), _(
|
|
3108
|
+
m("div", Pn, [
|
|
3109
|
+
(b = i.controls) != null && b.length ? (x(), _("span", Bn, [
|
|
3110
|
+
(x(!0), _(F, null, P((S = i.controls) == null ? void 0 : S.filter(
|
|
3145
3111
|
(y) => (y == null ? void 0 : y.options) && (y == null ? void 0 : y.name) !== "export"
|
|
3146
3112
|
), (y) => {
|
|
3147
|
-
var
|
|
3113
|
+
var L;
|
|
3148
3114
|
return x(), _("div", null, [
|
|
3149
|
-
Array.isArray(y == null ? void 0 : y.options) ? (x(),
|
|
3115
|
+
Array.isArray(y == null ? void 0 : y.options) ? (x(), I(o, {
|
|
3150
3116
|
key: 0,
|
|
3151
3117
|
title: y == null ? void 0 : y.name,
|
|
3152
3118
|
options: y == null ? void 0 : y.options,
|
|
3153
|
-
value: (
|
|
3154
|
-
onSelected: (
|
|
3155
|
-
}, null, 8, ["title", "options", "value", "onSelected"])) : typeof y.options == "boolean" ? (x(),
|
|
3119
|
+
value: (L = n.widgetData) == null ? void 0 : L.data[y == null ? void 0 : y.name],
|
|
3120
|
+
onSelected: (C) => i.selectedOptionHandler(C, y == null ? void 0 : y.name)
|
|
3121
|
+
}, null, 8, ["title", "options", "value", "onSelected"])) : typeof y.options == "boolean" ? (x(), I(a, {
|
|
3156
3122
|
key: 1,
|
|
3157
3123
|
"left-label": y == null ? void 0 : y.name,
|
|
3158
3124
|
"is-enabled": y == null ? void 0 : y.options,
|
|
3159
|
-
"onUpdate:isEnabled": (
|
|
3160
|
-
}, null, 8, ["left-label", "is-enabled", "onUpdate:isEnabled"])) :
|
|
3125
|
+
"onUpdate:isEnabled": (C) => i.changeStyleHandler(y == null ? void 0 : y.name, C)
|
|
3126
|
+
}, null, 8, ["left-label", "is-enabled", "onUpdate:isEnabled"])) : $("", !0)
|
|
3161
3127
|
]);
|
|
3162
3128
|
}), 256)),
|
|
3163
|
-
(
|
|
3129
|
+
(k = i.controls) != null && k.some((y) => (y == null ? void 0 : y.name) === "export") ? (x(), _("button", {
|
|
3164
3130
|
key: 0,
|
|
3165
3131
|
onClick: t[0] || (t[0] = (...y) => i.exportChart && i.exportChart(...y)),
|
|
3166
3132
|
class: "h-[32px] w-[32px] rounded-lg hover:bg-gray-100 duration-100 flex items-center justify-center"
|
|
3167
3133
|
}, [
|
|
3168
|
-
|
|
3134
|
+
Oe(f, {
|
|
3169
3135
|
height: "16",
|
|
3170
3136
|
width: "16",
|
|
3171
3137
|
class: "text-gray-800"
|
|
3172
3138
|
})
|
|
3173
|
-
])) :
|
|
3174
|
-
])) :
|
|
3139
|
+
])) : $("", !0)
|
|
3140
|
+
])) : $("", !0)
|
|
3175
3141
|
])
|
|
3176
3142
|
])
|
|
3177
3143
|
])),
|
|
3178
|
-
|
|
3179
|
-
n.widgetData ? (x(),
|
|
3144
|
+
m("div", Un, [
|
|
3145
|
+
n.widgetData ? (x(), I(Tt("bi-" + i.computedType), {
|
|
3180
3146
|
key: 0,
|
|
3181
3147
|
currentWidget: n.currentWidget,
|
|
3182
3148
|
"onUpdate:currentWidget": t[1] || (t[1] = (y) => n.currentWidget = y),
|
|
3183
3149
|
widgetData: n.widgetData,
|
|
3184
3150
|
"onUpdate:widgetData": t[2] || (t[2] = (y) => n.widgetData = y),
|
|
3185
3151
|
ref: "chart",
|
|
3186
|
-
dashboard:
|
|
3152
|
+
dashboard: r.dashboard,
|
|
3187
3153
|
title: i.computedTitle,
|
|
3188
|
-
widget:
|
|
3189
|
-
}, null, 40, ["currentWidget", "widgetData", "dashboard", "title", "widget"])) : (x(),
|
|
3154
|
+
widget: r.widget
|
|
3155
|
+
}, null, 40, ["currentWidget", "widgetData", "dashboard", "title", "widget"])) : (x(), I(u, {
|
|
3190
3156
|
key: 1,
|
|
3191
3157
|
class: "w-full h-full"
|
|
3192
3158
|
}))
|
|
3193
3159
|
])
|
|
3194
3160
|
], 2);
|
|
3195
3161
|
}
|
|
3196
|
-
const
|
|
3162
|
+
const Vn = /* @__PURE__ */ R($n, [["render", jn]]), In = {
|
|
3197
3163
|
props: {
|
|
3198
3164
|
title: { type: String, default: () => "Дані для відображення відсутні" },
|
|
3199
3165
|
text: {
|
|
@@ -3201,21 +3167,21 @@ const ei = /* @__PURE__ */ O(qn, [["render", Yn]]), ti = {
|
|
|
3201
3167
|
default: () => "Змініть параметри пошуку або спробуйте пізніше"
|
|
3202
3168
|
}
|
|
3203
3169
|
}
|
|
3204
|
-
},
|
|
3205
|
-
function
|
|
3206
|
-
return x(), _("div",
|
|
3207
|
-
|
|
3208
|
-
|
|
3209
|
-
t[0] || (t[0] =
|
|
3210
|
-
|
|
3211
|
-
|
|
3212
|
-
|
|
3170
|
+
}, zn = { class: "w-full overflow-hidden rounded vs-table-interface__table-wrp h-fit" }, Mn = { class: "p-5 min-h-[500px] flex flex-col justify-center items-center text-center" }, qn = { class: "max-w-sm mx-auto mt-6" }, Hn = { class: "font-medium text-gray-800 dark:text-neutral-200" }, Wn = { class: "mt-2 text-sm text-gray-500 dark:text-neutral-500" };
|
|
3171
|
+
function Jn(e, t, r, s, n, i) {
|
|
3172
|
+
return x(), _("div", zn, [
|
|
3173
|
+
m("div", null, [
|
|
3174
|
+
m("div", Mn, [
|
|
3175
|
+
t[0] || (t[0] = Ye('<svg class="w-48 mx-auto" viewBox="0 0 178 90" fill="none" xmlns="http://www.w3.org/2000/svg"><rect x="27" y="50.5" width="124" height="39" rx="7.5" fill="currentColor" class="fill-white dark:fill-neutral-800"></rect><rect x="27" y="50.5" width="124" height="39" rx="7.5" stroke="currentColor" class="stroke-gray-50 dark:stroke-neutral-700/10"></rect><rect x="34.5" y="58" width="24" height="24" rx="4" fill="currentColor" class="fill-gray-50 dark:fill-neutral-700/30"></rect><rect x="66.5" y="61" width="60" height="6" rx="3" fill="currentColor" class="fill-gray-50 dark:fill-neutral-700/30"></rect><rect x="66.5" y="73" width="77" height="6" rx="3" fill="currentColor" class="fill-gray-50 dark:fill-neutral-700/30"></rect><rect x="19.5" y="28.5" width="139" height="39" rx="7.5" fill="currentColor" class="fill-white dark:fill-neutral-800"></rect><rect x="19.5" y="28.5" width="139" height="39" rx="7.5" stroke="currentColor" class="stroke-gray-100 dark:stroke-neutral-700/30"></rect><rect x="27" y="36" width="24" height="24" rx="4" fill="currentColor" class="fill-gray-100 dark:fill-neutral-700/70"></rect><rect x="59" y="39" width="60" height="6" rx="3" fill="currentColor" class="fill-gray-100 dark:fill-neutral-700/70"></rect><rect x="59" y="51" width="92" height="6" rx="3" fill="currentColor" class="fill-gray-100 dark:fill-neutral-700/70"></rect><g filter="url(#filter1)"><rect x="12" y="6" width="154" height="40" rx="8" fill="currentColor" class="fill-white dark:fill-neutral-800" shape-rendering="crispEdges"></rect><rect x="12.5" y="6.5" width="153" height="39" rx="7.5" stroke="currentColor" class="stroke-gray-100 dark:stroke-neutral-700/60" shape-rendering="crispEdges"></rect><rect x="20" y="14" width="24" height="24" rx="4" fill="currentColor" class="fill-gray-200 dark:fill-neutral-700"></rect><rect x="52" y="17" width="60" height="6" rx="3" fill="currentColor" class="fill-gray-200 dark:fill-neutral-700"></rect><rect x="52" y="29" width="106" height="6" rx="3" fill="currentColor" class="fill-gray-200 dark:fill-neutral-700"></rect></g><defs><filter id="filter1" x="0" y="0" width="178" height="64" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB"><feFlood flood-opacity="0" result="BackgroundImageFix"></feFlood><feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"></feColorMatrix><feOffset dy="6"></feOffset><feGaussianBlur stdDeviation="6"></feGaussianBlur><feComposite in2="hardAlpha" operator="out"></feComposite><feColorMatrix type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.03 0"></feColorMatrix><feBlend mode="normal" in2="BackgroundImageFix" result="effect1_dropShadow_1187_14810"></feBlend><feBlend mode="normal" in="SourceGraphic" in2="effect1_dropShadow_1187_14810" result="shape"></feBlend></filter></defs></svg>', 1)),
|
|
3176
|
+
m("div", qn, [
|
|
3177
|
+
m("p", Hn, E(r.title), 1),
|
|
3178
|
+
m("p", Wn, E(r.text), 1)
|
|
3213
3179
|
])
|
|
3214
3180
|
])
|
|
3215
3181
|
])
|
|
3216
3182
|
]);
|
|
3217
3183
|
}
|
|
3218
|
-
const
|
|
3184
|
+
const Kn = /* @__PURE__ */ R(In, [["render", Jn]]), Xn = {}, Gn = {
|
|
3219
3185
|
class: "flex-shrink-0 size-3.5",
|
|
3220
3186
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3221
3187
|
width: "22",
|
|
@@ -3227,12 +3193,12 @@ const li = /* @__PURE__ */ O(ti, [["render", ai]]), ci = {}, ui = {
|
|
|
3227
3193
|
"stroke-linecap": "round",
|
|
3228
3194
|
"stroke-linejoin": "round"
|
|
3229
3195
|
};
|
|
3230
|
-
function
|
|
3231
|
-
return x(), _("svg",
|
|
3232
|
-
|
|
3196
|
+
function Qn(e, t) {
|
|
3197
|
+
return x(), _("svg", Gn, [...t[0] || (t[0] = [
|
|
3198
|
+
Ye('<line x1="21" x2="14" y1="4" y2="4"></line><line x1="10" x2="3" y1="4" y2="4"></line><line x1="21" x2="12" y1="12" y2="12"></line><line x1="8" x2="3" y1="12" y2="12"></line><line x1="21" x2="16" y1="20" y2="20"></line><line x1="12" x2="3" y1="20" y2="20"></line><line x1="14" x2="14" y1="2" y2="6"></line><line x1="8" x2="8" y1="10" y2="14"></line><line x1="16" x2="16" y1="18" y2="22"></line>', 9)
|
|
3233
3199
|
])]);
|
|
3234
3200
|
}
|
|
3235
|
-
const
|
|
3201
|
+
const Zn = /* @__PURE__ */ R(Xn, [["render", Qn]]), Yn = {}, ei = {
|
|
3236
3202
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3237
3203
|
viewBox: "0 0 24 24",
|
|
3238
3204
|
fill: "none",
|
|
@@ -3242,19 +3208,19 @@ const fi = /* @__PURE__ */ O(ci, [["render", di]]), hi = {}, pi = {
|
|
|
3242
3208
|
"stroke-linejoin": "round",
|
|
3243
3209
|
class: "icon icon-tabler icons-tabler-outline icon-tabler-refresh"
|
|
3244
3210
|
};
|
|
3245
|
-
function
|
|
3246
|
-
return x(), _("svg",
|
|
3247
|
-
|
|
3211
|
+
function ti(e, t) {
|
|
3212
|
+
return x(), _("svg", ei, [...t[0] || (t[0] = [
|
|
3213
|
+
m("path", {
|
|
3248
3214
|
stroke: "none",
|
|
3249
3215
|
d: "M0 0h24v24H0z",
|
|
3250
3216
|
fill: "none"
|
|
3251
3217
|
}, null, -1),
|
|
3252
|
-
|
|
3253
|
-
|
|
3218
|
+
m("path", { d: "M20 11a8.1 8.1 0 0 0 -15.5 -2m-.5 -4v4h4" }, null, -1),
|
|
3219
|
+
m("path", { d: "M4 13a8.1 8.1 0 0 0 15.5 2m.5 4v-4h-4" }, null, -1)
|
|
3254
3220
|
])]);
|
|
3255
3221
|
}
|
|
3256
|
-
const
|
|
3257
|
-
components: { filterIcon:
|
|
3222
|
+
const ri = /* @__PURE__ */ R(Yn, [["render", ti]]), si = {
|
|
3223
|
+
components: { filterIcon: Zn, refreshIcon: ri },
|
|
3258
3224
|
props: ["filterScheme"],
|
|
3259
3225
|
emits: ["filters:changed"],
|
|
3260
3226
|
data() {
|
|
@@ -3281,8 +3247,8 @@ const gi = /* @__PURE__ */ O(hi, [["render", mi]]), bi = {
|
|
|
3281
3247
|
this.isFilterVisible = !this.isFilterVisible;
|
|
3282
3248
|
},
|
|
3283
3249
|
handleFilterChange(e) {
|
|
3284
|
-
var t,
|
|
3285
|
-
this.filters = e, this.activeFilters = (
|
|
3250
|
+
var t, r;
|
|
3251
|
+
this.filters = e, this.activeFilters = (r = (t = this.$refs) == null ? void 0 : t.filter) == null ? void 0 : r.activeFilters, this.$emit("filters:changed", this.filters);
|
|
3286
3252
|
},
|
|
3287
3253
|
resetFilters() {
|
|
3288
3254
|
this.$refs.filter && this.$refs.filter.clearAll(), this.isFilterVisible = !1, this.$emit("filters:changed", ""), this.activeFilters = null;
|
|
@@ -3291,17 +3257,17 @@ const gi = /* @__PURE__ */ O(hi, [["render", mi]]), bi = {
|
|
|
3291
3257
|
this.isFilterVisible && e.classList.contains("filter-container") && (this.isFilterVisible = !1);
|
|
3292
3258
|
}
|
|
3293
3259
|
}
|
|
3294
|
-
},
|
|
3260
|
+
}, ni = { class: "flex items-center" }, ii = {
|
|
3295
3261
|
key: 0,
|
|
3296
3262
|
class: "font-medium text-[10px] min-w-[16px] py-0.5 px-[5px] bg-gray-800 text-white leading-3 rounded-full"
|
|
3297
3263
|
};
|
|
3298
|
-
function
|
|
3299
|
-
const o =
|
|
3300
|
-
return x(), _("div",
|
|
3301
|
-
|
|
3264
|
+
function oi(e, t, r, s, n, i) {
|
|
3265
|
+
const o = j("filterIcon"), a = j("VsFilterList");
|
|
3266
|
+
return x(), _("div", ni, [
|
|
3267
|
+
r.filterScheme ? (x(), I(a, {
|
|
3302
3268
|
key: 0,
|
|
3303
3269
|
ref: "filter",
|
|
3304
|
-
scheme:
|
|
3270
|
+
scheme: r.filterScheme,
|
|
3305
3271
|
closeFilterBtn: !0,
|
|
3306
3272
|
onFilterClose: t[1] || (t[1] = (f) => n.isFilterVisible = !1),
|
|
3307
3273
|
layout: "default",
|
|
@@ -3314,47 +3280,47 @@ function xi(e, t, s, r, n, i) {
|
|
|
3314
3280
|
background: !0,
|
|
3315
3281
|
onFilterChange: i.handleFilterChange
|
|
3316
3282
|
}, {
|
|
3317
|
-
button:
|
|
3318
|
-
|
|
3283
|
+
button: $t(() => [
|
|
3284
|
+
m("button", {
|
|
3319
3285
|
type: "button",
|
|
3320
3286
|
class: "py-2 px-2.5 ml-3 h-[38px] inline-flex items-center gap-x-1.5 text-xs font-medium rounded-lg border border-gray-200 bg-white text-gray-800 hover:bg-gray-50 disabled:opacity-50 disabled:pointer-events-none focus:outline-none focus:bg-gray-50",
|
|
3321
3287
|
onClick: t[0] || (t[0] = (...f) => i.toggleFilterShown && i.toggleFilterShown(...f))
|
|
3322
3288
|
}, [
|
|
3323
|
-
|
|
3324
|
-
t[2] || (t[2] =
|
|
3325
|
-
i.activeFiltersCount >= 1 ? (x(), _("span",
|
|
3289
|
+
Oe(o),
|
|
3290
|
+
t[2] || (t[2] = Ze(" Фільтри ", -1)),
|
|
3291
|
+
i.activeFiltersCount >= 1 ? (x(), _("span", ii, E(i.activeFiltersCount), 1)) : $("", !0)
|
|
3326
3292
|
])
|
|
3327
3293
|
]),
|
|
3328
3294
|
_: 1
|
|
3329
|
-
}, 8, ["scheme", "token", "onFilterChange"])) :
|
|
3295
|
+
}, 8, ["scheme", "token", "onFilterChange"])) : $("", !0)
|
|
3330
3296
|
]);
|
|
3331
3297
|
}
|
|
3332
|
-
const
|
|
3298
|
+
const ai = /* @__PURE__ */ R(si, [["render", oi]]), li = {
|
|
3333
3299
|
props: ["dashboardData", "filters"],
|
|
3334
|
-
components: { VsFilterHeader:
|
|
3335
|
-
},
|
|
3300
|
+
components: { VsFilterHeader: ai }
|
|
3301
|
+
}, ci = { class: "bg-white px-5 flex gap-4 h-[90px] border border-gray-200 mt-2 rounded-xl mb-2 pt-[3px] justify-between items-center" }, ui = { class: "grow" }, di = { class: "text-lg font-semibold text-stone-800 dark:text-neutral-200" }, fi = {
|
|
3336
3302
|
type: "button",
|
|
3337
3303
|
class: "inline-flex items-center text-sm gap-x-2 text-stone-800 hover:text-stone-500 focus:outline-none focus:text-stone-500 dark:text-neutral-200 dark:hover:text-neutral-400 dark:focus:text-neutral-400",
|
|
3338
3304
|
"data-clipboard-target": "#hs-erc",
|
|
3339
3305
|
"data-clipboard-action": "copy",
|
|
3340
3306
|
"data-clipboard-success-text": "Copied"
|
|
3341
3307
|
};
|
|
3342
|
-
function
|
|
3308
|
+
function hi(e, t, r, s, n, i) {
|
|
3343
3309
|
var a, f;
|
|
3344
|
-
const o =
|
|
3345
|
-
return x(), _("div",
|
|
3346
|
-
|
|
3347
|
-
|
|
3348
|
-
|
|
3310
|
+
const o = j("VsFilterHeader");
|
|
3311
|
+
return x(), _("div", ci, [
|
|
3312
|
+
m("div", ui, [
|
|
3313
|
+
m("h1", di, E((a = r.dashboardData) == null ? void 0 : a.title), 1),
|
|
3314
|
+
m("button", fi, E((f = r.dashboardData) == null ? void 0 : f.description), 1)
|
|
3349
3315
|
]),
|
|
3350
|
-
|
|
3351
|
-
filterScheme:
|
|
3352
|
-
"onFilters:changed": t[0] || (t[0] = (
|
|
3316
|
+
Oe(o, {
|
|
3317
|
+
filterScheme: r.filters,
|
|
3318
|
+
"onFilters:changed": t[0] || (t[0] = (u) => e.$emit("filters:changed", u))
|
|
3353
3319
|
}, null, 8, ["filterScheme"])
|
|
3354
3320
|
]);
|
|
3355
3321
|
}
|
|
3356
|
-
const
|
|
3357
|
-
components: { VsWidget:
|
|
3322
|
+
const pi = /* @__PURE__ */ R(li, [["render", hi]]), mi = {
|
|
3323
|
+
components: { VsWidget: Vn, VsNewNodata: Kn, VsHeader: pi },
|
|
3358
3324
|
props: ["id", "prefix"],
|
|
3359
3325
|
data() {
|
|
3360
3326
|
return {
|
|
@@ -3393,49 +3359,49 @@ const Oi = /* @__PURE__ */ O(Di, [["render", Ci]]), Ri = {
|
|
|
3393
3359
|
}[t] || "w-full";
|
|
3394
3360
|
},
|
|
3395
3361
|
async filterHandler(e) {
|
|
3396
|
-
var
|
|
3362
|
+
var r;
|
|
3397
3363
|
this.filterURl = "";
|
|
3398
3364
|
let t = "&filter=";
|
|
3399
|
-
(
|
|
3365
|
+
(r = e == null ? void 0 : e.url) != null && r.length && (e.url.split("|").forEach((n) => {
|
|
3400
3366
|
const i = n.split("=");
|
|
3401
3367
|
t += `${i[0]}=${i[1]}`;
|
|
3402
3368
|
}), this.filterURl += t);
|
|
3403
3369
|
}
|
|
3404
3370
|
}
|
|
3405
|
-
},
|
|
3406
|
-
function
|
|
3407
|
-
var
|
|
3408
|
-
const o =
|
|
3409
|
-
return x(), _("div",
|
|
3410
|
-
|
|
3411
|
-
(
|
|
3371
|
+
}, gi = { class: "w-full pb-8 overflow-y-auto" }, bi = { class: "grid flex-grow w-full grid-cols-12 gap-4 h-fit" };
|
|
3372
|
+
function wi(e, t, r, s, n, i) {
|
|
3373
|
+
var u, c, h;
|
|
3374
|
+
const o = j("VsHeader"), a = j("VsNewNodata"), f = j("VsWidget");
|
|
3375
|
+
return x(), _("div", gi, [
|
|
3376
|
+
m("div", null, [
|
|
3377
|
+
(u = n.dashboardData) != null && u.filters ? (x(), I(o, {
|
|
3412
3378
|
key: 0,
|
|
3413
|
-
filters: (
|
|
3379
|
+
filters: (c = n.dashboardData) == null ? void 0 : c.filters,
|
|
3414
3380
|
dashboardData: n.dashboardData,
|
|
3415
3381
|
"onFilters:changed": t[0] || (t[0] = (w) => i.filterHandler(w))
|
|
3416
|
-
}, null, 8, ["filters", "dashboardData"])) :
|
|
3382
|
+
}, null, 8, ["filters", "dashboardData"])) : $("", !0)
|
|
3417
3383
|
]),
|
|
3418
|
-
|
|
3419
|
-
n.error || !n.dashboardData ? (x(),
|
|
3384
|
+
m("div", bi, [
|
|
3385
|
+
n.error || !n.dashboardData ? (x(), I(a, {
|
|
3420
3386
|
key: 0,
|
|
3421
3387
|
class: "col-span-12"
|
|
3422
|
-
})) :
|
|
3423
|
-
(x(!0), _(
|
|
3424
|
-
var
|
|
3388
|
+
})) : $("", !0),
|
|
3389
|
+
(x(!0), _(F, null, P(((h = n.dashboardData) == null ? void 0 : h.panels) || [], (w, g) => {
|
|
3390
|
+
var d;
|
|
3425
3391
|
return x(), _("div", {
|
|
3426
|
-
key:
|
|
3427
|
-
class:
|
|
3392
|
+
key: g,
|
|
3393
|
+
class: J([`col-span-${w.col || 12}`, "flex flex-col gap-[10px]"])
|
|
3428
3394
|
}, [
|
|
3429
|
-
(
|
|
3395
|
+
(d = w.widgets) != null && d.length ? (x(!0), _(F, { key: 0 }, P(w.widgets, (p) => (x(), I(f, {
|
|
3430
3396
|
key: p,
|
|
3431
|
-
dashboard:
|
|
3397
|
+
dashboard: r.id,
|
|
3432
3398
|
widget: p,
|
|
3433
3399
|
"dashboard-widgets": n.dashboardData.widgets,
|
|
3434
3400
|
"filter-u-rl": n.filterURl
|
|
3435
|
-
}, null, 8, ["dashboard", "widget", "dashboard-widgets", "filter-u-rl"]))), 128)) : (x(),
|
|
3401
|
+
}, null, 8, ["dashboard", "widget", "dashboard-widgets", "filter-u-rl"]))), 128)) : (x(), I(f, {
|
|
3436
3402
|
key: 1,
|
|
3437
3403
|
class: "flex flex-col",
|
|
3438
|
-
dashboard:
|
|
3404
|
+
dashboard: r.id,
|
|
3439
3405
|
widget: w.widget,
|
|
3440
3406
|
"dashboard-widgets": n.dashboardData.widgets,
|
|
3441
3407
|
"filter-u-rl": n.filterURl
|
|
@@ -3445,9 +3411,9 @@ function Ni(e, t, s, r, n, i) {
|
|
|
3445
3411
|
])
|
|
3446
3412
|
]);
|
|
3447
3413
|
}
|
|
3448
|
-
const
|
|
3414
|
+
const ro = /* @__PURE__ */ R(mi, [["render", wi]]), yi = {
|
|
3449
3415
|
name: "VsPivotTable",
|
|
3450
|
-
mixins: [
|
|
3416
|
+
mixins: [M],
|
|
3451
3417
|
data() {
|
|
3452
3418
|
return {
|
|
3453
3419
|
values: null,
|
|
@@ -3470,46 +3436,46 @@ const bo = /* @__PURE__ */ O(Ri, [["render", Ni]]), Fi = {
|
|
|
3470
3436
|
const e = Array.from(
|
|
3471
3437
|
new Set(this.sourceData.map((t) => t[this.dimensions[0]]))
|
|
3472
3438
|
);
|
|
3473
|
-
this.dimensions[0].includes("date") ? this.xs = e.map((t) =>
|
|
3439
|
+
this.dimensions[0].includes("date") ? this.xs = e.map((t) => Te(t)) : this.xs = [...e], this.products = this.dimensions.filter((t, r) => r != 0), this.values = this.products.map((t, r) => ({
|
|
3474
3440
|
name: t,
|
|
3475
|
-
data: this.sourceData.filter((
|
|
3441
|
+
data: this.sourceData.filter((s) => parseFloat(s[t])).map((s) => V(parseFloat(s[t])))
|
|
3476
3442
|
}));
|
|
3477
3443
|
} catch (e) {
|
|
3478
3444
|
console.error(e);
|
|
3479
3445
|
}
|
|
3480
3446
|
}
|
|
3481
3447
|
}
|
|
3482
|
-
},
|
|
3448
|
+
}, xi = { class: "flex flex-col h-full p-5 space-y-4 rounded-xl custom-scrollbar" }, _i = { class: "overflow-x-auto [&::-webkit-scrollbar]:h-2 [&::-webkit-scrollbar-thumb]:rounded-full [&::-webkit-scrollbar-track]:bg-gray-100 [&::-webkit-scrollbar-thumb]:bg-gray-300 custom-scrollbar" }, Di = { class: "inline-block min-w-full align-middle" }, ki = { class: "min-w-full divide-y divide-gray-200" }, Si = { class: "space-x-2" }, vi = {
|
|
3483
3449
|
scope: "col",
|
|
3484
3450
|
class: "xl:min-w-[120px] min-w-48"
|
|
3485
|
-
},
|
|
3486
|
-
function
|
|
3487
|
-
return x(), _("div",
|
|
3488
|
-
|
|
3489
|
-
|
|
3490
|
-
|
|
3491
|
-
|
|
3492
|
-
|
|
3493
|
-
t[0] || (t[0] =
|
|
3451
|
+
}, Ei = { class: "py-2.5 text-text-start flex items-center gap-x-1 text-sm font-normal text-gray-500" }, Ci = { class: "divide-y divide-gray-200 text-[12px]" }, Ri = { class: "py-3 size-px whitespace-nowrap" }, Oi = { class: "flex items-center gap-x-3" }, Ti = { class: "font-medium text-gray-800" }, $i = { class: "py-3 size-px whitespace-nowrap" }, Ni = { class: "text-gray-600" };
|
|
3452
|
+
function Ai(e, t, r, s, n, i) {
|
|
3453
|
+
return x(), _("div", xi, [
|
|
3454
|
+
m("div", _i, [
|
|
3455
|
+
m("div", Di, [
|
|
3456
|
+
m("table", ki, [
|
|
3457
|
+
m("thead", null, [
|
|
3458
|
+
m("tr", Si, [
|
|
3459
|
+
t[0] || (t[0] = m("th", {
|
|
3494
3460
|
scope: "col",
|
|
3495
3461
|
class: "min-w-[200px]"
|
|
3496
3462
|
}, [
|
|
3497
|
-
|
|
3463
|
+
m("div", { class: "py-2.5 text-text-start flex items-center gap-x-1 text-sm font-normal text-gray-500" })
|
|
3498
3464
|
], -1)),
|
|
3499
|
-
(x(!0), _(
|
|
3500
|
-
|
|
3465
|
+
(x(!0), _(F, null, P(n.xs, (o) => (x(), _("th", vi, [
|
|
3466
|
+
m("div", Ei, E(o), 1)
|
|
3501
3467
|
]))), 256))
|
|
3502
3468
|
])
|
|
3503
3469
|
]),
|
|
3504
|
-
(x(!0), _(
|
|
3505
|
-
|
|
3506
|
-
|
|
3507
|
-
|
|
3508
|
-
|
|
3470
|
+
(x(!0), _(F, null, P(n.values, (o) => (x(), _("tbody", Ci, [
|
|
3471
|
+
m("tr", null, [
|
|
3472
|
+
m("td", Ri, [
|
|
3473
|
+
m("div", Oi, [
|
|
3474
|
+
m("span", Ti, E(o.name), 1)
|
|
3509
3475
|
])
|
|
3510
3476
|
]),
|
|
3511
|
-
(x(!0), _(
|
|
3512
|
-
|
|
3477
|
+
(x(!0), _(F, null, P(n.xs, (a, f) => (x(), _("td", $i, [
|
|
3478
|
+
m("span", Ni, E(o.data[f]), 1)
|
|
3513
3479
|
]))), 256))
|
|
3514
3480
|
])
|
|
3515
3481
|
]))), 256))
|
|
@@ -3518,26 +3484,26 @@ function Ji(e, t, s, r, n, i) {
|
|
|
3518
3484
|
])
|
|
3519
3485
|
]);
|
|
3520
3486
|
}
|
|
3521
|
-
const
|
|
3487
|
+
const Fi = /* @__PURE__ */ R(yi, [["render", Ai]]), Li = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
3522
3488
|
__proto__: null,
|
|
3523
|
-
default:
|
|
3489
|
+
default: Fi
|
|
3524
3490
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
3525
3491
|
export {
|
|
3526
|
-
|
|
3527
|
-
|
|
3528
|
-
|
|
3529
|
-
|
|
3530
|
-
|
|
3531
|
-
|
|
3492
|
+
ps as V,
|
|
3493
|
+
R as _,
|
|
3494
|
+
Y as a,
|
|
3495
|
+
Te as b,
|
|
3496
|
+
M as c,
|
|
3497
|
+
V as d,
|
|
3532
3498
|
v as e,
|
|
3533
|
-
|
|
3534
|
-
|
|
3535
|
-
|
|
3536
|
-
|
|
3537
|
-
|
|
3538
|
-
|
|
3539
|
-
|
|
3540
|
-
|
|
3541
|
-
|
|
3542
|
-
|
|
3499
|
+
Bi as f,
|
|
3500
|
+
Ss as g,
|
|
3501
|
+
Os as h,
|
|
3502
|
+
Hs as i,
|
|
3503
|
+
nn as j,
|
|
3504
|
+
pn as k,
|
|
3505
|
+
Fi as l,
|
|
3506
|
+
ro as m,
|
|
3507
|
+
Vn as n,
|
|
3508
|
+
ys as v
|
|
3543
3509
|
};
|