@oardi/ts-utils 0.0.55 → 0.0.56
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/extensions/array-extensions.d.ts +1 -1
- package/extensions/define-prototype-extension.d.ts +1 -0
- package/index.cjs +5 -5
- package/index.mjs +361 -341
- package/index.umd.js +5 -5
- package/package.json +1 -1
package/index.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const
|
|
1
|
+
const jt = {
|
|
2
2
|
xs: 0,
|
|
3
3
|
sm: 576,
|
|
4
4
|
md: 768,
|
|
@@ -7,7 +7,7 @@ const zt = {
|
|
|
7
7
|
xxl: 1400,
|
|
8
8
|
xxxl: 1600
|
|
9
9
|
};
|
|
10
|
-
class
|
|
10
|
+
class St {
|
|
11
11
|
static getScreenWidth() {
|
|
12
12
|
return document.documentElement.clientWidth;
|
|
13
13
|
}
|
|
@@ -15,65 +15,65 @@ class bt {
|
|
|
15
15
|
return document.documentElement.clientHeight;
|
|
16
16
|
}
|
|
17
17
|
}
|
|
18
|
-
class
|
|
19
|
-
static breakPoints =
|
|
18
|
+
class pt {
|
|
19
|
+
static breakPoints = jt;
|
|
20
20
|
static getCurrentBreakpoint() {
|
|
21
|
-
return
|
|
21
|
+
return pt.getBreakpointByScreenWidth(St.getScreenWidth());
|
|
22
22
|
}
|
|
23
|
-
static getBreakpointByScreenWidth(t =
|
|
23
|
+
static getBreakpointByScreenWidth(t = St.getScreenWidth()) {
|
|
24
24
|
let n = "xs";
|
|
25
|
-
for (const a of Object.keys(
|
|
26
|
-
|
|
25
|
+
for (const a of Object.keys(pt.breakPoints))
|
|
26
|
+
pt.breakPoints[a] <= t && (n = a);
|
|
27
27
|
return { breakpoint: n, screenWidth: t };
|
|
28
28
|
}
|
|
29
29
|
static isScreenGreaterThan(t) {
|
|
30
|
-
return
|
|
30
|
+
return St.getScreenWidth() > pt.breakPoints[t];
|
|
31
31
|
}
|
|
32
32
|
static isScreenSmallerThan(t) {
|
|
33
|
-
return
|
|
33
|
+
return St.getScreenWidth() < pt.breakPoints[t];
|
|
34
34
|
}
|
|
35
35
|
}
|
|
36
|
-
var
|
|
37
|
-
const
|
|
38
|
-
class
|
|
36
|
+
var et = /* @__PURE__ */ ((s) => (s.opera = "opera", s.firefox = "firefox", s.safari = "safari", s.ie = "ie", s.edgeLegacy = "edgeLegacy", s.edg = "edg", s.chrome = "chrome", s.iOS = "iOS", s.headlessChrome = "headlessChrome", s.nodeRuntime = "nodeRuntime", s.electron = "electron", s))(et || {});
|
|
37
|
+
const Pt = typeof navigator < "u" ? navigator.userAgent : "", lt = Pt.toLowerCase();
|
|
38
|
+
class rt {
|
|
39
39
|
/** check if current environment is running inside a browser */
|
|
40
40
|
static isBrowserEnv() {
|
|
41
41
|
return typeof window < "u" && typeof navigator < "u";
|
|
42
42
|
}
|
|
43
|
-
static isOpera(t =
|
|
43
|
+
static isOpera(t = lt) {
|
|
44
44
|
return this.isBrowserEnv() ? t.includes("opr/") || t.includes("opera") : !1;
|
|
45
45
|
}
|
|
46
|
-
static isFirefox(t =
|
|
46
|
+
static isFirefox(t = lt) {
|
|
47
47
|
return this.isBrowserEnv() ? t.includes("firefox") || typeof globalThis.InstallTrigger < "u" : !1;
|
|
48
48
|
}
|
|
49
|
-
static isSafari(t =
|
|
49
|
+
static isSafari(t = lt) {
|
|
50
50
|
if (!this.isBrowserEnv()) return !1;
|
|
51
51
|
const n = navigator.vendor && navigator.vendor.includes("Apple"), a = t.includes("safari"), k = !(t.includes("crios") || t.includes("chrome") || t.includes("android") || t.includes("opr/") || t.includes("edg"));
|
|
52
52
|
return n && a && k;
|
|
53
53
|
}
|
|
54
|
-
static isIOS(t =
|
|
54
|
+
static isIOS(t = lt) {
|
|
55
55
|
if (!this.isBrowserEnv()) return !1;
|
|
56
56
|
const n = /iphone|ipad|ipod/.test(t), a = t.includes("macintosh") && navigator.maxTouchPoints > 1;
|
|
57
57
|
return n || a;
|
|
58
58
|
}
|
|
59
59
|
static isEdgeLegacy() {
|
|
60
|
-
return this.isBrowserEnv() ? !!window.StyleMedia && !
|
|
60
|
+
return this.isBrowserEnv() ? !!window.StyleMedia && !lt.includes("edg/") : !1;
|
|
61
61
|
}
|
|
62
|
-
static isEdg(t =
|
|
62
|
+
static isEdg(t = lt) {
|
|
63
63
|
return this.isBrowserEnv() ? t.includes("edg/") : !1;
|
|
64
64
|
}
|
|
65
65
|
static isIE() {
|
|
66
66
|
return !this.isBrowserEnv() && typeof document > "u" ? !1 : !!document.documentMode;
|
|
67
67
|
}
|
|
68
|
-
static isChrome(t =
|
|
68
|
+
static isChrome(t = lt) {
|
|
69
69
|
if (!this.isBrowserEnv()) return !1;
|
|
70
70
|
const n = navigator.vendor && navigator.vendor.includes("Google"), a = t.includes("chrome") || t.includes("crios"), k = !this.isEdg(t) && !this.isOpera(t);
|
|
71
71
|
return n && a && k;
|
|
72
72
|
}
|
|
73
|
-
static isElectron(t =
|
|
73
|
+
static isElectron(t = lt) {
|
|
74
74
|
return typeof process < "u" && process.versions?.electron ? !0 : t.includes("electron");
|
|
75
75
|
}
|
|
76
|
-
static isHeadlessChrome(t =
|
|
76
|
+
static isHeadlessChrome(t = lt) {
|
|
77
77
|
return t.includes("headlesschrome");
|
|
78
78
|
}
|
|
79
79
|
static isNodeRuntime() {
|
|
@@ -81,43 +81,43 @@ class et {
|
|
|
81
81
|
}
|
|
82
82
|
static getCurrentBrowser() {
|
|
83
83
|
if (typeof navigator > "u") {
|
|
84
|
-
if (
|
|
85
|
-
if (
|
|
84
|
+
if (rt.isElectron()) return et.electron;
|
|
85
|
+
if (rt.isNodeRuntime()) return et.nodeRuntime;
|
|
86
86
|
throw new Error("navigator not set");
|
|
87
87
|
}
|
|
88
88
|
const t = navigator.userAgent.toLowerCase();
|
|
89
|
-
if (
|
|
90
|
-
if (
|
|
91
|
-
if (
|
|
92
|
-
if (
|
|
93
|
-
if (
|
|
94
|
-
if (
|
|
95
|
-
if (
|
|
96
|
-
if (
|
|
97
|
-
if (
|
|
98
|
-
if (
|
|
99
|
-
if (
|
|
89
|
+
if (rt.isOpera()) return et.opera;
|
|
90
|
+
if (rt.isFirefox()) return et.firefox;
|
|
91
|
+
if (rt.isSafari()) return et.safari;
|
|
92
|
+
if (rt.isIE()) return et.ie;
|
|
93
|
+
if (rt.isEdgeLegacy()) return et.edgeLegacy;
|
|
94
|
+
if (rt.isEdg()) return et.edg;
|
|
95
|
+
if (rt.isChrome()) return et.chrome;
|
|
96
|
+
if (rt.isIOS(t)) return et.iOS;
|
|
97
|
+
if (rt.isElectron(t)) return et.electron;
|
|
98
|
+
if (rt.isHeadlessChrome(t)) return et.headlessChrome;
|
|
99
|
+
if (rt.isNodeRuntime()) return et.nodeRuntime;
|
|
100
100
|
throw new Error("Browser could not be detected: " + t);
|
|
101
101
|
}
|
|
102
102
|
}
|
|
103
103
|
function de(s) {
|
|
104
104
|
return navigator.clipboard.writeText(s);
|
|
105
105
|
}
|
|
106
|
-
function
|
|
106
|
+
function Mt(s) {
|
|
107
107
|
return s && s.__esModule && Object.prototype.hasOwnProperty.call(s, "default") ? s.default : s;
|
|
108
108
|
}
|
|
109
|
-
var
|
|
110
|
-
var Yt =
|
|
111
|
-
function
|
|
112
|
-
return
|
|
109
|
+
var Et = { exports: {} };
|
|
110
|
+
var Yt = Et.exports, It;
|
|
111
|
+
function Ut() {
|
|
112
|
+
return It || (It = 1, (function(s, t) {
|
|
113
113
|
((n, a) => {
|
|
114
114
|
s.exports = a();
|
|
115
115
|
})(Yt, function n() {
|
|
116
|
-
var a = typeof self < "u" ? self : typeof window < "u" ? window : a !== void 0 ? a : {}, k, D = !a.document && !!a.postMessage, T = a.IS_PAPA_WORKER || !1,
|
|
117
|
-
function
|
|
116
|
+
var a = typeof self < "u" ? self : typeof window < "u" ? window : a !== void 0 ? a : {}, k, D = !a.document && !!a.postMessage, T = a.IS_PAPA_WORKER || !1, N = {}, K = 0, p = {};
|
|
117
|
+
function Y(e) {
|
|
118
118
|
this._handle = null, this._finished = !1, this._completed = !1, this._halted = !1, this._input = null, this._baseIndex = 0, this._partialLine = "", this._rowCount = 0, this._start = 0, this._nextChunk = null, this.isFirstChunk = !0, this._completeResults = { data: [], errors: [], meta: {} }, (function(r) {
|
|
119
|
-
var i =
|
|
120
|
-
i.chunkSize = parseInt(i.chunkSize), r.step || r.chunk || (i.chunkSize = null), this._handle = new
|
|
119
|
+
var i = ct(r);
|
|
120
|
+
i.chunkSize = parseInt(i.chunkSize), r.step || r.chunk || (i.chunkSize = null), this._handle = new nt(i), (this._handle.streamer = this)._config = i;
|
|
121
121
|
}).call(this, e), this.parseChunk = function(r, i) {
|
|
122
122
|
var u = parseInt(this._config.skipFirstNLines) || 0;
|
|
123
123
|
if (this.isFirstChunk && 0 < u) {
|
|
@@ -141,7 +141,7 @@ function Pt() {
|
|
|
141
141
|
}
|
|
142
142
|
function z(e) {
|
|
143
143
|
var r;
|
|
144
|
-
(e = e || {}).chunkSize || (e.chunkSize = p.RemoteChunkSize),
|
|
144
|
+
(e = e || {}).chunkSize || (e.chunkSize = p.RemoteChunkSize), Y.call(this, e), this._nextChunk = D ? function() {
|
|
145
145
|
this._readChunk(), this._chunkLoaded();
|
|
146
146
|
} : function() {
|
|
147
147
|
this._readChunk();
|
|
@@ -150,7 +150,7 @@ function Pt() {
|
|
|
150
150
|
}, this._readChunk = function() {
|
|
151
151
|
if (this._finished) this._chunkLoaded();
|
|
152
152
|
else {
|
|
153
|
-
if (r = new XMLHttpRequest(), this._config.withCredentials && (r.withCredentials = this._config.withCredentials), D || (r.onload =
|
|
153
|
+
if (r = new XMLHttpRequest(), this._config.withCredentials && (r.withCredentials = this._config.withCredentials), D || (r.onload = V(this._chunkLoaded, this), r.onerror = V(this._chunkError, this)), r.open(this._config.downloadRequestBody ? "POST" : "GET", this._input, !D), this._config.downloadRequestHeaders) {
|
|
154
154
|
var i, u = this._config.downloadRequestHeaders;
|
|
155
155
|
for (i in u) r.setRequestHeader(i, u[i]);
|
|
156
156
|
}
|
|
@@ -169,11 +169,11 @@ function Pt() {
|
|
|
169
169
|
i = r.statusText || i, this._sendError(new Error(i));
|
|
170
170
|
};
|
|
171
171
|
}
|
|
172
|
-
function
|
|
173
|
-
(e = e || {}).chunkSize || (e.chunkSize = p.LocalChunkSize),
|
|
172
|
+
function Q(e) {
|
|
173
|
+
(e = e || {}).chunkSize || (e.chunkSize = p.LocalChunkSize), Y.call(this, e);
|
|
174
174
|
var r, i, u = typeof FileReader < "u";
|
|
175
175
|
this.stream = function(m) {
|
|
176
|
-
this._input = m, i = m.slice || m.webkitSlice || m.mozSlice, u ? ((r = new FileReader()).onload =
|
|
176
|
+
this._input = m, i = m.slice || m.webkitSlice || m.mozSlice, u ? ((r = new FileReader()).onload = V(this._chunkLoaded, this), r.onerror = V(this._chunkError, this)) : r = new FileReaderSync(), this._nextChunk();
|
|
177
177
|
}, this._nextChunk = function() {
|
|
178
178
|
this._finished || this._config.preview && !(this._rowCount < this._config.preview) || this._readChunk();
|
|
179
179
|
}, this._readChunk = function() {
|
|
@@ -185,53 +185,53 @@ function Pt() {
|
|
|
185
185
|
this._sendError(r.error);
|
|
186
186
|
};
|
|
187
187
|
}
|
|
188
|
-
function
|
|
188
|
+
function q(e) {
|
|
189
189
|
var r;
|
|
190
|
-
|
|
190
|
+
Y.call(this, e = e || {}), this.stream = function(i) {
|
|
191
191
|
return r = i, this._nextChunk();
|
|
192
192
|
}, this._nextChunk = function() {
|
|
193
193
|
var i, u;
|
|
194
194
|
if (!this._finished) return i = this._config.chunkSize, r = i ? (u = r.substring(0, i), r.substring(i)) : (u = r, ""), this._finished = !r, this.parseChunk(u);
|
|
195
195
|
};
|
|
196
196
|
}
|
|
197
|
-
function
|
|
198
|
-
|
|
197
|
+
function G(e) {
|
|
198
|
+
Y.call(this, e = e || {});
|
|
199
199
|
var r = [], i = !0, u = !1;
|
|
200
200
|
this.pause = function() {
|
|
201
|
-
|
|
201
|
+
Y.prototype.pause.apply(this, arguments), this._input.pause();
|
|
202
202
|
}, this.resume = function() {
|
|
203
|
-
|
|
203
|
+
Y.prototype.resume.apply(this, arguments), this._input.resume();
|
|
204
204
|
}, this.stream = function(m) {
|
|
205
205
|
this._input = m, this._input.on("data", this._streamData), this._input.on("end", this._streamEnd), this._input.on("error", this._streamError);
|
|
206
206
|
}, this._checkIsFinished = function() {
|
|
207
207
|
u && r.length === 1 && (this._finished = !0);
|
|
208
208
|
}, this._nextChunk = function() {
|
|
209
209
|
this._checkIsFinished(), r.length ? this.parseChunk(r.shift()) : i = !0;
|
|
210
|
-
}, this._streamData =
|
|
210
|
+
}, this._streamData = V(function(m) {
|
|
211
211
|
try {
|
|
212
212
|
r.push(typeof m == "string" ? m : m.toString(this._config.encoding)), i && (i = !1, this._checkIsFinished(), this.parseChunk(r.shift()));
|
|
213
213
|
} catch (S) {
|
|
214
214
|
this._streamError(S);
|
|
215
215
|
}
|
|
216
|
-
}, this), this._streamError =
|
|
216
|
+
}, this), this._streamError = V(function(m) {
|
|
217
217
|
this._streamCleanUp(), this._sendError(m);
|
|
218
|
-
}, this), this._streamEnd =
|
|
218
|
+
}, this), this._streamEnd = V(function() {
|
|
219
219
|
this._streamCleanUp(), u = !0, this._streamData("");
|
|
220
|
-
}, this), this._streamCleanUp =
|
|
220
|
+
}, this), this._streamCleanUp = V(function() {
|
|
221
221
|
this._input.removeListener("data", this._streamData), this._input.removeListener("end", this._streamEnd), this._input.removeListener("error", this._streamError);
|
|
222
222
|
}, this);
|
|
223
223
|
}
|
|
224
|
-
function
|
|
224
|
+
function nt(e) {
|
|
225
225
|
var r, i, u, m, S = Math.pow(2, 53), y = -S, d = /^\s*-?(\d+\.?|\.\d+|\d+\.\d+)([eE][-+]?\d+)?\s*$/, l = /^((\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d\.\d+([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z)))$/, o = this, c = 0, f = 0, v = !1, g = !1, w = [], h = { data: [], errors: [], meta: {} };
|
|
226
226
|
function M(b) {
|
|
227
227
|
return e.skipEmptyLines === "greedy" ? b.join("").trim() === "" : b.length === 1 && b[0].length === 0;
|
|
228
228
|
}
|
|
229
229
|
function C() {
|
|
230
|
-
if (h && u && (
|
|
230
|
+
if (h && u && (B("Delimiter", "UndetectableDelimiter", "Unable to auto-detect delimiting character; defaulted to '" + p.DefaultDelimiter + "'"), u = !1), e.skipEmptyLines && (h.data = h.data.filter(function(_) {
|
|
231
231
|
return !M(_);
|
|
232
232
|
})), j()) {
|
|
233
|
-
let _ = function(I,
|
|
234
|
-
R(e.transformHeader) && (I = e.transformHeader(I,
|
|
233
|
+
let _ = function(I, P) {
|
|
234
|
+
R(e.transformHeader) && (I = e.transformHeader(I, P)), w.push(I);
|
|
235
235
|
};
|
|
236
236
|
if (h) if (Array.isArray(h.data[0])) {
|
|
237
237
|
for (var b = 0; j() && b < h.data.length; b++) h.data[b].forEach(_);
|
|
@@ -239,14 +239,14 @@ function Pt() {
|
|
|
239
239
|
} else h.data.forEach(_);
|
|
240
240
|
}
|
|
241
241
|
function x(_, I) {
|
|
242
|
-
for (var
|
|
243
|
-
var L = A, $ = _[A], $ = ((
|
|
244
|
-
if (d.test(
|
|
242
|
+
for (var P = e.header ? {} : [], A = 0; A < _.length; A++) {
|
|
243
|
+
var L = A, $ = _[A], $ = ((it, E) => ((U) => (e.dynamicTypingFunction && e.dynamicTyping[U] === void 0 && (e.dynamicTyping[U] = e.dynamicTypingFunction(U)), (e.dynamicTyping[U] || e.dynamicTyping) === !0))(it) ? E === "true" || E === "TRUE" || E !== "false" && E !== "FALSE" && (((U) => {
|
|
244
|
+
if (d.test(U) && (U = parseFloat(U), y < U && U < S))
|
|
245
245
|
return 1;
|
|
246
246
|
})(E) ? parseFloat(E) : l.test(E) ? new Date(E) : E === "" ? null : E) : E)(L = e.header ? A >= w.length ? "__parsed_extra" : w[A] : L, $ = e.transform ? e.transform($, L) : $);
|
|
247
|
-
L === "__parsed_extra" ? (
|
|
247
|
+
L === "__parsed_extra" ? (P[L] = P[L] || [], P[L].push($)) : P[L] = $;
|
|
248
248
|
}
|
|
249
|
-
return e.header && (A > w.length ?
|
|
249
|
+
return e.header && (A > w.length ? B("FieldMismatch", "TooManyFields", "Too many fields: expected " + w.length + " fields but parsed " + A, f + I) : A < w.length && B("FieldMismatch", "TooFewFields", "Too few fields: expected " + w.length + " fields but parsed " + A, f + I)), P;
|
|
250
250
|
}
|
|
251
251
|
var O;
|
|
252
252
|
h && (e.header || e.dynamicTyping || e.transform) && (O = 1, !h.data.length || Array.isArray(h.data[0]) ? (h.data = h.data.map(x), O = h.data.length) : h.data = x(h.data, 0), e.header && h.meta && (h.meta.fields = w), f += O);
|
|
@@ -254,22 +254,22 @@ function Pt() {
|
|
|
254
254
|
function j() {
|
|
255
255
|
return e.header && w.length === 0;
|
|
256
256
|
}
|
|
257
|
-
function
|
|
257
|
+
function B(b, x, O, _) {
|
|
258
258
|
b = { type: b, code: x, message: O }, _ !== void 0 && (b.row = _), h.errors.push(b);
|
|
259
259
|
}
|
|
260
260
|
R(e.step) && (m = e.step, e.step = function(b) {
|
|
261
261
|
h = b, j() ? C() : (C(), h.data.length !== 0 && (c += b.data.length, e.preview && c > e.preview ? i.abort() : (h.data = h.data[0], m(h, o))));
|
|
262
262
|
}), this.parse = function(b, x, O) {
|
|
263
|
-
var _ = e.quoteChar || '"', _ = (e.newline || (e.newline = this.guessLineEndings(b, _)), u = !1, e.delimiter ? R(e.delimiter) && (e.delimiter = e.delimiter(b), h.meta.delimiter = e.delimiter) : ((_ = ((I,
|
|
264
|
-
var
|
|
263
|
+
var _ = e.quoteChar || '"', _ = (e.newline || (e.newline = this.guessLineEndings(b, _)), u = !1, e.delimiter ? R(e.delimiter) && (e.delimiter = e.delimiter(b), h.meta.delimiter = e.delimiter) : ((_ = ((I, P, A, L, $) => {
|
|
264
|
+
var it, E, U, ht;
|
|
265
265
|
$ = $ || [",", " ", "|", ";", p.RECORD_SEP, p.UNIT_SEP];
|
|
266
|
-
for (var
|
|
267
|
-
for (var
|
|
268
|
-
0 <
|
|
266
|
+
for (var mt = 0; mt < $.length; mt++) {
|
|
267
|
+
for (var st, _t = $[mt], Z = 0, at = 0, J = 0, tt = (U = void 0, new gt({ comments: L, delimiter: _t, newline: P, preview: 10 }).parse(I)), ft = 0; ft < tt.data.length; ft++) A && M(tt.data[ft]) ? J++ : (st = tt.data[ft].length, at += st, U === void 0 ? U = st : 0 < st && (Z += Math.abs(st - U), U = st));
|
|
268
|
+
0 < tt.data.length && (at /= tt.data.length - J), (E === void 0 || Z <= E) && (ht === void 0 || ht < at) && 1.99 < at && (E = Z, it = _t, ht = at);
|
|
269
269
|
}
|
|
270
|
-
return { successful: !!(e.delimiter =
|
|
271
|
-
})(b, e.newline, e.skipEmptyLines, e.comments, e.delimitersToGuess)).successful ? e.delimiter = _.bestDelimiter : (u = !0, e.delimiter = p.DefaultDelimiter), h.meta.delimiter = e.delimiter),
|
|
272
|
-
return e.preview && e.header && _.preview++, r = b, i = new
|
|
270
|
+
return { successful: !!(e.delimiter = it), bestDelimiter: it };
|
|
271
|
+
})(b, e.newline, e.skipEmptyLines, e.comments, e.delimitersToGuess)).successful ? e.delimiter = _.bestDelimiter : (u = !0, e.delimiter = p.DefaultDelimiter), h.meta.delimiter = e.delimiter), ct(e));
|
|
272
|
+
return e.preview && e.header && _.preview++, r = b, i = new gt(_), h = i.parse(r, x, O), C(), v ? { meta: { paused: !0 } } : h || { meta: { paused: !1 } };
|
|
273
273
|
}, this.paused = function() {
|
|
274
274
|
return v;
|
|
275
275
|
}, this.pause = function() {
|
|
@@ -282,20 +282,20 @@ function Pt() {
|
|
|
282
282
|
g = !0, i.abort(), h.meta.aborted = !0, R(e.complete) && e.complete(h), r = "";
|
|
283
283
|
}, this.guessLineEndings = function(I, _) {
|
|
284
284
|
I = I.substring(0, 1048576);
|
|
285
|
-
var _ = new RegExp(
|
|
285
|
+
var _ = new RegExp(ut(_) + "([^]*?)" + ut(_), "gm"), O = (I = I.replace(_, "")).split("\r"), _ = I.split(`
|
|
286
286
|
`), I = 1 < _.length && _[0].length < O[0].length;
|
|
287
287
|
if (O.length === 1 || I) return `
|
|
288
288
|
`;
|
|
289
|
-
for (var
|
|
290
|
-
` &&
|
|
291
|
-
return
|
|
289
|
+
for (var P = 0, A = 0; A < O.length; A++) O[A][0] === `
|
|
290
|
+
` && P++;
|
|
291
|
+
return P >= O.length / 2 ? `\r
|
|
292
292
|
` : "\r";
|
|
293
293
|
};
|
|
294
294
|
}
|
|
295
|
-
function
|
|
295
|
+
function ut(e) {
|
|
296
296
|
return e.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
297
297
|
}
|
|
298
|
-
function
|
|
298
|
+
function gt(e) {
|
|
299
299
|
var r = (e = e || {}).delimiter, i = e.newline, u = e.comments, m = e.step, S = e.preview, y = e.fastMode, d = null, l = !1, o = e.quoteChar == null ? '"' : e.quoteChar, c = o;
|
|
300
300
|
if (e.escapeChar !== void 0 && (c = e.escapeChar), (typeof r != "string" || -1 < p.BAD_DELIMITERS.indexOf(r)) && (r = ","), u === r) throw new Error("Comment character same as delimiter");
|
|
301
301
|
u === !0 ? u = "#" : (typeof u != "string" || -1 < p.BAD_DELIMITERS.indexOf(u)) && (u = !1), i !== `
|
|
@@ -305,82 +305,82 @@ function Pt() {
|
|
|
305
305
|
var f = 0, v = !1;
|
|
306
306
|
this.parse = function(g, w, h) {
|
|
307
307
|
if (typeof g != "string") throw new Error("Input must be a string");
|
|
308
|
-
var M = g.length, C = r.length, j = i.length,
|
|
309
|
-
if (!g) return
|
|
308
|
+
var M = g.length, C = r.length, j = i.length, B = u.length, b = R(m), x = [], O = [], _ = [], I = f = 0;
|
|
309
|
+
if (!g) return Z();
|
|
310
310
|
if (y || y !== !1 && g.indexOf(o) === -1) {
|
|
311
|
-
for (var
|
|
312
|
-
if (_ =
|
|
313
|
-
else if (h) return
|
|
314
|
-
if (!u || _.substring(0,
|
|
311
|
+
for (var P = g.split(i), A = 0; A < P.length; A++) {
|
|
312
|
+
if (_ = P[A], f += _.length, A !== P.length - 1) f += i.length;
|
|
313
|
+
else if (h) return Z();
|
|
314
|
+
if (!u || _.substring(0, B) !== u) {
|
|
315
315
|
if (b) {
|
|
316
|
-
if (x = [],
|
|
317
|
-
} else
|
|
318
|
-
if (S && S <= A) return x = x.slice(0, S),
|
|
316
|
+
if (x = [], ht(_.split(r)), at(), v) return Z();
|
|
317
|
+
} else ht(_.split(r));
|
|
318
|
+
if (S && S <= A) return x = x.slice(0, S), Z(!0);
|
|
319
319
|
}
|
|
320
320
|
}
|
|
321
|
-
return
|
|
321
|
+
return Z();
|
|
322
322
|
}
|
|
323
|
-
for (var L = g.indexOf(r, f), $ = g.indexOf(i, f),
|
|
324
|
-
if ((E = g.indexOf(o, E + 1)) === -1) return h || O.push({ type: "Quotes", code: "MissingQuotes", message: "Quoted field unterminated", row: x.length, index: f }),
|
|
325
|
-
if (E === M - 1) return
|
|
323
|
+
for (var L = g.indexOf(r, f), $ = g.indexOf(i, f), it = new RegExp(ut(c) + ut(o), "g"), E = g.indexOf(o, f); ; ) if (g[f] === o) for (E = f, f++; ; ) {
|
|
324
|
+
if ((E = g.indexOf(o, E + 1)) === -1) return h || O.push({ type: "Quotes", code: "MissingQuotes", message: "Quoted field unterminated", row: x.length, index: f }), st();
|
|
325
|
+
if (E === M - 1) return st(g.substring(f, E).replace(it, o));
|
|
326
326
|
if (o === c && g[E + 1] === c) E++;
|
|
327
327
|
else if (o === c || E === 0 || g[E - 1] !== c) {
|
|
328
328
|
L !== -1 && L < E + 1 && (L = g.indexOf(r, E + 1));
|
|
329
|
-
var
|
|
330
|
-
if (g.substr(E + 1 +
|
|
331
|
-
_.push(g.substring(f, E).replace(
|
|
329
|
+
var U = mt(($ = $ !== -1 && $ < E + 1 ? g.indexOf(i, E + 1) : $) === -1 ? L : Math.min(L, $));
|
|
330
|
+
if (g.substr(E + 1 + U, C) === r) {
|
|
331
|
+
_.push(g.substring(f, E).replace(it, o)), g[f = E + 1 + U + C] !== o && (E = g.indexOf(o, f)), L = g.indexOf(r, f), $ = g.indexOf(i, f);
|
|
332
332
|
break;
|
|
333
333
|
}
|
|
334
|
-
if (
|
|
335
|
-
if (_.push(g.substring(f, E).replace(
|
|
336
|
-
if (S && x.length >= S) return
|
|
334
|
+
if (U = mt($), g.substring(E + 1 + U, E + 1 + U + j) === i) {
|
|
335
|
+
if (_.push(g.substring(f, E).replace(it, o)), _t(E + 1 + U + j), L = g.indexOf(r, f), E = g.indexOf(o, f), b && (at(), v)) return Z();
|
|
336
|
+
if (S && x.length >= S) return Z(!0);
|
|
337
337
|
break;
|
|
338
338
|
}
|
|
339
339
|
O.push({ type: "Quotes", code: "InvalidQuotes", message: "Trailing quote on quoted field is malformed", row: x.length, index: f }), E++;
|
|
340
340
|
}
|
|
341
341
|
}
|
|
342
|
-
else if (u && _.length === 0 && g.substring(f, f +
|
|
343
|
-
if ($ === -1) return
|
|
342
|
+
else if (u && _.length === 0 && g.substring(f, f + B) === u) {
|
|
343
|
+
if ($ === -1) return Z();
|
|
344
344
|
f = $ + j, $ = g.indexOf(i, f), L = g.indexOf(r, f);
|
|
345
345
|
} else if (L !== -1 && (L < $ || $ === -1)) _.push(g.substring(f, L)), f = L + C, L = g.indexOf(r, f);
|
|
346
346
|
else {
|
|
347
347
|
if ($ === -1) break;
|
|
348
|
-
if (_.push(g.substring(f, $)),
|
|
349
|
-
if (S && x.length >= S) return
|
|
348
|
+
if (_.push(g.substring(f, $)), _t($ + j), b && (at(), v)) return Z();
|
|
349
|
+
if (S && x.length >= S) return Z(!0);
|
|
350
350
|
}
|
|
351
|
-
return
|
|
352
|
-
function
|
|
353
|
-
x.push(
|
|
351
|
+
return st();
|
|
352
|
+
function ht(J) {
|
|
353
|
+
x.push(J), I = f;
|
|
354
354
|
}
|
|
355
|
-
function
|
|
356
|
-
var
|
|
357
|
-
return
|
|
355
|
+
function mt(J) {
|
|
356
|
+
var tt = 0;
|
|
357
|
+
return tt = J !== -1 && (J = g.substring(E + 1, J)) && J.trim() === "" ? J.length : tt;
|
|
358
358
|
}
|
|
359
|
-
function
|
|
360
|
-
return h || (
|
|
359
|
+
function st(J) {
|
|
360
|
+
return h || (J === void 0 && (J = g.substring(f)), _.push(J), f = M, ht(_), b && at()), Z();
|
|
361
361
|
}
|
|
362
|
-
function
|
|
363
|
-
f =
|
|
362
|
+
function _t(J) {
|
|
363
|
+
f = J, ht(_), _ = [], $ = g.indexOf(i, f);
|
|
364
364
|
}
|
|
365
|
-
function
|
|
365
|
+
function Z(J) {
|
|
366
366
|
if (e.header && !w && x.length && !l) {
|
|
367
|
-
var
|
|
368
|
-
let
|
|
369
|
-
for (let
|
|
370
|
-
let
|
|
371
|
-
if (
|
|
372
|
-
let
|
|
373
|
-
for (;
|
|
374
|
-
|
|
375
|
-
} else
|
|
376
|
-
|
|
367
|
+
var tt = x[0], ft = /* @__PURE__ */ Object.create(null), $t = new Set(tt);
|
|
368
|
+
let Rt = !1;
|
|
369
|
+
for (let yt = 0; yt < tt.length; yt++) {
|
|
370
|
+
let ot = tt[yt];
|
|
371
|
+
if (ft[ot = R(e.transformHeader) ? e.transformHeader(ot, yt) : ot]) {
|
|
372
|
+
let kt, Tt = ft[ot];
|
|
373
|
+
for (; kt = ot + "_" + Tt, Tt++, $t.has(kt); ) ;
|
|
374
|
+
$t.add(kt), tt[yt] = kt, ft[ot]++, Rt = !0, (d = d === null ? {} : d)[kt] = ot;
|
|
375
|
+
} else ft[ot] = 1, tt[yt] = ot;
|
|
376
|
+
$t.add(ot);
|
|
377
377
|
}
|
|
378
|
-
|
|
378
|
+
Rt && console.warn("Duplicate headers found and renamed."), l = !0;
|
|
379
379
|
}
|
|
380
|
-
return { data: x, errors: O, meta: { delimiter: r, linebreak: i, aborted: v, truncated: !!
|
|
380
|
+
return { data: x, errors: O, meta: { delimiter: r, linebreak: i, aborted: v, truncated: !!J, cursor: I + (w || 0), renamedHeaders: d } };
|
|
381
381
|
}
|
|
382
|
-
function
|
|
383
|
-
m(
|
|
382
|
+
function at() {
|
|
383
|
+
m(Z()), x = [], O = [];
|
|
384
384
|
}
|
|
385
385
|
}, this.abort = function() {
|
|
386
386
|
v = !0;
|
|
@@ -388,34 +388,34 @@ function Pt() {
|
|
|
388
388
|
return f;
|
|
389
389
|
};
|
|
390
390
|
}
|
|
391
|
-
function
|
|
392
|
-
var r = e.data, i =
|
|
391
|
+
function wt(e) {
|
|
392
|
+
var r = e.data, i = N[r.workerId], u = !1;
|
|
393
393
|
if (r.error) i.userError(r.error, r.file);
|
|
394
394
|
else if (r.results && r.results.data) {
|
|
395
395
|
var m = { abort: function() {
|
|
396
|
-
u = !0,
|
|
397
|
-
}, pause:
|
|
396
|
+
u = !0, dt(r.workerId, { data: [], errors: [], meta: { aborted: !0 } });
|
|
397
|
+
}, pause: bt, resume: bt };
|
|
398
398
|
if (R(i.userStep)) {
|
|
399
399
|
for (var S = 0; S < r.results.data.length && (i.userStep({ data: r.results.data[S], errors: r.results.errors, meta: r.results.meta }, m), !u); S++) ;
|
|
400
400
|
delete r.results;
|
|
401
401
|
} else R(i.userChunk) && (i.userChunk(r.results, m, r.file), delete r.results);
|
|
402
402
|
}
|
|
403
|
-
r.finished && !u &&
|
|
403
|
+
r.finished && !u && dt(r.workerId, r.results);
|
|
404
404
|
}
|
|
405
|
-
function
|
|
406
|
-
var i =
|
|
407
|
-
R(i.userComplete) && i.userComplete(r), i.terminate(), delete
|
|
405
|
+
function dt(e, r) {
|
|
406
|
+
var i = N[e];
|
|
407
|
+
R(i.userComplete) && i.userComplete(r), i.terminate(), delete N[e];
|
|
408
408
|
}
|
|
409
|
-
function
|
|
409
|
+
function bt() {
|
|
410
410
|
throw new Error("Not implemented.");
|
|
411
411
|
}
|
|
412
|
-
function
|
|
412
|
+
function ct(e) {
|
|
413
413
|
if (typeof e != "object" || e === null) return e;
|
|
414
414
|
var r, i = Array.isArray(e) ? [] : {};
|
|
415
|
-
for (r in e) i[r] =
|
|
415
|
+
for (r in e) i[r] = ct(e[r]);
|
|
416
416
|
return i;
|
|
417
417
|
}
|
|
418
|
-
function
|
|
418
|
+
function V(e, r) {
|
|
419
419
|
return function() {
|
|
420
420
|
e.apply(r, arguments);
|
|
421
421
|
};
|
|
@@ -425,13 +425,13 @@ function Pt() {
|
|
|
425
425
|
}
|
|
426
426
|
return p.parse = function(e, r) {
|
|
427
427
|
var i = (r = r || {}).dynamicTyping || !1;
|
|
428
|
-
if (R(i) && (r.dynamicTypingFunction = i, i = {}), r.dynamicTyping = i, r.transform = !!R(r.transform) && r.transform, !r.worker || !p.WORKERS_SUPPORTED) return i = null, p.NODE_STREAM_INPUT, typeof e == "string" ? (e = ((u) => u.charCodeAt(0) !== 65279 ? u : u.slice(1))(e), i = new (r.download ? z :
|
|
428
|
+
if (R(i) && (r.dynamicTypingFunction = i, i = {}), r.dynamicTyping = i, r.transform = !!R(r.transform) && r.transform, !r.worker || !p.WORKERS_SUPPORTED) return i = null, p.NODE_STREAM_INPUT, typeof e == "string" ? (e = ((u) => u.charCodeAt(0) !== 65279 ? u : u.slice(1))(e), i = new (r.download ? z : q)(r)) : e.readable === !0 && R(e.read) && R(e.on) ? i = new G(r) : (a.File && e instanceof File || e instanceof Object) && (i = new Q(r)), i.stream(e);
|
|
429
429
|
(i = (() => {
|
|
430
430
|
var u;
|
|
431
431
|
return !!p.WORKERS_SUPPORTED && (u = (() => {
|
|
432
432
|
var m = a.URL || a.webkitURL || null, S = n.toString();
|
|
433
433
|
return p.BLOB_URL || (p.BLOB_URL = m.createObjectURL(new Blob(["var global = (function() { if (typeof self !== 'undefined') { return self; } if (typeof window !== 'undefined') { return window; } if (typeof global !== 'undefined') { return global; } return {}; })(); global.IS_PAPA_WORKER=true; ", "(", S, ")();"], { type: "text/javascript" })));
|
|
434
|
-
})(), (u = new a.Worker(u)).onmessage =
|
|
434
|
+
})(), (u = new a.Worker(u)).onmessage = wt, u.id = K++, N[u.id] = u);
|
|
435
435
|
})()).userStep = r.step, i.userChunk = r.chunk, i.userComplete = r.complete, i.userError = r.error, r.step = R(r.step), r.chunk = R(r.chunk), r.complete = R(r.complete), r.error = R(r.error), delete r.worker, i.postMessage({ input: e, config: r, workerId: i.id });
|
|
436
436
|
}, p.unparse = function(e, r) {
|
|
437
437
|
var i = !1, u = !0, m = ",", S = `\r
|
|
@@ -445,14 +445,14 @@ function Pt() {
|
|
|
445
445
|
}
|
|
446
446
|
r.escapeChar !== void 0 && (d = r.escapeChar + y), r.escapeFormulae instanceof RegExp ? c = r.escapeFormulae : typeof r.escapeFormulae == "boolean" && r.escapeFormulae && (c = /^[=+\-@\t\r].*$/);
|
|
447
447
|
}
|
|
448
|
-
})(), new RegExp(
|
|
448
|
+
})(), new RegExp(ut(y), "g"));
|
|
449
449
|
if (typeof e == "string" && (e = JSON.parse(e)), Array.isArray(e)) {
|
|
450
450
|
if (!e.length || Array.isArray(e[0])) return v(null, e, l);
|
|
451
451
|
if (typeof e[0] == "object") return v(o || Object.keys(e[0]), e, l);
|
|
452
452
|
} else if (typeof e == "object") return typeof e.data == "string" && (e.data = JSON.parse(e.data)), Array.isArray(e.data) && (e.fields || (e.fields = e.meta && e.meta.fields || o), e.fields || (e.fields = Array.isArray(e.data[0]) ? e.fields : typeof e.data[0] == "object" ? Object.keys(e.data[0]) : []), Array.isArray(e.data[0]) || typeof e.data[0] == "object" || (e.data = [e.data])), v(e.fields || [], e.data || [], l);
|
|
453
453
|
throw new Error("Unable to serialize unrecognized input");
|
|
454
454
|
function v(w, h, M) {
|
|
455
|
-
var C = "", j = (typeof w == "string" && (w = JSON.parse(w)), typeof h == "string" && (h = JSON.parse(h)), Array.isArray(w) && 0 < w.length),
|
|
455
|
+
var C = "", j = (typeof w == "string" && (w = JSON.parse(w)), typeof h == "string" && (h = JSON.parse(h)), Array.isArray(w) && 0 < w.length), B = !Array.isArray(h[0]);
|
|
456
456
|
if (j && u) {
|
|
457
457
|
for (var b = 0; b < w.length; b++) 0 < b && (C += m), C += g(w[b], b);
|
|
458
458
|
0 < h.length && (C += S);
|
|
@@ -460,17 +460,17 @@ function Pt() {
|
|
|
460
460
|
for (var x = 0; x < h.length; x++) {
|
|
461
461
|
var O = (j ? w : h[x]).length, _ = !1, I = j ? Object.keys(h[x]).length === 0 : h[x].length === 0;
|
|
462
462
|
if (M && !j && (_ = M === "greedy" ? h[x].join("").trim() === "" : h[x].length === 1 && h[x][0].length === 0), M === "greedy" && j) {
|
|
463
|
-
for (var
|
|
464
|
-
var L =
|
|
465
|
-
|
|
463
|
+
for (var P = [], A = 0; A < O; A++) {
|
|
464
|
+
var L = B ? w[A] : A;
|
|
465
|
+
P.push(h[x][L]);
|
|
466
466
|
}
|
|
467
|
-
_ =
|
|
467
|
+
_ = P.join("").trim() === "";
|
|
468
468
|
}
|
|
469
469
|
if (!_) {
|
|
470
470
|
for (var $ = 0; $ < O; $++) {
|
|
471
471
|
0 < $ && !I && (C += m);
|
|
472
|
-
var
|
|
473
|
-
C += g(h[x][
|
|
472
|
+
var it = j && B ? w[$] : $;
|
|
473
|
+
C += g(h[x][it], $);
|
|
474
474
|
}
|
|
475
475
|
x < h.length - 1 && (!M || 0 < O && !I) && (C += S);
|
|
476
476
|
}
|
|
@@ -479,13 +479,13 @@ function Pt() {
|
|
|
479
479
|
}
|
|
480
480
|
function g(w, h) {
|
|
481
481
|
var M, C;
|
|
482
|
-
return w == null ? "" : w.constructor === Date ? JSON.stringify(w).slice(1, 25) : (C = !1, c && typeof w == "string" && c.test(w) && (w = "'" + w, C = !0), M = w.toString().replace(f, d), (C = C || i === !0 || typeof i == "function" && i(w, h) || Array.isArray(i) && i[h] || ((j,
|
|
483
|
-
for (var b = 0; b <
|
|
482
|
+
return w == null ? "" : w.constructor === Date ? JSON.stringify(w).slice(1, 25) : (C = !1, c && typeof w == "string" && c.test(w) && (w = "'" + w, C = !0), M = w.toString().replace(f, d), (C = C || i === !0 || typeof i == "function" && i(w, h) || Array.isArray(i) && i[h] || ((j, B) => {
|
|
483
|
+
for (var b = 0; b < B.length; b++) if (-1 < j.indexOf(B[b])) return !0;
|
|
484
484
|
return !1;
|
|
485
485
|
})(M, p.BAD_DELIMITERS) || -1 < M.indexOf(m) || M.charAt(0) === " " || M.charAt(M.length - 1) === " ") ? y + M + y : M);
|
|
486
486
|
}
|
|
487
487
|
}, p.RECORD_SEP = "", p.UNIT_SEP = "", p.BYTE_ORDER_MARK = "\uFEFF", p.BAD_DELIMITERS = ["\r", `
|
|
488
|
-
`, '"', p.BYTE_ORDER_MARK], p.WORKERS_SUPPORTED = !D && !!a.Worker, p.NODE_STREAM_INPUT = 1, p.LocalChunkSize = 10485760, p.RemoteChunkSize = 5242880, p.DefaultDelimiter = ",", p.Parser =
|
|
488
|
+
`, '"', p.BYTE_ORDER_MARK], p.WORKERS_SUPPORTED = !D && !!a.Worker, p.NODE_STREAM_INPUT = 1, p.LocalChunkSize = 10485760, p.RemoteChunkSize = 5242880, p.DefaultDelimiter = ",", p.Parser = gt, p.ParserHandle = nt, p.NetworkStreamer = z, p.FileStreamer = Q, p.StringStreamer = q, p.ReadableStreamStreamer = G, a.jQuery && ((k = a.jQuery).fn.parse = function(e) {
|
|
489
489
|
var r = e.config || {}, i = [];
|
|
490
490
|
return this.each(function(S) {
|
|
491
491
|
if (!(k(this).prop("tagName").toUpperCase() === "INPUT" && k(this).attr("type").toLowerCase() === "file" && a.FileReader) || !this.files || this.files.length === 0) return !0;
|
|
@@ -514,19 +514,19 @@ function Pt() {
|
|
|
514
514
|
}
|
|
515
515
|
}), T && (a.onmessage = function(e) {
|
|
516
516
|
e = e.data, p.WORKER_ID === void 0 && e && (p.WORKER_ID = e.workerId), typeof e.input == "string" ? a.postMessage({ workerId: p.WORKER_ID, results: p.parse(e.input, e.config), finished: !0 }) : (a.File && e.input instanceof File || e.input instanceof Object) && (e = p.parse(e.input, e.config)) && a.postMessage({ workerId: p.WORKER_ID, results: e, finished: !0 });
|
|
517
|
-
}), (z.prototype = Object.create(
|
|
517
|
+
}), (z.prototype = Object.create(Y.prototype)).constructor = z, (Q.prototype = Object.create(Y.prototype)).constructor = Q, (q.prototype = Object.create(q.prototype)).constructor = q, (G.prototype = Object.create(Y.prototype)).constructor = G, p;
|
|
518
518
|
});
|
|
519
|
-
})(
|
|
519
|
+
})(Et)), Et.exports;
|
|
520
520
|
}
|
|
521
|
-
var
|
|
522
|
-
const
|
|
521
|
+
var Wt = Ut();
|
|
522
|
+
const Nt = /* @__PURE__ */ Mt(Wt), { parse: Bt, unparse: qt } = Nt;
|
|
523
523
|
class he {
|
|
524
524
|
static unparse(t, n) {
|
|
525
|
-
return
|
|
525
|
+
return qt(t, n);
|
|
526
526
|
}
|
|
527
527
|
static parse(t) {
|
|
528
528
|
return new Promise((n, a) => {
|
|
529
|
-
|
|
529
|
+
Bt(t, {
|
|
530
530
|
header: !0,
|
|
531
531
|
complete: (k) => n(k),
|
|
532
532
|
error: (k) => a(k)
|
|
@@ -534,24 +534,24 @@ class he {
|
|
|
534
534
|
});
|
|
535
535
|
}
|
|
536
536
|
}
|
|
537
|
-
async function
|
|
538
|
-
const a = n?.mimeType ??
|
|
537
|
+
async function Kt(s, t, n) {
|
|
538
|
+
const a = n?.mimeType ?? Qt(t), k = Jt(s, a);
|
|
539
539
|
if ("showSaveFilePicker" in window && n?.showSaveFilePicker)
|
|
540
540
|
try {
|
|
541
|
-
const
|
|
541
|
+
const K = await (await window.showSaveFilePicker({
|
|
542
542
|
suggestedName: t,
|
|
543
|
-
types: [{ description: "Datei", accept: { [a]: [`.${
|
|
543
|
+
types: [{ description: "Datei", accept: { [a]: [`.${zt(t)}`] } }]
|
|
544
544
|
})).createWritable();
|
|
545
|
-
await
|
|
545
|
+
await K.write(k), await K.close();
|
|
546
546
|
return;
|
|
547
547
|
} catch {
|
|
548
548
|
}
|
|
549
549
|
const D = URL.createObjectURL(k), T = document.createElement("a");
|
|
550
|
-
T.href = D, T.download = t, T.rel = "noopener", T.style.display = "none", document.body.appendChild(T),
|
|
550
|
+
T.href = D, T.download = t, T.rel = "noopener", T.style.display = "none", document.body.appendChild(T), T.click(), window.setTimeout(() => {
|
|
551
551
|
document.body.removeChild(T), URL.revokeObjectURL(D);
|
|
552
552
|
}, 0), Vt() && window.open(D, "_blank", "noopener,noreferrer");
|
|
553
553
|
}
|
|
554
|
-
function
|
|
554
|
+
function Jt(s, t) {
|
|
555
555
|
if (s instanceof Blob)
|
|
556
556
|
return s.type ? s : new Blob([s], { type: t });
|
|
557
557
|
if (s instanceof ArrayBuffer || s instanceof Uint8Array) {
|
|
@@ -560,8 +560,8 @@ function Kt(s, t) {
|
|
|
560
560
|
}
|
|
561
561
|
return new Blob([s], { type: t || "text/plain;charset=utf-8" });
|
|
562
562
|
}
|
|
563
|
-
function
|
|
564
|
-
switch (
|
|
563
|
+
function Qt(s) {
|
|
564
|
+
switch (zt(s).toLowerCase()) {
|
|
565
565
|
case "txt":
|
|
566
566
|
return "text/plain;charset=utf-8";
|
|
567
567
|
case "csv":
|
|
@@ -583,30 +583,10 @@ function Jt(s) {
|
|
|
583
583
|
return "application/octet-stream";
|
|
584
584
|
}
|
|
585
585
|
}
|
|
586
|
-
function
|
|
586
|
+
function zt(s) {
|
|
587
587
|
const t = s.lastIndexOf(".");
|
|
588
588
|
return t >= 0 && t < s.length - 1 ? s.slice(t + 1) : "";
|
|
589
589
|
}
|
|
590
|
-
function Qt(s) {
|
|
591
|
-
const t = document.createEvent("MouseEvents");
|
|
592
|
-
t.initMouseEvent(
|
|
593
|
-
"click",
|
|
594
|
-
!0,
|
|
595
|
-
!0,
|
|
596
|
-
window,
|
|
597
|
-
0,
|
|
598
|
-
0,
|
|
599
|
-
0,
|
|
600
|
-
0,
|
|
601
|
-
0,
|
|
602
|
-
!1,
|
|
603
|
-
!1,
|
|
604
|
-
!1,
|
|
605
|
-
!1,
|
|
606
|
-
0,
|
|
607
|
-
null
|
|
608
|
-
), s.dispatchEvent(t);
|
|
609
|
-
}
|
|
610
590
|
function Vt() {
|
|
611
591
|
const s = navigator.userAgent, t = /iPad|iPhone|iPod/.test(s), n = /^((?!chrome|android).)*safari/i.test(s);
|
|
612
592
|
return t || n;
|
|
@@ -673,15 +653,15 @@ class ge {
|
|
|
673
653
|
const k = 1024, D = ["Bytes", "KB", "MB", "GB", "TB"];
|
|
674
654
|
let T = Math.floor(Math.log(t) / Math.log(k));
|
|
675
655
|
a && D.includes(a) && (T = D.indexOf(a));
|
|
676
|
-
const
|
|
677
|
-
return `${parseFloat(
|
|
656
|
+
const N = t / Math.pow(k, T);
|
|
657
|
+
return `${parseFloat(N.toFixed(n))} ${D[T]}`;
|
|
678
658
|
}
|
|
679
659
|
static save(t, n, a) {
|
|
680
660
|
const k = new Blob([t], { type: a });
|
|
681
|
-
|
|
661
|
+
Kt(k, n);
|
|
682
662
|
}
|
|
683
663
|
}
|
|
684
|
-
class
|
|
664
|
+
class Ct {
|
|
685
665
|
static set(t, n) {
|
|
686
666
|
localStorage.setItem(t, JSON.stringify(n));
|
|
687
667
|
}
|
|
@@ -701,39 +681,39 @@ class $t {
|
|
|
701
681
|
return Object.keys(localStorage).filter((n) => n.startsWith(t));
|
|
702
682
|
}
|
|
703
683
|
}
|
|
704
|
-
var
|
|
705
|
-
class
|
|
684
|
+
var vt = /* @__PURE__ */ ((s) => (s.log = "log", s.info = "info", s.warn = "warn", s.debug = "debug", s.error = "error", s))(vt || {});
|
|
685
|
+
class X {
|
|
706
686
|
static listeners = /* @__PURE__ */ new Set();
|
|
707
687
|
static enabled = !0;
|
|
708
688
|
static log(...t) {
|
|
709
|
-
|
|
689
|
+
X.doLog(vt.log, t);
|
|
710
690
|
}
|
|
711
691
|
static info(...t) {
|
|
712
|
-
|
|
692
|
+
X.doLog(vt.info, t);
|
|
713
693
|
}
|
|
714
694
|
static warn(...t) {
|
|
715
|
-
|
|
695
|
+
X.doLog(vt.warn, t);
|
|
716
696
|
}
|
|
717
697
|
static debug(...t) {
|
|
718
|
-
|
|
698
|
+
X.doLog(vt.debug, t);
|
|
719
699
|
}
|
|
720
700
|
static error(...t) {
|
|
721
|
-
|
|
701
|
+
X.doLog(vt.error, t);
|
|
722
702
|
}
|
|
723
703
|
static clearListeners() {
|
|
724
|
-
|
|
704
|
+
X.listeners.clear();
|
|
725
705
|
}
|
|
726
706
|
static setEnabled(t) {
|
|
727
|
-
|
|
707
|
+
X.enabled = t;
|
|
728
708
|
}
|
|
729
709
|
static doLog(t, n) {
|
|
730
|
-
if (!
|
|
710
|
+
if (!X.enabled) return;
|
|
731
711
|
const a = {
|
|
732
712
|
type: t,
|
|
733
713
|
args: n,
|
|
734
714
|
timestamp: (/* @__PURE__ */ new Date()).toISOString()
|
|
735
715
|
};
|
|
736
|
-
for (const k of
|
|
716
|
+
for (const k of X.listeners)
|
|
737
717
|
try {
|
|
738
718
|
if (k(a) === !1)
|
|
739
719
|
return;
|
|
@@ -747,12 +727,12 @@ class G {
|
|
|
747
727
|
try {
|
|
748
728
|
return t(k);
|
|
749
729
|
} finally {
|
|
750
|
-
|
|
730
|
+
X.listeners.delete(a);
|
|
751
731
|
}
|
|
752
732
|
};
|
|
753
|
-
return
|
|
733
|
+
return X.listeners.add(a), () => X.listeners.delete(a);
|
|
754
734
|
}
|
|
755
|
-
return
|
|
735
|
+
return X.listeners.add(t), () => X.listeners.delete(t);
|
|
756
736
|
}
|
|
757
737
|
}
|
|
758
738
|
const Zt = (s, t, n) => s.localeCompare(t) * (n ? 1 : -1), Gt = (s, t) => s < t ? -1 : s === t ? 0 : 1, Xt = (s, t, n) => Gt(s, t) * (n ? 1 : -1), Ht = (s, t, n) => {
|
|
@@ -764,13 +744,13 @@ const Zt = (s, t, n) => s.localeCompare(t) * (n ? 1 : -1), Gt = (s, t) => s < t
|
|
|
764
744
|
};
|
|
765
745
|
class me {
|
|
766
746
|
static get(t) {
|
|
767
|
-
return
|
|
747
|
+
return Ct.get(t);
|
|
768
748
|
}
|
|
769
749
|
static set(t, n) {
|
|
770
|
-
|
|
750
|
+
Ct.set(t, n);
|
|
771
751
|
}
|
|
772
752
|
static remove(t) {
|
|
773
|
-
|
|
753
|
+
Ct.remove(t);
|
|
774
754
|
}
|
|
775
755
|
}
|
|
776
756
|
class F {
|
|
@@ -802,41 +782,49 @@ class F {
|
|
|
802
782
|
F.initialized && (F.listeners.delete(t), F.listeners.size === 0 && (F.resizeTimeout !== null && (window.clearTimeout(F.resizeTimeout), F.resizeTimeout = null), window.removeEventListener("resize", F.handleResize), F.initialized = !1, F.lastWidth = null));
|
|
803
783
|
}
|
|
804
784
|
}
|
|
785
|
+
function W(s, t, n) {
|
|
786
|
+
Object.defineProperty(s, t, {
|
|
787
|
+
configurable: !0,
|
|
788
|
+
enumerable: !1,
|
|
789
|
+
value: n,
|
|
790
|
+
writable: !0
|
|
791
|
+
});
|
|
792
|
+
}
|
|
805
793
|
function ye() {
|
|
806
|
-
Array.prototype
|
|
794
|
+
W(Array.prototype, "distinct", function(s) {
|
|
807
795
|
return s ? this.filter(
|
|
808
796
|
(n, a, k) => k.findIndex((D) => s(D, n)) === a
|
|
809
797
|
) : this.filter((n, a, k) => k.indexOf(n) === a);
|
|
810
|
-
}, Array.prototype
|
|
798
|
+
}), W(Array.prototype, "filterBy", function(s) {
|
|
811
799
|
return this.filter((t) => s(t));
|
|
812
|
-
}, Array.prototype
|
|
800
|
+
}), W(Array.prototype, "first", function() {
|
|
813
801
|
return this.length > 0 ? this[0] : null;
|
|
814
|
-
}, Array.prototype
|
|
802
|
+
}), W(Array.prototype, "groupBy", function(s) {
|
|
815
803
|
return this.reduce((t, n) => {
|
|
816
804
|
const a = s(n);
|
|
817
805
|
return t[a] || (t[a] = []), t[a].push(n), t;
|
|
818
806
|
}, {});
|
|
819
|
-
}, Array.prototype
|
|
807
|
+
}), W(Array.prototype, "orderBy", function(s, t = !0) {
|
|
820
808
|
return this?.sort((n, a) => te(n, a, s, t)), this;
|
|
821
|
-
}, Array.prototype
|
|
809
|
+
}), W(Array.prototype, "removeBy", function(s, t) {
|
|
822
810
|
return this.filter((n) => s(n) !== t);
|
|
823
|
-
};
|
|
811
|
+
});
|
|
824
812
|
}
|
|
825
|
-
var
|
|
813
|
+
var xt = { exports: {} }, ee = xt.exports, At;
|
|
826
814
|
function re() {
|
|
827
|
-
return
|
|
815
|
+
return At || (At = 1, (function(s, t) {
|
|
828
816
|
(function(n, a) {
|
|
829
817
|
s.exports = a();
|
|
830
818
|
})(ee, (function() {
|
|
831
|
-
var n = 1e3, a = 6e4, k = 36e5, D = "millisecond", T = "second",
|
|
819
|
+
var n = 1e3, a = 6e4, k = 36e5, D = "millisecond", T = "second", N = "minute", K = "hour", p = "day", Y = "week", z = "month", Q = "quarter", q = "year", G = "date", nt = "Invalid Date", ut = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, gt = /\[([^\]]+)]|YYYY|YY|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, wt = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(y) {
|
|
832
820
|
var d = ["th", "st", "nd", "rd"], l = y % 100;
|
|
833
821
|
return "[" + y + (d[(l - 20) % 10] || d[l] || d[0]) + "]";
|
|
834
|
-
} },
|
|
822
|
+
} }, dt = function(y, d, l) {
|
|
835
823
|
var o = String(y);
|
|
836
824
|
return !o || o.length >= d ? y : "" + Array(d + 1 - o.length).join(l) + y;
|
|
837
|
-
},
|
|
825
|
+
}, bt = { s: dt, z: function(y) {
|
|
838
826
|
var d = -y.utcOffset(), l = Math.abs(d), o = Math.floor(l / 60), c = l % 60;
|
|
839
|
-
return (d <= 0 ? "+" : "-") +
|
|
827
|
+
return (d <= 0 ? "+" : "-") + dt(o, 2, "0") + ":" + dt(c, 2, "0");
|
|
840
828
|
}, m: function y(d, l) {
|
|
841
829
|
if (d.date() < l.date()) return -y(l, d);
|
|
842
830
|
var o = 12 * (l.year() - d.year()) + (l.month() - d.month()), c = d.clone().add(o, z), f = l - c < 0, v = d.clone().add(o + (f ? -1 : 1), z);
|
|
@@ -844,31 +832,31 @@ function re() {
|
|
|
844
832
|
}, a: function(y) {
|
|
845
833
|
return y < 0 ? Math.ceil(y) || 0 : Math.floor(y);
|
|
846
834
|
}, p: function(y) {
|
|
847
|
-
return { M: z, y:
|
|
835
|
+
return { M: z, y: q, w: Y, d: p, D: G, h: K, m: N, s: T, ms: D, Q }[y] || String(y || "").toLowerCase().replace(/s$/, "");
|
|
848
836
|
}, u: function(y) {
|
|
849
837
|
return y === void 0;
|
|
850
|
-
} },
|
|
851
|
-
|
|
838
|
+
} }, ct = "en", V = {};
|
|
839
|
+
V[ct] = wt;
|
|
852
840
|
var R = "$isDayjsObject", e = function(y) {
|
|
853
841
|
return y instanceof m || !(!y || !y[R]);
|
|
854
842
|
}, r = function y(d, l, o) {
|
|
855
843
|
var c;
|
|
856
|
-
if (!d) return
|
|
844
|
+
if (!d) return ct;
|
|
857
845
|
if (typeof d == "string") {
|
|
858
846
|
var f = d.toLowerCase();
|
|
859
|
-
|
|
847
|
+
V[f] && (c = f), l && (V[f] = l, c = f);
|
|
860
848
|
var v = d.split("-");
|
|
861
849
|
if (!c && v.length > 1) return y(v[0]);
|
|
862
850
|
} else {
|
|
863
851
|
var g = d.name;
|
|
864
|
-
|
|
852
|
+
V[g] = d, c = g;
|
|
865
853
|
}
|
|
866
|
-
return !o && c && (
|
|
854
|
+
return !o && c && (ct = c), c || !o && ct;
|
|
867
855
|
}, i = function(y, d) {
|
|
868
856
|
if (e(y)) return y.clone();
|
|
869
857
|
var l = typeof d == "object" ? d : {};
|
|
870
858
|
return l.date = y, l.args = arguments, new m(l);
|
|
871
|
-
}, u =
|
|
859
|
+
}, u = bt;
|
|
872
860
|
u.l = r, u.i = e, u.w = function(y, d) {
|
|
873
861
|
return i(y, { locale: d.$L, utc: d.$u, x: d.$x, $offset: d.$offset });
|
|
874
862
|
};
|
|
@@ -884,7 +872,7 @@ function re() {
|
|
|
884
872
|
if (u.u(c)) return /* @__PURE__ */ new Date();
|
|
885
873
|
if (c instanceof Date) return new Date(c);
|
|
886
874
|
if (typeof c == "string" && !/Z$/i.test(c)) {
|
|
887
|
-
var v = c.match(
|
|
875
|
+
var v = c.match(ut);
|
|
888
876
|
if (v) {
|
|
889
877
|
var g = v[2] - 1 || 0, w = (v[7] || "0").substring(0, 3);
|
|
890
878
|
return f ? new Date(Date.UTC(v[1], g, v[3] || 1, v[4] || 0, v[5] || 0, v[6] || 0, w)) : new Date(v[1], g, v[3] || 1, v[4] || 0, v[5] || 0, v[6] || 0, w);
|
|
@@ -898,7 +886,7 @@ function re() {
|
|
|
898
886
|
}, d.$utils = function() {
|
|
899
887
|
return u;
|
|
900
888
|
}, d.isValid = function() {
|
|
901
|
-
return this.$d.toString() !==
|
|
889
|
+
return this.$d.toString() !== nt;
|
|
902
890
|
}, d.isSame = function(l, o) {
|
|
903
891
|
var c = i(l);
|
|
904
892
|
return this.startOf(o) <= c && c <= this.endOf(o);
|
|
@@ -920,19 +908,19 @@ function re() {
|
|
|
920
908
|
return u.w(c.toDate()[x].apply(c.toDate("s"), (f ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(O)), c);
|
|
921
909
|
}, h = this.$W, M = this.$M, C = this.$D, j = "set" + (this.$u ? "UTC" : "");
|
|
922
910
|
switch (v) {
|
|
923
|
-
case
|
|
911
|
+
case q:
|
|
924
912
|
return f ? g(1, 0) : g(31, 11);
|
|
925
913
|
case z:
|
|
926
914
|
return f ? g(1, M) : g(0, M + 1);
|
|
927
|
-
case
|
|
928
|
-
var
|
|
915
|
+
case Y:
|
|
916
|
+
var B = this.$locale().weekStart || 0, b = (h < B ? h + 7 : h) - B;
|
|
929
917
|
return g(f ? C - b : C + (6 - b), M);
|
|
930
918
|
case p:
|
|
931
|
-
case
|
|
919
|
+
case G:
|
|
932
920
|
return w(j + "Hours", 0);
|
|
933
|
-
case
|
|
921
|
+
case K:
|
|
934
922
|
return w(j + "Minutes", 1);
|
|
935
|
-
case
|
|
923
|
+
case N:
|
|
936
924
|
return w(j + "Seconds", 2);
|
|
937
925
|
case T:
|
|
938
926
|
return w(j + "Milliseconds", 3);
|
|
@@ -942,10 +930,10 @@ function re() {
|
|
|
942
930
|
}, d.endOf = function(l) {
|
|
943
931
|
return this.startOf(l, !1);
|
|
944
932
|
}, d.$set = function(l, o) {
|
|
945
|
-
var c, f = u.p(l), v = "set" + (this.$u ? "UTC" : ""), g = (c = {}, c[p] = v + "Date", c[
|
|
946
|
-
if (f === z || f ===
|
|
947
|
-
var h = this.clone().set(
|
|
948
|
-
h.$d[g](w), h.init(), this.$d = h.set(
|
|
933
|
+
var c, f = u.p(l), v = "set" + (this.$u ? "UTC" : ""), g = (c = {}, c[p] = v + "Date", c[G] = v + "Date", c[z] = v + "Month", c[q] = v + "FullYear", c[K] = v + "Hours", c[N] = v + "Minutes", c[T] = v + "Seconds", c[D] = v + "Milliseconds", c)[f], w = f === p ? this.$D + (o - this.$W) : o;
|
|
934
|
+
if (f === z || f === q) {
|
|
935
|
+
var h = this.clone().set(G, 1);
|
|
936
|
+
h.$d[g](w), h.init(), this.$d = h.set(G, Math.min(this.$D, h.daysInMonth())).$d;
|
|
949
937
|
} else g && this.$d[g](w);
|
|
950
938
|
return this.init(), this;
|
|
951
939
|
}, d.set = function(l, o) {
|
|
@@ -960,25 +948,25 @@ function re() {
|
|
|
960
948
|
return u.w(C.date(C.date() + Math.round(M * l)), f);
|
|
961
949
|
};
|
|
962
950
|
if (v === z) return this.set(z, this.$M + l);
|
|
963
|
-
if (v ===
|
|
951
|
+
if (v === q) return this.set(q, this.$y + l);
|
|
964
952
|
if (v === p) return g(1);
|
|
965
|
-
if (v ===
|
|
966
|
-
var w = (c = {}, c[
|
|
953
|
+
if (v === Y) return g(7);
|
|
954
|
+
var w = (c = {}, c[N] = a, c[K] = k, c[T] = n, c)[v] || 1, h = this.$d.getTime() + l * w;
|
|
967
955
|
return u.w(h, this);
|
|
968
956
|
}, d.subtract = function(l, o) {
|
|
969
957
|
return this.add(-1 * l, o);
|
|
970
958
|
}, d.format = function(l) {
|
|
971
959
|
var o = this, c = this.$locale();
|
|
972
|
-
if (!this.isValid()) return c.invalidDate ||
|
|
973
|
-
var f = l || "YYYY-MM-DDTHH:mm:ssZ", v = u.z(this), g = this.$H, w = this.$m, h = this.$M, M = c.weekdays, C = c.months, j = c.meridiem,
|
|
974
|
-
return O && (O[_] || O(o, f)) || I[_].slice(0,
|
|
960
|
+
if (!this.isValid()) return c.invalidDate || nt;
|
|
961
|
+
var f = l || "YYYY-MM-DDTHH:mm:ssZ", v = u.z(this), g = this.$H, w = this.$m, h = this.$M, M = c.weekdays, C = c.months, j = c.meridiem, B = function(O, _, I, P) {
|
|
962
|
+
return O && (O[_] || O(o, f)) || I[_].slice(0, P);
|
|
975
963
|
}, b = function(O) {
|
|
976
964
|
return u.s(g % 12 || 12, O, "0");
|
|
977
965
|
}, x = j || function(O, _, I) {
|
|
978
|
-
var
|
|
979
|
-
return I ?
|
|
966
|
+
var P = O < 12 ? "AM" : "PM";
|
|
967
|
+
return I ? P.toLowerCase() : P;
|
|
980
968
|
};
|
|
981
|
-
return f.replace(
|
|
969
|
+
return f.replace(gt, (function(O, _) {
|
|
982
970
|
return _ || (function(I) {
|
|
983
971
|
switch (I) {
|
|
984
972
|
case "YY":
|
|
@@ -990,9 +978,9 @@ function re() {
|
|
|
990
978
|
case "MM":
|
|
991
979
|
return u.s(h + 1, 2, "0");
|
|
992
980
|
case "MMM":
|
|
993
|
-
return
|
|
981
|
+
return B(c.monthsShort, h, C, 3);
|
|
994
982
|
case "MMMM":
|
|
995
|
-
return
|
|
983
|
+
return B(C, h);
|
|
996
984
|
case "D":
|
|
997
985
|
return o.$D;
|
|
998
986
|
case "DD":
|
|
@@ -1000,9 +988,9 @@ function re() {
|
|
|
1000
988
|
case "d":
|
|
1001
989
|
return String(o.$W);
|
|
1002
990
|
case "dd":
|
|
1003
|
-
return
|
|
991
|
+
return B(c.weekdaysMin, o.$W, M, 2);
|
|
1004
992
|
case "ddd":
|
|
1005
|
-
return
|
|
993
|
+
return B(c.weekdaysShort, o.$W, M, 3);
|
|
1006
994
|
case "dddd":
|
|
1007
995
|
return M[o.$W];
|
|
1008
996
|
case "H":
|
|
@@ -1040,25 +1028,25 @@ function re() {
|
|
|
1040
1028
|
return u.m(v, w);
|
|
1041
1029
|
};
|
|
1042
1030
|
switch (g) {
|
|
1043
|
-
case
|
|
1031
|
+
case q:
|
|
1044
1032
|
f = C() / 12;
|
|
1045
1033
|
break;
|
|
1046
1034
|
case z:
|
|
1047
1035
|
f = C();
|
|
1048
1036
|
break;
|
|
1049
|
-
case
|
|
1037
|
+
case Q:
|
|
1050
1038
|
f = C() / 3;
|
|
1051
1039
|
break;
|
|
1052
|
-
case
|
|
1040
|
+
case Y:
|
|
1053
1041
|
f = (M - h) / 6048e5;
|
|
1054
1042
|
break;
|
|
1055
1043
|
case p:
|
|
1056
1044
|
f = (M - h) / 864e5;
|
|
1057
1045
|
break;
|
|
1058
|
-
case
|
|
1046
|
+
case K:
|
|
1059
1047
|
f = M / k;
|
|
1060
1048
|
break;
|
|
1061
|
-
case
|
|
1049
|
+
case N:
|
|
1062
1050
|
f = M / a;
|
|
1063
1051
|
break;
|
|
1064
1052
|
case T:
|
|
@@ -1071,7 +1059,7 @@ function re() {
|
|
|
1071
1059
|
}, d.daysInMonth = function() {
|
|
1072
1060
|
return this.endOf(z).$D;
|
|
1073
1061
|
}, d.$locale = function() {
|
|
1074
|
-
return
|
|
1062
|
+
return V[this.$L];
|
|
1075
1063
|
}, d.locale = function(l, o) {
|
|
1076
1064
|
if (!l) return this.$L;
|
|
1077
1065
|
var c = this.clone(), f = r(l, o, !0);
|
|
@@ -1088,7 +1076,7 @@ function re() {
|
|
|
1088
1076
|
return this.$d.toUTCString();
|
|
1089
1077
|
}, y;
|
|
1090
1078
|
})(), S = m.prototype;
|
|
1091
|
-
return i.prototype = S, [["$ms", D], ["$s", T], ["$m",
|
|
1079
|
+
return i.prototype = S, [["$ms", D], ["$s", T], ["$m", N], ["$H", K], ["$W", p], ["$M", z], ["$y", q], ["$D", G]].forEach((function(y) {
|
|
1092
1080
|
S[y[1]] = function(d) {
|
|
1093
1081
|
return this.$g(d, y[0], y[1]);
|
|
1094
1082
|
};
|
|
@@ -1096,15 +1084,15 @@ function re() {
|
|
|
1096
1084
|
return y.$i || (y(d, m, i), y.$i = !0), i;
|
|
1097
1085
|
}, i.locale = r, i.isDayjs = e, i.unix = function(y) {
|
|
1098
1086
|
return i(1e3 * y);
|
|
1099
|
-
}, i.en =
|
|
1087
|
+
}, i.en = V[ct], i.Ls = V, i.p = {}, i;
|
|
1100
1088
|
}));
|
|
1101
|
-
})(
|
|
1089
|
+
})(xt)), xt.exports;
|
|
1102
1090
|
}
|
|
1103
1091
|
var ne = re();
|
|
1104
|
-
const
|
|
1105
|
-
var
|
|
1092
|
+
const H = /* @__PURE__ */ Mt(ne);
|
|
1093
|
+
var Ot = { exports: {} }, ie = Ot.exports, Lt;
|
|
1106
1094
|
function se() {
|
|
1107
|
-
return
|
|
1095
|
+
return Lt || (Lt = 1, (function(s, t) {
|
|
1108
1096
|
(function(n, a) {
|
|
1109
1097
|
s.exports = a();
|
|
1110
1098
|
})(ie, (function() {
|
|
@@ -1112,95 +1100,127 @@ function se() {
|
|
|
1112
1100
|
return function(a, k, D) {
|
|
1113
1101
|
var T = function(p) {
|
|
1114
1102
|
return p.add(4 - p.isoWeekday(), n);
|
|
1115
|
-
},
|
|
1116
|
-
|
|
1103
|
+
}, N = k.prototype;
|
|
1104
|
+
N.isoWeekYear = function() {
|
|
1117
1105
|
return T(this).year();
|
|
1118
|
-
},
|
|
1106
|
+
}, N.isoWeek = function(p) {
|
|
1119
1107
|
if (!this.$utils().u(p)) return this.add(7 * (p - this.isoWeek()), n);
|
|
1120
|
-
var
|
|
1121
|
-
return
|
|
1122
|
-
},
|
|
1108
|
+
var Y, z, Q, q, G = T(this), nt = (Y = this.isoWeekYear(), z = this.$u, Q = (z ? D.utc : D)().year(Y).startOf("year"), q = 4 - Q.isoWeekday(), Q.isoWeekday() > 4 && (q += 7), Q.add(q, n));
|
|
1109
|
+
return G.diff(nt, "week") + 1;
|
|
1110
|
+
}, N.isoWeekday = function(p) {
|
|
1123
1111
|
return this.$utils().u(p) ? this.day() || 7 : this.day(this.day() % 7 ? p : p - 7);
|
|
1124
1112
|
};
|
|
1125
|
-
var
|
|
1126
|
-
|
|
1127
|
-
var z = this.$utils(),
|
|
1128
|
-
return z.p(p) === "isoweek" ?
|
|
1113
|
+
var K = N.startOf;
|
|
1114
|
+
N.startOf = function(p, Y) {
|
|
1115
|
+
var z = this.$utils(), Q = !!z.u(Y) || Y;
|
|
1116
|
+
return z.p(p) === "isoweek" ? Q ? this.date(this.date() - (this.isoWeekday() - 1)).startOf("day") : this.date(this.date() - 1 - (this.isoWeekday() - 1) + 7).endOf("day") : K.bind(this)(p, Y);
|
|
1129
1117
|
};
|
|
1130
1118
|
};
|
|
1131
1119
|
}));
|
|
1132
|
-
})(
|
|
1120
|
+
})(Ot)), Ot.exports;
|
|
1133
1121
|
}
|
|
1134
1122
|
var ae = se();
|
|
1135
|
-
const oe = /* @__PURE__ */
|
|
1136
|
-
var
|
|
1123
|
+
const oe = /* @__PURE__ */ Mt(ae);
|
|
1124
|
+
var Dt = { exports: {} }, ue = Dt.exports, Ft;
|
|
1137
1125
|
function ce() {
|
|
1138
|
-
return
|
|
1126
|
+
return Ft || (Ft = 1, (function(s, t) {
|
|
1139
1127
|
(function(n, a) {
|
|
1140
1128
|
s.exports = a();
|
|
1141
1129
|
})(ue, (function() {
|
|
1142
1130
|
var n = { LTS: "h:mm:ss A", LT: "h:mm A", L: "MM/DD/YYYY", LL: "MMMM D, YYYY", LLL: "MMMM D, YYYY h:mm A", LLLL: "dddd, MMMM D, YYYY h:mm A" };
|
|
1143
1131
|
return function(a, k, D) {
|
|
1144
|
-
var T = k.prototype,
|
|
1145
|
-
D.en.formats = n, T.format = function(
|
|
1146
|
-
|
|
1147
|
-
var p = this.$locale().formats,
|
|
1148
|
-
return z.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g, (function(
|
|
1149
|
-
var
|
|
1150
|
-
return
|
|
1151
|
-
return
|
|
1132
|
+
var T = k.prototype, N = T.format;
|
|
1133
|
+
D.en.formats = n, T.format = function(K) {
|
|
1134
|
+
K === void 0 && (K = "YYYY-MM-DDTHH:mm:ssZ");
|
|
1135
|
+
var p = this.$locale().formats, Y = (function(z, Q) {
|
|
1136
|
+
return z.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g, (function(q, G, nt) {
|
|
1137
|
+
var ut = nt && nt.toUpperCase();
|
|
1138
|
+
return G || Q[nt] || n[nt] || Q[ut].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g, (function(gt, wt, dt) {
|
|
1139
|
+
return wt || dt.slice(1);
|
|
1152
1140
|
}));
|
|
1153
1141
|
}));
|
|
1154
|
-
})(
|
|
1155
|
-
return
|
|
1142
|
+
})(K, p === void 0 ? {} : p);
|
|
1143
|
+
return N.call(this, Y);
|
|
1156
1144
|
};
|
|
1157
1145
|
};
|
|
1158
1146
|
}));
|
|
1159
|
-
})(
|
|
1147
|
+
})(Dt)), Dt.exports;
|
|
1160
1148
|
}
|
|
1161
1149
|
var fe = ce();
|
|
1162
|
-
const le = /* @__PURE__ */
|
|
1163
|
-
|
|
1164
|
-
|
|
1150
|
+
const le = /* @__PURE__ */ Mt(fe);
|
|
1151
|
+
H.extend(le);
|
|
1152
|
+
H.extend(oe);
|
|
1165
1153
|
function ve() {
|
|
1166
|
-
|
|
1167
|
-
|
|
1168
|
-
|
|
1169
|
-
|
|
1170
|
-
|
|
1171
|
-
|
|
1172
|
-
|
|
1173
|
-
|
|
1174
|
-
|
|
1175
|
-
|
|
1176
|
-
|
|
1177
|
-
|
|
1178
|
-
|
|
1179
|
-
return
|
|
1180
|
-
}, Date.prototype
|
|
1181
|
-
return
|
|
1182
|
-
},
|
|
1183
|
-
|
|
1184
|
-
|
|
1185
|
-
|
|
1186
|
-
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1154
|
+
W(
|
|
1155
|
+
Date.prototype,
|
|
1156
|
+
"add",
|
|
1157
|
+
function(s, t) {
|
|
1158
|
+
return H(this).add(s, t).toDate();
|
|
1159
|
+
}
|
|
1160
|
+
), W(
|
|
1161
|
+
Date.prototype,
|
|
1162
|
+
"diff",
|
|
1163
|
+
function(s, t) {
|
|
1164
|
+
return H(this).diff(s, t);
|
|
1165
|
+
}
|
|
1166
|
+
), W(Date.prototype, "endOf", function(s) {
|
|
1167
|
+
return H(this).endOf(s).toDate();
|
|
1168
|
+
}), W(Date.prototype, "firstDayOfMonth", function() {
|
|
1169
|
+
return H(this).startOf("month").toDate();
|
|
1170
|
+
}), W(
|
|
1171
|
+
Date.prototype,
|
|
1172
|
+
"format",
|
|
1173
|
+
function(s) {
|
|
1174
|
+
return H(this).format(s);
|
|
1175
|
+
}
|
|
1176
|
+
), W(
|
|
1177
|
+
Date.prototype,
|
|
1178
|
+
"isAfter",
|
|
1179
|
+
function(s, t) {
|
|
1180
|
+
return H(this).isAfter(s, t);
|
|
1181
|
+
}
|
|
1182
|
+
), W(
|
|
1183
|
+
Date.prototype,
|
|
1184
|
+
"isBefore",
|
|
1185
|
+
function(s, t) {
|
|
1186
|
+
return H(this).isBefore(s, t);
|
|
1187
|
+
}
|
|
1188
|
+
), W(Date.prototype, "isValid", function() {
|
|
1189
|
+
return H(this).isValid();
|
|
1190
|
+
}), W(Date.prototype, "isoWeek", function() {
|
|
1191
|
+
return H(this).isoWeek();
|
|
1192
|
+
}), W(
|
|
1193
|
+
Date.prototype,
|
|
1194
|
+
"subtract",
|
|
1195
|
+
function(s, t) {
|
|
1196
|
+
return H(this).subtract(s, t).toDate();
|
|
1197
|
+
}
|
|
1198
|
+
), W(Date.prototype, "lastDayOfMonth", function() {
|
|
1199
|
+
return H(this).endOf("month").toDate();
|
|
1200
|
+
}), W(
|
|
1201
|
+
Date.prototype,
|
|
1202
|
+
"set",
|
|
1203
|
+
function(s, t) {
|
|
1204
|
+
return H(this).set(s, t).toDate();
|
|
1205
|
+
}
|
|
1206
|
+
), W(
|
|
1207
|
+
Date.prototype,
|
|
1208
|
+
"startOf",
|
|
1209
|
+
function(s) {
|
|
1210
|
+
return H(this).startOf(s).toDate();
|
|
1211
|
+
}
|
|
1212
|
+
);
|
|
1193
1213
|
}
|
|
1194
1214
|
function we() {
|
|
1195
|
-
String.prototype
|
|
1215
|
+
W(String.prototype, "capitalize", function() {
|
|
1196
1216
|
return this.charAt(0).toUpperCase() + this.slice(1);
|
|
1197
|
-
}, String.prototype
|
|
1217
|
+
}), W(String.prototype, "isNumber", function() {
|
|
1198
1218
|
return !isNaN(Number(this)) && this.trim() !== "";
|
|
1199
|
-
}, String.prototype
|
|
1219
|
+
}), W(String.prototype, "isEmpty", function() {
|
|
1200
1220
|
return this === void 0 || !this || this.length === 0;
|
|
1201
|
-
}, String.prototype
|
|
1221
|
+
}), W(String.prototype, "stripTags", function() {
|
|
1202
1222
|
return new DOMParser().parseFromString(this.toString(), "text/html").body.textContent || "";
|
|
1203
|
-
};
|
|
1223
|
+
});
|
|
1204
1224
|
}
|
|
1205
1225
|
class _e {
|
|
1206
1226
|
resizeListener = null;
|
|
@@ -1226,31 +1246,31 @@ class _e {
|
|
|
1226
1246
|
const t = window.innerWidth;
|
|
1227
1247
|
this.emitTimeoutId !== null && clearTimeout(this.emitTimeoutId), this.emitTimeoutId = window.setTimeout(() => {
|
|
1228
1248
|
this.emitTimeoutId = null;
|
|
1229
|
-
const n =
|
|
1249
|
+
const n = pt.getBreakpointByScreenWidth(t);
|
|
1230
1250
|
for (const a of this.onResizeCallbacks)
|
|
1231
1251
|
a(t, n);
|
|
1232
1252
|
}, this.duplicateThresholdMs);
|
|
1233
1253
|
};
|
|
1234
1254
|
}
|
|
1235
1255
|
export {
|
|
1236
|
-
|
|
1237
|
-
|
|
1238
|
-
|
|
1256
|
+
pt as BreakPointHelper,
|
|
1257
|
+
jt as BreakPoints,
|
|
1258
|
+
rt as BrowserHelper,
|
|
1239
1259
|
_e as BrowserService,
|
|
1240
|
-
|
|
1260
|
+
et as BrowserType,
|
|
1241
1261
|
he as CsvHelper,
|
|
1242
1262
|
pe as EnumHelper,
|
|
1243
1263
|
ge as FileHelper,
|
|
1244
|
-
|
|
1245
|
-
|
|
1246
|
-
|
|
1247
|
-
|
|
1264
|
+
Ct as LocalStorageHelper,
|
|
1265
|
+
X as LoggerHelper,
|
|
1266
|
+
vt as LoggerType,
|
|
1267
|
+
St as ScreenHelper,
|
|
1248
1268
|
me as TokenHelper,
|
|
1249
1269
|
F as WindowResizeHelper,
|
|
1250
1270
|
de as copyToClipboard,
|
|
1251
1271
|
ye as initArrayExtensions,
|
|
1252
1272
|
ve as initDateExtensions,
|
|
1253
1273
|
we as initStringExtensions,
|
|
1254
|
-
|
|
1274
|
+
Kt as saveAs,
|
|
1255
1275
|
te as sortHelper
|
|
1256
1276
|
};
|