@wp-playground/client 3.0.1 → 3.0.2
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/blueprints-v2-handler.d.ts +7 -0
- package/index.cjs +39 -39
- package/index.d.ts +4 -0
- package/index.js +532 -504
- package/package.json +2 -2
package/index.js
CHANGED
|
@@ -67,16 +67,16 @@ if (Nl === "NODE" && typeof CustomEvent > "u") {
|
|
|
67
67
|
}
|
|
68
68
|
globalThis.CustomEvent = e;
|
|
69
69
|
}
|
|
70
|
-
const
|
|
71
|
-
|
|
72
|
-
new CustomEvent(
|
|
70
|
+
const hc = "playground-log", Aa = (e, ...t) => {
|
|
71
|
+
Pe.dispatchEvent(
|
|
72
|
+
new CustomEvent(hc, {
|
|
73
73
|
detail: {
|
|
74
74
|
log: e,
|
|
75
75
|
args: t
|
|
76
76
|
}
|
|
77
77
|
})
|
|
78
78
|
);
|
|
79
|
-
},
|
|
79
|
+
}, mc = (e, ...t) => {
|
|
80
80
|
switch (typeof e.message == "string" ? Reflect.set(e, "message", Li(e.message)) : e.message.message && typeof e.message.message == "string" && Reflect.set(
|
|
81
81
|
e.message,
|
|
82
82
|
"message",
|
|
@@ -100,15 +100,15 @@ const uc = "playground-log", Aa = (e, ...t) => {
|
|
|
100
100
|
default:
|
|
101
101
|
console.log(e.message, ...t);
|
|
102
102
|
}
|
|
103
|
-
},
|
|
103
|
+
}, yc = (e) => e instanceof Error ? [e.message, e.stack].join(`
|
|
104
104
|
`) : JSON.stringify(e, null, 2), jl = [], Ta = (e) => {
|
|
105
105
|
jl.push(e);
|
|
106
106
|
}, Oi = (e) => {
|
|
107
107
|
if (e.raw === !0)
|
|
108
108
|
Ta(e.message);
|
|
109
109
|
else {
|
|
110
|
-
const t =
|
|
111
|
-
typeof e.message == "object" ?
|
|
110
|
+
const t = bc(
|
|
111
|
+
typeof e.message == "object" ? yc(e.message) : e.message,
|
|
112
112
|
e.severity,
|
|
113
113
|
e.prefix ?? ur.JS
|
|
114
114
|
);
|
|
@@ -116,9 +116,9 @@ const uc = "playground-log", Aa = (e, ...t) => {
|
|
|
116
116
|
}
|
|
117
117
|
};
|
|
118
118
|
let Zn = 0;
|
|
119
|
-
const Ca = "/wordpress/wp-content/debug.log",
|
|
119
|
+
const Ca = "/wordpress/wp-content/debug.log", _c = async (e) => await e.fileExists(Ca) ? await e.readFileAsText(Ca) : "", Bl = (e, t) => {
|
|
120
120
|
t.addEventListener("request.end", async () => {
|
|
121
|
-
const r = await
|
|
121
|
+
const r = await _c(t);
|
|
122
122
|
if (r.length > Zn) {
|
|
123
123
|
const i = r.substring(Zn);
|
|
124
124
|
e.logMessage({
|
|
@@ -153,7 +153,7 @@ const Ca = "/wordpress/wp-content/debug.log", mc = async (e) => await e.fileExis
|
|
|
153
153
|
PHP: "PHP",
|
|
154
154
|
JS: "JavaScript"
|
|
155
155
|
};
|
|
156
|
-
class
|
|
156
|
+
class gc extends EventTarget {
|
|
157
157
|
// constructor
|
|
158
158
|
constructor(t = []) {
|
|
159
159
|
super(), this.fatalErrorEvent = "playground-fatal-error", this.severity = ft.Info, this.handlers = t;
|
|
@@ -274,14 +274,14 @@ class _c extends EventTarget {
|
|
|
274
274
|
);
|
|
275
275
|
}
|
|
276
276
|
}
|
|
277
|
-
const
|
|
277
|
+
const wc = () => {
|
|
278
278
|
try {
|
|
279
279
|
if (process.env.NODE_ENV === "test")
|
|
280
280
|
return [Oi, Aa];
|
|
281
281
|
} catch {
|
|
282
282
|
}
|
|
283
|
-
return [Oi,
|
|
284
|
-
},
|
|
283
|
+
return [Oi, mc, Aa];
|
|
284
|
+
}, Pe = new gc(wc()), Li = (e) => e.replace(/\t/g, ""), bc = (e, t, r) => {
|
|
285
285
|
const i = /* @__PURE__ */ new Date(), a = new Intl.DateTimeFormat("en-GB", {
|
|
286
286
|
year: "numeric",
|
|
287
287
|
month: "short",
|
|
@@ -296,11 +296,11 @@ const gc = () => {
|
|
|
296
296
|
timeZoneName: "short"
|
|
297
297
|
}).format(i), s = a + " " + n;
|
|
298
298
|
return e = Li(e), `[${s}] ${r} ${t.name}: ${e}`;
|
|
299
|
-
},
|
|
300
|
-
function
|
|
301
|
-
const r = e.headers.get("content-length") || "", i = parseInt(r, 10) ||
|
|
299
|
+
}, vc = 5 * 1024 * 1024;
|
|
300
|
+
function xc(e, t) {
|
|
301
|
+
const r = e.headers.get("content-length") || "", i = parseInt(r, 10) || vc;
|
|
302
302
|
return new Response(
|
|
303
|
-
|
|
303
|
+
Wl(e.body, i, t),
|
|
304
304
|
{
|
|
305
305
|
status: e.status,
|
|
306
306
|
statusText: e.statusText,
|
|
@@ -308,7 +308,7 @@ function vc(e, t) {
|
|
|
308
308
|
}
|
|
309
309
|
);
|
|
310
310
|
}
|
|
311
|
-
function
|
|
311
|
+
function Wl(e, t, r) {
|
|
312
312
|
function i(a, n) {
|
|
313
313
|
r(
|
|
314
314
|
new CustomEvent("progress", {
|
|
@@ -336,7 +336,7 @@ function Bl(e, t, r) {
|
|
|
336
336
|
} else
|
|
337
337
|
i(s, t), a.enqueue(f);
|
|
338
338
|
} catch (o) {
|
|
339
|
-
|
|
339
|
+
Pe.error({ e: o }), a.error(o);
|
|
340
340
|
break;
|
|
341
341
|
}
|
|
342
342
|
}
|
|
@@ -509,13 +509,13 @@ class Rn extends EventTarget {
|
|
|
509
509
|
this.dispatchEvent(new CustomEvent("done"));
|
|
510
510
|
}
|
|
511
511
|
}
|
|
512
|
-
const
|
|
513
|
-
function
|
|
512
|
+
const Ul = Symbol("SleepFinished");
|
|
513
|
+
function kc(e) {
|
|
514
514
|
return new Promise((t) => {
|
|
515
|
-
setTimeout(() => t(
|
|
515
|
+
setTimeout(() => t(Ul), e);
|
|
516
516
|
});
|
|
517
517
|
}
|
|
518
|
-
class
|
|
518
|
+
class Sc extends Error {
|
|
519
519
|
constructor() {
|
|
520
520
|
super("Acquiring lock timed out");
|
|
521
521
|
}
|
|
@@ -536,10 +536,10 @@ class Jr {
|
|
|
536
536
|
const t = new Promise((r) => {
|
|
537
537
|
this.queue.push(r);
|
|
538
538
|
});
|
|
539
|
-
this.timeout !== void 0 ? await Promise.race([t,
|
|
539
|
+
this.timeout !== void 0 ? await Promise.race([t, kc(this.timeout)]).then(
|
|
540
540
|
(r) => {
|
|
541
|
-
if (r ===
|
|
542
|
-
throw new
|
|
541
|
+
if (r === Ul)
|
|
542
|
+
throw new Sc();
|
|
543
543
|
}
|
|
544
544
|
) : await t;
|
|
545
545
|
} else {
|
|
@@ -576,12 +576,12 @@ function gn(e) {
|
|
|
576
576
|
}
|
|
577
577
|
function In(e) {
|
|
578
578
|
const t = e[0] === "/";
|
|
579
|
-
return e =
|
|
579
|
+
return e = Ec(
|
|
580
580
|
e.split("/").filter((r) => !!r),
|
|
581
581
|
!t
|
|
582
582
|
).join("/"), (t ? "/" : "") + e.replace(/\/$/, "");
|
|
583
583
|
}
|
|
584
|
-
function
|
|
584
|
+
function Ec(e, t) {
|
|
585
585
|
let r = 0;
|
|
586
586
|
for (let i = e.length - 1; i >= 0; i--) {
|
|
587
587
|
const a = e[i];
|
|
@@ -592,18 +592,18 @@ function Sc(e, t) {
|
|
|
592
592
|
e.unshift("..");
|
|
593
593
|
return e;
|
|
594
594
|
}
|
|
595
|
-
function
|
|
595
|
+
function Ml(e = 36, t = "!@#$%^&*()_+=-[]/.,<>?") {
|
|
596
596
|
const r = "0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ" + t;
|
|
597
597
|
let i = "";
|
|
598
598
|
for (let a = e; a > 0; --a)
|
|
599
599
|
i += r[Math.floor(Math.random() * r.length)];
|
|
600
600
|
return i;
|
|
601
601
|
}
|
|
602
|
-
function
|
|
603
|
-
return
|
|
602
|
+
function Pc() {
|
|
603
|
+
return Ml(36, "-_");
|
|
604
604
|
}
|
|
605
605
|
function wt(e) {
|
|
606
|
-
return `json_decode(base64_decode('${
|
|
606
|
+
return `json_decode(base64_decode('${Ac(
|
|
607
607
|
JSON.stringify(e)
|
|
608
608
|
)}'), true)`;
|
|
609
609
|
}
|
|
@@ -613,14 +613,14 @@ function Dn(e) {
|
|
|
613
613
|
t[r] = wt(e[r]);
|
|
614
614
|
return t;
|
|
615
615
|
}
|
|
616
|
-
function Pc(e) {
|
|
617
|
-
return Ac(new TextEncoder().encode(e));
|
|
618
|
-
}
|
|
619
616
|
function Ac(e) {
|
|
617
|
+
return Tc(new TextEncoder().encode(e));
|
|
618
|
+
}
|
|
619
|
+
function Tc(e) {
|
|
620
620
|
const t = String.fromCodePoint(...e);
|
|
621
621
|
return btoa(t);
|
|
622
622
|
}
|
|
623
|
-
function
|
|
623
|
+
function Cc(e) {
|
|
624
624
|
let t = 0;
|
|
625
625
|
e.forEach((a) => t += a.length);
|
|
626
626
|
const r = new Uint8Array(t);
|
|
@@ -633,7 +633,7 @@ function Tc(e) {
|
|
|
633
633
|
var e;
|
|
634
634
|
return typeof process < "u" && ((e = process.release) == null ? void 0 : e.name) === "node" ? "NODE" : typeof window < "u" ? "WEB" : typeof WorkerGlobalScope < "u" && self instanceof WorkerGlobalScope ? "WORKER" : "NODE";
|
|
635
635
|
})();
|
|
636
|
-
const
|
|
636
|
+
const Oc = {
|
|
637
637
|
500: "Internal Server Error",
|
|
638
638
|
502: "Bad Gateway",
|
|
639
639
|
404: "Not Found",
|
|
@@ -657,7 +657,7 @@ class us {
|
|
|
657
657
|
t,
|
|
658
658
|
{},
|
|
659
659
|
new TextEncoder().encode(
|
|
660
|
-
r ||
|
|
660
|
+
r || Oc[t] || ""
|
|
661
661
|
)
|
|
662
662
|
);
|
|
663
663
|
}
|
|
@@ -732,7 +732,7 @@ const { hasOwnProperty: Vn } = Object.prototype, Ri = (e, t = {}) => {
|
|
|
732
732
|
}
|
|
733
733
|
t.section && o.length && (o = "[" + Zt(t.section) + "]" + (t.newline ? r + r : r) + o);
|
|
734
734
|
for (const p of a) {
|
|
735
|
-
const c =
|
|
735
|
+
const c = ql(p, ".").join("\\."), y = (t.section ? t.section + "." : "") + c, h = Ri(e[p], {
|
|
736
736
|
...t,
|
|
737
737
|
section: y
|
|
738
738
|
});
|
|
@@ -740,7 +740,7 @@ const { hasOwnProperty: Vn } = Object.prototype, Ri = (e, t = {}) => {
|
|
|
740
740
|
}
|
|
741
741
|
return o;
|
|
742
742
|
};
|
|
743
|
-
function
|
|
743
|
+
function ql(e, t) {
|
|
744
744
|
var r = 0, i = 0, a = 0, n = [];
|
|
745
745
|
do
|
|
746
746
|
if (a = e.indexOf(t, r), a !== -1) {
|
|
@@ -783,7 +783,7 @@ const Ra = (e, t = {}) => {
|
|
|
783
783
|
for (const p of Object.keys(r)) {
|
|
784
784
|
if (!Vn.call(r, p) || typeof r[p] != "object" || Array.isArray(r[p]))
|
|
785
785
|
continue;
|
|
786
|
-
const c =
|
|
786
|
+
const c = ql(p, ".");
|
|
787
787
|
i = r;
|
|
788
788
|
const y = c.pop(), h = y.replace(/\\\./g, ".");
|
|
789
789
|
for (const _ of c)
|
|
@@ -793,8 +793,8 @@ const Ra = (e, t = {}) => {
|
|
|
793
793
|
for (const p of f)
|
|
794
794
|
delete r[p];
|
|
795
795
|
return r;
|
|
796
|
-
},
|
|
797
|
-
if (e = (e || "").trim(),
|
|
796
|
+
}, Kl = (e) => e.startsWith('"') && e.endsWith('"') || e.startsWith("'") && e.endsWith("'"), Zt = (e) => typeof e != "string" || e.match(/[=\r\n]/) || e.match(/^\[/) || e.length > 1 && Kl(e) || e !== e.trim() ? JSON.stringify(e) : e.split(";").join("\\;").split("#").join("\\#"), nn = (e) => {
|
|
797
|
+
if (e = (e || "").trim(), Kl(e)) {
|
|
798
798
|
e.charAt(0) === "'" && (e = e.slice(1, -1));
|
|
799
799
|
try {
|
|
800
800
|
e = JSON.parse(e);
|
|
@@ -824,13 +824,13 @@ var Ia = {
|
|
|
824
824
|
safe: Zt,
|
|
825
825
|
unsafe: nn
|
|
826
826
|
};
|
|
827
|
-
async function
|
|
827
|
+
async function pg(e, t) {
|
|
828
828
|
const r = Ia.parse(await e.readFileAsText(La));
|
|
829
829
|
for (const [i, a] of Object.entries(t))
|
|
830
830
|
a == null ? delete r[i] : r[i] = a;
|
|
831
831
|
await e.writeFile(La, Ia.stringify(r));
|
|
832
832
|
}
|
|
833
|
-
function
|
|
833
|
+
function Lc(...e) {
|
|
834
834
|
const t = new Uint8Array(
|
|
835
835
|
e.reduce((i, a) => i + a.length, 0)
|
|
836
836
|
);
|
|
@@ -839,12 +839,12 @@ function Oc(...e) {
|
|
|
839
839
|
t.set(i, r), r += i.length;
|
|
840
840
|
return t;
|
|
841
841
|
}
|
|
842
|
-
function
|
|
842
|
+
function Rc(e) {
|
|
843
843
|
{
|
|
844
844
|
let t = new Uint8Array();
|
|
845
845
|
return new TransformStream({
|
|
846
846
|
transform(r) {
|
|
847
|
-
t =
|
|
847
|
+
t = Lc(t, r);
|
|
848
848
|
},
|
|
849
849
|
flush(r) {
|
|
850
850
|
r.enqueue(t);
|
|
@@ -852,8 +852,8 @@ function Lc(e) {
|
|
|
852
852
|
});
|
|
853
853
|
}
|
|
854
854
|
}
|
|
855
|
-
async function
|
|
856
|
-
return await e.pipeThrough(
|
|
855
|
+
async function Ic(e, t) {
|
|
856
|
+
return await e.pipeThrough(Rc()).getReader().read().then(({ value: r }) => r);
|
|
857
857
|
}
|
|
858
858
|
class ws extends File {
|
|
859
859
|
/**
|
|
@@ -896,7 +896,7 @@ class ws extends File {
|
|
|
896
896
|
* @returns File data as an ArrayBuffer.
|
|
897
897
|
*/
|
|
898
898
|
async arrayBuffer() {
|
|
899
|
-
return await
|
|
899
|
+
return await Ic(this.stream());
|
|
900
900
|
}
|
|
901
901
|
}
|
|
902
902
|
ReadableStream.prototype[Symbol.asyncIterator] || (ReadableStream.prototype[Symbol.asyncIterator] = async function* () {
|
|
@@ -923,7 +923,7 @@ const ra = [
|
|
|
923
923
|
"7.4",
|
|
924
924
|
"7.3",
|
|
925
925
|
"7.2"
|
|
926
|
-
],
|
|
926
|
+
], Dc = ra[0], cg = ra;
|
|
927
927
|
async function Hn(e, t, r, { rmRoot: i = !1 } = {}) {
|
|
928
928
|
i && await e.isDir(t) && await e.rmdir(t, { recursive: !0 });
|
|
929
929
|
for (const [a, n] of Object.entries(r)) {
|
|
@@ -938,7 +938,7 @@ async function Hn(e, t, r, { rmRoot: i = !1 } = {}) {
|
|
|
938
938
|
* Copyright 2019 Google LLC
|
|
939
939
|
* SPDX-License-Identifier: Apache-2.0
|
|
940
940
|
*/
|
|
941
|
-
const
|
|
941
|
+
const zl = Symbol("Comlink.proxy"), Hc = Symbol("Comlink.endpoint"), $c = Symbol("Comlink.releaseProxy"), Yn = Symbol("Comlink.finalizer"), an = Symbol("Comlink.thrown");
|
|
942
942
|
/**
|
|
943
943
|
* @license
|
|
944
944
|
* Copyright 2019 Google LLC
|
|
@@ -954,8 +954,8 @@ const wn = {
|
|
|
954
954
|
CONSTRUCT: "CONSTRUCT",
|
|
955
955
|
ENDPOINT: "ENDPOINT",
|
|
956
956
|
RELEASE: "RELEASE"
|
|
957
|
-
},
|
|
958
|
-
canHandle: (e) =>
|
|
957
|
+
}, Gl = (e) => typeof e == "object" && e !== null || typeof e == "function", Fc = {
|
|
958
|
+
canHandle: (e) => Gl(e) && e[zl],
|
|
959
959
|
serialize(e) {
|
|
960
960
|
const { port1: t, port2: r } = new MessageChannel();
|
|
961
961
|
return sa(e, t), [r, [r]];
|
|
@@ -963,8 +963,8 @@ const wn = {
|
|
|
963
963
|
deserialize(e) {
|
|
964
964
|
return e.start(), na(e);
|
|
965
965
|
}
|
|
966
|
-
},
|
|
967
|
-
canHandle: (e) =>
|
|
966
|
+
}, Nc = {
|
|
967
|
+
canHandle: (e) => Gl(e) && an in e,
|
|
968
968
|
serialize({ value: e }) {
|
|
969
969
|
let t;
|
|
970
970
|
return e instanceof Error ? t = {
|
|
@@ -983,10 +983,10 @@ const wn = {
|
|
|
983
983
|
) : e.value;
|
|
984
984
|
}
|
|
985
985
|
}, Xt = /* @__PURE__ */ new Map([
|
|
986
|
-
["proxy",
|
|
987
|
-
["throw",
|
|
986
|
+
["proxy", Fc],
|
|
987
|
+
["throw", Nc]
|
|
988
988
|
]);
|
|
989
|
-
function
|
|
989
|
+
function jc(e, t) {
|
|
990
990
|
for (const r of e)
|
|
991
991
|
if (t === r || r === "*" || r instanceof RegExp && r.test(t))
|
|
992
992
|
return !0;
|
|
@@ -996,7 +996,7 @@ function sa(e, t = globalThis, r = ["*"], i) {
|
|
|
996
996
|
t.addEventListener("message", function a(n) {
|
|
997
997
|
if (!n || !n.data)
|
|
998
998
|
return;
|
|
999
|
-
if (!
|
|
999
|
+
if (!jc(r, n.origin)) {
|
|
1000
1000
|
console.warn(`Invalid origin '${n.origin}' for comlink proxy`);
|
|
1001
1001
|
return;
|
|
1002
1002
|
}
|
|
@@ -1022,13 +1022,13 @@ function sa(e, t = globalThis, r = ["*"], i) {
|
|
|
1022
1022
|
case _t.CONSTRUCT:
|
|
1023
1023
|
{
|
|
1024
1024
|
const _ = new h(...p);
|
|
1025
|
-
c =
|
|
1025
|
+
c = Xl(_);
|
|
1026
1026
|
}
|
|
1027
1027
|
break;
|
|
1028
1028
|
case _t.ENDPOINT:
|
|
1029
1029
|
{
|
|
1030
1030
|
const { port1: _, port2: L } = new MessageChannel();
|
|
1031
|
-
sa(e, L), c =
|
|
1031
|
+
sa(e, L), c = qc(_, [_]);
|
|
1032
1032
|
}
|
|
1033
1033
|
break;
|
|
1034
1034
|
case _t.RELEASE:
|
|
@@ -1042,7 +1042,7 @@ function sa(e, t = globalThis, r = ["*"], i) {
|
|
|
1042
1042
|
}
|
|
1043
1043
|
Promise.resolve(c).catch((y) => ({ value: y, [an]: 0 })).then((y) => {
|
|
1044
1044
|
const [h, _] = xn(y);
|
|
1045
|
-
t.postMessage({ ...h, id: s }, _), o === _t.RELEASE && (t.removeEventListener("message", a),
|
|
1045
|
+
t.postMessage({ ...h, id: s }, _), o === _t.RELEASE && (t.removeEventListener("message", a), Zl(t), Yn in e && typeof e[Yn] == "function" && e[Yn]());
|
|
1046
1046
|
}).catch(() => {
|
|
1047
1047
|
const [y, h] = xn({
|
|
1048
1048
|
value: new TypeError("Unserializable return value"),
|
|
@@ -1053,11 +1053,11 @@ function sa(e, t = globalThis, r = ["*"], i) {
|
|
|
1053
1053
|
});
|
|
1054
1054
|
}), t.start && t.start();
|
|
1055
1055
|
}
|
|
1056
|
-
function
|
|
1056
|
+
function Bc(e) {
|
|
1057
1057
|
return e.constructor.name === "MessagePort";
|
|
1058
1058
|
}
|
|
1059
|
-
function
|
|
1060
|
-
|
|
1059
|
+
function Zl(e) {
|
|
1060
|
+
Bc(e) && e.close();
|
|
1061
1061
|
}
|
|
1062
1062
|
function na(e, t) {
|
|
1063
1063
|
const r = /* @__PURE__ */ new Map();
|
|
@@ -1078,22 +1078,22 @@ function Ws(e) {
|
|
|
1078
1078
|
if (e)
|
|
1079
1079
|
throw new Error("Proxy has been released and is not useable");
|
|
1080
1080
|
}
|
|
1081
|
-
function
|
|
1081
|
+
function Vl(e) {
|
|
1082
1082
|
return Mr(e, /* @__PURE__ */ new Map(), {
|
|
1083
1083
|
type: _t.RELEASE
|
|
1084
1084
|
}).then(() => {
|
|
1085
|
-
|
|
1085
|
+
Zl(e);
|
|
1086
1086
|
});
|
|
1087
1087
|
}
|
|
1088
1088
|
const bn = /* @__PURE__ */ new WeakMap(), vn = "FinalizationRegistry" in globalThis && new FinalizationRegistry((e) => {
|
|
1089
1089
|
const t = (bn.get(e) || 0) - 1;
|
|
1090
|
-
bn.set(e, t), t === 0 &&
|
|
1090
|
+
bn.set(e, t), t === 0 && Vl(e);
|
|
1091
1091
|
});
|
|
1092
|
-
function
|
|
1092
|
+
function Wc(e, t) {
|
|
1093
1093
|
const r = (bn.get(t) || 0) + 1;
|
|
1094
1094
|
bn.set(t, r), vn && vn.register(e, t, e);
|
|
1095
1095
|
}
|
|
1096
|
-
function
|
|
1096
|
+
function Uc(e) {
|
|
1097
1097
|
vn && vn.unregister(e);
|
|
1098
1098
|
}
|
|
1099
1099
|
function Ii(e, t, r = [], i = function() {
|
|
@@ -1101,9 +1101,9 @@ function Ii(e, t, r = [], i = function() {
|
|
|
1101
1101
|
let a = !1;
|
|
1102
1102
|
const n = new Proxy(i, {
|
|
1103
1103
|
get(s, o) {
|
|
1104
|
-
if (Ws(a), o ===
|
|
1104
|
+
if (Ws(a), o === $c)
|
|
1105
1105
|
return () => {
|
|
1106
|
-
|
|
1106
|
+
Uc(n), Vl(e), t.clear(), a = !0;
|
|
1107
1107
|
};
|
|
1108
1108
|
if (o === "then") {
|
|
1109
1109
|
if (r.length === 0)
|
|
@@ -1133,7 +1133,7 @@ function Ii(e, t, r = [], i = function() {
|
|
|
1133
1133
|
apply(s, o, f) {
|
|
1134
1134
|
Ws(a);
|
|
1135
1135
|
const p = r[r.length - 1];
|
|
1136
|
-
if (p ===
|
|
1136
|
+
if (p === Hc)
|
|
1137
1137
|
return Mr(e, t, {
|
|
1138
1138
|
type: _t.ENDPOINT
|
|
1139
1139
|
}).then(br);
|
|
@@ -1166,23 +1166,23 @@ function Ii(e, t, r = [], i = function() {
|
|
|
1166
1166
|
).then(br);
|
|
1167
1167
|
}
|
|
1168
1168
|
});
|
|
1169
|
-
return
|
|
1169
|
+
return Wc(n, e), n;
|
|
1170
1170
|
}
|
|
1171
|
-
function
|
|
1171
|
+
function Mc(e) {
|
|
1172
1172
|
return Array.prototype.concat.apply([], e);
|
|
1173
1173
|
}
|
|
1174
1174
|
function Da(e) {
|
|
1175
1175
|
const t = e.map(xn);
|
|
1176
|
-
return [t.map((r) => r[0]),
|
|
1176
|
+
return [t.map((r) => r[0]), Mc(t.map((r) => r[1]))];
|
|
1177
1177
|
}
|
|
1178
|
-
const
|
|
1179
|
-
function
|
|
1180
|
-
return
|
|
1178
|
+
const Yl = /* @__PURE__ */ new WeakMap();
|
|
1179
|
+
function qc(e, t) {
|
|
1180
|
+
return Yl.set(e, t), e;
|
|
1181
1181
|
}
|
|
1182
|
-
function
|
|
1183
|
-
return Object.assign(e, { [
|
|
1182
|
+
function Xl(e) {
|
|
1183
|
+
return Object.assign(e, { [zl]: !0 });
|
|
1184
1184
|
}
|
|
1185
|
-
function
|
|
1185
|
+
function Kc(e, t = globalThis, r = "*") {
|
|
1186
1186
|
return {
|
|
1187
1187
|
postMessage: (i, a) => e.postMessage(i, r, a),
|
|
1188
1188
|
addEventListener: t.addEventListener.bind(t),
|
|
@@ -1207,7 +1207,7 @@ function xn(e) {
|
|
|
1207
1207
|
type: wn.RAW,
|
|
1208
1208
|
value: e
|
|
1209
1209
|
},
|
|
1210
|
-
|
|
1210
|
+
Yl.get(e) || []
|
|
1211
1211
|
];
|
|
1212
1212
|
}
|
|
1213
1213
|
function br(e) {
|
|
@@ -1220,16 +1220,16 @@ function br(e) {
|
|
|
1220
1220
|
}
|
|
1221
1221
|
function Mr(e, t, r, i) {
|
|
1222
1222
|
return new Promise((a) => {
|
|
1223
|
-
const n =
|
|
1223
|
+
const n = zc();
|
|
1224
1224
|
t.set(n, a), e.start && e.start(), e.postMessage({ id: n, ...r }, i);
|
|
1225
1225
|
});
|
|
1226
1226
|
}
|
|
1227
|
-
function
|
|
1227
|
+
function zc() {
|
|
1228
1228
|
return new Array(4).fill(0).map(
|
|
1229
1229
|
() => Math.floor(Math.random() * Number.MAX_SAFE_INTEGER).toString(16)
|
|
1230
1230
|
).join("-");
|
|
1231
1231
|
}
|
|
1232
|
-
function
|
|
1232
|
+
function Gc(e) {
|
|
1233
1233
|
const t = /* @__PURE__ */ new WeakMap();
|
|
1234
1234
|
return {
|
|
1235
1235
|
postMessage: e.postMessage.bind(e),
|
|
@@ -1246,7 +1246,7 @@ function zc(e) {
|
|
|
1246
1246
|
start: e.start && e.start.bind(e)
|
|
1247
1247
|
};
|
|
1248
1248
|
}
|
|
1249
|
-
const
|
|
1249
|
+
const Zc = [
|
|
1250
1250
|
// Native ES errors https://262.ecma-international.org/12.0/#sec-well-known-intrinsic-objects
|
|
1251
1251
|
Error,
|
|
1252
1252
|
EvalError,
|
|
@@ -1262,7 +1262,7 @@ const Gc = [
|
|
|
1262
1262
|
// https://nodejs.org/api/errors.html
|
|
1263
1263
|
globalThis.AssertionError,
|
|
1264
1264
|
globalThis.SystemError
|
|
1265
|
-
].filter(Boolean).map((e) => [e.name, e]),
|
|
1265
|
+
].filter(Boolean).map((e) => [e.name, e]), Vc = new Map(Zc);
|
|
1266
1266
|
class ia extends Error {
|
|
1267
1267
|
constructor(t) {
|
|
1268
1268
|
super(ia._prepareSuperMessage(t)), this.name = "NonError";
|
|
@@ -1275,7 +1275,7 @@ class ia extends Error {
|
|
|
1275
1275
|
}
|
|
1276
1276
|
}
|
|
1277
1277
|
}
|
|
1278
|
-
const
|
|
1278
|
+
const Yc = [
|
|
1279
1279
|
{
|
|
1280
1280
|
property: "name",
|
|
1281
1281
|
enumerable: !1
|
|
@@ -1300,12 +1300,12 @@ const Vc = [
|
|
|
1300
1300
|
property: "errors",
|
|
1301
1301
|
enumerable: !1
|
|
1302
1302
|
}
|
|
1303
|
-
], Di = /* @__PURE__ */ new WeakSet(),
|
|
1303
|
+
], Di = /* @__PURE__ */ new WeakSet(), Xc = (e) => {
|
|
1304
1304
|
Di.add(e);
|
|
1305
1305
|
const t = e.toJSON();
|
|
1306
1306
|
return Di.delete(e), t;
|
|
1307
|
-
},
|
|
1308
|
-
const t =
|
|
1307
|
+
}, Jl = (e) => {
|
|
1308
|
+
const t = Vc.get(e) ?? Error;
|
|
1309
1309
|
return t === AggregateError ? new t([]) : new t();
|
|
1310
1310
|
}, aa = ({
|
|
1311
1311
|
from: e,
|
|
@@ -1317,10 +1317,10 @@ const Vc = [
|
|
|
1317
1317
|
useToJSON: s,
|
|
1318
1318
|
serialize: o
|
|
1319
1319
|
}) => {
|
|
1320
|
-
if (r || (Array.isArray(e) ? r = [] : !o && Ha(e) ? r =
|
|
1320
|
+
if (r || (Array.isArray(e) ? r = [] : !o && Ha(e) ? r = Jl(e.name) : r = {}), t.push(e), n >= a)
|
|
1321
1321
|
return r;
|
|
1322
1322
|
if (s && typeof e.toJSON == "function" && !Di.has(e))
|
|
1323
|
-
return
|
|
1323
|
+
return Xc(e);
|
|
1324
1324
|
const f = (p) => aa({
|
|
1325
1325
|
from: p,
|
|
1326
1326
|
seen: [...t],
|
|
@@ -1355,7 +1355,7 @@ const Vc = [
|
|
|
1355
1355
|
}
|
|
1356
1356
|
}
|
|
1357
1357
|
if (o || r instanceof Error)
|
|
1358
|
-
for (const { property: p, enumerable: c } of
|
|
1358
|
+
for (const { property: p, enumerable: c } of Yc)
|
|
1359
1359
|
e[p] !== void 0 && e[p] !== null && Object.defineProperty(r, p, {
|
|
1360
1360
|
value: Ha(e[p]) || Array.isArray(e[p]) ? f(e[p]) : e[p],
|
|
1361
1361
|
enumerable: i ? !0 : c,
|
|
@@ -1364,7 +1364,7 @@ const Vc = [
|
|
|
1364
1364
|
});
|
|
1365
1365
|
return r;
|
|
1366
1366
|
};
|
|
1367
|
-
function
|
|
1367
|
+
function Jc(e, t = {}) {
|
|
1368
1368
|
const { maxDepth: r = Number.POSITIVE_INFINITY, useToJSON: i = !0 } = t;
|
|
1369
1369
|
return typeof e == "object" && e !== null ? aa({
|
|
1370
1370
|
from: e,
|
|
@@ -1376,12 +1376,12 @@ function Xc(e, t = {}) {
|
|
|
1376
1376
|
serialize: !0
|
|
1377
1377
|
}) : typeof e == "function" ? `[Function: ${e.name || "anonymous"}]` : e;
|
|
1378
1378
|
}
|
|
1379
|
-
function
|
|
1379
|
+
function Qc(e, t = {}) {
|
|
1380
1380
|
const { maxDepth: r = Number.POSITIVE_INFINITY } = t;
|
|
1381
|
-
return e instanceof Error ? e :
|
|
1381
|
+
return e instanceof Error ? e : eu(e) ? aa({
|
|
1382
1382
|
from: e,
|
|
1383
1383
|
seen: [],
|
|
1384
|
-
to:
|
|
1384
|
+
to: Jl(e.name),
|
|
1385
1385
|
maxDepth: r,
|
|
1386
1386
|
depth: 0,
|
|
1387
1387
|
serialize: !1
|
|
@@ -1390,14 +1390,14 @@ function Jc(e, t = {}) {
|
|
|
1390
1390
|
function Ha(e) {
|
|
1391
1391
|
return !!e && typeof e == "object" && typeof e.name == "string" && typeof e.message == "string" && typeof e.stack == "string";
|
|
1392
1392
|
}
|
|
1393
|
-
function
|
|
1393
|
+
function eu(e) {
|
|
1394
1394
|
return !!e && typeof e == "object" && typeof e.message == "string" && !Array.isArray(e);
|
|
1395
1395
|
}
|
|
1396
|
-
function
|
|
1396
|
+
function Ql(e, t = void 0) {
|
|
1397
1397
|
ru();
|
|
1398
1398
|
let r;
|
|
1399
|
-
import.meta.url.startsWith("file://") ? r =
|
|
1400
|
-
const a = na(r), n =
|
|
1399
|
+
import.meta.url.startsWith("file://") ? r = Gc(e) : r = e instanceof Worker ? e : Kc(e, t);
|
|
1400
|
+
const a = na(r), n = ef(a);
|
|
1401
1401
|
return new Proxy(n, {
|
|
1402
1402
|
get: (s, o) => o === "isConnected" ? async () => {
|
|
1403
1403
|
for (; ; )
|
|
@@ -1469,12 +1469,12 @@ const su = Xt.get(
|
|
|
1469
1469
|
let t;
|
|
1470
1470
|
return e instanceof Error ? (t = {
|
|
1471
1471
|
isError: !0,
|
|
1472
|
-
value:
|
|
1472
|
+
value: Jc(e)
|
|
1473
1473
|
}, t.value.originalErrorClassName = e.constructor.name) : t = { isError: !1, value: e }, [t, []];
|
|
1474
1474
|
},
|
|
1475
1475
|
deserialize: (e) => {
|
|
1476
1476
|
if (e.isError) {
|
|
1477
|
-
const t =
|
|
1477
|
+
const t = Qc(e.value), r = new Error("Comlink method call failed");
|
|
1478
1478
|
let i = t;
|
|
1479
1479
|
for (; i.cause; )
|
|
1480
1480
|
i = i.cause;
|
|
@@ -1484,20 +1484,20 @@ const su = Xt.get(
|
|
|
1484
1484
|
}
|
|
1485
1485
|
};
|
|
1486
1486
|
Xt.set("throw", nu);
|
|
1487
|
-
function
|
|
1487
|
+
function ef(e) {
|
|
1488
1488
|
return new Proxy(e, {
|
|
1489
1489
|
get(t, r) {
|
|
1490
1490
|
switch (typeof t[r]) {
|
|
1491
1491
|
case "function":
|
|
1492
1492
|
return (...i) => t[r](...i);
|
|
1493
1493
|
case "object":
|
|
1494
|
-
return t[r] === null ? t[r] :
|
|
1494
|
+
return t[r] === null ? t[r] : ef(t[r]);
|
|
1495
1495
|
case "undefined":
|
|
1496
1496
|
case "number":
|
|
1497
1497
|
case "string":
|
|
1498
1498
|
return t[r];
|
|
1499
1499
|
default:
|
|
1500
|
-
return
|
|
1500
|
+
return Xl(t[r]);
|
|
1501
1501
|
}
|
|
1502
1502
|
}
|
|
1503
1503
|
});
|
|
@@ -1518,14 +1518,14 @@ function iu(e) {
|
|
|
1518
1518
|
}
|
|
1519
1519
|
};
|
|
1520
1520
|
}
|
|
1521
|
-
function
|
|
1521
|
+
function tf(e) {
|
|
1522
1522
|
return e[Symbol.asyncIterator] ? e[Symbol.asyncIterator]() : e[Symbol.iterator] ? e[Symbol.iterator]() : e.next ? e : iu(e);
|
|
1523
1523
|
}
|
|
1524
|
-
class
|
|
1524
|
+
class rf {
|
|
1525
1525
|
constructor(t) {
|
|
1526
1526
|
if (typeof Buffer > "u")
|
|
1527
1527
|
throw new Error("Missing Buffer dependency");
|
|
1528
|
-
this.stream =
|
|
1528
|
+
this.stream = tf(t), this.buffer = null, this.cursor = 0, this.undoCursor = 0, this.started = !1, this._ended = !1, this._discardedBytes = 0;
|
|
1529
1529
|
}
|
|
1530
1530
|
eof() {
|
|
1531
1531
|
return this._ended && this.cursor === this.buffer.length;
|
|
@@ -1599,7 +1599,7 @@ class Ze {
|
|
|
1599
1599
|
return Buffer.concat([Buffer.from(i, "utf8"), t]);
|
|
1600
1600
|
}
|
|
1601
1601
|
static streamReader(t) {
|
|
1602
|
-
const r = new
|
|
1602
|
+
const r = new rf(t);
|
|
1603
1603
|
return async function() {
|
|
1604
1604
|
try {
|
|
1605
1605
|
let a = await r.read(4);
|
|
@@ -1654,19 +1654,19 @@ class $n extends Qr {
|
|
|
1654
1654
|
}
|
|
1655
1655
|
}
|
|
1656
1656
|
$n.code = "UnsafeFilepathError";
|
|
1657
|
-
function
|
|
1657
|
+
function sf(e, t) {
|
|
1658
1658
|
return -(e < t) || +(e > t);
|
|
1659
1659
|
}
|
|
1660
1660
|
function lu(e, t) {
|
|
1661
|
-
return
|
|
1661
|
+
return sf(e.path, t.path);
|
|
1662
1662
|
}
|
|
1663
1663
|
function fu(e, t) {
|
|
1664
|
-
return
|
|
1664
|
+
return sf(Fa(e), Fa(t));
|
|
1665
1665
|
}
|
|
1666
1666
|
function Fa(e) {
|
|
1667
1667
|
return e.mode === "040000" ? e.path + "/" : e.path;
|
|
1668
1668
|
}
|
|
1669
|
-
function
|
|
1669
|
+
function nf(e) {
|
|
1670
1670
|
switch (e) {
|
|
1671
1671
|
case "040000":
|
|
1672
1672
|
return "tree";
|
|
@@ -1697,7 +1697,7 @@ function pu(e) {
|
|
|
1697
1697
|
);
|
|
1698
1698
|
let n = e.slice(r, i).toString("utf8");
|
|
1699
1699
|
n === "40000" && (n = "040000");
|
|
1700
|
-
const s =
|
|
1700
|
+
const s = nf(n), o = e.slice(i + 1, a).toString("utf8");
|
|
1701
1701
|
if (o.includes("\\") || o.includes("/"))
|
|
1702
1702
|
throw new $n(o);
|
|
1703
1703
|
const f = e.slice(a + 1, a + 21).toString("hex");
|
|
@@ -1714,7 +1714,7 @@ function cu(e) {
|
|
|
1714
1714
|
throw new $e(`Could not understand file mode: ${e}`);
|
|
1715
1715
|
}
|
|
1716
1716
|
function uu(e) {
|
|
1717
|
-
return !e.oid && e.sha && (e.oid = e.sha), e.mode = cu(e.mode), e.type || (e.type =
|
|
1717
|
+
return !e.oid && e.sha && (e.oid = e.sha), e.mode = cu(e.mode), e.type || (e.type = nf(e.mode)), e;
|
|
1718
1718
|
}
|
|
1719
1719
|
class oa {
|
|
1720
1720
|
constructor(t) {
|
|
@@ -2006,7 +2006,7 @@ gpgsig` + Xn(s) + `
|
|
|
2006
2006
|
return ht.from(f);
|
|
2007
2007
|
}
|
|
2008
2008
|
}
|
|
2009
|
-
var
|
|
2009
|
+
var af = {};
|
|
2010
2010
|
/*! crc32.js (C) 2014-present SheetJS -- http://sheetjs.com */
|
|
2011
2011
|
(function(e) {
|
|
2012
2012
|
(function(t) {
|
|
@@ -2045,8 +2045,8 @@ var sf = {};
|
|
|
2045
2045
|
}
|
|
2046
2046
|
t.table = i, t.bstr = A, t.buf = H, t.str = S;
|
|
2047
2047
|
});
|
|
2048
|
-
})(
|
|
2049
|
-
const wu = /* @__PURE__ */ ta(
|
|
2048
|
+
})(af);
|
|
2049
|
+
const wu = /* @__PURE__ */ ta(af);
|
|
2050
2050
|
class bu {
|
|
2051
2051
|
static wrap({ type: t, object: r }) {
|
|
2052
2052
|
return Buffer.concat([
|
|
@@ -2223,7 +2223,7 @@ function ts(e) {
|
|
|
2223
2223
|
for (var t = e.length; --t >= 0; )
|
|
2224
2224
|
e[t] = 0;
|
|
2225
2225
|
}
|
|
2226
|
-
var Eu = 0,
|
|
2226
|
+
var Eu = 0, of = 1, Pu = 2, Au = 3, Tu = 258, la = 29, Is = 256, bs = Is + 1 + la, Gr = 30, fa = 19, lf = 2 * bs + 1, kr = 15, Jn = 16, Cu = 7, pa = 256, ff = 16, pf = 17, cf = 18, $i = (
|
|
2227
2227
|
/* extra bits for each length code */
|
|
2228
2228
|
[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]
|
|
2229
2229
|
), on = (
|
|
@@ -2232,7 +2232,7 @@ var Eu = 0, nf = 1, Pu = 2, Au = 3, Tu = 258, la = 29, Is = 256, bs = Is + 1 + l
|
|
|
2232
2232
|
), Ou = (
|
|
2233
2233
|
/* extra bits for each bit length code */
|
|
2234
2234
|
[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 3, 7]
|
|
2235
|
-
),
|
|
2235
|
+
), uf = [16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15], Lu = 512, Yt = new Array((bs + 2) * 2);
|
|
2236
2236
|
ts(Yt);
|
|
2237
2237
|
var hs = new Array(Gr * 2);
|
|
2238
2238
|
ts(hs);
|
|
@@ -2247,11 +2247,11 @@ ts(Sn);
|
|
|
2247
2247
|
function Qn(e, t, r, i, a) {
|
|
2248
2248
|
this.static_tree = e, this.extra_bits = t, this.extra_base = r, this.elems = i, this.max_length = a, this.has_stree = e && e.length;
|
|
2249
2249
|
}
|
|
2250
|
-
var
|
|
2250
|
+
var df, hf, mf;
|
|
2251
2251
|
function ei(e, t) {
|
|
2252
2252
|
this.dyn_tree = e, this.max_code = 0, this.stat_desc = t;
|
|
2253
2253
|
}
|
|
2254
|
-
function
|
|
2254
|
+
function yf(e) {
|
|
2255
2255
|
return e < 256 ? vs[e] : vs[256 + (e >>> 7)];
|
|
2256
2256
|
}
|
|
2257
2257
|
function ks(e, t) {
|
|
@@ -2268,7 +2268,7 @@ function jt(e, t, r) {
|
|
|
2268
2268
|
/*.Len*/
|
|
2269
2269
|
);
|
|
2270
2270
|
}
|
|
2271
|
-
function
|
|
2271
|
+
function _f(e, t) {
|
|
2272
2272
|
var r = 0;
|
|
2273
2273
|
do
|
|
2274
2274
|
r |= e & 1, e >>>= 1, r <<= 1;
|
|
@@ -2282,7 +2282,7 @@ function Iu(e, t) {
|
|
|
2282
2282
|
var r = t.dyn_tree, i = t.max_code, a = t.stat_desc.static_tree, n = t.stat_desc.has_stree, s = t.stat_desc.extra_bits, o = t.stat_desc.extra_base, f = t.stat_desc.max_length, p, c, y, h, _, L, m = 0;
|
|
2283
2283
|
for (h = 0; h <= kr; h++)
|
|
2284
2284
|
e.bl_count[h] = 0;
|
|
2285
|
-
for (r[e.heap[e.heap_max] * 2 + 1] = 0, p = e.heap_max + 1; p <
|
|
2285
|
+
for (r[e.heap[e.heap_max] * 2 + 1] = 0, p = e.heap_max + 1; p < lf; p++)
|
|
2286
2286
|
c = e.heap[p], h = r[r[c * 2 + 1] * 2 + 1] + 1, h > f && (h = f, m++), r[c * 2 + 1] = h, !(c > i) && (e.bl_count[h]++, _ = 0, c >= o && (_ = s[c - o]), L = r[c * 2], e.opt_len += L * (h + _), n && (e.static_len += L * (a[c * 2 + 1] + _)));
|
|
2287
2287
|
if (m !== 0) {
|
|
2288
2288
|
do {
|
|
@@ -2295,13 +2295,13 @@ function Iu(e, t) {
|
|
|
2295
2295
|
y = e.heap[--p], !(y > i) && (r[y * 2 + 1] !== h && (e.opt_len += (h - r[y * 2 + 1]) * r[y * 2], r[y * 2 + 1] = h), c--);
|
|
2296
2296
|
}
|
|
2297
2297
|
}
|
|
2298
|
-
function
|
|
2298
|
+
function gf(e, t, r) {
|
|
2299
2299
|
var i = new Array(kr + 1), a = 0, n, s;
|
|
2300
2300
|
for (n = 1; n <= kr; n++)
|
|
2301
2301
|
i[n] = a = a + r[n - 1] << 1;
|
|
2302
2302
|
for (s = 0; s <= t; s++) {
|
|
2303
2303
|
var o = e[s * 2 + 1];
|
|
2304
|
-
o !== 0 && (e[s * 2] =
|
|
2304
|
+
o !== 0 && (e[s * 2] = _f(i[o]++, o));
|
|
2305
2305
|
}
|
|
2306
2306
|
}
|
|
2307
2307
|
function Du() {
|
|
@@ -2325,11 +2325,11 @@ function Du() {
|
|
|
2325
2325
|
Yt[e * 2 + 1] = 7, e++, n[7]++;
|
|
2326
2326
|
for (; e <= 287; )
|
|
2327
2327
|
Yt[e * 2 + 1] = 8, e++, n[8]++;
|
|
2328
|
-
for (
|
|
2329
|
-
hs[e * 2 + 1] = 5, hs[e * 2] =
|
|
2330
|
-
|
|
2328
|
+
for (gf(Yt, bs + 1, n), e = 0; e < Gr; e++)
|
|
2329
|
+
hs[e * 2 + 1] = 5, hs[e * 2] = _f(e, 5);
|
|
2330
|
+
df = new Qn(Yt, $i, Is + 1, bs, kr), hf = new Qn(hs, on, 0, Gr, kr), mf = new Qn(new Array(0), Ou, 0, fa, Cu);
|
|
2331
2331
|
}
|
|
2332
|
-
function
|
|
2332
|
+
function wf(e) {
|
|
2333
2333
|
var t;
|
|
2334
2334
|
for (t = 0; t < bs; t++)
|
|
2335
2335
|
e.dyn_ltree[t * 2] = 0;
|
|
@@ -2339,11 +2339,11 @@ function _f(e) {
|
|
|
2339
2339
|
e.bl_tree[t * 2] = 0;
|
|
2340
2340
|
e.dyn_ltree[pa * 2] = 1, e.opt_len = e.static_len = 0, e.last_lit = e.matches = 0;
|
|
2341
2341
|
}
|
|
2342
|
-
function
|
|
2342
|
+
function bf(e) {
|
|
2343
2343
|
e.bi_valid > 8 ? ks(e, e.bi_buf) : e.bi_valid > 0 && (e.pending_buf[e.pending++] = e.bi_buf), e.bi_buf = 0, e.bi_valid = 0;
|
|
2344
2344
|
}
|
|
2345
2345
|
function Hu(e, t, r, i) {
|
|
2346
|
-
|
|
2346
|
+
bf(e), ks(e, r), ks(e, ~r), xu.arraySet(e.pending_buf, e.window, t, r, e.pending), e.pending += r;
|
|
2347
2347
|
}
|
|
2348
2348
|
function Ma(e, t, r, i) {
|
|
2349
2349
|
var a = t * 2, n = r * 2;
|
|
@@ -2358,13 +2358,13 @@ function qa(e, t, r) {
|
|
|
2358
2358
|
var i, a, n = 0, s, o;
|
|
2359
2359
|
if (e.last_lit !== 0)
|
|
2360
2360
|
do
|
|
2361
|
-
i = e.pending_buf[e.d_buf + n * 2] << 8 | e.pending_buf[e.d_buf + n * 2 + 1], a = e.pending_buf[e.l_buf + n], n++, i === 0 ? jt(e, a, t) : (s = xs[a], jt(e, s + Is + 1, t), o = $i[s], o !== 0 && (a -= ca[s], pt(e, a, o)), i--, s =
|
|
2361
|
+
i = e.pending_buf[e.d_buf + n * 2] << 8 | e.pending_buf[e.d_buf + n * 2 + 1], a = e.pending_buf[e.l_buf + n], n++, i === 0 ? jt(e, a, t) : (s = xs[a], jt(e, s + Is + 1, t), o = $i[s], o !== 0 && (a -= ca[s], pt(e, a, o)), i--, s = yf(i), jt(e, s, r), o = on[s], o !== 0 && (i -= Sn[s], pt(e, i, o)));
|
|
2362
2362
|
while (n < e.last_lit);
|
|
2363
2363
|
jt(e, pa, t);
|
|
2364
2364
|
}
|
|
2365
2365
|
function Fi(e, t) {
|
|
2366
2366
|
var r = t.dyn_tree, i = t.stat_desc.static_tree, a = t.stat_desc.has_stree, n = t.stat_desc.elems, s, o, f = -1, p;
|
|
2367
|
-
for (e.heap_len = 0, e.heap_max =
|
|
2367
|
+
for (e.heap_len = 0, e.heap_max = lf, s = 0; s < n; s++)
|
|
2368
2368
|
r[s * 2] !== 0 ? (e.heap[++e.heap_len] = f = s, e.depth[s] = 0) : r[s * 2 + 1] = 0;
|
|
2369
2369
|
for (; e.heap_len < 2; )
|
|
2370
2370
|
p = e.heap[++e.heap_len] = f < 2 ? ++f : 0, r[p * 2] = 1, e.depth[p] = 0, e.opt_len--, a && (e.static_len -= i[p * 2 + 1]);
|
|
@@ -2399,12 +2399,12 @@ function Fi(e, t) {
|
|
|
2399
2399
|
e.heap[--e.heap_max] = e.heap[
|
|
2400
2400
|
1
|
|
2401
2401
|
/*SMALLEST*/
|
|
2402
|
-
], Iu(e, t),
|
|
2402
|
+
], Iu(e, t), gf(r, f, e.bl_count);
|
|
2403
2403
|
}
|
|
2404
2404
|
function Ka(e, t, r) {
|
|
2405
2405
|
var i, a = -1, n, s = t[0 * 2 + 1], o = 0, f = 7, p = 4;
|
|
2406
2406
|
for (s === 0 && (f = 138, p = 3), t[(r + 1) * 2 + 1] = 65535, i = 0; i <= r; i++)
|
|
2407
|
-
n = s, s = t[(i + 1) * 2 + 1], !(++o < f && n === s) && (o < p ? e.bl_tree[n * 2] += o : n !== 0 ? (n !== a && e.bl_tree[n * 2]++, e.bl_tree[
|
|
2407
|
+
n = s, s = t[(i + 1) * 2 + 1], !(++o < f && n === s) && (o < p ? e.bl_tree[n * 2] += o : n !== 0 ? (n !== a && e.bl_tree[n * 2]++, e.bl_tree[ff * 2]++) : o <= 10 ? e.bl_tree[pf * 2]++ : e.bl_tree[cf * 2]++, o = 0, a = n, s === 0 ? (f = 138, p = 3) : n === s ? (f = 6, p = 3) : (f = 7, p = 4));
|
|
2408
2408
|
}
|
|
2409
2409
|
function za(e, t, r) {
|
|
2410
2410
|
var i, a = -1, n, s = t[0 * 2 + 1], o = 0, f = 7, p = 4;
|
|
@@ -2414,20 +2414,20 @@ function za(e, t, r) {
|
|
|
2414
2414
|
do
|
|
2415
2415
|
jt(e, n, e.bl_tree);
|
|
2416
2416
|
while (--o !== 0);
|
|
2417
|
-
else n !== 0 ? (n !== a && (jt(e, n, e.bl_tree), o--), jt(e,
|
|
2417
|
+
else n !== 0 ? (n !== a && (jt(e, n, e.bl_tree), o--), jt(e, ff, e.bl_tree), pt(e, o - 3, 2)) : o <= 10 ? (jt(e, pf, e.bl_tree), pt(e, o - 3, 3)) : (jt(e, cf, e.bl_tree), pt(e, o - 11, 7));
|
|
2418
2418
|
o = 0, a = n, s === 0 ? (f = 138, p = 3) : n === s ? (f = 6, p = 3) : (f = 7, p = 4);
|
|
2419
2419
|
}
|
|
2420
2420
|
}
|
|
2421
2421
|
function $u(e) {
|
|
2422
2422
|
var t;
|
|
2423
|
-
for (Ka(e, e.dyn_ltree, e.l_desc.max_code), Ka(e, e.dyn_dtree, e.d_desc.max_code), Fi(e, e.bl_desc), t = fa - 1; t >= 3 && e.bl_tree[
|
|
2423
|
+
for (Ka(e, e.dyn_ltree, e.l_desc.max_code), Ka(e, e.dyn_dtree, e.d_desc.max_code), Fi(e, e.bl_desc), t = fa - 1; t >= 3 && e.bl_tree[uf[t] * 2 + 1] === 0; t--)
|
|
2424
2424
|
;
|
|
2425
2425
|
return e.opt_len += 3 * (t + 1) + 5 + 5 + 4, t;
|
|
2426
2426
|
}
|
|
2427
2427
|
function Fu(e, t, r, i) {
|
|
2428
2428
|
var a;
|
|
2429
2429
|
for (pt(e, t - 257, 5), pt(e, r - 1, 5), pt(e, i - 4, 4), a = 0; a < i; a++)
|
|
2430
|
-
pt(e, e.bl_tree[
|
|
2430
|
+
pt(e, e.bl_tree[uf[a] * 2 + 1], 3);
|
|
2431
2431
|
za(e, e.dyn_ltree, t - 1), za(e, e.dyn_dtree, r - 1);
|
|
2432
2432
|
}
|
|
2433
2433
|
function Nu(e) {
|
|
@@ -2444,23 +2444,23 @@ function Nu(e) {
|
|
|
2444
2444
|
}
|
|
2445
2445
|
var Ga = !1;
|
|
2446
2446
|
function ju(e) {
|
|
2447
|
-
Ga || (Du(), Ga = !0), e.l_desc = new ei(e.dyn_ltree,
|
|
2447
|
+
Ga || (Du(), Ga = !0), e.l_desc = new ei(e.dyn_ltree, df), e.d_desc = new ei(e.dyn_dtree, hf), e.bl_desc = new ei(e.bl_tree, mf), e.bi_buf = 0, e.bi_valid = 0, wf(e);
|
|
2448
2448
|
}
|
|
2449
|
-
function
|
|
2449
|
+
function vf(e, t, r, i) {
|
|
2450
2450
|
pt(e, (Eu << 1) + (i ? 1 : 0), 3), Hu(e, t, r);
|
|
2451
2451
|
}
|
|
2452
2452
|
function Bu(e) {
|
|
2453
|
-
pt(e,
|
|
2453
|
+
pt(e, of << 1, 3), jt(e, pa, Yt), Ru(e);
|
|
2454
2454
|
}
|
|
2455
2455
|
function Wu(e, t, r, i) {
|
|
2456
2456
|
var a, n, s = 0;
|
|
2457
|
-
e.level > 0 ? (e.strm.data_type === Su && (e.strm.data_type = Nu(e)), Fi(e, e.l_desc), Fi(e, e.d_desc), s = $u(e), a = e.opt_len + 3 + 7 >>> 3, n = e.static_len + 3 + 7 >>> 3, n <= a && (a = n)) : a = n = r + 5, r + 4 <= a && t !== -1 ?
|
|
2457
|
+
e.level > 0 ? (e.strm.data_type === Su && (e.strm.data_type = Nu(e)), Fi(e, e.l_desc), Fi(e, e.d_desc), s = $u(e), a = e.opt_len + 3 + 7 >>> 3, n = e.static_len + 3 + 7 >>> 3, n <= a && (a = n)) : a = n = r + 5, r + 4 <= a && t !== -1 ? vf(e, t, r, i) : e.strategy === ku || n === a ? (pt(e, (of << 1) + (i ? 1 : 0), 3), qa(e, Yt, hs)) : (pt(e, (Pu << 1) + (i ? 1 : 0), 3), Fu(e, e.l_desc.max_code + 1, e.d_desc.max_code + 1, s + 1), qa(e, e.dyn_ltree, e.dyn_dtree)), wf(e), i && bf(e);
|
|
2458
2458
|
}
|
|
2459
2459
|
function Uu(e, t, r) {
|
|
2460
|
-
return e.pending_buf[e.d_buf + e.last_lit * 2] = t >>> 8 & 255, e.pending_buf[e.d_buf + e.last_lit * 2 + 1] = t & 255, e.pending_buf[e.l_buf + e.last_lit] = r & 255, e.last_lit++, t === 0 ? e.dyn_ltree[r * 2]++ : (e.matches++, t--, e.dyn_ltree[(xs[r] + Is + 1) * 2]++, e.dyn_dtree[
|
|
2460
|
+
return e.pending_buf[e.d_buf + e.last_lit * 2] = t >>> 8 & 255, e.pending_buf[e.d_buf + e.last_lit * 2 + 1] = t & 255, e.pending_buf[e.l_buf + e.last_lit] = r & 255, e.last_lit++, t === 0 ? e.dyn_ltree[r * 2]++ : (e.matches++, t--, e.dyn_ltree[(xs[r] + Is + 1) * 2]++, e.dyn_dtree[yf(t) * 2]++), e.last_lit === e.lit_bufsize - 1;
|
|
2461
2461
|
}
|
|
2462
2462
|
es._tr_init = ju;
|
|
2463
|
-
es._tr_stored_block =
|
|
2463
|
+
es._tr_stored_block = vf;
|
|
2464
2464
|
es._tr_flush_block = Wu;
|
|
2465
2465
|
es._tr_tally = Uu;
|
|
2466
2466
|
es._tr_align = Bu;
|
|
@@ -2474,7 +2474,7 @@ function Mu(e, t, r, i) {
|
|
|
2474
2474
|
}
|
|
2475
2475
|
return a | n << 16 | 0;
|
|
2476
2476
|
}
|
|
2477
|
-
var
|
|
2477
|
+
var xf = Mu;
|
|
2478
2478
|
function qu() {
|
|
2479
2479
|
for (var e, t = [], r = 0; r < 256; r++) {
|
|
2480
2480
|
e = r;
|
|
@@ -2492,7 +2492,7 @@ function zu(e, t, r, i) {
|
|
|
2492
2492
|
e = e >>> 8 ^ a[(e ^ t[s]) & 255];
|
|
2493
2493
|
return e ^ -1;
|
|
2494
2494
|
}
|
|
2495
|
-
var
|
|
2495
|
+
var kf = zu, ua = {
|
|
2496
2496
|
2: "need dictionary",
|
|
2497
2497
|
/* Z_NEED_DICT 2 */
|
|
2498
2498
|
1: "stream end",
|
|
@@ -2511,7 +2511,7 @@ var vf = zu, ua = {
|
|
|
2511
2511
|
/* Z_BUF_ERROR (-5) */
|
|
2512
2512
|
"-6": "incompatible version"
|
|
2513
2513
|
/* Z_VERSION_ERROR (-6) */
|
|
2514
|
-
}, st = tr, St = es,
|
|
2514
|
+
}, st = tr, St = es, Sf = xf, or = kf, Gu = ua, Dr = 0, Zu = 1, Vu = 3, yr = 4, Za = 5, Bt = 0, Va = 1, Et = -2, Yu = -3, ri = -5, Xu = -1, Ju = 1, Us = 2, Qu = 3, ed = 4, td = 0, rd = 2, Fn = 8, sd = 9, nd = 15, id = 8, ad = 29, od = 256, Ni = od + 1 + ad, ld = 30, fd = 19, pd = 2 * Ni + 1, cd = 15, ye = 3, hr = 258, Rt = hr + ye + 1, ud = 32, Nn = 42, ji = 69, ln = 73, fn = 91, pn = 103, Sr = 113, cs = 666, Me = 1, Ds = 2, Tr = 3, rs = 4, dd = 3;
|
|
2515
2515
|
function mr(e, t) {
|
|
2516
2516
|
return e.msg = Gu[t], t;
|
|
2517
2517
|
}
|
|
@@ -2537,9 +2537,9 @@ function is(e, t) {
|
|
|
2537
2537
|
}
|
|
2538
2538
|
function hd(e, t, r, i) {
|
|
2539
2539
|
var a = e.avail_in;
|
|
2540
|
-
return a > i && (a = i), a === 0 ? 0 : (e.avail_in -= a, st.arraySet(t, e.input, e.next_in, a, r), e.state.wrap === 1 ? e.adler =
|
|
2540
|
+
return a > i && (a = i), a === 0 ? 0 : (e.avail_in -= a, st.arraySet(t, e.input, e.next_in, a, r), e.state.wrap === 1 ? e.adler = Sf(e.adler, t, a, r) : e.state.wrap === 2 && (e.adler = or(e.adler, t, a, r)), e.next_in += a, e.total_in += a, a);
|
|
2541
2541
|
}
|
|
2542
|
-
function
|
|
2542
|
+
function Ef(e, t) {
|
|
2543
2543
|
var r = e.max_chain_length, i = e.strstart, a, n, s = e.prev_length, o = e.nice_match, f = e.strstart > e.w_size - Rt ? e.strstart - (e.w_size - Rt) : 0, p = e.window, c = e.w_mask, y = e.prev, h = e.strstart + hr, _ = p[i + s - 1], L = p[i + s];
|
|
2544
2544
|
e.prev_length >= e.good_match && (r >>= 2), o > e.lookahead && (o = e.lookahead);
|
|
2545
2545
|
do
|
|
@@ -2602,7 +2602,7 @@ function si(e, t) {
|
|
|
2602
2602
|
if (e.lookahead === 0)
|
|
2603
2603
|
break;
|
|
2604
2604
|
}
|
|
2605
|
-
if (r = 0, e.lookahead >= ye && (e.ins_h = (e.ins_h << e.hash_shift ^ e.window[e.strstart + ye - 1]) & e.hash_mask, r = e.prev[e.strstart & e.w_mask] = e.head[e.ins_h], e.head[e.ins_h] = e.strstart), r !== 0 && e.strstart - r <= e.w_size - Rt && (e.match_length =
|
|
2605
|
+
if (r = 0, e.lookahead >= ye && (e.ins_h = (e.ins_h << e.hash_shift ^ e.window[e.strstart + ye - 1]) & e.hash_mask, r = e.prev[e.strstart & e.w_mask] = e.head[e.ins_h], e.head[e.ins_h] = e.strstart), r !== 0 && e.strstart - r <= e.w_size - Rt && (e.match_length = Ef(e, r)), e.match_length >= ye)
|
|
2606
2606
|
if (i = St._tr_tally(e, e.strstart - e.match_start, e.match_length - ye), e.lookahead -= e.match_length, e.match_length <= e.max_lazy_match && e.lookahead >= ye) {
|
|
2607
2607
|
e.match_length--;
|
|
2608
2608
|
do
|
|
@@ -2626,7 +2626,7 @@ function Fr(e, t) {
|
|
|
2626
2626
|
if (e.lookahead === 0)
|
|
2627
2627
|
break;
|
|
2628
2628
|
}
|
|
2629
|
-
if (r = 0, e.lookahead >= ye && (e.ins_h = (e.ins_h << e.hash_shift ^ e.window[e.strstart + ye - 1]) & e.hash_mask, r = 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 = ye - 1, r !== 0 && e.prev_length < e.max_lazy_match && e.strstart - r <= e.w_size - Rt && (e.match_length =
|
|
2629
|
+
if (r = 0, e.lookahead >= ye && (e.ins_h = (e.ins_h << e.hash_shift ^ e.window[e.strstart + ye - 1]) & e.hash_mask, r = 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 = ye - 1, r !== 0 && e.prev_length < e.max_lazy_match && e.strstart - r <= e.w_size - Rt && (e.match_length = Ef(e, r), e.match_length <= 5 && (e.strategy === Ju || e.match_length === ye && e.strstart - e.match_start > 4096) && (e.match_length = ye - 1)), e.prev_length >= ye && e.match_length <= e.prev_length) {
|
|
2630
2630
|
a = e.strstart + e.lookahead - ye, i = St._tr_tally(e, e.strstart - 1 - e.prev_match, e.prev_length - ye), e.lookahead -= e.prev_length - 1, e.prev_length -= 2;
|
|
2631
2631
|
do
|
|
2632
2632
|
++e.strstart <= a && (e.ins_h = (e.ins_h << e.hash_shift ^ e.window[e.strstart + ye - 1]) & e.hash_mask, r = e.prev[e.strstart & e.w_mask] = e.head[e.ins_h], e.head[e.ins_h] = e.strstart);
|
|
@@ -2706,18 +2706,18 @@ function gd(e) {
|
|
|
2706
2706
|
function wd() {
|
|
2707
2707
|
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 = Fn, 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 st.Buf16(pd * 2), this.dyn_dtree = new st.Buf16((2 * ld + 1) * 2), this.bl_tree = new st.Buf16((2 * fd + 1) * 2), dr(this.dyn_ltree), dr(this.dyn_dtree), dr(this.bl_tree), this.l_desc = null, this.d_desc = null, this.bl_desc = null, this.bl_count = new st.Buf16(cd + 1), this.heap = new st.Buf16(2 * Ni + 1), dr(this.heap), this.heap_len = 0, this.heap_max = 0, this.depth = new st.Buf16(2 * Ni + 1), dr(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;
|
|
2708
2708
|
}
|
|
2709
|
-
function
|
|
2709
|
+
function Pf(e) {
|
|
2710
2710
|
var t;
|
|
2711
2711
|
return !e || !e.state ? mr(e, Et) : (e.total_in = e.total_out = 0, e.data_type = rd, t = e.state, t.pending = 0, t.pending_out = 0, t.wrap < 0 && (t.wrap = -t.wrap), t.status = t.wrap ? Nn : Sr, e.adler = t.wrap === 2 ? 0 : 1, t.last_flush = Dr, St._tr_init(t), Bt);
|
|
2712
2712
|
}
|
|
2713
|
-
function
|
|
2714
|
-
var t =
|
|
2713
|
+
function Af(e) {
|
|
2714
|
+
var t = Pf(e);
|
|
2715
2715
|
return t === Bt && gd(e.state), t;
|
|
2716
2716
|
}
|
|
2717
2717
|
function bd(e, t) {
|
|
2718
2718
|
return !e || !e.state || e.state.wrap !== 2 ? Et : (e.state.gzhead = t, Bt);
|
|
2719
2719
|
}
|
|
2720
|
-
function
|
|
2720
|
+
function Tf(e, t, r, i, a, n) {
|
|
2721
2721
|
if (!e)
|
|
2722
2722
|
return Et;
|
|
2723
2723
|
var s = 1;
|
|
@@ -2725,10 +2725,10 @@ function Pf(e, t, r, i, a, n) {
|
|
|
2725
2725
|
return mr(e, Et);
|
|
2726
2726
|
i === 8 && (i = 9);
|
|
2727
2727
|
var o = new wd();
|
|
2728
|
-
return e.state = o, o.strm = e, o.wrap = s, o.gzhead = null, o.w_bits = i, o.w_size = 1 << o.w_bits, o.w_mask = o.w_size - 1, o.hash_bits = a + 7, o.hash_size = 1 << o.hash_bits, o.hash_mask = o.hash_size - 1, o.hash_shift = ~~((o.hash_bits + ye - 1) / ye), o.window = new st.Buf8(o.w_size * 2), o.head = new st.Buf16(o.hash_size), o.prev = new st.Buf16(o.w_size), o.lit_bufsize = 1 << a + 6, o.pending_buf_size = o.lit_bufsize * 4, o.pending_buf = new st.Buf8(o.pending_buf_size), o.d_buf = 1 * o.lit_bufsize, o.l_buf = 3 * o.lit_bufsize, o.level = t, o.strategy = n, o.method = r,
|
|
2728
|
+
return e.state = o, o.strm = e, o.wrap = s, o.gzhead = null, o.w_bits = i, o.w_size = 1 << o.w_bits, o.w_mask = o.w_size - 1, o.hash_bits = a + 7, o.hash_size = 1 << o.hash_bits, o.hash_mask = o.hash_size - 1, o.hash_shift = ~~((o.hash_bits + ye - 1) / ye), o.window = new st.Buf8(o.w_size * 2), o.head = new st.Buf16(o.hash_size), o.prev = new st.Buf16(o.w_size), o.lit_bufsize = 1 << a + 6, o.pending_buf_size = o.lit_bufsize * 4, o.pending_buf = new st.Buf8(o.pending_buf_size), o.d_buf = 1 * o.lit_bufsize, o.l_buf = 3 * o.lit_bufsize, o.level = t, o.strategy = n, o.method = r, Af(e);
|
|
2729
2729
|
}
|
|
2730
2730
|
function vd(e, t) {
|
|
2731
|
-
return
|
|
2731
|
+
return Tf(e, t, Fn, nd, id, td);
|
|
2732
2732
|
}
|
|
2733
2733
|
function xd(e, t) {
|
|
2734
2734
|
var r, i, a, n;
|
|
@@ -2803,7 +2803,7 @@ function Sd(e, t) {
|
|
|
2803
2803
|
var r = t.length, i, a, n, s, o, f, p, c;
|
|
2804
2804
|
if (!e || !e.state || (i = e.state, s = i.wrap, s === 2 || s === 1 && i.status !== Nn || i.lookahead))
|
|
2805
2805
|
return Et;
|
|
2806
|
-
for (s === 1 && (e.adler =
|
|
2806
|
+
for (s === 1 && (e.adler = Sf(e.adler, t, r, 0)), i.wrap = 0, r >= i.w_size && (s === 0 && (dr(i.head), i.strstart = 0, i.block_start = 0, i.insert = 0), c = new st.Buf8(i.w_size), st.arraySet(c, t, r - i.w_size, i.w_size, 0), t = c, r = i.w_size), o = e.avail_in, f = e.next_in, p = e.input, e.avail_in = r, e.next_in = 0, e.input = t, Cr(i); i.lookahead >= ye; ) {
|
|
2807
2807
|
a = i.strstart, n = i.lookahead - (ye - 1);
|
|
2808
2808
|
do
|
|
2809
2809
|
i.ins_h = (i.ins_h << i.hash_shift ^ i.window[a + ye - 1]) & i.hash_mask, i.prev[a & i.w_mask] = i.head[i.ins_h], i.head[i.ins_h] = a, a++;
|
|
@@ -2813,24 +2813,24 @@ function Sd(e, t) {
|
|
|
2813
2813
|
return i.strstart += i.lookahead, i.block_start = i.strstart, i.insert = i.lookahead, i.lookahead = 0, i.match_length = i.prev_length = ye - 1, i.match_available = 0, e.next_in = f, e.input = p, e.avail_in = o, i.wrap = s, Bt;
|
|
2814
2814
|
}
|
|
2815
2815
|
qt.deflateInit = vd;
|
|
2816
|
-
qt.deflateInit2 =
|
|
2817
|
-
qt.deflateReset =
|
|
2818
|
-
qt.deflateResetKeep =
|
|
2816
|
+
qt.deflateInit2 = Tf;
|
|
2817
|
+
qt.deflateReset = Af;
|
|
2818
|
+
qt.deflateResetKeep = Pf;
|
|
2819
2819
|
qt.deflateSetHeader = bd;
|
|
2820
2820
|
qt.deflate = xd;
|
|
2821
2821
|
qt.deflateEnd = kd;
|
|
2822
2822
|
qt.deflateSetDictionary = Sd;
|
|
2823
2823
|
qt.deflateInfo = "pako deflate (from Nodeca project)";
|
|
2824
|
-
var Hr = {}, jn = tr,
|
|
2824
|
+
var Hr = {}, jn = tr, Cf = !0, Of = !0;
|
|
2825
2825
|
try {
|
|
2826
2826
|
String.fromCharCode.apply(null, [0]);
|
|
2827
2827
|
} catch {
|
|
2828
|
-
|
|
2828
|
+
Cf = !1;
|
|
2829
2829
|
}
|
|
2830
2830
|
try {
|
|
2831
2831
|
String.fromCharCode.apply(null, new Uint8Array(1));
|
|
2832
2832
|
} catch {
|
|
2833
|
-
|
|
2833
|
+
Of = !1;
|
|
2834
2834
|
}
|
|
2835
2835
|
var Ss = new jn.Buf8(256);
|
|
2836
2836
|
for (var sr = 0; sr < 256; sr++)
|
|
@@ -2844,15 +2844,15 @@ Hr.string2buf = function(e) {
|
|
|
2844
2844
|
r = e.charCodeAt(a), (r & 64512) === 55296 && a + 1 < s && (i = e.charCodeAt(a + 1), (i & 64512) === 56320 && (r = 65536 + (r - 55296 << 10) + (i - 56320), a++)), r < 128 ? t[n++] = r : r < 2048 ? (t[n++] = 192 | r >>> 6, t[n++] = 128 | r & 63) : r < 65536 ? (t[n++] = 224 | r >>> 12, t[n++] = 128 | r >>> 6 & 63, t[n++] = 128 | r & 63) : (t[n++] = 240 | r >>> 18, t[n++] = 128 | r >>> 12 & 63, t[n++] = 128 | r >>> 6 & 63, t[n++] = 128 | r & 63);
|
|
2845
2845
|
return t;
|
|
2846
2846
|
};
|
|
2847
|
-
function
|
|
2848
|
-
if (t < 65534 && (e.subarray &&
|
|
2847
|
+
function Lf(e, t) {
|
|
2848
|
+
if (t < 65534 && (e.subarray && Of || !e.subarray && Cf))
|
|
2849
2849
|
return String.fromCharCode.apply(null, jn.shrinkBuf(e, t));
|
|
2850
2850
|
for (var r = "", i = 0; i < t; i++)
|
|
2851
2851
|
r += String.fromCharCode(e[i]);
|
|
2852
2852
|
return r;
|
|
2853
2853
|
}
|
|
2854
2854
|
Hr.buf2binstring = function(e) {
|
|
2855
|
-
return
|
|
2855
|
+
return Lf(e, e.length);
|
|
2856
2856
|
};
|
|
2857
2857
|
Hr.binstring2buf = function(e) {
|
|
2858
2858
|
for (var t = new jn.Buf8(e.length), r = 0, i = t.length; r < i; r++)
|
|
@@ -2878,7 +2878,7 @@ Hr.buf2string = function(e, t) {
|
|
|
2878
2878
|
}
|
|
2879
2879
|
a < 65536 ? o[i++] = a : (a -= 65536, o[i++] = 55296 | a >> 10 & 1023, o[i++] = 56320 | a & 1023);
|
|
2880
2880
|
}
|
|
2881
|
-
return
|
|
2881
|
+
return Lf(o, i);
|
|
2882
2882
|
};
|
|
2883
2883
|
Hr.utf8border = function(e, t) {
|
|
2884
2884
|
var r;
|
|
@@ -2889,7 +2889,7 @@ Hr.utf8border = function(e, t) {
|
|
|
2889
2889
|
function Ed() {
|
|
2890
2890
|
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;
|
|
2891
2891
|
}
|
|
2892
|
-
var
|
|
2892
|
+
var Rf = Ed, ms = qt, ys = tr, Bi = Hr, Wi = ua, Pd = Rf, If = Object.prototype.toString, Ad = 0, ni = 4, Zr = 0, Xa = 1, Ja = 2, Td = -1, Cd = 0, Od = 8;
|
|
2893
2893
|
function Or(e) {
|
|
2894
2894
|
if (!(this instanceof Or)) return new Or(e);
|
|
2895
2895
|
this.options = ys.assign({
|
|
@@ -2915,7 +2915,7 @@ function Or(e) {
|
|
|
2915
2915
|
throw new Error(Wi[r]);
|
|
2916
2916
|
if (t.header && ms.deflateSetHeader(this.strm, t.header), t.dictionary) {
|
|
2917
2917
|
var i;
|
|
2918
|
-
if (typeof t.dictionary == "string" ? i = Bi.string2buf(t.dictionary) :
|
|
2918
|
+
if (typeof t.dictionary == "string" ? i = Bi.string2buf(t.dictionary) : If.call(t.dictionary) === "[object ArrayBuffer]" ? i = new Uint8Array(t.dictionary) : i = t.dictionary, r = ms.deflateSetDictionary(this.strm, i), r !== Zr)
|
|
2919
2919
|
throw new Error(Wi[r]);
|
|
2920
2920
|
this._dict_set = !0;
|
|
2921
2921
|
}
|
|
@@ -2924,7 +2924,7 @@ Or.prototype.push = function(e, t) {
|
|
|
2924
2924
|
var r = this.strm, i = this.options.chunkSize, a, n;
|
|
2925
2925
|
if (this.ended)
|
|
2926
2926
|
return !1;
|
|
2927
|
-
n = t === ~~t ? t : t === !0 ? ni : Ad, typeof e == "string" ? r.input = Bi.string2buf(e) :
|
|
2927
|
+
n = t === ~~t ? t : t === !0 ? ni : Ad, typeof e == "string" ? r.input = Bi.string2buf(e) : If.call(e) === "[object ArrayBuffer]" ? r.input = new Uint8Array(e) : r.input = e, r.next_in = 0, r.avail_in = r.input.length;
|
|
2928
2928
|
do {
|
|
2929
2929
|
if (r.avail_out === 0 && (r.output = new ys.Buf8(i), r.next_out = 0, r.avail_out = i), a = ms.deflate(r, n), a !== Xa && a !== Zr)
|
|
2930
2930
|
return this.onEnd(a), this.ended = !0, !1;
|
|
@@ -3220,31 +3220,31 @@ var Hs = {}, It = {}, Ms = 30, Id = 12, Dd = function(t, r) {
|
|
|
3220
3220
|
}
|
|
3221
3221
|
}
|
|
3222
3222
|
return O !== 0 && (n[P + O] = c - g << 24 | 64 << 16 | 0), f.bits = L, 0;
|
|
3223
|
-
}, gt = tr, Ui =
|
|
3223
|
+
}, gt = tr, Ui = xf, $t = kf, Bd = Dd, _s = jd, Wd = 0, Df = 1, Hf = 2, no = 4, Ud = 5, qs = 6, Lr = 0, Md = 1, qd = 2, Pt = -2, $f = -3, Ff = -4, Kd = -5, io = 8, Nf = 1, ao = 2, oo = 3, lo = 4, fo = 5, po = 6, co = 7, uo = 8, ho = 9, mo = 10, En = 11, Gt = 12, ai = 13, yo = 14, oi = 15, _o = 16, go = 17, wo = 18, bo = 19, Ks = 20, zs = 21, vo = 22, xo = 23, ko = 24, So = 25, Eo = 26, li = 27, Po = 28, Ao = 29, De = 30, jf = 31, zd = 32, Gd = 852, Zd = 592, Vd = 15, Yd = Vd;
|
|
3224
3224
|
function To(e) {
|
|
3225
3225
|
return (e >>> 24 & 255) + (e >>> 8 & 65280) + ((e & 65280) << 8) + ((e & 255) << 24);
|
|
3226
3226
|
}
|
|
3227
3227
|
function Xd() {
|
|
3228
3228
|
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 gt.Buf16(320), this.work = new gt.Buf16(288), this.lendyn = null, this.distdyn = null, this.sane = 0, this.back = 0, this.was = 0;
|
|
3229
3229
|
}
|
|
3230
|
-
function
|
|
3230
|
+
function Bf(e) {
|
|
3231
3231
|
var t;
|
|
3232
|
-
return !e || !e.state ? Pt : (t = e.state, e.total_in = e.total_out = t.total = 0, e.msg = "", t.wrap && (e.adler = t.wrap & 1), t.mode =
|
|
3232
|
+
return !e || !e.state ? Pt : (t = e.state, e.total_in = e.total_out = t.total = 0, e.msg = "", t.wrap && (e.adler = t.wrap & 1), t.mode = Nf, t.last = 0, t.havedict = 0, t.dmax = 32768, t.head = null, t.hold = 0, t.bits = 0, t.lencode = t.lendyn = new gt.Buf32(Gd), t.distcode = t.distdyn = new gt.Buf32(Zd), t.sane = 1, t.back = -1, Lr);
|
|
3233
3233
|
}
|
|
3234
|
-
function
|
|
3234
|
+
function Wf(e) {
|
|
3235
3235
|
var t;
|
|
3236
|
-
return !e || !e.state ? Pt : (t = e.state, t.wsize = 0, t.whave = 0, t.wnext = 0,
|
|
3236
|
+
return !e || !e.state ? Pt : (t = e.state, t.wsize = 0, t.whave = 0, t.wnext = 0, Bf(e));
|
|
3237
3237
|
}
|
|
3238
|
-
function
|
|
3238
|
+
function Uf(e, t) {
|
|
3239
3239
|
var r, i;
|
|
3240
|
-
return !e || !e.state || (i = e.state, t < 0 ? (r = 0, t = -t) : (r = (t >> 4) + 1, t < 48 && (t &= 15)), t && (t < 8 || t > 15)) ? Pt : (i.window !== null && i.wbits !== t && (i.window = null), i.wrap = r, i.wbits = t,
|
|
3240
|
+
return !e || !e.state || (i = e.state, t < 0 ? (r = 0, t = -t) : (r = (t >> 4) + 1, t < 48 && (t &= 15)), t && (t < 8 || t > 15)) ? Pt : (i.window !== null && i.wbits !== t && (i.window = null), i.wrap = r, i.wbits = t, Wf(e));
|
|
3241
3241
|
}
|
|
3242
|
-
function
|
|
3242
|
+
function Mf(e, t) {
|
|
3243
3243
|
var r, i;
|
|
3244
|
-
return e ? (i = new Xd(), e.state = i, i.window = null, r =
|
|
3244
|
+
return e ? (i = new Xd(), e.state = i, i.window = null, r = Uf(e, t), r !== Lr && (e.state = null), r) : Pt;
|
|
3245
3245
|
}
|
|
3246
3246
|
function Jd(e) {
|
|
3247
|
-
return
|
|
3247
|
+
return Mf(e, Yd);
|
|
3248
3248
|
}
|
|
3249
3249
|
var Co = !0, fi, pi;
|
|
3250
3250
|
function Qd(e) {
|
|
@@ -3258,13 +3258,13 @@ function Qd(e) {
|
|
|
3258
3258
|
e.lens[t++] = 7;
|
|
3259
3259
|
for (; t < 288; )
|
|
3260
3260
|
e.lens[t++] = 8;
|
|
3261
|
-
for (_s(
|
|
3261
|
+
for (_s(Df, e.lens, 0, 288, fi, 0, e.work, { bits: 9 }), t = 0; t < 32; )
|
|
3262
3262
|
e.lens[t++] = 5;
|
|
3263
|
-
_s(
|
|
3263
|
+
_s(Hf, e.lens, 0, 32, pi, 0, e.work, { bits: 5 }), Co = !1;
|
|
3264
3264
|
}
|
|
3265
3265
|
e.lencode = fi, e.lenbits = 9, e.distcode = pi, e.distbits = 5;
|
|
3266
3266
|
}
|
|
3267
|
-
function
|
|
3267
|
+
function qf(e, t, r, i) {
|
|
3268
3268
|
var a, n = e.state;
|
|
3269
3269
|
return n.window === null && (n.wsize = 1 << n.wbits, n.wnext = 0, n.whave = 0, n.window = new gt.Buf8(n.wsize)), i >= n.wsize ? (gt.arraySet(n.window, t, r - n.wsize, n.wsize, 0), n.wnext = 0, n.whave = n.wsize) : (a = n.wsize - n.wnext, a > i && (a = i), gt.arraySet(n.window, t, r - i, a, n.wnext), i -= a, i ? (gt.arraySet(n.window, t, r - i, i, 0), n.wnext = i, n.whave = n.wsize) : (n.wnext += a, n.wnext === n.wsize && (n.wnext = 0), n.whave < n.wsize && (n.whave += a))), 0;
|
|
3270
3270
|
}
|
|
@@ -3279,7 +3279,7 @@ function eh(e, t) {
|
|
|
3279
3279
|
e:
|
|
3280
3280
|
for (; ; )
|
|
3281
3281
|
switch (r.mode) {
|
|
3282
|
-
case
|
|
3282
|
+
case Nf:
|
|
3283
3283
|
if (r.wrap === 0) {
|
|
3284
3284
|
r.mode = ai;
|
|
3285
3285
|
break;
|
|
@@ -3543,11 +3543,11 @@ function eh(e, t) {
|
|
|
3543
3543
|
e.msg = "invalid code -- missing end-of-block", r.mode = De;
|
|
3544
3544
|
break;
|
|
3545
3545
|
}
|
|
3546
|
-
if (r.lenbits = 9, k = { bits: r.lenbits }, P = _s(
|
|
3546
|
+
if (r.lenbits = 9, k = { bits: r.lenbits }, P = _s(Df, r.lens, 0, r.nlen, r.lencode, 0, r.work, k), r.lenbits = k.bits, P) {
|
|
3547
3547
|
e.msg = "invalid literal/lengths set", r.mode = De;
|
|
3548
3548
|
break;
|
|
3549
3549
|
}
|
|
3550
|
-
if (r.distbits = 6, r.distcode = r.distdyn, k = { bits: r.distbits }, P = _s(
|
|
3550
|
+
if (r.distbits = 6, r.distcode = r.distdyn, k = { bits: r.distbits }, P = _s(Hf, r.lens, r.nlen, r.ndist, r.distcode, 0, r.work, k), r.distbits = k.bits, P) {
|
|
3551
3551
|
e.msg = "invalid distances set", r.mode = De;
|
|
3552
3552
|
break;
|
|
3553
3553
|
}
|
|
@@ -3684,15 +3684,15 @@ function eh(e, t) {
|
|
|
3684
3684
|
P = Md;
|
|
3685
3685
|
break e;
|
|
3686
3686
|
case De:
|
|
3687
|
-
P =
|
|
3687
|
+
P = $f;
|
|
3688
3688
|
break e;
|
|
3689
|
-
case
|
|
3690
|
-
return
|
|
3689
|
+
case jf:
|
|
3690
|
+
return Ff;
|
|
3691
3691
|
case zd:
|
|
3692
3692
|
default:
|
|
3693
3693
|
return Pt;
|
|
3694
3694
|
}
|
|
3695
|
-
return e.next_out = s, e.avail_out = f, e.next_in = n, e.avail_in = o, r.hold = p, r.bits = c, (r.wsize || h !== e.avail_out && r.mode < De && (r.mode < li || t !== no)) &&
|
|
3695
|
+
return e.next_out = s, e.avail_out = f, e.next_in = n, e.avail_in = o, r.hold = p, r.bits = c, (r.wsize || h !== e.avail_out && r.mode < De && (r.mode < li || t !== no)) && qf(e, e.output, e.next_out, h - e.avail_out), y -= e.avail_in, h -= e.avail_out, e.total_in += y, e.total_out += h, r.total += h, r.wrap && h && (e.adler = r.check = /*UPDATE(state.check, strm.next_out - _out, _out);*/
|
|
3696
3696
|
r.flags ? $t(r.check, a, h, e.next_out - h) : Ui(r.check, a, h, e.next_out - h)), e.data_type = r.bits + (r.last ? 64 : 0) + (r.mode === Gt ? 128 : 0) + (r.mode === Ks || r.mode === oi ? 256 : 0), (y === 0 && h === 0 || t === no) && P === Lr && (P = Kd), P;
|
|
3697
3697
|
}
|
|
3698
3698
|
function th(e) {
|
|
@@ -3707,19 +3707,19 @@ function rh(e, t) {
|
|
|
3707
3707
|
}
|
|
3708
3708
|
function sh(e, t) {
|
|
3709
3709
|
var r = t.length, i, a, n;
|
|
3710
|
-
return !e || !e.state || (i = e.state, i.wrap !== 0 && i.mode !== En) ? Pt : i.mode === En && (a = 1, a = Ui(a, t, r, 0), a !== i.check) ?
|
|
3710
|
+
return !e || !e.state || (i = e.state, i.wrap !== 0 && i.mode !== En) ? Pt : i.mode === En && (a = 1, a = Ui(a, t, r, 0), a !== i.check) ? $f : (n = qf(e, t, r, r), n ? (i.mode = jf, Ff) : (i.havedict = 1, Lr));
|
|
3711
3711
|
}
|
|
3712
|
-
It.inflateReset =
|
|
3713
|
-
It.inflateReset2 =
|
|
3714
|
-
It.inflateResetKeep =
|
|
3712
|
+
It.inflateReset = Wf;
|
|
3713
|
+
It.inflateReset2 = Uf;
|
|
3714
|
+
It.inflateResetKeep = Bf;
|
|
3715
3715
|
It.inflateInit = Jd;
|
|
3716
|
-
It.inflateInit2 =
|
|
3716
|
+
It.inflateInit2 = Mf;
|
|
3717
3717
|
It.inflate = eh;
|
|
3718
3718
|
It.inflateEnd = th;
|
|
3719
3719
|
It.inflateGetHeader = rh;
|
|
3720
3720
|
It.inflateSetDictionary = sh;
|
|
3721
3721
|
It.inflateInfo = "pako inflate (from Nodeca project)";
|
|
3722
|
-
var
|
|
3722
|
+
var Kf = {
|
|
3723
3723
|
/* Allowed flush values; see deflate() and inflate() below for details */
|
|
3724
3724
|
Z_NO_FLUSH: 0,
|
|
3725
3725
|
Z_PARTIAL_FLUSH: 1,
|
|
@@ -3762,7 +3762,7 @@ var Mf = {
|
|
|
3762
3762
|
function nh() {
|
|
3763
3763
|
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;
|
|
3764
3764
|
}
|
|
3765
|
-
var ih = nh, Vr = It, gs = tr, cn = Hr, Ne =
|
|
3765
|
+
var ih = nh, Vr = It, gs = tr, cn = Hr, Ne = Kf, Mi = ua, ah = Rf, oh = ih, zf = Object.prototype.toString;
|
|
3766
3766
|
function Rr(e) {
|
|
3767
3767
|
if (!(this instanceof Rr)) return new Rr(e);
|
|
3768
3768
|
this.options = gs.assign({
|
|
@@ -3778,14 +3778,14 @@ function Rr(e) {
|
|
|
3778
3778
|
);
|
|
3779
3779
|
if (r !== Ne.Z_OK)
|
|
3780
3780
|
throw new Error(Mi[r]);
|
|
3781
|
-
if (this.header = new oh(), Vr.inflateGetHeader(this.strm, this.header), t.dictionary && (typeof t.dictionary == "string" ? t.dictionary = cn.string2buf(t.dictionary) :
|
|
3781
|
+
if (this.header = new oh(), Vr.inflateGetHeader(this.strm, this.header), t.dictionary && (typeof t.dictionary == "string" ? t.dictionary = cn.string2buf(t.dictionary) : zf.call(t.dictionary) === "[object ArrayBuffer]" && (t.dictionary = new Uint8Array(t.dictionary)), t.raw && (r = Vr.inflateSetDictionary(this.strm, t.dictionary), r !== Ne.Z_OK)))
|
|
3782
3782
|
throw new Error(Mi[r]);
|
|
3783
3783
|
}
|
|
3784
3784
|
Rr.prototype.push = function(e, t) {
|
|
3785
3785
|
var r = this.strm, i = this.options.chunkSize, a = this.options.dictionary, n, s, o, f, p, c = !1;
|
|
3786
3786
|
if (this.ended)
|
|
3787
3787
|
return !1;
|
|
3788
|
-
s = t === ~~t ? t : t === !0 ? Ne.Z_FINISH : Ne.Z_NO_FLUSH, typeof e == "string" ? r.input = cn.binstring2buf(e) :
|
|
3788
|
+
s = t === ~~t ? t : t === !0 ? Ne.Z_FINISH : Ne.Z_NO_FLUSH, typeof e == "string" ? r.input = cn.binstring2buf(e) : zf.call(e) === "[object ArrayBuffer]" ? r.input = new Uint8Array(e) : r.input = e, r.next_in = 0, r.avail_in = r.input.length;
|
|
3789
3789
|
do {
|
|
3790
3790
|
if (r.avail_out === 0 && (r.output = new gs.Buf8(i), r.next_out = 0, r.avail_out = i), n = Vr.inflate(r, Ne.Z_NO_FLUSH), n === Ne.Z_NEED_DICT && a && (n = Vr.inflateSetDictionary(this.strm, a)), n === Ne.Z_BUF_ERROR && c === !0 && (n = Ne.Z_OK, c = !1), n !== Ne.Z_STREAM_END && n !== Ne.Z_OK)
|
|
3791
3791
|
return this.onEnd(n), this.ended = !0, !1;
|
|
@@ -3812,12 +3812,12 @@ Hs.Inflate = Rr;
|
|
|
3812
3812
|
Hs.inflate = ha;
|
|
3813
3813
|
Hs.inflateRaw = lh;
|
|
3814
3814
|
Hs.ungzip = ha;
|
|
3815
|
-
var fh = tr.assign, ph = Rs, ch = Hs, uh =
|
|
3816
|
-
fh(
|
|
3817
|
-
var dh =
|
|
3818
|
-
const
|
|
3815
|
+
var fh = tr.assign, ph = Rs, ch = Hs, uh = Kf, Gf = {};
|
|
3816
|
+
fh(Gf, ph, ch, uh);
|
|
3817
|
+
var dh = Gf;
|
|
3818
|
+
const Zf = /* @__PURE__ */ ta(dh);
|
|
3819
3819
|
async function hh(e, t) {
|
|
3820
|
-
const r = new
|
|
3820
|
+
const r = new rf(e);
|
|
3821
3821
|
let i = await r.read(4);
|
|
3822
3822
|
if (i = i.toString("utf8"), i !== "PACK")
|
|
3823
3823
|
throw new $e(`Invalid PACK header '${i}'`);
|
|
@@ -3827,7 +3827,7 @@ async function hh(e, t) {
|
|
|
3827
3827
|
let n = await r.read(4);
|
|
3828
3828
|
if (n = n.readUInt32BE(0), !(n < 1))
|
|
3829
3829
|
for (; !r.eof() && n--; ) {
|
|
3830
|
-
const s = r.tell(), { type: o, length: f, ofs: p, reference: c } = await mh(r), y = new
|
|
3830
|
+
const s = r.tell(), { type: o, length: f, ofs: p, reference: c } = await mh(r), y = new Zf.Inflate();
|
|
3831
3831
|
for (; !y.result; ) {
|
|
3832
3832
|
const h = await r.chunk();
|
|
3833
3833
|
if (!h) break;
|
|
@@ -3876,7 +3876,7 @@ async function mh(e) {
|
|
|
3876
3876
|
return r === 7 && (n = await e.read(20)), { type: r, length: i, ofs: a, reference: n };
|
|
3877
3877
|
}
|
|
3878
3878
|
async function yh(e) {
|
|
3879
|
-
return
|
|
3879
|
+
return Zf.inflate(e);
|
|
3880
3880
|
}
|
|
3881
3881
|
var qi = { exports: {} };
|
|
3882
3882
|
typeof Object.create == "function" ? qi.exports = function(t, r) {
|
|
@@ -3905,7 +3905,7 @@ for (var jr = 0, wh = ci.length; jr < wh; ++jr)
|
|
|
3905
3905
|
Wt[jr] = ci[jr], xt[ci.charCodeAt(jr)] = jr;
|
|
3906
3906
|
xt[45] = 62;
|
|
3907
3907
|
xt[95] = 63;
|
|
3908
|
-
function
|
|
3908
|
+
function Vf(e) {
|
|
3909
3909
|
var t = e.length;
|
|
3910
3910
|
if (t % 4 > 0)
|
|
3911
3911
|
throw new Error("Invalid string. Length must be a multiple of 4");
|
|
@@ -3915,14 +3915,14 @@ function Gf(e) {
|
|
|
3915
3915
|
return [r, i];
|
|
3916
3916
|
}
|
|
3917
3917
|
function bh(e) {
|
|
3918
|
-
var t =
|
|
3918
|
+
var t = Vf(e), r = t[0], i = t[1];
|
|
3919
3919
|
return (r + i) * 3 / 4 - i;
|
|
3920
3920
|
}
|
|
3921
3921
|
function vh(e, t, r) {
|
|
3922
3922
|
return (t + r) * 3 / 4 - r;
|
|
3923
3923
|
}
|
|
3924
3924
|
function xh(e) {
|
|
3925
|
-
var t, r =
|
|
3925
|
+
var t, r = Vf(e), i = r[0], a = r[1], n = new gh(vh(e, i, a)), s = 0, o = a > 0 ? i - 4 : i, f;
|
|
3926
3926
|
for (f = 0; f < o; f += 4)
|
|
3927
3927
|
t = xt[e.charCodeAt(f)] << 18 | xt[e.charCodeAt(f + 1)] << 12 | xt[e.charCodeAt(f + 2)] << 6 | xt[e.charCodeAt(f + 3)], n[s++] = t >> 16 & 255, n[s++] = t >> 8 & 255, n[s++] = t & 255;
|
|
3928
3928
|
return a === 2 && (t = xt[e.charCodeAt(f)] << 2 | xt[e.charCodeAt(f + 1)] >> 4, n[s++] = t & 255), a === 1 && (t = xt[e.charCodeAt(f)] << 10 | xt[e.charCodeAt(f + 1)] << 4 | xt[e.charCodeAt(f + 2)] >> 2, n[s++] = t >> 8 & 255, n[s++] = t & 255), n;
|
|
@@ -4195,7 +4195,7 @@ ma.write = function(e, t, r, i, a, n) {
|
|
|
4195
4195
|
return d;
|
|
4196
4196
|
case "utf8":
|
|
4197
4197
|
case "utf-8":
|
|
4198
|
-
return
|
|
4198
|
+
return Ae(v).length;
|
|
4199
4199
|
case "ucs2":
|
|
4200
4200
|
case "ucs-2":
|
|
4201
4201
|
case "utf16le":
|
|
@@ -4207,7 +4207,7 @@ ma.write = function(e, t, r, i, a, n) {
|
|
|
4207
4207
|
return bt(v).length;
|
|
4208
4208
|
default:
|
|
4209
4209
|
if (N)
|
|
4210
|
-
return T ? -1 :
|
|
4210
|
+
return T ? -1 : Ae(v).length;
|
|
4211
4211
|
u = ("" + u).toLowerCase(), N = !0;
|
|
4212
4212
|
}
|
|
4213
4213
|
}
|
|
@@ -4360,7 +4360,7 @@ ma.write = function(e, t, r, i, a, n) {
|
|
|
4360
4360
|
return X;
|
|
4361
4361
|
}
|
|
4362
4362
|
function C(v, u, d, T) {
|
|
4363
|
-
return Re(
|
|
4363
|
+
return Re(Ae(u, v.length - d), v, d, T);
|
|
4364
4364
|
}
|
|
4365
4365
|
function k(v, u, d, T) {
|
|
4366
4366
|
return Re(Ve(u), v, d, T);
|
|
@@ -4673,7 +4673,7 @@ ma.write = function(e, t, r, i, a, n) {
|
|
|
4673
4673
|
v = v + "=";
|
|
4674
4674
|
return v;
|
|
4675
4675
|
}
|
|
4676
|
-
function
|
|
4676
|
+
function Ae(v, u) {
|
|
4677
4677
|
u = u || 1 / 0;
|
|
4678
4678
|
for (var d, T = v.length, N = null, K = [], X = 0; X < T; ++X) {
|
|
4679
4679
|
if (d = v.charCodeAt(X), d > 55295 && d < 57344) {
|
|
@@ -4784,12 +4784,12 @@ ma.write = function(e, t, r, i, a, n) {
|
|
|
4784
4784
|
return r.SlowBuffer(s);
|
|
4785
4785
|
};
|
|
4786
4786
|
})(Ki, Ki.exports);
|
|
4787
|
-
var
|
|
4787
|
+
var Yf = Ki.exports, Xf = Yf.Buffer;
|
|
4788
4788
|
function Wn(e, t) {
|
|
4789
|
-
this._block =
|
|
4789
|
+
this._block = Xf.alloc(e), this._finalSize = t, this._blockSize = e, this._len = 0;
|
|
4790
4790
|
}
|
|
4791
4791
|
Wn.prototype.update = function(e, t) {
|
|
4792
|
-
typeof e == "string" && (t = t || "utf8", e =
|
|
4792
|
+
typeof e == "string" && (t = t || "utf8", e = Xf.from(e, t));
|
|
4793
4793
|
for (var r = this._block, i = this._blockSize, a = e.length, n = this._len, s = 0; s < a; ) {
|
|
4794
4794
|
for (var o = n % i, f = Math.min(a - s, i - o), p = 0; p < f; p++)
|
|
4795
4795
|
r[o + p] = e[s + p];
|
|
@@ -4814,16 +4814,16 @@ Wn.prototype.digest = function(e) {
|
|
|
4814
4814
|
Wn.prototype._update = function() {
|
|
4815
4815
|
throw new Error("_update must be implemented by subclass");
|
|
4816
4816
|
};
|
|
4817
|
-
var Ph = Wn, Ah = _h,
|
|
4817
|
+
var Ph = Wn, Ah = _h, Jf = Ph, Th = Yf.Buffer, Ch = [
|
|
4818
4818
|
1518500249,
|
|
4819
4819
|
1859775393,
|
|
4820
4820
|
-1894007588,
|
|
4821
4821
|
-899497514
|
|
4822
4822
|
], Oh = new Array(80);
|
|
4823
4823
|
function $s() {
|
|
4824
|
-
this.init(), this._w = Oh,
|
|
4824
|
+
this.init(), this._w = Oh, Jf.call(this, 64, 56);
|
|
4825
4825
|
}
|
|
4826
|
-
Ah($s,
|
|
4826
|
+
Ah($s, Jf);
|
|
4827
4827
|
$s.prototype.init = function() {
|
|
4828
4828
|
return this._a = 1732584193, this._b = 4023233417, this._c = 2562383102, this._d = 271733878, this._e = 3285377520, this;
|
|
4829
4829
|
};
|
|
@@ -4862,18 +4862,18 @@ function Fh(e) {
|
|
|
4862
4862
|
}
|
|
4863
4863
|
let ui = null;
|
|
4864
4864
|
async function Oo(e) {
|
|
4865
|
-
return ui === null && (ui = await jh()), ui ?
|
|
4865
|
+
return ui === null && (ui = await jh()), ui ? Qf(e) : Nh(e);
|
|
4866
4866
|
}
|
|
4867
4867
|
function Nh(e) {
|
|
4868
4868
|
return new $h().update(e).digest("hex");
|
|
4869
4869
|
}
|
|
4870
|
-
async function
|
|
4870
|
+
async function Qf(e) {
|
|
4871
4871
|
const t = await crypto.subtle.digest("SHA-1", e);
|
|
4872
4872
|
return Fh(t);
|
|
4873
4873
|
}
|
|
4874
4874
|
async function jh() {
|
|
4875
4875
|
try {
|
|
4876
|
-
if (await
|
|
4876
|
+
if (await Qf(new Uint8Array([])) === "da39a3ee5e6b4b0d3255bfef95601890afd80709") return !0;
|
|
4877
4877
|
} catch {
|
|
4878
4878
|
}
|
|
4879
4879
|
return !1;
|
|
@@ -5103,8 +5103,8 @@ class Un extends Qr {
|
|
|
5103
5103
|
}
|
|
5104
5104
|
}
|
|
5105
5105
|
Un.code = "ObjectTypeError";
|
|
5106
|
-
async function
|
|
5107
|
-
const r =
|
|
5106
|
+
async function ep(e, t) {
|
|
5107
|
+
const r = tf(e);
|
|
5108
5108
|
for (; ; ) {
|
|
5109
5109
|
const { value: i, done: a } = await r.next();
|
|
5110
5110
|
if (i && await t(i), a) break;
|
|
@@ -5114,7 +5114,7 @@ async function Jf(e, t) {
|
|
|
5114
5114
|
async function As(e) {
|
|
5115
5115
|
let t = 0;
|
|
5116
5116
|
const r = [];
|
|
5117
|
-
await
|
|
5117
|
+
await ep(e, (n) => {
|
|
5118
5118
|
r.push(n), t += n.byteLength;
|
|
5119
5119
|
});
|
|
5120
5120
|
const i = new Uint8Array(t);
|
|
@@ -5261,11 +5261,11 @@ class Uh {
|
|
|
5261
5261
|
// return output
|
|
5262
5262
|
// }
|
|
5263
5263
|
}
|
|
5264
|
-
async function
|
|
5264
|
+
async function tp(e) {
|
|
5265
5265
|
const { packetlines: t, packfile: r, progress: i } = Uh.demux(e), a = [], n = [], s = [];
|
|
5266
5266
|
let o = !1, f = !1;
|
|
5267
5267
|
return new Promise((p, c) => {
|
|
5268
|
-
|
|
5268
|
+
ep(t, (y) => {
|
|
5269
5269
|
const h = y.toString("utf8").trim();
|
|
5270
5270
|
if (h.startsWith("shallow")) {
|
|
5271
5271
|
const _ = h.slice(-41).trim();
|
|
@@ -5285,13 +5285,13 @@ async function Qf(e) {
|
|
|
5285
5285
|
}
|
|
5286
5286
|
typeof window < "u" && (window.Buffer = er.Buffer);
|
|
5287
5287
|
async function Mh(e, t, r) {
|
|
5288
|
-
const i = await
|
|
5288
|
+
const i = await sp(e, t), a = await Zh(i, t, r), n = await Vh(
|
|
5289
5289
|
e,
|
|
5290
5290
|
r.map((o) => a[o].oid)
|
|
5291
5291
|
), s = {};
|
|
5292
5292
|
return await Promise.all(
|
|
5293
5293
|
r.map(async (o) => {
|
|
5294
|
-
s[o] = await
|
|
5294
|
+
s[o] = await np(
|
|
5295
5295
|
n,
|
|
5296
5296
|
a[o].oid
|
|
5297
5297
|
);
|
|
@@ -5299,8 +5299,8 @@ async function Mh(e, t, r) {
|
|
|
5299
5299
|
), s;
|
|
5300
5300
|
}
|
|
5301
5301
|
async function qh(e, t) {
|
|
5302
|
-
const r = await
|
|
5303
|
-
return i != null && i.object ?
|
|
5302
|
+
const r = await sp(e, t), i = await Gh(r, t);
|
|
5303
|
+
return i != null && i.object ? rp(i) : [];
|
|
5304
5304
|
}
|
|
5305
5305
|
async function Kh(e, t) {
|
|
5306
5306
|
switch ((t.type === "infer" || t.type === void 0) && (["", "HEAD"].includes(t.value) ? t = {
|
|
@@ -5325,7 +5325,7 @@ async function Kh(e, t) {
|
|
|
5325
5325
|
throw new Error(`Invalid ref type: ${t.type}`);
|
|
5326
5326
|
}
|
|
5327
5327
|
}
|
|
5328
|
-
function
|
|
5328
|
+
function rp(e) {
|
|
5329
5329
|
return e.object.map((t) => {
|
|
5330
5330
|
if (t.type === "blob")
|
|
5331
5331
|
return {
|
|
@@ -5336,7 +5336,7 @@ function ep(e) {
|
|
|
5336
5336
|
return {
|
|
5337
5337
|
name: t.path,
|
|
5338
5338
|
type: "folder",
|
|
5339
|
-
children:
|
|
5339
|
+
children: rp(t)
|
|
5340
5340
|
};
|
|
5341
5341
|
}).filter((t) => !!(t != null && t.name));
|
|
5342
5342
|
}
|
|
@@ -5372,7 +5372,7 @@ async function zh(e, t) {
|
|
|
5372
5372
|
}
|
|
5373
5373
|
return a;
|
|
5374
5374
|
}
|
|
5375
|
-
async function
|
|
5375
|
+
async function sp(e, t) {
|
|
5376
5376
|
const r = er.Buffer.from(
|
|
5377
5377
|
await As([
|
|
5378
5378
|
Ze.encode(
|
|
@@ -5399,7 +5399,7 @@ async function tp(e, t) {
|
|
|
5399
5399
|
"Content-Length": `${r.length}`
|
|
5400
5400
|
},
|
|
5401
5401
|
body: r
|
|
5402
|
-
}), a =
|
|
5402
|
+
}), a = ip(i.body), n = await tp(a), s = er.Buffer.from(await As(n.packfile)), o = await Es.fromPack({
|
|
5403
5403
|
pack: s
|
|
5404
5404
|
}), f = o.read;
|
|
5405
5405
|
return o.read = async function({ oid: p, ...c }) {
|
|
@@ -5474,12 +5474,12 @@ async function Vh(e, t) {
|
|
|
5474
5474
|
"Content-Length": `${r.length}`
|
|
5475
5475
|
},
|
|
5476
5476
|
body: r
|
|
5477
|
-
}), a =
|
|
5477
|
+
}), a = ip(i.body), n = await tp(a), s = er.Buffer.from(await As(n.packfile));
|
|
5478
5478
|
return await Es.fromPack({
|
|
5479
5479
|
pack: s
|
|
5480
5480
|
});
|
|
5481
5481
|
}
|
|
5482
|
-
async function
|
|
5482
|
+
async function np(e, t) {
|
|
5483
5483
|
const r = await e.read({ oid: t });
|
|
5484
5484
|
if (Er(r), r.type === "blob")
|
|
5485
5485
|
return r.object;
|
|
@@ -5488,7 +5488,7 @@ async function rp(e, t) {
|
|
|
5488
5488
|
if (s === "blob") {
|
|
5489
5489
|
const o = await e.read({ oid: n });
|
|
5490
5490
|
Er(o), i[a] = o.object;
|
|
5491
|
-
} else s === "tree" && (i[a] = await
|
|
5491
|
+
} else s === "tree" && (i[a] = await np(e, n));
|
|
5492
5492
|
return i;
|
|
5493
5493
|
}
|
|
5494
5494
|
function Er(e) {
|
|
@@ -5524,7 +5524,7 @@ async function* Yh(e) {
|
|
|
5524
5524
|
yield t.substring(r + 4, r + i), r += i;
|
|
5525
5525
|
}
|
|
5526
5526
|
}
|
|
5527
|
-
function
|
|
5527
|
+
function ip(e) {
|
|
5528
5528
|
if (e[Symbol.asyncIterator])
|
|
5529
5529
|
return e;
|
|
5530
5530
|
const t = e.getReader();
|
|
@@ -5570,7 +5570,7 @@ function Xh(e, t) {
|
|
|
5570
5570
|
}
|
|
5571
5571
|
return a;
|
|
5572
5572
|
}
|
|
5573
|
-
const Ts = 15, zi = 30, Gi = 19, Jh = 29, Pn = 256, ya = Pn + 1 + Jh, Lo = 2 * ya + 1, as = 256, Qh = 7, Ro = 16, Io = 17, Do = 18, hi = 8 * 2, An = -1, em = 1, Gs = 2, tm = 0, qr = 0, Ho = 1, rm = 3, ot = 4, Ct = 0,
|
|
5573
|
+
const Ts = 15, zi = 30, Gi = 19, Jh = 29, Pn = 256, ya = Pn + 1 + Jh, Lo = 2 * ya + 1, as = 256, Qh = 7, Ro = 16, Io = 17, Do = 18, hi = 8 * 2, An = -1, em = 1, Gs = 2, tm = 0, qr = 0, Ho = 1, rm = 3, ot = 4, Ct = 0, ap = 1, Zs = 2, Lt = -2, sm = -3, Br = -5;
|
|
5574
5574
|
function Mn(e) {
|
|
5575
5575
|
return qn(e.map(([t, r]) => new Array(t).fill(r, 0, t)));
|
|
5576
5576
|
}
|
|
@@ -6025,8 +6025,8 @@ function Ft(e, t, r, i, a) {
|
|
|
6025
6025
|
const n = this;
|
|
6026
6026
|
n.good_length = e, n.max_lazy = t, n.nice_length = r, n.max_chain = i, n.func = a;
|
|
6027
6027
|
}
|
|
6028
|
-
const
|
|
6029
|
-
new Ft(0, 0, 0, 0,
|
|
6028
|
+
const op = 0, un = 1, wr = 2, Tt = [
|
|
6029
|
+
new Ft(0, 0, 0, 0, op),
|
|
6030
6030
|
new Ft(4, 4, 8, 4, un),
|
|
6031
6031
|
new Ft(4, 5, 16, 8, un),
|
|
6032
6032
|
new Ft(4, 6, 32, 32, un),
|
|
@@ -6075,7 +6075,7 @@ function dm() {
|
|
|
6075
6075
|
y[U] = 0;
|
|
6076
6076
|
k = Tt[E].max_lazy, I = Tt[E].good_length, j = Tt[E].nice_length, C = Tt[E].max_chain, A = 0, b = 0, S = 0, R = P = He - 1, $ = 0, h = 0;
|
|
6077
6077
|
}
|
|
6078
|
-
function
|
|
6078
|
+
function Ae() {
|
|
6079
6079
|
let U;
|
|
6080
6080
|
for (U = 0; U < ya; U++)
|
|
6081
6081
|
W[U * 2] = 0;
|
|
@@ -6086,7 +6086,7 @@ function dm() {
|
|
|
6086
6086
|
W[as * 2] = 1, e.opt_len = e.static_len = 0, ee = Z = 0;
|
|
6087
6087
|
}
|
|
6088
6088
|
function Ve() {
|
|
6089
|
-
z.dyn_tree = W, z.stat_desc = Ye.static_l_desc, ne.dyn_tree = M, ne.stat_desc = Ye.static_d_desc, G.dyn_tree = V, G.stat_desc = Ye.static_bl_desc, ie = 0, ae = 0, fe = 8,
|
|
6089
|
+
z.dyn_tree = W, z.stat_desc = Ye.static_l_desc, ne.dyn_tree = M, ne.stat_desc = Ye.static_d_desc, G.dyn_tree = V, G.stat_desc = Ye.static_bl_desc, ie = 0, ae = 0, fe = 8, Ae();
|
|
6090
6090
|
}
|
|
6091
6091
|
e.pqdownheap = function(U, Y) {
|
|
6092
6092
|
const q = e.heap, J = q[Y];
|
|
@@ -6178,7 +6178,7 @@ function dm() {
|
|
|
6178
6178
|
}
|
|
6179
6179
|
function Fe(U, Y, q) {
|
|
6180
6180
|
let J, se, le = 0;
|
|
6181
|
-
E > 0 ? (z.build_tree(e), ne.build_tree(e), le = bt(), J = e.opt_len + 3 + 7 >>> 3, se = e.static_len + 3 + 7 >>> 3, se <= J && (J = se)) : J = se = Y + 5, Y + 4 <= J && U != -1 ? he(U, Y, q) : se == J ? (Ce((_i << 1) + (q ? 1 : 0), 3), X(Ye.static_ltree, Ye.static_dtree)) : (Ce((um << 1) + (q ? 1 : 0), 3), d(z.max_code + 1, ne.max_code + 1, le + 1), X(W, M)),
|
|
6181
|
+
E > 0 ? (z.build_tree(e), ne.build_tree(e), le = bt(), J = e.opt_len + 3 + 7 >>> 3, se = e.static_len + 3 + 7 >>> 3, se <= J && (J = se)) : J = se = Y + 5, Y + 4 <= J && U != -1 ? he(U, Y, q) : se == J ? (Ce((_i << 1) + (q ? 1 : 0), 3), X(Ye.static_ltree, Ye.static_dtree)) : (Ce((um << 1) + (q ? 1 : 0), 3), d(z.max_code + 1, ne.max_code + 1, le + 1), X(W, M)), Ae(), q && pe();
|
|
6182
6182
|
}
|
|
6183
6183
|
function ue(U) {
|
|
6184
6184
|
Fe(b >= 0 ? b : -1, A - b, U), b = A, t.flush_pending();
|
|
@@ -6327,7 +6327,7 @@ function dm() {
|
|
|
6327
6327
|
return U.msg = Vs[Zs - Br], Br;
|
|
6328
6328
|
if (t.avail_in !== 0 || S !== 0 || Y != qr && r != ls) {
|
|
6329
6329
|
switch (de = -1, Tt[E].func) {
|
|
6330
|
-
case
|
|
6330
|
+
case op:
|
|
6331
6331
|
de = et(Y);
|
|
6332
6332
|
break;
|
|
6333
6333
|
case un:
|
|
@@ -6349,14 +6349,14 @@ function dm() {
|
|
|
6349
6349
|
return a = -1, Ct;
|
|
6350
6350
|
}
|
|
6351
6351
|
}
|
|
6352
|
-
return Y != ot ? Ct :
|
|
6352
|
+
return Y != ot ? Ct : ap;
|
|
6353
6353
|
};
|
|
6354
6354
|
}
|
|
6355
|
-
function
|
|
6355
|
+
function lp() {
|
|
6356
6356
|
const e = this;
|
|
6357
6357
|
e.next_in_index = 0, e.next_out_index = 0, e.avail_in = 0, e.total_in = 0, e.avail_out = 0, e.total_out = 0;
|
|
6358
6358
|
}
|
|
6359
|
-
|
|
6359
|
+
lp.prototype = {
|
|
6360
6360
|
deflateInit(e, t) {
|
|
6361
6361
|
const r = this;
|
|
6362
6362
|
return r.dstate = new dm(), t || (t = Ts), r.dstate.deflateInit(r, e, t);
|
|
@@ -6401,7 +6401,7 @@ ap.prototype = {
|
|
|
6401
6401
|
}
|
|
6402
6402
|
};
|
|
6403
6403
|
function hm(e) {
|
|
6404
|
-
const t = this, r = new
|
|
6404
|
+
const t = this, r = new lp(), i = mm(e && e.chunkSize ? e.chunkSize : 64 * 1024), a = qr, n = new Uint8Array(i);
|
|
6405
6405
|
let s = e ? e.level : An;
|
|
6406
6406
|
typeof s > "u" && (s = An), r.deflateInit(s), r.next_out = n, t.append = function(o, f) {
|
|
6407
6407
|
let p, c, y = 0, h = 0, _ = 0;
|
|
@@ -6421,7 +6421,7 @@ function hm(e) {
|
|
|
6421
6421
|
let o, f, p = 0, c = 0;
|
|
6422
6422
|
const y = [];
|
|
6423
6423
|
do {
|
|
6424
|
-
if (r.next_out_index = 0, r.avail_out = i, o = r.deflate(ot), o !=
|
|
6424
|
+
if (r.next_out_index = 0, r.avail_out = i, o = r.deflate(ot), o != ap && o != Ct)
|
|
6425
6425
|
throw new Error("deflating: " + r.msg);
|
|
6426
6426
|
i - r.avail_out > 0 && y.push(n.slice(0, r.next_out_index)), c += r.next_out_index;
|
|
6427
6427
|
} while (r.avail_in > 0 || r.avail_out === 0);
|
|
@@ -6451,7 +6451,7 @@ const ym = 15, we = 0, Jt = 1, _m = 2, lt = -2, Le = -3, No = -4, Qt = -5, mt =
|
|
|
6451
6451
|
16383,
|
|
6452
6452
|
32767,
|
|
6453
6453
|
65535
|
|
6454
|
-
],
|
|
6454
|
+
], fp = 1440, gm = 0, wm = 4, bm = 9, vm = 5, xm = [
|
|
6455
6455
|
96,
|
|
6456
6456
|
7,
|
|
6457
6457
|
256,
|
|
@@ -8249,7 +8249,7 @@ function Zi() {
|
|
|
8249
8249
|
if (S++, W += E, z = H - W, z = z > E ? E : z, (A = 1 << (C = k - W)) > $ + 1 && (A -= $ + 1, M = k, C < z))
|
|
8250
8250
|
for (; ++C < z && !((A <<= 1) <= i[++M]); )
|
|
8251
8251
|
A -= i[M];
|
|
8252
|
-
if (z = 1 << C, R[0] + z >
|
|
8252
|
+
if (z = 1 << C, R[0] + z > fp)
|
|
8253
8253
|
return Le;
|
|
8254
8254
|
n[S] = j = /* hp+ */
|
|
8255
8255
|
R[0], R[0] += z, S !== 0 ? (s[S] = P, a[0] = /* (byte) */
|
|
@@ -8487,7 +8487,7 @@ function Cm(e, t) {
|
|
|
8487
8487
|
const r = this;
|
|
8488
8488
|
let i = Wr, a = 0, n = 0, s = 0, o;
|
|
8489
8489
|
const f = [0], p = [0], c = new Tm();
|
|
8490
|
-
let y = 0, h = new Int32Array(
|
|
8490
|
+
let y = 0, h = new Int32Array(fp * 3);
|
|
8491
8491
|
const _ = 0, L = new Zi();
|
|
8492
8492
|
r.bitk = 0, r.bitb = 0, r.win = new Uint8Array(t), r.end = t, r.read = 0, r.write = 0, r.reset = function(m, g) {
|
|
8493
8493
|
g && (g[0] = _), i == tn && c.free(m), i = Wr, r.bitk = 0, r.bitb = 0, r.read = r.write = 0;
|
|
@@ -8733,9 +8733,9 @@ function Dm() {
|
|
|
8733
8733
|
return !r || !r.istate || !r.istate.blocks ? lt : r.istate.blocks.sync_point();
|
|
8734
8734
|
};
|
|
8735
8735
|
}
|
|
8736
|
-
function
|
|
8736
|
+
function pp() {
|
|
8737
8737
|
}
|
|
8738
|
-
|
|
8738
|
+
pp.prototype = {
|
|
8739
8739
|
inflateInit(e) {
|
|
8740
8740
|
const t = this;
|
|
8741
8741
|
return t.istate = new Dm(), e || (e = ym), t.istate.inflateInit(t, e);
|
|
@@ -8767,7 +8767,7 @@ lp.prototype = {
|
|
|
8767
8767
|
}
|
|
8768
8768
|
};
|
|
8769
8769
|
function Hm(e) {
|
|
8770
|
-
const t = this, r = new
|
|
8770
|
+
const t = this, r = new pp(), i = e && e.chunkSize ? Math.floor(e.chunkSize * 2) : 128 * 1024, a = gm, n = new Uint8Array(i);
|
|
8771
8771
|
let s = !1;
|
|
8772
8772
|
r.inflateInit(), r.next_out = n, t.append = function(o, f) {
|
|
8773
8773
|
const p = [];
|
|
@@ -8812,14 +8812,14 @@ class dl {
|
|
|
8812
8812
|
}
|
|
8813
8813
|
}
|
|
8814
8814
|
const Jm = 64;
|
|
8815
|
-
let
|
|
8815
|
+
let cp = 2;
|
|
8816
8816
|
try {
|
|
8817
|
-
typeof navigator != _r && navigator.hardwareConcurrency && (
|
|
8817
|
+
typeof navigator != _r && navigator.hardwareConcurrency && (cp = navigator.hardwareConcurrency);
|
|
8818
8818
|
} catch {
|
|
8819
8819
|
}
|
|
8820
8820
|
const Qm = {
|
|
8821
8821
|
chunkSize: 512 * 1024,
|
|
8822
|
-
maxWorkers:
|
|
8822
|
+
maxWorkers: cp,
|
|
8823
8823
|
terminateWorkerTimeout: 5e3,
|
|
8824
8824
|
useWebWorkers: !0,
|
|
8825
8825
|
useCompressionStream: !0,
|
|
@@ -10458,12 +10458,12 @@ const ki = {
|
|
|
10458
10458
|
}
|
|
10459
10459
|
return e;
|
|
10460
10460
|
})();
|
|
10461
|
-
const
|
|
10461
|
+
const up = [];
|
|
10462
10462
|
for (let e = 0; e < 256; e++) {
|
|
10463
10463
|
let t = e;
|
|
10464
10464
|
for (let r = 0; r < 8; r++)
|
|
10465
10465
|
t & 1 ? t = t >>> 1 ^ 3988292384 : t = t >>> 1;
|
|
10466
|
-
|
|
10466
|
+
up[e] = t;
|
|
10467
10467
|
}
|
|
10468
10468
|
class Tn {
|
|
10469
10469
|
constructor(t) {
|
|
@@ -10472,14 +10472,14 @@ class Tn {
|
|
|
10472
10472
|
append(t) {
|
|
10473
10473
|
let r = this.crc | 0;
|
|
10474
10474
|
for (let i = 0, a = t.length | 0; i < a; i++)
|
|
10475
|
-
r = r >>> 8 ^
|
|
10475
|
+
r = r >>> 8 ^ up[(r ^ t[i]) & 255];
|
|
10476
10476
|
this.crc = r;
|
|
10477
10477
|
}
|
|
10478
10478
|
get() {
|
|
10479
10479
|
return ~this.crc;
|
|
10480
10480
|
}
|
|
10481
10481
|
}
|
|
10482
|
-
class
|
|
10482
|
+
class dp extends TransformStream {
|
|
10483
10483
|
constructor() {
|
|
10484
10484
|
let t;
|
|
10485
10485
|
const r = new Tn();
|
|
@@ -10596,8 +10596,8 @@ const nt = {
|
|
|
10596
10596
|
return r & 3 && t.push(nt.partial(8 * (r & 3), i)), t;
|
|
10597
10597
|
}
|
|
10598
10598
|
}
|
|
10599
|
-
},
|
|
10600
|
-
|
|
10599
|
+
}, hp = {};
|
|
10600
|
+
hp.sha1 = class {
|
|
10601
10601
|
constructor(e) {
|
|
10602
10602
|
const t = this;
|
|
10603
10603
|
t.blockSize = 512, t._init = [1732584193, 4023233417, 2562383102, 271733878, 3285377520], t._key = [1518500249, 1859775393, 2400959708, 3395469782], e ? (t._h = e._h.slice(0), t._buffer = e._buffer.slice(0), t._length = e._length) : t.reset();
|
|
@@ -10681,8 +10681,8 @@ up.sha1 = class {
|
|
|
10681
10681
|
r[0] = r[0] + a | 0, r[1] = r[1] + n | 0, r[2] = r[2] + s | 0, r[3] = r[3] + o | 0, r[4] = r[4] + f | 0;
|
|
10682
10682
|
}
|
|
10683
10683
|
};
|
|
10684
|
-
const
|
|
10685
|
-
|
|
10684
|
+
const mp = {};
|
|
10685
|
+
mp.aes = class {
|
|
10686
10686
|
constructor(e) {
|
|
10687
10687
|
const t = this;
|
|
10688
10688
|
t._tables = [[[], [], [], [], []], [[], [], [], [], []]], t._tables[0][0][0] || t._precompute();
|
|
@@ -10780,8 +10780,8 @@ const s0 = {
|
|
|
10780
10780
|
}
|
|
10781
10781
|
return e;
|
|
10782
10782
|
}
|
|
10783
|
-
},
|
|
10784
|
-
|
|
10783
|
+
}, yp = {};
|
|
10784
|
+
yp.ctrGladman = class {
|
|
10785
10785
|
constructor(e, t) {
|
|
10786
10786
|
this._prf = e, this._initIv = t, this._iv = t;
|
|
10787
10787
|
}
|
|
@@ -10842,7 +10842,7 @@ const Ir = {
|
|
|
10842
10842
|
};
|
|
10843
10843
|
Ir.hmacSha1 = class {
|
|
10844
10844
|
constructor(e) {
|
|
10845
|
-
const t = this, r = t._hash =
|
|
10845
|
+
const t = this, r = t._hash = hp.sha1, i = [[], []];
|
|
10846
10846
|
t._baseHash = [new r(), new r()];
|
|
10847
10847
|
const a = t._baseHash[0].blockSize / 32;
|
|
10848
10848
|
e.length > a && (e = new r().update(e).finalize());
|
|
@@ -10868,19 +10868,19 @@ Ir.hmacSha1 = class {
|
|
|
10868
10868
|
return this.update(e), this.digest(e);
|
|
10869
10869
|
}
|
|
10870
10870
|
};
|
|
10871
|
-
const n0 = typeof crypto != _r && typeof crypto.getRandomValues == Fs,
|
|
10872
|
-
function
|
|
10871
|
+
const n0 = typeof crypto != _r && typeof crypto.getRandomValues == Fs, _p = "Invalid password", gp = "Invalid signature", ga = "zipjs-abort-check-password";
|
|
10872
|
+
function wp(e) {
|
|
10873
10873
|
return n0 ? crypto.getRandomValues(e) : s0.getRandomValues(e);
|
|
10874
10874
|
}
|
|
10875
|
-
const zr = 16, i0 = "raw",
|
|
10876
|
-
let hl = Kn &&
|
|
10875
|
+
const zr = 16, i0 = "raw", bp = { name: "PBKDF2" }, a0 = { name: "HMAC" }, o0 = "SHA-1", l0 = Object.assign({ hash: a0 }, bp), Vi = Object.assign({ iterations: 1e3, hash: { name: o0 } }, bp), f0 = ["deriveBits"], Cs = [8, 12, 16], ps = [16, 24, 32], fr = 10, p0 = [0, 0, 0, 0], Kn = typeof crypto != _r, Ns = Kn && crypto.subtle, vp = Kn && typeof Ns != _r, Ut = Cn.bytes, c0 = mp.aes, u0 = yp.ctrGladman, d0 = Ir.hmacSha1;
|
|
10876
|
+
let hl = Kn && vp && typeof Ns.importKey == Fs, ml = Kn && vp && typeof Ns.deriveBits == Fs;
|
|
10877
10877
|
class h0 extends TransformStream {
|
|
10878
10878
|
constructor({ password: t, rawPassword: r, signed: i, encryptionStrength: a, checkPasswordOnly: n }) {
|
|
10879
10879
|
super({
|
|
10880
10880
|
start() {
|
|
10881
10881
|
Object.assign(this, {
|
|
10882
10882
|
ready: new Promise((s) => this.resolveReady = s),
|
|
10883
|
-
password:
|
|
10883
|
+
password: Sp(t, r),
|
|
10884
10884
|
signed: i,
|
|
10885
10885
|
strength: a - 1,
|
|
10886
10886
|
pending: new Uint8Array()
|
|
@@ -10895,7 +10895,7 @@ class h0 extends TransformStream {
|
|
|
10895
10895
|
} = f;
|
|
10896
10896
|
p ? (await y0(f, c, p, kt(s, 0, Cs[c] + 2)), s = kt(s, Cs[c] + 2), n ? o.error(new Error(ga)) : y()) : await h;
|
|
10897
10897
|
const _ = new Uint8Array(s.length - fr - (s.length - fr) % zr);
|
|
10898
|
-
o.enqueue(
|
|
10898
|
+
o.enqueue(xp(f, s, _, 0, fr, !0));
|
|
10899
10899
|
},
|
|
10900
10900
|
async flush(s) {
|
|
10901
10901
|
const {
|
|
@@ -10919,7 +10919,7 @@ class h0 extends TransformStream {
|
|
|
10919
10919
|
const m = kt(Os(Ut, p.digest()), 0, fr);
|
|
10920
10920
|
for (let g = 0; g < fr; g++)
|
|
10921
10921
|
if (m[g] != _[g])
|
|
10922
|
-
throw new Error(
|
|
10922
|
+
throw new Error(gp);
|
|
10923
10923
|
}
|
|
10924
10924
|
s.enqueue(L);
|
|
10925
10925
|
}
|
|
@@ -10934,7 +10934,7 @@ class m0 extends TransformStream {
|
|
|
10934
10934
|
start() {
|
|
10935
10935
|
Object.assign(this, {
|
|
10936
10936
|
ready: new Promise((n) => this.resolveReady = n),
|
|
10937
|
-
password:
|
|
10937
|
+
password: Sp(t, r),
|
|
10938
10938
|
strength: i - 1,
|
|
10939
10939
|
pending: new Uint8Array()
|
|
10940
10940
|
});
|
|
@@ -10949,7 +10949,7 @@ class m0 extends TransformStream {
|
|
|
10949
10949
|
let h = new Uint8Array();
|
|
10950
10950
|
f ? (h = await _0(o, p, f), c()) : await y;
|
|
10951
10951
|
const _ = new Uint8Array(h.length + n.length - n.length % zr);
|
|
10952
|
-
_.set(h, 0), s.enqueue(
|
|
10952
|
+
_.set(h, 0), s.enqueue(xp(o, n, _, h.length, 0));
|
|
10953
10953
|
},
|
|
10954
10954
|
async flush(n) {
|
|
10955
10955
|
const {
|
|
@@ -10971,7 +10971,7 @@ class m0 extends TransformStream {
|
|
|
10971
10971
|
}), a = this;
|
|
10972
10972
|
}
|
|
10973
10973
|
}
|
|
10974
|
-
function
|
|
10974
|
+
function xp(e, t, r, i, a, n) {
|
|
10975
10975
|
const {
|
|
10976
10976
|
ctr: s,
|
|
10977
10977
|
hmac: o,
|
|
@@ -10988,15 +10988,15 @@ function bp(e, t, r, i, a, n) {
|
|
|
10988
10988
|
return e.pending = kt(t, c), r;
|
|
10989
10989
|
}
|
|
10990
10990
|
async function y0(e, t, r, i) {
|
|
10991
|
-
const a = await
|
|
10991
|
+
const a = await kp(e, t, r, kt(i, 0, Cs[t])), n = kt(i, Cs[t]);
|
|
10992
10992
|
if (a[0] != n[0] || a[1] != n[1])
|
|
10993
|
-
throw new Error(
|
|
10993
|
+
throw new Error(_p);
|
|
10994
10994
|
}
|
|
10995
10995
|
async function _0(e, t, r) {
|
|
10996
|
-
const i =
|
|
10996
|
+
const i = wp(new Uint8Array(Cs[t])), a = await kp(e, t, r, i);
|
|
10997
10997
|
return wa(i, a);
|
|
10998
10998
|
}
|
|
10999
|
-
async function
|
|
10999
|
+
async function kp(e, t, r, i) {
|
|
11000
11000
|
e.password = null;
|
|
11001
11001
|
const a = await g0(i0, r, l0, !1, f0), n = await w0(Object.assign({ salt: i }, Vi), a, 8 * (ps[t] * 2 + 2)), s = new Uint8Array(n), o = Ls(Ut, kt(s, 0, ps[t])), f = Ls(Ut, kt(s, ps[t], ps[t] * 2)), p = kt(s, ps[t] * 2);
|
|
11002
11002
|
return Object.assign(e, {
|
|
@@ -11029,7 +11029,7 @@ async function w0(e, t, r) {
|
|
|
11029
11029
|
else
|
|
11030
11030
|
return Ir.pbkdf2(t, e.salt, Vi.iterations, r);
|
|
11031
11031
|
}
|
|
11032
|
-
function
|
|
11032
|
+
function Sp(e, t) {
|
|
11033
11033
|
return t === it ? r0(e) : t;
|
|
11034
11034
|
}
|
|
11035
11035
|
function wa(e, t) {
|
|
@@ -11060,14 +11060,14 @@ class v0 extends TransformStream {
|
|
|
11060
11060
|
Object.assign(this, {
|
|
11061
11061
|
password: t,
|
|
11062
11062
|
passwordVerification: r
|
|
11063
|
-
}),
|
|
11063
|
+
}), Ep(this, t);
|
|
11064
11064
|
},
|
|
11065
11065
|
transform(a, n) {
|
|
11066
11066
|
const s = this;
|
|
11067
11067
|
if (s.password) {
|
|
11068
11068
|
const o = yl(s, a.subarray(0, Yr));
|
|
11069
11069
|
if (s.password = null, o[Yr - 1] != s.passwordVerification)
|
|
11070
|
-
throw new Error(
|
|
11070
|
+
throw new Error(_p);
|
|
11071
11071
|
a = a.subarray(Yr);
|
|
11072
11072
|
}
|
|
11073
11073
|
i ? n.error(new Error(ga)) : n.enqueue(yl(s, a));
|
|
@@ -11082,14 +11082,14 @@ class x0 extends TransformStream {
|
|
|
11082
11082
|
Object.assign(this, {
|
|
11083
11083
|
password: t,
|
|
11084
11084
|
passwordVerification: r
|
|
11085
|
-
}),
|
|
11085
|
+
}), Ep(this, t);
|
|
11086
11086
|
},
|
|
11087
11087
|
transform(i, a) {
|
|
11088
11088
|
const n = this;
|
|
11089
11089
|
let s, o;
|
|
11090
11090
|
if (n.password) {
|
|
11091
11091
|
n.password = null;
|
|
11092
|
-
const f =
|
|
11092
|
+
const f = wp(new Uint8Array(Yr));
|
|
11093
11093
|
f[Yr - 1] = n.passwordVerification, s = new Uint8Array(i.length + f.length), s.set(_l(n, f), 0), o = Yr;
|
|
11094
11094
|
} else
|
|
11095
11095
|
s = new Uint8Array(i.length), o = 0;
|
|
@@ -11101,16 +11101,16 @@ class x0 extends TransformStream {
|
|
|
11101
11101
|
function yl(e, t) {
|
|
11102
11102
|
const r = new Uint8Array(t.length);
|
|
11103
11103
|
for (let i = 0; i < t.length; i++)
|
|
11104
|
-
r[i] =
|
|
11104
|
+
r[i] = Pp(e) ^ t[i], ba(e, r[i]);
|
|
11105
11105
|
return r;
|
|
11106
11106
|
}
|
|
11107
11107
|
function _l(e, t) {
|
|
11108
11108
|
const r = new Uint8Array(t.length);
|
|
11109
11109
|
for (let i = 0; i < t.length; i++)
|
|
11110
|
-
r[i] =
|
|
11110
|
+
r[i] = Pp(e) ^ t[i], ba(e, t[i]);
|
|
11111
11111
|
return r;
|
|
11112
11112
|
}
|
|
11113
|
-
function
|
|
11113
|
+
function Ep(e, t) {
|
|
11114
11114
|
const r = [305419896, 591751049, 878082192];
|
|
11115
11115
|
Object.assign(e, {
|
|
11116
11116
|
keys: r,
|
|
@@ -11122,13 +11122,13 @@ function kp(e, t) {
|
|
|
11122
11122
|
}
|
|
11123
11123
|
function ba(e, t) {
|
|
11124
11124
|
let [r, i, a] = e.keys;
|
|
11125
|
-
e.crcKey0.append([t]), r = ~e.crcKey0.get(), i = gl(Math.imul(gl(i +
|
|
11125
|
+
e.crcKey0.append([t]), r = ~e.crcKey0.get(), i = gl(Math.imul(gl(i + Ap(r)), 134775813) + 1), e.crcKey2.append([i >>> 24]), a = ~e.crcKey2.get(), e.keys = [r, i, a];
|
|
11126
11126
|
}
|
|
11127
|
-
function
|
|
11127
|
+
function Pp(e) {
|
|
11128
11128
|
const t = e.keys[2] | 2;
|
|
11129
|
-
return
|
|
11129
|
+
return Ap(Math.imul(t, t ^ 1) >>> 8);
|
|
11130
11130
|
}
|
|
11131
|
-
function
|
|
11131
|
+
function Ap(e) {
|
|
11132
11132
|
return e & 255;
|
|
11133
11133
|
}
|
|
11134
11134
|
function gl(e) {
|
|
@@ -11139,8 +11139,8 @@ class k0 extends TransformStream {
|
|
|
11139
11139
|
constructor(t, { chunkSize: r, CompressionStream: i, CompressionStreamNative: a }) {
|
|
11140
11140
|
super({});
|
|
11141
11141
|
const { compressed: n, encrypted: s, useCompressionStream: o, zipCrypto: f, signed: p, level: c } = t, y = this;
|
|
11142
|
-
let h, _, L =
|
|
11143
|
-
(!s || f) && p && (h = new
|
|
11142
|
+
let h, _, L = Tp(super.readable);
|
|
11143
|
+
(!s || f) && p && (h = new dp(), L = Mt(L, h)), n && (L = Op(L, o, { level: c, chunkSize: r }, a, i)), s && (f ? L = Mt(L, new x0(t)) : (_ = new m0(t), L = Mt(L, _))), Cp(y, L, () => {
|
|
11144
11144
|
let m;
|
|
11145
11145
|
s && !f && (m = _.signature), (!s || f) && p && (m = new DataView(h.value.buffer).getUint32(0)), y.signature = m;
|
|
11146
11146
|
});
|
|
@@ -11150,31 +11150,31 @@ class S0 extends TransformStream {
|
|
|
11150
11150
|
constructor(t, { chunkSize: r, DecompressionStream: i, DecompressionStreamNative: a }) {
|
|
11151
11151
|
super({});
|
|
11152
11152
|
const { zipCrypto: n, encrypted: s, signed: o, signature: f, compressed: p, useCompressionStream: c } = t;
|
|
11153
|
-
let y, h, _ =
|
|
11154
|
-
s && (n ? _ = Mt(_, new v0(t)) : (h = new h0(t), _ = Mt(_, h))), p && (_ =
|
|
11153
|
+
let y, h, _ = Tp(super.readable);
|
|
11154
|
+
s && (n ? _ = Mt(_, new v0(t)) : (h = new h0(t), _ = Mt(_, h))), p && (_ = Op(_, c, { chunkSize: r }, a, i)), (!s || n) && o && (y = new dp(), _ = Mt(_, y)), Cp(this, _, () => {
|
|
11155
11155
|
if ((!s || n) && o) {
|
|
11156
11156
|
const L = new DataView(y.value.buffer);
|
|
11157
11157
|
if (f != L.getUint32(0, !1))
|
|
11158
|
-
throw new Error(
|
|
11158
|
+
throw new Error(gp);
|
|
11159
11159
|
}
|
|
11160
11160
|
});
|
|
11161
11161
|
}
|
|
11162
11162
|
}
|
|
11163
|
-
function
|
|
11163
|
+
function Tp(e) {
|
|
11164
11164
|
return Mt(e, new TransformStream({
|
|
11165
11165
|
transform(t, r) {
|
|
11166
11166
|
t && t.length && r.enqueue(t);
|
|
11167
11167
|
}
|
|
11168
11168
|
}));
|
|
11169
11169
|
}
|
|
11170
|
-
function
|
|
11170
|
+
function Cp(e, t, r) {
|
|
11171
11171
|
t = Mt(t, new TransformStream({ flush: r })), Object.defineProperty(e, "readable", {
|
|
11172
11172
|
get() {
|
|
11173
11173
|
return t;
|
|
11174
11174
|
}
|
|
11175
11175
|
});
|
|
11176
11176
|
}
|
|
11177
|
-
function
|
|
11177
|
+
function Op(e, t, r, i, a) {
|
|
11178
11178
|
try {
|
|
11179
11179
|
const n = t && i ? i : a;
|
|
11180
11180
|
e = Mt(e, new n(wl, r));
|
|
@@ -11193,13 +11193,13 @@ function Tp(e, t, r, i, a) {
|
|
|
11193
11193
|
function Mt(e, t) {
|
|
11194
11194
|
return e.pipeThrough(t);
|
|
11195
11195
|
}
|
|
11196
|
-
const E0 = "message", P0 = "start", A0 = "pull", bl = "data", T0 = "ack", vl = "close", C0 = "deflate",
|
|
11196
|
+
const E0 = "message", P0 = "start", A0 = "pull", bl = "data", T0 = "ack", vl = "close", C0 = "deflate", Lp = "inflate";
|
|
11197
11197
|
class O0 extends TransformStream {
|
|
11198
11198
|
constructor(t, r) {
|
|
11199
11199
|
super({});
|
|
11200
11200
|
const i = this, { codecType: a } = t;
|
|
11201
11201
|
let n;
|
|
11202
|
-
a.startsWith(C0) ? n = k0 : a.startsWith(
|
|
11202
|
+
a.startsWith(C0) ? n = k0 : a.startsWith(Lp) && (n = S0);
|
|
11203
11203
|
let s = 0, o = 0;
|
|
11204
11204
|
const f = new n(t, r), p = super.readable, c = new TransformStream({
|
|
11205
11205
|
transform(h, _) {
|
|
@@ -11248,7 +11248,7 @@ class L0 extends TransformStream {
|
|
|
11248
11248
|
}
|
|
11249
11249
|
}
|
|
11250
11250
|
}
|
|
11251
|
-
let
|
|
11251
|
+
let Rp = typeof Worker != _r;
|
|
11252
11252
|
class Si {
|
|
11253
11253
|
constructor(t, { readable: r, writable: i }, { options: a, config: n, streamOptions: s, useWebWorkers: o, transferStreams: f, scripts: p }, c) {
|
|
11254
11254
|
const { signal: y } = s;
|
|
@@ -11269,7 +11269,7 @@ class Si {
|
|
|
11269
11269
|
const { resolveTerminated: h } = t;
|
|
11270
11270
|
h && (t.resolveTerminated = null, t.terminated = !0, t.worker.terminate(), h()), t.busy = !1, c(t);
|
|
11271
11271
|
}
|
|
11272
|
-
}), (o &&
|
|
11272
|
+
}), (o && Rp ? I0 : Ip)(t, n);
|
|
11273
11273
|
}
|
|
11274
11274
|
}
|
|
11275
11275
|
class R0 extends TransformStream {
|
|
@@ -11294,7 +11294,7 @@ async function Ei(e, ...t) {
|
|
|
11294
11294
|
} catch {
|
|
11295
11295
|
}
|
|
11296
11296
|
}
|
|
11297
|
-
function
|
|
11297
|
+
function Ip(e, t) {
|
|
11298
11298
|
return {
|
|
11299
11299
|
run: () => D0(e, t)
|
|
11300
11300
|
};
|
|
@@ -11306,7 +11306,7 @@ function I0(e, t) {
|
|
|
11306
11306
|
try {
|
|
11307
11307
|
a = F0(e.scripts[0], r, e);
|
|
11308
11308
|
} catch {
|
|
11309
|
-
return
|
|
11309
|
+
return Rp = !1, Ip(e, t);
|
|
11310
11310
|
}
|
|
11311
11311
|
Object.assign(e, {
|
|
11312
11312
|
worker: a,
|
|
@@ -11477,7 +11477,7 @@ function W0(e, t = {}) {
|
|
|
11477
11477
|
`, i = () => t.useDataURI ? "data:text/javascript," + encodeURIComponent(r) : URL.createObjectURL(new Blob([r], { type: "text/javascript" }));
|
|
11478
11478
|
e({ workerScripts: { inflate: [i], deflate: [i] } });
|
|
11479
11479
|
}
|
|
11480
|
-
const U0 = "Writer iterator completed too soon", M0 = "Content-Type", q0 = 64 * 1024,
|
|
11480
|
+
const U0 = "Writer iterator completed too soon", M0 = "Content-Type", q0 = 64 * 1024, Dp = "writable";
|
|
11481
11481
|
class va {
|
|
11482
11482
|
constructor() {
|
|
11483
11483
|
this.size = 0;
|
|
@@ -11486,7 +11486,7 @@ class va {
|
|
|
11486
11486
|
this.initialized = !0;
|
|
11487
11487
|
}
|
|
11488
11488
|
}
|
|
11489
|
-
class
|
|
11489
|
+
class Hp extends va {
|
|
11490
11490
|
get readable() {
|
|
11491
11491
|
const t = this, { chunkSize: r = q0 } = t, i = new ReadableStream({
|
|
11492
11492
|
start() {
|
|
@@ -11500,7 +11500,7 @@ class Ip extends va {
|
|
|
11500
11500
|
return i;
|
|
11501
11501
|
}
|
|
11502
11502
|
}
|
|
11503
|
-
class Yi extends
|
|
11503
|
+
class Yi extends Hp {
|
|
11504
11504
|
constructor(t) {
|
|
11505
11505
|
super(), Object.assign(this, {
|
|
11506
11506
|
blob: t,
|
|
@@ -11517,7 +11517,7 @@ class K0 extends va {
|
|
|
11517
11517
|
constructor(t) {
|
|
11518
11518
|
super();
|
|
11519
11519
|
const r = this, i = new TransformStream(), a = [];
|
|
11520
|
-
t && a.push([M0, t]), Object.defineProperty(r,
|
|
11520
|
+
t && a.push([M0, t]), Object.defineProperty(r, Dp, {
|
|
11521
11521
|
get() {
|
|
11522
11522
|
return i.writable;
|
|
11523
11523
|
}
|
|
@@ -11527,7 +11527,7 @@ class K0 extends va {
|
|
|
11527
11527
|
return this.blob;
|
|
11528
11528
|
}
|
|
11529
11529
|
}
|
|
11530
|
-
class z0 extends
|
|
11530
|
+
class z0 extends Hp {
|
|
11531
11531
|
constructor(t) {
|
|
11532
11532
|
super(), this.readers = t;
|
|
11533
11533
|
}
|
|
@@ -11582,7 +11582,7 @@ class Pl extends va {
|
|
|
11582
11582
|
await s.ready, await p();
|
|
11583
11583
|
}
|
|
11584
11584
|
});
|
|
11585
|
-
Object.defineProperty(i,
|
|
11585
|
+
Object.defineProperty(i, Dp, {
|
|
11586
11586
|
get() {
|
|
11587
11587
|
return o;
|
|
11588
11588
|
}
|
|
@@ -11622,12 +11622,12 @@ function Z0(e) {
|
|
|
11622
11622
|
function Je(e, t, r, i) {
|
|
11623
11623
|
return e.readUint8Array(t, r, i);
|
|
11624
11624
|
}
|
|
11625
|
-
const
|
|
11625
|
+
const $p = "\0☺☻♥♦♣♠•◘○◙♂♀♪♫☼►◄↕‼¶§▬↨↑↓→←∟↔▲▼ !\"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~⌂ÇüéâäàåçêëèïîìÄÅÉæÆôöòûùÿÖÜ¢£¥₧ƒáíóúñѪº¿⌐¬½¼¡«»░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ ".split(""), V0 = $p.length == 256;
|
|
11626
11626
|
function Y0(e) {
|
|
11627
11627
|
if (V0) {
|
|
11628
11628
|
let t = "";
|
|
11629
11629
|
for (let r = 0; r < e.length; r++)
|
|
11630
|
-
t +=
|
|
11630
|
+
t += $p[e[r]];
|
|
11631
11631
|
return t;
|
|
11632
11632
|
} else
|
|
11633
11633
|
return new TextDecoder().decode(e);
|
|
@@ -11635,18 +11635,18 @@ function Y0(e) {
|
|
|
11635
11635
|
function mn(e, t) {
|
|
11636
11636
|
return t && t.trim().toLowerCase() == "cp437" ? Y0(e) : new TextDecoder(t).decode(e);
|
|
11637
11637
|
}
|
|
11638
|
-
const
|
|
11639
|
-
Hp,
|
|
11640
|
-
$p,
|
|
11641
|
-
Bp,
|
|
11642
|
-
jp,
|
|
11643
|
-
Ji,
|
|
11644
|
-
Qi,
|
|
11638
|
+
const Fp = "filename", Np = "rawFilename", jp = "comment", Bp = "rawComment", Wp = "uncompressedSize", Up = "compressedSize", Mp = "offset", Xi = "diskNumberStart", Ji = "lastModDate", Qi = "rawLastModDate", qp = "lastAccessDate", X0 = "rawLastAccessDate", Kp = "creationDate", J0 = "rawCreationDate", Q0 = "internalFileAttribute", ey = "internalFileAttributes", ty = "externalFileAttribute", ry = "externalFileAttributes", sy = "msDosCompatible", ny = "zip64", iy = "encrypted", ay = "version", oy = "versionMadeBy", ly = "zipCrypto", fy = "directory", py = "executable", cy = [
|
|
11645
11639
|
Fp,
|
|
11646
11640
|
Np,
|
|
11647
11641
|
Up,
|
|
11648
|
-
Mp,
|
|
11649
11642
|
Wp,
|
|
11643
|
+
Ji,
|
|
11644
|
+
Qi,
|
|
11645
|
+
jp,
|
|
11646
|
+
Bp,
|
|
11647
|
+
qp,
|
|
11648
|
+
Kp,
|
|
11649
|
+
Mp,
|
|
11650
11650
|
Xi,
|
|
11651
11651
|
Xi,
|
|
11652
11652
|
Q0,
|
|
@@ -11681,9 +11681,9 @@ class Al {
|
|
|
11681
11681
|
}
|
|
11682
11682
|
}
|
|
11683
11683
|
const Ai = "File format is not recognized", uy = "End of central directory not found", dy = "End of Zip64 central directory locator not found", hy = "Central directory header not found", my = "Local file header not found", yy = "Zip64 extra field not found", _y = "File contains encrypted entry", gy = "Encryption method not supported", Tl = "Compression method not supported", Cl = "Split zip file", Ol = "utf-8", Ll = "cp437", wy = [
|
|
11684
|
-
[jp, Pr],
|
|
11685
|
-
[Bp, Pr],
|
|
11686
11684
|
[Wp, Pr],
|
|
11685
|
+
[Up, Pr],
|
|
11686
|
+
[Mp, Pr],
|
|
11687
11687
|
[Xi, pr]
|
|
11688
11688
|
], by = {
|
|
11689
11689
|
[pr]: {
|
|
@@ -11756,8 +11756,8 @@ class Rl {
|
|
|
11756
11756
|
const E = new vy(i, a, r.options);
|
|
11757
11757
|
if (je($, R) != nl)
|
|
11758
11758
|
throw new Error(hy);
|
|
11759
|
-
|
|
11760
|
-
const D = !!E.bitFlag.languageEncodingFlag, I = R + 46, j = I + E.filenameLength, W = j + E.extraFieldLength, M = ze($, R + 4), V = M >> 8 == 0, z = M >> 8 == 3, ne = O.subarray(I, j), G = ze($, R + 32), Q = W + G, ee = O.subarray(W, Q), Z = D, fe = D, ie = je($, R + 38), ae = V && (Xr($, R + 38) & fl) == fl || z && (ie >> 16 & pl) == pl || ne.length && ne[ne.length - 1] == ul.charCodeAt(0), Se = z && (ie >> 16 & cl) == cl,
|
|
11759
|
+
zp(E, $, R + 6);
|
|
11760
|
+
const D = !!E.bitFlag.languageEncodingFlag, I = R + 46, j = I + E.filenameLength, W = j + E.extraFieldLength, M = ze($, R + 4), V = M >> 8 == 0, z = M >> 8 == 3, ne = O.subarray(I, j), G = ze($, R + 32), Q = W + G, ee = O.subarray(W, Q), Z = D, fe = D, ie = je($, R + 38), ae = V && (Xr($, R + 38) & fl) == fl || z && (ie >> 16 & pl) == pl || ne.length && ne[ne.length - 1] == ul.charCodeAt(0), Se = z && (ie >> 16 & cl) == cl, Ae = je($, R + 42) + g;
|
|
11761
11761
|
Object.assign(E, {
|
|
11762
11762
|
versionMadeBy: M,
|
|
11763
11763
|
msDosCompatible: V,
|
|
@@ -11765,7 +11765,7 @@ class Rl {
|
|
|
11765
11765
|
uncompressedSize: 0,
|
|
11766
11766
|
commentLength: G,
|
|
11767
11767
|
directory: ae,
|
|
11768
|
-
offset:
|
|
11768
|
+
offset: Ae,
|
|
11769
11769
|
diskNumberStart: ze($, R + 34),
|
|
11770
11770
|
internalFileAttributes: ze($, R + 36),
|
|
11771
11771
|
externalFileAttributes: ie,
|
|
@@ -11784,7 +11784,7 @@ class Rl {
|
|
|
11784
11784
|
filename: Re,
|
|
11785
11785
|
comment: Ie,
|
|
11786
11786
|
directory: ae || Re.endsWith(ul)
|
|
11787
|
-
}), b = Math.max(
|
|
11787
|
+
}), b = Math.max(Ae, b), Gp(E, E, $, R + 6), E.zipCrypto = E.encrypted && !E.extraFieldAES;
|
|
11788
11788
|
const at = new Al(E);
|
|
11789
11789
|
at.getData = (v, u) => E.getData(v, at, u), R = Q;
|
|
11790
11790
|
const { onprogress: Ce } = t;
|
|
@@ -11837,7 +11837,7 @@ class vy {
|
|
|
11837
11837
|
throw new Error(Tl);
|
|
11838
11838
|
if (je(R, 0) != jm)
|
|
11839
11839
|
throw new Error(my);
|
|
11840
|
-
|
|
11840
|
+
zp(g, R, 4), g.rawExtraField = g.extraFieldLength ? await Je(n, s + 30 + g.filenameLength, g.extraFieldLength, o) : new Uint8Array(), Gp(a, g, R, 4, !0), Object.assign(r, {
|
|
11841
11841
|
lastAccessDate: g.lastAccessDate,
|
|
11842
11842
|
creationDate: g.creationDate
|
|
11843
11843
|
});
|
|
@@ -11858,7 +11858,7 @@ class vy {
|
|
|
11858
11858
|
D && (t = new WritableStream()), t = Z0(t), await On(t, A ? m : L);
|
|
11859
11859
|
const { writable: I } = t, { onstart: j, onprogress: W, onend: M } = i, V = {
|
|
11860
11860
|
options: {
|
|
11861
|
-
codecType:
|
|
11861
|
+
codecType: Lp,
|
|
11862
11862
|
password: O,
|
|
11863
11863
|
rawPassword: $,
|
|
11864
11864
|
zipCrypto: S,
|
|
@@ -11889,7 +11889,7 @@ class vy {
|
|
|
11889
11889
|
return D ? it : t.getData ? t.getData() : I;
|
|
11890
11890
|
}
|
|
11891
11891
|
}
|
|
11892
|
-
function
|
|
11892
|
+
function zp(e, t, r) {
|
|
11893
11893
|
const i = e.rawBitFlag = ze(t, r + 2), a = (i & al) == al, n = je(t, r + 6);
|
|
11894
11894
|
Object.assign(e, {
|
|
11895
11895
|
encrypted: a,
|
|
@@ -11905,7 +11905,7 @@ function qp(e, t, r) {
|
|
|
11905
11905
|
extraFieldLength: ze(t, r + 24)
|
|
11906
11906
|
});
|
|
11907
11907
|
}
|
|
11908
|
-
function
|
|
11908
|
+
function Gp(e, t, r, i, a) {
|
|
11909
11909
|
const { rawExtraField: n } = t, s = t.extraField = /* @__PURE__ */ new Map(), o = Ge(new Uint8Array(n));
|
|
11910
11910
|
let f = 0;
|
|
11911
11911
|
try {
|
|
@@ -11927,9 +11927,9 @@ function Kp(e, t, r, i, a) {
|
|
|
11927
11927
|
const c = s.get(Mm);
|
|
11928
11928
|
c && (xy(c, t), t.extraFieldZip64 = c);
|
|
11929
11929
|
const y = s.get(Zm);
|
|
11930
|
-
y && (Il(y,
|
|
11930
|
+
y && (Il(y, Fp, Np, t, e), t.extraFieldUnicodePath = y);
|
|
11931
11931
|
const h = s.get(Vm);
|
|
11932
|
-
h && (Il(h,
|
|
11932
|
+
h && (Il(h, jp, Bp, t, e), t.extraFieldUnicodeComment = h);
|
|
11933
11933
|
const _ = s.get(qm);
|
|
11934
11934
|
_ ? (ky(_, t, p), t.extraFieldAES = _) : t.compressionMethod = p;
|
|
11935
11935
|
const L = s.get(Km);
|
|
@@ -11999,7 +11999,7 @@ function Sy(e, t) {
|
|
|
11999
11999
|
}
|
|
12000
12000
|
function Ey(e, t, r) {
|
|
12001
12001
|
const i = Ge(e.data), a = Xr(i, 0), n = [], s = [];
|
|
12002
|
-
r ? ((a & 1) == 1 && (n.push(Ji), s.push(Qi)), (a & 2) == 2 && (n.push(
|
|
12002
|
+
r ? ((a & 1) == 1 && (n.push(Ji), s.push(Qi)), (a & 2) == 2 && (n.push(qp), s.push(X0)), (a & 4) == 4 && (n.push(Kp), s.push(J0))) : e.data.length >= 5 && (n.push(Ji), s.push(Qi));
|
|
12003
12003
|
let o = 1;
|
|
12004
12004
|
n.forEach((f, p) => {
|
|
12005
12005
|
if (e.data.length >= o + 4) {
|
|
@@ -12057,12 +12057,12 @@ function Ty(e, t, r) {
|
|
|
12057
12057
|
function Ge(e) {
|
|
12058
12058
|
return new DataView(e.buffer);
|
|
12059
12059
|
}
|
|
12060
|
-
let
|
|
12060
|
+
let Zp;
|
|
12061
12061
|
try {
|
|
12062
|
-
|
|
12062
|
+
Zp = import.meta.url;
|
|
12063
12063
|
} catch {
|
|
12064
12064
|
}
|
|
12065
|
-
_a({ baseURL:
|
|
12065
|
+
_a({ baseURL: Zp });
|
|
12066
12066
|
W0(_a);
|
|
12067
12067
|
_a({ Deflate: hm, Inflate: Hm });
|
|
12068
12068
|
class Cy {
|
|
@@ -12599,12 +12599,12 @@ async function Uy(e, t, r, i) {
|
|
|
12599
12599
|
return await fetch(_, t);
|
|
12600
12600
|
}
|
|
12601
12601
|
}
|
|
12602
|
-
class
|
|
12602
|
+
class ug extends TransformStream {
|
|
12603
12603
|
constructor() {
|
|
12604
12604
|
let t = new Uint8Array(0), r = "SCAN_CHUNK_SIZE", i = 0;
|
|
12605
12605
|
super({
|
|
12606
12606
|
transform(a, n) {
|
|
12607
|
-
for (t =
|
|
12607
|
+
for (t = Cc([t, a]); t.length > 0; )
|
|
12608
12608
|
if (r === "SCAN_CHUNK_SIZE") {
|
|
12609
12609
|
if (t.length < 3)
|
|
12610
12610
|
return;
|
|
@@ -12736,7 +12736,7 @@ class Kt {
|
|
|
12736
12736
|
return r && (s = new r_(s, r)), new t_(s);
|
|
12737
12737
|
}
|
|
12738
12738
|
}
|
|
12739
|
-
class
|
|
12739
|
+
class Vp extends Kt {
|
|
12740
12740
|
constructor(t) {
|
|
12741
12741
|
super(), this.resource = t;
|
|
12742
12742
|
}
|
|
@@ -12825,7 +12825,7 @@ class xa extends Kt {
|
|
|
12825
12825
|
);
|
|
12826
12826
|
if (!n.ok)
|
|
12827
12827
|
throw new Error(`Could not download "${t}"`);
|
|
12828
|
-
if (n = await
|
|
12828
|
+
if (n = await xc(
|
|
12829
12829
|
n,
|
|
12830
12830
|
((a = this.progress) == null ? void 0 : a.loadingListener) ?? Zy
|
|
12831
12831
|
), n.status !== 200)
|
|
@@ -12978,7 +12978,7 @@ class Qy extends xa {
|
|
|
12978
12978
|
return zn(this.resource.slug);
|
|
12979
12979
|
}
|
|
12980
12980
|
getURL() {
|
|
12981
|
-
return `https://downloads.wordpress.org/theme/${
|
|
12981
|
+
return `https://downloads.wordpress.org/theme/${Yp(this.resource.slug)}`;
|
|
12982
12982
|
}
|
|
12983
12983
|
}
|
|
12984
12984
|
class e_ extends xa {
|
|
@@ -12991,19 +12991,19 @@ class e_ extends xa {
|
|
|
12991
12991
|
}
|
|
12992
12992
|
/** @inheritDoc */
|
|
12993
12993
|
getURL() {
|
|
12994
|
-
return `https://downloads.wordpress.org/plugin/${
|
|
12994
|
+
return `https://downloads.wordpress.org/plugin/${Yp(this.resource.slug)}`;
|
|
12995
12995
|
}
|
|
12996
12996
|
}
|
|
12997
|
-
function
|
|
12997
|
+
function Yp(e) {
|
|
12998
12998
|
return !e || e.endsWith(".zip") ? e : e + ".latest-stable.zip";
|
|
12999
12999
|
}
|
|
13000
|
-
class t_ extends
|
|
13000
|
+
class t_ extends Vp {
|
|
13001
13001
|
/** @inheritDoc */
|
|
13002
13002
|
async resolve() {
|
|
13003
13003
|
return this.promise || (this.promise = this.resource.resolve()), this.promise;
|
|
13004
13004
|
}
|
|
13005
13005
|
}
|
|
13006
|
-
class r_ extends
|
|
13006
|
+
class r_ extends Vp {
|
|
13007
13007
|
constructor(t, r) {
|
|
13008
13008
|
super(t), this.semaphore = r;
|
|
13009
13009
|
}
|
|
@@ -13034,7 +13034,7 @@ class s_ extends Kt {
|
|
|
13034
13034
|
const a = await this.streamBundledFile(this.resource.path), n = a.filesize;
|
|
13035
13035
|
if (!n)
|
|
13036
13036
|
return (r = this.progress) == null || r.set(100), a;
|
|
13037
|
-
const s =
|
|
13037
|
+
const s = Wl(
|
|
13038
13038
|
a.stream(),
|
|
13039
13039
|
n,
|
|
13040
13040
|
(o) => {
|
|
@@ -13065,7 +13065,7 @@ Error details: ${a instanceof Error ? a.message : String(a)}`,
|
|
|
13065
13065
|
return !0;
|
|
13066
13066
|
}
|
|
13067
13067
|
}
|
|
13068
|
-
const
|
|
13068
|
+
const Xp = async (e, { pluginPath: t, pluginName: r }, i) => {
|
|
13069
13069
|
i == null || i.tracker.setCaption(`Activating ${r || t}`);
|
|
13070
13070
|
const a = await e.documentRoot, n = await e.run({
|
|
13071
13071
|
code: `<?php
|
|
@@ -13104,7 +13104,7 @@ const Vp = async (e, { pluginPath: t, pluginName: r }, i) => {
|
|
|
13104
13104
|
DOCROOT: a
|
|
13105
13105
|
}
|
|
13106
13106
|
});
|
|
13107
|
-
n.text &&
|
|
13107
|
+
n.text && Pe.warn(
|
|
13108
13108
|
`Plugin ${t} activation printed the following bytes: ${n.text}`
|
|
13109
13109
|
);
|
|
13110
13110
|
const s = await e.run({
|
|
@@ -13153,10 +13153,10 @@ const Vp = async (e, { pluginPath: t, pluginName: r }, i) => {
|
|
|
13153
13153
|
}
|
|
13154
13154
|
});
|
|
13155
13155
|
if (s.text !== "true")
|
|
13156
|
-
throw s.text !== "false" &&
|
|
13156
|
+
throw s.text !== "false" && Pe.debug(s.text), new Error(
|
|
13157
13157
|
`Plugin ${t} could not be activated – WordPress exited with no error. Sometimes, when $_SERVER or site options are not configured correctly, WordPress exits early with a 301 redirect. Inspect the "debug" logs in the console for more details.`
|
|
13158
13158
|
);
|
|
13159
|
-
},
|
|
13159
|
+
}, Jp = async (e, { themeFolderName: t }, r) => {
|
|
13160
13160
|
r == null || r.tracker.setCaption(`Activating ${t}`);
|
|
13161
13161
|
const i = await e.documentRoot, a = `${i}/wp-content/themes/${t}`;
|
|
13162
13162
|
if (!await e.fileExists(a))
|
|
@@ -13188,12 +13188,12 @@ const Vp = async (e, { pluginPath: t, pluginName: r }, i) => {
|
|
|
13188
13188
|
}
|
|
13189
13189
|
});
|
|
13190
13190
|
if (n.text !== "Theme activated successfully")
|
|
13191
|
-
throw
|
|
13191
|
+
throw Pe.debug(n), new Error(
|
|
13192
13192
|
`Theme ${t} could not be activated – WordPress exited with no error. Sometimes, when $_SERVER or site options are not configured correctly, WordPress exits early with a 301 redirect. Inspect the "debug" logs in the console for more details`
|
|
13193
13193
|
);
|
|
13194
13194
|
}, n_ = async (e, { code: t }) => {
|
|
13195
13195
|
let r = typeof t == "string" ? t : t.content;
|
|
13196
|
-
return (r.includes('"wordpress/wp-load.php"') || r.includes("'wordpress/wp-load.php'")) && (
|
|
13196
|
+
return (r.includes('"wordpress/wp-load.php"') || r.includes("'wordpress/wp-load.php'")) && (Pe.error(
|
|
13197
13197
|
`
|
|
13198
13198
|
It looks like you're trying to load WordPress using a relative path 'wordpress/wp-load.php'.
|
|
13199
13199
|
|
|
@@ -13216,8 +13216,8 @@ This will ensure your code works reliably regardless of the current working dire
|
|
|
13216
13216
|
'"wordpress/wp-load.php"',
|
|
13217
13217
|
'"/wordpress/wp-load.php"'
|
|
13218
13218
|
)), await e.run({ code: r });
|
|
13219
|
-
}, i_ = async (e, { options: t }) => await e.run(t),
|
|
13220
|
-
t.startsWith("/") || (
|
|
13219
|
+
}, i_ = async (e, { options: t }) => await e.run(t), Qp = async (e, { path: t }) => {
|
|
13220
|
+
t.startsWith("/") || (Pe.error(
|
|
13221
13221
|
`
|
|
13222
13222
|
The rm() step in your Blueprint refers to a relative path.
|
|
13223
13223
|
|
|
@@ -13236,7 +13236,7 @@ This will ensure your code works reliably regardless of the current working dire
|
|
|
13236
13236
|
), t = `/${t}`), await e.unlink(t);
|
|
13237
13237
|
}, a_ = async (e, { sql: t }, r) => {
|
|
13238
13238
|
r == null || r.tracker.setCaption("Executing SQL Queries");
|
|
13239
|
-
const i = `/tmp/${
|
|
13239
|
+
const i = `/tmp/${Pc()}.sql`;
|
|
13240
13240
|
await e.writeFile(
|
|
13241
13241
|
i,
|
|
13242
13242
|
new Uint8Array(await t.arrayBuffer())
|
|
@@ -13259,18 +13259,18 @@ This will ensure your code works reliably regardless of the current working dire
|
|
|
13259
13259
|
}
|
|
13260
13260
|
`
|
|
13261
13261
|
});
|
|
13262
|
-
return await
|
|
13262
|
+
return await Qp(e, { path: i }), s;
|
|
13263
13263
|
}, o_ = async (e, { request: t }) => {
|
|
13264
|
-
|
|
13264
|
+
Pe.warn(
|
|
13265
13265
|
'Deprecated: The Blueprint step "request" is deprecated and will be removed in a future release.'
|
|
13266
13266
|
);
|
|
13267
13267
|
const r = await e.request(t);
|
|
13268
13268
|
if (r.httpStatusCode > 399 || r.httpStatusCode < 200)
|
|
13269
|
-
throw
|
|
13269
|
+
throw Pe.warn("WordPress response was", { response: r }), new Error(
|
|
13270
13270
|
`Request failed with status ${r.httpStatusCode}`
|
|
13271
13271
|
);
|
|
13272
13272
|
return r;
|
|
13273
|
-
},
|
|
13273
|
+
}, ec = async (e, t, r, i = !0) => {
|
|
13274
13274
|
const a = `/tmp/file-${Math.random()}.zip`;
|
|
13275
13275
|
if (t instanceof File) {
|
|
13276
13276
|
const s = t;
|
|
@@ -13659,7 +13659,7 @@ function skip_whitespace($tokens) {
|
|
|
13659
13659
|
return $output;
|
|
13660
13660
|
}
|
|
13661
13661
|
`;
|
|
13662
|
-
async function
|
|
13662
|
+
async function tc(e, t, r, i = "rewrite") {
|
|
13663
13663
|
const a = Dn({ wpConfigPath: t, constants: r, whenAlreadyDefined: i });
|
|
13664
13664
|
if ((await e.run({
|
|
13665
13665
|
code: `<?php ob_start(); ?>
|
|
@@ -13684,7 +13684,7 @@ async function f_(e, t) {
|
|
|
13684
13684
|
await e.readFileAsBuffer(
|
|
13685
13685
|
Ee(t, "wp-config-sample.php")
|
|
13686
13686
|
)
|
|
13687
|
-
), await
|
|
13687
|
+
), await tc(e, r, i, "skip");
|
|
13688
13688
|
}
|
|
13689
13689
|
const ka = async (e, { consts: t, method: r = "define-before-run" }) => {
|
|
13690
13690
|
switch (r) {
|
|
@@ -13693,7 +13693,7 @@ const ka = async (e, { consts: t, method: r = "define-before-run" }) => {
|
|
|
13693
13693
|
break;
|
|
13694
13694
|
case "rewrite-wp-config": {
|
|
13695
13695
|
const i = await e.documentRoot, a = Ee(i, "/wp-config.php");
|
|
13696
|
-
await
|
|
13696
|
+
await tc(
|
|
13697
13697
|
e,
|
|
13698
13698
|
a,
|
|
13699
13699
|
t,
|
|
@@ -13709,7 +13709,7 @@ async function p_(e, t) {
|
|
|
13709
13709
|
for (const r in t)
|
|
13710
13710
|
await e.defineConstant(r, t[r]);
|
|
13711
13711
|
}
|
|
13712
|
-
const
|
|
13712
|
+
const rc = async (e, { options: t }) => {
|
|
13713
13713
|
const r = await e.documentRoot;
|
|
13714
13714
|
await e.run({
|
|
13715
13715
|
code: `<?php
|
|
@@ -13745,7 +13745,7 @@ const ec = async (e, { options: t }) => {
|
|
|
13745
13745
|
* like the JavaScript parser or Composer are removed.
|
|
13746
13746
|
*/
|
|
13747
13747
|
url: "https://playground.wordpress.net/wp-cli.phar"
|
|
13748
|
-
},
|
|
13748
|
+
}, sc = async (e, t = Sa) => {
|
|
13749
13749
|
if (!await e.fileExists(t))
|
|
13750
13750
|
throw new Error(`wp-cli.phar not found at ${t}.
|
|
13751
13751
|
You can enable wp-cli support by adding "wp-cli" to the list of extra libraries in your blueprint as follows:
|
|
@@ -13754,14 +13754,14 @@ const ec = async (e, { options: t }) => {
|
|
|
13754
13754
|
}
|
|
13755
13755
|
Read more about it in the documentation.
|
|
13756
13756
|
https://wordpress.github.io/wordpress-playground/blueprints/data-format#extra-libraries`);
|
|
13757
|
-
},
|
|
13758
|
-
await
|
|
13757
|
+
}, nc = async (e, { command: t, wpCliPath: r = Sa }) => {
|
|
13758
|
+
await sc(e, r);
|
|
13759
13759
|
let i;
|
|
13760
13760
|
if (typeof t == "string" ? (t = t.trim(), i = d_(t)) : i = t, i.shift() !== "wp")
|
|
13761
13761
|
throw new Error('The first argument must be "wp".');
|
|
13762
13762
|
let n = !1;
|
|
13763
13763
|
const s = i.map((p) => p.startsWith("wordpress/") ? (n = !0, `/${p}`) : p);
|
|
13764
|
-
n &&
|
|
13764
|
+
n && Pe.error(
|
|
13765
13765
|
`
|
|
13766
13766
|
The wp-cli step in your Blueprint refers to a relative path.
|
|
13767
13767
|
|
|
@@ -13834,7 +13834,7 @@ function d_(e) {
|
|
|
13834
13834
|
return s && n.push(s), n;
|
|
13835
13835
|
}
|
|
13836
13836
|
const h_ = async (e, { wpCliPath: t }) => {
|
|
13837
|
-
await
|
|
13837
|
+
await sc(e, t), await ka(e, {
|
|
13838
13838
|
consts: {
|
|
13839
13839
|
WP_ALLOW_MULTISITE: 1
|
|
13840
13840
|
}
|
|
@@ -13845,16 +13845,16 @@ const h_ = async (e, { wpCliPath: t }) => {
|
|
|
13845
13845
|
throw r.hostname === "localhost" && (n += " For development, you can set up a playground.test domain using the instructions at https://wordpress.github.io/wordpress-playground/contributing/code."), new Error(n);
|
|
13846
13846
|
}
|
|
13847
13847
|
const i = r.pathname.replace(/\/$/, "") + "/", a = `${r.protocol}//${r.hostname}${i}`;
|
|
13848
|
-
await
|
|
13848
|
+
await rc(e, {
|
|
13849
13849
|
options: {
|
|
13850
13850
|
siteurl: a,
|
|
13851
13851
|
home: a
|
|
13852
13852
|
}
|
|
13853
|
-
}), await
|
|
13853
|
+
}), await nc(e, {
|
|
13854
13854
|
command: "wp core multisite-convert"
|
|
13855
13855
|
});
|
|
13856
13856
|
}, m_ = async (e, { fromPath: t, toPath: r }) => {
|
|
13857
|
-
(!t.startsWith("/") || !r.startsWith("/")) &&
|
|
13857
|
+
(!t.startsWith("/") || !r.startsWith("/")) && Pe.error(
|
|
13858
13858
|
`
|
|
13859
13859
|
The cp() step in your Blueprint refers to a relative path.
|
|
13860
13860
|
|
|
@@ -13875,7 +13875,7 @@ This will ensure your code works reliably regardless of the current working dire
|
|
|
13875
13875
|
await e.readFileAsBuffer(t)
|
|
13876
13876
|
);
|
|
13877
13877
|
}, y_ = async (e, { fromPath: t, toPath: r }) => {
|
|
13878
|
-
(!t.startsWith("/") || !r.startsWith("/")) &&
|
|
13878
|
+
(!t.startsWith("/") || !r.startsWith("/")) && Pe.error(
|
|
13879
13879
|
`
|
|
13880
13880
|
The mv() step in your Blueprint refers to a relative path.
|
|
13881
13881
|
|
|
@@ -13893,7 +13893,7 @@ This will ensure your code works reliably regardless of the current working dire
|
|
|
13893
13893
|
`.trim()
|
|
13894
13894
|
), t.startsWith("/") || (t = `/${t}`), r.startsWith("/") || (r = `/${r}`), await e.mv(t, r);
|
|
13895
13895
|
}, __ = async (e, { path: t }) => {
|
|
13896
|
-
t.startsWith("/") ||
|
|
13896
|
+
t.startsWith("/") || Pe.error(
|
|
13897
13897
|
`
|
|
13898
13898
|
The mkdir() step in your Blueprint refers to a relative path.
|
|
13899
13899
|
|
|
@@ -13911,7 +13911,7 @@ This will ensure your code works reliably regardless of the current working dire
|
|
|
13911
13911
|
`.trim()
|
|
13912
13912
|
), await e.mkdir(t);
|
|
13913
13913
|
}, g_ = async (e, { path: t }) => {
|
|
13914
|
-
t.startsWith("/") || (
|
|
13914
|
+
t.startsWith("/") || (Pe.error(
|
|
13915
13915
|
`
|
|
13916
13916
|
The rmdir() step in your Blueprint refers to a relative path.
|
|
13917
13917
|
|
|
@@ -13929,7 +13929,7 @@ This will ensure your code works reliably regardless of the current working dire
|
|
|
13929
13929
|
`.trim()
|
|
13930
13930
|
), t = `/${t}`), await e.rmdir(t);
|
|
13931
13931
|
}, Ea = async (e, { path: t, data: r }) => {
|
|
13932
|
-
r instanceof File && (r = new Uint8Array(await r.arrayBuffer())), t.startsWith("/") || (
|
|
13932
|
+
r instanceof File && (r = new Uint8Array(await r.arrayBuffer())), t.startsWith("/") || (Pe.error(
|
|
13933
13933
|
`
|
|
13934
13934
|
The writeFile() step in your Blueprint refers to a relative path.
|
|
13935
13935
|
|
|
@@ -13947,7 +13947,7 @@ This will ensure your code works reliably regardless of the current working dire
|
|
|
13947
13947
|
`.trim()
|
|
13948
13948
|
), t = `/${t}`), t.startsWith("/wordpress/wp-content/mu-plugins") && !await e.fileExists("/wordpress/wp-content/mu-plugins") && await e.mkdir("/wordpress/wp-content/mu-plugins"), await e.writeFile(t, r);
|
|
13949
13949
|
}, w_ = async (e, { writeToPath: t, filesTree: r }) => {
|
|
13950
|
-
t.startsWith("/") || (
|
|
13950
|
+
t.startsWith("/") || (Pe.error(
|
|
13951
13951
|
`
|
|
13952
13952
|
The writeFiles() step in your Blueprint refers to a relative path.
|
|
13953
13953
|
|
|
@@ -13964,7 +13964,7 @@ Use: writeFiles({ writeToPath: '/wordpress/wp-content/plugins/my-plugin'
|
|
|
13964
13964
|
This will ensure your code works reliably regardless of the current working directory.
|
|
13965
13965
|
`.trim()
|
|
13966
13966
|
), t = `/${t}`), await Hn(e, t, r.files);
|
|
13967
|
-
},
|
|
13967
|
+
}, ic = async (e, { siteUrl: t }) => {
|
|
13968
13968
|
await ka(e, {
|
|
13969
13969
|
consts: {
|
|
13970
13970
|
WP_HOME: t,
|
|
@@ -14036,7 +14036,7 @@ async function v_(e, t, r) {
|
|
|
14036
14036
|
}
|
|
14037
14037
|
});
|
|
14038
14038
|
}
|
|
14039
|
-
const
|
|
14039
|
+
const ac = async (e, { themeSlug: t = "" }, r) => {
|
|
14040
14040
|
var a;
|
|
14041
14041
|
(a = r == null ? void 0 : r.tracker) == null || a.setCaption("Importing theme starter content");
|
|
14042
14042
|
const i = await e.documentRoot;
|
|
@@ -14092,13 +14092,13 @@ const nc = async (e, { themeSlug: t = "" }, r) => {
|
|
|
14092
14092
|
});
|
|
14093
14093
|
}, Pa = async (e, { zipFile: t, zipPath: r, extractToPath: i }) => {
|
|
14094
14094
|
if (r)
|
|
14095
|
-
|
|
14095
|
+
Pe.warn(
|
|
14096
14096
|
'The "zipPath" option of the unzip() Blueprint step is deprecated and will be removed. Use "zipFile" instead.'
|
|
14097
14097
|
);
|
|
14098
14098
|
else if (!t)
|
|
14099
14099
|
throw new Error("Either zipPath or zipFile must be provided");
|
|
14100
|
-
await
|
|
14101
|
-
},
|
|
14100
|
+
await ec(e, t || r, i);
|
|
14101
|
+
}, oc = [
|
|
14102
14102
|
"db.php",
|
|
14103
14103
|
"plugins/akismet",
|
|
14104
14104
|
"plugins/hello.php",
|
|
@@ -14127,7 +14127,7 @@ const nc = async (e, { themeSlug: t = "" }, r) => {
|
|
|
14127
14127
|
extractToPath: a
|
|
14128
14128
|
}), a = Ee(a, r);
|
|
14129
14129
|
const n = Ee(a, "wp-content"), s = Ee(i, "wp-content");
|
|
14130
|
-
for (const c of
|
|
14130
|
+
for (const c of oc) {
|
|
14131
14131
|
const y = Ee(
|
|
14132
14132
|
n,
|
|
14133
14133
|
c
|
|
@@ -14151,7 +14151,7 @@ const nc = async (e, { themeSlug: t = "" }, r) => {
|
|
|
14151
14151
|
Ee(a, c),
|
|
14152
14152
|
Ee(i, c)
|
|
14153
14153
|
);
|
|
14154
|
-
await e.rmdir(a), await f_(e, i), await
|
|
14154
|
+
await e.rmdir(a), await f_(e, i), await ic(e, {
|
|
14155
14155
|
siteUrl: await e.absoluteUrl
|
|
14156
14156
|
});
|
|
14157
14157
|
const p = wt(
|
|
@@ -14173,13 +14173,13 @@ async function k_(e) {
|
|
|
14173
14173
|
});
|
|
14174
14174
|
return new File([t.bytes], "export.xml");
|
|
14175
14175
|
}
|
|
14176
|
-
async function
|
|
14176
|
+
async function lc(e, {
|
|
14177
14177
|
targetPath: t,
|
|
14178
14178
|
zipFile: r,
|
|
14179
14179
|
ifAlreadyInstalled: i = "overwrite",
|
|
14180
14180
|
targetFolderName: a = ""
|
|
14181
14181
|
}) {
|
|
14182
|
-
const s = r.name.replace(/\.zip$/, ""), o = Ee(await e.documentRoot, "wp-content"), f = Ee(o,
|
|
14182
|
+
const s = r.name.replace(/\.zip$/, ""), o = Ee(await e.documentRoot, "wp-content"), f = Ee(o, Ml()), p = Ee(f, "assets", s);
|
|
14183
14183
|
await e.fileExists(p) && await e.rmdir(f, {
|
|
14184
14184
|
recursive: !0
|
|
14185
14185
|
}), await e.mkdir(f);
|
|
@@ -14227,7 +14227,7 @@ async function ac(e, {
|
|
|
14227
14227
|
}
|
|
14228
14228
|
}
|
|
14229
14229
|
const S_ = async (e, { pluginData: t, pluginZipFile: r, ifAlreadyInstalled: i, options: a = {} }, n) => {
|
|
14230
|
-
r && (t = r,
|
|
14230
|
+
r && (t = r, Pe.warn(
|
|
14231
14231
|
'The "pluginZipFile" option is deprecated. Use "pluginData" instead.'
|
|
14232
14232
|
));
|
|
14233
14233
|
const s = Ee(
|
|
@@ -14248,7 +14248,7 @@ const S_ = async (e, { pluginData: t, pluginZipFile: r, ifAlreadyInstalled: i, o
|
|
|
14248
14248
|
p = zn(h), n == null || n.tracker.setCaption(
|
|
14249
14249
|
`Installing the ${p} plugin`
|
|
14250
14250
|
);
|
|
14251
|
-
const _ = await
|
|
14251
|
+
const _ = await lc(e, {
|
|
14252
14252
|
ifAlreadyInstalled: i,
|
|
14253
14253
|
zipFile: t,
|
|
14254
14254
|
targetPath: `${await e.documentRoot}/wp-content/plugins`,
|
|
@@ -14278,7 +14278,7 @@ const S_ = async (e, { pluginData: t, pluginZipFile: r, ifAlreadyInstalled: i, o
|
|
|
14278
14278
|
rmRoot: !0
|
|
14279
14279
|
}), f = h;
|
|
14280
14280
|
}
|
|
14281
|
-
("activate" in a ? a.activate : !0) && await
|
|
14281
|
+
("activate" in a ? a.activate : !0) && await Xp(
|
|
14282
14282
|
e,
|
|
14283
14283
|
{
|
|
14284
14284
|
pluginPath: f,
|
|
@@ -14287,14 +14287,14 @@ const S_ = async (e, { pluginData: t, pluginZipFile: r, ifAlreadyInstalled: i, o
|
|
|
14287
14287
|
n
|
|
14288
14288
|
);
|
|
14289
14289
|
}, E_ = async (e, { themeData: t, themeZipFile: r, ifAlreadyInstalled: i, options: a = {} }, n) => {
|
|
14290
|
-
r && (t = r,
|
|
14290
|
+
r && (t = r, Pe.warn(
|
|
14291
14291
|
'The "themeZipFile" option is deprecated. Use "themeData" instead.'
|
|
14292
14292
|
));
|
|
14293
14293
|
const s = "targetFolderName" in a ? a.targetFolderName : "";
|
|
14294
14294
|
let o = "", f = "";
|
|
14295
14295
|
if (t instanceof File) {
|
|
14296
14296
|
const y = t.name.split("/").pop() || "theme.zip";
|
|
14297
|
-
f = zn(y), n == null || n.tracker.setCaption(`Installing the ${f} theme`), o = (await
|
|
14297
|
+
f = zn(y), n == null || n.tracker.setCaption(`Installing the ${f} theme`), o = (await lc(e, {
|
|
14298
14298
|
ifAlreadyInstalled: i,
|
|
14299
14299
|
zipFile: t,
|
|
14300
14300
|
targetPath: `${await e.documentRoot}/wp-content/themes`,
|
|
@@ -14312,13 +14312,13 @@ const S_ = async (e, { pluginData: t, pluginZipFile: r, ifAlreadyInstalled: i, o
|
|
|
14312
14312
|
rmRoot: !0
|
|
14313
14313
|
});
|
|
14314
14314
|
}
|
|
14315
|
-
("activate" in a ? a.activate : !0) && await
|
|
14315
|
+
("activate" in a ? a.activate : !0) && await Jp(
|
|
14316
14316
|
e,
|
|
14317
14317
|
{
|
|
14318
14318
|
themeFolderName: o
|
|
14319
14319
|
},
|
|
14320
14320
|
n
|
|
14321
|
-
), ("importStarterContent" in a ? a.importStarterContent : !1) && await
|
|
14321
|
+
), ("importStarterContent" in a ? a.importStarterContent : !1) && await ac(
|
|
14322
14322
|
e,
|
|
14323
14323
|
{
|
|
14324
14324
|
themeSlug: o
|
|
@@ -14370,7 +14370,7 @@ const S_ = async (e, { pluginData: t, pluginZipFile: r, ifAlreadyInstalled: i, o
|
|
|
14370
14370
|
});
|
|
14371
14371
|
}, C_ = async (e, { selfContained: t = !1 } = {}) => {
|
|
14372
14372
|
const r = "/tmp/wordpress-playground.zip", i = await e.documentRoot, a = Ee(i, "wp-content");
|
|
14373
|
-
let n =
|
|
14373
|
+
let n = oc;
|
|
14374
14374
|
t && (n = n.filter((f) => !f.startsWith("themes/twenty")).filter(
|
|
14375
14375
|
(f) => f !== "mu-plugins/sqlite-database-integration"
|
|
14376
14376
|
));
|
|
@@ -14545,7 +14545,7 @@ const R_ = async (e, t) => {
|
|
|
14545
14545
|
`Failed to download translations for ${_}: ${L.statusText}`
|
|
14546
14546
|
);
|
|
14547
14547
|
let m = `${i}/wp-content/languages`;
|
|
14548
|
-
_ === "plugin" ? m += "/plugins" : _ === "theme" && (m += "/themes"), await
|
|
14548
|
+
_ === "plugin" ? m += "/plugins" : _ === "theme" && (m += "/themes"), await ec(
|
|
14549
14549
|
e,
|
|
14550
14550
|
new File(
|
|
14551
14551
|
[await L.blob()],
|
|
@@ -14558,7 +14558,7 @@ const R_ = async (e, t) => {
|
|
|
14558
14558
|
throw new Error(
|
|
14559
14559
|
`Failed to download translations for WordPress. Please check if the language code ${t} is correct. You can find all available languages and translations on https://translate.wordpress.org/.`
|
|
14560
14560
|
);
|
|
14561
|
-
|
|
14561
|
+
Pe.warn(
|
|
14562
14562
|
`Error downloading translations for ${_}: ${L}`
|
|
14563
14563
|
);
|
|
14564
14564
|
}
|
|
@@ -14567,14 +14567,14 @@ const R_ = async (e, t) => {
|
|
|
14567
14567
|
await Promise.all(y);
|
|
14568
14568
|
}, D_ = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
14569
14569
|
__proto__: null,
|
|
14570
|
-
activatePlugin:
|
|
14571
|
-
activateTheme:
|
|
14570
|
+
activatePlugin: Xp,
|
|
14571
|
+
activateTheme: Jp,
|
|
14572
14572
|
cp: m_,
|
|
14573
|
-
defineSiteUrl:
|
|
14573
|
+
defineSiteUrl: ic,
|
|
14574
14574
|
defineWpConfigConsts: ka,
|
|
14575
14575
|
enableMultisite: h_,
|
|
14576
14576
|
exportWXR: k_,
|
|
14577
|
-
importThemeStarterContent:
|
|
14577
|
+
importThemeStarterContent: ac,
|
|
14578
14578
|
importWordPressFiles: x_,
|
|
14579
14579
|
importWxr: b_,
|
|
14580
14580
|
installPlugin: S_,
|
|
@@ -14584,17 +14584,17 @@ const R_ = async (e, t) => {
|
|
|
14584
14584
|
mv: y_,
|
|
14585
14585
|
request: o_,
|
|
14586
14586
|
resetData: A_,
|
|
14587
|
-
rm:
|
|
14587
|
+
rm: Qp,
|
|
14588
14588
|
rmdir: g_,
|
|
14589
14589
|
runPHP: n_,
|
|
14590
14590
|
runPHPWithOptions: i_,
|
|
14591
14591
|
runSql: a_,
|
|
14592
14592
|
runWpInstallationWizard: T_,
|
|
14593
14593
|
setSiteLanguage: I_,
|
|
14594
|
-
setSiteOptions:
|
|
14594
|
+
setSiteOptions: rc,
|
|
14595
14595
|
unzip: Pa,
|
|
14596
14596
|
updateUserMeta: c_,
|
|
14597
|
-
wpCLI:
|
|
14597
|
+
wpCLI: nc,
|
|
14598
14598
|
writeFile: Ea,
|
|
14599
14599
|
writeFiles: w_,
|
|
14600
14600
|
zipWpContent: C_
|
|
@@ -14728,7 +14728,7 @@ const R_ = async (e, t) => {
|
|
|
14728
14728
|
enum: ["8.4", "8.3", "8.2", "8.1", "8.0", "7.4", "7.3", "7.2"]
|
|
14729
14729
|
}, F_ = {
|
|
14730
14730
|
additionalProperties: { type: ["string", "boolean", "number"] }
|
|
14731
|
-
},
|
|
14731
|
+
}, fc = Object.prototype.hasOwnProperty;
|
|
14732
14732
|
function ke(e, { instancePath: t = "", parentData: r, parentDataProperty: i, rootData: a = e } = {}) {
|
|
14733
14733
|
let n = null, s = 0;
|
|
14734
14734
|
const o = s;
|
|
@@ -16609,7 +16609,7 @@ function Ot(e, { instancePath: t = "", parentData: r, parentDataProperty: i, roo
|
|
|
16609
16609
|
}
|
|
16610
16610
|
return Ot.errors = n, s === 0;
|
|
16611
16611
|
}
|
|
16612
|
-
const
|
|
16612
|
+
const pc = {
|
|
16613
16613
|
enum: ["GET", "POST", "HEAD", "OPTIONS", "PATCH", "PUT", "DELETE"]
|
|
16614
16614
|
};
|
|
16615
16615
|
function yt(e, { instancePath: t = "", parentData: r, parentDataProperty: i, rootData: a = e } = {}) {
|
|
@@ -16660,7 +16660,7 @@ function yt(e, { instancePath: t = "", parentData: r, parentDataProperty: i, roo
|
|
|
16660
16660
|
instancePath: t + "/method",
|
|
16661
16661
|
schemaPath: "#/definitions/HTTPMethod/enum",
|
|
16662
16662
|
keyword: "enum",
|
|
16663
|
-
params: { allowedValues:
|
|
16663
|
+
params: { allowedValues: pc.enum },
|
|
16664
16664
|
message: "must be equal to one of the allowed values"
|
|
16665
16665
|
}
|
|
16666
16666
|
], !1;
|
|
@@ -17157,8 +17157,8 @@ function yt(e, { instancePath: t = "", parentData: r, parentDataProperty: i, roo
|
|
|
17157
17157
|
), s++;
|
|
17158
17158
|
} else {
|
|
17159
17159
|
const Se = s;
|
|
17160
|
-
for (const
|
|
17161
|
-
if (
|
|
17160
|
+
for (const Ae in Z)
|
|
17161
|
+
if (Ae !== "byteLength") {
|
|
17162
17162
|
const Ve = {
|
|
17163
17163
|
instancePath: t + "/body/" + I.replace(
|
|
17164
17164
|
/~/g,
|
|
@@ -17170,7 +17170,7 @@ function yt(e, { instancePath: t = "", parentData: r, parentDataProperty: i, roo
|
|
|
17170
17170
|
schemaPath: "#/properties/body/anyOf/2/additionalProperties/anyOf/1/properties/buffer/additionalProperties",
|
|
17171
17171
|
keyword: "additionalProperties",
|
|
17172
17172
|
params: {
|
|
17173
|
-
additionalProperty:
|
|
17173
|
+
additionalProperty: Ae
|
|
17174
17174
|
},
|
|
17175
17175
|
message: "must NOT have additional properties"
|
|
17176
17176
|
};
|
|
@@ -17182,9 +17182,9 @@ function yt(e, { instancePath: t = "", parentData: r, parentDataProperty: i, roo
|
|
|
17182
17182
|
break;
|
|
17183
17183
|
}
|
|
17184
17184
|
if (Se === s && Z.byteLength !== void 0) {
|
|
17185
|
-
let
|
|
17186
|
-
if (!(typeof
|
|
17187
|
-
|
|
17185
|
+
let Ae = Z.byteLength;
|
|
17186
|
+
if (!(typeof Ae == "number" && isFinite(
|
|
17187
|
+
Ae
|
|
17188
17188
|
))) {
|
|
17189
17189
|
const Ve = {
|
|
17190
17190
|
instancePath: t + "/body/" + I.replace(
|
|
@@ -17475,7 +17475,7 @@ function yt(e, { instancePath: t = "", parentData: r, parentDataProperty: i, roo
|
|
|
17475
17475
|
if (!(typeof ie == "number" && isFinite(
|
|
17476
17476
|
ie
|
|
17477
17477
|
))) {
|
|
17478
|
-
const
|
|
17478
|
+
const Ae = {
|
|
17479
17479
|
instancePath: t + "/body/" + I.replace(
|
|
17480
17480
|
/~/g,
|
|
17481
17481
|
"~0"
|
|
@@ -17491,9 +17491,9 @@ function yt(e, { instancePath: t = "", parentData: r, parentDataProperty: i, roo
|
|
|
17491
17491
|
message: "must be number"
|
|
17492
17492
|
};
|
|
17493
17493
|
n === null ? n = [
|
|
17494
|
-
|
|
17494
|
+
Ae
|
|
17495
17495
|
] : n.push(
|
|
17496
|
-
|
|
17496
|
+
Ae
|
|
17497
17497
|
), s++;
|
|
17498
17498
|
}
|
|
17499
17499
|
var m = ae === s;
|
|
@@ -17729,7 +17729,7 @@ function Ue(e, { instancePath: t = "", parentData: r, parentDataProperty: i, roo
|
|
|
17729
17729
|
if (e && typeof e == "object" && !Array.isArray(e)) {
|
|
17730
17730
|
const L = s;
|
|
17731
17731
|
for (const m in e)
|
|
17732
|
-
if (!
|
|
17732
|
+
if (!fc.call(j_.properties, m))
|
|
17733
17733
|
return Ue.errors = [
|
|
17734
17734
|
{
|
|
17735
17735
|
instancePath: t,
|
|
@@ -17808,7 +17808,7 @@ function Ue(e, { instancePath: t = "", parentData: r, parentDataProperty: i, roo
|
|
|
17808
17808
|
schemaPath: "#/definitions/HTTPMethod/enum",
|
|
17809
17809
|
keyword: "enum",
|
|
17810
17810
|
params: {
|
|
17811
|
-
allowedValues:
|
|
17811
|
+
allowedValues: pc.enum
|
|
17812
17812
|
},
|
|
17813
17813
|
message: "must be equal to one of the allowed values"
|
|
17814
17814
|
}
|
|
@@ -20189,22 +20189,22 @@ function w(e, { instancePath: t = "", parentData: r, parentDataProperty: i, root
|
|
|
20189
20189
|
l
|
|
20190
20190
|
)) {
|
|
20191
20191
|
const re = s;
|
|
20192
|
-
for (const
|
|
20193
|
-
if (!(
|
|
20192
|
+
for (const Te in l)
|
|
20193
|
+
if (!(Te === "activate" || Te === "targetFolderName"))
|
|
20194
20194
|
return w.errors = [
|
|
20195
20195
|
{
|
|
20196
20196
|
instancePath: t + "/options",
|
|
20197
20197
|
schemaPath: "#/definitions/InstallPluginOptions/additionalProperties",
|
|
20198
20198
|
keyword: "additionalProperties",
|
|
20199
20199
|
params: {
|
|
20200
|
-
additionalProperty:
|
|
20200
|
+
additionalProperty: Te
|
|
20201
20201
|
},
|
|
20202
20202
|
message: "must NOT have additional properties"
|
|
20203
20203
|
}
|
|
20204
20204
|
], !1;
|
|
20205
20205
|
if (re === s) {
|
|
20206
20206
|
if (l.activate !== void 0) {
|
|
20207
|
-
const
|
|
20207
|
+
const Te = s;
|
|
20208
20208
|
if (typeof l.activate != "boolean")
|
|
20209
20209
|
return w.errors = [
|
|
20210
20210
|
{
|
|
@@ -20217,12 +20217,12 @@ function w(e, { instancePath: t = "", parentData: r, parentDataProperty: i, root
|
|
|
20217
20217
|
message: "must be boolean"
|
|
20218
20218
|
}
|
|
20219
20219
|
], !1;
|
|
20220
|
-
var D =
|
|
20220
|
+
var D = Te === s;
|
|
20221
20221
|
} else
|
|
20222
20222
|
var D = !0;
|
|
20223
20223
|
if (D)
|
|
20224
20224
|
if (l.targetFolderName !== void 0) {
|
|
20225
|
-
const
|
|
20225
|
+
const Te = s;
|
|
20226
20226
|
if (typeof l.targetFolderName != "string")
|
|
20227
20227
|
return w.errors = [
|
|
20228
20228
|
{
|
|
@@ -20235,7 +20235,7 @@ function w(e, { instancePath: t = "", parentData: r, parentDataProperty: i, root
|
|
|
20235
20235
|
message: "must be string"
|
|
20236
20236
|
}
|
|
20237
20237
|
], !1;
|
|
20238
|
-
var D =
|
|
20238
|
+
var D = Te === s;
|
|
20239
20239
|
} else
|
|
20240
20240
|
var D = !0;
|
|
20241
20241
|
}
|
|
@@ -20517,22 +20517,22 @@ function w(e, { instancePath: t = "", parentData: r, parentDataProperty: i, root
|
|
|
20517
20517
|
l
|
|
20518
20518
|
)) {
|
|
20519
20519
|
const re = s;
|
|
20520
|
-
for (const
|
|
20521
|
-
if (!(
|
|
20520
|
+
for (const Te in l)
|
|
20521
|
+
if (!(Te === "activate" || Te === "importStarterContent" || Te === "targetFolderName"))
|
|
20522
20522
|
return w.errors = [
|
|
20523
20523
|
{
|
|
20524
20524
|
instancePath: t + "/options",
|
|
20525
20525
|
schemaPath: "#/definitions/InstallThemeOptions/additionalProperties",
|
|
20526
20526
|
keyword: "additionalProperties",
|
|
20527
20527
|
params: {
|
|
20528
|
-
additionalProperty:
|
|
20528
|
+
additionalProperty: Te
|
|
20529
20529
|
},
|
|
20530
20530
|
message: "must NOT have additional properties"
|
|
20531
20531
|
}
|
|
20532
20532
|
], !1;
|
|
20533
20533
|
if (re === s) {
|
|
20534
20534
|
if (l.activate !== void 0) {
|
|
20535
|
-
const
|
|
20535
|
+
const Te = s;
|
|
20536
20536
|
if (typeof l.activate != "boolean")
|
|
20537
20537
|
return w.errors = [
|
|
20538
20538
|
{
|
|
@@ -20545,12 +20545,12 @@ function w(e, { instancePath: t = "", parentData: r, parentDataProperty: i, root
|
|
|
20545
20545
|
message: "must be boolean"
|
|
20546
20546
|
}
|
|
20547
20547
|
], !1;
|
|
20548
|
-
var M =
|
|
20548
|
+
var M = Te === s;
|
|
20549
20549
|
} else
|
|
20550
20550
|
var M = !0;
|
|
20551
20551
|
if (M) {
|
|
20552
20552
|
if (l.importStarterContent !== void 0) {
|
|
20553
|
-
const
|
|
20553
|
+
const Te = s;
|
|
20554
20554
|
if (typeof l.importStarterContent != "boolean")
|
|
20555
20555
|
return w.errors = [
|
|
20556
20556
|
{
|
|
@@ -20563,12 +20563,12 @@ function w(e, { instancePath: t = "", parentData: r, parentDataProperty: i, root
|
|
|
20563
20563
|
message: "must be boolean"
|
|
20564
20564
|
}
|
|
20565
20565
|
], !1;
|
|
20566
|
-
var M =
|
|
20566
|
+
var M = Te === s;
|
|
20567
20567
|
} else
|
|
20568
20568
|
var M = !0;
|
|
20569
20569
|
if (M)
|
|
20570
20570
|
if (l.targetFolderName !== void 0) {
|
|
20571
|
-
const
|
|
20571
|
+
const Te = s;
|
|
20572
20572
|
if (typeof l.targetFolderName != "string")
|
|
20573
20573
|
return w.errors = [
|
|
20574
20574
|
{
|
|
@@ -20581,7 +20581,7 @@ function w(e, { instancePath: t = "", parentData: r, parentDataProperty: i, root
|
|
|
20581
20581
|
message: "must be string"
|
|
20582
20582
|
}
|
|
20583
20583
|
], !1;
|
|
20584
|
-
var M =
|
|
20584
|
+
var M = Te === s;
|
|
20585
20585
|
} else
|
|
20586
20586
|
var M = !0;
|
|
20587
20587
|
}
|
|
@@ -21578,10 +21578,10 @@ function w(e, { instancePath: t = "", parentData: r, parentDataProperty: i, root
|
|
|
21578
21578
|
message: "must be object"
|
|
21579
21579
|
}
|
|
21580
21580
|
], !1;
|
|
21581
|
-
var
|
|
21581
|
+
var Ae = F === s;
|
|
21582
21582
|
} else
|
|
21583
|
-
var
|
|
21584
|
-
if (
|
|
21583
|
+
var Ae = !0;
|
|
21584
|
+
if (Ae) {
|
|
21585
21585
|
if (e.step !== void 0) {
|
|
21586
21586
|
let l = e.step;
|
|
21587
21587
|
const F = s;
|
|
@@ -21609,10 +21609,10 @@ function w(e, { instancePath: t = "", parentData: r, parentDataProperty: i, root
|
|
|
21609
21609
|
message: "must be equal to constant"
|
|
21610
21610
|
}
|
|
21611
21611
|
], !1;
|
|
21612
|
-
var
|
|
21612
|
+
var Ae = F === s;
|
|
21613
21613
|
} else
|
|
21614
|
-
var
|
|
21615
|
-
if (
|
|
21614
|
+
var Ae = !0;
|
|
21615
|
+
if (Ae)
|
|
21616
21616
|
if (e.path !== void 0) {
|
|
21617
21617
|
const l = s;
|
|
21618
21618
|
if (typeof e.path != "string")
|
|
@@ -21627,9 +21627,9 @@ function w(e, { instancePath: t = "", parentData: r, parentDataProperty: i, root
|
|
|
21627
21627
|
message: "must be string"
|
|
21628
21628
|
}
|
|
21629
21629
|
], !1;
|
|
21630
|
-
var
|
|
21630
|
+
var Ae = l === s;
|
|
21631
21631
|
} else
|
|
21632
|
-
var
|
|
21632
|
+
var Ae = !0;
|
|
21633
21633
|
}
|
|
21634
21634
|
}
|
|
21635
21635
|
}
|
|
@@ -22415,22 +22415,22 @@ function w(e, { instancePath: t = "", parentData: r, parentDataProperty: i, root
|
|
|
22415
22415
|
l
|
|
22416
22416
|
)) {
|
|
22417
22417
|
const re = s;
|
|
22418
|
-
for (const
|
|
22419
|
-
if (!(
|
|
22418
|
+
for (const Te in l)
|
|
22419
|
+
if (!(Te === "adminUsername" || Te === "adminPassword"))
|
|
22420
22420
|
return w.errors = [
|
|
22421
22421
|
{
|
|
22422
22422
|
instancePath: t + "/options",
|
|
22423
22423
|
schemaPath: "#/definitions/WordPressInstallationOptions/additionalProperties",
|
|
22424
22424
|
keyword: "additionalProperties",
|
|
22425
22425
|
params: {
|
|
22426
|
-
additionalProperty:
|
|
22426
|
+
additionalProperty: Te
|
|
22427
22427
|
},
|
|
22428
22428
|
message: "must NOT have additional properties"
|
|
22429
22429
|
}
|
|
22430
22430
|
], !1;
|
|
22431
22431
|
if (re === s) {
|
|
22432
22432
|
if (l.adminUsername !== void 0) {
|
|
22433
|
-
const
|
|
22433
|
+
const Te = s;
|
|
22434
22434
|
if (typeof l.adminUsername != "string")
|
|
22435
22435
|
return w.errors = [
|
|
22436
22436
|
{
|
|
@@ -22443,12 +22443,12 @@ function w(e, { instancePath: t = "", parentData: r, parentDataProperty: i, root
|
|
|
22443
22443
|
message: "must be string"
|
|
22444
22444
|
}
|
|
22445
22445
|
], !1;
|
|
22446
|
-
var T =
|
|
22446
|
+
var T = Te === s;
|
|
22447
22447
|
} else
|
|
22448
22448
|
var T = !0;
|
|
22449
22449
|
if (T)
|
|
22450
22450
|
if (l.adminPassword !== void 0) {
|
|
22451
|
-
const
|
|
22451
|
+
const Te = s;
|
|
22452
22452
|
if (typeof l.adminPassword != "string")
|
|
22453
22453
|
return w.errors = [
|
|
22454
22454
|
{
|
|
@@ -22461,7 +22461,7 @@ function w(e, { instancePath: t = "", parentData: r, parentDataProperty: i, root
|
|
|
22461
22461
|
message: "must be string"
|
|
22462
22462
|
}
|
|
22463
22463
|
], !1;
|
|
22464
|
-
var T =
|
|
22464
|
+
var T = Te === s;
|
|
22465
22465
|
} else
|
|
22466
22466
|
var T = !0;
|
|
22467
22467
|
}
|
|
@@ -24370,7 +24370,7 @@ function me(e, { instancePath: t = "", parentData: r, parentDataProperty: i, roo
|
|
|
24370
24370
|
if (e && typeof e == "object" && !Array.isArray(e)) {
|
|
24371
24371
|
const H = s;
|
|
24372
24372
|
for (const S in e)
|
|
24373
|
-
if (!
|
|
24373
|
+
if (!fc.call(H_.properties, S))
|
|
24374
24374
|
return me.errors = [
|
|
24375
24375
|
{
|
|
24376
24376
|
instancePath: t,
|
|
@@ -25385,15 +25385,15 @@ async function U_(e, t = {}) {
|
|
|
25385
25385
|
...t
|
|
25386
25386
|
};
|
|
25387
25387
|
let i;
|
|
25388
|
-
return
|
|
25388
|
+
return cc(e) ? (i = await M_(e), r.streamBundledFile = function(...a) {
|
|
25389
25389
|
return e.read(...a);
|
|
25390
25390
|
}) : i = e, q_(i, r);
|
|
25391
25391
|
}
|
|
25392
|
-
function
|
|
25392
|
+
function cc(e) {
|
|
25393
25393
|
return e && "read" in e && typeof e.read == "function";
|
|
25394
25394
|
}
|
|
25395
25395
|
async function M_(e) {
|
|
25396
|
-
if (!
|
|
25396
|
+
if (!cc(e))
|
|
25397
25397
|
return e;
|
|
25398
25398
|
const r = await (await e.read("blueprint.json")).text();
|
|
25399
25399
|
return JSON.parse(r);
|
|
@@ -25415,11 +25415,11 @@ function q_(e, {
|
|
|
25415
25415
|
steps: (e.steps || []).filter(G_).filter(Z_)
|
|
25416
25416
|
}, e.steps = [...e.steps || [], ...o || []];
|
|
25417
25417
|
for (const C of e.steps)
|
|
25418
|
-
!C || typeof C != "object" || (C.step === "importFile" ? (C.step = "importWxr",
|
|
25418
|
+
!C || typeof C != "object" || (C.step === "importFile" ? (C.step = "importWxr", Pe.warn(
|
|
25419
25419
|
'The "importFile" step is deprecated. Use "importWxr" instead.'
|
|
25420
|
-
)) : (C == null ? void 0 : C.step) === "installPlugin" && "pluginZipFile" in C ? (C.pluginData = C.pluginZipFile,
|
|
25420
|
+
)) : (C == null ? void 0 : C.step) === "installPlugin" && "pluginZipFile" in C ? (C.pluginData = C.pluginZipFile, Pe.warn(
|
|
25421
25421
|
'The "pluginZipFile" option of the "installPlugin" step is deprecated. Use "pluginData" instead.'
|
|
25422
|
-
)) : (C == null ? void 0 : C.step) === "installTheme" && "themeZipFile" in C && (C.themeData = C.themeZipFile,
|
|
25422
|
+
)) : (C == null ? void 0 : C.step) === "installTheme" && "themeZipFile" in C && (C.themeData = C.themeZipFile, Pe.warn(
|
|
25423
25423
|
'The "themeZipFile" option of the "installTheme" step is deprecated. Use "themeData" instead.'
|
|
25424
25424
|
)));
|
|
25425
25425
|
if (e.constants && e.steps.unshift({
|
|
@@ -25498,7 +25498,7 @@ function q_(e, {
|
|
|
25498
25498
|
php: z_(
|
|
25499
25499
|
(A = e.preferredVersions) == null ? void 0 : A.php,
|
|
25500
25500
|
ra,
|
|
25501
|
-
|
|
25501
|
+
Dc
|
|
25502
25502
|
),
|
|
25503
25503
|
wp: ((H = e.preferredVersions) == null ? void 0 : H.wp) || "latest"
|
|
25504
25504
|
},
|
|
@@ -25563,7 +25563,7 @@ function G_(e) {
|
|
|
25563
25563
|
return !!(typeof e == "object" && e);
|
|
25564
25564
|
}
|
|
25565
25565
|
function Z_(e) {
|
|
25566
|
-
return ["setPhpIniEntry", "request"].includes(e.step) ? (
|
|
25566
|
+
return ["setPhpIniEntry", "request"].includes(e.step) ? (Pe.warn(
|
|
25567
25567
|
`The "${e.step}" Blueprint is no longer supported and you can remove it from your Blueprint.`
|
|
25568
25568
|
), !1) : !0;
|
|
25569
25569
|
}
|
|
@@ -25660,7 +25660,7 @@ function Q_(e) {
|
|
|
25660
25660
|
};
|
|
25661
25661
|
}
|
|
25662
25662
|
}
|
|
25663
|
-
async function
|
|
25663
|
+
async function dg(e) {
|
|
25664
25664
|
var c, y;
|
|
25665
25665
|
const t = e.cliArgs || [];
|
|
25666
25666
|
for (const h of t)
|
|
@@ -25697,7 +25697,7 @@ async function ug(e) {
|
|
|
25697
25697
|
return;
|
|
25698
25698
|
await new Promise((L) => setTimeout(L, 0)), _.type.startsWith("blueprint.") && await a(_);
|
|
25699
25699
|
} catch (_) {
|
|
25700
|
-
|
|
25700
|
+
Pe.warn("Failed to parse message as JSON:", h, _);
|
|
25701
25701
|
}
|
|
25702
25702
|
});
|
|
25703
25703
|
await (i == null ? void 0 : i.writeFile(
|
|
@@ -25798,7 +25798,7 @@ require( "/tmp/blueprints.phar" );
|
|
|
25798
25798
|
]);
|
|
25799
25799
|
return p.finished.finally(f), p;
|
|
25800
25800
|
}
|
|
25801
|
-
async function
|
|
25801
|
+
async function hg(e) {
|
|
25802
25802
|
const t = await fetch(e, {
|
|
25803
25803
|
credentials: "omit"
|
|
25804
25804
|
});
|
|
@@ -25829,7 +25829,7 @@ async function eg(e) {
|
|
|
25829
25829
|
const t = new Uint8Array(e, 0, 4);
|
|
25830
25830
|
return t[0] === 80 && t[1] === 75 && t[2] === 3 && t[3] === 4;
|
|
25831
25831
|
}
|
|
25832
|
-
function
|
|
25832
|
+
function mg() {
|
|
25833
25833
|
}
|
|
25834
25834
|
const tg = [], rg = "127.0.0.1", sg = 4400;
|
|
25835
25835
|
class ng {
|
|
@@ -25852,7 +25852,7 @@ class ng {
|
|
|
25852
25852
|
onStepCompleted: a,
|
|
25853
25853
|
onBlueprintValidated: i,
|
|
25854
25854
|
corsProxy: n
|
|
25855
|
-
}), g =
|
|
25855
|
+
}), g = Ql(
|
|
25856
25856
|
t.contentWindow,
|
|
25857
25857
|
t.ownerDocument.defaultView
|
|
25858
25858
|
);
|
|
@@ -25867,31 +25867,59 @@ class ng {
|
|
|
25867
25867
|
withNetworking: m.features.networking,
|
|
25868
25868
|
corsProxyUrl: n,
|
|
25869
25869
|
sqliteDriverVersion: c
|
|
25870
|
-
}), await g.isReady(), _.finish(),
|
|
25870
|
+
}), await g.isReady(), _.finish(), Bl(Pe, g), y == null || y(g), await X_(m, g), m.features.networking && await g.prefetchUpdateChecks(), g;
|
|
25871
|
+
}
|
|
25872
|
+
}
|
|
25873
|
+
class ig {
|
|
25874
|
+
constructor(t) {
|
|
25875
|
+
this.options = t;
|
|
25876
|
+
}
|
|
25877
|
+
async bootPlayground(t, r) {
|
|
25878
|
+
const {
|
|
25879
|
+
blueprint: i,
|
|
25880
|
+
onClientConnected: a,
|
|
25881
|
+
corsProxy: n,
|
|
25882
|
+
mounts: s,
|
|
25883
|
+
sapiName: o,
|
|
25884
|
+
scope: f
|
|
25885
|
+
} = this.options, p = r.stage(), c = Ql(
|
|
25886
|
+
t.contentWindow,
|
|
25887
|
+
t.ownerDocument.defaultView
|
|
25888
|
+
);
|
|
25889
|
+
return await c.isConnected(), r.pipe(c), await c.onDownloadProgress(p.loadingListener), await c.boot({
|
|
25890
|
+
mounts: s,
|
|
25891
|
+
sapiName: o,
|
|
25892
|
+
scope: f ?? Math.random().toFixed(16),
|
|
25893
|
+
corsProxyUrl: n,
|
|
25894
|
+
experimentalBlueprintsV2Runner: !0,
|
|
25895
|
+
// Pass the declaration directly – the worker runs the V2 runner.
|
|
25896
|
+
blueprint: i
|
|
25897
|
+
}), await c.isReady(), p.finish(), Bl(Pe, c), a == null || a(c), c;
|
|
25871
25898
|
}
|
|
25872
25899
|
}
|
|
25873
|
-
async function
|
|
25900
|
+
async function yg(e) {
|
|
25874
25901
|
const {
|
|
25875
25902
|
iframe: t,
|
|
25876
25903
|
progressTracker: r = new Rn(),
|
|
25877
25904
|
disableProgressBar: i
|
|
25878
25905
|
} = e;
|
|
25879
25906
|
let { remoteUrl: a } = e;
|
|
25880
|
-
|
|
25881
|
-
progressbar: !i
|
|
25907
|
+
lg(a), ag(t), a = fg(a, {
|
|
25908
|
+
progressbar: !i,
|
|
25909
|
+
"blueprints-runner": e.experimentalBlueprintsV2Runner ? "v2" : "v1"
|
|
25882
25910
|
}), r.setCaption("Preparing WordPress"), await new Promise((o) => {
|
|
25883
25911
|
t.src = a, t.addEventListener("load", o, !1);
|
|
25884
25912
|
});
|
|
25885
|
-
const s = await new ng(e).bootPlayground(t, r);
|
|
25913
|
+
const s = await (e.experimentalBlueprintsV2Runner ? new ig(e) : new ng(e)).bootPlayground(t, r);
|
|
25886
25914
|
return r.finish(), s;
|
|
25887
25915
|
}
|
|
25888
|
-
function
|
|
25916
|
+
function ag(e) {
|
|
25889
25917
|
var t, r;
|
|
25890
25918
|
(t = e.sandbox) != null && t.length && !((r = e.sandbox) != null && r.contains("allow-storage-access-by-user-activation")) && e.sandbox.add("allow-storage-access-by-user-activation");
|
|
25891
25919
|
}
|
|
25892
|
-
const
|
|
25893
|
-
|
|
25894
|
-
|
|
25920
|
+
const uc = "https://playground.wordpress.net", og = `http://${rg}:${sg}`, Fl = [
|
|
25921
|
+
uc,
|
|
25922
|
+
og,
|
|
25895
25923
|
// An older origin that's still used by some plugins.
|
|
25896
25924
|
"https://wasm.wordpress.net",
|
|
25897
25925
|
// Allow hosting remote from same origin
|
|
@@ -25901,9 +25929,9 @@ const pc = "https://playground.wordpress.net", ag = `http://${rg}:${sg}`, Fl = [
|
|
|
25901
25929
|
"http://127.0.0.1",
|
|
25902
25930
|
"https://127.0.0.1",
|
|
25903
25931
|
...tg
|
|
25904
|
-
],
|
|
25905
|
-
function
|
|
25906
|
-
const t = new URL(e,
|
|
25932
|
+
], dc = uc;
|
|
25933
|
+
function lg(e) {
|
|
25934
|
+
const t = new URL(e, dc);
|
|
25907
25935
|
if (!(Fl.includes(t.origin) && t.pathname === "/remote.html"))
|
|
25908
25936
|
throw new Error(
|
|
25909
25937
|
`Invalid remote URL: ${t}. Expected remote URL to have a path of "/remote.html" based on one of the following origins:
|
|
@@ -25913,8 +25941,8 @@ function og(e) {
|
|
|
25913
25941
|
)}`
|
|
25914
25942
|
);
|
|
25915
25943
|
}
|
|
25916
|
-
function
|
|
25917
|
-
const r = new URL(e,
|
|
25944
|
+
function fg(e, t) {
|
|
25945
|
+
const r = new URL(e, dc), i = new URLSearchParams(r.search);
|
|
25918
25946
|
for (const [a, n] of Object.entries(t))
|
|
25919
25947
|
if (n != null && n !== !1)
|
|
25920
25948
|
if (Array.isArray(n))
|
|
@@ -25925,26 +25953,26 @@ function lg(e, t) {
|
|
|
25925
25953
|
return r.search = i.toString(), r.toString();
|
|
25926
25954
|
}
|
|
25927
25955
|
export {
|
|
25928
|
-
|
|
25956
|
+
Dc as LatestSupportedPHPVersion,
|
|
25929
25957
|
ra as SupportedPHPVersions,
|
|
25930
|
-
|
|
25931
|
-
|
|
25932
|
-
|
|
25958
|
+
cg as SupportedPHPVersionsList,
|
|
25959
|
+
Xp as activatePlugin,
|
|
25960
|
+
Jp as activateTheme,
|
|
25933
25961
|
U_ as compileBlueprint,
|
|
25934
25962
|
U_ as compileBlueprintV1,
|
|
25935
25963
|
m_ as cp,
|
|
25936
|
-
|
|
25964
|
+
ic as defineSiteUrl,
|
|
25937
25965
|
ka as defineWpConfigConsts,
|
|
25938
25966
|
h_ as enableMultisite,
|
|
25939
25967
|
k_ as exportWXR,
|
|
25940
25968
|
M_ as getBlueprintDeclaration,
|
|
25941
25969
|
J_ as getV2Runner,
|
|
25942
|
-
|
|
25970
|
+
ac as importThemeStarterContent,
|
|
25943
25971
|
x_ as importWordPressFiles,
|
|
25944
25972
|
b_ as importWxr,
|
|
25945
25973
|
S_ as installPlugin,
|
|
25946
25974
|
E_ as installTheme,
|
|
25947
|
-
|
|
25975
|
+
cc as isBlueprintBundle,
|
|
25948
25976
|
P_ as login,
|
|
25949
25977
|
__ as mkdir,
|
|
25950
25978
|
y_ as mv,
|
|
@@ -25952,25 +25980,25 @@ export {
|
|
|
25952
25980
|
Dn as phpVars,
|
|
25953
25981
|
o_ as request,
|
|
25954
25982
|
A_ as resetData,
|
|
25955
|
-
|
|
25956
|
-
|
|
25983
|
+
hg as resolveRemoteBlueprint,
|
|
25984
|
+
Qp as rm,
|
|
25957
25985
|
g_ as rmdir,
|
|
25958
25986
|
X_ as runBlueprintSteps,
|
|
25959
25987
|
X_ as runBlueprintV1Steps,
|
|
25960
|
-
|
|
25988
|
+
dg as runBlueprintV2,
|
|
25961
25989
|
n_ as runPHP,
|
|
25962
25990
|
i_ as runPHPWithOptions,
|
|
25963
25991
|
a_ as runSql,
|
|
25964
25992
|
T_ as runWpInstallationWizard,
|
|
25965
|
-
|
|
25966
|
-
|
|
25993
|
+
pg as setPhpIniEntries,
|
|
25994
|
+
mg as setPluginProxyURL,
|
|
25967
25995
|
I_ as setSiteLanguage,
|
|
25968
|
-
|
|
25969
|
-
|
|
25996
|
+
rc as setSiteOptions,
|
|
25997
|
+
yg as startPlaygroundWeb,
|
|
25970
25998
|
Pa as unzip,
|
|
25971
25999
|
c_ as updateUserMeta,
|
|
25972
|
-
|
|
25973
|
-
|
|
26000
|
+
nc as wpCLI,
|
|
26001
|
+
oc as wpContentFilesExcludedFromExport,
|
|
25974
26002
|
Ea as writeFile,
|
|
25975
26003
|
w_ as writeFiles,
|
|
25976
26004
|
C_ as zipWpContent
|