vitessce 3.3.6 → 3.3.7
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/blosc-956db408.js +716 -0
- package/dist/browser-554eb095.js +524 -0
- package/dist/chunk-INHXZS53-098e8433.js +14 -0
- package/dist/{deflate-9e423bc3.js → deflate-7339ed48.js} +1 -1
- package/dist/gzip-61747bf5.js +24 -0
- package/dist/{hglib-e5c0ae1a.js → hglib-4d4fcdaa.js} +1 -1
- package/dist/{index-1e4a64e8.js → index-49a32ccf.js} +46057 -45226
- package/dist/index.min.js +1 -1
- package/dist/{jpeg-5261849f.js → jpeg-7f257036.js} +1 -1
- package/dist/{lerc-0fea78d5.js → lerc-3e44eeeb.js} +1 -1
- package/dist/lz4-06c5cf38.js +640 -0
- package/dist/{lzw-1a05b6d0.js → lzw-1ab3e2ce.js} +1 -1
- package/dist/{packbits-d82fd6d7.js → packbits-e3afba86.js} +1 -1
- package/dist/{raw-390bbd75.js → raw-86c4def1.js} +1 -1
- package/dist/{webimage-a8dfc9d0.js → webimage-13d23394.js} +1 -1
- package/dist/zlib-99872a4e.js +24 -0
- package/dist/zstd-3d748ae3.js +639 -0
- package/package.json +5 -5
- package/dist/blosc-1a207459.js +0 -806
- package/dist/gzip-f01f0894.js +0 -22
- package/dist/lz4-cf6d9a58.js +0 -762
- package/dist/pako.esm-856454b6-9892b637.js +0 -1716
- package/dist/zlib-78d53244.js +0 -22
- package/dist/zstd-c70336b5.js +0 -762
|
@@ -1,1716 +0,0 @@
|
|
|
1
|
-
/*! pako 2.0.3 https://github.com/nodeca/pako @license (MIT AND Zlib) */
|
|
2
|
-
function _e(e) {
|
|
3
|
-
let i = e.length;
|
|
4
|
-
for (; --i >= 0; )
|
|
5
|
-
e[i] = 0;
|
|
6
|
-
}
|
|
7
|
-
const Ci = 0, ai = 1, $i = 2, Fi = 3, Mi = 258, dt = 29, Ae = 256, ge = Ae + 1 + dt, oe = 30, st = 19, ni = 2 * ge + 1, Q = 15, Ge = 16, Hi = 7, ct = 256, li = 16, ri = 17, fi = 18, ft = (
|
|
8
|
-
/* extra bits for each length code */
|
|
9
|
-
new Uint8Array([0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 0])
|
|
10
|
-
), Ce = (
|
|
11
|
-
/* extra bits for each distance code */
|
|
12
|
-
new Uint8Array([0, 0, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 13, 13])
|
|
13
|
-
), Bi = (
|
|
14
|
-
/* extra bits for each bit length code */
|
|
15
|
-
new Uint8Array([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 3, 7])
|
|
16
|
-
), oi = new Uint8Array([16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15]), Ki = 512, B = new Array((ge + 2) * 2);
|
|
17
|
-
_e(B);
|
|
18
|
-
const ue = new Array(oe * 2);
|
|
19
|
-
_e(ue);
|
|
20
|
-
const pe = new Array(Ki);
|
|
21
|
-
_e(pe);
|
|
22
|
-
const xe = new Array(Mi - Fi + 1);
|
|
23
|
-
_e(xe);
|
|
24
|
-
const ut = new Array(dt);
|
|
25
|
-
_e(ut);
|
|
26
|
-
const He = new Array(oe);
|
|
27
|
-
_e(He);
|
|
28
|
-
function je(e, i, t, n, a) {
|
|
29
|
-
this.static_tree = e, this.extra_bits = i, this.extra_base = t, this.elems = n, this.max_length = a, this.has_stree = e && e.length;
|
|
30
|
-
}
|
|
31
|
-
let _i, hi, di;
|
|
32
|
-
function We(e, i) {
|
|
33
|
-
this.dyn_tree = e, this.max_code = 0, this.stat_desc = i;
|
|
34
|
-
}
|
|
35
|
-
const si = (e) => e < 256 ? pe[e] : pe[256 + (e >>> 7)], ke = (e, i) => {
|
|
36
|
-
e.pending_buf[e.pending++] = i & 255, e.pending_buf[e.pending++] = i >>> 8 & 255;
|
|
37
|
-
}, N = (e, i, t) => {
|
|
38
|
-
e.bi_valid > Ge - t ? (e.bi_buf |= i << e.bi_valid & 65535, ke(e, e.bi_buf), e.bi_buf = i >> Ge - e.bi_valid, e.bi_valid += t - Ge) : (e.bi_buf |= i << e.bi_valid & 65535, e.bi_valid += t);
|
|
39
|
-
}, F = (e, i, t) => {
|
|
40
|
-
N(
|
|
41
|
-
e,
|
|
42
|
-
t[i * 2],
|
|
43
|
-
t[i * 2 + 1]
|
|
44
|
-
/*.Len*/
|
|
45
|
-
);
|
|
46
|
-
}, ci = (e, i) => {
|
|
47
|
-
let t = 0;
|
|
48
|
-
do
|
|
49
|
-
t |= e & 1, e >>>= 1, t <<= 1;
|
|
50
|
-
while (--i > 0);
|
|
51
|
-
return t >>> 1;
|
|
52
|
-
}, Pi = (e) => {
|
|
53
|
-
e.bi_valid === 16 ? (ke(e, e.bi_buf), e.bi_buf = 0, e.bi_valid = 0) : e.bi_valid >= 8 && (e.pending_buf[e.pending++] = e.bi_buf & 255, e.bi_buf >>= 8, e.bi_valid -= 8);
|
|
54
|
-
}, Xi = (e, i) => {
|
|
55
|
-
const t = i.dyn_tree, n = i.max_code, a = i.stat_desc.static_tree, l = i.stat_desc.has_stree, o = i.stat_desc.extra_bits, f = i.stat_desc.extra_base, c = i.stat_desc.max_length;
|
|
56
|
-
let r, _, E, s, h, u, m = 0;
|
|
57
|
-
for (s = 0; s <= Q; s++)
|
|
58
|
-
e.bl_count[s] = 0;
|
|
59
|
-
for (t[e.heap[e.heap_max] * 2 + 1] = 0, r = e.heap_max + 1; r < ni; r++)
|
|
60
|
-
_ = e.heap[r], s = t[t[_ * 2 + 1] * 2 + 1] + 1, s > c && (s = c, m++), t[_ * 2 + 1] = s, !(_ > n) && (e.bl_count[s]++, h = 0, _ >= f && (h = o[_ - f]), u = t[_ * 2], e.opt_len += u * (s + h), l && (e.static_len += u * (a[_ * 2 + 1] + h)));
|
|
61
|
-
if (m !== 0) {
|
|
62
|
-
do {
|
|
63
|
-
for (s = c - 1; e.bl_count[s] === 0; )
|
|
64
|
-
s--;
|
|
65
|
-
e.bl_count[s]--, e.bl_count[s + 1] += 2, e.bl_count[c]--, m -= 2;
|
|
66
|
-
} while (m > 0);
|
|
67
|
-
for (s = c; s !== 0; s--)
|
|
68
|
-
for (_ = e.bl_count[s]; _ !== 0; )
|
|
69
|
-
E = e.heap[--r], !(E > n) && (t[E * 2 + 1] !== s && (e.opt_len += (s - t[E * 2 + 1]) * t[E * 2], t[E * 2 + 1] = s), _--);
|
|
70
|
-
}
|
|
71
|
-
}, ui = (e, i, t) => {
|
|
72
|
-
const n = new Array(Q + 1);
|
|
73
|
-
let a = 0, l, o;
|
|
74
|
-
for (l = 1; l <= Q; l++)
|
|
75
|
-
n[l] = a = a + t[l - 1] << 1;
|
|
76
|
-
for (o = 0; o <= i; o++) {
|
|
77
|
-
let f = e[o * 2 + 1];
|
|
78
|
-
f !== 0 && (e[o * 2] = ci(n[f]++, f));
|
|
79
|
-
}
|
|
80
|
-
}, Yi = () => {
|
|
81
|
-
let e, i, t, n, a;
|
|
82
|
-
const l = new Array(Q + 1);
|
|
83
|
-
for (t = 0, n = 0; n < dt - 1; n++)
|
|
84
|
-
for (ut[n] = t, e = 0; e < 1 << ft[n]; e++)
|
|
85
|
-
xe[t++] = n;
|
|
86
|
-
for (xe[t - 1] = n, a = 0, n = 0; n < 16; n++)
|
|
87
|
-
for (He[n] = a, e = 0; e < 1 << Ce[n]; e++)
|
|
88
|
-
pe[a++] = n;
|
|
89
|
-
for (a >>= 7; n < oe; n++)
|
|
90
|
-
for (He[n] = a << 7, e = 0; e < 1 << Ce[n] - 7; e++)
|
|
91
|
-
pe[256 + a++] = n;
|
|
92
|
-
for (i = 0; i <= Q; i++)
|
|
93
|
-
l[i] = 0;
|
|
94
|
-
for (e = 0; e <= 143; )
|
|
95
|
-
B[e * 2 + 1] = 8, e++, l[8]++;
|
|
96
|
-
for (; e <= 255; )
|
|
97
|
-
B[e * 2 + 1] = 9, e++, l[9]++;
|
|
98
|
-
for (; e <= 279; )
|
|
99
|
-
B[e * 2 + 1] = 7, e++, l[7]++;
|
|
100
|
-
for (; e <= 287; )
|
|
101
|
-
B[e * 2 + 1] = 8, e++, l[8]++;
|
|
102
|
-
for (ui(B, ge + 1, l), e = 0; e < oe; e++)
|
|
103
|
-
ue[e * 2 + 1] = 5, ue[e * 2] = ci(e, 5);
|
|
104
|
-
_i = new je(B, ft, Ae + 1, ge, Q), hi = new je(ue, Ce, 0, oe, Q), di = new je(new Array(0), Bi, 0, st, Hi);
|
|
105
|
-
}, bi = (e) => {
|
|
106
|
-
let i;
|
|
107
|
-
for (i = 0; i < ge; i++)
|
|
108
|
-
e.dyn_ltree[i * 2] = 0;
|
|
109
|
-
for (i = 0; i < oe; i++)
|
|
110
|
-
e.dyn_dtree[i * 2] = 0;
|
|
111
|
-
for (i = 0; i < st; i++)
|
|
112
|
-
e.bl_tree[i * 2] = 0;
|
|
113
|
-
e.dyn_ltree[ct * 2] = 1, e.opt_len = e.static_len = 0, e.last_lit = e.matches = 0;
|
|
114
|
-
}, wi = (e) => {
|
|
115
|
-
e.bi_valid > 8 ? ke(e, e.bi_buf) : e.bi_valid > 0 && (e.pending_buf[e.pending++] = e.bi_buf), e.bi_buf = 0, e.bi_valid = 0;
|
|
116
|
-
}, Gi = (e, i, t, n) => {
|
|
117
|
-
wi(e), n && (ke(e, t), ke(e, ~t)), e.pending_buf.set(e.window.subarray(i, i + t), e.pending), e.pending += t;
|
|
118
|
-
}, xt = (e, i, t, n) => {
|
|
119
|
-
const a = i * 2, l = t * 2;
|
|
120
|
-
return e[a] < e[l] || e[a] === e[l] && n[i] <= n[t];
|
|
121
|
-
}, Ve = (e, i, t) => {
|
|
122
|
-
const n = e.heap[t];
|
|
123
|
-
let a = t << 1;
|
|
124
|
-
for (; a <= e.heap_len && (a < e.heap_len && xt(i, e.heap[a + 1], e.heap[a], e.depth) && a++, !xt(i, n, e.heap[a], e.depth)); )
|
|
125
|
-
e.heap[t] = e.heap[a], t = a, a <<= 1;
|
|
126
|
-
e.heap[t] = n;
|
|
127
|
-
}, kt = (e, i, t) => {
|
|
128
|
-
let n, a, l = 0, o, f;
|
|
129
|
-
if (e.last_lit !== 0)
|
|
130
|
-
do
|
|
131
|
-
n = e.pending_buf[e.d_buf + l * 2] << 8 | e.pending_buf[e.d_buf + l * 2 + 1], a = e.pending_buf[e.l_buf + l], l++, n === 0 ? F(e, a, i) : (o = xe[a], F(e, o + Ae + 1, i), f = ft[o], f !== 0 && (a -= ut[o], N(e, a, f)), n--, o = si(n), F(e, o, t), f = Ce[o], f !== 0 && (n -= He[o], N(e, n, f)));
|
|
132
|
-
while (l < e.last_lit);
|
|
133
|
-
F(e, ct, i);
|
|
134
|
-
}, ot = (e, i) => {
|
|
135
|
-
const t = i.dyn_tree, n = i.stat_desc.static_tree, a = i.stat_desc.has_stree, l = i.stat_desc.elems;
|
|
136
|
-
let o, f, c = -1, r;
|
|
137
|
-
for (e.heap_len = 0, e.heap_max = ni, o = 0; o < l; o++)
|
|
138
|
-
t[o * 2] !== 0 ? (e.heap[++e.heap_len] = c = o, e.depth[o] = 0) : t[o * 2 + 1] = 0;
|
|
139
|
-
for (; e.heap_len < 2; )
|
|
140
|
-
r = e.heap[++e.heap_len] = c < 2 ? ++c : 0, t[r * 2] = 1, e.depth[r] = 0, e.opt_len--, a && (e.static_len -= n[r * 2 + 1]);
|
|
141
|
-
for (i.max_code = c, o = e.heap_len >> 1; o >= 1; o--)
|
|
142
|
-
Ve(e, t, o);
|
|
143
|
-
r = l;
|
|
144
|
-
do
|
|
145
|
-
o = e.heap[
|
|
146
|
-
1
|
|
147
|
-
/*SMALLEST*/
|
|
148
|
-
], e.heap[
|
|
149
|
-
1
|
|
150
|
-
/*SMALLEST*/
|
|
151
|
-
] = e.heap[e.heap_len--], Ve(
|
|
152
|
-
e,
|
|
153
|
-
t,
|
|
154
|
-
1
|
|
155
|
-
/*SMALLEST*/
|
|
156
|
-
), f = e.heap[
|
|
157
|
-
1
|
|
158
|
-
/*SMALLEST*/
|
|
159
|
-
], e.heap[--e.heap_max] = o, e.heap[--e.heap_max] = f, t[r * 2] = t[o * 2] + t[f * 2], e.depth[r] = (e.depth[o] >= e.depth[f] ? e.depth[o] : e.depth[f]) + 1, t[o * 2 + 1] = t[f * 2 + 1] = r, e.heap[
|
|
160
|
-
1
|
|
161
|
-
/*SMALLEST*/
|
|
162
|
-
] = r++, Ve(
|
|
163
|
-
e,
|
|
164
|
-
t,
|
|
165
|
-
1
|
|
166
|
-
/*SMALLEST*/
|
|
167
|
-
);
|
|
168
|
-
while (e.heap_len >= 2);
|
|
169
|
-
e.heap[--e.heap_max] = e.heap[
|
|
170
|
-
1
|
|
171
|
-
/*SMALLEST*/
|
|
172
|
-
], Xi(e, i), ui(t, c, e.bl_count);
|
|
173
|
-
}, vt = (e, i, t) => {
|
|
174
|
-
let n, a = -1, l, o = i[0 * 2 + 1], f = 0, c = 7, r = 4;
|
|
175
|
-
for (o === 0 && (c = 138, r = 3), i[(t + 1) * 2 + 1] = 65535, n = 0; n <= t; n++)
|
|
176
|
-
l = o, o = i[(n + 1) * 2 + 1], !(++f < c && l === o) && (f < r ? e.bl_tree[l * 2] += f : l !== 0 ? (l !== a && e.bl_tree[l * 2]++, e.bl_tree[li * 2]++) : f <= 10 ? e.bl_tree[ri * 2]++ : e.bl_tree[fi * 2]++, f = 0, a = l, o === 0 ? (c = 138, r = 3) : l === o ? (c = 6, r = 3) : (c = 7, r = 4));
|
|
177
|
-
}, Et = (e, i, t) => {
|
|
178
|
-
let n, a = -1, l, o = i[0 * 2 + 1], f = 0, c = 7, r = 4;
|
|
179
|
-
for (o === 0 && (c = 138, r = 3), n = 0; n <= t; n++)
|
|
180
|
-
if (l = o, o = i[(n + 1) * 2 + 1], !(++f < c && l === o)) {
|
|
181
|
-
if (f < r)
|
|
182
|
-
do
|
|
183
|
-
F(e, l, e.bl_tree);
|
|
184
|
-
while (--f !== 0);
|
|
185
|
-
else
|
|
186
|
-
l !== 0 ? (l !== a && (F(e, l, e.bl_tree), f--), F(e, li, e.bl_tree), N(e, f - 3, 2)) : f <= 10 ? (F(e, ri, e.bl_tree), N(e, f - 3, 3)) : (F(e, fi, e.bl_tree), N(e, f - 11, 7));
|
|
187
|
-
f = 0, a = l, o === 0 ? (c = 138, r = 3) : l === o ? (c = 6, r = 3) : (c = 7, r = 4);
|
|
188
|
-
}
|
|
189
|
-
}, ji = (e) => {
|
|
190
|
-
let i;
|
|
191
|
-
for (vt(e, e.dyn_ltree, e.l_desc.max_code), vt(e, e.dyn_dtree, e.d_desc.max_code), ot(e, e.bl_desc), i = st - 1; i >= 3 && e.bl_tree[oi[i] * 2 + 1] === 0; i--)
|
|
192
|
-
;
|
|
193
|
-
return e.opt_len += 3 * (i + 1) + 5 + 5 + 4, i;
|
|
194
|
-
}, Wi = (e, i, t, n) => {
|
|
195
|
-
let a;
|
|
196
|
-
for (N(e, i - 257, 5), N(e, t - 1, 5), N(e, n - 4, 4), a = 0; a < n; a++)
|
|
197
|
-
N(e, e.bl_tree[oi[a] * 2 + 1], 3);
|
|
198
|
-
Et(e, e.dyn_ltree, i - 1), Et(e, e.dyn_dtree, t - 1);
|
|
199
|
-
}, Vi = (e) => {
|
|
200
|
-
let i = 4093624447, t;
|
|
201
|
-
for (t = 0; t <= 31; t++, i >>>= 1)
|
|
202
|
-
if (i & 1 && e.dyn_ltree[t * 2] !== 0)
|
|
203
|
-
return 0;
|
|
204
|
-
if (e.dyn_ltree[9 * 2] !== 0 || e.dyn_ltree[10 * 2] !== 0 || e.dyn_ltree[13 * 2] !== 0)
|
|
205
|
-
return 1;
|
|
206
|
-
for (t = 32; t < Ae; t++)
|
|
207
|
-
if (e.dyn_ltree[t * 2] !== 0)
|
|
208
|
-
return 1;
|
|
209
|
-
return 0;
|
|
210
|
-
};
|
|
211
|
-
let yt = !1;
|
|
212
|
-
const Ji = (e) => {
|
|
213
|
-
yt || (Yi(), yt = !0), e.l_desc = new We(e.dyn_ltree, _i), e.d_desc = new We(e.dyn_dtree, hi), e.bl_desc = new We(e.bl_tree, di), e.bi_buf = 0, e.bi_valid = 0, bi(e);
|
|
214
|
-
}, gi = (e, i, t, n) => {
|
|
215
|
-
N(e, (Ci << 1) + (n ? 1 : 0), 3), Gi(e, i, t, !0);
|
|
216
|
-
}, Qi = (e) => {
|
|
217
|
-
N(e, ai << 1, 3), F(e, ct, B), Pi(e);
|
|
218
|
-
}, qi = (e, i, t, n) => {
|
|
219
|
-
let a, l, o = 0;
|
|
220
|
-
e.level > 0 ? (e.strm.data_type === 2 && (e.strm.data_type = Vi(e)), ot(e, e.l_desc), ot(e, e.d_desc), o = ji(e), a = e.opt_len + 3 + 7 >>> 3, l = e.static_len + 3 + 7 >>> 3, l <= a && (a = l)) : a = l = t + 5, t + 4 <= a && i !== -1 ? gi(e, i, t, n) : e.strategy === 4 || l === a ? (N(e, (ai << 1) + (n ? 1 : 0), 3), kt(e, B, ue)) : (N(e, ($i << 1) + (n ? 1 : 0), 3), Wi(e, e.l_desc.max_code + 1, e.d_desc.max_code + 1, o + 1), kt(e, e.dyn_ltree, e.dyn_dtree)), bi(e), n && wi(e);
|
|
221
|
-
}, ea = (e, i, t) => (e.pending_buf[e.d_buf + e.last_lit * 2] = i >>> 8 & 255, e.pending_buf[e.d_buf + e.last_lit * 2 + 1] = i & 255, e.pending_buf[e.l_buf + e.last_lit] = t & 255, e.last_lit++, i === 0 ? e.dyn_ltree[t * 2]++ : (e.matches++, i--, e.dyn_ltree[(xe[t] + Ae + 1) * 2]++, e.dyn_dtree[si(i) * 2]++), e.last_lit === e.lit_bufsize - 1);
|
|
222
|
-
var ta = Ji, ia = gi, aa = qi, na = ea, la = Qi, ra = {
|
|
223
|
-
_tr_init: ta,
|
|
224
|
-
_tr_stored_block: ia,
|
|
225
|
-
_tr_flush_block: aa,
|
|
226
|
-
_tr_tally: na,
|
|
227
|
-
_tr_align: la
|
|
228
|
-
};
|
|
229
|
-
const fa = (e, i, t, n) => {
|
|
230
|
-
let a = e & 65535 | 0, l = e >>> 16 & 65535 | 0, o = 0;
|
|
231
|
-
for (; t !== 0; ) {
|
|
232
|
-
o = t > 2e3 ? 2e3 : t, t -= o;
|
|
233
|
-
do
|
|
234
|
-
a = a + i[n++] | 0, l = l + a | 0;
|
|
235
|
-
while (--o);
|
|
236
|
-
a %= 65521, l %= 65521;
|
|
237
|
-
}
|
|
238
|
-
return a | l << 16 | 0;
|
|
239
|
-
};
|
|
240
|
-
var ve = fa;
|
|
241
|
-
const oa = () => {
|
|
242
|
-
let e, i = [];
|
|
243
|
-
for (var t = 0; t < 256; t++) {
|
|
244
|
-
e = t;
|
|
245
|
-
for (var n = 0; n < 8; n++)
|
|
246
|
-
e = e & 1 ? 3988292384 ^ e >>> 1 : e >>> 1;
|
|
247
|
-
i[t] = e;
|
|
248
|
-
}
|
|
249
|
-
return i;
|
|
250
|
-
}, _a = new Uint32Array(oa()), ha = (e, i, t, n) => {
|
|
251
|
-
const a = _a, l = n + t;
|
|
252
|
-
e ^= -1;
|
|
253
|
-
for (let o = n; o < l; o++)
|
|
254
|
-
e = e >>> 8 ^ a[(e ^ i[o]) & 255];
|
|
255
|
-
return e ^ -1;
|
|
256
|
-
};
|
|
257
|
-
var I = ha, ee = {
|
|
258
|
-
2: "need dictionary",
|
|
259
|
-
/* Z_NEED_DICT 2 */
|
|
260
|
-
1: "stream end",
|
|
261
|
-
/* Z_STREAM_END 1 */
|
|
262
|
-
0: "",
|
|
263
|
-
/* Z_OK 0 */
|
|
264
|
-
"-1": "file error",
|
|
265
|
-
/* Z_ERRNO (-1) */
|
|
266
|
-
"-2": "stream error",
|
|
267
|
-
/* Z_STREAM_ERROR (-2) */
|
|
268
|
-
"-3": "data error",
|
|
269
|
-
/* Z_DATA_ERROR (-3) */
|
|
270
|
-
"-4": "insufficient memory",
|
|
271
|
-
/* Z_MEM_ERROR (-4) */
|
|
272
|
-
"-5": "buffer error",
|
|
273
|
-
/* Z_BUF_ERROR (-5) */
|
|
274
|
-
"-6": "incompatible version"
|
|
275
|
-
/* Z_VERSION_ERROR (-6) */
|
|
276
|
-
}, ne = {
|
|
277
|
-
/* Allowed flush values; see deflate() and inflate() below for details */
|
|
278
|
-
Z_NO_FLUSH: 0,
|
|
279
|
-
Z_PARTIAL_FLUSH: 1,
|
|
280
|
-
Z_SYNC_FLUSH: 2,
|
|
281
|
-
Z_FULL_FLUSH: 3,
|
|
282
|
-
Z_FINISH: 4,
|
|
283
|
-
Z_BLOCK: 5,
|
|
284
|
-
Z_TREES: 6,
|
|
285
|
-
/* Return codes for the compression/decompression functions. Negative values
|
|
286
|
-
* are errors, positive values are used for special but normal events.
|
|
287
|
-
*/
|
|
288
|
-
Z_OK: 0,
|
|
289
|
-
Z_STREAM_END: 1,
|
|
290
|
-
Z_NEED_DICT: 2,
|
|
291
|
-
Z_ERRNO: -1,
|
|
292
|
-
Z_STREAM_ERROR: -2,
|
|
293
|
-
Z_DATA_ERROR: -3,
|
|
294
|
-
Z_MEM_ERROR: -4,
|
|
295
|
-
Z_BUF_ERROR: -5,
|
|
296
|
-
//Z_VERSION_ERROR: -6,
|
|
297
|
-
/* compression levels */
|
|
298
|
-
Z_NO_COMPRESSION: 0,
|
|
299
|
-
Z_BEST_SPEED: 1,
|
|
300
|
-
Z_BEST_COMPRESSION: 9,
|
|
301
|
-
Z_DEFAULT_COMPRESSION: -1,
|
|
302
|
-
Z_FILTERED: 1,
|
|
303
|
-
Z_HUFFMAN_ONLY: 2,
|
|
304
|
-
Z_RLE: 3,
|
|
305
|
-
Z_FIXED: 4,
|
|
306
|
-
Z_DEFAULT_STRATEGY: 0,
|
|
307
|
-
/* Possible values of the data_type field (though see inflate()) */
|
|
308
|
-
Z_BINARY: 0,
|
|
309
|
-
Z_TEXT: 1,
|
|
310
|
-
//Z_ASCII: 1, // = Z_TEXT (deprecated)
|
|
311
|
-
Z_UNKNOWN: 2,
|
|
312
|
-
/* The deflate compression method */
|
|
313
|
-
Z_DEFLATED: 8
|
|
314
|
-
//Z_NULL: null // Use -1 or null inline, depending on var type
|
|
315
|
-
};
|
|
316
|
-
const { _tr_init: da, _tr_stored_block: sa, _tr_flush_block: ca, _tr_tally: j, _tr_align: ua } = ra, {
|
|
317
|
-
Z_NO_FLUSH: le,
|
|
318
|
-
Z_PARTIAL_FLUSH: ba,
|
|
319
|
-
Z_FULL_FLUSH: wa,
|
|
320
|
-
Z_FINISH: W,
|
|
321
|
-
Z_BLOCK: St,
|
|
322
|
-
Z_OK: M,
|
|
323
|
-
Z_STREAM_END: At,
|
|
324
|
-
Z_STREAM_ERROR: L,
|
|
325
|
-
Z_DATA_ERROR: ga,
|
|
326
|
-
Z_BUF_ERROR: Je,
|
|
327
|
-
Z_DEFAULT_COMPRESSION: pa,
|
|
328
|
-
Z_FILTERED: xa,
|
|
329
|
-
Z_HUFFMAN_ONLY: Ie,
|
|
330
|
-
Z_RLE: ka,
|
|
331
|
-
Z_FIXED: va,
|
|
332
|
-
Z_DEFAULT_STRATEGY: Ea,
|
|
333
|
-
Z_UNKNOWN: ya,
|
|
334
|
-
Z_DEFLATED: Pe
|
|
335
|
-
} = ne, Sa = 9, Aa = 15, Ra = 8, za = 29, Ta = 256, _t = Ta + 1 + za, ma = 30, Da = 19, Za = 2 * _t + 1, Ia = 15, k = 3, Y = 258, C = Y + k + 1, Oa = 32, Xe = 42, ht = 69, $e = 73, Fe = 91, Me = 103, q = 113, se = 666, D = 1, Re = 2, te = 3, he = 4, Na = 3, G = (e, i) => (e.msg = ee[i], i), Rt = (e) => (e << 1) - (e > 4 ? 9 : 0), X = (e) => {
|
|
336
|
-
let i = e.length;
|
|
337
|
-
for (; --i >= 0; )
|
|
338
|
-
e[i] = 0;
|
|
339
|
-
};
|
|
340
|
-
let La = (e, i, t) => (i << e.hash_shift ^ t) & e.hash_mask, V = La;
|
|
341
|
-
const P = (e) => {
|
|
342
|
-
const i = e.state;
|
|
343
|
-
let t = i.pending;
|
|
344
|
-
t > e.avail_out && (t = e.avail_out), t !== 0 && (e.output.set(i.pending_buf.subarray(i.pending_out, i.pending_out + t), e.next_out), e.next_out += t, i.pending_out += t, e.total_out += t, e.avail_out -= t, i.pending -= t, i.pending === 0 && (i.pending_out = 0));
|
|
345
|
-
}, O = (e, i) => {
|
|
346
|
-
ca(e, e.block_start >= 0 ? e.block_start : -1, e.strstart - e.block_start, i), e.block_start = e.strstart, P(e.strm);
|
|
347
|
-
}, y = (e, i) => {
|
|
348
|
-
e.pending_buf[e.pending++] = i;
|
|
349
|
-
}, de = (e, i) => {
|
|
350
|
-
e.pending_buf[e.pending++] = i >>> 8 & 255, e.pending_buf[e.pending++] = i & 255;
|
|
351
|
-
}, Ua = (e, i, t, n) => {
|
|
352
|
-
let a = e.avail_in;
|
|
353
|
-
return a > n && (a = n), a === 0 ? 0 : (e.avail_in -= a, i.set(e.input.subarray(e.next_in, e.next_in + a), t), e.state.wrap === 1 ? e.adler = ve(e.adler, i, a, t) : e.state.wrap === 2 && (e.adler = I(e.adler, i, a, t)), e.next_in += a, e.total_in += a, a);
|
|
354
|
-
}, pi = (e, i) => {
|
|
355
|
-
let t = e.max_chain_length, n = e.strstart, a, l, o = e.prev_length, f = e.nice_match;
|
|
356
|
-
const c = e.strstart > e.w_size - C ? e.strstart - (e.w_size - C) : 0, r = e.window, _ = e.w_mask, E = e.prev, s = e.strstart + Y;
|
|
357
|
-
let h = r[n + o - 1], u = r[n + o];
|
|
358
|
-
e.prev_length >= e.good_match && (t >>= 2), f > e.lookahead && (f = e.lookahead);
|
|
359
|
-
do
|
|
360
|
-
if (a = i, !(r[a + o] !== u || r[a + o - 1] !== h || r[a] !== r[n] || r[++a] !== r[n + 1])) {
|
|
361
|
-
n += 2, a++;
|
|
362
|
-
do
|
|
363
|
-
;
|
|
364
|
-
while (r[++n] === r[++a] && r[++n] === r[++a] && r[++n] === r[++a] && r[++n] === r[++a] && r[++n] === r[++a] && r[++n] === r[++a] && r[++n] === r[++a] && r[++n] === r[++a] && n < s);
|
|
365
|
-
if (l = Y - (s - n), n = s - Y, l > o) {
|
|
366
|
-
if (e.match_start = i, o = l, l >= f)
|
|
367
|
-
break;
|
|
368
|
-
h = r[n + o - 1], u = r[n + o];
|
|
369
|
-
}
|
|
370
|
-
}
|
|
371
|
-
while ((i = E[i & _]) > c && --t !== 0);
|
|
372
|
-
return o <= e.lookahead ? o : e.lookahead;
|
|
373
|
-
}, ie = (e) => {
|
|
374
|
-
const i = e.w_size;
|
|
375
|
-
let t, n, a, l, o;
|
|
376
|
-
do {
|
|
377
|
-
if (l = e.window_size - e.lookahead - e.strstart, e.strstart >= i + (i - C)) {
|
|
378
|
-
e.window.set(e.window.subarray(i, i + i), 0), e.match_start -= i, e.strstart -= i, e.block_start -= i, n = e.hash_size, t = n;
|
|
379
|
-
do
|
|
380
|
-
a = e.head[--t], e.head[t] = a >= i ? a - i : 0;
|
|
381
|
-
while (--n);
|
|
382
|
-
n = i, t = n;
|
|
383
|
-
do
|
|
384
|
-
a = e.prev[--t], e.prev[t] = a >= i ? a - i : 0;
|
|
385
|
-
while (--n);
|
|
386
|
-
l += i;
|
|
387
|
-
}
|
|
388
|
-
if (e.strm.avail_in === 0)
|
|
389
|
-
break;
|
|
390
|
-
if (n = Ua(e.strm, e.window, e.strstart + e.lookahead, l), e.lookahead += n, e.lookahead + e.insert >= k)
|
|
391
|
-
for (o = e.strstart - e.insert, e.ins_h = e.window[o], e.ins_h = V(e, e.ins_h, e.window[o + 1]); e.insert && (e.ins_h = V(e, e.ins_h, e.window[o + k - 1]), e.prev[o & e.w_mask] = e.head[e.ins_h], e.head[e.ins_h] = o, o++, e.insert--, !(e.lookahead + e.insert < k)); )
|
|
392
|
-
;
|
|
393
|
-
} while (e.lookahead < C && e.strm.avail_in !== 0);
|
|
394
|
-
}, Ca = (e, i) => {
|
|
395
|
-
let t = 65535;
|
|
396
|
-
for (t > e.pending_buf_size - 5 && (t = e.pending_buf_size - 5); ; ) {
|
|
397
|
-
if (e.lookahead <= 1) {
|
|
398
|
-
if (ie(e), e.lookahead === 0 && i === le)
|
|
399
|
-
return D;
|
|
400
|
-
if (e.lookahead === 0)
|
|
401
|
-
break;
|
|
402
|
-
}
|
|
403
|
-
e.strstart += e.lookahead, e.lookahead = 0;
|
|
404
|
-
const n = e.block_start + t;
|
|
405
|
-
if ((e.strstart === 0 || e.strstart >= n) && (e.lookahead = e.strstart - n, e.strstart = n, O(e, !1), e.strm.avail_out === 0) || e.strstart - e.block_start >= e.w_size - C && (O(e, !1), e.strm.avail_out === 0))
|
|
406
|
-
return D;
|
|
407
|
-
}
|
|
408
|
-
return e.insert = 0, i === W ? (O(e, !0), e.strm.avail_out === 0 ? te : he) : (e.strstart > e.block_start && (O(e, !1), e.strm.avail_out === 0), D);
|
|
409
|
-
}, Qe = (e, i) => {
|
|
410
|
-
let t, n;
|
|
411
|
-
for (; ; ) {
|
|
412
|
-
if (e.lookahead < C) {
|
|
413
|
-
if (ie(e), e.lookahead < C && i === le)
|
|
414
|
-
return D;
|
|
415
|
-
if (e.lookahead === 0)
|
|
416
|
-
break;
|
|
417
|
-
}
|
|
418
|
-
if (t = 0, e.lookahead >= k && (e.ins_h = V(e, e.ins_h, e.window[e.strstart + k - 1]), t = e.prev[e.strstart & e.w_mask] = e.head[e.ins_h], e.head[e.ins_h] = e.strstart), t !== 0 && e.strstart - t <= e.w_size - C && (e.match_length = pi(e, t)), e.match_length >= k)
|
|
419
|
-
if (n = j(e, e.strstart - e.match_start, e.match_length - k), e.lookahead -= e.match_length, e.match_length <= e.max_lazy_match && e.lookahead >= k) {
|
|
420
|
-
e.match_length--;
|
|
421
|
-
do
|
|
422
|
-
e.strstart++, e.ins_h = V(e, e.ins_h, e.window[e.strstart + k - 1]), t = e.prev[e.strstart & e.w_mask] = e.head[e.ins_h], e.head[e.ins_h] = e.strstart;
|
|
423
|
-
while (--e.match_length !== 0);
|
|
424
|
-
e.strstart++;
|
|
425
|
-
} else
|
|
426
|
-
e.strstart += e.match_length, e.match_length = 0, e.ins_h = e.window[e.strstart], e.ins_h = V(e, e.ins_h, e.window[e.strstart + 1]);
|
|
427
|
-
else
|
|
428
|
-
n = j(e, 0, e.window[e.strstart]), e.lookahead--, e.strstart++;
|
|
429
|
-
if (n && (O(e, !1), e.strm.avail_out === 0))
|
|
430
|
-
return D;
|
|
431
|
-
}
|
|
432
|
-
return e.insert = e.strstart < k - 1 ? e.strstart : k - 1, i === W ? (O(e, !0), e.strm.avail_out === 0 ? te : he) : e.last_lit && (O(e, !1), e.strm.avail_out === 0) ? D : Re;
|
|
433
|
-
}, re = (e, i) => {
|
|
434
|
-
let t, n, a;
|
|
435
|
-
for (; ; ) {
|
|
436
|
-
if (e.lookahead < C) {
|
|
437
|
-
if (ie(e), e.lookahead < C && i === le)
|
|
438
|
-
return D;
|
|
439
|
-
if (e.lookahead === 0)
|
|
440
|
-
break;
|
|
441
|
-
}
|
|
442
|
-
if (t = 0, e.lookahead >= k && (e.ins_h = V(e, e.ins_h, e.window[e.strstart + k - 1]), t = e.prev[e.strstart & e.w_mask] = e.head[e.ins_h], e.head[e.ins_h] = e.strstart), e.prev_length = e.match_length, e.prev_match = e.match_start, e.match_length = k - 1, t !== 0 && e.prev_length < e.max_lazy_match && e.strstart - t <= e.w_size - C && (e.match_length = pi(e, t), e.match_length <= 5 && (e.strategy === xa || e.match_length === k && e.strstart - e.match_start > 4096) && (e.match_length = k - 1)), e.prev_length >= k && e.match_length <= e.prev_length) {
|
|
443
|
-
a = e.strstart + e.lookahead - k, n = j(e, e.strstart - 1 - e.prev_match, e.prev_length - k), e.lookahead -= e.prev_length - 1, e.prev_length -= 2;
|
|
444
|
-
do
|
|
445
|
-
++e.strstart <= a && (e.ins_h = V(e, e.ins_h, e.window[e.strstart + k - 1]), t = e.prev[e.strstart & e.w_mask] = e.head[e.ins_h], e.head[e.ins_h] = e.strstart);
|
|
446
|
-
while (--e.prev_length !== 0);
|
|
447
|
-
if (e.match_available = 0, e.match_length = k - 1, e.strstart++, n && (O(e, !1), e.strm.avail_out === 0))
|
|
448
|
-
return D;
|
|
449
|
-
} else if (e.match_available) {
|
|
450
|
-
if (n = j(e, 0, e.window[e.strstart - 1]), n && O(e, !1), e.strstart++, e.lookahead--, e.strm.avail_out === 0)
|
|
451
|
-
return D;
|
|
452
|
-
} else
|
|
453
|
-
e.match_available = 1, e.strstart++, e.lookahead--;
|
|
454
|
-
}
|
|
455
|
-
return e.match_available && (n = j(e, 0, e.window[e.strstart - 1]), e.match_available = 0), e.insert = e.strstart < k - 1 ? e.strstart : k - 1, i === W ? (O(e, !0), e.strm.avail_out === 0 ? te : he) : e.last_lit && (O(e, !1), e.strm.avail_out === 0) ? D : Re;
|
|
456
|
-
}, $a = (e, i) => {
|
|
457
|
-
let t, n, a, l;
|
|
458
|
-
const o = e.window;
|
|
459
|
-
for (; ; ) {
|
|
460
|
-
if (e.lookahead <= Y) {
|
|
461
|
-
if (ie(e), e.lookahead <= Y && i === le)
|
|
462
|
-
return D;
|
|
463
|
-
if (e.lookahead === 0)
|
|
464
|
-
break;
|
|
465
|
-
}
|
|
466
|
-
if (e.match_length = 0, e.lookahead >= k && e.strstart > 0 && (a = e.strstart - 1, n = o[a], n === o[++a] && n === o[++a] && n === o[++a])) {
|
|
467
|
-
l = e.strstart + Y;
|
|
468
|
-
do
|
|
469
|
-
;
|
|
470
|
-
while (n === o[++a] && n === o[++a] && n === o[++a] && n === o[++a] && n === o[++a] && n === o[++a] && n === o[++a] && n === o[++a] && a < l);
|
|
471
|
-
e.match_length = Y - (l - a), e.match_length > e.lookahead && (e.match_length = e.lookahead);
|
|
472
|
-
}
|
|
473
|
-
if (e.match_length >= k ? (t = j(e, 1, e.match_length - k), e.lookahead -= e.match_length, e.strstart += e.match_length, e.match_length = 0) : (t = j(e, 0, e.window[e.strstart]), e.lookahead--, e.strstart++), t && (O(e, !1), e.strm.avail_out === 0))
|
|
474
|
-
return D;
|
|
475
|
-
}
|
|
476
|
-
return e.insert = 0, i === W ? (O(e, !0), e.strm.avail_out === 0 ? te : he) : e.last_lit && (O(e, !1), e.strm.avail_out === 0) ? D : Re;
|
|
477
|
-
}, Fa = (e, i) => {
|
|
478
|
-
let t;
|
|
479
|
-
for (; ; ) {
|
|
480
|
-
if (e.lookahead === 0 && (ie(e), e.lookahead === 0)) {
|
|
481
|
-
if (i === le)
|
|
482
|
-
return D;
|
|
483
|
-
break;
|
|
484
|
-
}
|
|
485
|
-
if (e.match_length = 0, t = j(e, 0, e.window[e.strstart]), e.lookahead--, e.strstart++, t && (O(e, !1), e.strm.avail_out === 0))
|
|
486
|
-
return D;
|
|
487
|
-
}
|
|
488
|
-
return e.insert = 0, i === W ? (O(e, !0), e.strm.avail_out === 0 ? te : he) : e.last_lit && (O(e, !1), e.strm.avail_out === 0) ? D : Re;
|
|
489
|
-
};
|
|
490
|
-
function $(e, i, t, n, a) {
|
|
491
|
-
this.good_length = e, this.max_lazy = i, this.nice_length = t, this.max_chain = n, this.func = a;
|
|
492
|
-
}
|
|
493
|
-
const ce = [
|
|
494
|
-
/* good lazy nice chain */
|
|
495
|
-
new $(0, 0, 0, 0, Ca),
|
|
496
|
-
/* 0 store only */
|
|
497
|
-
new $(4, 4, 8, 4, Qe),
|
|
498
|
-
/* 1 max speed, no lazy matches */
|
|
499
|
-
new $(4, 5, 16, 8, Qe),
|
|
500
|
-
/* 2 */
|
|
501
|
-
new $(4, 6, 32, 32, Qe),
|
|
502
|
-
/* 3 */
|
|
503
|
-
new $(4, 4, 16, 16, re),
|
|
504
|
-
/* 4 lazy matches */
|
|
505
|
-
new $(8, 16, 32, 32, re),
|
|
506
|
-
/* 5 */
|
|
507
|
-
new $(8, 16, 128, 128, re),
|
|
508
|
-
/* 6 */
|
|
509
|
-
new $(8, 32, 128, 256, re),
|
|
510
|
-
/* 7 */
|
|
511
|
-
new $(32, 128, 258, 1024, re),
|
|
512
|
-
/* 8 */
|
|
513
|
-
new $(32, 258, 258, 4096, re)
|
|
514
|
-
/* 9 max compression */
|
|
515
|
-
], Ma = (e) => {
|
|
516
|
-
e.window_size = 2 * e.w_size, X(e.head), e.max_lazy_match = ce[e.level].max_lazy, e.good_match = ce[e.level].good_length, e.nice_match = ce[e.level].nice_length, e.max_chain_length = ce[e.level].max_chain, e.strstart = 0, e.block_start = 0, e.lookahead = 0, e.insert = 0, e.match_length = e.prev_length = k - 1, e.match_available = 0, e.ins_h = 0;
|
|
517
|
-
};
|
|
518
|
-
function Ha() {
|
|
519
|
-
this.strm = null, this.status = 0, this.pending_buf = null, this.pending_buf_size = 0, this.pending_out = 0, this.pending = 0, this.wrap = 0, this.gzhead = null, this.gzindex = 0, this.method = Pe, this.last_flush = -1, this.w_size = 0, this.w_bits = 0, this.w_mask = 0, this.window = null, this.window_size = 0, this.prev = null, this.head = null, this.ins_h = 0, this.hash_size = 0, this.hash_bits = 0, this.hash_mask = 0, this.hash_shift = 0, this.block_start = 0, this.match_length = 0, this.prev_match = 0, this.match_available = 0, this.strstart = 0, this.match_start = 0, this.lookahead = 0, this.prev_length = 0, this.max_chain_length = 0, this.max_lazy_match = 0, this.level = 0, this.strategy = 0, this.good_match = 0, this.nice_match = 0, this.dyn_ltree = new Uint16Array(Za * 2), this.dyn_dtree = new Uint16Array((2 * ma + 1) * 2), this.bl_tree = new Uint16Array((2 * Da + 1) * 2), X(this.dyn_ltree), X(this.dyn_dtree), X(this.bl_tree), this.l_desc = null, this.d_desc = null, this.bl_desc = null, this.bl_count = new Uint16Array(Ia + 1), this.heap = new Uint16Array(2 * _t + 1), X(this.heap), this.heap_len = 0, this.heap_max = 0, this.depth = new Uint16Array(2 * _t + 1), X(this.depth), this.l_buf = 0, this.lit_bufsize = 0, this.last_lit = 0, this.d_buf = 0, this.opt_len = 0, this.static_len = 0, this.matches = 0, this.insert = 0, this.bi_buf = 0, this.bi_valid = 0;
|
|
520
|
-
}
|
|
521
|
-
const xi = (e) => {
|
|
522
|
-
if (!e || !e.state)
|
|
523
|
-
return G(e, L);
|
|
524
|
-
e.total_in = e.total_out = 0, e.data_type = ya;
|
|
525
|
-
const i = e.state;
|
|
526
|
-
return i.pending = 0, i.pending_out = 0, i.wrap < 0 && (i.wrap = -i.wrap), i.status = i.wrap ? Xe : q, e.adler = i.wrap === 2 ? 0 : 1, i.last_flush = le, da(i), M;
|
|
527
|
-
}, ki = (e) => {
|
|
528
|
-
const i = xi(e);
|
|
529
|
-
return i === M && Ma(e.state), i;
|
|
530
|
-
}, Ba = (e, i) => !e || !e.state || e.state.wrap !== 2 ? L : (e.state.gzhead = i, M), vi = (e, i, t, n, a, l) => {
|
|
531
|
-
if (!e)
|
|
532
|
-
return L;
|
|
533
|
-
let o = 1;
|
|
534
|
-
if (i === pa && (i = 6), n < 0 ? (o = 0, n = -n) : n > 15 && (o = 2, n -= 16), a < 1 || a > Sa || t !== Pe || n < 8 || n > 15 || i < 0 || i > 9 || l < 0 || l > va)
|
|
535
|
-
return G(e, L);
|
|
536
|
-
n === 8 && (n = 9);
|
|
537
|
-
const f = new Ha();
|
|
538
|
-
return e.state = f, f.strm = e, f.wrap = o, f.gzhead = null, f.w_bits = n, f.w_size = 1 << f.w_bits, f.w_mask = f.w_size - 1, f.hash_bits = a + 7, f.hash_size = 1 << f.hash_bits, f.hash_mask = f.hash_size - 1, f.hash_shift = ~~((f.hash_bits + k - 1) / k), f.window = new Uint8Array(f.w_size * 2), f.head = new Uint16Array(f.hash_size), f.prev = new Uint16Array(f.w_size), f.lit_bufsize = 1 << a + 6, f.pending_buf_size = f.lit_bufsize * 4, f.pending_buf = new Uint8Array(f.pending_buf_size), f.d_buf = 1 * f.lit_bufsize, f.l_buf = (1 + 2) * f.lit_bufsize, f.level = i, f.strategy = l, f.method = t, ki(e);
|
|
539
|
-
}, Ka = (e, i) => vi(e, i, Pe, Aa, Ra, Ea), Pa = (e, i) => {
|
|
540
|
-
let t, n;
|
|
541
|
-
if (!e || !e.state || i > St || i < 0)
|
|
542
|
-
return e ? G(e, L) : L;
|
|
543
|
-
const a = e.state;
|
|
544
|
-
if (!e.output || !e.input && e.avail_in !== 0 || a.status === se && i !== W)
|
|
545
|
-
return G(e, e.avail_out === 0 ? Je : L);
|
|
546
|
-
a.strm = e;
|
|
547
|
-
const l = a.last_flush;
|
|
548
|
-
if (a.last_flush = i, a.status === Xe)
|
|
549
|
-
if (a.wrap === 2)
|
|
550
|
-
e.adler = 0, y(a, 31), y(a, 139), y(a, 8), a.gzhead ? (y(
|
|
551
|
-
a,
|
|
552
|
-
(a.gzhead.text ? 1 : 0) + (a.gzhead.hcrc ? 2 : 0) + (a.gzhead.extra ? 4 : 0) + (a.gzhead.name ? 8 : 0) + (a.gzhead.comment ? 16 : 0)
|
|
553
|
-
), y(a, a.gzhead.time & 255), y(a, a.gzhead.time >> 8 & 255), y(a, a.gzhead.time >> 16 & 255), y(a, a.gzhead.time >> 24 & 255), y(a, a.level === 9 ? 2 : a.strategy >= Ie || a.level < 2 ? 4 : 0), y(a, a.gzhead.os & 255), a.gzhead.extra && a.gzhead.extra.length && (y(a, a.gzhead.extra.length & 255), y(a, a.gzhead.extra.length >> 8 & 255)), a.gzhead.hcrc && (e.adler = I(e.adler, a.pending_buf, a.pending, 0)), a.gzindex = 0, a.status = ht) : (y(a, 0), y(a, 0), y(a, 0), y(a, 0), y(a, 0), y(a, a.level === 9 ? 2 : a.strategy >= Ie || a.level < 2 ? 4 : 0), y(a, Na), a.status = q);
|
|
554
|
-
else {
|
|
555
|
-
let o = Pe + (a.w_bits - 8 << 4) << 8, f = -1;
|
|
556
|
-
a.strategy >= Ie || a.level < 2 ? f = 0 : a.level < 6 ? f = 1 : a.level === 6 ? f = 2 : f = 3, o |= f << 6, a.strstart !== 0 && (o |= Oa), o += 31 - o % 31, a.status = q, de(a, o), a.strstart !== 0 && (de(a, e.adler >>> 16), de(a, e.adler & 65535)), e.adler = 1;
|
|
557
|
-
}
|
|
558
|
-
if (a.status === ht)
|
|
559
|
-
if (a.gzhead.extra) {
|
|
560
|
-
for (t = a.pending; a.gzindex < (a.gzhead.extra.length & 65535) && !(a.pending === a.pending_buf_size && (a.gzhead.hcrc && a.pending > t && (e.adler = I(e.adler, a.pending_buf, a.pending - t, t)), P(e), t = a.pending, a.pending === a.pending_buf_size)); )
|
|
561
|
-
y(a, a.gzhead.extra[a.gzindex] & 255), a.gzindex++;
|
|
562
|
-
a.gzhead.hcrc && a.pending > t && (e.adler = I(e.adler, a.pending_buf, a.pending - t, t)), a.gzindex === a.gzhead.extra.length && (a.gzindex = 0, a.status = $e);
|
|
563
|
-
} else
|
|
564
|
-
a.status = $e;
|
|
565
|
-
if (a.status === $e)
|
|
566
|
-
if (a.gzhead.name) {
|
|
567
|
-
t = a.pending;
|
|
568
|
-
do {
|
|
569
|
-
if (a.pending === a.pending_buf_size && (a.gzhead.hcrc && a.pending > t && (e.adler = I(e.adler, a.pending_buf, a.pending - t, t)), P(e), t = a.pending, a.pending === a.pending_buf_size)) {
|
|
570
|
-
n = 1;
|
|
571
|
-
break;
|
|
572
|
-
}
|
|
573
|
-
a.gzindex < a.gzhead.name.length ? n = a.gzhead.name.charCodeAt(a.gzindex++) & 255 : n = 0, y(a, n);
|
|
574
|
-
} while (n !== 0);
|
|
575
|
-
a.gzhead.hcrc && a.pending > t && (e.adler = I(e.adler, a.pending_buf, a.pending - t, t)), n === 0 && (a.gzindex = 0, a.status = Fe);
|
|
576
|
-
} else
|
|
577
|
-
a.status = Fe;
|
|
578
|
-
if (a.status === Fe)
|
|
579
|
-
if (a.gzhead.comment) {
|
|
580
|
-
t = a.pending;
|
|
581
|
-
do {
|
|
582
|
-
if (a.pending === a.pending_buf_size && (a.gzhead.hcrc && a.pending > t && (e.adler = I(e.adler, a.pending_buf, a.pending - t, t)), P(e), t = a.pending, a.pending === a.pending_buf_size)) {
|
|
583
|
-
n = 1;
|
|
584
|
-
break;
|
|
585
|
-
}
|
|
586
|
-
a.gzindex < a.gzhead.comment.length ? n = a.gzhead.comment.charCodeAt(a.gzindex++) & 255 : n = 0, y(a, n);
|
|
587
|
-
} while (n !== 0);
|
|
588
|
-
a.gzhead.hcrc && a.pending > t && (e.adler = I(e.adler, a.pending_buf, a.pending - t, t)), n === 0 && (a.status = Me);
|
|
589
|
-
} else
|
|
590
|
-
a.status = Me;
|
|
591
|
-
if (a.status === Me && (a.gzhead.hcrc ? (a.pending + 2 > a.pending_buf_size && P(e), a.pending + 2 <= a.pending_buf_size && (y(a, e.adler & 255), y(a, e.adler >> 8 & 255), e.adler = 0, a.status = q)) : a.status = q), a.pending !== 0) {
|
|
592
|
-
if (P(e), e.avail_out === 0)
|
|
593
|
-
return a.last_flush = -1, M;
|
|
594
|
-
} else if (e.avail_in === 0 && Rt(i) <= Rt(l) && i !== W)
|
|
595
|
-
return G(e, Je);
|
|
596
|
-
if (a.status === se && e.avail_in !== 0)
|
|
597
|
-
return G(e, Je);
|
|
598
|
-
if (e.avail_in !== 0 || a.lookahead !== 0 || i !== le && a.status !== se) {
|
|
599
|
-
let o = a.strategy === Ie ? Fa(a, i) : a.strategy === ka ? $a(a, i) : ce[a.level].func(a, i);
|
|
600
|
-
if ((o === te || o === he) && (a.status = se), o === D || o === te)
|
|
601
|
-
return e.avail_out === 0 && (a.last_flush = -1), M;
|
|
602
|
-
if (o === Re && (i === ba ? ua(a) : i !== St && (sa(a, 0, 0, !1), i === wa && (X(a.head), a.lookahead === 0 && (a.strstart = 0, a.block_start = 0, a.insert = 0))), P(e), e.avail_out === 0))
|
|
603
|
-
return a.last_flush = -1, M;
|
|
604
|
-
}
|
|
605
|
-
return i !== W ? M : a.wrap <= 0 ? At : (a.wrap === 2 ? (y(a, e.adler & 255), y(a, e.adler >> 8 & 255), y(a, e.adler >> 16 & 255), y(a, e.adler >> 24 & 255), y(a, e.total_in & 255), y(a, e.total_in >> 8 & 255), y(a, e.total_in >> 16 & 255), y(a, e.total_in >> 24 & 255)) : (de(a, e.adler >>> 16), de(a, e.adler & 65535)), P(e), a.wrap > 0 && (a.wrap = -a.wrap), a.pending !== 0 ? M : At);
|
|
606
|
-
}, Xa = (e) => {
|
|
607
|
-
if (!e || !e.state)
|
|
608
|
-
return L;
|
|
609
|
-
const i = e.state.status;
|
|
610
|
-
return i !== Xe && i !== ht && i !== $e && i !== Fe && i !== Me && i !== q && i !== se ? G(e, L) : (e.state = null, i === q ? G(e, ga) : M);
|
|
611
|
-
}, Ya = (e, i) => {
|
|
612
|
-
let t = i.length;
|
|
613
|
-
if (!e || !e.state)
|
|
614
|
-
return L;
|
|
615
|
-
const n = e.state, a = n.wrap;
|
|
616
|
-
if (a === 2 || a === 1 && n.status !== Xe || n.lookahead)
|
|
617
|
-
return L;
|
|
618
|
-
if (a === 1 && (e.adler = ve(e.adler, i, t, 0)), n.wrap = 0, t >= n.w_size) {
|
|
619
|
-
a === 0 && (X(n.head), n.strstart = 0, n.block_start = 0, n.insert = 0);
|
|
620
|
-
let c = new Uint8Array(n.w_size);
|
|
621
|
-
c.set(i.subarray(t - n.w_size, t), 0), i = c, t = n.w_size;
|
|
622
|
-
}
|
|
623
|
-
const l = e.avail_in, o = e.next_in, f = e.input;
|
|
624
|
-
for (e.avail_in = t, e.next_in = 0, e.input = i, ie(n); n.lookahead >= k; ) {
|
|
625
|
-
let c = n.strstart, r = n.lookahead - (k - 1);
|
|
626
|
-
do
|
|
627
|
-
n.ins_h = V(n, n.ins_h, n.window[c + k - 1]), n.prev[c & n.w_mask] = n.head[n.ins_h], n.head[n.ins_h] = c, c++;
|
|
628
|
-
while (--r);
|
|
629
|
-
n.strstart = c, n.lookahead = k - 1, ie(n);
|
|
630
|
-
}
|
|
631
|
-
return n.strstart += n.lookahead, n.block_start = n.strstart, n.insert = n.lookahead, n.lookahead = 0, n.match_length = n.prev_length = k - 1, n.match_available = 0, e.next_in = o, e.input = f, e.avail_in = l, n.wrap = a, M;
|
|
632
|
-
};
|
|
633
|
-
var Ga = Ka, ja = vi, Wa = ki, Va = xi, Ja = Ba, Qa = Pa, qa = Xa, en = Ya, tn = "pako deflate (from Nodeca project)", be = {
|
|
634
|
-
deflateInit: Ga,
|
|
635
|
-
deflateInit2: ja,
|
|
636
|
-
deflateReset: Wa,
|
|
637
|
-
deflateResetKeep: Va,
|
|
638
|
-
deflateSetHeader: Ja,
|
|
639
|
-
deflate: Qa,
|
|
640
|
-
deflateEnd: qa,
|
|
641
|
-
deflateSetDictionary: en,
|
|
642
|
-
deflateInfo: tn
|
|
643
|
-
};
|
|
644
|
-
const an = (e, i) => Object.prototype.hasOwnProperty.call(e, i);
|
|
645
|
-
var nn = function(e) {
|
|
646
|
-
const i = Array.prototype.slice.call(arguments, 1);
|
|
647
|
-
for (; i.length; ) {
|
|
648
|
-
const t = i.shift();
|
|
649
|
-
if (t) {
|
|
650
|
-
if (typeof t != "object")
|
|
651
|
-
throw new TypeError(t + "must be non-object");
|
|
652
|
-
for (const n in t)
|
|
653
|
-
an(t, n) && (e[n] = t[n]);
|
|
654
|
-
}
|
|
655
|
-
}
|
|
656
|
-
return e;
|
|
657
|
-
}, ln = (e) => {
|
|
658
|
-
let i = 0;
|
|
659
|
-
for (let n = 0, a = e.length; n < a; n++)
|
|
660
|
-
i += e[n].length;
|
|
661
|
-
const t = new Uint8Array(i);
|
|
662
|
-
for (let n = 0, a = 0, l = e.length; n < l; n++) {
|
|
663
|
-
let o = e[n];
|
|
664
|
-
t.set(o, a), a += o.length;
|
|
665
|
-
}
|
|
666
|
-
return t;
|
|
667
|
-
}, Ye = {
|
|
668
|
-
assign: nn,
|
|
669
|
-
flattenChunks: ln
|
|
670
|
-
};
|
|
671
|
-
let Ei = !0;
|
|
672
|
-
try {
|
|
673
|
-
String.fromCharCode.apply(null, new Uint8Array(1));
|
|
674
|
-
} catch {
|
|
675
|
-
Ei = !1;
|
|
676
|
-
}
|
|
677
|
-
const Ee = new Uint8Array(256);
|
|
678
|
-
for (let e = 0; e < 256; e++)
|
|
679
|
-
Ee[e] = e >= 252 ? 6 : e >= 248 ? 5 : e >= 240 ? 4 : e >= 224 ? 3 : e >= 192 ? 2 : 1;
|
|
680
|
-
Ee[254] = Ee[254] = 1;
|
|
681
|
-
var rn = (e) => {
|
|
682
|
-
let i, t, n, a, l, o = e.length, f = 0;
|
|
683
|
-
for (a = 0; a < o; a++)
|
|
684
|
-
t = e.charCodeAt(a), (t & 64512) === 55296 && a + 1 < o && (n = e.charCodeAt(a + 1), (n & 64512) === 56320 && (t = 65536 + (t - 55296 << 10) + (n - 56320), a++)), f += t < 128 ? 1 : t < 2048 ? 2 : t < 65536 ? 3 : 4;
|
|
685
|
-
for (i = new Uint8Array(f), l = 0, a = 0; l < f; a++)
|
|
686
|
-
t = e.charCodeAt(a), (t & 64512) === 55296 && a + 1 < o && (n = e.charCodeAt(a + 1), (n & 64512) === 56320 && (t = 65536 + (t - 55296 << 10) + (n - 56320), a++)), t < 128 ? i[l++] = t : t < 2048 ? (i[l++] = 192 | t >>> 6, i[l++] = 128 | t & 63) : t < 65536 ? (i[l++] = 224 | t >>> 12, i[l++] = 128 | t >>> 6 & 63, i[l++] = 128 | t & 63) : (i[l++] = 240 | t >>> 18, i[l++] = 128 | t >>> 12 & 63, i[l++] = 128 | t >>> 6 & 63, i[l++] = 128 | t & 63);
|
|
687
|
-
return i;
|
|
688
|
-
};
|
|
689
|
-
const fn = (e, i) => {
|
|
690
|
-
if (i < 65534 && e.subarray && Ei)
|
|
691
|
-
return String.fromCharCode.apply(null, e.length === i ? e : e.subarray(0, i));
|
|
692
|
-
let t = "";
|
|
693
|
-
for (let n = 0; n < i; n++)
|
|
694
|
-
t += String.fromCharCode(e[n]);
|
|
695
|
-
return t;
|
|
696
|
-
};
|
|
697
|
-
var on = (e, i) => {
|
|
698
|
-
let t, n;
|
|
699
|
-
const a = i || e.length, l = new Array(a * 2);
|
|
700
|
-
for (n = 0, t = 0; t < a; ) {
|
|
701
|
-
let o = e[t++];
|
|
702
|
-
if (o < 128) {
|
|
703
|
-
l[n++] = o;
|
|
704
|
-
continue;
|
|
705
|
-
}
|
|
706
|
-
let f = Ee[o];
|
|
707
|
-
if (f > 4) {
|
|
708
|
-
l[n++] = 65533, t += f - 1;
|
|
709
|
-
continue;
|
|
710
|
-
}
|
|
711
|
-
for (o &= f === 2 ? 31 : f === 3 ? 15 : 7; f > 1 && t < a; )
|
|
712
|
-
o = o << 6 | e[t++] & 63, f--;
|
|
713
|
-
if (f > 1) {
|
|
714
|
-
l[n++] = 65533;
|
|
715
|
-
continue;
|
|
716
|
-
}
|
|
717
|
-
o < 65536 ? l[n++] = o : (o -= 65536, l[n++] = 55296 | o >> 10 & 1023, l[n++] = 56320 | o & 1023);
|
|
718
|
-
}
|
|
719
|
-
return fn(l, n);
|
|
720
|
-
}, _n = (e, i) => {
|
|
721
|
-
i = i || e.length, i > e.length && (i = e.length);
|
|
722
|
-
let t = i - 1;
|
|
723
|
-
for (; t >= 0 && (e[t] & 192) === 128; )
|
|
724
|
-
t--;
|
|
725
|
-
return t < 0 || t === 0 ? i : t + Ee[e[t]] > i ? t : i;
|
|
726
|
-
}, ye = {
|
|
727
|
-
string2buf: rn,
|
|
728
|
-
buf2string: on,
|
|
729
|
-
utf8border: _n
|
|
730
|
-
};
|
|
731
|
-
function hn() {
|
|
732
|
-
this.input = null, this.next_in = 0, this.avail_in = 0, this.total_in = 0, this.output = null, this.next_out = 0, this.avail_out = 0, this.total_out = 0, this.msg = "", this.state = null, this.data_type = 2, this.adler = 0;
|
|
733
|
-
}
|
|
734
|
-
var yi = hn;
|
|
735
|
-
const Si = Object.prototype.toString, {
|
|
736
|
-
Z_NO_FLUSH: dn,
|
|
737
|
-
Z_SYNC_FLUSH: sn,
|
|
738
|
-
Z_FULL_FLUSH: cn,
|
|
739
|
-
Z_FINISH: un,
|
|
740
|
-
Z_OK: Be,
|
|
741
|
-
Z_STREAM_END: bn,
|
|
742
|
-
Z_DEFAULT_COMPRESSION: wn,
|
|
743
|
-
Z_DEFAULT_STRATEGY: gn,
|
|
744
|
-
Z_DEFLATED: pn
|
|
745
|
-
} = ne;
|
|
746
|
-
function ze(e) {
|
|
747
|
-
this.options = Ye.assign({
|
|
748
|
-
level: wn,
|
|
749
|
-
method: pn,
|
|
750
|
-
chunkSize: 16384,
|
|
751
|
-
windowBits: 15,
|
|
752
|
-
memLevel: 8,
|
|
753
|
-
strategy: gn
|
|
754
|
-
}, e || {});
|
|
755
|
-
let i = this.options;
|
|
756
|
-
i.raw && i.windowBits > 0 ? i.windowBits = -i.windowBits : i.gzip && i.windowBits > 0 && i.windowBits < 16 && (i.windowBits += 16), this.err = 0, this.msg = "", this.ended = !1, this.chunks = [], this.strm = new yi(), this.strm.avail_out = 0;
|
|
757
|
-
let t = be.deflateInit2(
|
|
758
|
-
this.strm,
|
|
759
|
-
i.level,
|
|
760
|
-
i.method,
|
|
761
|
-
i.windowBits,
|
|
762
|
-
i.memLevel,
|
|
763
|
-
i.strategy
|
|
764
|
-
);
|
|
765
|
-
if (t !== Be)
|
|
766
|
-
throw new Error(ee[t]);
|
|
767
|
-
if (i.header && be.deflateSetHeader(this.strm, i.header), i.dictionary) {
|
|
768
|
-
let n;
|
|
769
|
-
if (typeof i.dictionary == "string" ? n = ye.string2buf(i.dictionary) : Si.call(i.dictionary) === "[object ArrayBuffer]" ? n = new Uint8Array(i.dictionary) : n = i.dictionary, t = be.deflateSetDictionary(this.strm, n), t !== Be)
|
|
770
|
-
throw new Error(ee[t]);
|
|
771
|
-
this._dict_set = !0;
|
|
772
|
-
}
|
|
773
|
-
}
|
|
774
|
-
ze.prototype.push = function(e, i) {
|
|
775
|
-
const t = this.strm, n = this.options.chunkSize;
|
|
776
|
-
let a, l;
|
|
777
|
-
if (this.ended)
|
|
778
|
-
return !1;
|
|
779
|
-
for (i === ~~i ? l = i : l = i === !0 ? un : dn, typeof e == "string" ? t.input = ye.string2buf(e) : Si.call(e) === "[object ArrayBuffer]" ? t.input = new Uint8Array(e) : t.input = e, t.next_in = 0, t.avail_in = t.input.length; ; ) {
|
|
780
|
-
if (t.avail_out === 0 && (t.output = new Uint8Array(n), t.next_out = 0, t.avail_out = n), (l === sn || l === cn) && t.avail_out <= 6) {
|
|
781
|
-
this.onData(t.output.subarray(0, t.next_out)), t.avail_out = 0;
|
|
782
|
-
continue;
|
|
783
|
-
}
|
|
784
|
-
if (a = be.deflate(t, l), a === bn)
|
|
785
|
-
return t.next_out > 0 && this.onData(t.output.subarray(0, t.next_out)), a = be.deflateEnd(this.strm), this.onEnd(a), this.ended = !0, a === Be;
|
|
786
|
-
if (t.avail_out === 0) {
|
|
787
|
-
this.onData(t.output);
|
|
788
|
-
continue;
|
|
789
|
-
}
|
|
790
|
-
if (l > 0 && t.next_out > 0) {
|
|
791
|
-
this.onData(t.output.subarray(0, t.next_out)), t.avail_out = 0;
|
|
792
|
-
continue;
|
|
793
|
-
}
|
|
794
|
-
if (t.avail_in === 0)
|
|
795
|
-
break;
|
|
796
|
-
}
|
|
797
|
-
return !0;
|
|
798
|
-
};
|
|
799
|
-
ze.prototype.onData = function(e) {
|
|
800
|
-
this.chunks.push(e);
|
|
801
|
-
};
|
|
802
|
-
ze.prototype.onEnd = function(e) {
|
|
803
|
-
e === Be && (this.result = Ye.flattenChunks(this.chunks)), this.chunks = [], this.err = e, this.msg = this.strm.msg;
|
|
804
|
-
};
|
|
805
|
-
function bt(e, i) {
|
|
806
|
-
const t = new ze(i);
|
|
807
|
-
if (t.push(e, !0), t.err)
|
|
808
|
-
throw t.msg || ee[t.err];
|
|
809
|
-
return t.result;
|
|
810
|
-
}
|
|
811
|
-
function xn(e, i) {
|
|
812
|
-
return i = i || {}, i.raw = !0, bt(e, i);
|
|
813
|
-
}
|
|
814
|
-
function kn(e, i) {
|
|
815
|
-
return i = i || {}, i.gzip = !0, bt(e, i);
|
|
816
|
-
}
|
|
817
|
-
var vn = ze, En = bt, yn = xn, Sn = kn, An = ne, Rn = {
|
|
818
|
-
Deflate: vn,
|
|
819
|
-
deflate: En,
|
|
820
|
-
deflateRaw: yn,
|
|
821
|
-
gzip: Sn,
|
|
822
|
-
constants: An
|
|
823
|
-
};
|
|
824
|
-
const Oe = 30, zn = 12;
|
|
825
|
-
var Tn = function(i, t) {
|
|
826
|
-
let n, a, l, o, f, c, r, _, E, s, h, u, m, v, w, A, x, d, S, Z, b, z, R, g;
|
|
827
|
-
const p = i.state;
|
|
828
|
-
n = i.next_in, R = i.input, a = n + (i.avail_in - 5), l = i.next_out, g = i.output, o = l - (t - i.avail_out), f = l + (i.avail_out - 257), c = p.dmax, r = p.wsize, _ = p.whave, E = p.wnext, s = p.window, h = p.hold, u = p.bits, m = p.lencode, v = p.distcode, w = (1 << p.lenbits) - 1, A = (1 << p.distbits) - 1;
|
|
829
|
-
e:
|
|
830
|
-
do {
|
|
831
|
-
u < 15 && (h += R[n++] << u, u += 8, h += R[n++] << u, u += 8), x = m[h & w];
|
|
832
|
-
t:
|
|
833
|
-
for (; ; ) {
|
|
834
|
-
if (d = x >>> 24, h >>>= d, u -= d, d = x >>> 16 & 255, d === 0)
|
|
835
|
-
g[l++] = x & 65535;
|
|
836
|
-
else if (d & 16) {
|
|
837
|
-
S = x & 65535, d &= 15, d && (u < d && (h += R[n++] << u, u += 8), S += h & (1 << d) - 1, h >>>= d, u -= d), u < 15 && (h += R[n++] << u, u += 8, h += R[n++] << u, u += 8), x = v[h & A];
|
|
838
|
-
i:
|
|
839
|
-
for (; ; ) {
|
|
840
|
-
if (d = x >>> 24, h >>>= d, u -= d, d = x >>> 16 & 255, d & 16) {
|
|
841
|
-
if (Z = x & 65535, d &= 15, u < d && (h += R[n++] << u, u += 8, u < d && (h += R[n++] << u, u += 8)), Z += h & (1 << d) - 1, Z > c) {
|
|
842
|
-
i.msg = "invalid distance too far back", p.mode = Oe;
|
|
843
|
-
break e;
|
|
844
|
-
}
|
|
845
|
-
if (h >>>= d, u -= d, d = l - o, Z > d) {
|
|
846
|
-
if (d = Z - d, d > _ && p.sane) {
|
|
847
|
-
i.msg = "invalid distance too far back", p.mode = Oe;
|
|
848
|
-
break e;
|
|
849
|
-
}
|
|
850
|
-
if (b = 0, z = s, E === 0) {
|
|
851
|
-
if (b += r - d, d < S) {
|
|
852
|
-
S -= d;
|
|
853
|
-
do
|
|
854
|
-
g[l++] = s[b++];
|
|
855
|
-
while (--d);
|
|
856
|
-
b = l - Z, z = g;
|
|
857
|
-
}
|
|
858
|
-
} else if (E < d) {
|
|
859
|
-
if (b += r + E - d, d -= E, d < S) {
|
|
860
|
-
S -= d;
|
|
861
|
-
do
|
|
862
|
-
g[l++] = s[b++];
|
|
863
|
-
while (--d);
|
|
864
|
-
if (b = 0, E < S) {
|
|
865
|
-
d = E, S -= d;
|
|
866
|
-
do
|
|
867
|
-
g[l++] = s[b++];
|
|
868
|
-
while (--d);
|
|
869
|
-
b = l - Z, z = g;
|
|
870
|
-
}
|
|
871
|
-
}
|
|
872
|
-
} else if (b += E - d, d < S) {
|
|
873
|
-
S -= d;
|
|
874
|
-
do
|
|
875
|
-
g[l++] = s[b++];
|
|
876
|
-
while (--d);
|
|
877
|
-
b = l - Z, z = g;
|
|
878
|
-
}
|
|
879
|
-
for (; S > 2; )
|
|
880
|
-
g[l++] = z[b++], g[l++] = z[b++], g[l++] = z[b++], S -= 3;
|
|
881
|
-
S && (g[l++] = z[b++], S > 1 && (g[l++] = z[b++]));
|
|
882
|
-
} else {
|
|
883
|
-
b = l - Z;
|
|
884
|
-
do
|
|
885
|
-
g[l++] = g[b++], g[l++] = g[b++], g[l++] = g[b++], S -= 3;
|
|
886
|
-
while (S > 2);
|
|
887
|
-
S && (g[l++] = g[b++], S > 1 && (g[l++] = g[b++]));
|
|
888
|
-
}
|
|
889
|
-
} else if (d & 64) {
|
|
890
|
-
i.msg = "invalid distance code", p.mode = Oe;
|
|
891
|
-
break e;
|
|
892
|
-
} else {
|
|
893
|
-
x = v[(x & 65535) + (h & (1 << d) - 1)];
|
|
894
|
-
continue i;
|
|
895
|
-
}
|
|
896
|
-
break;
|
|
897
|
-
}
|
|
898
|
-
} else if (d & 64)
|
|
899
|
-
if (d & 32) {
|
|
900
|
-
p.mode = zn;
|
|
901
|
-
break e;
|
|
902
|
-
} else {
|
|
903
|
-
i.msg = "invalid literal/length code", p.mode = Oe;
|
|
904
|
-
break e;
|
|
905
|
-
}
|
|
906
|
-
else {
|
|
907
|
-
x = m[(x & 65535) + (h & (1 << d) - 1)];
|
|
908
|
-
continue t;
|
|
909
|
-
}
|
|
910
|
-
break;
|
|
911
|
-
}
|
|
912
|
-
} while (n < a && l < f);
|
|
913
|
-
S = u >> 3, n -= S, u -= S << 3, h &= (1 << u) - 1, i.next_in = n, i.next_out = l, i.avail_in = n < a ? 5 + (a - n) : 5 - (n - a), i.avail_out = l < f ? 257 + (f - l) : 257 - (l - f), p.hold = h, p.bits = u;
|
|
914
|
-
};
|
|
915
|
-
const fe = 15, zt = 852, Tt = 592, mt = 0, qe = 1, Dt = 2, mn = new Uint16Array([
|
|
916
|
-
/* Length codes 257..285 base */
|
|
917
|
-
3,
|
|
918
|
-
4,
|
|
919
|
-
5,
|
|
920
|
-
6,
|
|
921
|
-
7,
|
|
922
|
-
8,
|
|
923
|
-
9,
|
|
924
|
-
10,
|
|
925
|
-
11,
|
|
926
|
-
13,
|
|
927
|
-
15,
|
|
928
|
-
17,
|
|
929
|
-
19,
|
|
930
|
-
23,
|
|
931
|
-
27,
|
|
932
|
-
31,
|
|
933
|
-
35,
|
|
934
|
-
43,
|
|
935
|
-
51,
|
|
936
|
-
59,
|
|
937
|
-
67,
|
|
938
|
-
83,
|
|
939
|
-
99,
|
|
940
|
-
115,
|
|
941
|
-
131,
|
|
942
|
-
163,
|
|
943
|
-
195,
|
|
944
|
-
227,
|
|
945
|
-
258,
|
|
946
|
-
0,
|
|
947
|
-
0
|
|
948
|
-
]), Dn = new Uint8Array([
|
|
949
|
-
/* Length codes 257..285 extra */
|
|
950
|
-
16,
|
|
951
|
-
16,
|
|
952
|
-
16,
|
|
953
|
-
16,
|
|
954
|
-
16,
|
|
955
|
-
16,
|
|
956
|
-
16,
|
|
957
|
-
16,
|
|
958
|
-
17,
|
|
959
|
-
17,
|
|
960
|
-
17,
|
|
961
|
-
17,
|
|
962
|
-
18,
|
|
963
|
-
18,
|
|
964
|
-
18,
|
|
965
|
-
18,
|
|
966
|
-
19,
|
|
967
|
-
19,
|
|
968
|
-
19,
|
|
969
|
-
19,
|
|
970
|
-
20,
|
|
971
|
-
20,
|
|
972
|
-
20,
|
|
973
|
-
20,
|
|
974
|
-
21,
|
|
975
|
-
21,
|
|
976
|
-
21,
|
|
977
|
-
21,
|
|
978
|
-
16,
|
|
979
|
-
72,
|
|
980
|
-
78
|
|
981
|
-
]), Zn = new Uint16Array([
|
|
982
|
-
/* Distance codes 0..29 base */
|
|
983
|
-
1,
|
|
984
|
-
2,
|
|
985
|
-
3,
|
|
986
|
-
4,
|
|
987
|
-
5,
|
|
988
|
-
7,
|
|
989
|
-
9,
|
|
990
|
-
13,
|
|
991
|
-
17,
|
|
992
|
-
25,
|
|
993
|
-
33,
|
|
994
|
-
49,
|
|
995
|
-
65,
|
|
996
|
-
97,
|
|
997
|
-
129,
|
|
998
|
-
193,
|
|
999
|
-
257,
|
|
1000
|
-
385,
|
|
1001
|
-
513,
|
|
1002
|
-
769,
|
|
1003
|
-
1025,
|
|
1004
|
-
1537,
|
|
1005
|
-
2049,
|
|
1006
|
-
3073,
|
|
1007
|
-
4097,
|
|
1008
|
-
6145,
|
|
1009
|
-
8193,
|
|
1010
|
-
12289,
|
|
1011
|
-
16385,
|
|
1012
|
-
24577,
|
|
1013
|
-
0,
|
|
1014
|
-
0
|
|
1015
|
-
]), In = new Uint8Array([
|
|
1016
|
-
/* Distance codes 0..29 extra */
|
|
1017
|
-
16,
|
|
1018
|
-
16,
|
|
1019
|
-
16,
|
|
1020
|
-
16,
|
|
1021
|
-
17,
|
|
1022
|
-
17,
|
|
1023
|
-
18,
|
|
1024
|
-
18,
|
|
1025
|
-
19,
|
|
1026
|
-
19,
|
|
1027
|
-
20,
|
|
1028
|
-
20,
|
|
1029
|
-
21,
|
|
1030
|
-
21,
|
|
1031
|
-
22,
|
|
1032
|
-
22,
|
|
1033
|
-
23,
|
|
1034
|
-
23,
|
|
1035
|
-
24,
|
|
1036
|
-
24,
|
|
1037
|
-
25,
|
|
1038
|
-
25,
|
|
1039
|
-
26,
|
|
1040
|
-
26,
|
|
1041
|
-
27,
|
|
1042
|
-
27,
|
|
1043
|
-
28,
|
|
1044
|
-
28,
|
|
1045
|
-
29,
|
|
1046
|
-
29,
|
|
1047
|
-
64,
|
|
1048
|
-
64
|
|
1049
|
-
]), On = (e, i, t, n, a, l, o, f) => {
|
|
1050
|
-
const c = f.bits;
|
|
1051
|
-
let r = 0, _ = 0, E = 0, s = 0, h = 0, u = 0, m = 0, v = 0, w = 0, A = 0, x, d, S, Z, b, z = null, R = 0, g;
|
|
1052
|
-
const p = new Uint16Array(fe + 1), J = new Uint16Array(fe + 1);
|
|
1053
|
-
let me = null, gt = 0, pt, De, Ze;
|
|
1054
|
-
for (r = 0; r <= fe; r++)
|
|
1055
|
-
p[r] = 0;
|
|
1056
|
-
for (_ = 0; _ < n; _++)
|
|
1057
|
-
p[i[t + _]]++;
|
|
1058
|
-
for (h = c, s = fe; s >= 1 && p[s] === 0; s--)
|
|
1059
|
-
;
|
|
1060
|
-
if (h > s && (h = s), s === 0)
|
|
1061
|
-
return a[l++] = 1 << 24 | 64 << 16 | 0, a[l++] = 1 << 24 | 64 << 16 | 0, f.bits = 1, 0;
|
|
1062
|
-
for (E = 1; E < s && p[E] === 0; E++)
|
|
1063
|
-
;
|
|
1064
|
-
for (h < E && (h = E), v = 1, r = 1; r <= fe; r++)
|
|
1065
|
-
if (v <<= 1, v -= p[r], v < 0)
|
|
1066
|
-
return -1;
|
|
1067
|
-
if (v > 0 && (e === mt || s !== 1))
|
|
1068
|
-
return -1;
|
|
1069
|
-
for (J[1] = 0, r = 1; r < fe; r++)
|
|
1070
|
-
J[r + 1] = J[r] + p[r];
|
|
1071
|
-
for (_ = 0; _ < n; _++)
|
|
1072
|
-
i[t + _] !== 0 && (o[J[i[t + _]]++] = _);
|
|
1073
|
-
if (e === mt ? (z = me = o, g = 19) : e === qe ? (z = mn, R -= 257, me = Dn, gt -= 257, g = 256) : (z = Zn, me = In, g = -1), A = 0, _ = 0, r = E, b = l, u = h, m = 0, S = -1, w = 1 << h, Z = w - 1, e === qe && w > zt || e === Dt && w > Tt)
|
|
1074
|
-
return 1;
|
|
1075
|
-
for (; ; ) {
|
|
1076
|
-
pt = r - m, o[_] < g ? (De = 0, Ze = o[_]) : o[_] > g ? (De = me[gt + o[_]], Ze = z[R + o[_]]) : (De = 32 + 64, Ze = 0), x = 1 << r - m, d = 1 << u, E = d;
|
|
1077
|
-
do
|
|
1078
|
-
d -= x, a[b + (A >> m) + d] = pt << 24 | De << 16 | Ze | 0;
|
|
1079
|
-
while (d !== 0);
|
|
1080
|
-
for (x = 1 << r - 1; A & x; )
|
|
1081
|
-
x >>= 1;
|
|
1082
|
-
if (x !== 0 ? (A &= x - 1, A += x) : A = 0, _++, --p[r] === 0) {
|
|
1083
|
-
if (r === s)
|
|
1084
|
-
break;
|
|
1085
|
-
r = i[t + o[_]];
|
|
1086
|
-
}
|
|
1087
|
-
if (r > h && (A & Z) !== S) {
|
|
1088
|
-
for (m === 0 && (m = h), b += E, u = r - m, v = 1 << u; u + m < s && (v -= p[u + m], !(v <= 0)); )
|
|
1089
|
-
u++, v <<= 1;
|
|
1090
|
-
if (w += 1 << u, e === qe && w > zt || e === Dt && w > Tt)
|
|
1091
|
-
return 1;
|
|
1092
|
-
S = A & Z, a[S] = h << 24 | u << 16 | b - l | 0;
|
|
1093
|
-
}
|
|
1094
|
-
}
|
|
1095
|
-
return A !== 0 && (a[b + A] = r - m << 24 | 64 << 16 | 0), f.bits = h, 0;
|
|
1096
|
-
};
|
|
1097
|
-
var we = On;
|
|
1098
|
-
const Nn = 0, Ai = 1, Ri = 2, {
|
|
1099
|
-
Z_FINISH: Zt,
|
|
1100
|
-
Z_BLOCK: Ln,
|
|
1101
|
-
Z_TREES: Ne,
|
|
1102
|
-
Z_OK: ae,
|
|
1103
|
-
Z_STREAM_END: Un,
|
|
1104
|
-
Z_NEED_DICT: Cn,
|
|
1105
|
-
Z_STREAM_ERROR: U,
|
|
1106
|
-
Z_DATA_ERROR: zi,
|
|
1107
|
-
Z_MEM_ERROR: Ti,
|
|
1108
|
-
Z_BUF_ERROR: $n,
|
|
1109
|
-
Z_DEFLATED: It
|
|
1110
|
-
} = ne, mi = 1, Ot = 2, Nt = 3, Lt = 4, Ut = 5, Ct = 6, $t = 7, Ft = 8, Mt = 9, Ht = 10, Ke = 11, H = 12, et = 13, Bt = 14, tt = 15, Kt = 16, Pt = 17, Xt = 18, Yt = 19, Le = 20, Ue = 21, Gt = 22, jt = 23, Wt = 24, Vt = 25, Jt = 26, it = 27, Qt = 28, qt = 29, T = 30, Di = 31, Fn = 32, Mn = 852, Hn = 592, Bn = 15, Kn = Bn, ei = (e) => (e >>> 24 & 255) + (e >>> 8 & 65280) + ((e & 65280) << 8) + ((e & 255) << 24);
|
|
1111
|
-
function Pn() {
|
|
1112
|
-
this.mode = 0, this.last = !1, this.wrap = 0, this.havedict = !1, this.flags = 0, this.dmax = 0, this.check = 0, this.total = 0, this.head = null, this.wbits = 0, this.wsize = 0, this.whave = 0, this.wnext = 0, this.window = null, this.hold = 0, this.bits = 0, this.length = 0, this.offset = 0, this.extra = 0, this.lencode = null, this.distcode = null, this.lenbits = 0, this.distbits = 0, this.ncode = 0, this.nlen = 0, this.ndist = 0, this.have = 0, this.next = null, this.lens = new Uint16Array(320), this.work = new Uint16Array(288), this.lendyn = null, this.distdyn = null, this.sane = 0, this.back = 0, this.was = 0;
|
|
1113
|
-
}
|
|
1114
|
-
const Zi = (e) => {
|
|
1115
|
-
if (!e || !e.state)
|
|
1116
|
-
return U;
|
|
1117
|
-
const i = e.state;
|
|
1118
|
-
return e.total_in = e.total_out = i.total = 0, e.msg = "", i.wrap && (e.adler = i.wrap & 1), i.mode = mi, i.last = 0, i.havedict = 0, i.dmax = 32768, i.head = null, i.hold = 0, i.bits = 0, i.lencode = i.lendyn = new Int32Array(Mn), i.distcode = i.distdyn = new Int32Array(Hn), i.sane = 1, i.back = -1, ae;
|
|
1119
|
-
}, Ii = (e) => {
|
|
1120
|
-
if (!e || !e.state)
|
|
1121
|
-
return U;
|
|
1122
|
-
const i = e.state;
|
|
1123
|
-
return i.wsize = 0, i.whave = 0, i.wnext = 0, Zi(e);
|
|
1124
|
-
}, Oi = (e, i) => {
|
|
1125
|
-
let t;
|
|
1126
|
-
if (!e || !e.state)
|
|
1127
|
-
return U;
|
|
1128
|
-
const n = e.state;
|
|
1129
|
-
return i < 0 ? (t = 0, i = -i) : (t = (i >> 4) + 1, i < 48 && (i &= 15)), i && (i < 8 || i > 15) ? U : (n.window !== null && n.wbits !== i && (n.window = null), n.wrap = t, n.wbits = i, Ii(e));
|
|
1130
|
-
}, Ni = (e, i) => {
|
|
1131
|
-
if (!e)
|
|
1132
|
-
return U;
|
|
1133
|
-
const t = new Pn();
|
|
1134
|
-
e.state = t, t.window = null;
|
|
1135
|
-
const n = Oi(e, i);
|
|
1136
|
-
return n !== ae && (e.state = null), n;
|
|
1137
|
-
}, Xn = (e) => Ni(e, Kn);
|
|
1138
|
-
let ti = !0, at, nt;
|
|
1139
|
-
const Yn = (e) => {
|
|
1140
|
-
if (ti) {
|
|
1141
|
-
at = new Int32Array(512), nt = new Int32Array(32);
|
|
1142
|
-
let i = 0;
|
|
1143
|
-
for (; i < 144; )
|
|
1144
|
-
e.lens[i++] = 8;
|
|
1145
|
-
for (; i < 256; )
|
|
1146
|
-
e.lens[i++] = 9;
|
|
1147
|
-
for (; i < 280; )
|
|
1148
|
-
e.lens[i++] = 7;
|
|
1149
|
-
for (; i < 288; )
|
|
1150
|
-
e.lens[i++] = 8;
|
|
1151
|
-
for (we(Ai, e.lens, 0, 288, at, 0, e.work, { bits: 9 }), i = 0; i < 32; )
|
|
1152
|
-
e.lens[i++] = 5;
|
|
1153
|
-
we(Ri, e.lens, 0, 32, nt, 0, e.work, { bits: 5 }), ti = !1;
|
|
1154
|
-
}
|
|
1155
|
-
e.lencode = at, e.lenbits = 9, e.distcode = nt, e.distbits = 5;
|
|
1156
|
-
}, Li = (e, i, t, n) => {
|
|
1157
|
-
let a;
|
|
1158
|
-
const l = e.state;
|
|
1159
|
-
return l.window === null && (l.wsize = 1 << l.wbits, l.wnext = 0, l.whave = 0, l.window = new Uint8Array(l.wsize)), n >= l.wsize ? (l.window.set(i.subarray(t - l.wsize, t), 0), l.wnext = 0, l.whave = l.wsize) : (a = l.wsize - l.wnext, a > n && (a = n), l.window.set(i.subarray(t - n, t - n + a), l.wnext), n -= a, n ? (l.window.set(i.subarray(t - n, t), 0), l.wnext = n, l.whave = l.wsize) : (l.wnext += a, l.wnext === l.wsize && (l.wnext = 0), l.whave < l.wsize && (l.whave += a))), 0;
|
|
1160
|
-
}, Gn = (e, i) => {
|
|
1161
|
-
let t, n, a, l, o, f, c, r, _, E, s, h, u, m, v = 0, w, A, x, d, S, Z, b, z;
|
|
1162
|
-
const R = new Uint8Array(4);
|
|
1163
|
-
let g, p;
|
|
1164
|
-
const J = (
|
|
1165
|
-
/* permutation of code lengths */
|
|
1166
|
-
new Uint8Array([16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15])
|
|
1167
|
-
);
|
|
1168
|
-
if (!e || !e.state || !e.output || !e.input && e.avail_in !== 0)
|
|
1169
|
-
return U;
|
|
1170
|
-
t = e.state, t.mode === H && (t.mode = et), o = e.next_out, a = e.output, c = e.avail_out, l = e.next_in, n = e.input, f = e.avail_in, r = t.hold, _ = t.bits, E = f, s = c, z = ae;
|
|
1171
|
-
e:
|
|
1172
|
-
for (; ; )
|
|
1173
|
-
switch (t.mode) {
|
|
1174
|
-
case mi:
|
|
1175
|
-
if (t.wrap === 0) {
|
|
1176
|
-
t.mode = et;
|
|
1177
|
-
break;
|
|
1178
|
-
}
|
|
1179
|
-
for (; _ < 16; ) {
|
|
1180
|
-
if (f === 0)
|
|
1181
|
-
break e;
|
|
1182
|
-
f--, r += n[l++] << _, _ += 8;
|
|
1183
|
-
}
|
|
1184
|
-
if (t.wrap & 2 && r === 35615) {
|
|
1185
|
-
t.check = 0, R[0] = r & 255, R[1] = r >>> 8 & 255, t.check = I(t.check, R, 2, 0), r = 0, _ = 0, t.mode = Ot;
|
|
1186
|
-
break;
|
|
1187
|
-
}
|
|
1188
|
-
if (t.flags = 0, t.head && (t.head.done = !1), !(t.wrap & 1) || /* check if zlib header allowed */
|
|
1189
|
-
(((r & 255) << 8) + (r >> 8)) % 31) {
|
|
1190
|
-
e.msg = "incorrect header check", t.mode = T;
|
|
1191
|
-
break;
|
|
1192
|
-
}
|
|
1193
|
-
if ((r & 15) !== It) {
|
|
1194
|
-
e.msg = "unknown compression method", t.mode = T;
|
|
1195
|
-
break;
|
|
1196
|
-
}
|
|
1197
|
-
if (r >>>= 4, _ -= 4, b = (r & 15) + 8, t.wbits === 0)
|
|
1198
|
-
t.wbits = b;
|
|
1199
|
-
else if (b > t.wbits) {
|
|
1200
|
-
e.msg = "invalid window size", t.mode = T;
|
|
1201
|
-
break;
|
|
1202
|
-
}
|
|
1203
|
-
t.dmax = 1 << t.wbits, e.adler = t.check = 1, t.mode = r & 512 ? Ht : H, r = 0, _ = 0;
|
|
1204
|
-
break;
|
|
1205
|
-
case Ot:
|
|
1206
|
-
for (; _ < 16; ) {
|
|
1207
|
-
if (f === 0)
|
|
1208
|
-
break e;
|
|
1209
|
-
f--, r += n[l++] << _, _ += 8;
|
|
1210
|
-
}
|
|
1211
|
-
if (t.flags = r, (t.flags & 255) !== It) {
|
|
1212
|
-
e.msg = "unknown compression method", t.mode = T;
|
|
1213
|
-
break;
|
|
1214
|
-
}
|
|
1215
|
-
if (t.flags & 57344) {
|
|
1216
|
-
e.msg = "unknown header flags set", t.mode = T;
|
|
1217
|
-
break;
|
|
1218
|
-
}
|
|
1219
|
-
t.head && (t.head.text = r >> 8 & 1), t.flags & 512 && (R[0] = r & 255, R[1] = r >>> 8 & 255, t.check = I(t.check, R, 2, 0)), r = 0, _ = 0, t.mode = Nt;
|
|
1220
|
-
case Nt:
|
|
1221
|
-
for (; _ < 32; ) {
|
|
1222
|
-
if (f === 0)
|
|
1223
|
-
break e;
|
|
1224
|
-
f--, r += n[l++] << _, _ += 8;
|
|
1225
|
-
}
|
|
1226
|
-
t.head && (t.head.time = r), t.flags & 512 && (R[0] = r & 255, R[1] = r >>> 8 & 255, R[2] = r >>> 16 & 255, R[3] = r >>> 24 & 255, t.check = I(t.check, R, 4, 0)), r = 0, _ = 0, t.mode = Lt;
|
|
1227
|
-
case Lt:
|
|
1228
|
-
for (; _ < 16; ) {
|
|
1229
|
-
if (f === 0)
|
|
1230
|
-
break e;
|
|
1231
|
-
f--, r += n[l++] << _, _ += 8;
|
|
1232
|
-
}
|
|
1233
|
-
t.head && (t.head.xflags = r & 255, t.head.os = r >> 8), t.flags & 512 && (R[0] = r & 255, R[1] = r >>> 8 & 255, t.check = I(t.check, R, 2, 0)), r = 0, _ = 0, t.mode = Ut;
|
|
1234
|
-
case Ut:
|
|
1235
|
-
if (t.flags & 1024) {
|
|
1236
|
-
for (; _ < 16; ) {
|
|
1237
|
-
if (f === 0)
|
|
1238
|
-
break e;
|
|
1239
|
-
f--, r += n[l++] << _, _ += 8;
|
|
1240
|
-
}
|
|
1241
|
-
t.length = r, t.head && (t.head.extra_len = r), t.flags & 512 && (R[0] = r & 255, R[1] = r >>> 8 & 255, t.check = I(t.check, R, 2, 0)), r = 0, _ = 0;
|
|
1242
|
-
} else
|
|
1243
|
-
t.head && (t.head.extra = null);
|
|
1244
|
-
t.mode = Ct;
|
|
1245
|
-
case Ct:
|
|
1246
|
-
if (t.flags & 1024 && (h = t.length, h > f && (h = f), h && (t.head && (b = t.head.extra_len - t.length, t.head.extra || (t.head.extra = new Uint8Array(t.head.extra_len)), t.head.extra.set(
|
|
1247
|
-
n.subarray(
|
|
1248
|
-
l,
|
|
1249
|
-
// extra field is limited to 65536 bytes
|
|
1250
|
-
// - no need for additional size check
|
|
1251
|
-
l + h
|
|
1252
|
-
),
|
|
1253
|
-
/*len + copy > state.head.extra_max - len ? state.head.extra_max : copy,*/
|
|
1254
|
-
b
|
|
1255
|
-
)), t.flags & 512 && (t.check = I(t.check, n, h, l)), f -= h, l += h, t.length -= h), t.length))
|
|
1256
|
-
break e;
|
|
1257
|
-
t.length = 0, t.mode = $t;
|
|
1258
|
-
case $t:
|
|
1259
|
-
if (t.flags & 2048) {
|
|
1260
|
-
if (f === 0)
|
|
1261
|
-
break e;
|
|
1262
|
-
h = 0;
|
|
1263
|
-
do
|
|
1264
|
-
b = n[l + h++], t.head && b && t.length < 65536 && (t.head.name += String.fromCharCode(b));
|
|
1265
|
-
while (b && h < f);
|
|
1266
|
-
if (t.flags & 512 && (t.check = I(t.check, n, h, l)), f -= h, l += h, b)
|
|
1267
|
-
break e;
|
|
1268
|
-
} else
|
|
1269
|
-
t.head && (t.head.name = null);
|
|
1270
|
-
t.length = 0, t.mode = Ft;
|
|
1271
|
-
case Ft:
|
|
1272
|
-
if (t.flags & 4096) {
|
|
1273
|
-
if (f === 0)
|
|
1274
|
-
break e;
|
|
1275
|
-
h = 0;
|
|
1276
|
-
do
|
|
1277
|
-
b = n[l + h++], t.head && b && t.length < 65536 && (t.head.comment += String.fromCharCode(b));
|
|
1278
|
-
while (b && h < f);
|
|
1279
|
-
if (t.flags & 512 && (t.check = I(t.check, n, h, l)), f -= h, l += h, b)
|
|
1280
|
-
break e;
|
|
1281
|
-
} else
|
|
1282
|
-
t.head && (t.head.comment = null);
|
|
1283
|
-
t.mode = Mt;
|
|
1284
|
-
case Mt:
|
|
1285
|
-
if (t.flags & 512) {
|
|
1286
|
-
for (; _ < 16; ) {
|
|
1287
|
-
if (f === 0)
|
|
1288
|
-
break e;
|
|
1289
|
-
f--, r += n[l++] << _, _ += 8;
|
|
1290
|
-
}
|
|
1291
|
-
if (r !== (t.check & 65535)) {
|
|
1292
|
-
e.msg = "header crc mismatch", t.mode = T;
|
|
1293
|
-
break;
|
|
1294
|
-
}
|
|
1295
|
-
r = 0, _ = 0;
|
|
1296
|
-
}
|
|
1297
|
-
t.head && (t.head.hcrc = t.flags >> 9 & 1, t.head.done = !0), e.adler = t.check = 0, t.mode = H;
|
|
1298
|
-
break;
|
|
1299
|
-
case Ht:
|
|
1300
|
-
for (; _ < 32; ) {
|
|
1301
|
-
if (f === 0)
|
|
1302
|
-
break e;
|
|
1303
|
-
f--, r += n[l++] << _, _ += 8;
|
|
1304
|
-
}
|
|
1305
|
-
e.adler = t.check = ei(r), r = 0, _ = 0, t.mode = Ke;
|
|
1306
|
-
case Ke:
|
|
1307
|
-
if (t.havedict === 0)
|
|
1308
|
-
return e.next_out = o, e.avail_out = c, e.next_in = l, e.avail_in = f, t.hold = r, t.bits = _, Cn;
|
|
1309
|
-
e.adler = t.check = 1, t.mode = H;
|
|
1310
|
-
case H:
|
|
1311
|
-
if (i === Ln || i === Ne)
|
|
1312
|
-
break e;
|
|
1313
|
-
case et:
|
|
1314
|
-
if (t.last) {
|
|
1315
|
-
r >>>= _ & 7, _ -= _ & 7, t.mode = it;
|
|
1316
|
-
break;
|
|
1317
|
-
}
|
|
1318
|
-
for (; _ < 3; ) {
|
|
1319
|
-
if (f === 0)
|
|
1320
|
-
break e;
|
|
1321
|
-
f--, r += n[l++] << _, _ += 8;
|
|
1322
|
-
}
|
|
1323
|
-
switch (t.last = r & 1, r >>>= 1, _ -= 1, r & 3) {
|
|
1324
|
-
case 0:
|
|
1325
|
-
t.mode = Bt;
|
|
1326
|
-
break;
|
|
1327
|
-
case 1:
|
|
1328
|
-
if (Yn(t), t.mode = Le, i === Ne) {
|
|
1329
|
-
r >>>= 2, _ -= 2;
|
|
1330
|
-
break e;
|
|
1331
|
-
}
|
|
1332
|
-
break;
|
|
1333
|
-
case 2:
|
|
1334
|
-
t.mode = Pt;
|
|
1335
|
-
break;
|
|
1336
|
-
case 3:
|
|
1337
|
-
e.msg = "invalid block type", t.mode = T;
|
|
1338
|
-
}
|
|
1339
|
-
r >>>= 2, _ -= 2;
|
|
1340
|
-
break;
|
|
1341
|
-
case Bt:
|
|
1342
|
-
for (r >>>= _ & 7, _ -= _ & 7; _ < 32; ) {
|
|
1343
|
-
if (f === 0)
|
|
1344
|
-
break e;
|
|
1345
|
-
f--, r += n[l++] << _, _ += 8;
|
|
1346
|
-
}
|
|
1347
|
-
if ((r & 65535) !== (r >>> 16 ^ 65535)) {
|
|
1348
|
-
e.msg = "invalid stored block lengths", t.mode = T;
|
|
1349
|
-
break;
|
|
1350
|
-
}
|
|
1351
|
-
if (t.length = r & 65535, r = 0, _ = 0, t.mode = tt, i === Ne)
|
|
1352
|
-
break e;
|
|
1353
|
-
case tt:
|
|
1354
|
-
t.mode = Kt;
|
|
1355
|
-
case Kt:
|
|
1356
|
-
if (h = t.length, h) {
|
|
1357
|
-
if (h > f && (h = f), h > c && (h = c), h === 0)
|
|
1358
|
-
break e;
|
|
1359
|
-
a.set(n.subarray(l, l + h), o), f -= h, l += h, c -= h, o += h, t.length -= h;
|
|
1360
|
-
break;
|
|
1361
|
-
}
|
|
1362
|
-
t.mode = H;
|
|
1363
|
-
break;
|
|
1364
|
-
case Pt:
|
|
1365
|
-
for (; _ < 14; ) {
|
|
1366
|
-
if (f === 0)
|
|
1367
|
-
break e;
|
|
1368
|
-
f--, r += n[l++] << _, _ += 8;
|
|
1369
|
-
}
|
|
1370
|
-
if (t.nlen = (r & 31) + 257, r >>>= 5, _ -= 5, t.ndist = (r & 31) + 1, r >>>= 5, _ -= 5, t.ncode = (r & 15) + 4, r >>>= 4, _ -= 4, t.nlen > 286 || t.ndist > 30) {
|
|
1371
|
-
e.msg = "too many length or distance symbols", t.mode = T;
|
|
1372
|
-
break;
|
|
1373
|
-
}
|
|
1374
|
-
t.have = 0, t.mode = Xt;
|
|
1375
|
-
case Xt:
|
|
1376
|
-
for (; t.have < t.ncode; ) {
|
|
1377
|
-
for (; _ < 3; ) {
|
|
1378
|
-
if (f === 0)
|
|
1379
|
-
break e;
|
|
1380
|
-
f--, r += n[l++] << _, _ += 8;
|
|
1381
|
-
}
|
|
1382
|
-
t.lens[J[t.have++]] = r & 7, r >>>= 3, _ -= 3;
|
|
1383
|
-
}
|
|
1384
|
-
for (; t.have < 19; )
|
|
1385
|
-
t.lens[J[t.have++]] = 0;
|
|
1386
|
-
if (t.lencode = t.lendyn, t.lenbits = 7, g = { bits: t.lenbits }, z = we(Nn, t.lens, 0, 19, t.lencode, 0, t.work, g), t.lenbits = g.bits, z) {
|
|
1387
|
-
e.msg = "invalid code lengths set", t.mode = T;
|
|
1388
|
-
break;
|
|
1389
|
-
}
|
|
1390
|
-
t.have = 0, t.mode = Yt;
|
|
1391
|
-
case Yt:
|
|
1392
|
-
for (; t.have < t.nlen + t.ndist; ) {
|
|
1393
|
-
for (; v = t.lencode[r & (1 << t.lenbits) - 1], w = v >>> 24, A = v >>> 16 & 255, x = v & 65535, !(w <= _); ) {
|
|
1394
|
-
if (f === 0)
|
|
1395
|
-
break e;
|
|
1396
|
-
f--, r += n[l++] << _, _ += 8;
|
|
1397
|
-
}
|
|
1398
|
-
if (x < 16)
|
|
1399
|
-
r >>>= w, _ -= w, t.lens[t.have++] = x;
|
|
1400
|
-
else {
|
|
1401
|
-
if (x === 16) {
|
|
1402
|
-
for (p = w + 2; _ < p; ) {
|
|
1403
|
-
if (f === 0)
|
|
1404
|
-
break e;
|
|
1405
|
-
f--, r += n[l++] << _, _ += 8;
|
|
1406
|
-
}
|
|
1407
|
-
if (r >>>= w, _ -= w, t.have === 0) {
|
|
1408
|
-
e.msg = "invalid bit length repeat", t.mode = T;
|
|
1409
|
-
break;
|
|
1410
|
-
}
|
|
1411
|
-
b = t.lens[t.have - 1], h = 3 + (r & 3), r >>>= 2, _ -= 2;
|
|
1412
|
-
} else if (x === 17) {
|
|
1413
|
-
for (p = w + 3; _ < p; ) {
|
|
1414
|
-
if (f === 0)
|
|
1415
|
-
break e;
|
|
1416
|
-
f--, r += n[l++] << _, _ += 8;
|
|
1417
|
-
}
|
|
1418
|
-
r >>>= w, _ -= w, b = 0, h = 3 + (r & 7), r >>>= 3, _ -= 3;
|
|
1419
|
-
} else {
|
|
1420
|
-
for (p = w + 7; _ < p; ) {
|
|
1421
|
-
if (f === 0)
|
|
1422
|
-
break e;
|
|
1423
|
-
f--, r += n[l++] << _, _ += 8;
|
|
1424
|
-
}
|
|
1425
|
-
r >>>= w, _ -= w, b = 0, h = 11 + (r & 127), r >>>= 7, _ -= 7;
|
|
1426
|
-
}
|
|
1427
|
-
if (t.have + h > t.nlen + t.ndist) {
|
|
1428
|
-
e.msg = "invalid bit length repeat", t.mode = T;
|
|
1429
|
-
break;
|
|
1430
|
-
}
|
|
1431
|
-
for (; h--; )
|
|
1432
|
-
t.lens[t.have++] = b;
|
|
1433
|
-
}
|
|
1434
|
-
}
|
|
1435
|
-
if (t.mode === T)
|
|
1436
|
-
break;
|
|
1437
|
-
if (t.lens[256] === 0) {
|
|
1438
|
-
e.msg = "invalid code -- missing end-of-block", t.mode = T;
|
|
1439
|
-
break;
|
|
1440
|
-
}
|
|
1441
|
-
if (t.lenbits = 9, g = { bits: t.lenbits }, z = we(Ai, t.lens, 0, t.nlen, t.lencode, 0, t.work, g), t.lenbits = g.bits, z) {
|
|
1442
|
-
e.msg = "invalid literal/lengths set", t.mode = T;
|
|
1443
|
-
break;
|
|
1444
|
-
}
|
|
1445
|
-
if (t.distbits = 6, t.distcode = t.distdyn, g = { bits: t.distbits }, z = we(Ri, t.lens, t.nlen, t.ndist, t.distcode, 0, t.work, g), t.distbits = g.bits, z) {
|
|
1446
|
-
e.msg = "invalid distances set", t.mode = T;
|
|
1447
|
-
break;
|
|
1448
|
-
}
|
|
1449
|
-
if (t.mode = Le, i === Ne)
|
|
1450
|
-
break e;
|
|
1451
|
-
case Le:
|
|
1452
|
-
t.mode = Ue;
|
|
1453
|
-
case Ue:
|
|
1454
|
-
if (f >= 6 && c >= 258) {
|
|
1455
|
-
e.next_out = o, e.avail_out = c, e.next_in = l, e.avail_in = f, t.hold = r, t.bits = _, Tn(e, s), o = e.next_out, a = e.output, c = e.avail_out, l = e.next_in, n = e.input, f = e.avail_in, r = t.hold, _ = t.bits, t.mode === H && (t.back = -1);
|
|
1456
|
-
break;
|
|
1457
|
-
}
|
|
1458
|
-
for (t.back = 0; v = t.lencode[r & (1 << t.lenbits) - 1], w = v >>> 24, A = v >>> 16 & 255, x = v & 65535, !(w <= _); ) {
|
|
1459
|
-
if (f === 0)
|
|
1460
|
-
break e;
|
|
1461
|
-
f--, r += n[l++] << _, _ += 8;
|
|
1462
|
-
}
|
|
1463
|
-
if (A && !(A & 240)) {
|
|
1464
|
-
for (d = w, S = A, Z = x; v = t.lencode[Z + ((r & (1 << d + S) - 1) >> d)], w = v >>> 24, A = v >>> 16 & 255, x = v & 65535, !(d + w <= _); ) {
|
|
1465
|
-
if (f === 0)
|
|
1466
|
-
break e;
|
|
1467
|
-
f--, r += n[l++] << _, _ += 8;
|
|
1468
|
-
}
|
|
1469
|
-
r >>>= d, _ -= d, t.back += d;
|
|
1470
|
-
}
|
|
1471
|
-
if (r >>>= w, _ -= w, t.back += w, t.length = x, A === 0) {
|
|
1472
|
-
t.mode = Jt;
|
|
1473
|
-
break;
|
|
1474
|
-
}
|
|
1475
|
-
if (A & 32) {
|
|
1476
|
-
t.back = -1, t.mode = H;
|
|
1477
|
-
break;
|
|
1478
|
-
}
|
|
1479
|
-
if (A & 64) {
|
|
1480
|
-
e.msg = "invalid literal/length code", t.mode = T;
|
|
1481
|
-
break;
|
|
1482
|
-
}
|
|
1483
|
-
t.extra = A & 15, t.mode = Gt;
|
|
1484
|
-
case Gt:
|
|
1485
|
-
if (t.extra) {
|
|
1486
|
-
for (p = t.extra; _ < p; ) {
|
|
1487
|
-
if (f === 0)
|
|
1488
|
-
break e;
|
|
1489
|
-
f--, r += n[l++] << _, _ += 8;
|
|
1490
|
-
}
|
|
1491
|
-
t.length += r & (1 << t.extra) - 1, r >>>= t.extra, _ -= t.extra, t.back += t.extra;
|
|
1492
|
-
}
|
|
1493
|
-
t.was = t.length, t.mode = jt;
|
|
1494
|
-
case jt:
|
|
1495
|
-
for (; v = t.distcode[r & (1 << t.distbits) - 1], w = v >>> 24, A = v >>> 16 & 255, x = v & 65535, !(w <= _); ) {
|
|
1496
|
-
if (f === 0)
|
|
1497
|
-
break e;
|
|
1498
|
-
f--, r += n[l++] << _, _ += 8;
|
|
1499
|
-
}
|
|
1500
|
-
if (!(A & 240)) {
|
|
1501
|
-
for (d = w, S = A, Z = x; v = t.distcode[Z + ((r & (1 << d + S) - 1) >> d)], w = v >>> 24, A = v >>> 16 & 255, x = v & 65535, !(d + w <= _); ) {
|
|
1502
|
-
if (f === 0)
|
|
1503
|
-
break e;
|
|
1504
|
-
f--, r += n[l++] << _, _ += 8;
|
|
1505
|
-
}
|
|
1506
|
-
r >>>= d, _ -= d, t.back += d;
|
|
1507
|
-
}
|
|
1508
|
-
if (r >>>= w, _ -= w, t.back += w, A & 64) {
|
|
1509
|
-
e.msg = "invalid distance code", t.mode = T;
|
|
1510
|
-
break;
|
|
1511
|
-
}
|
|
1512
|
-
t.offset = x, t.extra = A & 15, t.mode = Wt;
|
|
1513
|
-
case Wt:
|
|
1514
|
-
if (t.extra) {
|
|
1515
|
-
for (p = t.extra; _ < p; ) {
|
|
1516
|
-
if (f === 0)
|
|
1517
|
-
break e;
|
|
1518
|
-
f--, r += n[l++] << _, _ += 8;
|
|
1519
|
-
}
|
|
1520
|
-
t.offset += r & (1 << t.extra) - 1, r >>>= t.extra, _ -= t.extra, t.back += t.extra;
|
|
1521
|
-
}
|
|
1522
|
-
if (t.offset > t.dmax) {
|
|
1523
|
-
e.msg = "invalid distance too far back", t.mode = T;
|
|
1524
|
-
break;
|
|
1525
|
-
}
|
|
1526
|
-
t.mode = Vt;
|
|
1527
|
-
case Vt:
|
|
1528
|
-
if (c === 0)
|
|
1529
|
-
break e;
|
|
1530
|
-
if (h = s - c, t.offset > h) {
|
|
1531
|
-
if (h = t.offset - h, h > t.whave && t.sane) {
|
|
1532
|
-
e.msg = "invalid distance too far back", t.mode = T;
|
|
1533
|
-
break;
|
|
1534
|
-
}
|
|
1535
|
-
h > t.wnext ? (h -= t.wnext, u = t.wsize - h) : u = t.wnext - h, h > t.length && (h = t.length), m = t.window;
|
|
1536
|
-
} else
|
|
1537
|
-
m = a, u = o - t.offset, h = t.length;
|
|
1538
|
-
h > c && (h = c), c -= h, t.length -= h;
|
|
1539
|
-
do
|
|
1540
|
-
a[o++] = m[u++];
|
|
1541
|
-
while (--h);
|
|
1542
|
-
t.length === 0 && (t.mode = Ue);
|
|
1543
|
-
break;
|
|
1544
|
-
case Jt:
|
|
1545
|
-
if (c === 0)
|
|
1546
|
-
break e;
|
|
1547
|
-
a[o++] = t.length, c--, t.mode = Ue;
|
|
1548
|
-
break;
|
|
1549
|
-
case it:
|
|
1550
|
-
if (t.wrap) {
|
|
1551
|
-
for (; _ < 32; ) {
|
|
1552
|
-
if (f === 0)
|
|
1553
|
-
break e;
|
|
1554
|
-
f--, r |= n[l++] << _, _ += 8;
|
|
1555
|
-
}
|
|
1556
|
-
if (s -= c, e.total_out += s, t.total += s, s && (e.adler = t.check = /*UPDATE(state.check, put - _out, _out);*/
|
|
1557
|
-
t.flags ? I(t.check, a, s, o - s) : ve(t.check, a, s, o - s)), s = c, (t.flags ? r : ei(r)) !== t.check) {
|
|
1558
|
-
e.msg = "incorrect data check", t.mode = T;
|
|
1559
|
-
break;
|
|
1560
|
-
}
|
|
1561
|
-
r = 0, _ = 0;
|
|
1562
|
-
}
|
|
1563
|
-
t.mode = Qt;
|
|
1564
|
-
case Qt:
|
|
1565
|
-
if (t.wrap && t.flags) {
|
|
1566
|
-
for (; _ < 32; ) {
|
|
1567
|
-
if (f === 0)
|
|
1568
|
-
break e;
|
|
1569
|
-
f--, r += n[l++] << _, _ += 8;
|
|
1570
|
-
}
|
|
1571
|
-
if (r !== (t.total & 4294967295)) {
|
|
1572
|
-
e.msg = "incorrect length check", t.mode = T;
|
|
1573
|
-
break;
|
|
1574
|
-
}
|
|
1575
|
-
r = 0, _ = 0;
|
|
1576
|
-
}
|
|
1577
|
-
t.mode = qt;
|
|
1578
|
-
case qt:
|
|
1579
|
-
z = Un;
|
|
1580
|
-
break e;
|
|
1581
|
-
case T:
|
|
1582
|
-
z = zi;
|
|
1583
|
-
break e;
|
|
1584
|
-
case Di:
|
|
1585
|
-
return Ti;
|
|
1586
|
-
case Fn:
|
|
1587
|
-
default:
|
|
1588
|
-
return U;
|
|
1589
|
-
}
|
|
1590
|
-
return e.next_out = o, e.avail_out = c, e.next_in = l, e.avail_in = f, t.hold = r, t.bits = _, (t.wsize || s !== e.avail_out && t.mode < T && (t.mode < it || i !== Zt)) && Li(e, e.output, e.next_out, s - e.avail_out), E -= e.avail_in, s -= e.avail_out, e.total_in += E, e.total_out += s, t.total += s, t.wrap && s && (e.adler = t.check = /*UPDATE(state.check, strm.next_out - _out, _out);*/
|
|
1591
|
-
t.flags ? I(t.check, a, s, e.next_out - s) : ve(t.check, a, s, e.next_out - s)), e.data_type = t.bits + (t.last ? 64 : 0) + (t.mode === H ? 128 : 0) + (t.mode === Le || t.mode === tt ? 256 : 0), (E === 0 && s === 0 || i === Zt) && z === ae && (z = $n), z;
|
|
1592
|
-
}, jn = (e) => {
|
|
1593
|
-
if (!e || !e.state)
|
|
1594
|
-
return U;
|
|
1595
|
-
let i = e.state;
|
|
1596
|
-
return i.window && (i.window = null), e.state = null, ae;
|
|
1597
|
-
}, Wn = (e, i) => {
|
|
1598
|
-
if (!e || !e.state)
|
|
1599
|
-
return U;
|
|
1600
|
-
const t = e.state;
|
|
1601
|
-
return t.wrap & 2 ? (t.head = i, i.done = !1, ae) : U;
|
|
1602
|
-
}, Vn = (e, i) => {
|
|
1603
|
-
const t = i.length;
|
|
1604
|
-
let n, a, l;
|
|
1605
|
-
return !e || !e.state || (n = e.state, n.wrap !== 0 && n.mode !== Ke) ? U : n.mode === Ke && (a = 1, a = ve(a, i, t, 0), a !== n.check) ? zi : (l = Li(e, i, t, t), l ? (n.mode = Di, Ti) : (n.havedict = 1, ae));
|
|
1606
|
-
};
|
|
1607
|
-
var Jn = Ii, Qn = Oi, qn = Zi, el = Xn, tl = Ni, il = Gn, al = jn, nl = Wn, ll = Vn, rl = "pako inflate (from Nodeca project)", K = {
|
|
1608
|
-
inflateReset: Jn,
|
|
1609
|
-
inflateReset2: Qn,
|
|
1610
|
-
inflateResetKeep: qn,
|
|
1611
|
-
inflateInit: el,
|
|
1612
|
-
inflateInit2: tl,
|
|
1613
|
-
inflate: il,
|
|
1614
|
-
inflateEnd: al,
|
|
1615
|
-
inflateGetHeader: nl,
|
|
1616
|
-
inflateSetDictionary: ll,
|
|
1617
|
-
inflateInfo: rl
|
|
1618
|
-
};
|
|
1619
|
-
function fl() {
|
|
1620
|
-
this.text = 0, this.time = 0, this.xflags = 0, this.os = 0, this.extra = null, this.extra_len = 0, this.name = "", this.comment = "", this.hcrc = 0, this.done = !1;
|
|
1621
|
-
}
|
|
1622
|
-
var ol = fl;
|
|
1623
|
-
const Ui = Object.prototype.toString, {
|
|
1624
|
-
Z_NO_FLUSH: _l,
|
|
1625
|
-
Z_FINISH: hl,
|
|
1626
|
-
Z_OK: Se,
|
|
1627
|
-
Z_STREAM_END: lt,
|
|
1628
|
-
Z_NEED_DICT: rt,
|
|
1629
|
-
Z_STREAM_ERROR: dl,
|
|
1630
|
-
Z_DATA_ERROR: ii,
|
|
1631
|
-
Z_MEM_ERROR: sl
|
|
1632
|
-
} = ne;
|
|
1633
|
-
function Te(e) {
|
|
1634
|
-
this.options = Ye.assign({
|
|
1635
|
-
chunkSize: 1024 * 64,
|
|
1636
|
-
windowBits: 15,
|
|
1637
|
-
to: ""
|
|
1638
|
-
}, e || {});
|
|
1639
|
-
const i = this.options;
|
|
1640
|
-
i.raw && i.windowBits >= 0 && i.windowBits < 16 && (i.windowBits = -i.windowBits, i.windowBits === 0 && (i.windowBits = -15)), i.windowBits >= 0 && i.windowBits < 16 && !(e && e.windowBits) && (i.windowBits += 32), i.windowBits > 15 && i.windowBits < 48 && (i.windowBits & 15 || (i.windowBits |= 15)), this.err = 0, this.msg = "", this.ended = !1, this.chunks = [], this.strm = new yi(), this.strm.avail_out = 0;
|
|
1641
|
-
let t = K.inflateInit2(
|
|
1642
|
-
this.strm,
|
|
1643
|
-
i.windowBits
|
|
1644
|
-
);
|
|
1645
|
-
if (t !== Se)
|
|
1646
|
-
throw new Error(ee[t]);
|
|
1647
|
-
if (this.header = new ol(), K.inflateGetHeader(this.strm, this.header), i.dictionary && (typeof i.dictionary == "string" ? i.dictionary = ye.string2buf(i.dictionary) : Ui.call(i.dictionary) === "[object ArrayBuffer]" && (i.dictionary = new Uint8Array(i.dictionary)), i.raw && (t = K.inflateSetDictionary(this.strm, i.dictionary), t !== Se)))
|
|
1648
|
-
throw new Error(ee[t]);
|
|
1649
|
-
}
|
|
1650
|
-
Te.prototype.push = function(e, i) {
|
|
1651
|
-
const t = this.strm, n = this.options.chunkSize, a = this.options.dictionary;
|
|
1652
|
-
let l, o, f;
|
|
1653
|
-
if (this.ended)
|
|
1654
|
-
return !1;
|
|
1655
|
-
for (i === ~~i ? o = i : o = i === !0 ? hl : _l, Ui.call(e) === "[object ArrayBuffer]" ? t.input = new Uint8Array(e) : t.input = e, t.next_in = 0, t.avail_in = t.input.length; ; ) {
|
|
1656
|
-
for (t.avail_out === 0 && (t.output = new Uint8Array(n), t.next_out = 0, t.avail_out = n), l = K.inflate(t, o), l === rt && a && (l = K.inflateSetDictionary(t, a), l === Se ? l = K.inflate(t, o) : l === ii && (l = rt)); t.avail_in > 0 && l === lt && t.state.wrap > 0 && e[t.next_in] !== 0; )
|
|
1657
|
-
K.inflateReset(t), l = K.inflate(t, o);
|
|
1658
|
-
switch (l) {
|
|
1659
|
-
case dl:
|
|
1660
|
-
case ii:
|
|
1661
|
-
case rt:
|
|
1662
|
-
case sl:
|
|
1663
|
-
return this.onEnd(l), this.ended = !0, !1;
|
|
1664
|
-
}
|
|
1665
|
-
if (f = t.avail_out, t.next_out && (t.avail_out === 0 || l === lt))
|
|
1666
|
-
if (this.options.to === "string") {
|
|
1667
|
-
let c = ye.utf8border(t.output, t.next_out), r = t.next_out - c, _ = ye.buf2string(t.output, c);
|
|
1668
|
-
t.next_out = r, t.avail_out = n - r, r && t.output.set(t.output.subarray(c, c + r), 0), this.onData(_);
|
|
1669
|
-
} else
|
|
1670
|
-
this.onData(t.output.length === t.next_out ? t.output : t.output.subarray(0, t.next_out));
|
|
1671
|
-
if (!(l === Se && f === 0)) {
|
|
1672
|
-
if (l === lt)
|
|
1673
|
-
return l = K.inflateEnd(this.strm), this.onEnd(l), this.ended = !0, !0;
|
|
1674
|
-
if (t.avail_in === 0)
|
|
1675
|
-
break;
|
|
1676
|
-
}
|
|
1677
|
-
}
|
|
1678
|
-
return !0;
|
|
1679
|
-
};
|
|
1680
|
-
Te.prototype.onData = function(e) {
|
|
1681
|
-
this.chunks.push(e);
|
|
1682
|
-
};
|
|
1683
|
-
Te.prototype.onEnd = function(e) {
|
|
1684
|
-
e === Se && (this.options.to === "string" ? this.result = this.chunks.join("") : this.result = Ye.flattenChunks(this.chunks)), this.chunks = [], this.err = e, this.msg = this.strm.msg;
|
|
1685
|
-
};
|
|
1686
|
-
function wt(e, i) {
|
|
1687
|
-
const t = new Te(i);
|
|
1688
|
-
if (t.push(e), t.err)
|
|
1689
|
-
throw t.msg || ee[t.err];
|
|
1690
|
-
return t.result;
|
|
1691
|
-
}
|
|
1692
|
-
function cl(e, i) {
|
|
1693
|
-
return i = i || {}, i.raw = !0, wt(e, i);
|
|
1694
|
-
}
|
|
1695
|
-
var ul = Te, bl = wt, wl = cl, gl = wt, pl = ne, xl = {
|
|
1696
|
-
Inflate: ul,
|
|
1697
|
-
inflate: bl,
|
|
1698
|
-
inflateRaw: wl,
|
|
1699
|
-
ungzip: gl,
|
|
1700
|
-
constants: pl
|
|
1701
|
-
};
|
|
1702
|
-
const { Deflate: kl, deflate: vl, deflateRaw: El, gzip: yl } = Rn, { Inflate: Sl, inflate: Al, inflateRaw: Rl, ungzip: zl } = xl;
|
|
1703
|
-
var Tl = kl, ml = vl, Dl = El, Zl = yl, Il = Sl, Ol = Al, Nl = Rl, Ll = zl, Ul = ne, Cl = {
|
|
1704
|
-
Deflate: Tl,
|
|
1705
|
-
deflate: ml,
|
|
1706
|
-
deflateRaw: Dl,
|
|
1707
|
-
gzip: Zl,
|
|
1708
|
-
Inflate: Il,
|
|
1709
|
-
inflate: Ol,
|
|
1710
|
-
inflateRaw: Nl,
|
|
1711
|
-
ungzip: Ll,
|
|
1712
|
-
constants: Ul
|
|
1713
|
-
};
|
|
1714
|
-
export {
|
|
1715
|
-
Cl as p
|
|
1716
|
-
};
|