@oardi/ts-utils 0.0.60 → 0.0.62
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/helpers/browser/browser-type.enum.d.ts +2 -0
- package/helpers/browser/browser.helper.d.ts +5 -2
- package/index.cjs +8 -8
- package/index.mjs +512 -486
- package/index.umd.js +7 -7
- package/package.json +1 -1
package/index.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const
|
|
1
|
+
const Ut = {
|
|
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,119 +15,142 @@ class bt {
|
|
|
15
15
|
return document.documentElement.clientHeight;
|
|
16
16
|
}
|
|
17
17
|
}
|
|
18
|
-
class
|
|
19
|
-
static breakPoints =
|
|
18
|
+
class ht {
|
|
19
|
+
static breakPoints = Ut;
|
|
20
20
|
static getCurrentBreakpoint() {
|
|
21
|
-
return
|
|
21
|
+
return ht.getBreakpointByScreenWidth(St.getScreenWidth());
|
|
22
22
|
}
|
|
23
|
-
static getBreakpointByScreenWidth(t =
|
|
23
|
+
static getBreakpointByScreenWidth(t = St.getScreenWidth()) {
|
|
24
24
|
let n = "xs";
|
|
25
|
-
for (const s of Object.keys(
|
|
26
|
-
|
|
25
|
+
for (const s of Object.keys(ht.breakPoints))
|
|
26
|
+
ht.breakPoints[s] <= t && (n = s);
|
|
27
27
|
return { breakpoint: n, screenWidth: t };
|
|
28
28
|
}
|
|
29
29
|
static isScreenGreaterThan(t) {
|
|
30
|
-
return
|
|
30
|
+
return St.getScreenWidth() > ht.breakPoints[t];
|
|
31
31
|
}
|
|
32
32
|
static isScreenSmallerThan(t) {
|
|
33
|
-
return
|
|
33
|
+
return St.getScreenWidth() < ht.breakPoints[t];
|
|
34
34
|
}
|
|
35
35
|
}
|
|
36
|
-
var
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
static isBrowserEnv() {
|
|
41
|
-
return typeof window < "u" && typeof navigator < "u";
|
|
42
|
-
}
|
|
43
|
-
static isOpera(t = dt) {
|
|
44
|
-
return this.isBrowserEnv() ? t.includes("opr/") || t.includes("opera") : !1;
|
|
45
|
-
}
|
|
46
|
-
static isFirefox(t = dt) {
|
|
47
|
-
return this.isBrowserEnv() ? t.includes("firefox") || typeof globalThis.InstallTrigger < "u" : !1;
|
|
48
|
-
}
|
|
49
|
-
static isSafari(t = dt) {
|
|
50
|
-
if (!this.isBrowserEnv()) return !1;
|
|
51
|
-
const n = navigator.vendor && navigator.vendor.includes("Apple"), s = t.includes("safari"), h = !(t.includes("crios") || t.includes("chrome") || t.includes("android") || t.includes("opr/") || t.includes("edg"));
|
|
52
|
-
return n && s && h;
|
|
36
|
+
var rt = /* @__PURE__ */ ((a) => (a.opera = "opera", a.firefox = "firefox", a.safari = "safari", a.ie = "ie", a.edgeLegacy = "edgeLegacy", a.edg = "edg", a.chrome = "chrome", a.iOS = "iOS", a.iOsSafari = "iOsSafari", a.edgiOs = "edgiOs", a.headlessChrome = "headlessChrome", a.nodeRuntime = "nodeRuntime", a.electron = "electron", a))(rt || {});
|
|
37
|
+
class X {
|
|
38
|
+
static getUserAgent() {
|
|
39
|
+
return this.isBrowserEnv() ? navigator.userAgent.toLowerCase() : "";
|
|
53
40
|
}
|
|
54
|
-
static
|
|
55
|
-
|
|
56
|
-
const n = /iphone|ipad|ipod/.test(t), s = t.includes("macintosh") && navigator.maxTouchPoints > 1;
|
|
57
|
-
return n || s;
|
|
41
|
+
static resolveUserAgent(t) {
|
|
42
|
+
return (t ?? this.getUserAgent()).toLowerCase();
|
|
58
43
|
}
|
|
59
|
-
static
|
|
60
|
-
return
|
|
44
|
+
static isBrowserEnv() {
|
|
45
|
+
return typeof window < "u" && typeof navigator < "u";
|
|
61
46
|
}
|
|
62
|
-
static
|
|
63
|
-
|
|
47
|
+
static isOpera(t) {
|
|
48
|
+
if (!this.isBrowserEnv())
|
|
49
|
+
return !1;
|
|
50
|
+
const n = this.resolveUserAgent(t);
|
|
51
|
+
return n.includes("opr/") || n.includes("opera");
|
|
52
|
+
}
|
|
53
|
+
static isFirefox(t) {
|
|
54
|
+
return this.isBrowserEnv() ? this.resolveUserAgent(t).includes("firefox") || typeof globalThis.InstallTrigger < "u" : !1;
|
|
55
|
+
}
|
|
56
|
+
static isSafari(t) {
|
|
57
|
+
if (!this.isBrowserEnv())
|
|
58
|
+
return !1;
|
|
59
|
+
const n = navigator.vendor.includes("Apple"), s = this.resolveUserAgent(t), d = s.includes("safari"), S = !(s.includes("crios") || s.includes("chrome") || s.includes("android") || s.includes("opr/") || s.includes("edg"));
|
|
60
|
+
return n && d && S;
|
|
61
|
+
}
|
|
62
|
+
static isIOS(t) {
|
|
63
|
+
if (!this.isBrowserEnv())
|
|
64
|
+
return !1;
|
|
65
|
+
const n = this.resolveUserAgent(t), s = /iphone|ipad|ipod/.test(n), d = n.includes("macintosh") && navigator.maxTouchPoints > 1;
|
|
66
|
+
return s || d;
|
|
67
|
+
}
|
|
68
|
+
static isIosSafari(t) {
|
|
69
|
+
if (!this.isBrowserEnv())
|
|
70
|
+
return !1;
|
|
71
|
+
const n = this.resolveUserAgent(t);
|
|
72
|
+
return this.isIOS(n) && this.isSafari(n);
|
|
73
|
+
}
|
|
74
|
+
static isEdgeLegacy(t) {
|
|
75
|
+
if (!this.isBrowserEnv())
|
|
76
|
+
return !1;
|
|
77
|
+
const n = this.resolveUserAgent(t);
|
|
78
|
+
return !!window.StyleMedia && !n.includes("edg/");
|
|
79
|
+
}
|
|
80
|
+
static isEdg(t) {
|
|
81
|
+
return this.isBrowserEnv() ? this.resolveUserAgent(t).includes("edg/") : !1;
|
|
82
|
+
}
|
|
83
|
+
static isEdgeIos(t) {
|
|
84
|
+
if (!this.isBrowserEnv())
|
|
85
|
+
return !1;
|
|
86
|
+
const n = this.resolveUserAgent(t);
|
|
87
|
+
return this.isIOS(n) && n.includes("edgios");
|
|
64
88
|
}
|
|
65
89
|
static isIE() {
|
|
66
|
-
return
|
|
90
|
+
return this.isBrowserEnv() ? typeof document < "u" && !!document.documentMode : !1;
|
|
67
91
|
}
|
|
68
|
-
static isChrome(t
|
|
69
|
-
if (!this.isBrowserEnv())
|
|
70
|
-
|
|
71
|
-
|
|
92
|
+
static isChrome(t) {
|
|
93
|
+
if (!this.isBrowserEnv())
|
|
94
|
+
return !1;
|
|
95
|
+
const n = this.resolveUserAgent(t), s = navigator.vendor.includes("Google"), d = n.includes("chrome") || n.includes("crios"), S = !this.isEdg(n) && !this.isOpera(n);
|
|
96
|
+
return s && d && S;
|
|
72
97
|
}
|
|
73
|
-
static isElectron(t
|
|
74
|
-
|
|
98
|
+
static isElectron(t) {
|
|
99
|
+
const n = !!(typeof process < "u" && process.versions?.electron), s = this.resolveUserAgent(t);
|
|
100
|
+
return n || s.includes("electron");
|
|
75
101
|
}
|
|
76
|
-
static isHeadlessChrome(t
|
|
77
|
-
return t.includes("headlesschrome");
|
|
102
|
+
static isHeadlessChrome(t) {
|
|
103
|
+
return this.isBrowserEnv() ? this.resolveUserAgent(t).includes("headlesschrome") : !1;
|
|
78
104
|
}
|
|
79
105
|
static isNodeRuntime() {
|
|
80
106
|
return typeof process < "u" && !!process.versions?.node && !this.isBrowserEnv();
|
|
81
107
|
}
|
|
82
108
|
static getCurrentBrowser() {
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
if (
|
|
90
|
-
if (
|
|
91
|
-
if (
|
|
92
|
-
if (
|
|
93
|
-
if (
|
|
94
|
-
if (
|
|
95
|
-
if (
|
|
96
|
-
if (
|
|
97
|
-
if (rt.isElectron(t)) return et.electron;
|
|
98
|
-
if (rt.isHeadlessChrome(t)) return et.headlessChrome;
|
|
99
|
-
if (rt.isNodeRuntime()) return et.nodeRuntime;
|
|
109
|
+
const t = X.getUserAgent();
|
|
110
|
+
if (X.isElectron(t)) return rt.electron;
|
|
111
|
+
if (X.isNodeRuntime()) return rt.nodeRuntime;
|
|
112
|
+
if (X.isOpera(t)) return rt.opera;
|
|
113
|
+
if (X.isFirefox(t)) return rt.firefox;
|
|
114
|
+
if (X.isEdgeIos(t)) return rt.edgiOs;
|
|
115
|
+
if (X.isIosSafari(t)) return rt.iOsSafari;
|
|
116
|
+
if (X.isIOS(t)) return rt.iOS;
|
|
117
|
+
if (X.isHeadlessChrome(t)) return rt.headlessChrome;
|
|
118
|
+
if (X.isIE()) return rt.ie;
|
|
119
|
+
if (X.isEdgeLegacy(t)) return rt.edgeLegacy;
|
|
120
|
+
if (X.isEdg(t)) return rt.edg;
|
|
121
|
+
if (X.isChrome(t)) return rt.chrome;
|
|
122
|
+
if (X.isSafari(t)) return rt.safari;
|
|
100
123
|
throw new Error("Browser could not be detected: " + t);
|
|
101
124
|
}
|
|
102
125
|
}
|
|
103
|
-
class
|
|
104
|
-
static toBlob(t, n, s = !1,
|
|
105
|
-
return new Promise((S,
|
|
126
|
+
class ae {
|
|
127
|
+
static toBlob(t, n, s = !1, d) {
|
|
128
|
+
return new Promise((S, z) => {
|
|
106
129
|
t.toBlob(
|
|
107
|
-
(
|
|
108
|
-
|
|
130
|
+
(T) => {
|
|
131
|
+
T ? S(T) : z(new Error("canvas.toBlob returned null"));
|
|
109
132
|
},
|
|
110
133
|
n,
|
|
111
|
-
s ?
|
|
134
|
+
s ? d : void 0
|
|
112
135
|
);
|
|
113
136
|
});
|
|
114
137
|
}
|
|
115
138
|
}
|
|
116
|
-
function
|
|
139
|
+
function oe(a) {
|
|
117
140
|
return navigator.clipboard.writeText(a);
|
|
118
141
|
}
|
|
119
|
-
function
|
|
142
|
+
function Dt(a) {
|
|
120
143
|
return a && a.__esModule && Object.prototype.hasOwnProperty.call(a, "default") ? a.default : a;
|
|
121
144
|
}
|
|
122
|
-
var
|
|
123
|
-
var
|
|
124
|
-
function
|
|
125
|
-
return
|
|
145
|
+
var bt = { exports: {} };
|
|
146
|
+
var Ft = bt.exports, Lt;
|
|
147
|
+
function zt() {
|
|
148
|
+
return Lt || (Lt = 1, (function(a, t) {
|
|
126
149
|
((n, s) => {
|
|
127
150
|
a.exports = s();
|
|
128
|
-
})(
|
|
129
|
-
var s = typeof self < "u" ? self : typeof window < "u" ? window : s !== void 0 ? s : {},
|
|
130
|
-
function
|
|
151
|
+
})(Ft, function n() {
|
|
152
|
+
var s = typeof self < "u" ? self : typeof window < "u" ? window : s !== void 0 ? s : {}, d, S = !s.document && !!s.postMessage, z = s.IS_PAPA_WORKER || !1, T = {}, K = 0, p = {};
|
|
153
|
+
function I(e) {
|
|
131
154
|
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) {
|
|
132
155
|
var i = ct(r);
|
|
133
156
|
i.chunkSize = parseInt(i.chunkSize), r.step || r.chunk || (i.chunkSize = null), this._handle = new nt(i), (this._handle.streamer = this)._config = i;
|
|
@@ -140,7 +163,7 @@ function Yt() {
|
|
|
140
163
|
this.isFirstChunk && R(this._config.beforeFirstChunk) && (y = this._config.beforeFirstChunk(r)) !== void 0 && (r = y), this.isFirstChunk = !1, this._halted = !1;
|
|
141
164
|
var u = this._partialLine + r, y = (this._partialLine = "", this._handle.parse(u, this._baseIndex, !this._finished));
|
|
142
165
|
if (!this._handle.paused() && !this._handle.aborted()) {
|
|
143
|
-
if (r = y.meta.cursor, u = (this._finished || (this._partialLine = u.substring(r - this._baseIndex), this._baseIndex = r), y && y.data && (this._rowCount += y.data.length), this._finished || this._config.preview && this._rowCount >= this._config.preview),
|
|
166
|
+
if (r = y.meta.cursor, u = (this._finished || (this._partialLine = u.substring(r - this._baseIndex), this._baseIndex = r), y && y.data && (this._rowCount += y.data.length), this._finished || this._config.preview && this._rowCount >= this._config.preview), z) s.postMessage({ results: y, workerId: p.WORKER_ID, finished: u });
|
|
144
167
|
else if (R(this._config.chunk) && !i) {
|
|
145
168
|
if (this._config.chunk(y, this._handle), this._handle.paused() || this._handle.aborted()) return void (this._halted = !0);
|
|
146
169
|
this._completeResults = y = void 0;
|
|
@@ -149,12 +172,12 @@ function Yt() {
|
|
|
149
172
|
}
|
|
150
173
|
this._halted = !0;
|
|
151
174
|
}, this._sendError = function(r) {
|
|
152
|
-
R(this._config.error) ? this._config.error(r) :
|
|
175
|
+
R(this._config.error) ? this._config.error(r) : z && this._config.error && s.postMessage({ workerId: p.WORKER_ID, error: r, finished: !1 });
|
|
153
176
|
};
|
|
154
177
|
}
|
|
155
178
|
function j(e) {
|
|
156
179
|
var r;
|
|
157
|
-
(e = e || {}).chunkSize || (e.chunkSize = p.RemoteChunkSize),
|
|
180
|
+
(e = e || {}).chunkSize || (e.chunkSize = p.RemoteChunkSize), I.call(this, e), this._nextChunk = S ? function() {
|
|
158
181
|
this._readChunk(), this._chunkLoaded();
|
|
159
182
|
} : function() {
|
|
160
183
|
this._readChunk();
|
|
@@ -183,7 +206,7 @@ function Yt() {
|
|
|
183
206
|
};
|
|
184
207
|
}
|
|
185
208
|
function Q(e) {
|
|
186
|
-
(e = e || {}).chunkSize || (e.chunkSize = p.LocalChunkSize),
|
|
209
|
+
(e = e || {}).chunkSize || (e.chunkSize = p.LocalChunkSize), I.call(this, e);
|
|
187
210
|
var r, i, u = typeof FileReader < "u";
|
|
188
211
|
this.stream = function(y) {
|
|
189
212
|
this._input = y, i = y.slice || y.webkitSlice || y.mozSlice, u ? ((r = new FileReader()).onload = V(this._chunkLoaded, this), r.onerror = V(this._chunkError, this)) : r = new FileReaderSync(), this._nextChunk();
|
|
@@ -200,7 +223,7 @@ function Yt() {
|
|
|
200
223
|
}
|
|
201
224
|
function q(e) {
|
|
202
225
|
var r;
|
|
203
|
-
|
|
226
|
+
I.call(this, e = e || {}), this.stream = function(i) {
|
|
204
227
|
return r = i, this._nextChunk();
|
|
205
228
|
}, this._nextChunk = function() {
|
|
206
229
|
var i, u;
|
|
@@ -208,12 +231,12 @@ function Yt() {
|
|
|
208
231
|
};
|
|
209
232
|
}
|
|
210
233
|
function G(e) {
|
|
211
|
-
|
|
234
|
+
I.call(this, e = e || {});
|
|
212
235
|
var r = [], i = !0, u = !1;
|
|
213
236
|
this.pause = function() {
|
|
214
|
-
|
|
237
|
+
I.prototype.pause.apply(this, arguments), this._input.pause();
|
|
215
238
|
}, this.resume = function() {
|
|
216
|
-
|
|
239
|
+
I.prototype.resume.apply(this, arguments), this._input.resume();
|
|
217
240
|
}, this.stream = function(y) {
|
|
218
241
|
this._input = y, this._input.on("data", this._streamData), this._input.on("end", this._streamEnd), this._input.on("error", this._streamError);
|
|
219
242
|
}, this._checkIsFinished = function() {
|
|
@@ -235,7 +258,7 @@ function Yt() {
|
|
|
235
258
|
}, this);
|
|
236
259
|
}
|
|
237
260
|
function nt(e) {
|
|
238
|
-
var r, i, u, y, E = Math.pow(2, 53), v = -E,
|
|
261
|
+
var r, i, u, y, E = Math.pow(2, 53), v = -E, h = /^\s*-?(\d+\.?|\.\d+|\d+\.\d+)([eE][-+]?\d+)?\s*$/, f = /^((\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, l = 0, w = !1, g = !1, k = [], m = { data: [], errors: [], meta: {} };
|
|
239
262
|
function M(b) {
|
|
240
263
|
return e.skipEmptyLines === "greedy" ? b.join("").trim() === "" : b.length === 1 && b[0].length === 0;
|
|
241
264
|
}
|
|
@@ -243,46 +266,46 @@ function Yt() {
|
|
|
243
266
|
if (m && u && (W("Delimiter", "UndetectableDelimiter", "Unable to auto-detect delimiting character; defaulted to '" + p.DefaultDelimiter + "'"), u = !1), e.skipEmptyLines && (m.data = m.data.filter(function(_) {
|
|
244
267
|
return !M(_);
|
|
245
268
|
})), Y()) {
|
|
246
|
-
let _ = function(L,
|
|
247
|
-
R(e.transformHeader) && (L = e.transformHeader(L,
|
|
269
|
+
let _ = function(L, B) {
|
|
270
|
+
R(e.transformHeader) && (L = e.transformHeader(L, B)), k.push(L);
|
|
248
271
|
};
|
|
249
272
|
if (m) if (Array.isArray(m.data[0])) {
|
|
250
273
|
for (var b = 0; Y() && b < m.data.length; b++) m.data[b].forEach(_);
|
|
251
274
|
m.data.splice(0, 1);
|
|
252
275
|
} else m.data.forEach(_);
|
|
253
276
|
}
|
|
254
|
-
function
|
|
255
|
-
for (var
|
|
256
|
-
var
|
|
257
|
-
if (
|
|
277
|
+
function x(_, L) {
|
|
278
|
+
for (var B = e.header ? {} : [], A = 0; A < _.length; A++) {
|
|
279
|
+
var U = A, $ = _[A], $ = ((it, O) => ((P) => (e.dynamicTypingFunction && e.dynamicTyping[P] === void 0 && (e.dynamicTyping[P] = e.dynamicTypingFunction(P)), (e.dynamicTyping[P] || e.dynamicTyping) === !0))(it) ? O === "true" || O === "TRUE" || O !== "false" && O !== "FALSE" && (((P) => {
|
|
280
|
+
if (h.test(P) && (P = parseFloat(P), v < P && P < E))
|
|
258
281
|
return 1;
|
|
259
|
-
})(
|
|
260
|
-
|
|
282
|
+
})(O) ? parseFloat(O) : f.test(O) ? new Date(O) : O === "" ? null : O) : O)(U = e.header ? A >= k.length ? "__parsed_extra" : k[A] : U, $ = e.transform ? e.transform($, U) : $);
|
|
283
|
+
U === "__parsed_extra" ? (B[U] = B[U] || [], B[U].push($)) : B[U] = $;
|
|
261
284
|
}
|
|
262
|
-
return e.header && (
|
|
285
|
+
return e.header && (A > k.length ? W("FieldMismatch", "TooManyFields", "Too many fields: expected " + k.length + " fields but parsed " + A, l + L) : A < k.length && W("FieldMismatch", "TooFewFields", "Too few fields: expected " + k.length + " fields but parsed " + A, l + L)), B;
|
|
263
286
|
}
|
|
264
|
-
var
|
|
265
|
-
m && (e.header || e.dynamicTyping || e.transform) && (
|
|
287
|
+
var D;
|
|
288
|
+
m && (e.header || e.dynamicTyping || e.transform) && (D = 1, !m.data.length || Array.isArray(m.data[0]) ? (m.data = m.data.map(x), D = m.data.length) : m.data = x(m.data, 0), e.header && m.meta && (m.meta.fields = k), l += D);
|
|
266
289
|
}
|
|
267
290
|
function Y() {
|
|
268
291
|
return e.header && k.length === 0;
|
|
269
292
|
}
|
|
270
|
-
function W(b,
|
|
271
|
-
b = { type: b, code:
|
|
293
|
+
function W(b, x, D, _) {
|
|
294
|
+
b = { type: b, code: x, message: D }, _ !== void 0 && (b.row = _), m.errors.push(b);
|
|
272
295
|
}
|
|
273
296
|
R(e.step) && (y = e.step, e.step = function(b) {
|
|
274
297
|
m = b, Y() ? C() : (C(), m.data.length !== 0 && (c += b.data.length, e.preview && c > e.preview ? i.abort() : (m.data = m.data[0], y(m, o))));
|
|
275
|
-
}), this.parse = function(b,
|
|
276
|
-
var _ = e.quoteChar || '"', _ = (e.newline || (e.newline = this.guessLineEndings(b, _)), u = !1, e.delimiter ? R(e.delimiter) && (e.delimiter = e.delimiter(b), m.meta.delimiter = e.delimiter) : ((_ = ((L,
|
|
277
|
-
var it,
|
|
298
|
+
}), this.parse = function(b, x, D) {
|
|
299
|
+
var _ = e.quoteChar || '"', _ = (e.newline || (e.newline = this.guessLineEndings(b, _)), u = !1, e.delimiter ? R(e.delimiter) && (e.delimiter = e.delimiter(b), m.meta.delimiter = e.delimiter) : ((_ = ((L, B, A, U, $) => {
|
|
300
|
+
var it, O, P, dt;
|
|
278
301
|
$ = $ || [",", " ", "|", ";", p.RECORD_SEP, p.UNIT_SEP];
|
|
279
|
-
for (var
|
|
280
|
-
for (var st,
|
|
281
|
-
0 <
|
|
302
|
+
for (var mt = 0; mt < $.length; mt++) {
|
|
303
|
+
for (var st, wt = $[mt], Z = 0, at = 0, J = 0, et = (P = void 0, new pt({ comments: U, delimiter: wt, newline: B, preview: 10 }).parse(L)), lt = 0; lt < et.data.length; lt++) A && M(et.data[lt]) ? J++ : (st = et.data[lt].length, at += st, P === void 0 ? P = st : 0 < st && (Z += Math.abs(st - P), P = st));
|
|
304
|
+
0 < et.data.length && (at /= et.data.length - J), (O === void 0 || Z <= O) && (dt === void 0 || dt < at) && 1.99 < at && (O = Z, it = wt, dt = at);
|
|
282
305
|
}
|
|
283
306
|
return { successful: !!(e.delimiter = it), bestDelimiter: it };
|
|
284
307
|
})(b, e.newline, e.skipEmptyLines, e.comments, e.delimitersToGuess)).successful ? e.delimiter = _.bestDelimiter : (u = !0, e.delimiter = p.DefaultDelimiter), m.meta.delimiter = e.delimiter), ct(e));
|
|
285
|
-
return e.preview && e.header && _.preview++, r = b, i = new
|
|
308
|
+
return e.preview && e.header && _.preview++, r = b, i = new pt(_), m = i.parse(r, x, D), C(), w ? { meta: { paused: !0 } } : m || { meta: { paused: !1 } };
|
|
286
309
|
}, this.paused = function() {
|
|
287
310
|
return w;
|
|
288
311
|
}, this.pause = function() {
|
|
@@ -295,21 +318,21 @@ function Yt() {
|
|
|
295
318
|
g = !0, i.abort(), m.meta.aborted = !0, R(e.complete) && e.complete(m), r = "";
|
|
296
319
|
}, this.guessLineEndings = function(L, _) {
|
|
297
320
|
L = L.substring(0, 1048576);
|
|
298
|
-
var _ = new RegExp(ut(_) + "([^]*?)" + ut(_), "gm"),
|
|
299
|
-
`), L = 1 < _.length && _[0].length <
|
|
300
|
-
if (
|
|
321
|
+
var _ = new RegExp(ut(_) + "([^]*?)" + ut(_), "gm"), D = (L = L.replace(_, "")).split("\r"), _ = L.split(`
|
|
322
|
+
`), L = 1 < _.length && _[0].length < D[0].length;
|
|
323
|
+
if (D.length === 1 || L) return `
|
|
301
324
|
`;
|
|
302
|
-
for (var
|
|
303
|
-
` &&
|
|
304
|
-
return
|
|
325
|
+
for (var B = 0, A = 0; A < D.length; A++) D[A][0] === `
|
|
326
|
+
` && B++;
|
|
327
|
+
return B >= D.length / 2 ? `\r
|
|
305
328
|
` : "\r";
|
|
306
329
|
};
|
|
307
330
|
}
|
|
308
331
|
function ut(e) {
|
|
309
332
|
return e.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
310
333
|
}
|
|
311
|
-
function
|
|
312
|
-
var r = (e = e || {}).delimiter, i = e.newline, u = e.comments, y = e.step, E = e.preview, v = e.fastMode,
|
|
334
|
+
function pt(e) {
|
|
335
|
+
var r = (e = e || {}).delimiter, i = e.newline, u = e.comments, y = e.step, E = e.preview, v = e.fastMode, h = null, f = !1, o = e.quoteChar == null ? '"' : e.quoteChar, c = o;
|
|
313
336
|
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");
|
|
314
337
|
u === !0 ? u = "#" : (typeof u != "string" || -1 < p.BAD_DELIMITERS.indexOf(u)) && (u = !1), i !== `
|
|
315
338
|
` && i !== "\r" && i !== `\r
|
|
@@ -318,82 +341,82 @@ function Yt() {
|
|
|
318
341
|
var l = 0, w = !1;
|
|
319
342
|
this.parse = function(g, k, m) {
|
|
320
343
|
if (typeof g != "string") throw new Error("Input must be a string");
|
|
321
|
-
var M = g.length, C = r.length, Y = i.length, W = u.length, b = R(y),
|
|
344
|
+
var M = g.length, C = r.length, Y = i.length, W = u.length, b = R(y), x = [], D = [], _ = [], L = l = 0;
|
|
322
345
|
if (!g) return Z();
|
|
323
346
|
if (v || v !== !1 && g.indexOf(o) === -1) {
|
|
324
|
-
for (var
|
|
325
|
-
if (_ =
|
|
347
|
+
for (var B = g.split(i), A = 0; A < B.length; A++) {
|
|
348
|
+
if (_ = B[A], l += _.length, A !== B.length - 1) l += i.length;
|
|
326
349
|
else if (m) return Z();
|
|
327
350
|
if (!u || _.substring(0, W) !== u) {
|
|
328
351
|
if (b) {
|
|
329
|
-
if (
|
|
330
|
-
} else
|
|
331
|
-
if (E && E <=
|
|
352
|
+
if (x = [], dt(_.split(r)), at(), w) return Z();
|
|
353
|
+
} else dt(_.split(r));
|
|
354
|
+
if (E && E <= A) return x = x.slice(0, E), Z(!0);
|
|
332
355
|
}
|
|
333
356
|
}
|
|
334
357
|
return Z();
|
|
335
358
|
}
|
|
336
|
-
for (var
|
|
337
|
-
if ((
|
|
338
|
-
if (
|
|
339
|
-
if (o === c && g[
|
|
340
|
-
else if (o === c ||
|
|
341
|
-
|
|
342
|
-
var
|
|
343
|
-
if (g.substr(
|
|
344
|
-
_.push(g.substring(l,
|
|
359
|
+
for (var U = g.indexOf(r, l), $ = g.indexOf(i, l), it = new RegExp(ut(c) + ut(o), "g"), O = g.indexOf(o, l); ; ) if (g[l] === o) for (O = l, l++; ; ) {
|
|
360
|
+
if ((O = g.indexOf(o, O + 1)) === -1) return m || D.push({ type: "Quotes", code: "MissingQuotes", message: "Quoted field unterminated", row: x.length, index: l }), st();
|
|
361
|
+
if (O === M - 1) return st(g.substring(l, O).replace(it, o));
|
|
362
|
+
if (o === c && g[O + 1] === c) O++;
|
|
363
|
+
else if (o === c || O === 0 || g[O - 1] !== c) {
|
|
364
|
+
U !== -1 && U < O + 1 && (U = g.indexOf(r, O + 1));
|
|
365
|
+
var P = mt(($ = $ !== -1 && $ < O + 1 ? g.indexOf(i, O + 1) : $) === -1 ? U : Math.min(U, $));
|
|
366
|
+
if (g.substr(O + 1 + P, C) === r) {
|
|
367
|
+
_.push(g.substring(l, O).replace(it, o)), g[l = O + 1 + P + C] !== o && (O = g.indexOf(o, l)), U = g.indexOf(r, l), $ = g.indexOf(i, l);
|
|
345
368
|
break;
|
|
346
369
|
}
|
|
347
|
-
if (
|
|
348
|
-
if (_.push(g.substring(l,
|
|
349
|
-
if (E &&
|
|
370
|
+
if (P = mt($), g.substring(O + 1 + P, O + 1 + P + Y) === i) {
|
|
371
|
+
if (_.push(g.substring(l, O).replace(it, o)), wt(O + 1 + P + Y), U = g.indexOf(r, l), O = g.indexOf(o, l), b && (at(), w)) return Z();
|
|
372
|
+
if (E && x.length >= E) return Z(!0);
|
|
350
373
|
break;
|
|
351
374
|
}
|
|
352
|
-
|
|
375
|
+
D.push({ type: "Quotes", code: "InvalidQuotes", message: "Trailing quote on quoted field is malformed", row: x.length, index: l }), O++;
|
|
353
376
|
}
|
|
354
377
|
}
|
|
355
378
|
else if (u && _.length === 0 && g.substring(l, l + W) === u) {
|
|
356
379
|
if ($ === -1) return Z();
|
|
357
|
-
l = $ + Y, $ = g.indexOf(i, l),
|
|
358
|
-
} else if (
|
|
380
|
+
l = $ + Y, $ = g.indexOf(i, l), U = g.indexOf(r, l);
|
|
381
|
+
} else if (U !== -1 && (U < $ || $ === -1)) _.push(g.substring(l, U)), l = U + C, U = g.indexOf(r, l);
|
|
359
382
|
else {
|
|
360
383
|
if ($ === -1) break;
|
|
361
|
-
if (_.push(g.substring(l, $)),
|
|
362
|
-
if (E &&
|
|
384
|
+
if (_.push(g.substring(l, $)), wt($ + Y), b && (at(), w)) return Z();
|
|
385
|
+
if (E && x.length >= E) return Z(!0);
|
|
363
386
|
}
|
|
364
387
|
return st();
|
|
365
|
-
function
|
|
366
|
-
|
|
388
|
+
function dt(J) {
|
|
389
|
+
x.push(J), L = l;
|
|
367
390
|
}
|
|
368
|
-
function
|
|
369
|
-
var
|
|
370
|
-
return
|
|
391
|
+
function mt(J) {
|
|
392
|
+
var et = 0;
|
|
393
|
+
return et = J !== -1 && (J = g.substring(O + 1, J)) && J.trim() === "" ? J.length : et;
|
|
371
394
|
}
|
|
372
395
|
function st(J) {
|
|
373
|
-
return m || (J === void 0 && (J = g.substring(l)), _.push(J), l = M,
|
|
396
|
+
return m || (J === void 0 && (J = g.substring(l)), _.push(J), l = M, dt(_), b && at()), Z();
|
|
374
397
|
}
|
|
375
|
-
function
|
|
376
|
-
l = J,
|
|
398
|
+
function wt(J) {
|
|
399
|
+
l = J, dt(_), _ = [], $ = g.indexOf(i, l);
|
|
377
400
|
}
|
|
378
401
|
function Z(J) {
|
|
379
|
-
if (e.header && !k &&
|
|
380
|
-
var
|
|
381
|
-
let
|
|
382
|
-
for (let
|
|
383
|
-
let ot =
|
|
384
|
-
if (lt[ot = R(e.transformHeader) ? e.transformHeader(ot,
|
|
385
|
-
let
|
|
386
|
-
for (;
|
|
387
|
-
|
|
388
|
-
} else lt[ot] = 1,
|
|
389
|
-
|
|
402
|
+
if (e.header && !k && x.length && !f) {
|
|
403
|
+
var et = x[0], lt = /* @__PURE__ */ Object.create(null), Mt = new Set(et);
|
|
404
|
+
let Ct = !1;
|
|
405
|
+
for (let gt = 0; gt < et.length; gt++) {
|
|
406
|
+
let ot = et[gt];
|
|
407
|
+
if (lt[ot = R(e.transformHeader) ? e.transformHeader(ot, gt) : ot]) {
|
|
408
|
+
let kt, Rt = lt[ot];
|
|
409
|
+
for (; kt = ot + "_" + Rt, Rt++, Mt.has(kt); ) ;
|
|
410
|
+
Mt.add(kt), et[gt] = kt, lt[ot]++, Ct = !0, (h = h === null ? {} : h)[kt] = ot;
|
|
411
|
+
} else lt[ot] = 1, et[gt] = ot;
|
|
412
|
+
Mt.add(ot);
|
|
390
413
|
}
|
|
391
|
-
|
|
414
|
+
Ct && console.warn("Duplicate headers found and renamed."), f = !0;
|
|
392
415
|
}
|
|
393
|
-
return { data:
|
|
416
|
+
return { data: x, errors: D, meta: { delimiter: r, linebreak: i, aborted: w, truncated: !!J, cursor: L + (k || 0), renamedHeaders: h } };
|
|
394
417
|
}
|
|
395
418
|
function at() {
|
|
396
|
-
y(Z()),
|
|
419
|
+
y(Z()), x = [], D = [];
|
|
397
420
|
}
|
|
398
421
|
}, this.abort = function() {
|
|
399
422
|
w = !0;
|
|
@@ -401,13 +424,13 @@ function Yt() {
|
|
|
401
424
|
return l;
|
|
402
425
|
};
|
|
403
426
|
}
|
|
404
|
-
function
|
|
405
|
-
var r = e.data, i =
|
|
427
|
+
function vt(e) {
|
|
428
|
+
var r = e.data, i = T[r.workerId], u = !1;
|
|
406
429
|
if (r.error) i.userError(r.error, r.file);
|
|
407
430
|
else if (r.results && r.results.data) {
|
|
408
431
|
var y = { abort: function() {
|
|
409
432
|
u = !0, ft(r.workerId, { data: [], errors: [], meta: { aborted: !0 } });
|
|
410
|
-
}, pause:
|
|
433
|
+
}, pause: _t, resume: _t };
|
|
411
434
|
if (R(i.userStep)) {
|
|
412
435
|
for (var E = 0; E < r.results.data.length && (i.userStep({ data: r.results.data[E], errors: r.results.errors, meta: r.results.meta }, y), !u); E++) ;
|
|
413
436
|
delete r.results;
|
|
@@ -416,10 +439,10 @@ function Yt() {
|
|
|
416
439
|
r.finished && !u && ft(r.workerId, r.results);
|
|
417
440
|
}
|
|
418
441
|
function ft(e, r) {
|
|
419
|
-
var i =
|
|
420
|
-
R(i.userComplete) && i.userComplete(r), i.terminate(), delete
|
|
442
|
+
var i = T[e];
|
|
443
|
+
R(i.userComplete) && i.userComplete(r), i.terminate(), delete T[e];
|
|
421
444
|
}
|
|
422
|
-
function
|
|
445
|
+
function _t() {
|
|
423
446
|
throw new Error("Not implemented.");
|
|
424
447
|
}
|
|
425
448
|
function ct(e) {
|
|
@@ -444,25 +467,25 @@ function Yt() {
|
|
|
444
467
|
return !!p.WORKERS_SUPPORTED && (u = (() => {
|
|
445
468
|
var y = s.URL || s.webkitURL || null, E = n.toString();
|
|
446
469
|
return p.BLOB_URL || (p.BLOB_URL = y.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; ", "(", E, ")();"], { type: "text/javascript" })));
|
|
447
|
-
})(), (u = new s.Worker(u)).onmessage =
|
|
470
|
+
})(), (u = new s.Worker(u)).onmessage = vt, u.id = K++, T[u.id] = u);
|
|
448
471
|
})()).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 });
|
|
449
472
|
}, p.unparse = function(e, r) {
|
|
450
473
|
var i = !1, u = !0, y = ",", E = `\r
|
|
451
|
-
`, v = '"',
|
|
474
|
+
`, v = '"', h = v + v, f = !1, o = null, c = !1, l = ((() => {
|
|
452
475
|
if (typeof r == "object") {
|
|
453
476
|
if (typeof r.delimiter != "string" || p.BAD_DELIMITERS.filter(function(k) {
|
|
454
477
|
return r.delimiter.indexOf(k) !== -1;
|
|
455
|
-
}).length || (y = r.delimiter), typeof r.quotes != "boolean" && typeof r.quotes != "function" && !Array.isArray(r.quotes) || (i = r.quotes), typeof r.skipEmptyLines != "boolean" && typeof r.skipEmptyLines != "string" || (
|
|
478
|
+
}).length || (y = r.delimiter), typeof r.quotes != "boolean" && typeof r.quotes != "function" && !Array.isArray(r.quotes) || (i = r.quotes), typeof r.skipEmptyLines != "boolean" && typeof r.skipEmptyLines != "string" || (f = r.skipEmptyLines), typeof r.newline == "string" && (E = r.newline), typeof r.quoteChar == "string" && (v = r.quoteChar), typeof r.header == "boolean" && (u = r.header), Array.isArray(r.columns)) {
|
|
456
479
|
if (r.columns.length === 0) throw new Error("Option columns is empty");
|
|
457
480
|
o = r.columns;
|
|
458
481
|
}
|
|
459
|
-
r.escapeChar !== void 0 && (
|
|
482
|
+
r.escapeChar !== void 0 && (h = r.escapeChar + v), r.escapeFormulae instanceof RegExp ? c = r.escapeFormulae : typeof r.escapeFormulae == "boolean" && r.escapeFormulae && (c = /^[=+\-@\t\r].*$/);
|
|
460
483
|
}
|
|
461
484
|
})(), new RegExp(ut(v), "g"));
|
|
462
485
|
if (typeof e == "string" && (e = JSON.parse(e)), Array.isArray(e)) {
|
|
463
|
-
if (!e.length || Array.isArray(e[0])) return w(null, e,
|
|
464
|
-
if (typeof e[0] == "object") return w(o || Object.keys(e[0]), e,
|
|
465
|
-
} 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])), w(e.fields || [], e.data || [],
|
|
486
|
+
if (!e.length || Array.isArray(e[0])) return w(null, e, f);
|
|
487
|
+
if (typeof e[0] == "object") return w(o || Object.keys(e[0]), e, f);
|
|
488
|
+
} 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])), w(e.fields || [], e.data || [], f);
|
|
466
489
|
throw new Error("Unable to serialize unrecognized input");
|
|
467
490
|
function w(k, m, M) {
|
|
468
491
|
var C = "", Y = (typeof k == "string" && (k = JSON.parse(k)), typeof m == "string" && (m = JSON.parse(m)), Array.isArray(k) && 0 < k.length), W = !Array.isArray(m[0]);
|
|
@@ -470,50 +493,50 @@ function Yt() {
|
|
|
470
493
|
for (var b = 0; b < k.length; b++) 0 < b && (C += y), C += g(k[b], b);
|
|
471
494
|
0 < m.length && (C += E);
|
|
472
495
|
}
|
|
473
|
-
for (var
|
|
474
|
-
var
|
|
475
|
-
if (M && !Y && (_ = M === "greedy" ? m[
|
|
476
|
-
for (var
|
|
477
|
-
var
|
|
478
|
-
|
|
496
|
+
for (var x = 0; x < m.length; x++) {
|
|
497
|
+
var D = (Y ? k : m[x]).length, _ = !1, L = Y ? Object.keys(m[x]).length === 0 : m[x].length === 0;
|
|
498
|
+
if (M && !Y && (_ = M === "greedy" ? m[x].join("").trim() === "" : m[x].length === 1 && m[x][0].length === 0), M === "greedy" && Y) {
|
|
499
|
+
for (var B = [], A = 0; A < D; A++) {
|
|
500
|
+
var U = W ? k[A] : A;
|
|
501
|
+
B.push(m[x][U]);
|
|
479
502
|
}
|
|
480
|
-
_ =
|
|
503
|
+
_ = B.join("").trim() === "";
|
|
481
504
|
}
|
|
482
505
|
if (!_) {
|
|
483
|
-
for (var $ = 0; $ <
|
|
506
|
+
for (var $ = 0; $ < D; $++) {
|
|
484
507
|
0 < $ && !L && (C += y);
|
|
485
508
|
var it = Y && W ? k[$] : $;
|
|
486
|
-
C += g(m[
|
|
509
|
+
C += g(m[x][it], $);
|
|
487
510
|
}
|
|
488
|
-
|
|
511
|
+
x < m.length - 1 && (!M || 0 < D && !L) && (C += E);
|
|
489
512
|
}
|
|
490
513
|
}
|
|
491
514
|
return C;
|
|
492
515
|
}
|
|
493
516
|
function g(k, m) {
|
|
494
517
|
var M, C;
|
|
495
|
-
return k == null ? "" : k.constructor === Date ? JSON.stringify(k).slice(1, 25) : (C = !1, c && typeof k == "string" && c.test(k) && (k = "'" + k, C = !0), M = k.toString().replace(l,
|
|
518
|
+
return k == null ? "" : k.constructor === Date ? JSON.stringify(k).slice(1, 25) : (C = !1, c && typeof k == "string" && c.test(k) && (k = "'" + k, C = !0), M = k.toString().replace(l, h), (C = C || i === !0 || typeof i == "function" && i(k, m) || Array.isArray(i) && i[m] || ((Y, W) => {
|
|
496
519
|
for (var b = 0; b < W.length; b++) if (-1 < Y.indexOf(W[b])) return !0;
|
|
497
520
|
return !1;
|
|
498
521
|
})(M, p.BAD_DELIMITERS) || -1 < M.indexOf(y) || M.charAt(0) === " " || M.charAt(M.length - 1) === " ") ? v + M + v : M);
|
|
499
522
|
}
|
|
500
523
|
}, p.RECORD_SEP = "", p.UNIT_SEP = "", p.BYTE_ORDER_MARK = "\uFEFF", p.BAD_DELIMITERS = ["\r", `
|
|
501
|
-
`, '"', p.BYTE_ORDER_MARK], p.WORKERS_SUPPORTED = !S && !!s.Worker, p.NODE_STREAM_INPUT = 1, p.LocalChunkSize = 10485760, p.RemoteChunkSize = 5242880, p.DefaultDelimiter = ",", p.Parser =
|
|
524
|
+
`, '"', p.BYTE_ORDER_MARK], p.WORKERS_SUPPORTED = !S && !!s.Worker, p.NODE_STREAM_INPUT = 1, p.LocalChunkSize = 10485760, p.RemoteChunkSize = 5242880, p.DefaultDelimiter = ",", p.Parser = pt, p.ParserHandle = nt, p.NetworkStreamer = j, p.FileStreamer = Q, p.StringStreamer = q, p.ReadableStreamStreamer = G, s.jQuery && ((d = s.jQuery).fn.parse = function(e) {
|
|
502
525
|
var r = e.config || {}, i = [];
|
|
503
526
|
return this.each(function(E) {
|
|
504
|
-
if (!(
|
|
505
|
-
for (var v = 0; v < this.files.length; v++) i.push({ file: this.files[v], inputElem: this, instanceConfig:
|
|
527
|
+
if (!(d(this).prop("tagName").toUpperCase() === "INPUT" && d(this).attr("type").toLowerCase() === "file" && s.FileReader) || !this.files || this.files.length === 0) return !0;
|
|
528
|
+
for (var v = 0; v < this.files.length; v++) i.push({ file: this.files[v], inputElem: this, instanceConfig: d.extend({}, r) });
|
|
506
529
|
}), u(), this;
|
|
507
530
|
function u() {
|
|
508
531
|
if (i.length === 0) R(e.complete) && e.complete();
|
|
509
532
|
else {
|
|
510
|
-
var E, v,
|
|
533
|
+
var E, v, h, f, o = i[0];
|
|
511
534
|
if (R(e.before)) {
|
|
512
535
|
var c = e.before(o.file, o.inputElem);
|
|
513
536
|
if (typeof c == "object") {
|
|
514
|
-
if (c.action === "abort") return E = "AbortError", v = o.file,
|
|
537
|
+
if (c.action === "abort") return E = "AbortError", v = o.file, h = o.inputElem, f = c.reason, void (R(e.error) && e.error({ name: E }, v, h, f));
|
|
515
538
|
if (c.action === "skip") return void y();
|
|
516
|
-
typeof c.config == "object" && (o.instanceConfig =
|
|
539
|
+
typeof c.config == "object" && (o.instanceConfig = d.extend(o.instanceConfig, c.config));
|
|
517
540
|
} else if (c === "skip") return void y();
|
|
518
541
|
}
|
|
519
542
|
var l = o.instanceConfig.complete;
|
|
@@ -525,29 +548,29 @@ function Yt() {
|
|
|
525
548
|
function y() {
|
|
526
549
|
i.splice(0, 1), u();
|
|
527
550
|
}
|
|
528
|
-
}),
|
|
551
|
+
}), z && (s.onmessage = function(e) {
|
|
529
552
|
e = e.data, p.WORKER_ID === void 0 && e && (p.WORKER_ID = e.workerId), typeof e.input == "string" ? s.postMessage({ workerId: p.WORKER_ID, results: p.parse(e.input, e.config), finished: !0 }) : (s.File && e.input instanceof File || e.input instanceof Object) && (e = p.parse(e.input, e.config)) && s.postMessage({ workerId: p.WORKER_ID, results: e, finished: !0 });
|
|
530
|
-
}), (j.prototype = Object.create(
|
|
553
|
+
}), (j.prototype = Object.create(I.prototype)).constructor = j, (Q.prototype = Object.create(I.prototype)).constructor = Q, (q.prototype = Object.create(q.prototype)).constructor = q, (G.prototype = Object.create(I.prototype)).constructor = G, p;
|
|
531
554
|
});
|
|
532
|
-
})(
|
|
555
|
+
})(bt)), bt.exports;
|
|
533
556
|
}
|
|
534
|
-
var
|
|
535
|
-
const
|
|
536
|
-
class
|
|
557
|
+
var jt = zt();
|
|
558
|
+
const Yt = /* @__PURE__ */ Dt(jt), { parse: Bt, unparse: Pt } = Yt;
|
|
559
|
+
class ue {
|
|
537
560
|
static unparse(t, n) {
|
|
538
|
-
return
|
|
561
|
+
return Pt(t, n);
|
|
539
562
|
}
|
|
540
563
|
static parse(t) {
|
|
541
564
|
return new Promise((n, s) => {
|
|
542
|
-
|
|
565
|
+
Bt(t, {
|
|
543
566
|
header: !0,
|
|
544
|
-
complete: (
|
|
545
|
-
error: (
|
|
567
|
+
complete: (d) => n(d),
|
|
568
|
+
error: (d) => s(d)
|
|
546
569
|
});
|
|
547
570
|
});
|
|
548
571
|
}
|
|
549
572
|
}
|
|
550
|
-
class
|
|
573
|
+
class Nt {
|
|
551
574
|
static revokeObjectUrlDelay = 4e4;
|
|
552
575
|
static utf8BomMimeType = /^\s*(?:text\/\S*|application\/xml|\S+\/\S+\+xml)\s*;\s*charset\s*=\s*utf-8/i;
|
|
553
576
|
/**
|
|
@@ -558,8 +581,8 @@ class qt {
|
|
|
558
581
|
*/
|
|
559
582
|
static saveAs(t, n, s = {}) {
|
|
560
583
|
this.assertBrowserEnvironment();
|
|
561
|
-
const
|
|
562
|
-
this.downloadBlob(S,
|
|
584
|
+
const d = this.resolveFileName(t, n), S = s.autoBom ? this.addUtf8Bom(t) : t;
|
|
585
|
+
this.downloadBlob(S, d);
|
|
563
586
|
}
|
|
564
587
|
static resolveFileName(t, n) {
|
|
565
588
|
return typeof n == "string" && n.trim().length > 0 ? n : typeof File < "u" && t instanceof File && t.name.trim().length > 0 ? t.name : "download";
|
|
@@ -585,15 +608,15 @@ class qt {
|
|
|
585
608
|
const s = document.body ?? document.documentElement;
|
|
586
609
|
if (!s)
|
|
587
610
|
throw new Error("DownloadHelper.saveAs requires an initialized document.");
|
|
588
|
-
const
|
|
611
|
+
const d = document.createElement("a");
|
|
589
612
|
try {
|
|
590
|
-
|
|
613
|
+
d.download = n, d.href = t, d.target = "_blank", d.rel = "noopener noreferrer", d.style.display = "none", s.appendChild(d), d.click();
|
|
591
614
|
} finally {
|
|
592
|
-
|
|
615
|
+
d.remove();
|
|
593
616
|
}
|
|
594
617
|
}
|
|
595
618
|
}
|
|
596
|
-
class
|
|
619
|
+
class ce {
|
|
597
620
|
static getEnumValue(t, n) {
|
|
598
621
|
if (n in t)
|
|
599
622
|
return t[n];
|
|
@@ -606,7 +629,7 @@ class de {
|
|
|
606
629
|
}));
|
|
607
630
|
}
|
|
608
631
|
}
|
|
609
|
-
class
|
|
632
|
+
class le {
|
|
610
633
|
static getFileExtension(t) {
|
|
611
634
|
let n = "";
|
|
612
635
|
const s = t.lastIndexOf(".");
|
|
@@ -617,32 +640,32 @@ class fe {
|
|
|
617
640
|
*/
|
|
618
641
|
static readAsText(t) {
|
|
619
642
|
const n = new FileReader();
|
|
620
|
-
return new Promise((s,
|
|
643
|
+
return new Promise((s, d) => {
|
|
621
644
|
n.onload = () => {
|
|
622
|
-
n.onload = null, n.onerror = null, typeof n.result == "string" ? s(n.result) :
|
|
645
|
+
n.onload = null, n.onerror = null, typeof n.result == "string" ? s(n.result) : d(new Error("Unexpected result type"));
|
|
623
646
|
}, n.onerror = () => {
|
|
624
647
|
const S = n.error ?? new Error("FileReader error");
|
|
625
|
-
n.onload = null, n.onerror = null,
|
|
648
|
+
n.onload = null, n.onerror = null, d(S);
|
|
626
649
|
}, n.readAsText(t);
|
|
627
650
|
});
|
|
628
651
|
}
|
|
629
652
|
static readAsArrayBuffer(t) {
|
|
630
653
|
const n = new FileReader();
|
|
631
|
-
return new Promise((s,
|
|
654
|
+
return new Promise((s, d) => {
|
|
632
655
|
n.onload = () => {
|
|
633
|
-
n.onload = null, n.onerror = null, n.result instanceof ArrayBuffer ? s(n.result) :
|
|
656
|
+
n.onload = null, n.onerror = null, n.result instanceof ArrayBuffer ? s(n.result) : d(new Error("Unexpected result type"));
|
|
634
657
|
}, n.onerror = () => {
|
|
635
658
|
const S = n.error ?? new Error("FileReader error");
|
|
636
|
-
n.onload = null, n.onerror = null,
|
|
659
|
+
n.onload = null, n.onerror = null, d(S);
|
|
637
660
|
}, n.readAsArrayBuffer(t);
|
|
638
661
|
});
|
|
639
662
|
}
|
|
640
663
|
static readAsDataUrl(t) {
|
|
641
664
|
const n = new FileReader();
|
|
642
|
-
return new Promise((s,
|
|
665
|
+
return new Promise((s, d) => {
|
|
643
666
|
n.onload = (S) => {
|
|
644
667
|
s(S);
|
|
645
|
-
}, n.onerror = (S) =>
|
|
668
|
+
}, n.onerror = (S) => d(S), n.readAsDataURL(t);
|
|
646
669
|
});
|
|
647
670
|
}
|
|
648
671
|
/** usage:
|
|
@@ -652,11 +675,11 @@ class fe {
|
|
|
652
675
|
static formatFileSize(t, n = 2, s) {
|
|
653
676
|
if (t === 0)
|
|
654
677
|
return "0 Bytes";
|
|
655
|
-
const
|
|
656
|
-
let
|
|
657
|
-
s && S.includes(s) && (
|
|
658
|
-
const
|
|
659
|
-
return `${parseFloat(
|
|
678
|
+
const d = 1024, S = ["Bytes", "KB", "MB", "GB", "TB"];
|
|
679
|
+
let z = Math.floor(Math.log(t) / Math.log(d));
|
|
680
|
+
s && S.includes(s) && (z = S.indexOf(s));
|
|
681
|
+
const T = t / Math.pow(d, z);
|
|
682
|
+
return `${parseFloat(T.toFixed(n))} ${S[z]}`;
|
|
660
683
|
}
|
|
661
684
|
static isWithinSizeLimit(t, n) {
|
|
662
685
|
if (!Number.isSafeInteger(n) || n < 0)
|
|
@@ -664,15 +687,15 @@ class fe {
|
|
|
664
687
|
return t.size <= n;
|
|
665
688
|
}
|
|
666
689
|
static save(t, n, s) {
|
|
667
|
-
const
|
|
668
|
-
|
|
690
|
+
const d = new Blob([t], { type: s });
|
|
691
|
+
Nt.saveAs(d, n);
|
|
669
692
|
}
|
|
670
693
|
}
|
|
671
|
-
class
|
|
694
|
+
class fe {
|
|
672
695
|
static hasAllowedMimeType(t, n) {
|
|
673
696
|
const s = t.type.trim().toLowerCase();
|
|
674
697
|
return s.length > 0 && n.some(
|
|
675
|
-
(
|
|
698
|
+
(d) => d.trim().toLowerCase() === s
|
|
676
699
|
);
|
|
677
700
|
}
|
|
678
701
|
static load(t) {
|
|
@@ -680,26 +703,26 @@ class he {
|
|
|
680
703
|
return this.loadSource(n).finally(() => URL.revokeObjectURL(n));
|
|
681
704
|
}
|
|
682
705
|
static async compress(t, n = 0.8, s = "image/jpeg") {
|
|
683
|
-
const
|
|
706
|
+
const d = await this.loadSource(t), { canvas: S } = this.resize(d, d.width, d.height);
|
|
684
707
|
return S.toDataURL(s, n);
|
|
685
708
|
}
|
|
686
709
|
static resize(t, n, s) {
|
|
687
|
-
let { width:
|
|
688
|
-
const
|
|
689
|
-
|
|
710
|
+
let { width: d, height: S } = t;
|
|
711
|
+
const z = n / d, T = s / S, K = Math.min(z, T, 1);
|
|
712
|
+
d = Math.floor(d * K), S = Math.floor(S * K);
|
|
690
713
|
const p = document.createElement("canvas");
|
|
691
|
-
p.width =
|
|
692
|
-
const
|
|
693
|
-
return
|
|
714
|
+
p.width = d, p.height = S;
|
|
715
|
+
const I = p.getContext("2d");
|
|
716
|
+
return I.clearRect(0, 0, d, S), I.drawImage(t, 0, 0, d, S), { canvas: p, width: d, height: S };
|
|
694
717
|
}
|
|
695
718
|
static loadSource(t) {
|
|
696
719
|
return new Promise((n, s) => {
|
|
697
|
-
const
|
|
698
|
-
|
|
720
|
+
const d = new Image();
|
|
721
|
+
d.onload = () => n(d), d.onerror = s, d.src = t;
|
|
699
722
|
});
|
|
700
723
|
}
|
|
701
724
|
}
|
|
702
|
-
class
|
|
725
|
+
class $t {
|
|
703
726
|
static set(t, n) {
|
|
704
727
|
localStorage.setItem(t, JSON.stringify(n));
|
|
705
728
|
}
|
|
@@ -719,41 +742,41 @@ class Ct {
|
|
|
719
742
|
return Object.keys(localStorage).filter((n) => n.startsWith(t));
|
|
720
743
|
}
|
|
721
744
|
}
|
|
722
|
-
var
|
|
723
|
-
class
|
|
745
|
+
var yt = /* @__PURE__ */ ((a) => (a.log = "log", a.info = "info", a.warn = "warn", a.debug = "debug", a.error = "error", a))(yt || {});
|
|
746
|
+
class H {
|
|
724
747
|
static listeners = /* @__PURE__ */ new Set();
|
|
725
748
|
static enabled = !0;
|
|
726
749
|
static log(...t) {
|
|
727
|
-
|
|
750
|
+
H.doLog(yt.log, t);
|
|
728
751
|
}
|
|
729
752
|
static info(...t) {
|
|
730
|
-
|
|
753
|
+
H.doLog(yt.info, t);
|
|
731
754
|
}
|
|
732
755
|
static warn(...t) {
|
|
733
|
-
|
|
756
|
+
H.doLog(yt.warn, t);
|
|
734
757
|
}
|
|
735
758
|
static debug(...t) {
|
|
736
|
-
|
|
759
|
+
H.doLog(yt.debug, t);
|
|
737
760
|
}
|
|
738
761
|
static error(...t) {
|
|
739
|
-
|
|
762
|
+
H.doLog(yt.error, t);
|
|
740
763
|
}
|
|
741
764
|
static clearListeners() {
|
|
742
|
-
|
|
765
|
+
H.listeners.clear();
|
|
743
766
|
}
|
|
744
767
|
static setEnabled(t) {
|
|
745
|
-
|
|
768
|
+
H.enabled = t;
|
|
746
769
|
}
|
|
747
770
|
static doLog(t, n) {
|
|
748
|
-
if (!
|
|
771
|
+
if (!H.enabled) return;
|
|
749
772
|
const s = {
|
|
750
773
|
type: t,
|
|
751
774
|
args: n,
|
|
752
775
|
timestamp: (/* @__PURE__ */ new Date()).toISOString()
|
|
753
776
|
};
|
|
754
|
-
for (const
|
|
777
|
+
for (const d of H.listeners)
|
|
755
778
|
try {
|
|
756
|
-
if (
|
|
779
|
+
if (d(s) === !1)
|
|
757
780
|
return;
|
|
758
781
|
} catch {
|
|
759
782
|
}
|
|
@@ -761,63 +784,63 @@ class X {
|
|
|
761
784
|
}
|
|
762
785
|
static onLog(t, n = !1) {
|
|
763
786
|
if (n) {
|
|
764
|
-
const s = (
|
|
787
|
+
const s = (d) => {
|
|
765
788
|
try {
|
|
766
|
-
return t(
|
|
789
|
+
return t(d);
|
|
767
790
|
} finally {
|
|
768
|
-
|
|
791
|
+
H.listeners.delete(s);
|
|
769
792
|
}
|
|
770
793
|
};
|
|
771
|
-
return
|
|
794
|
+
return H.listeners.add(s), () => H.listeners.delete(s);
|
|
772
795
|
}
|
|
773
|
-
return
|
|
796
|
+
return H.listeners.add(t), () => H.listeners.delete(t);
|
|
774
797
|
}
|
|
775
798
|
}
|
|
776
|
-
const
|
|
777
|
-
const
|
|
778
|
-
return
|
|
799
|
+
const Wt = (a, t, n) => a.localeCompare(t) * (n ? 1 : -1), qt = (a, t) => a < t ? -1 : a === t ? 0 : 1, Kt = (a, t, n) => qt(a, t) * (n ? 1 : -1), Jt = (a, t, n) => typeof a == "string" && typeof t == "string" ? Wt(a, t, n) : Kt(a, t, n), Qt = (a, t, n, s) => {
|
|
800
|
+
const d = n(a), S = n(t);
|
|
801
|
+
return Jt(d, S, s);
|
|
779
802
|
};
|
|
780
|
-
class
|
|
803
|
+
class de {
|
|
781
804
|
static get(t) {
|
|
782
|
-
return
|
|
805
|
+
return $t.get(t);
|
|
783
806
|
}
|
|
784
807
|
static set(t, n) {
|
|
785
|
-
|
|
808
|
+
$t.set(t, n);
|
|
786
809
|
}
|
|
787
810
|
static remove(t) {
|
|
788
|
-
|
|
811
|
+
$t.remove(t);
|
|
789
812
|
}
|
|
790
813
|
}
|
|
791
|
-
class
|
|
814
|
+
class F {
|
|
792
815
|
static listeners = /* @__PURE__ */ new Set();
|
|
793
816
|
static initialized = !1;
|
|
794
817
|
static resizeTimeout = null;
|
|
795
818
|
static lastWidth = null;
|
|
796
819
|
static onResize(t) {
|
|
797
|
-
return
|
|
820
|
+
return F.initialized || F.init(), F.listeners.add(t), () => F.off(t);
|
|
798
821
|
}
|
|
799
822
|
static handleResize = () => {
|
|
800
|
-
|
|
823
|
+
F.resizeTimeout !== null && (window.clearTimeout(F.resizeTimeout), F.resizeTimeout = null), F.resizeTimeout = window.setTimeout(() => {
|
|
801
824
|
const t = window.innerWidth;
|
|
802
|
-
if (
|
|
803
|
-
|
|
804
|
-
for (const n of
|
|
825
|
+
if (F.resizeTimeout = null, t !== F.lastWidth) {
|
|
826
|
+
F.lastWidth = t;
|
|
827
|
+
for (const n of F.listeners)
|
|
805
828
|
n(t);
|
|
806
829
|
}
|
|
807
830
|
}, 150);
|
|
808
831
|
};
|
|
809
832
|
static init() {
|
|
810
|
-
if (!
|
|
833
|
+
if (!F.initialized) {
|
|
811
834
|
if (typeof window > "u")
|
|
812
835
|
throw new Error("WindowResizeHelper is only available in browser environments");
|
|
813
|
-
|
|
836
|
+
F.lastWidth = window.innerWidth, window.addEventListener("resize", F.handleResize, { passive: !0 }), F.initialized = !0;
|
|
814
837
|
}
|
|
815
838
|
}
|
|
816
839
|
static off(t) {
|
|
817
|
-
|
|
840
|
+
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));
|
|
818
841
|
}
|
|
819
842
|
}
|
|
820
|
-
function
|
|
843
|
+
function N(a, t, n) {
|
|
821
844
|
Object.defineProperty(a, t, {
|
|
822
845
|
configurable: !0,
|
|
823
846
|
enumerable: !1,
|
|
@@ -825,82 +848,85 @@ function P(a, t, n) {
|
|
|
825
848
|
writable: !0
|
|
826
849
|
});
|
|
827
850
|
}
|
|
828
|
-
function
|
|
829
|
-
|
|
851
|
+
function he() {
|
|
852
|
+
N(Array.prototype, "distinct", function(a) {
|
|
830
853
|
return a ? this.filter(
|
|
831
|
-
(n, s,
|
|
832
|
-
) : this.filter((n, s,
|
|
833
|
-
}),
|
|
854
|
+
(n, s, d) => d.findIndex((S) => a(S, n)) === s
|
|
855
|
+
) : this.filter((n, s, d) => d.indexOf(n) === s);
|
|
856
|
+
}), N(Array.prototype, "filterBy", function(a) {
|
|
834
857
|
return this.filter((t) => a(t));
|
|
835
|
-
}),
|
|
858
|
+
}), N(Array.prototype, "first", function() {
|
|
836
859
|
return this.length > 0 ? this[0] : null;
|
|
837
|
-
}),
|
|
838
|
-
return this.reduce(
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
860
|
+
}), N(Array.prototype, "groupBy", function(a) {
|
|
861
|
+
return this.reduce(
|
|
862
|
+
(t, n) => {
|
|
863
|
+
const s = a(n);
|
|
864
|
+
return Object.hasOwn(t, s) || (t[s] = []), t[s].push(n), t;
|
|
865
|
+
},
|
|
866
|
+
/* @__PURE__ */ Object.create(null)
|
|
867
|
+
);
|
|
868
|
+
}), N(Array.prototype, "orderBy", function(a, t = !0) {
|
|
869
|
+
return this?.sort((n, s) => Qt(n, s, a, t)), this;
|
|
870
|
+
}), N(Array.prototype, "removeBy", function(a, t) {
|
|
845
871
|
return this.filter((n) => a(n) !== t);
|
|
846
872
|
});
|
|
847
873
|
}
|
|
848
|
-
var
|
|
849
|
-
function
|
|
850
|
-
return
|
|
874
|
+
var Et = { exports: {} }, Vt = Et.exports, At;
|
|
875
|
+
function Zt() {
|
|
876
|
+
return At || (At = 1, (function(a, t) {
|
|
851
877
|
(function(n, s) {
|
|
852
878
|
a.exports = s();
|
|
853
|
-
})(
|
|
854
|
-
var n = 1e3, s = 6e4,
|
|
855
|
-
var
|
|
856
|
-
return "[" + v + (
|
|
857
|
-
} }, ft = function(v,
|
|
879
|
+
})(Vt, (function() {
|
|
880
|
+
var n = 1e3, s = 6e4, d = 36e5, S = "millisecond", z = "second", T = "minute", K = "hour", p = "day", I = "week", j = "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+)?$/, pt = /\[([^\]]+)]|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, vt = { 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(v) {
|
|
881
|
+
var h = ["th", "st", "nd", "rd"], f = v % 100;
|
|
882
|
+
return "[" + v + (h[(f - 20) % 10] || h[f] || h[0]) + "]";
|
|
883
|
+
} }, ft = function(v, h, f) {
|
|
858
884
|
var o = String(v);
|
|
859
|
-
return !o || o.length >=
|
|
860
|
-
},
|
|
861
|
-
var
|
|
862
|
-
return (
|
|
863
|
-
}, m: function v(
|
|
864
|
-
if (
|
|
865
|
-
var o = 12 * (
|
|
866
|
-
return +(-(o + (
|
|
885
|
+
return !o || o.length >= h ? v : "" + Array(h + 1 - o.length).join(f) + v;
|
|
886
|
+
}, _t = { s: ft, z: function(v) {
|
|
887
|
+
var h = -v.utcOffset(), f = Math.abs(h), o = Math.floor(f / 60), c = f % 60;
|
|
888
|
+
return (h <= 0 ? "+" : "-") + ft(o, 2, "0") + ":" + ft(c, 2, "0");
|
|
889
|
+
}, m: function v(h, f) {
|
|
890
|
+
if (h.date() < f.date()) return -v(f, h);
|
|
891
|
+
var o = 12 * (f.year() - h.year()) + (f.month() - h.month()), c = h.clone().add(o, j), l = f - c < 0, w = h.clone().add(o + (l ? -1 : 1), j);
|
|
892
|
+
return +(-(o + (f - c) / (l ? c - w : w - c)) || 0);
|
|
867
893
|
}, a: function(v) {
|
|
868
894
|
return v < 0 ? Math.ceil(v) || 0 : Math.floor(v);
|
|
869
895
|
}, p: function(v) {
|
|
870
|
-
return { M: j, y: q, w:
|
|
896
|
+
return { M: j, y: q, w: I, d: p, D: G, h: K, m: T, s: z, ms: S, Q }[v] || String(v || "").toLowerCase().replace(/s$/, "");
|
|
871
897
|
}, u: function(v) {
|
|
872
898
|
return v === void 0;
|
|
873
899
|
} }, ct = "en", V = {};
|
|
874
|
-
V[ct] =
|
|
900
|
+
V[ct] = vt;
|
|
875
901
|
var R = "$isDayjsObject", e = function(v) {
|
|
876
902
|
return v instanceof y || !(!v || !v[R]);
|
|
877
|
-
}, r = function v(
|
|
903
|
+
}, r = function v(h, f, o) {
|
|
878
904
|
var c;
|
|
879
|
-
if (!
|
|
880
|
-
if (typeof
|
|
881
|
-
var l =
|
|
882
|
-
V[l] && (c = l),
|
|
883
|
-
var w =
|
|
905
|
+
if (!h) return ct;
|
|
906
|
+
if (typeof h == "string") {
|
|
907
|
+
var l = h.toLowerCase();
|
|
908
|
+
V[l] && (c = l), f && (V[l] = f, c = l);
|
|
909
|
+
var w = h.split("-");
|
|
884
910
|
if (!c && w.length > 1) return v(w[0]);
|
|
885
911
|
} else {
|
|
886
|
-
var g =
|
|
887
|
-
V[g] =
|
|
912
|
+
var g = h.name;
|
|
913
|
+
V[g] = h, c = g;
|
|
888
914
|
}
|
|
889
915
|
return !o && c && (ct = c), c || !o && ct;
|
|
890
|
-
}, i = function(v,
|
|
916
|
+
}, i = function(v, h) {
|
|
891
917
|
if (e(v)) return v.clone();
|
|
892
|
-
var
|
|
893
|
-
return
|
|
894
|
-
}, u =
|
|
895
|
-
u.l = r, u.i = e, u.w = function(v,
|
|
896
|
-
return i(v, { locale:
|
|
918
|
+
var f = typeof h == "object" ? h : {};
|
|
919
|
+
return f.date = v, f.args = arguments, new y(f);
|
|
920
|
+
}, u = _t;
|
|
921
|
+
u.l = r, u.i = e, u.w = function(v, h) {
|
|
922
|
+
return i(v, { locale: h.$L, utc: h.$u, x: h.$x, $offset: h.$offset });
|
|
897
923
|
};
|
|
898
924
|
var y = (function() {
|
|
899
|
-
function v(
|
|
900
|
-
this.$L = r(
|
|
925
|
+
function v(f) {
|
|
926
|
+
this.$L = r(f.locale, null, !0), this.parse(f), this.$x = this.$x || f.x || {}, this[R] = !0;
|
|
901
927
|
}
|
|
902
|
-
var
|
|
903
|
-
return
|
|
928
|
+
var h = v.prototype;
|
|
929
|
+
return h.parse = function(f) {
|
|
904
930
|
this.$d = (function(o) {
|
|
905
931
|
var c = o.date, l = o.utc;
|
|
906
932
|
if (c === null) return /* @__PURE__ */ new Date(NaN);
|
|
@@ -914,40 +940,40 @@ function Xt() {
|
|
|
914
940
|
}
|
|
915
941
|
}
|
|
916
942
|
return new Date(c);
|
|
917
|
-
})(
|
|
918
|
-
},
|
|
919
|
-
var
|
|
920
|
-
this.$y =
|
|
921
|
-
},
|
|
943
|
+
})(f), this.init();
|
|
944
|
+
}, h.init = function() {
|
|
945
|
+
var f = this.$d;
|
|
946
|
+
this.$y = f.getFullYear(), this.$M = f.getMonth(), this.$D = f.getDate(), this.$W = f.getDay(), this.$H = f.getHours(), this.$m = f.getMinutes(), this.$s = f.getSeconds(), this.$ms = f.getMilliseconds();
|
|
947
|
+
}, h.$utils = function() {
|
|
922
948
|
return u;
|
|
923
|
-
},
|
|
949
|
+
}, h.isValid = function() {
|
|
924
950
|
return this.$d.toString() !== nt;
|
|
925
|
-
},
|
|
926
|
-
var c = i(
|
|
951
|
+
}, h.isSame = function(f, o) {
|
|
952
|
+
var c = i(f);
|
|
927
953
|
return this.startOf(o) <= c && c <= this.endOf(o);
|
|
928
|
-
},
|
|
929
|
-
return i(
|
|
930
|
-
},
|
|
931
|
-
return this.endOf(o) < i(
|
|
932
|
-
},
|
|
933
|
-
return u.u(
|
|
934
|
-
},
|
|
954
|
+
}, h.isAfter = function(f, o) {
|
|
955
|
+
return i(f) < this.startOf(o);
|
|
956
|
+
}, h.isBefore = function(f, o) {
|
|
957
|
+
return this.endOf(o) < i(f);
|
|
958
|
+
}, h.$g = function(f, o, c) {
|
|
959
|
+
return u.u(f) ? this[o] : this.set(c, f);
|
|
960
|
+
}, h.unix = function() {
|
|
935
961
|
return Math.floor(this.valueOf() / 1e3);
|
|
936
|
-
},
|
|
962
|
+
}, h.valueOf = function() {
|
|
937
963
|
return this.$d.getTime();
|
|
938
|
-
},
|
|
939
|
-
var c = this, l = !!u.u(o) || o, w = u.p(
|
|
940
|
-
var _ = u.w(c.$u ? Date.UTC(c.$y,
|
|
964
|
+
}, h.startOf = function(f, o) {
|
|
965
|
+
var c = this, l = !!u.u(o) || o, w = u.p(f), g = function(x, D) {
|
|
966
|
+
var _ = u.w(c.$u ? Date.UTC(c.$y, D, x) : new Date(c.$y, D, x), c);
|
|
941
967
|
return l ? _ : _.endOf(p);
|
|
942
|
-
}, k = function(
|
|
943
|
-
return u.w(c.toDate()[
|
|
968
|
+
}, k = function(x, D) {
|
|
969
|
+
return u.w(c.toDate()[x].apply(c.toDate("s"), (l ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(D)), c);
|
|
944
970
|
}, m = this.$W, M = this.$M, C = this.$D, Y = "set" + (this.$u ? "UTC" : "");
|
|
945
971
|
switch (w) {
|
|
946
972
|
case q:
|
|
947
973
|
return l ? g(1, 0) : g(31, 11);
|
|
948
974
|
case j:
|
|
949
975
|
return l ? g(1, M) : g(0, M + 1);
|
|
950
|
-
case
|
|
976
|
+
case I:
|
|
951
977
|
var W = this.$locale().weekStart || 0, b = (m < W ? m + 7 : m) - W;
|
|
952
978
|
return g(l ? C - b : C + (6 - b), M);
|
|
953
979
|
case p:
|
|
@@ -955,53 +981,53 @@ function Xt() {
|
|
|
955
981
|
return k(Y + "Hours", 0);
|
|
956
982
|
case K:
|
|
957
983
|
return k(Y + "Minutes", 1);
|
|
958
|
-
case
|
|
984
|
+
case T:
|
|
959
985
|
return k(Y + "Seconds", 2);
|
|
960
|
-
case
|
|
986
|
+
case z:
|
|
961
987
|
return k(Y + "Milliseconds", 3);
|
|
962
988
|
default:
|
|
963
989
|
return this.clone();
|
|
964
990
|
}
|
|
965
|
-
},
|
|
966
|
-
return this.startOf(
|
|
967
|
-
},
|
|
968
|
-
var c, l = u.p(
|
|
991
|
+
}, h.endOf = function(f) {
|
|
992
|
+
return this.startOf(f, !1);
|
|
993
|
+
}, h.$set = function(f, o) {
|
|
994
|
+
var c, l = u.p(f), w = "set" + (this.$u ? "UTC" : ""), g = (c = {}, c[p] = w + "Date", c[G] = w + "Date", c[j] = w + "Month", c[q] = w + "FullYear", c[K] = w + "Hours", c[T] = w + "Minutes", c[z] = w + "Seconds", c[S] = w + "Milliseconds", c)[l], k = l === p ? this.$D + (o - this.$W) : o;
|
|
969
995
|
if (l === j || l === q) {
|
|
970
996
|
var m = this.clone().set(G, 1);
|
|
971
997
|
m.$d[g](k), m.init(), this.$d = m.set(G, Math.min(this.$D, m.daysInMonth())).$d;
|
|
972
998
|
} else g && this.$d[g](k);
|
|
973
999
|
return this.init(), this;
|
|
974
|
-
},
|
|
975
|
-
return this.clone().$set(
|
|
976
|
-
},
|
|
977
|
-
return this[u.p(
|
|
978
|
-
},
|
|
1000
|
+
}, h.set = function(f, o) {
|
|
1001
|
+
return this.clone().$set(f, o);
|
|
1002
|
+
}, h.get = function(f) {
|
|
1003
|
+
return this[u.p(f)]();
|
|
1004
|
+
}, h.add = function(f, o) {
|
|
979
1005
|
var c, l = this;
|
|
980
|
-
|
|
1006
|
+
f = Number(f);
|
|
981
1007
|
var w = u.p(o), g = function(M) {
|
|
982
1008
|
var C = i(l);
|
|
983
|
-
return u.w(C.date(C.date() + Math.round(M *
|
|
1009
|
+
return u.w(C.date(C.date() + Math.round(M * f)), l);
|
|
984
1010
|
};
|
|
985
|
-
if (w === j) return this.set(j, this.$M +
|
|
986
|
-
if (w === q) return this.set(q, this.$y +
|
|
1011
|
+
if (w === j) return this.set(j, this.$M + f);
|
|
1012
|
+
if (w === q) return this.set(q, this.$y + f);
|
|
987
1013
|
if (w === p) return g(1);
|
|
988
|
-
if (w ===
|
|
989
|
-
var k = (c = {}, c[
|
|
1014
|
+
if (w === I) return g(7);
|
|
1015
|
+
var k = (c = {}, c[T] = s, c[K] = d, c[z] = n, c)[w] || 1, m = this.$d.getTime() + f * k;
|
|
990
1016
|
return u.w(m, this);
|
|
991
|
-
},
|
|
992
|
-
return this.add(-1 *
|
|
993
|
-
},
|
|
1017
|
+
}, h.subtract = function(f, o) {
|
|
1018
|
+
return this.add(-1 * f, o);
|
|
1019
|
+
}, h.format = function(f) {
|
|
994
1020
|
var o = this, c = this.$locale();
|
|
995
1021
|
if (!this.isValid()) return c.invalidDate || nt;
|
|
996
|
-
var l =
|
|
997
|
-
return
|
|
998
|
-
}, b = function(
|
|
999
|
-
return u.s(g % 12 || 12,
|
|
1000
|
-
},
|
|
1001
|
-
var
|
|
1002
|
-
return L ?
|
|
1022
|
+
var l = f || "YYYY-MM-DDTHH:mm:ssZ", w = u.z(this), g = this.$H, k = this.$m, m = this.$M, M = c.weekdays, C = c.months, Y = c.meridiem, W = function(D, _, L, B) {
|
|
1023
|
+
return D && (D[_] || D(o, l)) || L[_].slice(0, B);
|
|
1024
|
+
}, b = function(D) {
|
|
1025
|
+
return u.s(g % 12 || 12, D, "0");
|
|
1026
|
+
}, x = Y || function(D, _, L) {
|
|
1027
|
+
var B = D < 12 ? "AM" : "PM";
|
|
1028
|
+
return L ? B.toLowerCase() : B;
|
|
1003
1029
|
};
|
|
1004
|
-
return l.replace(
|
|
1030
|
+
return l.replace(pt, (function(D, _) {
|
|
1005
1031
|
return _ || (function(L) {
|
|
1006
1032
|
switch (L) {
|
|
1007
1033
|
case "YY":
|
|
@@ -1037,9 +1063,9 @@ function Xt() {
|
|
|
1037
1063
|
case "hh":
|
|
1038
1064
|
return b(2);
|
|
1039
1065
|
case "a":
|
|
1040
|
-
return
|
|
1066
|
+
return x(g, k, !0);
|
|
1041
1067
|
case "A":
|
|
1042
|
-
return
|
|
1068
|
+
return x(g, k, !1);
|
|
1043
1069
|
case "m":
|
|
1044
1070
|
return String(k);
|
|
1045
1071
|
case "mm":
|
|
@@ -1054,12 +1080,12 @@ function Xt() {
|
|
|
1054
1080
|
return w;
|
|
1055
1081
|
}
|
|
1056
1082
|
return null;
|
|
1057
|
-
})(
|
|
1083
|
+
})(D) || w.replace(":", "");
|
|
1058
1084
|
}));
|
|
1059
|
-
},
|
|
1085
|
+
}, h.utcOffset = function() {
|
|
1060
1086
|
return 15 * -Math.round(this.$d.getTimezoneOffset() / 15);
|
|
1061
|
-
},
|
|
1062
|
-
var l, w = this, g = u.p(o), k = i(
|
|
1087
|
+
}, h.diff = function(f, o, c) {
|
|
1088
|
+
var l, w = this, g = u.p(o), k = i(f), m = (k.utcOffset() - this.utcOffset()) * s, M = this - k, C = function() {
|
|
1063
1089
|
return u.m(w, k);
|
|
1064
1090
|
};
|
|
1065
1091
|
switch (g) {
|
|
@@ -1072,192 +1098,192 @@ function Xt() {
|
|
|
1072
1098
|
case Q:
|
|
1073
1099
|
l = C() / 3;
|
|
1074
1100
|
break;
|
|
1075
|
-
case
|
|
1101
|
+
case I:
|
|
1076
1102
|
l = (M - m) / 6048e5;
|
|
1077
1103
|
break;
|
|
1078
1104
|
case p:
|
|
1079
1105
|
l = (M - m) / 864e5;
|
|
1080
1106
|
break;
|
|
1081
1107
|
case K:
|
|
1082
|
-
l = M /
|
|
1108
|
+
l = M / d;
|
|
1083
1109
|
break;
|
|
1084
|
-
case
|
|
1110
|
+
case T:
|
|
1085
1111
|
l = M / s;
|
|
1086
1112
|
break;
|
|
1087
|
-
case
|
|
1113
|
+
case z:
|
|
1088
1114
|
l = M / n;
|
|
1089
1115
|
break;
|
|
1090
1116
|
default:
|
|
1091
1117
|
l = M;
|
|
1092
1118
|
}
|
|
1093
1119
|
return c ? l : u.a(l);
|
|
1094
|
-
},
|
|
1120
|
+
}, h.daysInMonth = function() {
|
|
1095
1121
|
return this.endOf(j).$D;
|
|
1096
|
-
},
|
|
1122
|
+
}, h.$locale = function() {
|
|
1097
1123
|
return V[this.$L];
|
|
1098
|
-
},
|
|
1099
|
-
if (!
|
|
1100
|
-
var c = this.clone(), l = r(
|
|
1124
|
+
}, h.locale = function(f, o) {
|
|
1125
|
+
if (!f) return this.$L;
|
|
1126
|
+
var c = this.clone(), l = r(f, o, !0);
|
|
1101
1127
|
return l && (c.$L = l), c;
|
|
1102
|
-
},
|
|
1128
|
+
}, h.clone = function() {
|
|
1103
1129
|
return u.w(this.$d, this);
|
|
1104
|
-
},
|
|
1130
|
+
}, h.toDate = function() {
|
|
1105
1131
|
return new Date(this.valueOf());
|
|
1106
|
-
},
|
|
1132
|
+
}, h.toJSON = function() {
|
|
1107
1133
|
return this.isValid() ? this.toISOString() : null;
|
|
1108
|
-
},
|
|
1134
|
+
}, h.toISOString = function() {
|
|
1109
1135
|
return this.$d.toISOString();
|
|
1110
|
-
},
|
|
1136
|
+
}, h.toString = function() {
|
|
1111
1137
|
return this.$d.toUTCString();
|
|
1112
1138
|
}, v;
|
|
1113
1139
|
})(), E = y.prototype;
|
|
1114
|
-
return i.prototype = E, [["$ms", S], ["$s",
|
|
1115
|
-
E[v[1]] = function(
|
|
1116
|
-
return this.$g(
|
|
1140
|
+
return i.prototype = E, [["$ms", S], ["$s", z], ["$m", T], ["$H", K], ["$W", p], ["$M", j], ["$y", q], ["$D", G]].forEach((function(v) {
|
|
1141
|
+
E[v[1]] = function(h) {
|
|
1142
|
+
return this.$g(h, v[0], v[1]);
|
|
1117
1143
|
};
|
|
1118
|
-
})), i.extend = function(v,
|
|
1119
|
-
return v.$i || (v(
|
|
1144
|
+
})), i.extend = function(v, h) {
|
|
1145
|
+
return v.$i || (v(h, y, i), v.$i = !0), i;
|
|
1120
1146
|
}, i.locale = r, i.isDayjs = e, i.unix = function(v) {
|
|
1121
1147
|
return i(1e3 * v);
|
|
1122
1148
|
}, i.en = V[ct], i.Ls = V, i.p = {}, i;
|
|
1123
1149
|
}));
|
|
1124
|
-
})(
|
|
1150
|
+
})(Et)), Et.exports;
|
|
1125
1151
|
}
|
|
1126
|
-
var
|
|
1127
|
-
const
|
|
1128
|
-
var
|
|
1129
|
-
function
|
|
1130
|
-
return
|
|
1152
|
+
var Gt = Zt();
|
|
1153
|
+
const tt = /* @__PURE__ */ Dt(Gt);
|
|
1154
|
+
var Ot = { exports: {} }, Xt = Ot.exports, Tt;
|
|
1155
|
+
function Ht() {
|
|
1156
|
+
return Tt || (Tt = 1, (function(a, t) {
|
|
1131
1157
|
(function(n, s) {
|
|
1132
1158
|
a.exports = s();
|
|
1133
|
-
})(
|
|
1159
|
+
})(Xt, (function() {
|
|
1134
1160
|
var n = "day";
|
|
1135
|
-
return function(s,
|
|
1136
|
-
var
|
|
1161
|
+
return function(s, d, S) {
|
|
1162
|
+
var z = function(p) {
|
|
1137
1163
|
return p.add(4 - p.isoWeekday(), n);
|
|
1138
|
-
},
|
|
1139
|
-
|
|
1140
|
-
return
|
|
1141
|
-
},
|
|
1164
|
+
}, T = d.prototype;
|
|
1165
|
+
T.isoWeekYear = function() {
|
|
1166
|
+
return z(this).year();
|
|
1167
|
+
}, T.isoWeek = function(p) {
|
|
1142
1168
|
if (!this.$utils().u(p)) return this.add(7 * (p - this.isoWeek()), n);
|
|
1143
|
-
var
|
|
1169
|
+
var I, j, Q, q, G = z(this), nt = (I = this.isoWeekYear(), j = this.$u, Q = (j ? S.utc : S)().year(I).startOf("year"), q = 4 - Q.isoWeekday(), Q.isoWeekday() > 4 && (q += 7), Q.add(q, n));
|
|
1144
1170
|
return G.diff(nt, "week") + 1;
|
|
1145
|
-
},
|
|
1171
|
+
}, T.isoWeekday = function(p) {
|
|
1146
1172
|
return this.$utils().u(p) ? this.day() || 7 : this.day(this.day() % 7 ? p : p - 7);
|
|
1147
1173
|
};
|
|
1148
|
-
var K =
|
|
1149
|
-
|
|
1150
|
-
var j = this.$utils(), Q = !!j.u(
|
|
1151
|
-
return j.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,
|
|
1174
|
+
var K = T.startOf;
|
|
1175
|
+
T.startOf = function(p, I) {
|
|
1176
|
+
var j = this.$utils(), Q = !!j.u(I) || I;
|
|
1177
|
+
return j.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, I);
|
|
1152
1178
|
};
|
|
1153
1179
|
};
|
|
1154
1180
|
}));
|
|
1155
|
-
})(
|
|
1181
|
+
})(Ot)), Ot.exports;
|
|
1156
1182
|
}
|
|
1157
|
-
var
|
|
1158
|
-
const
|
|
1159
|
-
var
|
|
1160
|
-
function
|
|
1161
|
-
return
|
|
1183
|
+
var te = Ht();
|
|
1184
|
+
const ee = /* @__PURE__ */ Dt(te);
|
|
1185
|
+
var xt = { exports: {} }, re = xt.exports, It;
|
|
1186
|
+
function ne() {
|
|
1187
|
+
return It || (It = 1, (function(a, t) {
|
|
1162
1188
|
(function(n, s) {
|
|
1163
1189
|
a.exports = s();
|
|
1164
|
-
})(
|
|
1190
|
+
})(re, (function() {
|
|
1165
1191
|
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" };
|
|
1166
|
-
return function(s,
|
|
1167
|
-
var
|
|
1168
|
-
S.en.formats = n,
|
|
1192
|
+
return function(s, d, S) {
|
|
1193
|
+
var z = d.prototype, T = z.format;
|
|
1194
|
+
S.en.formats = n, z.format = function(K) {
|
|
1169
1195
|
K === void 0 && (K = "YYYY-MM-DDTHH:mm:ssZ");
|
|
1170
|
-
var p = this.$locale().formats,
|
|
1196
|
+
var p = this.$locale().formats, I = (function(j, Q) {
|
|
1171
1197
|
return j.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g, (function(q, G, nt) {
|
|
1172
1198
|
var ut = nt && nt.toUpperCase();
|
|
1173
|
-
return G || Q[nt] || n[nt] || Q[ut].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g, (function(
|
|
1174
|
-
return
|
|
1199
|
+
return G || Q[nt] || n[nt] || Q[ut].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g, (function(pt, vt, ft) {
|
|
1200
|
+
return vt || ft.slice(1);
|
|
1175
1201
|
}));
|
|
1176
1202
|
}));
|
|
1177
1203
|
})(K, p === void 0 ? {} : p);
|
|
1178
|
-
return
|
|
1204
|
+
return T.call(this, I);
|
|
1179
1205
|
};
|
|
1180
1206
|
};
|
|
1181
1207
|
}));
|
|
1182
|
-
})(
|
|
1208
|
+
})(xt)), xt.exports;
|
|
1183
1209
|
}
|
|
1184
|
-
var
|
|
1185
|
-
const
|
|
1186
|
-
|
|
1187
|
-
|
|
1188
|
-
function
|
|
1189
|
-
|
|
1210
|
+
var ie = ne();
|
|
1211
|
+
const se = /* @__PURE__ */ Dt(ie);
|
|
1212
|
+
tt.extend(se);
|
|
1213
|
+
tt.extend(ee);
|
|
1214
|
+
function pe() {
|
|
1215
|
+
N(
|
|
1190
1216
|
Date.prototype,
|
|
1191
1217
|
"add",
|
|
1192
1218
|
function(a, t) {
|
|
1193
|
-
return
|
|
1219
|
+
return tt(this).add(a, t).toDate();
|
|
1194
1220
|
}
|
|
1195
|
-
),
|
|
1221
|
+
), N(
|
|
1196
1222
|
Date.prototype,
|
|
1197
1223
|
"diff",
|
|
1198
1224
|
function(a, t) {
|
|
1199
|
-
return
|
|
1225
|
+
return tt(this).diff(a, t);
|
|
1200
1226
|
}
|
|
1201
|
-
),
|
|
1202
|
-
return
|
|
1203
|
-
}),
|
|
1204
|
-
return
|
|
1205
|
-
}),
|
|
1227
|
+
), N(Date.prototype, "endOf", function(a) {
|
|
1228
|
+
return tt(this).endOf(a).toDate();
|
|
1229
|
+
}), N(Date.prototype, "firstDayOfMonth", function() {
|
|
1230
|
+
return tt(this).startOf("month").toDate();
|
|
1231
|
+
}), N(
|
|
1206
1232
|
Date.prototype,
|
|
1207
1233
|
"format",
|
|
1208
1234
|
function(a) {
|
|
1209
|
-
return
|
|
1235
|
+
return tt(this).format(a);
|
|
1210
1236
|
}
|
|
1211
|
-
),
|
|
1237
|
+
), N(
|
|
1212
1238
|
Date.prototype,
|
|
1213
1239
|
"isAfter",
|
|
1214
1240
|
function(a, t) {
|
|
1215
|
-
return
|
|
1241
|
+
return tt(this).isAfter(a, t);
|
|
1216
1242
|
}
|
|
1217
|
-
),
|
|
1243
|
+
), N(
|
|
1218
1244
|
Date.prototype,
|
|
1219
1245
|
"isBefore",
|
|
1220
1246
|
function(a, t) {
|
|
1221
|
-
return
|
|
1247
|
+
return tt(this).isBefore(a, t);
|
|
1222
1248
|
}
|
|
1223
|
-
),
|
|
1224
|
-
return
|
|
1225
|
-
}),
|
|
1226
|
-
return
|
|
1227
|
-
}),
|
|
1249
|
+
), N(Date.prototype, "isValid", function() {
|
|
1250
|
+
return tt(this).isValid();
|
|
1251
|
+
}), N(Date.prototype, "isoWeek", function() {
|
|
1252
|
+
return tt(this).isoWeek();
|
|
1253
|
+
}), N(
|
|
1228
1254
|
Date.prototype,
|
|
1229
1255
|
"subtract",
|
|
1230
1256
|
function(a, t) {
|
|
1231
|
-
return
|
|
1257
|
+
return tt(this).subtract(a, t).toDate();
|
|
1232
1258
|
}
|
|
1233
|
-
),
|
|
1234
|
-
return
|
|
1235
|
-
}),
|
|
1259
|
+
), N(Date.prototype, "lastDayOfMonth", function() {
|
|
1260
|
+
return tt(this).endOf("month").toDate();
|
|
1261
|
+
}), N(
|
|
1236
1262
|
Date.prototype,
|
|
1237
1263
|
"set",
|
|
1238
1264
|
function(a, t) {
|
|
1239
|
-
return
|
|
1265
|
+
return tt(this).set(a, t).toDate();
|
|
1240
1266
|
}
|
|
1241
|
-
),
|
|
1267
|
+
), N(
|
|
1242
1268
|
Date.prototype,
|
|
1243
1269
|
"startOf",
|
|
1244
1270
|
function(a) {
|
|
1245
|
-
return
|
|
1271
|
+
return tt(this).startOf(a).toDate();
|
|
1246
1272
|
}
|
|
1247
1273
|
);
|
|
1248
1274
|
}
|
|
1249
|
-
function
|
|
1250
|
-
|
|
1275
|
+
function me() {
|
|
1276
|
+
N(String.prototype, "capitalize", function() {
|
|
1251
1277
|
return this.charAt(0).toUpperCase() + this.slice(1);
|
|
1252
|
-
}),
|
|
1278
|
+
}), N(String.prototype, "isNumber", function() {
|
|
1253
1279
|
return !isNaN(Number(this)) && this.trim() !== "";
|
|
1254
|
-
}),
|
|
1280
|
+
}), N(String.prototype, "isEmpty", function() {
|
|
1255
1281
|
return this === void 0 || !this || this.length === 0;
|
|
1256
|
-
}),
|
|
1282
|
+
}), N(String.prototype, "stripTags", function() {
|
|
1257
1283
|
return new DOMParser().parseFromString(this.toString(), "text/html").body.textContent || "";
|
|
1258
1284
|
});
|
|
1259
1285
|
}
|
|
1260
|
-
class
|
|
1286
|
+
class ge {
|
|
1261
1287
|
resizeListener = null;
|
|
1262
1288
|
onResizeCallbacks = /* @__PURE__ */ new Set();
|
|
1263
1289
|
// feuert bei jedem throttled Resize
|
|
@@ -1281,33 +1307,33 @@ class ve {
|
|
|
1281
1307
|
const t = window.innerWidth;
|
|
1282
1308
|
this.emitTimeoutId !== null && clearTimeout(this.emitTimeoutId), this.emitTimeoutId = window.setTimeout(() => {
|
|
1283
1309
|
this.emitTimeoutId = null;
|
|
1284
|
-
const n =
|
|
1310
|
+
const n = ht.getBreakpointByScreenWidth(t);
|
|
1285
1311
|
for (const s of this.onResizeCallbacks)
|
|
1286
1312
|
s(t, n);
|
|
1287
1313
|
}, this.duplicateThresholdMs);
|
|
1288
1314
|
};
|
|
1289
1315
|
}
|
|
1290
1316
|
export {
|
|
1291
|
-
|
|
1292
|
-
|
|
1293
|
-
|
|
1294
|
-
|
|
1295
|
-
|
|
1296
|
-
|
|
1297
|
-
|
|
1298
|
-
|
|
1299
|
-
|
|
1300
|
-
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
|
|
1317
|
+
ht as BreakPointHelper,
|
|
1318
|
+
Ut as BreakPoints,
|
|
1319
|
+
X as BrowserHelper,
|
|
1320
|
+
ge as BrowserService,
|
|
1321
|
+
rt as BrowserType,
|
|
1322
|
+
ae as CanvasHelper,
|
|
1323
|
+
ue as CsvHelper,
|
|
1324
|
+
Nt as DownloadHelper,
|
|
1325
|
+
ce as EnumHelper,
|
|
1326
|
+
le as FileHelper,
|
|
1327
|
+
fe as ImageHelper,
|
|
1328
|
+
$t as LocalStorageHelper,
|
|
1329
|
+
H as LoggerHelper,
|
|
1330
|
+
yt as LoggerType,
|
|
1331
|
+
St as ScreenHelper,
|
|
1332
|
+
de as TokenHelper,
|
|
1333
|
+
F as WindowResizeHelper,
|
|
1334
|
+
oe as copyToClipboard,
|
|
1335
|
+
he as initArrayExtensions,
|
|
1336
|
+
pe as initDateExtensions,
|
|
1337
|
+
me as initStringExtensions,
|
|
1338
|
+
Qt as sortHelper
|
|
1313
1339
|
};
|