@opencloud-eu/web-client 7.4.0 → 8.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{axios-CAceQWl5.js → axios-CiL7Z3dm.js} +837 -623
- package/dist/dist-p2k0FYjB.js +4 -0
- package/dist/{generated-CSkivkhn.js → generated-5SvS30Rr.js} +350 -324
- package/dist/graph-u53S3WT9.js +376 -0
- package/dist/{helpers-hr58GB0t.js → helpers-CrYtf7Ol.js} +9 -3
- package/dist/{ocs-BupRjiCI.js → ocs-CDSkdguM.js} +1282 -429
- package/dist/schemas-BlxXwTjV.js +3959 -0
- package/dist/src/graph/generated/api.d.ts +256 -152
- package/dist/src/helpers/resource/types.d.ts +3 -2
- package/dist/src/sse/index.d.ts +12 -0
- package/dist/src/webdav/constants/dav.d.ts +5 -1
- package/dist/{toString-Y_fh2BSJ.js → toString-CVetDRwx.js} +1 -1
- package/dist/web-client/graph/generated.js +2 -2
- package/dist/web-client/graph.js +1 -1
- package/dist/web-client/ocs.js +1 -1
- package/dist/web-client/ox.js +49 -2
- package/dist/web-client/sse.js +57 -48
- package/dist/web-client/webdav.js +2 -2
- package/dist/web-client.js +5 -5
- package/dist/webdav-BdeuuZHv.js +6422 -0
- package/package.json +4 -4
- package/dist/dist-Ciqaw6jy.js +0 -812
- package/dist/graph-BDtqSczU.js +0 -375
- package/dist/ox-DIaYdpxw.js +0 -3045
- package/dist/webdav-BE0Z-EcD.js +0 -4538
package/dist/dist-Ciqaw6jy.js
DELETED
|
@@ -1,812 +0,0 @@
|
|
|
1
|
-
//#region ../../node_modules/.pnpm/vite-plugin-node-polyfills@0.28.0_vite@8.2.1_@types+node@25.9.5_jiti@2.7.0_yaml@2.9.0_/node_modules/vite-plugin-node-polyfills/shims/global/dist/index.js
|
|
2
|
-
var e = globalThis || self, t = {}, n = {};
|
|
3
|
-
n.byteLength = u, n.toByteArray = f, n.fromByteArray = h;
|
|
4
|
-
for (var r = [], i = [], a = typeof Uint8Array < "u" ? Uint8Array : Array, o = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/", s = 0, c = o.length; s < c; ++s) r[s] = o[s], i[o.charCodeAt(s)] = s;
|
|
5
|
-
i[45] = 62, i[95] = 63;
|
|
6
|
-
function l(e) {
|
|
7
|
-
var t = e.length;
|
|
8
|
-
if (t % 4 > 0) throw Error("Invalid string. Length must be a multiple of 4");
|
|
9
|
-
var n = e.indexOf("=");
|
|
10
|
-
n === -1 && (n = t);
|
|
11
|
-
var r = n === t ? 0 : 4 - n % 4;
|
|
12
|
-
return [n, r];
|
|
13
|
-
}
|
|
14
|
-
function u(e) {
|
|
15
|
-
var t = l(e), n = t[0], r = t[1];
|
|
16
|
-
return (n + r) * 3 / 4 - r;
|
|
17
|
-
}
|
|
18
|
-
function d(e, t, n) {
|
|
19
|
-
return (t + n) * 3 / 4 - n;
|
|
20
|
-
}
|
|
21
|
-
function f(e) {
|
|
22
|
-
var t, n = l(e), r = n[0], o = n[1], s = new a(d(e, r, o)), c = 0, u = o > 0 ? r - 4 : r, f;
|
|
23
|
-
for (f = 0; f < u; f += 4) t = i[e.charCodeAt(f)] << 18 | i[e.charCodeAt(f + 1)] << 12 | i[e.charCodeAt(f + 2)] << 6 | i[e.charCodeAt(f + 3)], s[c++] = t >> 16 & 255, s[c++] = t >> 8 & 255, s[c++] = t & 255;
|
|
24
|
-
return o === 2 && (t = i[e.charCodeAt(f)] << 2 | i[e.charCodeAt(f + 1)] >> 4, s[c++] = t & 255), o === 1 && (t = i[e.charCodeAt(f)] << 10 | i[e.charCodeAt(f + 1)] << 4 | i[e.charCodeAt(f + 2)] >> 2, s[c++] = t >> 8 & 255, s[c++] = t & 255), s;
|
|
25
|
-
}
|
|
26
|
-
function p(e) {
|
|
27
|
-
return r[e >> 18 & 63] + r[e >> 12 & 63] + r[e >> 6 & 63] + r[e & 63];
|
|
28
|
-
}
|
|
29
|
-
function m(e, t, n) {
|
|
30
|
-
for (var r, i = [], a = t; a < n; a += 3) r = (e[a] << 16 & 16711680) + (e[a + 1] << 8 & 65280) + (e[a + 2] & 255), i.push(p(r));
|
|
31
|
-
return i.join("");
|
|
32
|
-
}
|
|
33
|
-
function h(e) {
|
|
34
|
-
for (var t, n = e.length, i = n % 3, a = [], o = 16383, s = 0, c = n - i; s < c; s += o) a.push(m(e, s, s + o > c ? c : s + o));
|
|
35
|
-
return i === 1 ? (t = e[n - 1], a.push(r[t >> 2] + r[t << 4 & 63] + "==")) : i === 2 && (t = (e[n - 2] << 8) + e[n - 1], a.push(r[t >> 10] + r[t >> 4 & 63] + r[t << 2 & 63] + "=")), a.join("");
|
|
36
|
-
}
|
|
37
|
-
var g = {};
|
|
38
|
-
g.read = function(e, t, n, r, i) {
|
|
39
|
-
var a, o, s = i * 8 - r - 1, c = (1 << s) - 1, l = c >> 1, u = -7, d = n ? i - 1 : 0, f = n ? -1 : 1, p = e[t + d];
|
|
40
|
-
for (d += f, a = p & (1 << -u) - 1, p >>= -u, u += s; u > 0; a = a * 256 + e[t + d], d += f, u -= 8);
|
|
41
|
-
for (o = a & (1 << -u) - 1, a >>= -u, u += r; u > 0; o = o * 256 + e[t + d], d += f, u -= 8);
|
|
42
|
-
if (a === 0) a = 1 - l;
|
|
43
|
-
else if (a === c) return o ? NaN : (p ? -1 : 1) * Infinity;
|
|
44
|
-
else o += 2 ** r, a -= l;
|
|
45
|
-
return (p ? -1 : 1) * o * 2 ** (a - r);
|
|
46
|
-
}, g.write = function(e, t, n, r, i, a) {
|
|
47
|
-
var o, s, c, l = a * 8 - i - 1, u = (1 << l) - 1, d = u >> 1, f = i === 23 ? 2 ** -24 - 2 ** -77 : 0, p = r ? 0 : a - 1, m = r ? 1 : -1, h = +(t < 0 || t === 0 && 1 / t < 0);
|
|
48
|
-
for (t = Math.abs(t), isNaN(t) || t === Infinity ? (s = +!!isNaN(t), o = u) : (o = Math.floor(Math.log(t) / Math.LN2), t * (c = 2 ** -o) < 1 && (o--, c *= 2), o + d >= 1 ? t += f / c : t += f * 2 ** (1 - d), t * c >= 2 && (o++, c /= 2), o + d >= u ? (s = 0, o = u) : o + d >= 1 ? (s = (t * c - 1) * 2 ** i, o += d) : (s = t * 2 ** (d - 1) * 2 ** i, o = 0)); i >= 8; e[n + p] = s & 255, p += m, s /= 256, i -= 8);
|
|
49
|
-
for (o = o << i | s, l += i; l > 0; e[n + p] = o & 255, p += m, o /= 256, l -= 8);
|
|
50
|
-
e[n + p - m] |= h * 128;
|
|
51
|
-
}, (function(e) {
|
|
52
|
-
let t = n, r = g, i = typeof Symbol == "function" && typeof Symbol.for == "function" ? Symbol.for("nodejs.util.inspect.custom") : null;
|
|
53
|
-
e.Buffer = d, e.SlowBuffer = te, e.INSPECT_MAX_BYTES = 50;
|
|
54
|
-
let a = 2147483647;
|
|
55
|
-
e.kMaxLength = a;
|
|
56
|
-
let { Uint8Array: o, ArrayBuffer: s, SharedArrayBuffer: c } = globalThis;
|
|
57
|
-
d.TYPED_ARRAY_SUPPORT = l(), !d.TYPED_ARRAY_SUPPORT && typeof console < "u" && typeof console.error == "function" && console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");
|
|
58
|
-
function l() {
|
|
59
|
-
try {
|
|
60
|
-
let e = new o(1), t = { foo: function() {
|
|
61
|
-
return 42;
|
|
62
|
-
} };
|
|
63
|
-
return Object.setPrototypeOf(t, o.prototype), Object.setPrototypeOf(e, t), e.foo() === 42;
|
|
64
|
-
} catch {
|
|
65
|
-
return !1;
|
|
66
|
-
}
|
|
67
|
-
}
|
|
68
|
-
Object.defineProperty(d.prototype, "parent", {
|
|
69
|
-
enumerable: !0,
|
|
70
|
-
get: function() {
|
|
71
|
-
if (d.isBuffer(this)) return this.buffer;
|
|
72
|
-
}
|
|
73
|
-
}), Object.defineProperty(d.prototype, "offset", {
|
|
74
|
-
enumerable: !0,
|
|
75
|
-
get: function() {
|
|
76
|
-
if (d.isBuffer(this)) return this.byteOffset;
|
|
77
|
-
}
|
|
78
|
-
});
|
|
79
|
-
function u(e) {
|
|
80
|
-
if (e > a) throw RangeError("The value \"" + e + "\" is invalid for option \"size\"");
|
|
81
|
-
let t = new o(e);
|
|
82
|
-
return Object.setPrototypeOf(t, d.prototype), t;
|
|
83
|
-
}
|
|
84
|
-
function d(e, t, n) {
|
|
85
|
-
if (typeof e == "number") {
|
|
86
|
-
if (typeof t == "string") throw TypeError("The \"string\" argument must be of type string. Received type number");
|
|
87
|
-
return h(e);
|
|
88
|
-
}
|
|
89
|
-
return f(e, t, n);
|
|
90
|
-
}
|
|
91
|
-
d.poolSize = 8192;
|
|
92
|
-
function f(e, t, n) {
|
|
93
|
-
if (typeof e == "string") return _(e, t);
|
|
94
|
-
if (s.isView(e)) return y(e);
|
|
95
|
-
if (e == null) throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type " + typeof e);
|
|
96
|
-
if (Z(e, s) || e && Z(e.buffer, s) || c !== void 0 && (Z(e, c) || e && Z(e.buffer, c))) return b(e, t, n);
|
|
97
|
-
if (typeof e == "number") throw TypeError("The \"value\" argument must not be of type number. Received type number");
|
|
98
|
-
let r = e.valueOf && e.valueOf();
|
|
99
|
-
if (r != null && r !== e) return d.from(r, t, n);
|
|
100
|
-
let i = ee(e);
|
|
101
|
-
if (i) return i;
|
|
102
|
-
if (typeof Symbol < "u" && Symbol.toPrimitive != null && typeof e[Symbol.toPrimitive] == "function") return d.from(e[Symbol.toPrimitive]("string"), t, n);
|
|
103
|
-
throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type " + typeof e);
|
|
104
|
-
}
|
|
105
|
-
d.from = function(e, t, n) {
|
|
106
|
-
return f(e, t, n);
|
|
107
|
-
}, Object.setPrototypeOf(d.prototype, o.prototype), Object.setPrototypeOf(d, o);
|
|
108
|
-
function p(e) {
|
|
109
|
-
if (typeof e != "number") throw TypeError("\"size\" argument must be of type number");
|
|
110
|
-
if (e < 0) throw RangeError("The value \"" + e + "\" is invalid for option \"size\"");
|
|
111
|
-
}
|
|
112
|
-
function m(e, t, n) {
|
|
113
|
-
return p(e), e <= 0 || t === void 0 ? u(e) : typeof n == "string" ? u(e).fill(t, n) : u(e).fill(t);
|
|
114
|
-
}
|
|
115
|
-
d.alloc = function(e, t, n) {
|
|
116
|
-
return m(e, t, n);
|
|
117
|
-
};
|
|
118
|
-
function h(e) {
|
|
119
|
-
return p(e), u(e < 0 ? 0 : x(e) | 0);
|
|
120
|
-
}
|
|
121
|
-
d.allocUnsafe = function(e) {
|
|
122
|
-
return h(e);
|
|
123
|
-
}, d.allocUnsafeSlow = function(e) {
|
|
124
|
-
return h(e);
|
|
125
|
-
};
|
|
126
|
-
function _(e, t) {
|
|
127
|
-
if ((typeof t != "string" || t === "") && (t = "utf8"), !d.isEncoding(t)) throw TypeError("Unknown encoding: " + t);
|
|
128
|
-
let n = S(e, t) | 0, r = u(n), i = r.write(e, t);
|
|
129
|
-
return i !== n && (r = r.slice(0, i)), r;
|
|
130
|
-
}
|
|
131
|
-
function v(e) {
|
|
132
|
-
let t = e.length < 0 ? 0 : x(e.length) | 0, n = u(t);
|
|
133
|
-
for (let r = 0; r < t; r += 1) n[r] = e[r] & 255;
|
|
134
|
-
return n;
|
|
135
|
-
}
|
|
136
|
-
function y(e) {
|
|
137
|
-
if (Z(e, o)) {
|
|
138
|
-
let t = new o(e);
|
|
139
|
-
return b(t.buffer, t.byteOffset, t.byteLength);
|
|
140
|
-
}
|
|
141
|
-
return v(e);
|
|
142
|
-
}
|
|
143
|
-
function b(e, t, n) {
|
|
144
|
-
if (t < 0 || e.byteLength < t) throw RangeError("\"offset\" is outside of buffer bounds");
|
|
145
|
-
if (e.byteLength < t + (n || 0)) throw RangeError("\"length\" is outside of buffer bounds");
|
|
146
|
-
let r;
|
|
147
|
-
return r = t === void 0 && n === void 0 ? new o(e) : n === void 0 ? new o(e, t) : new o(e, t, n), Object.setPrototypeOf(r, d.prototype), r;
|
|
148
|
-
}
|
|
149
|
-
function ee(e) {
|
|
150
|
-
if (d.isBuffer(e)) {
|
|
151
|
-
let t = x(e.length) | 0, n = u(t);
|
|
152
|
-
return n.length === 0 || e.copy(n, 0, 0, t), n;
|
|
153
|
-
}
|
|
154
|
-
if (e.length !== void 0) return typeof e.length != "number" || Q(e.length) ? u(0) : v(e);
|
|
155
|
-
if (e.type === "Buffer" && Array.isArray(e.data)) return v(e.data);
|
|
156
|
-
}
|
|
157
|
-
function x(e) {
|
|
158
|
-
if (e >= a) throw RangeError("Attempt to allocate Buffer larger than maximum size: 0x" + a.toString(16) + " bytes");
|
|
159
|
-
return e | 0;
|
|
160
|
-
}
|
|
161
|
-
function te(e) {
|
|
162
|
-
return +e != e && (e = 0), d.alloc(+e);
|
|
163
|
-
}
|
|
164
|
-
d.isBuffer = function(e) {
|
|
165
|
-
return e != null && e._isBuffer === !0 && e !== d.prototype;
|
|
166
|
-
}, d.compare = function(e, t) {
|
|
167
|
-
if (Z(e, o) && (e = d.from(e, e.offset, e.byteLength)), Z(t, o) && (t = d.from(t, t.offset, t.byteLength)), !d.isBuffer(e) || !d.isBuffer(t)) throw TypeError("The \"buf1\", \"buf2\" arguments must be one of type Buffer or Uint8Array");
|
|
168
|
-
if (e === t) return 0;
|
|
169
|
-
let n = e.length, r = t.length;
|
|
170
|
-
for (let i = 0, a = Math.min(n, r); i < a; ++i) if (e[i] !== t[i]) {
|
|
171
|
-
n = e[i], r = t[i];
|
|
172
|
-
break;
|
|
173
|
-
}
|
|
174
|
-
return n < r ? -1 : +(r < n);
|
|
175
|
-
}, d.isEncoding = function(e) {
|
|
176
|
-
switch (String(e).toLowerCase()) {
|
|
177
|
-
case "hex":
|
|
178
|
-
case "utf8":
|
|
179
|
-
case "utf-8":
|
|
180
|
-
case "ascii":
|
|
181
|
-
case "latin1":
|
|
182
|
-
case "binary":
|
|
183
|
-
case "base64":
|
|
184
|
-
case "ucs2":
|
|
185
|
-
case "ucs-2":
|
|
186
|
-
case "utf16le":
|
|
187
|
-
case "utf-16le": return !0;
|
|
188
|
-
default: return !1;
|
|
189
|
-
}
|
|
190
|
-
}, d.concat = function(e, t) {
|
|
191
|
-
if (!Array.isArray(e)) throw TypeError("\"list\" argument must be an Array of Buffers");
|
|
192
|
-
if (e.length === 0) return d.alloc(0);
|
|
193
|
-
let n;
|
|
194
|
-
if (t === void 0) for (t = 0, n = 0; n < e.length; ++n) t += e[n].length;
|
|
195
|
-
let r = d.allocUnsafe(t), i = 0;
|
|
196
|
-
for (n = 0; n < e.length; ++n) {
|
|
197
|
-
let t = e[n];
|
|
198
|
-
if (Z(t, o)) i + t.length > r.length ? (d.isBuffer(t) || (t = d.from(t)), t.copy(r, i)) : o.prototype.set.call(r, t, i);
|
|
199
|
-
else if (d.isBuffer(t)) t.copy(r, i);
|
|
200
|
-
else throw TypeError("\"list\" argument must be an Array of Buffers");
|
|
201
|
-
i += t.length;
|
|
202
|
-
}
|
|
203
|
-
return r;
|
|
204
|
-
};
|
|
205
|
-
function S(e, t) {
|
|
206
|
-
if (d.isBuffer(e)) return e.length;
|
|
207
|
-
if (s.isView(e) || Z(e, s)) return e.byteLength;
|
|
208
|
-
if (typeof e != "string") throw TypeError("The \"string\" argument must be one of type string, Buffer, or ArrayBuffer. Received type " + typeof e);
|
|
209
|
-
let n = e.length, r = arguments.length > 2 && arguments[2] === !0;
|
|
210
|
-
if (!r && n === 0) return 0;
|
|
211
|
-
let i = !1;
|
|
212
|
-
for (;;) switch (t) {
|
|
213
|
-
case "ascii":
|
|
214
|
-
case "latin1":
|
|
215
|
-
case "binary": return n;
|
|
216
|
-
case "utf8":
|
|
217
|
-
case "utf-8": return q(e).length;
|
|
218
|
-
case "ucs2":
|
|
219
|
-
case "ucs-2":
|
|
220
|
-
case "utf16le":
|
|
221
|
-
case "utf-16le": return n * 2;
|
|
222
|
-
case "hex": return n >>> 1;
|
|
223
|
-
case "base64": return Y(e).length;
|
|
224
|
-
default:
|
|
225
|
-
if (i) return r ? -1 : q(e).length;
|
|
226
|
-
t = ("" + t).toLowerCase(), i = !0;
|
|
227
|
-
}
|
|
228
|
-
}
|
|
229
|
-
d.byteLength = S;
|
|
230
|
-
function C(e, t, n) {
|
|
231
|
-
let r = !1;
|
|
232
|
-
if ((t === void 0 || t < 0) && (t = 0), t > this.length || ((n === void 0 || n > this.length) && (n = this.length), n <= 0) || (n >>>= 0, t >>>= 0, n <= t)) return "";
|
|
233
|
-
for (e ||= "utf8";;) switch (e) {
|
|
234
|
-
case "hex": return se(this, t, n);
|
|
235
|
-
case "utf8":
|
|
236
|
-
case "utf-8": return A(this, t, n);
|
|
237
|
-
case "ascii": return ae(this, t, n);
|
|
238
|
-
case "latin1":
|
|
239
|
-
case "binary": return oe(this, t, n);
|
|
240
|
-
case "base64": return k(this, t, n);
|
|
241
|
-
case "ucs2":
|
|
242
|
-
case "ucs-2":
|
|
243
|
-
case "utf16le":
|
|
244
|
-
case "utf-16le": return ce(this, t, n);
|
|
245
|
-
default:
|
|
246
|
-
if (r) throw TypeError("Unknown encoding: " + e);
|
|
247
|
-
e = (e + "").toLowerCase(), r = !0;
|
|
248
|
-
}
|
|
249
|
-
}
|
|
250
|
-
d.prototype._isBuffer = !0;
|
|
251
|
-
function w(e, t, n) {
|
|
252
|
-
let r = e[t];
|
|
253
|
-
e[t] = e[n], e[n] = r;
|
|
254
|
-
}
|
|
255
|
-
d.prototype.swap16 = function() {
|
|
256
|
-
let e = this.length;
|
|
257
|
-
if (e % 2 != 0) throw RangeError("Buffer size must be a multiple of 16-bits");
|
|
258
|
-
for (let t = 0; t < e; t += 2) w(this, t, t + 1);
|
|
259
|
-
return this;
|
|
260
|
-
}, d.prototype.swap32 = function() {
|
|
261
|
-
let e = this.length;
|
|
262
|
-
if (e % 4 != 0) throw RangeError("Buffer size must be a multiple of 32-bits");
|
|
263
|
-
for (let t = 0; t < e; t += 4) w(this, t, t + 3), w(this, t + 1, t + 2);
|
|
264
|
-
return this;
|
|
265
|
-
}, d.prototype.swap64 = function() {
|
|
266
|
-
let e = this.length;
|
|
267
|
-
if (e % 8 != 0) throw RangeError("Buffer size must be a multiple of 64-bits");
|
|
268
|
-
for (let t = 0; t < e; t += 8) w(this, t, t + 7), w(this, t + 1, t + 6), w(this, t + 2, t + 5), w(this, t + 3, t + 4);
|
|
269
|
-
return this;
|
|
270
|
-
}, d.prototype.toString = function() {
|
|
271
|
-
let e = this.length;
|
|
272
|
-
return e === 0 ? "" : arguments.length === 0 ? A(this, 0, e) : C.apply(this, arguments);
|
|
273
|
-
}, d.prototype.toLocaleString = d.prototype.toString, d.prototype.equals = function(e) {
|
|
274
|
-
if (!d.isBuffer(e)) throw TypeError("Argument must be a Buffer");
|
|
275
|
-
return this === e || d.compare(this, e) === 0;
|
|
276
|
-
}, d.prototype.inspect = function() {
|
|
277
|
-
let t = "", n = e.INSPECT_MAX_BYTES;
|
|
278
|
-
return t = this.toString("hex", 0, n).replace(/(.{2})/g, "$1 ").trim(), this.length > n && (t += " ... "), "<Buffer " + t + ">";
|
|
279
|
-
}, i && (d.prototype[i] = d.prototype.inspect), d.prototype.compare = function(e, t, n, r, i) {
|
|
280
|
-
if (Z(e, o) && (e = d.from(e, e.offset, e.byteLength)), !d.isBuffer(e)) throw TypeError("The \"target\" argument must be one of type Buffer or Uint8Array. Received type " + typeof e);
|
|
281
|
-
if (t === void 0 && (t = 0), n === void 0 && (n = e ? e.length : 0), r === void 0 && (r = 0), i === void 0 && (i = this.length), t < 0 || n > e.length || r < 0 || i > this.length) throw RangeError("out of range index");
|
|
282
|
-
if (r >= i && t >= n) return 0;
|
|
283
|
-
if (r >= i) return -1;
|
|
284
|
-
if (t >= n) return 1;
|
|
285
|
-
if (t >>>= 0, n >>>= 0, r >>>= 0, i >>>= 0, this === e) return 0;
|
|
286
|
-
let a = i - r, s = n - t, c = Math.min(a, s), l = this.slice(r, i), u = e.slice(t, n);
|
|
287
|
-
for (let e = 0; e < c; ++e) if (l[e] !== u[e]) {
|
|
288
|
-
a = l[e], s = u[e];
|
|
289
|
-
break;
|
|
290
|
-
}
|
|
291
|
-
return a < s ? -1 : +(s < a);
|
|
292
|
-
};
|
|
293
|
-
function T(e, t, n, r, i) {
|
|
294
|
-
if (e.length === 0) return -1;
|
|
295
|
-
if (typeof n == "string" ? (r = n, n = 0) : n > 2147483647 ? n = 2147483647 : n < -2147483648 && (n = -2147483648), n = +n, Q(n) && (n = i ? 0 : e.length - 1), n < 0 && (n = e.length + n), n >= e.length) {
|
|
296
|
-
if (i) return -1;
|
|
297
|
-
n = e.length - 1;
|
|
298
|
-
} else if (n < 0) {
|
|
299
|
-
if (i) n = 0;
|
|
300
|
-
else return -1;
|
|
301
|
-
}
|
|
302
|
-
if (typeof t == "string" && (t = d.from(t, r)), d.isBuffer(t)) return t.length === 0 ? -1 : E(e, t, n, r, i);
|
|
303
|
-
if (typeof t == "number") return t &= 255, typeof o.prototype.indexOf == "function" ? i ? o.prototype.indexOf.call(e, t, n) : o.prototype.lastIndexOf.call(e, t, n) : E(e, [t], n, r, i);
|
|
304
|
-
throw TypeError("val must be string, number or Buffer");
|
|
305
|
-
}
|
|
306
|
-
function E(e, t, n, r, i) {
|
|
307
|
-
let a = 1, o = e.length, s = t.length;
|
|
308
|
-
if (r !== void 0 && (r = String(r).toLowerCase(), r === "ucs2" || r === "ucs-2" || r === "utf16le" || r === "utf-16le")) {
|
|
309
|
-
if (e.length < 2 || t.length < 2) return -1;
|
|
310
|
-
a = 2, o /= 2, s /= 2, n /= 2;
|
|
311
|
-
}
|
|
312
|
-
function c(e, t) {
|
|
313
|
-
return a === 1 ? e[t] : e.readUInt16BE(t * a);
|
|
314
|
-
}
|
|
315
|
-
let l;
|
|
316
|
-
if (i) {
|
|
317
|
-
let r = -1;
|
|
318
|
-
for (l = n; l < o; l++) if (c(e, l) === c(t, r === -1 ? 0 : l - r)) {
|
|
319
|
-
if (r === -1 && (r = l), l - r + 1 === s) return r * a;
|
|
320
|
-
} else r !== -1 && (l -= l - r), r = -1;
|
|
321
|
-
} else for (n + s > o && (n = o - s), l = n; l >= 0; l--) {
|
|
322
|
-
let n = !0;
|
|
323
|
-
for (let r = 0; r < s; r++) if (c(e, l + r) !== c(t, r)) {
|
|
324
|
-
n = !1;
|
|
325
|
-
break;
|
|
326
|
-
}
|
|
327
|
-
if (n) return l;
|
|
328
|
-
}
|
|
329
|
-
return -1;
|
|
330
|
-
}
|
|
331
|
-
d.prototype.includes = function(e, t, n) {
|
|
332
|
-
return this.indexOf(e, t, n) !== -1;
|
|
333
|
-
}, d.prototype.indexOf = function(e, t, n) {
|
|
334
|
-
return T(this, e, t, n, !0);
|
|
335
|
-
}, d.prototype.lastIndexOf = function(e, t, n) {
|
|
336
|
-
return T(this, e, t, n, !1);
|
|
337
|
-
};
|
|
338
|
-
function ne(e, t, n, r) {
|
|
339
|
-
n = Number(n) || 0;
|
|
340
|
-
let i = e.length - n;
|
|
341
|
-
r ? (r = Number(r), r > i && (r = i)) : r = i;
|
|
342
|
-
let a = t.length;
|
|
343
|
-
r > a / 2 && (r = a / 2);
|
|
344
|
-
let o;
|
|
345
|
-
for (o = 0; o < r; ++o) {
|
|
346
|
-
let r = parseInt(t.substr(o * 2, 2), 16);
|
|
347
|
-
if (Q(r)) return o;
|
|
348
|
-
e[n + o] = r;
|
|
349
|
-
}
|
|
350
|
-
return o;
|
|
351
|
-
}
|
|
352
|
-
function re(e, t, n, r) {
|
|
353
|
-
return X(q(t, e.length - n), e, n, r);
|
|
354
|
-
}
|
|
355
|
-
function ie(e, t, n, r) {
|
|
356
|
-
return X(de(t), e, n, r);
|
|
357
|
-
}
|
|
358
|
-
function D(e, t, n, r) {
|
|
359
|
-
return X(Y(t), e, n, r);
|
|
360
|
-
}
|
|
361
|
-
function O(e, t, n, r) {
|
|
362
|
-
return X(J(t, e.length - n), e, n, r);
|
|
363
|
-
}
|
|
364
|
-
d.prototype.write = function(e, t, n, r) {
|
|
365
|
-
if (t === void 0) r = "utf8", n = this.length, t = 0;
|
|
366
|
-
else if (n === void 0 && typeof t == "string") r = t, n = this.length, t = 0;
|
|
367
|
-
else if (isFinite(t)) t >>>= 0, isFinite(n) ? (n >>>= 0, r === void 0 && (r = "utf8")) : (r = n, n = void 0);
|
|
368
|
-
else throw Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");
|
|
369
|
-
let i = this.length - t;
|
|
370
|
-
if ((n === void 0 || n > i) && (n = i), e.length > 0 && (n < 0 || t < 0) || t > this.length) throw RangeError("Attempt to write outside buffer bounds");
|
|
371
|
-
r ||= "utf8";
|
|
372
|
-
let a = !1;
|
|
373
|
-
for (;;) switch (r) {
|
|
374
|
-
case "hex": return ne(this, e, t, n);
|
|
375
|
-
case "utf8":
|
|
376
|
-
case "utf-8": return re(this, e, t, n);
|
|
377
|
-
case "ascii":
|
|
378
|
-
case "latin1":
|
|
379
|
-
case "binary": return ie(this, e, t, n);
|
|
380
|
-
case "base64": return D(this, e, t, n);
|
|
381
|
-
case "ucs2":
|
|
382
|
-
case "ucs-2":
|
|
383
|
-
case "utf16le":
|
|
384
|
-
case "utf-16le": return O(this, e, t, n);
|
|
385
|
-
default:
|
|
386
|
-
if (a) throw TypeError("Unknown encoding: " + r);
|
|
387
|
-
r = ("" + r).toLowerCase(), a = !0;
|
|
388
|
-
}
|
|
389
|
-
}, d.prototype.toJSON = function() {
|
|
390
|
-
return {
|
|
391
|
-
type: "Buffer",
|
|
392
|
-
data: Array.prototype.slice.call(this._arr || this, 0)
|
|
393
|
-
};
|
|
394
|
-
};
|
|
395
|
-
function k(e, n, r) {
|
|
396
|
-
return n === 0 && r === e.length ? t.fromByteArray(e) : t.fromByteArray(e.slice(n, r));
|
|
397
|
-
}
|
|
398
|
-
function A(e, t, n) {
|
|
399
|
-
n = Math.min(e.length, n);
|
|
400
|
-
let r = [], i = t;
|
|
401
|
-
for (; i < n;) {
|
|
402
|
-
let t = e[i], a = null, o = t > 239 ? 4 : t > 223 ? 3 : t > 191 ? 2 : 1;
|
|
403
|
-
if (i + o <= n) {
|
|
404
|
-
let n, r, s, c;
|
|
405
|
-
switch (o) {
|
|
406
|
-
case 1:
|
|
407
|
-
t < 128 && (a = t);
|
|
408
|
-
break;
|
|
409
|
-
case 2:
|
|
410
|
-
n = e[i + 1], (n & 192) == 128 && (c = (t & 31) << 6 | n & 63, c > 127 && (a = c));
|
|
411
|
-
break;
|
|
412
|
-
case 3:
|
|
413
|
-
n = e[i + 1], r = e[i + 2], (n & 192) == 128 && (r & 192) == 128 && (c = (t & 15) << 12 | (n & 63) << 6 | r & 63, c > 2047 && (c < 55296 || c > 57343) && (a = c));
|
|
414
|
-
break;
|
|
415
|
-
case 4: n = e[i + 1], r = e[i + 2], s = e[i + 3], (n & 192) == 128 && (r & 192) == 128 && (s & 192) == 128 && (c = (t & 15) << 18 | (n & 63) << 12 | (r & 63) << 6 | s & 63, c > 65535 && c < 1114112 && (a = c));
|
|
416
|
-
}
|
|
417
|
-
}
|
|
418
|
-
a === null ? (a = 65533, o = 1) : a > 65535 && (a -= 65536, r.push(a >>> 10 & 1023 | 55296), a = 56320 | a & 1023), r.push(a), i += o;
|
|
419
|
-
}
|
|
420
|
-
return M(r);
|
|
421
|
-
}
|
|
422
|
-
let j = 4096;
|
|
423
|
-
function M(e) {
|
|
424
|
-
let t = e.length;
|
|
425
|
-
if (t <= j) return String.fromCharCode.apply(String, e);
|
|
426
|
-
let n = "", r = 0;
|
|
427
|
-
for (; r < t;) n += String.fromCharCode.apply(String, e.slice(r, r += j));
|
|
428
|
-
return n;
|
|
429
|
-
}
|
|
430
|
-
function ae(e, t, n) {
|
|
431
|
-
let r = "";
|
|
432
|
-
n = Math.min(e.length, n);
|
|
433
|
-
for (let i = t; i < n; ++i) r += String.fromCharCode(e[i] & 127);
|
|
434
|
-
return r;
|
|
435
|
-
}
|
|
436
|
-
function oe(e, t, n) {
|
|
437
|
-
let r = "";
|
|
438
|
-
n = Math.min(e.length, n);
|
|
439
|
-
for (let i = t; i < n; ++i) r += String.fromCharCode(e[i]);
|
|
440
|
-
return r;
|
|
441
|
-
}
|
|
442
|
-
function se(e, t, n) {
|
|
443
|
-
let r = e.length;
|
|
444
|
-
(!t || t < 0) && (t = 0), (!n || n < 0 || n > r) && (n = r);
|
|
445
|
-
let i = "";
|
|
446
|
-
for (let r = t; r < n; ++r) i += fe[e[r]];
|
|
447
|
-
return i;
|
|
448
|
-
}
|
|
449
|
-
function ce(e, t, n) {
|
|
450
|
-
let r = e.slice(t, n), i = "";
|
|
451
|
-
for (let e = 0; e < r.length - 1; e += 2) i += String.fromCharCode(r[e] + r[e + 1] * 256);
|
|
452
|
-
return i;
|
|
453
|
-
}
|
|
454
|
-
d.prototype.slice = function(e, t) {
|
|
455
|
-
let n = this.length;
|
|
456
|
-
e = ~~e, t = t === void 0 ? n : ~~t, e < 0 ? (e += n, e < 0 && (e = 0)) : e > n && (e = n), t < 0 ? (t += n, t < 0 && (t = 0)) : t > n && (t = n), t < e && (t = e);
|
|
457
|
-
let r = this.subarray(e, t);
|
|
458
|
-
return Object.setPrototypeOf(r, d.prototype), r;
|
|
459
|
-
};
|
|
460
|
-
function N(e, t, n) {
|
|
461
|
-
if (e % 1 != 0 || e < 0) throw RangeError("offset is not uint");
|
|
462
|
-
if (e + t > n) throw RangeError("Trying to access beyond buffer length");
|
|
463
|
-
}
|
|
464
|
-
d.prototype.readUintLE = d.prototype.readUIntLE = function(e, t, n) {
|
|
465
|
-
e >>>= 0, t >>>= 0, n || N(e, t, this.length);
|
|
466
|
-
let r = this[e], i = 1, a = 0;
|
|
467
|
-
for (; ++a < t && (i *= 256);) r += this[e + a] * i;
|
|
468
|
-
return r;
|
|
469
|
-
}, d.prototype.readUintBE = d.prototype.readUIntBE = function(e, t, n) {
|
|
470
|
-
e >>>= 0, t >>>= 0, n || N(e, t, this.length);
|
|
471
|
-
let r = this[e + --t], i = 1;
|
|
472
|
-
for (; t > 0 && (i *= 256);) r += this[e + --t] * i;
|
|
473
|
-
return r;
|
|
474
|
-
}, d.prototype.readUint8 = d.prototype.readUInt8 = function(e, t) {
|
|
475
|
-
return e >>>= 0, t || N(e, 1, this.length), this[e];
|
|
476
|
-
}, d.prototype.readUint16LE = d.prototype.readUInt16LE = function(e, t) {
|
|
477
|
-
return e >>>= 0, t || N(e, 2, this.length), this[e] | this[e + 1] << 8;
|
|
478
|
-
}, d.prototype.readUint16BE = d.prototype.readUInt16BE = function(e, t) {
|
|
479
|
-
return e >>>= 0, t || N(e, 2, this.length), this[e] << 8 | this[e + 1];
|
|
480
|
-
}, d.prototype.readUint32LE = d.prototype.readUInt32LE = function(e, t) {
|
|
481
|
-
return e >>>= 0, t || N(e, 4, this.length), (this[e] | this[e + 1] << 8 | this[e + 2] << 16) + this[e + 3] * 16777216;
|
|
482
|
-
}, d.prototype.readUint32BE = d.prototype.readUInt32BE = function(e, t) {
|
|
483
|
-
return e >>>= 0, t || N(e, 4, this.length), this[e] * 16777216 + (this[e + 1] << 16 | this[e + 2] << 8 | this[e + 3]);
|
|
484
|
-
}, d.prototype.readBigUInt64LE = $(function(e) {
|
|
485
|
-
e >>>= 0, G(e, "offset");
|
|
486
|
-
let t = this[e], n = this[e + 7];
|
|
487
|
-
(t === void 0 || n === void 0) && K(e, this.length - 8);
|
|
488
|
-
let r = t + this[++e] * 256 + this[++e] * 2 ** 16 + this[++e] * 2 ** 24, i = this[++e] + this[++e] * 256 + this[++e] * 2 ** 16 + n * 2 ** 24;
|
|
489
|
-
return BigInt(r) + (BigInt(i) << BigInt(32));
|
|
490
|
-
}), d.prototype.readBigUInt64BE = $(function(e) {
|
|
491
|
-
e >>>= 0, G(e, "offset");
|
|
492
|
-
let t = this[e], n = this[e + 7];
|
|
493
|
-
(t === void 0 || n === void 0) && K(e, this.length - 8);
|
|
494
|
-
let r = t * 2 ** 24 + this[++e] * 2 ** 16 + this[++e] * 256 + this[++e], i = this[++e] * 2 ** 24 + this[++e] * 2 ** 16 + this[++e] * 256 + n;
|
|
495
|
-
return (BigInt(r) << BigInt(32)) + BigInt(i);
|
|
496
|
-
}), d.prototype.readIntLE = function(e, t, n) {
|
|
497
|
-
e >>>= 0, t >>>= 0, n || N(e, t, this.length);
|
|
498
|
-
let r = this[e], i = 1, a = 0;
|
|
499
|
-
for (; ++a < t && (i *= 256);) r += this[e + a] * i;
|
|
500
|
-
return i *= 128, r >= i && (r -= 2 ** (8 * t)), r;
|
|
501
|
-
}, d.prototype.readIntBE = function(e, t, n) {
|
|
502
|
-
e >>>= 0, t >>>= 0, n || N(e, t, this.length);
|
|
503
|
-
let r = t, i = 1, a = this[e + --r];
|
|
504
|
-
for (; r > 0 && (i *= 256);) a += this[e + --r] * i;
|
|
505
|
-
return i *= 128, a >= i && (a -= 2 ** (8 * t)), a;
|
|
506
|
-
}, d.prototype.readInt8 = function(e, t) {
|
|
507
|
-
return e >>>= 0, t || N(e, 1, this.length), this[e] & 128 ? (255 - this[e] + 1) * -1 : this[e];
|
|
508
|
-
}, d.prototype.readInt16LE = function(e, t) {
|
|
509
|
-
e >>>= 0, t || N(e, 2, this.length);
|
|
510
|
-
let n = this[e] | this[e + 1] << 8;
|
|
511
|
-
return n & 32768 ? n | 4294901760 : n;
|
|
512
|
-
}, d.prototype.readInt16BE = function(e, t) {
|
|
513
|
-
e >>>= 0, t || N(e, 2, this.length);
|
|
514
|
-
let n = this[e + 1] | this[e] << 8;
|
|
515
|
-
return n & 32768 ? n | 4294901760 : n;
|
|
516
|
-
}, d.prototype.readInt32LE = function(e, t) {
|
|
517
|
-
return e >>>= 0, t || N(e, 4, this.length), this[e] | this[e + 1] << 8 | this[e + 2] << 16 | this[e + 3] << 24;
|
|
518
|
-
}, d.prototype.readInt32BE = function(e, t) {
|
|
519
|
-
return e >>>= 0, t || N(e, 4, this.length), this[e] << 24 | this[e + 1] << 16 | this[e + 2] << 8 | this[e + 3];
|
|
520
|
-
}, d.prototype.readBigInt64LE = $(function(e) {
|
|
521
|
-
e >>>= 0, G(e, "offset");
|
|
522
|
-
let t = this[e], n = this[e + 7];
|
|
523
|
-
(t === void 0 || n === void 0) && K(e, this.length - 8);
|
|
524
|
-
let r = this[e + 4] + this[e + 5] * 256 + this[e + 6] * 2 ** 16 + (n << 24);
|
|
525
|
-
return (BigInt(r) << BigInt(32)) + BigInt(t + this[++e] * 256 + this[++e] * 2 ** 16 + this[++e] * 2 ** 24);
|
|
526
|
-
}), d.prototype.readBigInt64BE = $(function(e) {
|
|
527
|
-
e >>>= 0, G(e, "offset");
|
|
528
|
-
let t = this[e], n = this[e + 7];
|
|
529
|
-
(t === void 0 || n === void 0) && K(e, this.length - 8);
|
|
530
|
-
let r = (t << 24) + this[++e] * 2 ** 16 + this[++e] * 256 + this[++e];
|
|
531
|
-
return (BigInt(r) << BigInt(32)) + BigInt(this[++e] * 2 ** 24 + this[++e] * 2 ** 16 + this[++e] * 256 + n);
|
|
532
|
-
}), d.prototype.readFloatLE = function(e, t) {
|
|
533
|
-
return e >>>= 0, t || N(e, 4, this.length), r.read(this, e, !0, 23, 4);
|
|
534
|
-
}, d.prototype.readFloatBE = function(e, t) {
|
|
535
|
-
return e >>>= 0, t || N(e, 4, this.length), r.read(this, e, !1, 23, 4);
|
|
536
|
-
}, d.prototype.readDoubleLE = function(e, t) {
|
|
537
|
-
return e >>>= 0, t || N(e, 8, this.length), r.read(this, e, !0, 52, 8);
|
|
538
|
-
}, d.prototype.readDoubleBE = function(e, t) {
|
|
539
|
-
return e >>>= 0, t || N(e, 8, this.length), r.read(this, e, !1, 52, 8);
|
|
540
|
-
};
|
|
541
|
-
function P(e, t, n, r, i, a) {
|
|
542
|
-
if (!d.isBuffer(e)) throw TypeError("\"buffer\" argument must be a Buffer instance");
|
|
543
|
-
if (t > i || t < a) throw RangeError("\"value\" argument is out of bounds");
|
|
544
|
-
if (n + r > e.length) throw RangeError("Index out of range");
|
|
545
|
-
}
|
|
546
|
-
d.prototype.writeUintLE = d.prototype.writeUIntLE = function(e, t, n, r) {
|
|
547
|
-
if (e = +e, t >>>= 0, n >>>= 0, !r) {
|
|
548
|
-
let r = 2 ** (8 * n) - 1;
|
|
549
|
-
P(this, e, t, n, r, 0);
|
|
550
|
-
}
|
|
551
|
-
let i = 1, a = 0;
|
|
552
|
-
for (this[t] = e & 255; ++a < n && (i *= 256);) this[t + a] = e / i & 255;
|
|
553
|
-
return t + n;
|
|
554
|
-
}, d.prototype.writeUintBE = d.prototype.writeUIntBE = function(e, t, n, r) {
|
|
555
|
-
if (e = +e, t >>>= 0, n >>>= 0, !r) {
|
|
556
|
-
let r = 2 ** (8 * n) - 1;
|
|
557
|
-
P(this, e, t, n, r, 0);
|
|
558
|
-
}
|
|
559
|
-
let i = n - 1, a = 1;
|
|
560
|
-
for (this[t + i] = e & 255; --i >= 0 && (a *= 256);) this[t + i] = e / a & 255;
|
|
561
|
-
return t + n;
|
|
562
|
-
}, d.prototype.writeUint8 = d.prototype.writeUInt8 = function(e, t, n) {
|
|
563
|
-
return e = +e, t >>>= 0, n || P(this, e, t, 1, 255, 0), this[t] = e & 255, t + 1;
|
|
564
|
-
}, d.prototype.writeUint16LE = d.prototype.writeUInt16LE = function(e, t, n) {
|
|
565
|
-
return e = +e, t >>>= 0, n || P(this, e, t, 2, 65535, 0), this[t] = e & 255, this[t + 1] = e >>> 8, t + 2;
|
|
566
|
-
}, d.prototype.writeUint16BE = d.prototype.writeUInt16BE = function(e, t, n) {
|
|
567
|
-
return e = +e, t >>>= 0, n || P(this, e, t, 2, 65535, 0), this[t] = e >>> 8, this[t + 1] = e & 255, t + 2;
|
|
568
|
-
}, d.prototype.writeUint32LE = d.prototype.writeUInt32LE = function(e, t, n) {
|
|
569
|
-
return e = +e, t >>>= 0, n || P(this, e, t, 4, 4294967295, 0), this[t + 3] = e >>> 24, this[t + 2] = e >>> 16, this[t + 1] = e >>> 8, this[t] = e & 255, t + 4;
|
|
570
|
-
}, d.prototype.writeUint32BE = d.prototype.writeUInt32BE = function(e, t, n) {
|
|
571
|
-
return e = +e, t >>>= 0, n || P(this, e, t, 4, 4294967295, 0), this[t] = e >>> 24, this[t + 1] = e >>> 16, this[t + 2] = e >>> 8, this[t + 3] = e & 255, t + 4;
|
|
572
|
-
};
|
|
573
|
-
function F(e, t, n, r, i) {
|
|
574
|
-
W(t, r, i, e, n, 7);
|
|
575
|
-
let a = Number(t & BigInt(4294967295));
|
|
576
|
-
e[n++] = a, a >>= 8, e[n++] = a, a >>= 8, e[n++] = a, a >>= 8, e[n++] = a;
|
|
577
|
-
let o = Number(t >> BigInt(32) & BigInt(4294967295));
|
|
578
|
-
return e[n++] = o, o >>= 8, e[n++] = o, o >>= 8, e[n++] = o, o >>= 8, e[n++] = o, n;
|
|
579
|
-
}
|
|
580
|
-
function I(e, t, n, r, i) {
|
|
581
|
-
W(t, r, i, e, n, 7);
|
|
582
|
-
let a = Number(t & BigInt(4294967295));
|
|
583
|
-
e[n + 7] = a, a >>= 8, e[n + 6] = a, a >>= 8, e[n + 5] = a, a >>= 8, e[n + 4] = a;
|
|
584
|
-
let o = Number(t >> BigInt(32) & BigInt(4294967295));
|
|
585
|
-
return e[n + 3] = o, o >>= 8, e[n + 2] = o, o >>= 8, e[n + 1] = o, o >>= 8, e[n] = o, n + 8;
|
|
586
|
-
}
|
|
587
|
-
d.prototype.writeBigUInt64LE = $(function(e, t = 0) {
|
|
588
|
-
return F(this, e, t, BigInt(0), BigInt("0xffffffffffffffff"));
|
|
589
|
-
}), d.prototype.writeBigUInt64BE = $(function(e, t = 0) {
|
|
590
|
-
return I(this, e, t, BigInt(0), BigInt("0xffffffffffffffff"));
|
|
591
|
-
}), d.prototype.writeIntLE = function(e, t, n, r) {
|
|
592
|
-
if (e = +e, t >>>= 0, !r) {
|
|
593
|
-
let r = 2 ** (8 * n - 1);
|
|
594
|
-
P(this, e, t, n, r - 1, -r);
|
|
595
|
-
}
|
|
596
|
-
let i = 0, a = 1, o = 0;
|
|
597
|
-
for (this[t] = e & 255; ++i < n && (a *= 256);) e < 0 && o === 0 && this[t + i - 1] !== 0 && (o = 1), this[t + i] = (e / a >> 0) - o & 255;
|
|
598
|
-
return t + n;
|
|
599
|
-
}, d.prototype.writeIntBE = function(e, t, n, r) {
|
|
600
|
-
if (e = +e, t >>>= 0, !r) {
|
|
601
|
-
let r = 2 ** (8 * n - 1);
|
|
602
|
-
P(this, e, t, n, r - 1, -r);
|
|
603
|
-
}
|
|
604
|
-
let i = n - 1, a = 1, o = 0;
|
|
605
|
-
for (this[t + i] = e & 255; --i >= 0 && (a *= 256);) e < 0 && o === 0 && this[t + i + 1] !== 0 && (o = 1), this[t + i] = (e / a >> 0) - o & 255;
|
|
606
|
-
return t + n;
|
|
607
|
-
}, d.prototype.writeInt8 = function(e, t, n) {
|
|
608
|
-
return e = +e, t >>>= 0, n || P(this, e, t, 1, 127, -128), e < 0 && (e = 255 + e + 1), this[t] = e & 255, t + 1;
|
|
609
|
-
}, d.prototype.writeInt16LE = function(e, t, n) {
|
|
610
|
-
return e = +e, t >>>= 0, n || P(this, e, t, 2, 32767, -32768), this[t] = e & 255, this[t + 1] = e >>> 8, t + 2;
|
|
611
|
-
}, d.prototype.writeInt16BE = function(e, t, n) {
|
|
612
|
-
return e = +e, t >>>= 0, n || P(this, e, t, 2, 32767, -32768), this[t] = e >>> 8, this[t + 1] = e & 255, t + 2;
|
|
613
|
-
}, d.prototype.writeInt32LE = function(e, t, n) {
|
|
614
|
-
return e = +e, t >>>= 0, n || P(this, e, t, 4, 2147483647, -2147483648), this[t] = e & 255, this[t + 1] = e >>> 8, this[t + 2] = e >>> 16, this[t + 3] = e >>> 24, t + 4;
|
|
615
|
-
}, d.prototype.writeInt32BE = function(e, t, n) {
|
|
616
|
-
return e = +e, t >>>= 0, n || P(this, e, t, 4, 2147483647, -2147483648), e < 0 && (e = 4294967295 + e + 1), this[t] = e >>> 24, this[t + 1] = e >>> 16, this[t + 2] = e >>> 8, this[t + 3] = e & 255, t + 4;
|
|
617
|
-
}, d.prototype.writeBigInt64LE = $(function(e, t = 0) {
|
|
618
|
-
return F(this, e, t, -BigInt("0x8000000000000000"), BigInt("0x7fffffffffffffff"));
|
|
619
|
-
}), d.prototype.writeBigInt64BE = $(function(e, t = 0) {
|
|
620
|
-
return I(this, e, t, -BigInt("0x8000000000000000"), BigInt("0x7fffffffffffffff"));
|
|
621
|
-
});
|
|
622
|
-
function L(e, t, n, r, i, a) {
|
|
623
|
-
if (n + r > e.length || n < 0) throw RangeError("Index out of range");
|
|
624
|
-
}
|
|
625
|
-
function R(e, t, n, i, a) {
|
|
626
|
-
return t = +t, n >>>= 0, a || L(e, t, n, 4), r.write(e, t, n, i, 23, 4), n + 4;
|
|
627
|
-
}
|
|
628
|
-
d.prototype.writeFloatLE = function(e, t, n) {
|
|
629
|
-
return R(this, e, t, !0, n);
|
|
630
|
-
}, d.prototype.writeFloatBE = function(e, t, n) {
|
|
631
|
-
return R(this, e, t, !1, n);
|
|
632
|
-
};
|
|
633
|
-
function z(e, t, n, i, a) {
|
|
634
|
-
return t = +t, n >>>= 0, a || L(e, t, n, 8), r.write(e, t, n, i, 52, 8), n + 8;
|
|
635
|
-
}
|
|
636
|
-
d.prototype.writeDoubleLE = function(e, t, n) {
|
|
637
|
-
return z(this, e, t, !0, n);
|
|
638
|
-
}, d.prototype.writeDoubleBE = function(e, t, n) {
|
|
639
|
-
return z(this, e, t, !1, n);
|
|
640
|
-
}, d.prototype.copy = function(e, t, n, r) {
|
|
641
|
-
if (!d.isBuffer(e)) throw TypeError("argument should be a Buffer");
|
|
642
|
-
if (n ||= 0, !r && r !== 0 && (r = this.length), t >= e.length && (t = e.length), t ||= 0, r > 0 && r < n && (r = n), r === n || e.length === 0 || this.length === 0) return 0;
|
|
643
|
-
if (t < 0) throw RangeError("targetStart out of bounds");
|
|
644
|
-
if (n < 0 || n >= this.length) throw RangeError("Index out of range");
|
|
645
|
-
if (r < 0) throw RangeError("sourceEnd out of bounds");
|
|
646
|
-
r > this.length && (r = this.length), e.length - t < r - n && (r = e.length - t + n);
|
|
647
|
-
let i = r - n;
|
|
648
|
-
return this === e && typeof o.prototype.copyWithin == "function" ? this.copyWithin(t, n, r) : o.prototype.set.call(e, this.subarray(n, r), t), i;
|
|
649
|
-
}, d.prototype.fill = function(e, t, n, r) {
|
|
650
|
-
if (typeof e == "string") {
|
|
651
|
-
if (typeof t == "string" ? (r = t, t = 0, n = this.length) : typeof n == "string" && (r = n, n = this.length), r !== void 0 && typeof r != "string") throw TypeError("encoding must be a string");
|
|
652
|
-
if (typeof r == "string" && !d.isEncoding(r)) throw TypeError("Unknown encoding: " + r);
|
|
653
|
-
if (e.length === 1) {
|
|
654
|
-
let t = e.charCodeAt(0);
|
|
655
|
-
(r === "utf8" && t < 128 || r === "latin1") && (e = t);
|
|
656
|
-
}
|
|
657
|
-
} else typeof e == "number" ? e &= 255 : typeof e == "boolean" && (e = Number(e));
|
|
658
|
-
if (t < 0 || this.length < t || this.length < n) throw RangeError("Out of range index");
|
|
659
|
-
if (n <= t) return this;
|
|
660
|
-
t >>>= 0, n = n === void 0 ? this.length : n >>> 0, e ||= 0;
|
|
661
|
-
let i;
|
|
662
|
-
if (typeof e == "number") for (i = t; i < n; ++i) this[i] = e;
|
|
663
|
-
else {
|
|
664
|
-
let a = d.isBuffer(e) ? e : d.from(e, r), o = a.length;
|
|
665
|
-
if (o === 0) throw TypeError("The value \"" + e + "\" is invalid for argument \"value\"");
|
|
666
|
-
for (i = 0; i < n - t; ++i) this[i + t] = a[i % o];
|
|
667
|
-
}
|
|
668
|
-
return this;
|
|
669
|
-
};
|
|
670
|
-
let B = {};
|
|
671
|
-
function V(e, t, n) {
|
|
672
|
-
B[e] = class extends n {
|
|
673
|
-
constructor() {
|
|
674
|
-
super(), Object.defineProperty(this, "message", {
|
|
675
|
-
value: t.apply(this, arguments),
|
|
676
|
-
writable: !0,
|
|
677
|
-
configurable: !0
|
|
678
|
-
}), this.name = `${this.name} [${e}]`, this.stack, delete this.name;
|
|
679
|
-
}
|
|
680
|
-
get code() {
|
|
681
|
-
return e;
|
|
682
|
-
}
|
|
683
|
-
set code(e) {
|
|
684
|
-
Object.defineProperty(this, "code", {
|
|
685
|
-
configurable: !0,
|
|
686
|
-
enumerable: !0,
|
|
687
|
-
value: e,
|
|
688
|
-
writable: !0
|
|
689
|
-
});
|
|
690
|
-
}
|
|
691
|
-
toString() {
|
|
692
|
-
return `${this.name} [${e}]: ${this.message}`;
|
|
693
|
-
}
|
|
694
|
-
};
|
|
695
|
-
}
|
|
696
|
-
V("ERR_BUFFER_OUT_OF_BOUNDS", function(e) {
|
|
697
|
-
return e ? `${e} is outside of buffer bounds` : "Attempt to access memory outside buffer bounds";
|
|
698
|
-
}, RangeError), V("ERR_INVALID_ARG_TYPE", function(e, t) {
|
|
699
|
-
return `The "${e}" argument must be of type number. Received type ${typeof t}`;
|
|
700
|
-
}, TypeError), V("ERR_OUT_OF_RANGE", function(e, t, n) {
|
|
701
|
-
let r = `The value of "${e}" is out of range.`, i = n;
|
|
702
|
-
return Number.isInteger(n) && Math.abs(n) > 2 ** 32 ? i = H(String(n)) : typeof n == "bigint" && (i = String(n), (n > BigInt(2) ** BigInt(32) || n < -(BigInt(2) ** BigInt(32))) && (i = H(i)), i += "n"), r += ` It must be ${t}. Received ${i}`, r;
|
|
703
|
-
}, RangeError);
|
|
704
|
-
function H(e) {
|
|
705
|
-
let t = "", n = e.length, r = +(e[0] === "-");
|
|
706
|
-
for (; n >= r + 4; n -= 3) t = `_${e.slice(n - 3, n)}${t}`;
|
|
707
|
-
return `${e.slice(0, n)}${t}`;
|
|
708
|
-
}
|
|
709
|
-
function U(e, t, n) {
|
|
710
|
-
G(t, "offset"), (e[t] === void 0 || e[t + n] === void 0) && K(t, e.length - (n + 1));
|
|
711
|
-
}
|
|
712
|
-
function W(e, t, n, r, i, a) {
|
|
713
|
-
if (e > n || e < t) {
|
|
714
|
-
let r = typeof t == "bigint" ? "n" : "", i;
|
|
715
|
-
throw i = a > 3 ? t === 0 || t === BigInt(0) ? `>= 0${r} and < 2${r} ** ${(a + 1) * 8}${r}` : `>= -(2${r} ** ${(a + 1) * 8 - 1}${r}) and < 2 ** ${(a + 1) * 8 - 1}${r}` : `>= ${t}${r} and <= ${n}${r}`, new B.ERR_OUT_OF_RANGE("value", i, e);
|
|
716
|
-
}
|
|
717
|
-
U(r, i, a);
|
|
718
|
-
}
|
|
719
|
-
function G(e, t) {
|
|
720
|
-
if (typeof e != "number") throw new B.ERR_INVALID_ARG_TYPE(t, "number", e);
|
|
721
|
-
}
|
|
722
|
-
function K(e, t, n) {
|
|
723
|
-
throw Math.floor(e) === e ? t < 0 ? new B.ERR_BUFFER_OUT_OF_BOUNDS() : new B.ERR_OUT_OF_RANGE(n || "offset", `>= ${+!!n} and <= ${t}`, e) : (G(e, n), new B.ERR_OUT_OF_RANGE(n || "offset", "an integer", e));
|
|
724
|
-
}
|
|
725
|
-
let le = /[^+/0-9A-Za-z-_]/g;
|
|
726
|
-
function ue(e) {
|
|
727
|
-
if (e = e.split("=")[0], e = e.trim().replace(le, ""), e.length < 2) return "";
|
|
728
|
-
for (; e.length % 4 != 0;) e += "=";
|
|
729
|
-
return e;
|
|
730
|
-
}
|
|
731
|
-
function q(e, t) {
|
|
732
|
-
t ||= Infinity;
|
|
733
|
-
let n, r = e.length, i = null, a = [];
|
|
734
|
-
for (let o = 0; o < r; ++o) {
|
|
735
|
-
if (n = e.charCodeAt(o), n > 55295 && n < 57344) {
|
|
736
|
-
if (!i) {
|
|
737
|
-
if (n > 56319) {
|
|
738
|
-
(t -= 3) > -1 && a.push(239, 191, 189);
|
|
739
|
-
continue;
|
|
740
|
-
}
|
|
741
|
-
if (o + 1 === r) {
|
|
742
|
-
(t -= 3) > -1 && a.push(239, 191, 189);
|
|
743
|
-
continue;
|
|
744
|
-
}
|
|
745
|
-
i = n;
|
|
746
|
-
continue;
|
|
747
|
-
}
|
|
748
|
-
if (n < 56320) {
|
|
749
|
-
(t -= 3) > -1 && a.push(239, 191, 189), i = n;
|
|
750
|
-
continue;
|
|
751
|
-
}
|
|
752
|
-
n = (i - 55296 << 10 | n - 56320) + 65536;
|
|
753
|
-
} else i && (t -= 3) > -1 && a.push(239, 191, 189);
|
|
754
|
-
if (i = null, n < 128) {
|
|
755
|
-
if (--t < 0) break;
|
|
756
|
-
a.push(n);
|
|
757
|
-
} else if (n < 2048) {
|
|
758
|
-
if ((t -= 2) < 0) break;
|
|
759
|
-
a.push(n >> 6 | 192, n & 63 | 128);
|
|
760
|
-
} else if (n < 65536) {
|
|
761
|
-
if ((t -= 3) < 0) break;
|
|
762
|
-
a.push(n >> 12 | 224, n >> 6 & 63 | 128, n & 63 | 128);
|
|
763
|
-
} else if (n < 1114112) {
|
|
764
|
-
if ((t -= 4) < 0) break;
|
|
765
|
-
a.push(n >> 18 | 240, n >> 12 & 63 | 128, n >> 6 & 63 | 128, n & 63 | 128);
|
|
766
|
-
} else throw Error("Invalid code point");
|
|
767
|
-
}
|
|
768
|
-
return a;
|
|
769
|
-
}
|
|
770
|
-
function de(e) {
|
|
771
|
-
let t = [];
|
|
772
|
-
for (let n = 0; n < e.length; ++n) t.push(e.charCodeAt(n) & 255);
|
|
773
|
-
return t;
|
|
774
|
-
}
|
|
775
|
-
function J(e, t) {
|
|
776
|
-
let n, r, i, a = [];
|
|
777
|
-
for (let o = 0; o < e.length && !((t -= 2) < 0); ++o) n = e.charCodeAt(o), r = n >> 8, i = n % 256, a.push(i), a.push(r);
|
|
778
|
-
return a;
|
|
779
|
-
}
|
|
780
|
-
function Y(e) {
|
|
781
|
-
return t.toByteArray(ue(e));
|
|
782
|
-
}
|
|
783
|
-
function X(e, t, n, r) {
|
|
784
|
-
let i;
|
|
785
|
-
for (i = 0; i < r && !(i + n >= t.length || i >= e.length); ++i) t[i + n] = e[i];
|
|
786
|
-
return i;
|
|
787
|
-
}
|
|
788
|
-
function Z(e, t) {
|
|
789
|
-
return e instanceof t || e != null && e.constructor != null && e.constructor.name != null && e.constructor.name === t.name;
|
|
790
|
-
}
|
|
791
|
-
function Q(e) {
|
|
792
|
-
return e !== e;
|
|
793
|
-
}
|
|
794
|
-
let fe = (function() {
|
|
795
|
-
let e = "0123456789abcdef", t = Array(256);
|
|
796
|
-
for (let n = 0; n < 16; ++n) {
|
|
797
|
-
let r = n * 16;
|
|
798
|
-
for (let i = 0; i < 16; ++i) t[r + i] = e[n] + e[i];
|
|
799
|
-
}
|
|
800
|
-
return t;
|
|
801
|
-
})();
|
|
802
|
-
function $(e) {
|
|
803
|
-
return typeof BigInt > "u" ? pe : e;
|
|
804
|
-
}
|
|
805
|
-
function pe() {
|
|
806
|
-
throw Error("BigInt not supported");
|
|
807
|
-
}
|
|
808
|
-
})(t);
|
|
809
|
-
var _ = t.Buffer;
|
|
810
|
-
t.Blob, t.BlobOptions, t.Buffer, t.File, t.FileOptions, t.INSPECT_MAX_BYTES, t.SlowBuffer, t.TranscodeEncoding, t.atob, t.btoa, t.constants, t.isAscii, t.isUtf8, t.kMaxLength, t.kStringMaxLength, t.resolveObjectURL, t.transcode;
|
|
811
|
-
//#endregion
|
|
812
|
-
export { e as n, _ as t };
|