minerender 2.1.0-alpha.41 → 2.1.0-alpha.43
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/browser/index.d.mts +83 -27
- package/dist/browser/index.d.ts +83 -27
- package/dist/browser/index.js +560 -325
- package/dist/browser/index.js.map +1 -1
- package/dist/browser/index.mjs +474 -239
- package/dist/browser/index.mjs.map +1 -1
- package/dist/bundle.js +902 -661
- package/dist/bundle.js.map +1 -1
- package/dist/node/index.d.mts +83 -27
- package/dist/node/index.d.ts +83 -27
- package/dist/node/index.js +563 -325
- package/dist/node/index.js.map +1 -1
- package/dist/node/index.mjs +474 -239
- package/dist/node/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/bundle.js
CHANGED
|
@@ -3050,7 +3050,7 @@ var MineRender = (() => {
|
|
|
3050
3050
|
var bufferLength = serializedString.length * 0.75;
|
|
3051
3051
|
var len = serializedString.length;
|
|
3052
3052
|
var i4;
|
|
3053
|
-
var
|
|
3053
|
+
var p13 = 0;
|
|
3054
3054
|
var encoded1, encoded2, encoded3, encoded4;
|
|
3055
3055
|
if (serializedString[serializedString.length - 1] === "=") {
|
|
3056
3056
|
bufferLength--;
|
|
@@ -3065,9 +3065,9 @@ var MineRender = (() => {
|
|
|
3065
3065
|
encoded2 = BASE_CHARS.indexOf(serializedString[i4 + 1]);
|
|
3066
3066
|
encoded3 = BASE_CHARS.indexOf(serializedString[i4 + 2]);
|
|
3067
3067
|
encoded4 = BASE_CHARS.indexOf(serializedString[i4 + 3]);
|
|
3068
|
-
bytes[
|
|
3069
|
-
bytes[
|
|
3070
|
-
bytes[
|
|
3068
|
+
bytes[p13++] = encoded1 << 2 | encoded2 >> 4;
|
|
3069
|
+
bytes[p13++] = (encoded2 & 15) << 4 | encoded3 >> 2;
|
|
3070
|
+
bytes[p13++] = (encoded3 & 3) << 6 | encoded4 & 63;
|
|
3071
3071
|
}
|
|
3072
3072
|
return buffer2;
|
|
3073
3073
|
}
|
|
@@ -11092,9 +11092,9 @@ var MineRender = (() => {
|
|
|
11092
11092
|
return createIterResult(value, false);
|
|
11093
11093
|
}
|
|
11094
11094
|
if (error) {
|
|
11095
|
-
const
|
|
11095
|
+
const p13 = Promise.reject(error);
|
|
11096
11096
|
error = null;
|
|
11097
|
-
return
|
|
11097
|
+
return p13;
|
|
11098
11098
|
}
|
|
11099
11099
|
if (finished) {
|
|
11100
11100
|
return createIterResult(void 0, true);
|
|
@@ -11511,7 +11511,7 @@ var MineRender = (() => {
|
|
|
11511
11511
|
o4[k22] = m4[k4];
|
|
11512
11512
|
});
|
|
11513
11513
|
var __exportStar = exports13 && exports13.__exportStar || function(m4, exports14) {
|
|
11514
|
-
for (var
|
|
11514
|
+
for (var p13 in m4) if (p13 !== "default" && !Object.prototype.hasOwnProperty.call(exports14, p13)) __createBinding(exports14, m4, p13);
|
|
11515
11515
|
};
|
|
11516
11516
|
Object.defineProperty(exports13, "__esModule", { value: true });
|
|
11517
11517
|
__exportStar(require_Base(), exports13);
|
|
@@ -11531,8 +11531,8 @@ var MineRender = (() => {
|
|
|
11531
11531
|
__assign = Object.assign || function(t5) {
|
|
11532
11532
|
for (var s4, i4 = 1, n4 = arguments.length; i4 < n4; i4++) {
|
|
11533
11533
|
s4 = arguments[i4];
|
|
11534
|
-
for (var
|
|
11535
|
-
t5[
|
|
11534
|
+
for (var p13 in s4) if (Object.prototype.hasOwnProperty.call(s4, p13))
|
|
11535
|
+
t5[p13] = s4[p13];
|
|
11536
11536
|
}
|
|
11537
11537
|
return t5;
|
|
11538
11538
|
};
|
|
@@ -11811,9 +11811,9 @@ var MineRender = (() => {
|
|
|
11811
11811
|
return createIterResult(value, false);
|
|
11812
11812
|
}
|
|
11813
11813
|
if (error) {
|
|
11814
|
-
const
|
|
11814
|
+
const p13 = Promise.reject(error);
|
|
11815
11815
|
error = null;
|
|
11816
|
-
return
|
|
11816
|
+
return p13;
|
|
11817
11817
|
}
|
|
11818
11818
|
if (finished) {
|
|
11819
11819
|
return createIterResult(void 0, true);
|
|
@@ -12049,8 +12049,8 @@ var MineRender = (() => {
|
|
|
12049
12049
|
if (je(t5)) return e6.stylize(Date.prototype.toString.call(t5), "date");
|
|
12050
12050
|
if (Ae(t5)) return ce(t5);
|
|
12051
12051
|
}
|
|
12052
|
-
var a4, c4 = "", s4 = false,
|
|
12053
|
-
(pe(t5) && (s4 = true,
|
|
12052
|
+
var a4, c4 = "", s4 = false, p13 = ["{", "}"];
|
|
12053
|
+
(pe(t5) && (s4 = true, p13 = ["[", "]"]), we(t5)) && (c4 = " [Function" + (t5.name ? ": " + t5.name : "") + "]");
|
|
12054
12054
|
return me(t5) && (c4 = " " + RegExp.prototype.toString.call(t5)), je(t5) && (c4 = " " + Date.prototype.toUTCString.call(t5)), Ae(t5) && (c4 = " " + ce(t5)), 0 !== o4.length || s4 && 0 != t5.length ? r5 < 0 ? me(t5) ? e6.stylize(RegExp.prototype.toString.call(t5), "regexp") : e6.stylize("[Object]", "special") : (e6.seen.push(t5), a4 = s4 ? function(e7, t6, r6, n5, i5) {
|
|
12055
12055
|
for (var o5 = [], u5 = 0, f5 = t6.length; u5 < f5; ++u5) ke(t6, String(u5)) ? o5.push(se(e7, t6, r6, n5, String(u5), true)) : o5.push("");
|
|
12056
12056
|
return i5.forEach(function(i6) {
|
|
@@ -12064,7 +12064,7 @@ var MineRender = (() => {
|
|
|
12064
12064
|
return n5++, t7.indexOf("\n") >= 0 && n5++, e8 + t7.replace(/\u001b\[\d\d?m/g, "").length + 1;
|
|
12065
12065
|
}, 0) > 60) return r6[0] + ("" === t6 ? "" : t6 + "\n ") + " " + e7.join(",\n ") + " " + r6[1];
|
|
12066
12066
|
return r6[0] + t6 + " " + e7.join(", ") + " " + r6[1];
|
|
12067
|
-
}(a4, c4,
|
|
12067
|
+
}(a4, c4, p13)) : p13[0] + c4 + p13[1];
|
|
12068
12068
|
}
|
|
12069
12069
|
function ce(e6) {
|
|
12070
12070
|
return "[" + Error.prototype.toString.call(e6) + "]";
|
|
@@ -12811,11 +12811,11 @@ var MineRender = (() => {
|
|
|
12811
12811
|
if (-1 === a4 && (a4 = o4), o4 - a4 + 1 === s4) return a4 * f4;
|
|
12812
12812
|
} else -1 !== a4 && (o4 -= o4 - a4), a4 = -1;
|
|
12813
12813
|
} else for (e6 + s4 > u4 && (e6 = u4 - s4), o4 = e6; o4 >= 0; o4--) {
|
|
12814
|
-
for (var
|
|
12815
|
-
|
|
12814
|
+
for (var p13 = true, c4 = 0; c4 < s4; c4++) if (h5(t5, o4 + c4) !== h5(r5, c4)) {
|
|
12815
|
+
p13 = false;
|
|
12816
12816
|
break;
|
|
12817
12817
|
}
|
|
12818
|
-
if (
|
|
12818
|
+
if (p13) return o4;
|
|
12819
12819
|
}
|
|
12820
12820
|
return -1;
|
|
12821
12821
|
}
|
|
@@ -12859,8 +12859,8 @@ var MineRender = (() => {
|
|
|
12859
12859
|
function I2(t5, r5, e6) {
|
|
12860
12860
|
e6 = Math.min(t5.length, e6);
|
|
12861
12861
|
for (var n4 = [], i4 = r5; i4 < e6; ) {
|
|
12862
|
-
var o4, f4, u4, s4, h5 = t5[i4], a4 = null,
|
|
12863
|
-
if (i4 +
|
|
12862
|
+
var o4, f4, u4, s4, h5 = t5[i4], a4 = null, p13 = h5 > 239 ? 4 : h5 > 223 ? 3 : h5 > 191 ? 2 : 1;
|
|
12863
|
+
if (i4 + p13 <= e6) switch (p13) {
|
|
12864
12864
|
case 1:
|
|
12865
12865
|
h5 < 128 && (a4 = h5);
|
|
12866
12866
|
break;
|
|
@@ -12873,7 +12873,7 @@ var MineRender = (() => {
|
|
|
12873
12873
|
case 4:
|
|
12874
12874
|
o4 = t5[i4 + 1], f4 = t5[i4 + 2], u4 = t5[i4 + 3], 128 == (192 & o4) && 128 == (192 & f4) && 128 == (192 & u4) && (s4 = (15 & h5) << 18 | (63 & o4) << 12 | (63 & f4) << 6 | 63 & u4) > 65535 && s4 < 1114112 && (a4 = s4);
|
|
12875
12875
|
}
|
|
12876
|
-
null === a4 ? (a4 = 65533,
|
|
12876
|
+
null === a4 ? (a4 = 65533, p13 = 1) : a4 > 65535 && (a4 -= 65536, n4.push(a4 >>> 10 & 1023 | 55296), a4 = 56320 | 1023 & a4), n4.push(a4), i4 += p13;
|
|
12877
12877
|
}
|
|
12878
12878
|
return function(t6) {
|
|
12879
12879
|
var r6 = t6.length;
|
|
@@ -14939,10 +14939,10 @@ var MineRender = (() => {
|
|
|
14939
14939
|
key: "join",
|
|
14940
14940
|
value: function join(s4) {
|
|
14941
14941
|
if (this.length === 0) return "";
|
|
14942
|
-
var
|
|
14943
|
-
var ret = "" +
|
|
14944
|
-
while (
|
|
14945
|
-
ret += s4 +
|
|
14942
|
+
var p13 = this.head;
|
|
14943
|
+
var ret = "" + p13.data;
|
|
14944
|
+
while (p13 = p13.next) {
|
|
14945
|
+
ret += s4 + p13.data;
|
|
14946
14946
|
}
|
|
14947
14947
|
return ret;
|
|
14948
14948
|
}
|
|
@@ -14951,12 +14951,12 @@ var MineRender = (() => {
|
|
|
14951
14951
|
value: function concat2(n4) {
|
|
14952
14952
|
if (this.length === 0) return Buffer2.alloc(0);
|
|
14953
14953
|
var ret = Buffer2.allocUnsafe(n4 >>> 0);
|
|
14954
|
-
var
|
|
14954
|
+
var p13 = this.head;
|
|
14955
14955
|
var i4 = 0;
|
|
14956
|
-
while (
|
|
14957
|
-
copyBuffer(
|
|
14958
|
-
i4 +=
|
|
14959
|
-
|
|
14956
|
+
while (p13) {
|
|
14957
|
+
copyBuffer(p13.data, ret, i4);
|
|
14958
|
+
i4 += p13.data.length;
|
|
14959
|
+
p13 = p13.next;
|
|
14960
14960
|
}
|
|
14961
14961
|
return ret;
|
|
14962
14962
|
}
|
|
@@ -14984,12 +14984,12 @@ var MineRender = (() => {
|
|
|
14984
14984
|
}, {
|
|
14985
14985
|
key: "_getString",
|
|
14986
14986
|
value: function _getString(n4) {
|
|
14987
|
-
var
|
|
14987
|
+
var p13 = this.head;
|
|
14988
14988
|
var c4 = 1;
|
|
14989
|
-
var ret =
|
|
14989
|
+
var ret = p13.data;
|
|
14990
14990
|
n4 -= ret.length;
|
|
14991
|
-
while (
|
|
14992
|
-
var str =
|
|
14991
|
+
while (p13 = p13.next) {
|
|
14992
|
+
var str = p13.data;
|
|
14993
14993
|
var nb = n4 > str.length ? str.length : n4;
|
|
14994
14994
|
if (nb === str.length) ret += str;
|
|
14995
14995
|
else ret += str.slice(0, n4);
|
|
@@ -14997,11 +14997,11 @@ var MineRender = (() => {
|
|
|
14997
14997
|
if (n4 === 0) {
|
|
14998
14998
|
if (nb === str.length) {
|
|
14999
14999
|
++c4;
|
|
15000
|
-
if (
|
|
15000
|
+
if (p13.next) this.head = p13.next;
|
|
15001
15001
|
else this.head = this.tail = null;
|
|
15002
15002
|
} else {
|
|
15003
|
-
this.head =
|
|
15004
|
-
|
|
15003
|
+
this.head = p13;
|
|
15004
|
+
p13.data = str.slice(nb);
|
|
15005
15005
|
}
|
|
15006
15006
|
break;
|
|
15007
15007
|
}
|
|
@@ -15015,23 +15015,23 @@ var MineRender = (() => {
|
|
|
15015
15015
|
key: "_getBuffer",
|
|
15016
15016
|
value: function _getBuffer(n4) {
|
|
15017
15017
|
var ret = Buffer2.allocUnsafe(n4);
|
|
15018
|
-
var
|
|
15018
|
+
var p13 = this.head;
|
|
15019
15019
|
var c4 = 1;
|
|
15020
|
-
|
|
15021
|
-
n4 -=
|
|
15022
|
-
while (
|
|
15023
|
-
var buf =
|
|
15020
|
+
p13.data.copy(ret);
|
|
15021
|
+
n4 -= p13.data.length;
|
|
15022
|
+
while (p13 = p13.next) {
|
|
15023
|
+
var buf = p13.data;
|
|
15024
15024
|
var nb = n4 > buf.length ? buf.length : n4;
|
|
15025
15025
|
buf.copy(ret, ret.length - n4, 0, nb);
|
|
15026
15026
|
n4 -= nb;
|
|
15027
15027
|
if (n4 === 0) {
|
|
15028
15028
|
if (nb === buf.length) {
|
|
15029
15029
|
++c4;
|
|
15030
|
-
if (
|
|
15030
|
+
if (p13.next) this.head = p13.next;
|
|
15031
15031
|
else this.head = this.tail = null;
|
|
15032
15032
|
} else {
|
|
15033
|
-
this.head =
|
|
15034
|
-
|
|
15033
|
+
this.head = p13;
|
|
15034
|
+
p13.data = buf.slice(nb);
|
|
15035
15035
|
}
|
|
15036
15036
|
break;
|
|
15037
15037
|
}
|
|
@@ -16321,11 +16321,11 @@ var MineRender = (() => {
|
|
|
16321
16321
|
var decoder = new StringDecoder(enc);
|
|
16322
16322
|
this._readableState.decoder = decoder;
|
|
16323
16323
|
this._readableState.encoding = this._readableState.decoder.encoding;
|
|
16324
|
-
var
|
|
16324
|
+
var p13 = this._readableState.buffer.head;
|
|
16325
16325
|
var content = "";
|
|
16326
|
-
while (
|
|
16327
|
-
content += decoder.write(
|
|
16328
|
-
|
|
16326
|
+
while (p13 !== null) {
|
|
16327
|
+
content += decoder.write(p13.data);
|
|
16328
|
+
p13 = p13.next;
|
|
16329
16329
|
}
|
|
16330
16330
|
this._readableState.buffer.clear();
|
|
16331
16331
|
if (content !== "") this._readableState.buffer.push(content);
|
|
@@ -17068,8 +17068,8 @@ var MineRender = (() => {
|
|
|
17068
17068
|
} }, t$13 = [], e$23 = [], n$23 = "undefined" != typeof Uint8Array ? Uint8Array : Array, o$23 = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/", a$13 = 0, h$13 = o$23.length; a$13 < h$13; ++a$13) t$13[a$13] = o$23[a$13], e$23[o$23.charCodeAt(a$13)] = a$13;
|
|
17069
17069
|
e$23["-".charCodeAt(0)] = 62, e$23["_".charCodeAt(0)] = 63;
|
|
17070
17070
|
a$1$1 = { read: function(a4, t5, o4, r5, h5) {
|
|
17071
|
-
var M4, f4,
|
|
17072
|
-
for (N4 += n4, M4 = u4 & (1 << -i4) - 1, u4 >>= -i4, i4 +=
|
|
17071
|
+
var M4, f4, p13 = 8 * h5 - r5 - 1, w4 = (1 << p13) - 1, e6 = w4 >> 1, i4 = -7, N4 = o4 ? h5 - 1 : 0, n4 = o4 ? -1 : 1, u4 = a4[t5 + N4];
|
|
17072
|
+
for (N4 += n4, M4 = u4 & (1 << -i4) - 1, u4 >>= -i4, i4 += p13; i4 > 0; M4 = 256 * M4 + a4[t5 + N4], N4 += n4, i4 -= 8) ;
|
|
17073
17073
|
for (f4 = M4 & (1 << -i4) - 1, M4 >>= -i4, i4 += r5; i4 > 0; f4 = 256 * f4 + a4[t5 + N4], N4 += n4, i4 -= 8) ;
|
|
17074
17074
|
if (0 === M4) M4 = 1 - e6;
|
|
17075
17075
|
else {
|
|
@@ -17078,9 +17078,9 @@ var MineRender = (() => {
|
|
|
17078
17078
|
}
|
|
17079
17079
|
return (u4 ? -1 : 1) * f4 * Math.pow(2, M4 - r5);
|
|
17080
17080
|
}, write: function(a4, t5, o4, r5, h5, M4) {
|
|
17081
|
-
var f4,
|
|
17082
|
-
for (t5 = Math.abs(t5), isNaN(t5) || t5 === 1 / 0 ? (
|
|
17083
|
-
for (f4 = f4 << h5 |
|
|
17081
|
+
var f4, p13, w4, e6 = 8 * M4 - h5 - 1, i4 = (1 << e6) - 1, N4 = i4 >> 1, n4 = 23 === h5 ? Math.pow(2, -24) - Math.pow(2, -77) : 0, u4 = r5 ? 0 : M4 - 1, l4 = r5 ? 1 : -1, s4 = t5 < 0 || 0 === t5 && 1 / t5 < 0 ? 1 : 0;
|
|
17082
|
+
for (t5 = Math.abs(t5), isNaN(t5) || t5 === 1 / 0 ? (p13 = isNaN(t5) ? 1 : 0, f4 = i4) : (f4 = Math.floor(Math.log(t5) / Math.LN2), t5 * (w4 = Math.pow(2, -f4)) < 1 && (f4--, w4 *= 2), (t5 += f4 + N4 >= 1 ? n4 / w4 : n4 * Math.pow(2, 1 - N4)) * w4 >= 2 && (f4++, w4 /= 2), f4 + N4 >= i4 ? (p13 = 0, f4 = i4) : f4 + N4 >= 1 ? (p13 = (t5 * w4 - 1) * Math.pow(2, h5), f4 += N4) : (p13 = t5 * Math.pow(2, N4 - 1) * Math.pow(2, h5), f4 = 0)); h5 >= 8; a4[o4 + u4] = 255 & p13, u4 += l4, p13 /= 256, h5 -= 8) ;
|
|
17083
|
+
for (f4 = f4 << h5 | p13, e6 += h5; e6 > 0; a4[o4 + u4] = 255 & f4, u4 += l4, f4 /= 256, e6 -= 8) ;
|
|
17084
17084
|
a4[o4 + u4 - l4] |= 128 * s4;
|
|
17085
17085
|
} };
|
|
17086
17086
|
e$1$1 = {};
|
|
@@ -17184,8 +17184,8 @@ var MineRender = (() => {
|
|
|
17184
17184
|
if (n4 >= i4) return -1;
|
|
17185
17185
|
if (r5 >= e6) return 1;
|
|
17186
17186
|
if (this === t5) return 0;
|
|
17187
|
-
for (var o4 = (i4 >>>= 0) - (n4 >>>= 0), f4 = (e6 >>>= 0) - (r5 >>>= 0), s4 = Math.min(o4, f4), h5 = this.slice(n4, i4), a4 = t5.slice(r5, e6),
|
|
17188
|
-
o4 = h5[
|
|
17187
|
+
for (var o4 = (i4 >>>= 0) - (n4 >>>= 0), f4 = (e6 >>>= 0) - (r5 >>>= 0), s4 = Math.min(o4, f4), h5 = this.slice(n4, i4), a4 = t5.slice(r5, e6), p13 = 0; p13 < s4; ++p13) if (h5[p13] !== a4[p13]) {
|
|
17188
|
+
o4 = h5[p13], f4 = a4[p13];
|
|
17189
17189
|
break;
|
|
17190
17190
|
}
|
|
17191
17191
|
return o4 < f4 ? -1 : f4 < o4 ? 1 : 0;
|
|
@@ -17785,7 +17785,7 @@ var MineRender = (() => {
|
|
|
17785
17785
|
e6.set(t6, r6);
|
|
17786
17786
|
}
|
|
17787
17787
|
function r6() {
|
|
17788
|
-
return
|
|
17788
|
+
return p13(t6, arguments, h5(this).constructor);
|
|
17789
17789
|
}
|
|
17790
17790
|
return r6.prototype = Object.create(t6.prototype, { constructor: { value: r6, enumerable: false, writable: true, configurable: true } }), g4(r6, t6);
|
|
17791
17791
|
})(t5);
|
|
@@ -17801,8 +17801,8 @@ var MineRender = (() => {
|
|
|
17801
17801
|
return false;
|
|
17802
17802
|
}
|
|
17803
17803
|
}
|
|
17804
|
-
function
|
|
17805
|
-
return (
|
|
17804
|
+
function p13(t5, e6, n5) {
|
|
17805
|
+
return (p13 = s4() ? Reflect.construct : function(t6, e7, n6) {
|
|
17806
17806
|
var r6 = [null];
|
|
17807
17807
|
r6.push.apply(r6, e7);
|
|
17808
17808
|
var o5 = new (Function.bind.apply(t6, r6))();
|
|
@@ -17841,41 +17841,41 @@ var MineRender = (() => {
|
|
|
17841
17841
|
return b4(t5, { compact: false, customInspect: false, depth: 1e3, maxArrayLength: 1 / 0, showHidden: false, breakLength: 1 / 0, showProxy: false, sorted: true, getters: true });
|
|
17842
17842
|
}
|
|
17843
17843
|
function q3(t5, e6, r6) {
|
|
17844
|
-
var o5 = "", c5 = "", a5 = 0, i4 = "", u4 = false, l4 = x4(t5), f5 = l4.split("\n"), s5 = x4(e6).split("\n"),
|
|
17844
|
+
var o5 = "", c5 = "", a5 = 0, i4 = "", u4 = false, l4 = x4(t5), f5 = l4.split("\n"), s5 = x4(e6).split("\n"), p14 = 0, g5 = "";
|
|
17845
17845
|
if ("strictEqual" === r6 && "object" === y5(t5) && "object" === y5(e6) && null !== t5 && null !== e6 && (r6 = "strictEqualObject"), 1 === f5.length && 1 === s5.length && f5[0] !== s5[0]) {
|
|
17846
17846
|
var h6 = f5[0].length + s5[0].length;
|
|
17847
17847
|
if (h6 <= 10) {
|
|
17848
17848
|
if (!("object" === y5(t5) && null !== t5 || "object" === y5(e6) && null !== e6 || 0 === t5 && 0 === e6)) return "".concat(j4[r6], "\n\n") + "".concat(f5[0], " !== ").concat(s5[0], "\n");
|
|
17849
17849
|
} else if ("strictEqualObject" !== r6) {
|
|
17850
17850
|
if (h6 < (n4.stderr && n4.stderr.isTTY ? n4.stderr.columns : 80)) {
|
|
17851
|
-
for (; f5[0][
|
|
17852
|
-
|
|
17851
|
+
for (; f5[0][p14] === s5[0][p14]; ) p14++;
|
|
17852
|
+
p14 > 2 && (g5 = "\n ".concat(function(t6, e7) {
|
|
17853
17853
|
if (e7 = Math.floor(e7), 0 == t6.length || 0 == e7) return "";
|
|
17854
17854
|
var n5 = t6.length * e7;
|
|
17855
17855
|
for (e7 = Math.floor(Math.log(e7) / Math.log(2)); e7; ) t6 += t6, e7--;
|
|
17856
17856
|
return t6 += t6.substring(0, n5 - t6.length);
|
|
17857
|
-
}(" ",
|
|
17857
|
+
}(" ", p14), "^"), p14 = 0);
|
|
17858
17858
|
}
|
|
17859
17859
|
}
|
|
17860
17860
|
}
|
|
17861
|
-
for (var b5 = f5[f5.length - 1], v6 = s5[s5.length - 1]; b5 === v6 && (
|
|
17861
|
+
for (var b5 = f5[f5.length - 1], v6 = s5[s5.length - 1]; b5 === v6 && (p14++ < 2 ? i4 = "\n ".concat(b5).concat(i4) : o5 = b5, f5.pop(), s5.pop(), 0 !== f5.length && 0 !== s5.length); ) b5 = f5[f5.length - 1], v6 = s5[s5.length - 1];
|
|
17862
17862
|
var O5 = Math.max(f5.length, s5.length);
|
|
17863
17863
|
if (0 === O5) {
|
|
17864
17864
|
var q4 = l4.split("\n");
|
|
17865
17865
|
if (q4.length > 30) for (q4[26] = "".concat(m4, "...").concat(S4); q4.length > 27; ) q4.pop();
|
|
17866
17866
|
return "".concat(j4.notIdentical, "\n\n").concat(q4.join("\n"), "\n");
|
|
17867
17867
|
}
|
|
17868
|
-
|
|
17868
|
+
p14 > 3 && (i4 = "\n".concat(m4, "...").concat(S4).concat(i4), u4 = true), "" !== o5 && (i4 = "\n ".concat(o5).concat(i4), o5 = "");
|
|
17869
17869
|
var R5 = 0, A4 = j4[r6] + "\n".concat(E4, "+ actual").concat(S4, " ").concat(w4, "- expected").concat(S4), k4 = " ".concat(m4, "...").concat(S4, " Lines skipped");
|
|
17870
|
-
for (
|
|
17871
|
-
var _4 =
|
|
17872
|
-
if (f5.length <
|
|
17873
|
-
else if (s5.length <
|
|
17870
|
+
for (p14 = 0; p14 < O5; p14++) {
|
|
17871
|
+
var _4 = p14 - a5;
|
|
17872
|
+
if (f5.length < p14 + 1) _4 > 1 && p14 > 2 && (_4 > 4 ? (c5 += "\n".concat(m4, "...").concat(S4), u4 = true) : _4 > 3 && (c5 += "\n ".concat(s5[p14 - 2]), R5++), c5 += "\n ".concat(s5[p14 - 1]), R5++), a5 = p14, o5 += "\n".concat(w4, "-").concat(S4, " ").concat(s5[p14]), R5++;
|
|
17873
|
+
else if (s5.length < p14 + 1) _4 > 1 && p14 > 2 && (_4 > 4 ? (c5 += "\n".concat(m4, "...").concat(S4), u4 = true) : _4 > 3 && (c5 += "\n ".concat(f5[p14 - 2]), R5++), c5 += "\n ".concat(f5[p14 - 1]), R5++), a5 = p14, c5 += "\n".concat(E4, "+").concat(S4, " ").concat(f5[p14]), R5++;
|
|
17874
17874
|
else {
|
|
17875
|
-
var T5 = s5[
|
|
17876
|
-
I4 && d4(T5, ",") && T5.slice(0, -1) === P5 && (I4 = false, P5 += ","), I4 ? (_4 > 1 &&
|
|
17875
|
+
var T5 = s5[p14], P5 = f5[p14], I4 = P5 !== T5 && (!d4(P5, ",") || P5.slice(0, -1) !== T5);
|
|
17876
|
+
I4 && d4(T5, ",") && T5.slice(0, -1) === P5 && (I4 = false, P5 += ","), I4 ? (_4 > 1 && p14 > 2 && (_4 > 4 ? (c5 += "\n".concat(m4, "...").concat(S4), u4 = true) : _4 > 3 && (c5 += "\n ".concat(f5[p14 - 2]), R5++), c5 += "\n ".concat(f5[p14 - 1]), R5++), a5 = p14, c5 += "\n".concat(E4, "+").concat(S4, " ").concat(P5), o5 += "\n".concat(w4, "-").concat(S4, " ").concat(T5), R5 += 2) : (c5 += o5, o5 = "", 1 !== _4 && 0 !== p14 || (c5 += "\n ".concat(P5), R5++));
|
|
17877
17877
|
}
|
|
17878
|
-
if (R5 > 20 &&
|
|
17878
|
+
if (R5 > 20 && p14 < O5 - 2) return "".concat(A4).concat(k4, "\n").concat(c5, "\n").concat(m4, "...").concat(S4).concat(o5, "\n") + "".concat(m4, "...").concat(S4);
|
|
17879
17879
|
}
|
|
17880
17880
|
return "".concat(A4).concat(u4 ? k4 : "", "\n").concat(c5).concat(o5).concat(i4).concat(g5);
|
|
17881
17881
|
}
|
|
@@ -17889,9 +17889,9 @@ var MineRender = (() => {
|
|
|
17889
17889
|
if (Error.stackTraceLimit = 0, null != o5) r6 = c4(this, h5(e6).call(this, String(o5)));
|
|
17890
17890
|
else if (n4.stderr && n4.stderr.isTTY && (n4.stderr && n4.stderr.getColorDepth && 1 !== n4.stderr.getColorDepth() ? (m4 = "\x1B[34m", E4 = "\x1B[32m", S4 = "\x1B[39m", w4 = "\x1B[31m") : (m4 = "", E4 = "", S4 = "", w4 = "")), "object" === y5(l4) && null !== l4 && "object" === y5(f5) && null !== f5 && "stack" in l4 && l4 instanceof Error && "stack" in f5 && f5 instanceof Error && (l4 = O4(l4), f5 = O4(f5)), "deepStrictEqual" === i5 || "strictEqual" === i5) r6 = c4(this, h5(e6).call(this, q3(l4, f5, i5)));
|
|
17891
17891
|
else if ("notDeepStrictEqual" === i5 || "notStrictEqual" === i5) {
|
|
17892
|
-
var
|
|
17893
|
-
if ("notStrictEqual" === i5 && "object" === y5(l4) && null !== l4 && (
|
|
17894
|
-
r6 = 1 === g5.length ? c4(this, h5(e6).call(this, "".concat(
|
|
17892
|
+
var p14 = j4[i5], g5 = x4(l4).split("\n");
|
|
17893
|
+
if ("notStrictEqual" === i5 && "object" === y5(l4) && null !== l4 && (p14 = j4.notStrictEqualObject), g5.length > 30) for (g5[26] = "".concat(m4, "...").concat(S4); g5.length > 27; ) g5.pop();
|
|
17894
|
+
r6 = 1 === g5.length ? c4(this, h5(e6).call(this, "".concat(p14, " ").concat(g5[0]))) : c4(this, h5(e6).call(this, "".concat(p14, "\n\n").concat(g5.join("\n"), "\n")));
|
|
17895
17895
|
} else {
|
|
17896
17896
|
var b5 = x4(l4), d5 = "", R5 = j4[i5];
|
|
17897
17897
|
"notDeepEqual" === i5 || "notEqual" === i5 ? (b5 = "".concat(j4[i5], "\n\n").concat(b5)).length > 1024 && (b5 = "".concat(b5.slice(0, 1021), "...")) : (d5 = "".concat(x4(f5)), b5.length > 512 && (b5 = "".concat(b5.slice(0, 509), "...")), d5.length > 512 && (d5 = "".concat(d5.slice(0, 509), "...")), "deepEqual" === i5 || "equal" === i5 ? b5 = "".concat(R5, "\n\n").concat(b5, "\n\nshould equal\n\n") : d5 = " ".concat(i5, " ").concat(d5)), r6 = c4(this, h5(e6).call(this, "".concat(b5).concat(d5)));
|
|
@@ -18044,8 +18044,8 @@ var MineRender = (() => {
|
|
|
18044
18044
|
var s4 = v$1(e6);
|
|
18045
18045
|
if (u4.length !== s4.length && z3(e6, s4).length !== l4) return false;
|
|
18046
18046
|
} else {
|
|
18047
|
-
var
|
|
18048
|
-
if (0 !==
|
|
18047
|
+
var p13 = v$1(e6);
|
|
18048
|
+
if (0 !== p13.length && 0 !== z3(e6, p13).length) return false;
|
|
18049
18049
|
}
|
|
18050
18050
|
}
|
|
18051
18051
|
if (0 === c4.length && (0 === o4 || 1 === o4 && 0 === t5.length || 0 === t5.size)) return true;
|
|
@@ -18178,7 +18178,7 @@ var MineRender = (() => {
|
|
|
18178
18178
|
return t6 && "function" == typeof Symbol && t6.constructor === Symbol && t6 !== Symbol.prototype ? "symbol" : typeof t6;
|
|
18179
18179
|
})(t5);
|
|
18180
18180
|
}
|
|
18181
|
-
var a4, u4, l4 = i$5().codes, s4 = l4.ERR_AMBIGUOUS_ARGUMENT,
|
|
18181
|
+
var a4, u4, l4 = i$5().codes, s4 = l4.ERR_AMBIGUOUS_ARGUMENT, p13 = l4.ERR_INVALID_ARG_TYPE, g4 = l4.ERR_INVALID_ARG_VALUE, h5 = l4.ERR_INVALID_RETURN_VALUE, y5 = l4.ERR_MISSING_ARGS, b4 = f$6(), v5 = X.inspect, d4 = X.types, m$13 = d4.isPromise, E4 = d4.isRegExp, w4 = Object.assign ? Object.assign : r4.assign, S4 = Object.is ? Object.is : m3;
|
|
18182
18182
|
function j4() {
|
|
18183
18183
|
a4 = X2.isDeepEqual, u4 = X2.isDeepStrictEqual;
|
|
18184
18184
|
}
|
|
@@ -18263,7 +18263,7 @@ var MineRender = (() => {
|
|
|
18263
18263
|
function P5(t5, e6, n4, r5) {
|
|
18264
18264
|
if ("function" != typeof e6) {
|
|
18265
18265
|
if (E4(e6)) return e6.test(t5);
|
|
18266
|
-
if (2 === arguments.length) throw new
|
|
18266
|
+
if (2 === arguments.length) throw new p13("expected", ["Function", "RegExp"], e6);
|
|
18267
18267
|
if ("object" !== c4(t5) || null === t5) {
|
|
18268
18268
|
var o5 = new b4({ actual: t5, expected: e6, message: n4, operator: "deepStrictEqual", stackStartFn: r5 });
|
|
18269
18269
|
throw o5.operator = r5.name, o5;
|
|
@@ -18278,7 +18278,7 @@ var MineRender = (() => {
|
|
|
18278
18278
|
return void 0 !== e6.prototype && t5 instanceof e6 || !Error.isPrototypeOf(e6) && true === e6.call({}, t5);
|
|
18279
18279
|
}
|
|
18280
18280
|
function I4(t5) {
|
|
18281
|
-
if ("function" != typeof t5) throw new
|
|
18281
|
+
if ("function" != typeof t5) throw new p13("fn", "Function", t5);
|
|
18282
18282
|
try {
|
|
18283
18283
|
t5();
|
|
18284
18284
|
} catch (t6) {
|
|
@@ -18295,7 +18295,7 @@ var MineRender = (() => {
|
|
|
18295
18295
|
if ("function" == typeof t5) {
|
|
18296
18296
|
if (!D4(e6 = t5())) throw new h5("instance of Promise", "promiseFn", e6);
|
|
18297
18297
|
} else {
|
|
18298
|
-
if (!D4(t5)) throw new
|
|
18298
|
+
if (!D4(t5)) throw new p13("promiseFn", ["Function", "Promise"], t5);
|
|
18299
18299
|
e6 = t5;
|
|
18300
18300
|
}
|
|
18301
18301
|
return Promise.resolve().then(function() {
|
|
@@ -18309,12 +18309,12 @@ var MineRender = (() => {
|
|
|
18309
18309
|
}
|
|
18310
18310
|
function N4(t5, e6, n4, r5) {
|
|
18311
18311
|
if ("string" == typeof n4) {
|
|
18312
|
-
if (4 === arguments.length) throw new
|
|
18312
|
+
if (4 === arguments.length) throw new p13("error", ["Object", "Error", "Function", "RegExp"], n4);
|
|
18313
18313
|
if ("object" === c4(e6) && null !== e6) {
|
|
18314
18314
|
if (e6.message === n4) throw new s4("error/message", 'The error message "'.concat(e6.message, '" is identical to the message.'));
|
|
18315
18315
|
} else if (e6 === n4) throw new s4("error/message", 'The error "'.concat(e6, '" is identical to the message.'));
|
|
18316
18316
|
r5 = n4, n4 = void 0;
|
|
18317
|
-
} else if (null != n4 && "object" !== c4(n4) && "function" != typeof n4) throw new
|
|
18317
|
+
} else if (null != n4 && "object" !== c4(n4) && "function" != typeof n4) throw new p13("error", ["Object", "Error", "Function", "RegExp"], n4);
|
|
18318
18318
|
if (e6 === q3) {
|
|
18319
18319
|
var o5 = "";
|
|
18320
18320
|
n4 && n4.name && (o5 += " (".concat(n4.name, ")")), o5 += r5 ? ": ".concat(r5) : ".";
|
|
@@ -18373,7 +18373,7 @@ var MineRender = (() => {
|
|
|
18373
18373
|
}
|
|
18374
18374
|
}, x4.strict = w4(M4, x4, { equal: x4.strictEqual, deepEqual: x4.deepStrictEqual, notEqual: x4.notStrictEqual, notDeepEqual: x4.notDeepStrictEqual }), x4.strict.strict = x4.strict, Z2;
|
|
18375
18375
|
}
|
|
18376
|
-
var r4, t4, e$13, r$12, n4, o4, c4, l4, i4, a4, u4, f4,
|
|
18376
|
+
var r4, t4, e$13, r$12, n4, o4, c4, l4, i4, a4, u4, f4, p13, s4, y4, b3, g3, h4, $2, j3, w3, r$22, e$22, o$13, n$13, a$12, c$13, l$13, u$13, f$13, t$12, f$22, e$3, l$22, t$22, n$22, o$22, r$3, e$4, o$32, t$32, n$3, y$1, a$22, i$13, d3, f$3, u$23, A3, l$3, v4, P3, c$22, t$4, p$12, o$4, i$22, a$3, l$4, r$4, n$4, i$3, o$5, c$3, f$4, u$3, s$13, a$4, l$5, p$2, m3, N3, e$5, i$4, n$5, t$5, u$4, a$5, m$12, o$6, s$2, f$5, c$4, a$6, u$5, l$6, g$1, h$12, y$2, b$1, v$1, d$12, E3, w$1, S3, j$1, O3, x3, q2, R3, A$1, k3, _3, T3, P$1, I3, D3, F3, N$1, L3, M3, X2, Z2, $$1, et;
|
|
18377
18377
|
var init_chunk_CjPlbOtt = __esm({
|
|
18378
18378
|
"../../node_modules/@jspm/core/nodelibs/browser/chunk-CjPlbOtt.js"() {
|
|
18379
18379
|
init_dirname();
|
|
@@ -18393,10 +18393,10 @@ var MineRender = (() => {
|
|
|
18393
18393
|
}, "prototype"), u4 = ["toString", "toLocaleString", "valueOf", "hasOwnProperty", "isPrototypeOf", "propertyIsEnumerable", "constructor"], f4 = function(t5) {
|
|
18394
18394
|
var e6 = t5.constructor;
|
|
18395
18395
|
return e6 && e6.prototype === t5;
|
|
18396
|
-
},
|
|
18396
|
+
}, p13 = { $applicationCache: true, $console: true, $external: true, $frame: true, $frameElement: true, $frames: true, $innerHeight: true, $innerWidth: true, $onmozfullscreenchange: true, $onmozfullscreenerror: true, $outerHeight: true, $outerWidth: true, $pageXOffset: true, $pageYOffset: true, $parent: true, $scrollLeft: true, $scrollTop: true, $scrollX: true, $scrollY: true, $self: true, $webkitIndexedDB: true, $webkitStorageInfo: true, $window: true }, s4 = function() {
|
|
18397
18397
|
if ("undefined" == typeof window) return false;
|
|
18398
18398
|
for (var t5 in window) try {
|
|
18399
|
-
if (!
|
|
18399
|
+
if (!p13["$" + t5] && n4.call(window, t5) && null !== window[t5] && "object" == typeof window[t5]) try {
|
|
18400
18400
|
f4(window[t5]);
|
|
18401
18401
|
} catch (t6) {
|
|
18402
18402
|
return true;
|
|
@@ -18407,10 +18407,10 @@ var MineRender = (() => {
|
|
|
18407
18407
|
return false;
|
|
18408
18408
|
}();
|
|
18409
18409
|
t4 = function(t5) {
|
|
18410
|
-
var e6 = null !== t5 && "object" == typeof t5, r5 = "[object Function]" === o4.call(t5), l5 = c4(t5),
|
|
18410
|
+
var e6 = null !== t5 && "object" == typeof t5, r5 = "[object Function]" === o4.call(t5), l5 = c4(t5), p14 = e6 && "[object String]" === o4.call(t5), y5 = [];
|
|
18411
18411
|
if (!e6 && !r5 && !l5) throw new TypeError("Object.keys called on a non-object");
|
|
18412
18412
|
var b4 = a4 && r5;
|
|
18413
|
-
if (
|
|
18413
|
+
if (p14 && t5.length > 0 && !n4.call(t5, 0)) for (var g4 = 0; g4 < t5.length; ++g4) y5.push(String(g4));
|
|
18414
18414
|
if (l5 && t5.length > 0) for (var h5 = 0; h5 < t5.length; ++h5) y5.push(String(h5));
|
|
18415
18415
|
else for (var $3 in t5) b4 && "prototype" === $3 || !n4.call(t5, $3) || y5.push(String($3));
|
|
18416
18416
|
if (i4) for (var j4 = function(t6) {
|
|
@@ -18497,19 +18497,19 @@ var MineRender = (() => {
|
|
|
18497
18497
|
r$3 = function(r5) {
|
|
18498
18498
|
var e6 = this;
|
|
18499
18499
|
if ("function" != typeof e6 || "[object Function]" !== o$22.call(e6)) throw new TypeError(t$22 + e6);
|
|
18500
|
-
for (var
|
|
18501
|
-
if (this instanceof
|
|
18500
|
+
for (var p13, i4 = n$22.call(arguments, 1), c4 = function() {
|
|
18501
|
+
if (this instanceof p13) {
|
|
18502
18502
|
var t5 = e6.apply(this, i4.concat(n$22.call(arguments)));
|
|
18503
18503
|
return Object(t5) === t5 ? t5 : this;
|
|
18504
18504
|
}
|
|
18505
18505
|
return e6.apply(r5, i4.concat(n$22.call(arguments)));
|
|
18506
18506
|
}, a4 = Math.max(0, e6.length - i4.length), l4 = [], u4 = 0; u4 < a4; u4++) l4.push("$" + u4);
|
|
18507
|
-
if (
|
|
18507
|
+
if (p13 = Function("binder", "return function (" + l4.join(",") + "){ return binder.apply(this,arguments); }")(c4), e6.prototype) {
|
|
18508
18508
|
var y5 = function() {
|
|
18509
18509
|
};
|
|
18510
|
-
y5.prototype = e6.prototype,
|
|
18510
|
+
y5.prototype = e6.prototype, p13.prototype = new y5(), y5.prototype = null;
|
|
18511
18511
|
}
|
|
18512
|
-
return
|
|
18512
|
+
return p13;
|
|
18513
18513
|
};
|
|
18514
18514
|
e$4 = Function.prototype.bind || r$3;
|
|
18515
18515
|
o$32 = TypeError;
|
|
@@ -19118,9 +19118,9 @@ var MineRender = (() => {
|
|
|
19118
19118
|
if (typeof source !== "object") {
|
|
19119
19119
|
throw new TypeError(source + "must be non-object");
|
|
19120
19120
|
}
|
|
19121
|
-
for (var
|
|
19122
|
-
if (_has(source,
|
|
19123
|
-
obj[
|
|
19121
|
+
for (var p13 in source) {
|
|
19122
|
+
if (_has(source, p13)) {
|
|
19123
|
+
obj[p13] = source[p13];
|
|
19124
19124
|
}
|
|
19125
19125
|
}
|
|
19126
19126
|
}
|
|
@@ -20064,7 +20064,7 @@ var MineRender = (() => {
|
|
|
20064
20064
|
}
|
|
20065
20065
|
function fill_window(s4) {
|
|
20066
20066
|
var _w_size = s4.w_size;
|
|
20067
|
-
var
|
|
20067
|
+
var p13, n4, m4, more, str;
|
|
20068
20068
|
do {
|
|
20069
20069
|
more = s4.window_size - s4.lookahead - s4.strstart;
|
|
20070
20070
|
if (s4.strstart >= _w_size + (_w_size - MIN_LOOKAHEAD2)) {
|
|
@@ -20073,16 +20073,16 @@ var MineRender = (() => {
|
|
|
20073
20073
|
s4.strstart -= _w_size;
|
|
20074
20074
|
s4.block_start -= _w_size;
|
|
20075
20075
|
n4 = s4.hash_size;
|
|
20076
|
-
|
|
20076
|
+
p13 = n4;
|
|
20077
20077
|
do {
|
|
20078
|
-
m4 = s4.head[--
|
|
20079
|
-
s4.head[
|
|
20078
|
+
m4 = s4.head[--p13];
|
|
20079
|
+
s4.head[p13] = m4 >= _w_size ? m4 - _w_size : 0;
|
|
20080
20080
|
} while (--n4);
|
|
20081
20081
|
n4 = _w_size;
|
|
20082
|
-
|
|
20082
|
+
p13 = n4;
|
|
20083
20083
|
do {
|
|
20084
|
-
m4 = s4.prev[--
|
|
20085
|
-
s4.prev[
|
|
20084
|
+
m4 = s4.prev[--p13];
|
|
20085
|
+
s4.prev[p13] = m4 >= _w_size ? m4 - _w_size : 0;
|
|
20086
20086
|
} while (--n4);
|
|
20087
20087
|
more += _w_size;
|
|
20088
20088
|
}
|
|
@@ -26092,12 +26092,12 @@ var MineRender = (() => {
|
|
|
26092
26092
|
return v5;
|
|
26093
26093
|
}
|
|
26094
26094
|
function resolveSchema(root, ref) {
|
|
26095
|
-
var
|
|
26095
|
+
var p13 = URI.parse(ref), refPath = _getFullPath(p13), baseId = getFullPath(this._getId(root.schema));
|
|
26096
26096
|
if (Object.keys(root.schema).length === 0 || refPath !== baseId) {
|
|
26097
26097
|
var id = normalizeId(refPath);
|
|
26098
26098
|
var refVal = this._refs[id];
|
|
26099
26099
|
if (typeof refVal == "string") {
|
|
26100
|
-
return resolveRecursive.call(this, root, refVal,
|
|
26100
|
+
return resolveRecursive.call(this, root, refVal, p13);
|
|
26101
26101
|
} else if (refVal instanceof SchemaObject) {
|
|
26102
26102
|
if (!refVal.validate) this._compile(refVal);
|
|
26103
26103
|
root = refVal;
|
|
@@ -26115,7 +26115,7 @@ var MineRender = (() => {
|
|
|
26115
26115
|
if (!root.schema) return;
|
|
26116
26116
|
baseId = getFullPath(this._getId(root.schema));
|
|
26117
26117
|
}
|
|
26118
|
-
return getJsonPointer.call(this,
|
|
26118
|
+
return getJsonPointer.call(this, p13, baseId, root.schema, root);
|
|
26119
26119
|
}
|
|
26120
26120
|
function resolveRecursive(root, ref, parsedRef) {
|
|
26121
26121
|
var res = resolveSchema.call(this, root, ref);
|
|
@@ -26220,11 +26220,11 @@ var MineRender = (() => {
|
|
|
26220
26220
|
}
|
|
26221
26221
|
function getFullPath(id, normalize2) {
|
|
26222
26222
|
if (normalize2 !== false) id = normalizeId(id);
|
|
26223
|
-
var
|
|
26224
|
-
return _getFullPath(
|
|
26223
|
+
var p13 = URI.parse(id);
|
|
26224
|
+
return _getFullPath(p13);
|
|
26225
26225
|
}
|
|
26226
|
-
function _getFullPath(
|
|
26227
|
-
return URI.serialize(
|
|
26226
|
+
function _getFullPath(p13) {
|
|
26227
|
+
return URI.serialize(p13).split("#")[0] + "#";
|
|
26228
26228
|
}
|
|
26229
26229
|
var TRAILING_SLASH_HASH = /#\/?$/;
|
|
26230
26230
|
function normalizeId(id) {
|
|
@@ -29112,8 +29112,8 @@ var MineRender = (() => {
|
|
|
29112
29112
|
if ($required && !(it.opts.$data && $required.$data) && $required.length < it.opts.loopRequired) {
|
|
29113
29113
|
var $requiredHash = it.util.toHash($required);
|
|
29114
29114
|
}
|
|
29115
|
-
function notProto(
|
|
29116
|
-
return
|
|
29115
|
+
function notProto(p13) {
|
|
29116
|
+
return p13 !== "__proto__";
|
|
29117
29117
|
}
|
|
29118
29118
|
out += "var " + $errs + " = errors;var " + $nextValid + " = true;";
|
|
29119
29119
|
if ($ownProperties) {
|
|
@@ -30048,19 +30048,19 @@ var MineRender = (() => {
|
|
|
30048
30048
|
callback = meta;
|
|
30049
30049
|
meta = void 0;
|
|
30050
30050
|
}
|
|
30051
|
-
var
|
|
30051
|
+
var p13 = loadMetaSchemaOf(schema).then(function() {
|
|
30052
30052
|
var schemaObj = self2._addSchema(schema, void 0, meta);
|
|
30053
30053
|
return schemaObj.validate || _compileAsync(schemaObj);
|
|
30054
30054
|
});
|
|
30055
30055
|
if (callback) {
|
|
30056
|
-
|
|
30056
|
+
p13.then(
|
|
30057
30057
|
function(v5) {
|
|
30058
30058
|
callback(null, v5);
|
|
30059
30059
|
},
|
|
30060
30060
|
callback
|
|
30061
30061
|
);
|
|
30062
30062
|
}
|
|
30063
|
-
return
|
|
30063
|
+
return p13;
|
|
30064
30064
|
function loadMetaSchemaOf(sch) {
|
|
30065
30065
|
var $schema = sch.$schema;
|
|
30066
30066
|
return $schema && !self2.getSchema($schema) ? compileAsync.call(self2, { $ref: $schema }, true) : Promise.resolve();
|
|
@@ -30870,8 +30870,8 @@ var MineRender = (() => {
|
|
|
30870
30870
|
throw new Error("schema should be object or boolean");
|
|
30871
30871
|
var serialize = this._opts.serialize;
|
|
30872
30872
|
var cacheKey = serialize ? serialize(schema) : schema;
|
|
30873
|
-
var
|
|
30874
|
-
if (
|
|
30873
|
+
var cached2 = this._cache.get(cacheKey);
|
|
30874
|
+
if (cached2) return cached2;
|
|
30875
30875
|
shouldAddSchema = shouldAddSchema || this._opts.addUsedSchema !== false;
|
|
30876
30876
|
var id = resolve.normalizeId(this._getId(schema));
|
|
30877
30877
|
if (id && shouldAddSchema) checkUnique(this, id);
|
|
@@ -33128,12 +33128,12 @@ var MineRender = (() => {
|
|
|
33128
33128
|
});
|
|
33129
33129
|
if (superClass) _setPrototypeOf(subClass, superClass);
|
|
33130
33130
|
}
|
|
33131
|
-
function _setPrototypeOf(o4,
|
|
33132
|
-
_setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf2(o5,
|
|
33133
|
-
o5.__proto__ =
|
|
33131
|
+
function _setPrototypeOf(o4, p13) {
|
|
33132
|
+
_setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf2(o5, p14) {
|
|
33133
|
+
o5.__proto__ = p14;
|
|
33134
33134
|
return o5;
|
|
33135
33135
|
};
|
|
33136
|
-
return _setPrototypeOf(o4,
|
|
33136
|
+
return _setPrototypeOf(o4, p13);
|
|
33137
33137
|
}
|
|
33138
33138
|
function _createSuper(Derived) {
|
|
33139
33139
|
var hasNativeReflectConstruct = _isNativeReflectConstruct();
|
|
@@ -33484,12 +33484,12 @@ var MineRender = (() => {
|
|
|
33484
33484
|
function _isNativeFunction(fn) {
|
|
33485
33485
|
return Function.toString.call(fn).indexOf("[native code]") !== -1;
|
|
33486
33486
|
}
|
|
33487
|
-
function _setPrototypeOf(o4,
|
|
33488
|
-
_setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf2(o5,
|
|
33489
|
-
o5.__proto__ =
|
|
33487
|
+
function _setPrototypeOf(o4, p13) {
|
|
33488
|
+
_setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf2(o5, p14) {
|
|
33489
|
+
o5.__proto__ = p14;
|
|
33490
33490
|
return o5;
|
|
33491
33491
|
};
|
|
33492
|
-
return _setPrototypeOf(o4,
|
|
33492
|
+
return _setPrototypeOf(o4, p13);
|
|
33493
33493
|
}
|
|
33494
33494
|
function _getPrototypeOf(o4) {
|
|
33495
33495
|
_getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf2(o5) {
|
|
@@ -35978,20 +35978,20 @@ var MineRender = (() => {
|
|
|
35978
35978
|
validateProtocol(protocol) {
|
|
35979
35979
|
let valid = this.ajv.validate("protocol", protocol);
|
|
35980
35980
|
assert2.ok(valid, JSON.stringify(this.ajv.errors, null, 2));
|
|
35981
|
-
function validateTypes(
|
|
35981
|
+
function validateTypes(p13, originalValidator, path) {
|
|
35982
35982
|
const v5 = new _Validator(originalValidator.typesSchemas);
|
|
35983
|
-
Object.keys(
|
|
35983
|
+
Object.keys(p13).forEach((k4) => {
|
|
35984
35984
|
if (k4 == "types") {
|
|
35985
|
-
Object.keys(
|
|
35986
|
-
Object.keys(
|
|
35985
|
+
Object.keys(p13[k4]).forEach((typeName) => v5.addType(typeName));
|
|
35986
|
+
Object.keys(p13[k4]).forEach((typeName) => {
|
|
35987
35987
|
try {
|
|
35988
|
-
v5.validateType(
|
|
35988
|
+
v5.validateType(p13[k4][typeName], path + "." + k4 + "." + typeName);
|
|
35989
35989
|
} catch (e6) {
|
|
35990
35990
|
throw new Error("Error at " + path + "." + k4 + "." + typeName);
|
|
35991
35991
|
}
|
|
35992
35992
|
});
|
|
35993
35993
|
} else {
|
|
35994
|
-
validateTypes(
|
|
35994
|
+
validateTypes(p13[k4], v5, path + "." + k4);
|
|
35995
35995
|
}
|
|
35996
35996
|
});
|
|
35997
35997
|
}
|
|
@@ -39370,20 +39370,20 @@ var MineRender = (() => {
|
|
|
39370
39370
|
}
|
|
39371
39371
|
join(s4) {
|
|
39372
39372
|
if (this.length === 0) return "";
|
|
39373
|
-
let
|
|
39374
|
-
let ret = "" +
|
|
39375
|
-
while ((
|
|
39373
|
+
let p13 = this.head;
|
|
39374
|
+
let ret = "" + p13.data;
|
|
39375
|
+
while ((p13 = p13.next) !== null) ret += s4 + p13.data;
|
|
39376
39376
|
return ret;
|
|
39377
39377
|
}
|
|
39378
39378
|
concat(n4) {
|
|
39379
39379
|
if (this.length === 0) return Buffer2.alloc(0);
|
|
39380
39380
|
const ret = Buffer2.allocUnsafe(n4 >>> 0);
|
|
39381
|
-
let
|
|
39381
|
+
let p13 = this.head;
|
|
39382
39382
|
let i4 = 0;
|
|
39383
|
-
while (
|
|
39384
|
-
TypedArrayPrototypeSet(ret,
|
|
39385
|
-
i4 +=
|
|
39386
|
-
|
|
39383
|
+
while (p13) {
|
|
39384
|
+
TypedArrayPrototypeSet(ret, p13.data, i4);
|
|
39385
|
+
i4 += p13.data.length;
|
|
39386
|
+
p13 = p13.next;
|
|
39387
39387
|
}
|
|
39388
39388
|
return ret;
|
|
39389
39389
|
}
|
|
@@ -39404,17 +39404,17 @@ var MineRender = (() => {
|
|
|
39404
39404
|
return this.head.data;
|
|
39405
39405
|
}
|
|
39406
39406
|
*[SymbolIterator]() {
|
|
39407
|
-
for (let
|
|
39408
|
-
yield
|
|
39407
|
+
for (let p13 = this.head; p13; p13 = p13.next) {
|
|
39408
|
+
yield p13.data;
|
|
39409
39409
|
}
|
|
39410
39410
|
}
|
|
39411
39411
|
// Consumes a specified amount of characters from the buffered data.
|
|
39412
39412
|
_getString(n4) {
|
|
39413
39413
|
let ret = "";
|
|
39414
|
-
let
|
|
39414
|
+
let p13 = this.head;
|
|
39415
39415
|
let c4 = 0;
|
|
39416
39416
|
do {
|
|
39417
|
-
const str =
|
|
39417
|
+
const str = p13.data;
|
|
39418
39418
|
if (n4 > str.length) {
|
|
39419
39419
|
ret += str;
|
|
39420
39420
|
n4 -= str.length;
|
|
@@ -39422,17 +39422,17 @@ var MineRender = (() => {
|
|
|
39422
39422
|
if (n4 === str.length) {
|
|
39423
39423
|
ret += str;
|
|
39424
39424
|
++c4;
|
|
39425
|
-
if (
|
|
39425
|
+
if (p13.next) this.head = p13.next;
|
|
39426
39426
|
else this.head = this.tail = null;
|
|
39427
39427
|
} else {
|
|
39428
39428
|
ret += StringPrototypeSlice(str, 0, n4);
|
|
39429
|
-
this.head =
|
|
39430
|
-
|
|
39429
|
+
this.head = p13;
|
|
39430
|
+
p13.data = StringPrototypeSlice(str, n4);
|
|
39431
39431
|
}
|
|
39432
39432
|
break;
|
|
39433
39433
|
}
|
|
39434
39434
|
++c4;
|
|
39435
|
-
} while ((
|
|
39435
|
+
} while ((p13 = p13.next) !== null);
|
|
39436
39436
|
this.length -= c4;
|
|
39437
39437
|
return ret;
|
|
39438
39438
|
}
|
|
@@ -39440,10 +39440,10 @@ var MineRender = (() => {
|
|
|
39440
39440
|
_getBuffer(n4) {
|
|
39441
39441
|
const ret = Buffer2.allocUnsafe(n4);
|
|
39442
39442
|
const retLen = n4;
|
|
39443
|
-
let
|
|
39443
|
+
let p13 = this.head;
|
|
39444
39444
|
let c4 = 0;
|
|
39445
39445
|
do {
|
|
39446
|
-
const buf =
|
|
39446
|
+
const buf = p13.data;
|
|
39447
39447
|
if (n4 > buf.length) {
|
|
39448
39448
|
TypedArrayPrototypeSet(ret, buf, retLen - n4);
|
|
39449
39449
|
n4 -= buf.length;
|
|
@@ -39451,17 +39451,17 @@ var MineRender = (() => {
|
|
|
39451
39451
|
if (n4 === buf.length) {
|
|
39452
39452
|
TypedArrayPrototypeSet(ret, buf, retLen - n4);
|
|
39453
39453
|
++c4;
|
|
39454
|
-
if (
|
|
39454
|
+
if (p13.next) this.head = p13.next;
|
|
39455
39455
|
else this.head = this.tail = null;
|
|
39456
39456
|
} else {
|
|
39457
39457
|
TypedArrayPrototypeSet(ret, new Uint8Array2(buf.buffer, buf.byteOffset, n4), retLen - n4);
|
|
39458
|
-
this.head =
|
|
39459
|
-
|
|
39458
|
+
this.head = p13;
|
|
39459
|
+
p13.data = buf.slice(n4);
|
|
39460
39460
|
}
|
|
39461
39461
|
break;
|
|
39462
39462
|
}
|
|
39463
39463
|
++c4;
|
|
39464
|
-
} while ((
|
|
39464
|
+
} while ((p13 = p13.next) !== null);
|
|
39465
39465
|
this.length -= c4;
|
|
39466
39466
|
return ret;
|
|
39467
39467
|
}
|
|
@@ -39729,7 +39729,7 @@ var MineRender = (() => {
|
|
|
39729
39729
|
}
|
|
39730
39730
|
return 0;
|
|
39731
39731
|
}
|
|
39732
|
-
function utf8CheckExtraBytes(self2, buf,
|
|
39732
|
+
function utf8CheckExtraBytes(self2, buf, p13) {
|
|
39733
39733
|
if ((buf[0] & 192) !== 128) {
|
|
39734
39734
|
self2.lastNeed = 0;
|
|
39735
39735
|
return "\uFFFD";
|
|
@@ -39748,14 +39748,14 @@ var MineRender = (() => {
|
|
|
39748
39748
|
}
|
|
39749
39749
|
}
|
|
39750
39750
|
function utf8FillLast(buf) {
|
|
39751
|
-
var
|
|
39752
|
-
var r5 = utf8CheckExtraBytes(this, buf,
|
|
39751
|
+
var p13 = this.lastTotal - this.lastNeed;
|
|
39752
|
+
var r5 = utf8CheckExtraBytes(this, buf, p13);
|
|
39753
39753
|
if (r5 !== void 0) return r5;
|
|
39754
39754
|
if (this.lastNeed <= buf.length) {
|
|
39755
|
-
buf.copy(this.lastChar,
|
|
39755
|
+
buf.copy(this.lastChar, p13, 0, this.lastNeed);
|
|
39756
39756
|
return this.lastChar.toString(this.encoding, 0, this.lastTotal);
|
|
39757
39757
|
}
|
|
39758
|
-
buf.copy(this.lastChar,
|
|
39758
|
+
buf.copy(this.lastChar, p13, 0, buf.length);
|
|
39759
39759
|
this.lastNeed -= buf.length;
|
|
39760
39760
|
}
|
|
39761
39761
|
function utf8Text(buf, i4) {
|
|
@@ -45441,16 +45441,16 @@ return ${compiler2.callType("value", tagType)}
|
|
|
45441
45441
|
}
|
|
45442
45442
|
return m4;
|
|
45443
45443
|
};
|
|
45444
|
-
bits = function(d4,
|
|
45445
|
-
var o4 =
|
|
45446
|
-
return (d4[o4] | d4[o4 + 1] << 8) >> (
|
|
45444
|
+
bits = function(d4, p13, m4) {
|
|
45445
|
+
var o4 = p13 / 8 | 0;
|
|
45446
|
+
return (d4[o4] | d4[o4 + 1] << 8) >> (p13 & 7) & m4;
|
|
45447
45447
|
};
|
|
45448
|
-
bits16 = function(d4,
|
|
45449
|
-
var o4 =
|
|
45450
|
-
return (d4[o4] | d4[o4 + 1] << 8 | d4[o4 + 2] << 16) >> (
|
|
45448
|
+
bits16 = function(d4, p13) {
|
|
45449
|
+
var o4 = p13 / 8 | 0;
|
|
45450
|
+
return (d4[o4] | d4[o4 + 1] << 8 | d4[o4 + 2] << 16) >> (p13 & 7);
|
|
45451
45451
|
};
|
|
45452
|
-
shft = function(
|
|
45453
|
-
return (
|
|
45452
|
+
shft = function(p13) {
|
|
45453
|
+
return (p13 + 7) / 8 | 0;
|
|
45454
45454
|
};
|
|
45455
45455
|
slc = function(v5, s4, e6) {
|
|
45456
45456
|
if (s4 == null || s4 < 0)
|
|
@@ -45627,15 +45627,15 @@ return ${compiler2.callType("value", tagType)}
|
|
|
45627
45627
|
} while (!final);
|
|
45628
45628
|
return bt != buf.length && noBuf ? slc(buf, 0, bt) : buf.subarray(0, bt);
|
|
45629
45629
|
};
|
|
45630
|
-
wbits = function(d4,
|
|
45631
|
-
v5 <<=
|
|
45632
|
-
var o4 =
|
|
45630
|
+
wbits = function(d4, p13, v5) {
|
|
45631
|
+
v5 <<= p13 & 7;
|
|
45632
|
+
var o4 = p13 / 8 | 0;
|
|
45633
45633
|
d4[o4] |= v5;
|
|
45634
45634
|
d4[o4 + 1] |= v5 >> 8;
|
|
45635
45635
|
};
|
|
45636
|
-
wbits16 = function(d4,
|
|
45637
|
-
v5 <<=
|
|
45638
|
-
var o4 =
|
|
45636
|
+
wbits16 = function(d4, p13, v5) {
|
|
45637
|
+
v5 <<= p13 & 7;
|
|
45638
|
+
var o4 = p13 / 8 | 0;
|
|
45639
45639
|
d4[o4] |= v5;
|
|
45640
45640
|
d4[o4 + 1] |= v5 >> 8;
|
|
45641
45641
|
d4[o4 + 2] |= v5 >> 16;
|
|
@@ -45761,8 +45761,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
45761
45761
|
out[o4 + i4 + 4] = dat[i4];
|
|
45762
45762
|
return (o4 + 4 + s4) * 8;
|
|
45763
45763
|
};
|
|
45764
|
-
wblk = function(dat, out, final, syms, lf, df, eb, li, bs, bl,
|
|
45765
|
-
wbits(out,
|
|
45764
|
+
wblk = function(dat, out, final, syms, lf, df, eb, li, bs, bl, p13) {
|
|
45765
|
+
wbits(out, p13++, final);
|
|
45766
45766
|
++lf[256];
|
|
45767
45767
|
var _a2 = hTree(lf, 15), dlt = _a2.t, mlb = _a2.l;
|
|
45768
45768
|
var _b2 = hTree(df, 15), ddt = _b2.t, mdb = _b2.l;
|
|
@@ -45781,27 +45781,27 @@ return ${compiler2.callType("value", tagType)}
|
|
|
45781
45781
|
var ftlen = clen(lf, flt) + clen(df, fdt) + eb;
|
|
45782
45782
|
var dtlen = clen(lf, dlt) + clen(df, ddt) + eb + 14 + 3 * nlcc + clen(lcfreq, lct) + 2 * lcfreq[16] + 3 * lcfreq[17] + 7 * lcfreq[18];
|
|
45783
45783
|
if (bs >= 0 && flen <= ftlen && flen <= dtlen)
|
|
45784
|
-
return wfblk(out,
|
|
45784
|
+
return wfblk(out, p13, dat.subarray(bs, bs + bl));
|
|
45785
45785
|
var lm, ll, dm, dl;
|
|
45786
|
-
wbits(out,
|
|
45786
|
+
wbits(out, p13, 1 + (dtlen < ftlen)), p13 += 2;
|
|
45787
45787
|
if (dtlen < ftlen) {
|
|
45788
45788
|
lm = hMap(dlt, mlb, 0), ll = dlt, dm = hMap(ddt, mdb, 0), dl = ddt;
|
|
45789
45789
|
var llm = hMap(lct, mlcb, 0);
|
|
45790
|
-
wbits(out,
|
|
45791
|
-
wbits(out,
|
|
45792
|
-
wbits(out,
|
|
45793
|
-
|
|
45790
|
+
wbits(out, p13, nlc - 257);
|
|
45791
|
+
wbits(out, p13 + 5, ndc - 1);
|
|
45792
|
+
wbits(out, p13 + 10, nlcc - 4);
|
|
45793
|
+
p13 += 14;
|
|
45794
45794
|
for (var i4 = 0; i4 < nlcc; ++i4)
|
|
45795
|
-
wbits(out,
|
|
45796
|
-
|
|
45795
|
+
wbits(out, p13 + 3 * i4, lct[clim[i4]]);
|
|
45796
|
+
p13 += 3 * nlcc;
|
|
45797
45797
|
var lcts = [lclt, lcdt];
|
|
45798
45798
|
for (var it = 0; it < 2; ++it) {
|
|
45799
45799
|
var clct = lcts[it];
|
|
45800
45800
|
for (var i4 = 0; i4 < clct.length; ++i4) {
|
|
45801
45801
|
var len = clct[i4] & 31;
|
|
45802
|
-
wbits(out,
|
|
45802
|
+
wbits(out, p13, llm[len]), p13 += lct[len];
|
|
45803
45803
|
if (len > 15)
|
|
45804
|
-
wbits(out,
|
|
45804
|
+
wbits(out, p13, clct[i4] >> 5 & 127), p13 += clct[i4] >> 12;
|
|
45805
45805
|
}
|
|
45806
45806
|
}
|
|
45807
45807
|
} else {
|
|
@@ -45811,19 +45811,19 @@ return ${compiler2.callType("value", tagType)}
|
|
|
45811
45811
|
var sym = syms[i4];
|
|
45812
45812
|
if (sym > 255) {
|
|
45813
45813
|
var len = sym >> 18 & 31;
|
|
45814
|
-
wbits16(out,
|
|
45814
|
+
wbits16(out, p13, lm[len + 257]), p13 += ll[len + 257];
|
|
45815
45815
|
if (len > 7)
|
|
45816
|
-
wbits(out,
|
|
45816
|
+
wbits(out, p13, sym >> 23 & 31), p13 += fleb[len];
|
|
45817
45817
|
var dst = sym & 31;
|
|
45818
|
-
wbits16(out,
|
|
45818
|
+
wbits16(out, p13, dm[dst]), p13 += dl[dst];
|
|
45819
45819
|
if (dst > 3)
|
|
45820
|
-
wbits16(out,
|
|
45820
|
+
wbits16(out, p13, sym >> 5 & 8191), p13 += fdeb[dst];
|
|
45821
45821
|
} else {
|
|
45822
|
-
wbits16(out,
|
|
45822
|
+
wbits16(out, p13, lm[sym]), p13 += ll[sym];
|
|
45823
45823
|
}
|
|
45824
45824
|
}
|
|
45825
|
-
wbits16(out,
|
|
45826
|
-
return
|
|
45825
|
+
wbits16(out, p13, lm[256]);
|
|
45826
|
+
return p13 + ll[256];
|
|
45827
45827
|
};
|
|
45828
45828
|
deo = /* @__PURE__ */ new i32([65540, 131080, 131088, 131104, 262176, 1048704, 1048832, 2114560, 2117632]);
|
|
45829
45829
|
et2 = /* @__PURE__ */ new u8(0);
|
|
@@ -46796,10 +46796,10 @@ return ${compiler2.callType("value", tagType)}
|
|
|
46796
46796
|
}
|
|
46797
46797
|
}
|
|
46798
46798
|
function paethPredictor(a4, b4, c4) {
|
|
46799
|
-
const
|
|
46800
|
-
const pa = Math.abs(
|
|
46801
|
-
const pb = Math.abs(
|
|
46802
|
-
const pc = Math.abs(
|
|
46799
|
+
const p13 = a4 + b4 - c4;
|
|
46800
|
+
const pa = Math.abs(p13 - a4);
|
|
46801
|
+
const pb = Math.abs(p13 - b4);
|
|
46802
|
+
const pc = Math.abs(p13 - c4);
|
|
46803
46803
|
if (pa <= pb && pa <= pc)
|
|
46804
46804
|
return a4;
|
|
46805
46805
|
else if (pb <= pc)
|
|
@@ -48038,7 +48038,7 @@ return ${compiler2.callType("value", tagType)}
|
|
|
48038
48038
|
}, domElement: c4, setMode: u4 };
|
|
48039
48039
|
};
|
|
48040
48040
|
f4.Panel = function(e6, f5, l4) {
|
|
48041
|
-
var c4 = Infinity, k4 = 0, g4 = Math.round, a4 = g4(window.devicePixelRatio || 1), r5 = 80 * a4, h5 = 48 * a4, t5 = 3 * a4, v5 = 2 * a4, d4 = 3 * a4, m4 = 15 * a4, n4 = 74 * a4,
|
|
48041
|
+
var c4 = Infinity, k4 = 0, g4 = Math.round, a4 = g4(window.devicePixelRatio || 1), r5 = 80 * a4, h5 = 48 * a4, t5 = 3 * a4, v5 = 2 * a4, d4 = 3 * a4, m4 = 15 * a4, n4 = 74 * a4, p13 = 30 * a4, q3 = document.createElement("canvas");
|
|
48042
48042
|
q3.width = r5;
|
|
48043
48043
|
q3.height = h5;
|
|
48044
48044
|
q3.style.cssText = "width:80px;height:48px";
|
|
@@ -48049,10 +48049,10 @@ return ${compiler2.callType("value", tagType)}
|
|
|
48049
48049
|
b4.fillRect(0, 0, r5, h5);
|
|
48050
48050
|
b4.fillStyle = f5;
|
|
48051
48051
|
b4.fillText(e6, t5, v5);
|
|
48052
|
-
b4.fillRect(d4, m4, n4,
|
|
48052
|
+
b4.fillRect(d4, m4, n4, p13);
|
|
48053
48053
|
b4.fillStyle = l4;
|
|
48054
48054
|
b4.globalAlpha = 0.9;
|
|
48055
|
-
b4.fillRect(d4, m4, n4,
|
|
48055
|
+
b4.fillRect(d4, m4, n4, p13);
|
|
48056
48056
|
return { dom: q3, update: function(h6, w4) {
|
|
48057
48057
|
c4 = Math.min(c4, h6);
|
|
48058
48058
|
k4 = Math.max(k4, h6);
|
|
@@ -48061,11 +48061,11 @@ return ${compiler2.callType("value", tagType)}
|
|
|
48061
48061
|
b4.fillRect(0, 0, r5, m4);
|
|
48062
48062
|
b4.fillStyle = f5;
|
|
48063
48063
|
b4.fillText(g4(h6) + " " + e6 + " (" + g4(c4) + "-" + g4(k4) + ")", t5, v5);
|
|
48064
|
-
b4.drawImage(q3, d4 + a4, m4, n4 - a4,
|
|
48065
|
-
b4.fillRect(d4 + n4 - a4, m4, a4,
|
|
48064
|
+
b4.drawImage(q3, d4 + a4, m4, n4 - a4, p13, d4, m4, n4 - a4, p13);
|
|
48065
|
+
b4.fillRect(d4 + n4 - a4, m4, a4, p13);
|
|
48066
48066
|
b4.fillStyle = l4;
|
|
48067
48067
|
b4.globalAlpha = 0.9;
|
|
48068
|
-
b4.fillRect(d4 + n4 - a4, m4, a4, g4((1 - h6 / w4) *
|
|
48068
|
+
b4.fillRect(d4 + n4 - a4, m4, a4, g4((1 - h6 / w4) * p13));
|
|
48069
48069
|
} };
|
|
48070
48070
|
};
|
|
48071
48071
|
return f4;
|
|
@@ -48091,6 +48091,7 @@ return ${compiler2.callType("value", tagType)}
|
|
|
48091
48091
|
BasicAssetKey: () => BasicAssetKey,
|
|
48092
48092
|
BatchedExecutor: () => BatchedExecutor,
|
|
48093
48093
|
BlockObject: () => BlockObject,
|
|
48094
|
+
BlockStateResolver: () => BlockStateResolver,
|
|
48094
48095
|
BlockStates: () => BlockStates,
|
|
48095
48096
|
BlockTints: () => BlockTints,
|
|
48096
48097
|
BrowserArchiveProxy: () => BrowserArchiveProxy,
|
|
@@ -48149,6 +48150,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
48149
48150
|
SceneStats: () => SceneStats,
|
|
48150
48151
|
SceneStatsDisplay: () => SceneStatsDisplay,
|
|
48151
48152
|
SchematicParser: () => SchematicParser,
|
|
48153
|
+
SectionMesh: () => SectionMesh,
|
|
48154
|
+
SectionModels: () => SectionModels,
|
|
48152
48155
|
SkinImage: () => SkinImage,
|
|
48153
48156
|
SkinObject: () => SkinObject,
|
|
48154
48157
|
SkinPart: () => SkinPart,
|
|
@@ -52443,16 +52446,16 @@ return ${compiler2.callType("value", tagType)}
|
|
|
52443
52446
|
const te2 = this.elements;
|
|
52444
52447
|
const w4 = 1 / (right - left);
|
|
52445
52448
|
const h5 = 1 / (top - bottom);
|
|
52446
|
-
const
|
|
52449
|
+
const p13 = 1 / (far - near);
|
|
52447
52450
|
const x4 = (right + left) * w4;
|
|
52448
52451
|
const y5 = (top + bottom) * h5;
|
|
52449
52452
|
let z4, zInv;
|
|
52450
52453
|
if (coordinateSystem === WebGLCoordinateSystem) {
|
|
52451
|
-
z4 = (far + near) *
|
|
52452
|
-
zInv = -2 *
|
|
52454
|
+
z4 = (far + near) * p13;
|
|
52455
|
+
zInv = -2 * p13;
|
|
52453
52456
|
} else if (coordinateSystem === WebGPUCoordinateSystem) {
|
|
52454
|
-
z4 = near *
|
|
52455
|
-
zInv = -1 *
|
|
52457
|
+
z4 = near * p13;
|
|
52458
|
+
zInv = -1 * p13;
|
|
52456
52459
|
} else {
|
|
52457
52460
|
throw new Error("THREE.Matrix4.makeOrthographic(): Invalid coordinate system: " + coordinateSystem);
|
|
52458
52461
|
}
|
|
@@ -53361,18 +53364,18 @@ return ${compiler2.callType("value", tagType)}
|
|
|
53361
53364
|
intersectsBox(box) {
|
|
53362
53365
|
return box.intersectsTriangle(this);
|
|
53363
53366
|
}
|
|
53364
|
-
closestPointToPoint(
|
|
53367
|
+
closestPointToPoint(p13, target) {
|
|
53365
53368
|
const a4 = this.a, b4 = this.b, c4 = this.c;
|
|
53366
53369
|
let v5, w4;
|
|
53367
53370
|
_vab.subVectors(b4, a4);
|
|
53368
53371
|
_vac.subVectors(c4, a4);
|
|
53369
|
-
_vap.subVectors(
|
|
53372
|
+
_vap.subVectors(p13, a4);
|
|
53370
53373
|
const d1 = _vab.dot(_vap);
|
|
53371
53374
|
const d22 = _vac.dot(_vap);
|
|
53372
53375
|
if (d1 <= 0 && d22 <= 0) {
|
|
53373
53376
|
return target.copy(a4);
|
|
53374
53377
|
}
|
|
53375
|
-
_vbp.subVectors(
|
|
53378
|
+
_vbp.subVectors(p13, b4);
|
|
53376
53379
|
const d32 = _vab.dot(_vbp);
|
|
53377
53380
|
const d4 = _vac.dot(_vbp);
|
|
53378
53381
|
if (d32 >= 0 && d4 <= d32) {
|
|
@@ -53383,7 +53386,7 @@ return ${compiler2.callType("value", tagType)}
|
|
|
53383
53386
|
v5 = d1 / (d1 - d32);
|
|
53384
53387
|
return target.copy(a4).addScaledVector(_vab, v5);
|
|
53385
53388
|
}
|
|
53386
|
-
_vcp.subVectors(
|
|
53389
|
+
_vcp.subVectors(p13, c4);
|
|
53387
53390
|
const d5 = _vab.dot(_vcp);
|
|
53388
53391
|
const d6 = _vac.dot(_vcp);
|
|
53389
53392
|
if (d6 >= 0 && d5 <= d6) {
|
|
@@ -53561,13 +53564,13 @@ return ${compiler2.callType("value", tagType)}
|
|
|
53561
53564
|
};
|
|
53562
53565
|
var _hslA = { h: 0, s: 0, l: 0 };
|
|
53563
53566
|
var _hslB = { h: 0, s: 0, l: 0 };
|
|
53564
|
-
function hue2rgb(
|
|
53567
|
+
function hue2rgb(p13, q3, t5) {
|
|
53565
53568
|
if (t5 < 0) t5 += 1;
|
|
53566
53569
|
if (t5 > 1) t5 -= 1;
|
|
53567
|
-
if (t5 < 1 / 6) return
|
|
53570
|
+
if (t5 < 1 / 6) return p13 + (q3 - p13) * 6 * t5;
|
|
53568
53571
|
if (t5 < 1 / 2) return q3;
|
|
53569
|
-
if (t5 < 2 / 3) return
|
|
53570
|
-
return
|
|
53572
|
+
if (t5 < 2 / 3) return p13 + (q3 - p13) * 6 * (2 / 3 - t5);
|
|
53573
|
+
return p13;
|
|
53571
53574
|
}
|
|
53572
53575
|
var Color = class {
|
|
53573
53576
|
constructor(r5, g4, b4) {
|
|
@@ -53620,11 +53623,11 @@ return ${compiler2.callType("value", tagType)}
|
|
|
53620
53623
|
if (s4 === 0) {
|
|
53621
53624
|
this.r = this.g = this.b = l4;
|
|
53622
53625
|
} else {
|
|
53623
|
-
const
|
|
53624
|
-
const q3 = 2 * l4 -
|
|
53625
|
-
this.r = hue2rgb(q3,
|
|
53626
|
-
this.g = hue2rgb(q3,
|
|
53627
|
-
this.b = hue2rgb(q3,
|
|
53626
|
+
const p13 = l4 <= 0.5 ? l4 * (1 + s4) : l4 + s4 - l4 * s4;
|
|
53627
|
+
const q3 = 2 * l4 - p13;
|
|
53628
|
+
this.r = hue2rgb(q3, p13, h5 + 1 / 3);
|
|
53629
|
+
this.g = hue2rgb(q3, p13, h5);
|
|
53630
|
+
this.b = hue2rgb(q3, p13, h5 - 1 / 3);
|
|
53628
53631
|
}
|
|
53629
53632
|
ColorManagement.toWorkingColorSpace(this, colorSpace);
|
|
53630
53633
|
return this;
|
|
@@ -55362,19 +55365,19 @@ return ${compiler2.callType("value", tagType)}
|
|
|
55362
55365
|
const dst = {};
|
|
55363
55366
|
for (const u4 in src) {
|
|
55364
55367
|
dst[u4] = {};
|
|
55365
|
-
for (const
|
|
55366
|
-
const property = src[u4][
|
|
55368
|
+
for (const p13 in src[u4]) {
|
|
55369
|
+
const property = src[u4][p13];
|
|
55367
55370
|
if (property && (property.isColor || property.isMatrix3 || property.isMatrix4 || property.isVector2 || property.isVector3 || property.isVector4 || property.isTexture || property.isQuaternion)) {
|
|
55368
55371
|
if (property.isRenderTargetTexture) {
|
|
55369
55372
|
console.warn("UniformsUtils: Textures of render targets cannot be cloned via cloneUniforms() or mergeUniforms().");
|
|
55370
|
-
dst[u4][
|
|
55373
|
+
dst[u4][p13] = null;
|
|
55371
55374
|
} else {
|
|
55372
|
-
dst[u4][
|
|
55375
|
+
dst[u4][p13] = property.clone();
|
|
55373
55376
|
}
|
|
55374
55377
|
} else if (Array.isArray(property)) {
|
|
55375
|
-
dst[u4][
|
|
55378
|
+
dst[u4][p13] = property.slice();
|
|
55376
55379
|
} else {
|
|
55377
|
-
dst[u4][
|
|
55380
|
+
dst[u4][p13] = property;
|
|
55378
55381
|
}
|
|
55379
55382
|
}
|
|
55380
55383
|
}
|
|
@@ -55384,8 +55387,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
55384
55387
|
const merged = {};
|
|
55385
55388
|
for (let u4 = 0; u4 < uniforms.length; u4++) {
|
|
55386
55389
|
const tmp = cloneUniforms(uniforms[u4]);
|
|
55387
|
-
for (const
|
|
55388
|
-
merged[
|
|
55390
|
+
for (const p13 in tmp) {
|
|
55391
|
+
merged[p13] = tmp[p13];
|
|
55389
55392
|
}
|
|
55390
55393
|
}
|
|
55391
55394
|
return merged;
|
|
@@ -56237,8 +56240,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
56237
56240
|
}
|
|
56238
56241
|
function update(attribute, bufferType) {
|
|
56239
56242
|
if (attribute.isGLBufferAttribute) {
|
|
56240
|
-
const
|
|
56241
|
-
if (!
|
|
56243
|
+
const cached2 = buffers.get(attribute);
|
|
56244
|
+
if (!cached2 || cached2.version < attribute.version) {
|
|
56242
56245
|
buffers.set(attribute, {
|
|
56243
56246
|
buffer: attribute.buffer,
|
|
56244
56247
|
type: attribute.type,
|
|
@@ -60723,8 +60726,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
60723
60726
|
}
|
|
60724
60727
|
function acquireProgram(parameters, cacheKey) {
|
|
60725
60728
|
let program;
|
|
60726
|
-
for (let
|
|
60727
|
-
const preexistingProgram = programs[
|
|
60729
|
+
for (let p13 = 0, pl = programs.length; p13 < pl; p13++) {
|
|
60730
|
+
const preexistingProgram = programs[p13];
|
|
60728
60731
|
if (preexistingProgram.cacheKey === cacheKey) {
|
|
60729
60732
|
program = preexistingProgram;
|
|
60730
60733
|
++program.usedTimes;
|
|
@@ -63435,19 +63438,19 @@ return ${compiler2.callType("value", tagType)}
|
|
|
63435
63438
|
}
|
|
63436
63439
|
function WebGLUtils(gl, extensions, capabilities) {
|
|
63437
63440
|
const isWebGL2 = capabilities.isWebGL2;
|
|
63438
|
-
function convert(
|
|
63441
|
+
function convert(p13, colorSpace = NoColorSpace) {
|
|
63439
63442
|
let extension;
|
|
63440
63443
|
const transfer = ColorManagement.getTransfer(colorSpace);
|
|
63441
|
-
if (
|
|
63442
|
-
if (
|
|
63443
|
-
if (
|
|
63444
|
-
if (
|
|
63445
|
-
if (
|
|
63446
|
-
if (
|
|
63447
|
-
if (
|
|
63448
|
-
if (
|
|
63449
|
-
if (
|
|
63450
|
-
if (
|
|
63444
|
+
if (p13 === UnsignedByteType) return gl.UNSIGNED_BYTE;
|
|
63445
|
+
if (p13 === UnsignedShort4444Type) return gl.UNSIGNED_SHORT_4_4_4_4;
|
|
63446
|
+
if (p13 === UnsignedShort5551Type) return gl.UNSIGNED_SHORT_5_5_5_1;
|
|
63447
|
+
if (p13 === ByteType) return gl.BYTE;
|
|
63448
|
+
if (p13 === ShortType) return gl.SHORT;
|
|
63449
|
+
if (p13 === UnsignedShortType) return gl.UNSIGNED_SHORT;
|
|
63450
|
+
if (p13 === IntType) return gl.INT;
|
|
63451
|
+
if (p13 === UnsignedIntType) return gl.UNSIGNED_INT;
|
|
63452
|
+
if (p13 === FloatType) return gl.FLOAT;
|
|
63453
|
+
if (p13 === HalfFloatType) {
|
|
63451
63454
|
if (isWebGL2) return gl.HALF_FLOAT;
|
|
63452
63455
|
extension = extensions.get("OES_texture_half_float");
|
|
63453
63456
|
if (extension !== null) {
|
|
@@ -63456,13 +63459,13 @@ return ${compiler2.callType("value", tagType)}
|
|
|
63456
63459
|
return null;
|
|
63457
63460
|
}
|
|
63458
63461
|
}
|
|
63459
|
-
if (
|
|
63460
|
-
if (
|
|
63461
|
-
if (
|
|
63462
|
-
if (
|
|
63463
|
-
if (
|
|
63464
|
-
if (
|
|
63465
|
-
if (
|
|
63462
|
+
if (p13 === AlphaFormat) return gl.ALPHA;
|
|
63463
|
+
if (p13 === RGBAFormat) return gl.RGBA;
|
|
63464
|
+
if (p13 === LuminanceFormat) return gl.LUMINANCE;
|
|
63465
|
+
if (p13 === LuminanceAlphaFormat) return gl.LUMINANCE_ALPHA;
|
|
63466
|
+
if (p13 === DepthFormat) return gl.DEPTH_COMPONENT;
|
|
63467
|
+
if (p13 === DepthStencilFormat) return gl.DEPTH_STENCIL;
|
|
63468
|
+
if (p13 === _SRGBAFormat) {
|
|
63466
63469
|
extension = extensions.get("EXT_sRGB");
|
|
63467
63470
|
if (extension !== null) {
|
|
63468
63471
|
return extension.SRGB_ALPHA_EXT;
|
|
@@ -63470,46 +63473,46 @@ return ${compiler2.callType("value", tagType)}
|
|
|
63470
63473
|
return null;
|
|
63471
63474
|
}
|
|
63472
63475
|
}
|
|
63473
|
-
if (
|
|
63474
|
-
if (
|
|
63475
|
-
if (
|
|
63476
|
-
if (
|
|
63477
|
-
if (
|
|
63478
|
-
if (
|
|
63476
|
+
if (p13 === RedFormat) return gl.RED;
|
|
63477
|
+
if (p13 === RedIntegerFormat) return gl.RED_INTEGER;
|
|
63478
|
+
if (p13 === RGFormat) return gl.RG;
|
|
63479
|
+
if (p13 === RGIntegerFormat) return gl.RG_INTEGER;
|
|
63480
|
+
if (p13 === RGBAIntegerFormat) return gl.RGBA_INTEGER;
|
|
63481
|
+
if (p13 === RGB_S3TC_DXT1_Format || p13 === RGBA_S3TC_DXT1_Format || p13 === RGBA_S3TC_DXT3_Format || p13 === RGBA_S3TC_DXT5_Format) {
|
|
63479
63482
|
if (transfer === SRGBTransfer) {
|
|
63480
63483
|
extension = extensions.get("WEBGL_compressed_texture_s3tc_srgb");
|
|
63481
63484
|
if (extension !== null) {
|
|
63482
|
-
if (
|
|
63483
|
-
if (
|
|
63484
|
-
if (
|
|
63485
|
-
if (
|
|
63485
|
+
if (p13 === RGB_S3TC_DXT1_Format) return extension.COMPRESSED_SRGB_S3TC_DXT1_EXT;
|
|
63486
|
+
if (p13 === RGBA_S3TC_DXT1_Format) return extension.COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT;
|
|
63487
|
+
if (p13 === RGBA_S3TC_DXT3_Format) return extension.COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT;
|
|
63488
|
+
if (p13 === RGBA_S3TC_DXT5_Format) return extension.COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT;
|
|
63486
63489
|
} else {
|
|
63487
63490
|
return null;
|
|
63488
63491
|
}
|
|
63489
63492
|
} else {
|
|
63490
63493
|
extension = extensions.get("WEBGL_compressed_texture_s3tc");
|
|
63491
63494
|
if (extension !== null) {
|
|
63492
|
-
if (
|
|
63493
|
-
if (
|
|
63494
|
-
if (
|
|
63495
|
-
if (
|
|
63495
|
+
if (p13 === RGB_S3TC_DXT1_Format) return extension.COMPRESSED_RGB_S3TC_DXT1_EXT;
|
|
63496
|
+
if (p13 === RGBA_S3TC_DXT1_Format) return extension.COMPRESSED_RGBA_S3TC_DXT1_EXT;
|
|
63497
|
+
if (p13 === RGBA_S3TC_DXT3_Format) return extension.COMPRESSED_RGBA_S3TC_DXT3_EXT;
|
|
63498
|
+
if (p13 === RGBA_S3TC_DXT5_Format) return extension.COMPRESSED_RGBA_S3TC_DXT5_EXT;
|
|
63496
63499
|
} else {
|
|
63497
63500
|
return null;
|
|
63498
63501
|
}
|
|
63499
63502
|
}
|
|
63500
63503
|
}
|
|
63501
|
-
if (
|
|
63504
|
+
if (p13 === RGB_PVRTC_4BPPV1_Format || p13 === RGB_PVRTC_2BPPV1_Format || p13 === RGBA_PVRTC_4BPPV1_Format || p13 === RGBA_PVRTC_2BPPV1_Format) {
|
|
63502
63505
|
extension = extensions.get("WEBGL_compressed_texture_pvrtc");
|
|
63503
63506
|
if (extension !== null) {
|
|
63504
|
-
if (
|
|
63505
|
-
if (
|
|
63506
|
-
if (
|
|
63507
|
-
if (
|
|
63507
|
+
if (p13 === RGB_PVRTC_4BPPV1_Format) return extension.COMPRESSED_RGB_PVRTC_4BPPV1_IMG;
|
|
63508
|
+
if (p13 === RGB_PVRTC_2BPPV1_Format) return extension.COMPRESSED_RGB_PVRTC_2BPPV1_IMG;
|
|
63509
|
+
if (p13 === RGBA_PVRTC_4BPPV1_Format) return extension.COMPRESSED_RGBA_PVRTC_4BPPV1_IMG;
|
|
63510
|
+
if (p13 === RGBA_PVRTC_2BPPV1_Format) return extension.COMPRESSED_RGBA_PVRTC_2BPPV1_IMG;
|
|
63508
63511
|
} else {
|
|
63509
63512
|
return null;
|
|
63510
63513
|
}
|
|
63511
63514
|
}
|
|
63512
|
-
if (
|
|
63515
|
+
if (p13 === RGB_ETC1_Format) {
|
|
63513
63516
|
extension = extensions.get("WEBGL_compressed_texture_etc1");
|
|
63514
63517
|
if (extension !== null) {
|
|
63515
63518
|
return extension.COMPRESSED_RGB_ETC1_WEBGL;
|
|
@@ -63517,58 +63520,58 @@ return ${compiler2.callType("value", tagType)}
|
|
|
63517
63520
|
return null;
|
|
63518
63521
|
}
|
|
63519
63522
|
}
|
|
63520
|
-
if (
|
|
63523
|
+
if (p13 === RGB_ETC2_Format || p13 === RGBA_ETC2_EAC_Format) {
|
|
63521
63524
|
extension = extensions.get("WEBGL_compressed_texture_etc");
|
|
63522
63525
|
if (extension !== null) {
|
|
63523
|
-
if (
|
|
63524
|
-
if (
|
|
63526
|
+
if (p13 === RGB_ETC2_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ETC2 : extension.COMPRESSED_RGB8_ETC2;
|
|
63527
|
+
if (p13 === RGBA_ETC2_EAC_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ETC2_EAC : extension.COMPRESSED_RGBA8_ETC2_EAC;
|
|
63525
63528
|
} else {
|
|
63526
63529
|
return null;
|
|
63527
63530
|
}
|
|
63528
63531
|
}
|
|
63529
|
-
if (
|
|
63532
|
+
if (p13 === RGBA_ASTC_4x4_Format || p13 === RGBA_ASTC_5x4_Format || p13 === RGBA_ASTC_5x5_Format || p13 === RGBA_ASTC_6x5_Format || p13 === RGBA_ASTC_6x6_Format || p13 === RGBA_ASTC_8x5_Format || p13 === RGBA_ASTC_8x6_Format || p13 === RGBA_ASTC_8x8_Format || p13 === RGBA_ASTC_10x5_Format || p13 === RGBA_ASTC_10x6_Format || p13 === RGBA_ASTC_10x8_Format || p13 === RGBA_ASTC_10x10_Format || p13 === RGBA_ASTC_12x10_Format || p13 === RGBA_ASTC_12x12_Format) {
|
|
63530
63533
|
extension = extensions.get("WEBGL_compressed_texture_astc");
|
|
63531
63534
|
if (extension !== null) {
|
|
63532
|
-
if (
|
|
63533
|
-
if (
|
|
63534
|
-
if (
|
|
63535
|
-
if (
|
|
63536
|
-
if (
|
|
63537
|
-
if (
|
|
63538
|
-
if (
|
|
63539
|
-
if (
|
|
63540
|
-
if (
|
|
63541
|
-
if (
|
|
63542
|
-
if (
|
|
63543
|
-
if (
|
|
63544
|
-
if (
|
|
63545
|
-
if (
|
|
63535
|
+
if (p13 === RGBA_ASTC_4x4_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_4x4_KHR : extension.COMPRESSED_RGBA_ASTC_4x4_KHR;
|
|
63536
|
+
if (p13 === RGBA_ASTC_5x4_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_5x4_KHR : extension.COMPRESSED_RGBA_ASTC_5x4_KHR;
|
|
63537
|
+
if (p13 === RGBA_ASTC_5x5_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_5x5_KHR : extension.COMPRESSED_RGBA_ASTC_5x5_KHR;
|
|
63538
|
+
if (p13 === RGBA_ASTC_6x5_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_6x5_KHR : extension.COMPRESSED_RGBA_ASTC_6x5_KHR;
|
|
63539
|
+
if (p13 === RGBA_ASTC_6x6_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_6x6_KHR : extension.COMPRESSED_RGBA_ASTC_6x6_KHR;
|
|
63540
|
+
if (p13 === RGBA_ASTC_8x5_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_8x5_KHR : extension.COMPRESSED_RGBA_ASTC_8x5_KHR;
|
|
63541
|
+
if (p13 === RGBA_ASTC_8x6_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_8x6_KHR : extension.COMPRESSED_RGBA_ASTC_8x6_KHR;
|
|
63542
|
+
if (p13 === RGBA_ASTC_8x8_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_8x8_KHR : extension.COMPRESSED_RGBA_ASTC_8x8_KHR;
|
|
63543
|
+
if (p13 === RGBA_ASTC_10x5_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_10x5_KHR : extension.COMPRESSED_RGBA_ASTC_10x5_KHR;
|
|
63544
|
+
if (p13 === RGBA_ASTC_10x6_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_10x6_KHR : extension.COMPRESSED_RGBA_ASTC_10x6_KHR;
|
|
63545
|
+
if (p13 === RGBA_ASTC_10x8_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_10x8_KHR : extension.COMPRESSED_RGBA_ASTC_10x8_KHR;
|
|
63546
|
+
if (p13 === RGBA_ASTC_10x10_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_10x10_KHR : extension.COMPRESSED_RGBA_ASTC_10x10_KHR;
|
|
63547
|
+
if (p13 === RGBA_ASTC_12x10_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_12x10_KHR : extension.COMPRESSED_RGBA_ASTC_12x10_KHR;
|
|
63548
|
+
if (p13 === RGBA_ASTC_12x12_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_12x12_KHR : extension.COMPRESSED_RGBA_ASTC_12x12_KHR;
|
|
63546
63549
|
} else {
|
|
63547
63550
|
return null;
|
|
63548
63551
|
}
|
|
63549
63552
|
}
|
|
63550
|
-
if (
|
|
63553
|
+
if (p13 === RGBA_BPTC_Format || p13 === RGB_BPTC_SIGNED_Format || p13 === RGB_BPTC_UNSIGNED_Format) {
|
|
63551
63554
|
extension = extensions.get("EXT_texture_compression_bptc");
|
|
63552
63555
|
if (extension !== null) {
|
|
63553
|
-
if (
|
|
63554
|
-
if (
|
|
63555
|
-
if (
|
|
63556
|
+
if (p13 === RGBA_BPTC_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB_ALPHA_BPTC_UNORM_EXT : extension.COMPRESSED_RGBA_BPTC_UNORM_EXT;
|
|
63557
|
+
if (p13 === RGB_BPTC_SIGNED_Format) return extension.COMPRESSED_RGB_BPTC_SIGNED_FLOAT_EXT;
|
|
63558
|
+
if (p13 === RGB_BPTC_UNSIGNED_Format) return extension.COMPRESSED_RGB_BPTC_UNSIGNED_FLOAT_EXT;
|
|
63556
63559
|
} else {
|
|
63557
63560
|
return null;
|
|
63558
63561
|
}
|
|
63559
63562
|
}
|
|
63560
|
-
if (
|
|
63563
|
+
if (p13 === RED_RGTC1_Format || p13 === SIGNED_RED_RGTC1_Format || p13 === RED_GREEN_RGTC2_Format || p13 === SIGNED_RED_GREEN_RGTC2_Format) {
|
|
63561
63564
|
extension = extensions.get("EXT_texture_compression_rgtc");
|
|
63562
63565
|
if (extension !== null) {
|
|
63563
|
-
if (
|
|
63564
|
-
if (
|
|
63565
|
-
if (
|
|
63566
|
-
if (
|
|
63566
|
+
if (p13 === RGBA_BPTC_Format) return extension.COMPRESSED_RED_RGTC1_EXT;
|
|
63567
|
+
if (p13 === SIGNED_RED_RGTC1_Format) return extension.COMPRESSED_SIGNED_RED_RGTC1_EXT;
|
|
63568
|
+
if (p13 === RED_GREEN_RGTC2_Format) return extension.COMPRESSED_RED_GREEN_RGTC2_EXT;
|
|
63569
|
+
if (p13 === SIGNED_RED_GREEN_RGTC2_Format) return extension.COMPRESSED_SIGNED_RED_GREEN_RGTC2_EXT;
|
|
63567
63570
|
} else {
|
|
63568
63571
|
return null;
|
|
63569
63572
|
}
|
|
63570
63573
|
}
|
|
63571
|
-
if (
|
|
63574
|
+
if (p13 === UnsignedInt248Type) {
|
|
63572
63575
|
if (isWebGL2) return gl.UNSIGNED_INT_24_8;
|
|
63573
63576
|
extension = extensions.get("WEBGL_depth_texture");
|
|
63574
63577
|
if (extension !== null) {
|
|
@@ -63577,7 +63580,7 @@ return ${compiler2.callType("value", tagType)}
|
|
|
63577
63580
|
return null;
|
|
63578
63581
|
}
|
|
63579
63582
|
}
|
|
63580
|
-
return gl[
|
|
63583
|
+
return gl[p13] !== void 0 ? gl[p13] : null;
|
|
63581
63584
|
}
|
|
63582
63585
|
return { convert };
|
|
63583
63586
|
}
|
|
@@ -66995,10 +66998,10 @@ return ${compiler2.callType("value", tagType)}
|
|
|
66995
66998
|
this._offsetNext = iNext * stride;
|
|
66996
66999
|
}
|
|
66997
67000
|
interpolate_(i1, t0, t5, t1) {
|
|
66998
|
-
const result = this.resultBuffer, values = this.sampleValues, stride = this.valueSize, o1 = i1 * stride, o0 = o1 - stride, oP = this._offsetPrev, oN = this._offsetNext, wP = this._weightPrev, wN = this._weightNext,
|
|
66999
|
-
const sP = -wP * ppp + 2 * wP * pp - wP *
|
|
67000
|
-
const s0 = (1 + wP) * ppp + (-1.5 - 2 * wP) * pp + (-0.5 + wP) *
|
|
67001
|
-
const s1 = (-1 - wN) * ppp + (1.5 + wN) * pp + 0.5 *
|
|
67001
|
+
const result = this.resultBuffer, values = this.sampleValues, stride = this.valueSize, o1 = i1 * stride, o0 = o1 - stride, oP = this._offsetPrev, oN = this._offsetNext, wP = this._weightPrev, wN = this._weightNext, p13 = (t5 - t0) / (t1 - t0), pp = p13 * p13, ppp = pp * p13;
|
|
67002
|
+
const sP = -wP * ppp + 2 * wP * pp - wP * p13;
|
|
67003
|
+
const s0 = (1 + wP) * ppp + (-1.5 - 2 * wP) * pp + (-0.5 + wP) * p13 + 1;
|
|
67004
|
+
const s1 = (-1 - wN) * ppp + (1.5 + wN) * pp + 0.5 * p13;
|
|
67002
67005
|
const sN = wN * ppp - wN * pp;
|
|
67003
67006
|
for (let i4 = 0; i4 !== stride; ++i4) {
|
|
67004
67007
|
result[i4] = sP * values[oP + i4] + s0 * values[o0 + i4] + s1 * values[o1 + i4] + sN * values[oN + i4];
|
|
@@ -68253,7 +68256,7 @@ return ${compiler2.callType("value", tagType)}
|
|
|
68253
68256
|
function keyCompletablePromiseMapToPromiseContainingMap(keyToPromiseMap) {
|
|
68254
68257
|
const keys = asArray(keyToPromiseMap.keys());
|
|
68255
68258
|
const values = asArray(keyToPromiseMap.values());
|
|
68256
|
-
return Promise.all(values.map((
|
|
68259
|
+
return Promise.all(values.map((p13) => p13.promise)).then((resolvedValues) => {
|
|
68257
68260
|
const valueMap = /* @__PURE__ */ new Map();
|
|
68258
68261
|
keys.forEach((key, i4) => {
|
|
68259
68262
|
const value = resolvedValues[i4];
|
|
@@ -69513,11 +69516,11 @@ return ${compiler2.callType("value", tagType)}
|
|
|
69513
69516
|
static async loadCanvasData(src) {
|
|
69514
69517
|
const keyStr = serializeImageKey({ src });
|
|
69515
69518
|
const info = this.getInfo(src);
|
|
69516
|
-
const
|
|
69519
|
+
const cached2 = Caching.rawImageCache.getIfPresent(keyStr);
|
|
69517
69520
|
try {
|
|
69518
69521
|
return await this.infoToCanvasData(await info);
|
|
69519
69522
|
} catch (err2) {
|
|
69520
|
-
if (
|
|
69523
|
+
if (cached2 && Caching.rawImageCache.getIfPresent(keyStr) === cached2) {
|
|
69521
69524
|
Caching.rawImageCache.invalidate(keyStr);
|
|
69522
69525
|
}
|
|
69523
69526
|
throw err2;
|
|
@@ -69651,8 +69654,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
69651
69654
|
}
|
|
69652
69655
|
static getImage(key) {
|
|
69653
69656
|
const keyStr = serializeTextureKey(key);
|
|
69654
|
-
const
|
|
69655
|
-
if (
|
|
69657
|
+
const cached2 = Caching.textureCache.peek(keyStr);
|
|
69658
|
+
if (cached2 && TextureLoader.hasFailed(cached2)) {
|
|
69656
69659
|
Caching.textureCache.invalidate(keyStr);
|
|
69657
69660
|
}
|
|
69658
69661
|
return Caching.textureCache.get(keyStr, (k4) => {
|
|
@@ -69959,12 +69962,12 @@ return ${compiler2.callType("value", tagType)}
|
|
|
69959
69962
|
return a4.join("/");
|
|
69960
69963
|
}
|
|
69961
69964
|
getFullPath() {
|
|
69962
|
-
let
|
|
69965
|
+
let p13 = [];
|
|
69963
69966
|
if (this.type) {
|
|
69964
|
-
|
|
69967
|
+
p13.push(this.type);
|
|
69965
69968
|
}
|
|
69966
|
-
|
|
69967
|
-
return
|
|
69969
|
+
p13.push(this.path);
|
|
69970
|
+
return p13.join("/");
|
|
69968
69971
|
}
|
|
69969
69972
|
toNamespacedString() {
|
|
69970
69973
|
return this.namespace + ":" + this.getFullPath();
|
|
@@ -70056,7 +70059,7 @@ return ${compiler2.callType("value", tagType)}
|
|
|
70056
70059
|
merged.display = { ...inheritedDisplay, ...DisplayTransforms.withHandFallbacks(source.display) };
|
|
70057
70060
|
}
|
|
70058
70061
|
}
|
|
70059
|
-
merged.hierarchy = models.map((m4) => m4.parent).filter((
|
|
70062
|
+
merged.hierarchy = models.map((m4) => m4.parent).filter((p13) => `${p13}`);
|
|
70060
70063
|
merged.hierarchy.push(`${merged.parent}`);
|
|
70061
70064
|
return merged;
|
|
70062
70065
|
}
|
|
@@ -71452,8 +71455,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
71452
71455
|
that.opt_len += 3 * (max_blindex + 1) + 5 + 5 + 4;
|
|
71453
71456
|
return max_blindex;
|
|
71454
71457
|
}
|
|
71455
|
-
function put_byte(
|
|
71456
|
-
that.pending_buf[that.pending++] =
|
|
71458
|
+
function put_byte(p13) {
|
|
71459
|
+
that.pending_buf[that.pending++] = p13;
|
|
71457
71460
|
}
|
|
71458
71461
|
function put_short(w4) {
|
|
71459
71462
|
put_byte(w4 & 255);
|
|
@@ -71682,7 +71685,7 @@ return ${compiler2.callType("value", tagType)}
|
|
|
71682
71685
|
}
|
|
71683
71686
|
function fill_window() {
|
|
71684
71687
|
let n4, m4;
|
|
71685
|
-
let
|
|
71688
|
+
let p13;
|
|
71686
71689
|
let more;
|
|
71687
71690
|
do {
|
|
71688
71691
|
more = window_size - lookahead - strstart;
|
|
@@ -71696,16 +71699,16 @@ return ${compiler2.callType("value", tagType)}
|
|
|
71696
71699
|
strstart -= w_size;
|
|
71697
71700
|
block_start -= w_size;
|
|
71698
71701
|
n4 = hash_size;
|
|
71699
|
-
|
|
71702
|
+
p13 = n4;
|
|
71700
71703
|
do {
|
|
71701
|
-
m4 = head[--
|
|
71702
|
-
head[
|
|
71704
|
+
m4 = head[--p13] & 65535;
|
|
71705
|
+
head[p13] = m4 >= w_size ? m4 - w_size : 0;
|
|
71703
71706
|
} while (--n4 !== 0);
|
|
71704
71707
|
n4 = w_size;
|
|
71705
|
-
|
|
71708
|
+
p13 = n4;
|
|
71706
71709
|
do {
|
|
71707
|
-
m4 = prev[--
|
|
71708
|
-
prev[
|
|
71710
|
+
m4 = prev[--p13] & 65535;
|
|
71711
|
+
prev[p13] = m4 >= w_size ? m4 - w_size : 0;
|
|
71709
71712
|
} while (--n4 !== 0);
|
|
71710
71713
|
more += w_size;
|
|
71711
71714
|
}
|
|
@@ -74106,17 +74109,17 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74106
74109
|
let k4;
|
|
74107
74110
|
let l4;
|
|
74108
74111
|
let mask;
|
|
74109
|
-
let
|
|
74112
|
+
let p13;
|
|
74110
74113
|
let q3;
|
|
74111
74114
|
let w4;
|
|
74112
74115
|
let xp;
|
|
74113
74116
|
let y5;
|
|
74114
74117
|
let z4;
|
|
74115
|
-
|
|
74118
|
+
p13 = 0;
|
|
74116
74119
|
i4 = n4;
|
|
74117
74120
|
do {
|
|
74118
|
-
c4[b4[bindex +
|
|
74119
|
-
|
|
74121
|
+
c4[b4[bindex + p13]]++;
|
|
74122
|
+
p13++;
|
|
74120
74123
|
i4--;
|
|
74121
74124
|
} while (i4 !== 0);
|
|
74122
74125
|
if (c4[0] == n4) {
|
|
@@ -74151,24 +74154,24 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74151
74154
|
}
|
|
74152
74155
|
c4[i4] += y5;
|
|
74153
74156
|
x4[1] = j4 = 0;
|
|
74154
|
-
|
|
74157
|
+
p13 = 1;
|
|
74155
74158
|
xp = 2;
|
|
74156
74159
|
while (--i4 !== 0) {
|
|
74157
|
-
x4[xp] = j4 += c4[
|
|
74160
|
+
x4[xp] = j4 += c4[p13];
|
|
74158
74161
|
xp++;
|
|
74159
|
-
|
|
74162
|
+
p13++;
|
|
74160
74163
|
}
|
|
74161
74164
|
i4 = 0;
|
|
74162
|
-
|
|
74165
|
+
p13 = 0;
|
|
74163
74166
|
do {
|
|
74164
|
-
if ((j4 = b4[bindex +
|
|
74167
|
+
if ((j4 = b4[bindex + p13]) !== 0) {
|
|
74165
74168
|
v6[x4[j4]++] = i4;
|
|
74166
74169
|
}
|
|
74167
|
-
|
|
74170
|
+
p13++;
|
|
74168
74171
|
} while (++i4 < n4);
|
|
74169
74172
|
n4 = x4[g4];
|
|
74170
74173
|
x4[0] = i4 = 0;
|
|
74171
|
-
|
|
74174
|
+
p13 = 0;
|
|
74172
74175
|
h5 = -1;
|
|
74173
74176
|
w4 = -l4;
|
|
74174
74177
|
u4[0] = 0;
|
|
@@ -74216,16 +74219,16 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74216
74219
|
}
|
|
74217
74220
|
r5[1] = /* (byte) */
|
|
74218
74221
|
k4 - w4;
|
|
74219
|
-
if (
|
|
74222
|
+
if (p13 >= n4) {
|
|
74220
74223
|
r5[0] = 128 + 64;
|
|
74221
|
-
} else if (v6[
|
|
74224
|
+
} else if (v6[p13] < s4) {
|
|
74222
74225
|
r5[0] = /* (byte) */
|
|
74223
|
-
v6[
|
|
74224
|
-
r5[2] = v6[
|
|
74226
|
+
v6[p13] < 256 ? 0 : 32 + 64;
|
|
74227
|
+
r5[2] = v6[p13++];
|
|
74225
74228
|
} else {
|
|
74226
74229
|
r5[0] = /* (byte) */
|
|
74227
|
-
e6[v6[
|
|
74228
|
-
r5[2] = d4[v6[
|
|
74230
|
+
e6[v6[p13] - s4] + 16 + 64;
|
|
74231
|
+
r5[2] = d4[v6[p13++] - s4];
|
|
74229
74232
|
}
|
|
74230
74233
|
f4 = 1 << k4 - w4;
|
|
74231
74234
|
for (j4 = i4 >>> w4; j4 < z4; j4 += f4) {
|
|
@@ -74354,7 +74357,7 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74354
74357
|
let e6;
|
|
74355
74358
|
let b4;
|
|
74356
74359
|
let k4;
|
|
74357
|
-
let
|
|
74360
|
+
let p13;
|
|
74358
74361
|
let n4;
|
|
74359
74362
|
let q3;
|
|
74360
74363
|
let m4;
|
|
@@ -74364,7 +74367,7 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74364
74367
|
let d4;
|
|
74365
74368
|
let r5;
|
|
74366
74369
|
let tp_index_t_3;
|
|
74367
|
-
|
|
74370
|
+
p13 = z4.next_in_index;
|
|
74368
74371
|
n4 = z4.avail_in;
|
|
74369
74372
|
b4 = s4.bitb;
|
|
74370
74373
|
k4 = s4.bitk;
|
|
@@ -74375,7 +74378,7 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74375
74378
|
do {
|
|
74376
74379
|
while (k4 < 20) {
|
|
74377
74380
|
n4--;
|
|
74378
|
-
b4 |= (z4.read_byte(
|
|
74381
|
+
b4 |= (z4.read_byte(p13++) & 255) << k4;
|
|
74379
74382
|
k4 += 8;
|
|
74380
74383
|
}
|
|
74381
74384
|
t5 = b4 & ml;
|
|
@@ -74401,7 +74404,7 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74401
74404
|
k4 -= e6;
|
|
74402
74405
|
while (k4 < 15) {
|
|
74403
74406
|
n4--;
|
|
74404
|
-
b4 |= (z4.read_byte(
|
|
74407
|
+
b4 |= (z4.read_byte(p13++) & 255) << k4;
|
|
74405
74408
|
k4 += 8;
|
|
74406
74409
|
}
|
|
74407
74410
|
t5 = b4 & md;
|
|
@@ -74416,7 +74419,7 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74416
74419
|
e6 &= 15;
|
|
74417
74420
|
while (k4 < e6) {
|
|
74418
74421
|
n4--;
|
|
74419
|
-
b4 |= (z4.read_byte(
|
|
74422
|
+
b4 |= (z4.read_byte(p13++) & 255) << k4;
|
|
74420
74423
|
k4 += 8;
|
|
74421
74424
|
}
|
|
74422
74425
|
d4 = tp[tp_index_t_3 + 2] + (b4 & inflate_mask[e6]);
|
|
@@ -74477,13 +74480,13 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74477
74480
|
c4 = z4.avail_in - n4;
|
|
74478
74481
|
c4 = k4 >> 3 < c4 ? k4 >> 3 : c4;
|
|
74479
74482
|
n4 += c4;
|
|
74480
|
-
|
|
74483
|
+
p13 -= c4;
|
|
74481
74484
|
k4 -= c4 << 3;
|
|
74482
74485
|
s4.bitb = b4;
|
|
74483
74486
|
s4.bitk = k4;
|
|
74484
74487
|
z4.avail_in = n4;
|
|
74485
|
-
z4.total_in +=
|
|
74486
|
-
z4.next_in_index =
|
|
74488
|
+
z4.total_in += p13 - z4.next_in_index;
|
|
74489
|
+
z4.next_in_index = p13;
|
|
74487
74490
|
s4.write = q3;
|
|
74488
74491
|
return Z_DATA_ERROR3;
|
|
74489
74492
|
}
|
|
@@ -74506,13 +74509,13 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74506
74509
|
c4 = z4.avail_in - n4;
|
|
74507
74510
|
c4 = k4 >> 3 < c4 ? k4 >> 3 : c4;
|
|
74508
74511
|
n4 += c4;
|
|
74509
|
-
|
|
74512
|
+
p13 -= c4;
|
|
74510
74513
|
k4 -= c4 << 3;
|
|
74511
74514
|
s4.bitb = b4;
|
|
74512
74515
|
s4.bitk = k4;
|
|
74513
74516
|
z4.avail_in = n4;
|
|
74514
|
-
z4.total_in +=
|
|
74515
|
-
z4.next_in_index =
|
|
74517
|
+
z4.total_in += p13 - z4.next_in_index;
|
|
74518
|
+
z4.next_in_index = p13;
|
|
74516
74519
|
s4.write = q3;
|
|
74517
74520
|
return Z_STREAM_END3;
|
|
74518
74521
|
} else {
|
|
@@ -74520,13 +74523,13 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74520
74523
|
c4 = z4.avail_in - n4;
|
|
74521
74524
|
c4 = k4 >> 3 < c4 ? k4 >> 3 : c4;
|
|
74522
74525
|
n4 += c4;
|
|
74523
|
-
|
|
74526
|
+
p13 -= c4;
|
|
74524
74527
|
k4 -= c4 << 3;
|
|
74525
74528
|
s4.bitb = b4;
|
|
74526
74529
|
s4.bitk = k4;
|
|
74527
74530
|
z4.avail_in = n4;
|
|
74528
|
-
z4.total_in +=
|
|
74529
|
-
z4.next_in_index =
|
|
74531
|
+
z4.total_in += p13 - z4.next_in_index;
|
|
74532
|
+
z4.next_in_index = p13;
|
|
74530
74533
|
s4.write = q3;
|
|
74531
74534
|
return Z_DATA_ERROR3;
|
|
74532
74535
|
}
|
|
@@ -74535,13 +74538,13 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74535
74538
|
c4 = z4.avail_in - n4;
|
|
74536
74539
|
c4 = k4 >> 3 < c4 ? k4 >> 3 : c4;
|
|
74537
74540
|
n4 += c4;
|
|
74538
|
-
|
|
74541
|
+
p13 -= c4;
|
|
74539
74542
|
k4 -= c4 << 3;
|
|
74540
74543
|
s4.bitb = b4;
|
|
74541
74544
|
s4.bitk = k4;
|
|
74542
74545
|
z4.avail_in = n4;
|
|
74543
|
-
z4.total_in +=
|
|
74544
|
-
z4.next_in_index =
|
|
74546
|
+
z4.total_in += p13 - z4.next_in_index;
|
|
74547
|
+
z4.next_in_index = p13;
|
|
74545
74548
|
s4.write = q3;
|
|
74546
74549
|
return Z_OK3;
|
|
74547
74550
|
}
|
|
@@ -74563,12 +74566,12 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74563
74566
|
let e6;
|
|
74564
74567
|
let b4 = 0;
|
|
74565
74568
|
let k4 = 0;
|
|
74566
|
-
let
|
|
74569
|
+
let p13 = 0;
|
|
74567
74570
|
let n4;
|
|
74568
74571
|
let q3;
|
|
74569
74572
|
let m4;
|
|
74570
74573
|
let f4;
|
|
74571
|
-
|
|
74574
|
+
p13 = z4.next_in_index;
|
|
74572
74575
|
n4 = z4.avail_in;
|
|
74573
74576
|
b4 = s4.bitb;
|
|
74574
74577
|
k4 = s4.bitk;
|
|
@@ -74582,11 +74585,11 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74582
74585
|
s4.bitb = b4;
|
|
74583
74586
|
s4.bitk = k4;
|
|
74584
74587
|
z4.avail_in = n4;
|
|
74585
|
-
z4.total_in +=
|
|
74586
|
-
z4.next_in_index =
|
|
74588
|
+
z4.total_in += p13 - z4.next_in_index;
|
|
74589
|
+
z4.next_in_index = p13;
|
|
74587
74590
|
s4.write = q3;
|
|
74588
74591
|
r5 = inflate_fast(lbits, dbits, ltree, ltree_index, dtree, dtree_index, s4, z4);
|
|
74589
|
-
|
|
74592
|
+
p13 = z4.next_in_index;
|
|
74590
74593
|
n4 = z4.avail_in;
|
|
74591
74594
|
b4 = s4.bitb;
|
|
74592
74595
|
k4 = s4.bitk;
|
|
@@ -74611,13 +74614,13 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74611
74614
|
s4.bitb = b4;
|
|
74612
74615
|
s4.bitk = k4;
|
|
74613
74616
|
z4.avail_in = n4;
|
|
74614
|
-
z4.total_in +=
|
|
74615
|
-
z4.next_in_index =
|
|
74617
|
+
z4.total_in += p13 - z4.next_in_index;
|
|
74618
|
+
z4.next_in_index = p13;
|
|
74616
74619
|
s4.write = q3;
|
|
74617
74620
|
return s4.inflate_flush(z4, r5);
|
|
74618
74621
|
}
|
|
74619
74622
|
n4--;
|
|
74620
|
-
b4 |= (z4.read_byte(
|
|
74623
|
+
b4 |= (z4.read_byte(p13++) & 255) << k4;
|
|
74621
74624
|
k4 += 8;
|
|
74622
74625
|
}
|
|
74623
74626
|
tindex = (tree_index + (b4 & inflate_mask[j4])) * 3;
|
|
@@ -74650,8 +74653,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74650
74653
|
s4.bitb = b4;
|
|
74651
74654
|
s4.bitk = k4;
|
|
74652
74655
|
z4.avail_in = n4;
|
|
74653
|
-
z4.total_in +=
|
|
74654
|
-
z4.next_in_index =
|
|
74656
|
+
z4.total_in += p13 - z4.next_in_index;
|
|
74657
|
+
z4.next_in_index = p13;
|
|
74655
74658
|
s4.write = q3;
|
|
74656
74659
|
return s4.inflate_flush(z4, r5);
|
|
74657
74660
|
case LENEXT:
|
|
@@ -74663,13 +74666,13 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74663
74666
|
s4.bitb = b4;
|
|
74664
74667
|
s4.bitk = k4;
|
|
74665
74668
|
z4.avail_in = n4;
|
|
74666
|
-
z4.total_in +=
|
|
74667
|
-
z4.next_in_index =
|
|
74669
|
+
z4.total_in += p13 - z4.next_in_index;
|
|
74670
|
+
z4.next_in_index = p13;
|
|
74668
74671
|
s4.write = q3;
|
|
74669
74672
|
return s4.inflate_flush(z4, r5);
|
|
74670
74673
|
}
|
|
74671
74674
|
n4--;
|
|
74672
|
-
b4 |= (z4.read_byte(
|
|
74675
|
+
b4 |= (z4.read_byte(p13++) & 255) << k4;
|
|
74673
74676
|
k4 += 8;
|
|
74674
74677
|
}
|
|
74675
74678
|
len += b4 & inflate_mask[j4];
|
|
@@ -74689,13 +74692,13 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74689
74692
|
s4.bitb = b4;
|
|
74690
74693
|
s4.bitk = k4;
|
|
74691
74694
|
z4.avail_in = n4;
|
|
74692
|
-
z4.total_in +=
|
|
74693
|
-
z4.next_in_index =
|
|
74695
|
+
z4.total_in += p13 - z4.next_in_index;
|
|
74696
|
+
z4.next_in_index = p13;
|
|
74694
74697
|
s4.write = q3;
|
|
74695
74698
|
return s4.inflate_flush(z4, r5);
|
|
74696
74699
|
}
|
|
74697
74700
|
n4--;
|
|
74698
|
-
b4 |= (z4.read_byte(
|
|
74701
|
+
b4 |= (z4.read_byte(p13++) & 255) << k4;
|
|
74699
74702
|
k4 += 8;
|
|
74700
74703
|
}
|
|
74701
74704
|
tindex = (tree_index + (b4 & inflate_mask[j4])) * 3;
|
|
@@ -74719,8 +74722,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74719
74722
|
s4.bitb = b4;
|
|
74720
74723
|
s4.bitk = k4;
|
|
74721
74724
|
z4.avail_in = n4;
|
|
74722
|
-
z4.total_in +=
|
|
74723
|
-
z4.next_in_index =
|
|
74725
|
+
z4.total_in += p13 - z4.next_in_index;
|
|
74726
|
+
z4.next_in_index = p13;
|
|
74724
74727
|
s4.write = q3;
|
|
74725
74728
|
return s4.inflate_flush(z4, r5);
|
|
74726
74729
|
case DISTEXT:
|
|
@@ -74732,13 +74735,13 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74732
74735
|
s4.bitb = b4;
|
|
74733
74736
|
s4.bitk = k4;
|
|
74734
74737
|
z4.avail_in = n4;
|
|
74735
|
-
z4.total_in +=
|
|
74736
|
-
z4.next_in_index =
|
|
74738
|
+
z4.total_in += p13 - z4.next_in_index;
|
|
74739
|
+
z4.next_in_index = p13;
|
|
74737
74740
|
s4.write = q3;
|
|
74738
74741
|
return s4.inflate_flush(z4, r5);
|
|
74739
74742
|
}
|
|
74740
74743
|
n4--;
|
|
74741
|
-
b4 |= (z4.read_byte(
|
|
74744
|
+
b4 |= (z4.read_byte(p13++) & 255) << k4;
|
|
74742
74745
|
k4 += 8;
|
|
74743
74746
|
}
|
|
74744
74747
|
dist += b4 & inflate_mask[j4];
|
|
@@ -74770,8 +74773,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74770
74773
|
s4.bitb = b4;
|
|
74771
74774
|
s4.bitk = k4;
|
|
74772
74775
|
z4.avail_in = n4;
|
|
74773
|
-
z4.total_in +=
|
|
74774
|
-
z4.next_in_index =
|
|
74776
|
+
z4.total_in += p13 - z4.next_in_index;
|
|
74777
|
+
z4.next_in_index = p13;
|
|
74775
74778
|
s4.write = q3;
|
|
74776
74779
|
return s4.inflate_flush(z4, r5);
|
|
74777
74780
|
}
|
|
@@ -74804,8 +74807,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74804
74807
|
s4.bitb = b4;
|
|
74805
74808
|
s4.bitk = k4;
|
|
74806
74809
|
z4.avail_in = n4;
|
|
74807
|
-
z4.total_in +=
|
|
74808
|
-
z4.next_in_index =
|
|
74810
|
+
z4.total_in += p13 - z4.next_in_index;
|
|
74811
|
+
z4.next_in_index = p13;
|
|
74809
74812
|
s4.write = q3;
|
|
74810
74813
|
return s4.inflate_flush(z4, r5);
|
|
74811
74814
|
}
|
|
@@ -74821,7 +74824,7 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74821
74824
|
if (k4 > 7) {
|
|
74822
74825
|
k4 -= 8;
|
|
74823
74826
|
n4++;
|
|
74824
|
-
|
|
74827
|
+
p13--;
|
|
74825
74828
|
}
|
|
74826
74829
|
s4.write = q3;
|
|
74827
74830
|
r5 = s4.inflate_flush(z4, r5);
|
|
@@ -74831,8 +74834,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74831
74834
|
s4.bitb = b4;
|
|
74832
74835
|
s4.bitk = k4;
|
|
74833
74836
|
z4.avail_in = n4;
|
|
74834
|
-
z4.total_in +=
|
|
74835
|
-
z4.next_in_index =
|
|
74837
|
+
z4.total_in += p13 - z4.next_in_index;
|
|
74838
|
+
z4.next_in_index = p13;
|
|
74836
74839
|
s4.write = q3;
|
|
74837
74840
|
return s4.inflate_flush(z4, r5);
|
|
74838
74841
|
}
|
|
@@ -74843,8 +74846,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74843
74846
|
s4.bitb = b4;
|
|
74844
74847
|
s4.bitk = k4;
|
|
74845
74848
|
z4.avail_in = n4;
|
|
74846
|
-
z4.total_in +=
|
|
74847
|
-
z4.next_in_index =
|
|
74849
|
+
z4.total_in += p13 - z4.next_in_index;
|
|
74850
|
+
z4.next_in_index = p13;
|
|
74848
74851
|
s4.write = q3;
|
|
74849
74852
|
return s4.inflate_flush(z4, r5);
|
|
74850
74853
|
case BADCODE:
|
|
@@ -74852,8 +74855,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74852
74855
|
s4.bitb = b4;
|
|
74853
74856
|
s4.bitk = k4;
|
|
74854
74857
|
z4.avail_in = n4;
|
|
74855
|
-
z4.total_in +=
|
|
74856
|
-
z4.next_in_index =
|
|
74858
|
+
z4.total_in += p13 - z4.next_in_index;
|
|
74859
|
+
z4.next_in_index = p13;
|
|
74857
74860
|
s4.write = q3;
|
|
74858
74861
|
return s4.inflate_flush(z4, r5);
|
|
74859
74862
|
default:
|
|
@@ -74861,8 +74864,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74861
74864
|
s4.bitb = b4;
|
|
74862
74865
|
s4.bitk = k4;
|
|
74863
74866
|
z4.avail_in = n4;
|
|
74864
|
-
z4.total_in +=
|
|
74865
|
-
z4.next_in_index =
|
|
74867
|
+
z4.total_in += p13 - z4.next_in_index;
|
|
74868
|
+
z4.next_in_index = p13;
|
|
74866
74869
|
s4.write = q3;
|
|
74867
74870
|
return s4.inflate_flush(z4, r5);
|
|
74868
74871
|
}
|
|
@@ -74937,9 +74940,9 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74937
74940
|
that.reset(z4, null);
|
|
74938
74941
|
that.inflate_flush = function(z5, r5) {
|
|
74939
74942
|
let n4;
|
|
74940
|
-
let
|
|
74943
|
+
let p13;
|
|
74941
74944
|
let q3;
|
|
74942
|
-
|
|
74945
|
+
p13 = z5.next_out_index;
|
|
74943
74946
|
q3 = that.read;
|
|
74944
74947
|
n4 = /* (int) */
|
|
74945
74948
|
(q3 <= that.write ? that.write : that.end) - q3;
|
|
@@ -74949,8 +74952,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74949
74952
|
r5 = Z_OK3;
|
|
74950
74953
|
z5.avail_out -= n4;
|
|
74951
74954
|
z5.total_out += n4;
|
|
74952
|
-
z5.next_out.set(that.win.subarray(q3, q3 + n4),
|
|
74953
|
-
|
|
74955
|
+
z5.next_out.set(that.win.subarray(q3, q3 + n4), p13);
|
|
74956
|
+
p13 += n4;
|
|
74954
74957
|
q3 += n4;
|
|
74955
74958
|
if (q3 == that.end) {
|
|
74956
74959
|
q3 = 0;
|
|
@@ -74963,11 +74966,11 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74963
74966
|
r5 = Z_OK3;
|
|
74964
74967
|
z5.avail_out -= n4;
|
|
74965
74968
|
z5.total_out += n4;
|
|
74966
|
-
z5.next_out.set(that.win.subarray(q3, q3 + n4),
|
|
74967
|
-
|
|
74969
|
+
z5.next_out.set(that.win.subarray(q3, q3 + n4), p13);
|
|
74970
|
+
p13 += n4;
|
|
74968
74971
|
q3 += n4;
|
|
74969
74972
|
}
|
|
74970
|
-
z5.next_out_index =
|
|
74973
|
+
z5.next_out_index = p13;
|
|
74971
74974
|
that.read = q3;
|
|
74972
74975
|
return r5;
|
|
74973
74976
|
};
|
|
@@ -74975,12 +74978,12 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74975
74978
|
let t5;
|
|
74976
74979
|
let b4;
|
|
74977
74980
|
let k4;
|
|
74978
|
-
let
|
|
74981
|
+
let p13;
|
|
74979
74982
|
let n4;
|
|
74980
74983
|
let q3;
|
|
74981
74984
|
let m4;
|
|
74982
74985
|
let i4;
|
|
74983
|
-
|
|
74986
|
+
p13 = z5.next_in_index;
|
|
74984
74987
|
n4 = z5.avail_in;
|
|
74985
74988
|
b4 = that.bitb;
|
|
74986
74989
|
k4 = that.bitk;
|
|
@@ -74998,13 +75001,13 @@ return ${compiler2.callType("value", tagType)}
|
|
|
74998
75001
|
that.bitb = b4;
|
|
74999
75002
|
that.bitk = k4;
|
|
75000
75003
|
z5.avail_in = n4;
|
|
75001
|
-
z5.total_in +=
|
|
75002
|
-
z5.next_in_index =
|
|
75004
|
+
z5.total_in += p13 - z5.next_in_index;
|
|
75005
|
+
z5.next_in_index = p13;
|
|
75003
75006
|
that.write = q3;
|
|
75004
75007
|
return that.inflate_flush(z5, r5);
|
|
75005
75008
|
}
|
|
75006
75009
|
n4--;
|
|
75007
|
-
b4 |= (z5.read_byte(
|
|
75010
|
+
b4 |= (z5.read_byte(p13++) & 255) << k4;
|
|
75008
75011
|
k4 += 8;
|
|
75009
75012
|
}
|
|
75010
75013
|
t5 = /* (int) */
|
|
@@ -75044,8 +75047,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
75044
75047
|
that.bitb = b4;
|
|
75045
75048
|
that.bitk = k4;
|
|
75046
75049
|
z5.avail_in = n4;
|
|
75047
|
-
z5.total_in +=
|
|
75048
|
-
z5.next_in_index =
|
|
75050
|
+
z5.total_in += p13 - z5.next_in_index;
|
|
75051
|
+
z5.next_in_index = p13;
|
|
75049
75052
|
that.write = q3;
|
|
75050
75053
|
return that.inflate_flush(z5, r5);
|
|
75051
75054
|
}
|
|
@@ -75058,13 +75061,13 @@ return ${compiler2.callType("value", tagType)}
|
|
|
75058
75061
|
that.bitb = b4;
|
|
75059
75062
|
that.bitk = k4;
|
|
75060
75063
|
z5.avail_in = n4;
|
|
75061
|
-
z5.total_in +=
|
|
75062
|
-
z5.next_in_index =
|
|
75064
|
+
z5.total_in += p13 - z5.next_in_index;
|
|
75065
|
+
z5.next_in_index = p13;
|
|
75063
75066
|
that.write = q3;
|
|
75064
75067
|
return that.inflate_flush(z5, r5);
|
|
75065
75068
|
}
|
|
75066
75069
|
n4--;
|
|
75067
|
-
b4 |= (z5.read_byte(
|
|
75070
|
+
b4 |= (z5.read_byte(p13++) & 255) << k4;
|
|
75068
75071
|
k4 += 8;
|
|
75069
75072
|
}
|
|
75070
75073
|
if ((~b4 >>> 16 & 65535) != (b4 & 65535)) {
|
|
@@ -75074,8 +75077,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
75074
75077
|
that.bitb = b4;
|
|
75075
75078
|
that.bitk = k4;
|
|
75076
75079
|
z5.avail_in = n4;
|
|
75077
|
-
z5.total_in +=
|
|
75078
|
-
z5.next_in_index =
|
|
75080
|
+
z5.total_in += p13 - z5.next_in_index;
|
|
75081
|
+
z5.next_in_index = p13;
|
|
75079
75082
|
that.write = q3;
|
|
75080
75083
|
return that.inflate_flush(z5, r5);
|
|
75081
75084
|
}
|
|
@@ -75088,8 +75091,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
75088
75091
|
that.bitb = b4;
|
|
75089
75092
|
that.bitk = k4;
|
|
75090
75093
|
z5.avail_in = n4;
|
|
75091
|
-
z5.total_in +=
|
|
75092
|
-
z5.next_in_index =
|
|
75094
|
+
z5.total_in += p13 - z5.next_in_index;
|
|
75095
|
+
z5.next_in_index = p13;
|
|
75093
75096
|
that.write = q3;
|
|
75094
75097
|
return that.inflate_flush(z5, r5);
|
|
75095
75098
|
}
|
|
@@ -75114,8 +75117,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
75114
75117
|
that.bitb = b4;
|
|
75115
75118
|
that.bitk = k4;
|
|
75116
75119
|
z5.avail_in = n4;
|
|
75117
|
-
z5.total_in +=
|
|
75118
|
-
z5.next_in_index =
|
|
75120
|
+
z5.total_in += p13 - z5.next_in_index;
|
|
75121
|
+
z5.next_in_index = p13;
|
|
75119
75122
|
that.write = q3;
|
|
75120
75123
|
return that.inflate_flush(z5, r5);
|
|
75121
75124
|
}
|
|
@@ -75127,8 +75130,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
75127
75130
|
t5 = n4;
|
|
75128
75131
|
if (t5 > m4)
|
|
75129
75132
|
t5 = m4;
|
|
75130
|
-
that.win.set(z5.read_buf(
|
|
75131
|
-
|
|
75133
|
+
that.win.set(z5.read_buf(p13, t5), q3);
|
|
75134
|
+
p13 += t5;
|
|
75132
75135
|
n4 -= t5;
|
|
75133
75136
|
q3 += t5;
|
|
75134
75137
|
m4 -= t5;
|
|
@@ -75144,13 +75147,13 @@ return ${compiler2.callType("value", tagType)}
|
|
|
75144
75147
|
that.bitb = b4;
|
|
75145
75148
|
that.bitk = k4;
|
|
75146
75149
|
z5.avail_in = n4;
|
|
75147
|
-
z5.total_in +=
|
|
75148
|
-
z5.next_in_index =
|
|
75150
|
+
z5.total_in += p13 - z5.next_in_index;
|
|
75151
|
+
z5.next_in_index = p13;
|
|
75149
75152
|
that.write = q3;
|
|
75150
75153
|
return that.inflate_flush(z5, r5);
|
|
75151
75154
|
}
|
|
75152
75155
|
n4--;
|
|
75153
|
-
b4 |= (z5.read_byte(
|
|
75156
|
+
b4 |= (z5.read_byte(p13++) & 255) << k4;
|
|
75154
75157
|
k4 += 8;
|
|
75155
75158
|
}
|
|
75156
75159
|
table3 = t5 = b4 & 16383;
|
|
@@ -75161,8 +75164,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
75161
75164
|
that.bitb = b4;
|
|
75162
75165
|
that.bitk = k4;
|
|
75163
75166
|
z5.avail_in = n4;
|
|
75164
|
-
z5.total_in +=
|
|
75165
|
-
z5.next_in_index =
|
|
75167
|
+
z5.total_in += p13 - z5.next_in_index;
|
|
75168
|
+
z5.next_in_index = p13;
|
|
75166
75169
|
that.write = q3;
|
|
75167
75170
|
return that.inflate_flush(z5, r5);
|
|
75168
75171
|
}
|
|
@@ -75188,13 +75191,13 @@ return ${compiler2.callType("value", tagType)}
|
|
|
75188
75191
|
that.bitb = b4;
|
|
75189
75192
|
that.bitk = k4;
|
|
75190
75193
|
z5.avail_in = n4;
|
|
75191
|
-
z5.total_in +=
|
|
75192
|
-
z5.next_in_index =
|
|
75194
|
+
z5.total_in += p13 - z5.next_in_index;
|
|
75195
|
+
z5.next_in_index = p13;
|
|
75193
75196
|
that.write = q3;
|
|
75194
75197
|
return that.inflate_flush(z5, r5);
|
|
75195
75198
|
}
|
|
75196
75199
|
n4--;
|
|
75197
|
-
b4 |= (z5.read_byte(
|
|
75200
|
+
b4 |= (z5.read_byte(p13++) & 255) << k4;
|
|
75198
75201
|
k4 += 8;
|
|
75199
75202
|
}
|
|
75200
75203
|
blens[border[index++]] = b4 & 7;
|
|
@@ -75215,8 +75218,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
75215
75218
|
that.bitb = b4;
|
|
75216
75219
|
that.bitk = k4;
|
|
75217
75220
|
z5.avail_in = n4;
|
|
75218
|
-
z5.total_in +=
|
|
75219
|
-
z5.next_in_index =
|
|
75221
|
+
z5.total_in += p13 - z5.next_in_index;
|
|
75222
|
+
z5.next_in_index = p13;
|
|
75220
75223
|
that.write = q3;
|
|
75221
75224
|
return that.inflate_flush(z5, r5);
|
|
75222
75225
|
}
|
|
@@ -75238,13 +75241,13 @@ return ${compiler2.callType("value", tagType)}
|
|
|
75238
75241
|
that.bitb = b4;
|
|
75239
75242
|
that.bitk = k4;
|
|
75240
75243
|
z5.avail_in = n4;
|
|
75241
|
-
z5.total_in +=
|
|
75242
|
-
z5.next_in_index =
|
|
75244
|
+
z5.total_in += p13 - z5.next_in_index;
|
|
75245
|
+
z5.next_in_index = p13;
|
|
75243
75246
|
that.write = q3;
|
|
75244
75247
|
return that.inflate_flush(z5, r5);
|
|
75245
75248
|
}
|
|
75246
75249
|
n4--;
|
|
75247
|
-
b4 |= (z5.read_byte(
|
|
75250
|
+
b4 |= (z5.read_byte(p13++) & 255) << k4;
|
|
75248
75251
|
k4 += 8;
|
|
75249
75252
|
}
|
|
75250
75253
|
t5 = hufts[(tb[0] + (b4 & inflate_mask[t5])) * 3 + 1];
|
|
@@ -75263,13 +75266,13 @@ return ${compiler2.callType("value", tagType)}
|
|
|
75263
75266
|
that.bitb = b4;
|
|
75264
75267
|
that.bitk = k4;
|
|
75265
75268
|
z5.avail_in = n4;
|
|
75266
|
-
z5.total_in +=
|
|
75267
|
-
z5.next_in_index =
|
|
75269
|
+
z5.total_in += p13 - z5.next_in_index;
|
|
75270
|
+
z5.next_in_index = p13;
|
|
75268
75271
|
that.write = q3;
|
|
75269
75272
|
return that.inflate_flush(z5, r5);
|
|
75270
75273
|
}
|
|
75271
75274
|
n4--;
|
|
75272
|
-
b4 |= (z5.read_byte(
|
|
75275
|
+
b4 |= (z5.read_byte(p13++) & 255) << k4;
|
|
75273
75276
|
k4 += 8;
|
|
75274
75277
|
}
|
|
75275
75278
|
b4 >>>= t5;
|
|
@@ -75287,8 +75290,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
75287
75290
|
that.bitb = b4;
|
|
75288
75291
|
that.bitk = k4;
|
|
75289
75292
|
z5.avail_in = n4;
|
|
75290
|
-
z5.total_in +=
|
|
75291
|
-
z5.next_in_index =
|
|
75293
|
+
z5.total_in += p13 - z5.next_in_index;
|
|
75294
|
+
z5.next_in_index = p13;
|
|
75292
75295
|
that.write = q3;
|
|
75293
75296
|
return that.inflate_flush(z5, r5);
|
|
75294
75297
|
}
|
|
@@ -75317,8 +75320,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
75317
75320
|
that.bitb = b4;
|
|
75318
75321
|
that.bitk = k4;
|
|
75319
75322
|
z5.avail_in = n4;
|
|
75320
|
-
z5.total_in +=
|
|
75321
|
-
z5.next_in_index =
|
|
75323
|
+
z5.total_in += p13 - z5.next_in_index;
|
|
75324
|
+
z5.next_in_index = p13;
|
|
75322
75325
|
that.write = q3;
|
|
75323
75326
|
return that.inflate_flush(z5, r5);
|
|
75324
75327
|
}
|
|
@@ -75329,15 +75332,15 @@ return ${compiler2.callType("value", tagType)}
|
|
|
75329
75332
|
that.bitb = b4;
|
|
75330
75333
|
that.bitk = k4;
|
|
75331
75334
|
z5.avail_in = n4;
|
|
75332
|
-
z5.total_in +=
|
|
75333
|
-
z5.next_in_index =
|
|
75335
|
+
z5.total_in += p13 - z5.next_in_index;
|
|
75336
|
+
z5.next_in_index = p13;
|
|
75334
75337
|
that.write = q3;
|
|
75335
75338
|
if ((r5 = codes2.proc(that, z5, r5)) != Z_STREAM_END3) {
|
|
75336
75339
|
return that.inflate_flush(z5, r5);
|
|
75337
75340
|
}
|
|
75338
75341
|
r5 = Z_OK3;
|
|
75339
75342
|
codes2.free(z5);
|
|
75340
|
-
|
|
75343
|
+
p13 = z5.next_in_index;
|
|
75341
75344
|
n4 = z5.avail_in;
|
|
75342
75345
|
b4 = that.bitb;
|
|
75343
75346
|
k4 = that.bitk;
|
|
@@ -75360,8 +75363,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
75360
75363
|
that.bitb = b4;
|
|
75361
75364
|
that.bitk = k4;
|
|
75362
75365
|
z5.avail_in = n4;
|
|
75363
|
-
z5.total_in +=
|
|
75364
|
-
z5.next_in_index =
|
|
75366
|
+
z5.total_in += p13 - z5.next_in_index;
|
|
75367
|
+
z5.next_in_index = p13;
|
|
75365
75368
|
that.write = q3;
|
|
75366
75369
|
return that.inflate_flush(z5, r5);
|
|
75367
75370
|
}
|
|
@@ -75372,8 +75375,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
75372
75375
|
that.bitb = b4;
|
|
75373
75376
|
that.bitk = k4;
|
|
75374
75377
|
z5.avail_in = n4;
|
|
75375
|
-
z5.total_in +=
|
|
75376
|
-
z5.next_in_index =
|
|
75378
|
+
z5.total_in += p13 - z5.next_in_index;
|
|
75379
|
+
z5.next_in_index = p13;
|
|
75377
75380
|
that.write = q3;
|
|
75378
75381
|
return that.inflate_flush(z5, r5);
|
|
75379
75382
|
case BADBLOCKS:
|
|
@@ -75381,8 +75384,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
75381
75384
|
that.bitb = b4;
|
|
75382
75385
|
that.bitk = k4;
|
|
75383
75386
|
z5.avail_in = n4;
|
|
75384
|
-
z5.total_in +=
|
|
75385
|
-
z5.next_in_index =
|
|
75387
|
+
z5.total_in += p13 - z5.next_in_index;
|
|
75388
|
+
z5.next_in_index = p13;
|
|
75386
75389
|
that.write = q3;
|
|
75387
75390
|
return that.inflate_flush(z5, r5);
|
|
75388
75391
|
default:
|
|
@@ -75390,8 +75393,8 @@ return ${compiler2.callType("value", tagType)}
|
|
|
75390
75393
|
that.bitb = b4;
|
|
75391
75394
|
that.bitk = k4;
|
|
75392
75395
|
z5.avail_in = n4;
|
|
75393
|
-
z5.total_in +=
|
|
75394
|
-
z5.next_in_index =
|
|
75396
|
+
z5.total_in += p13 - z5.next_in_index;
|
|
75397
|
+
z5.next_in_index = p13;
|
|
75395
75398
|
that.write = q3;
|
|
75396
75399
|
return that.inflate_flush(z5, r5);
|
|
75397
75400
|
}
|
|
@@ -75590,7 +75593,7 @@ return ${compiler2.callType("value", tagType)}
|
|
|
75590
75593
|
};
|
|
75591
75594
|
that.inflateSync = function(z4) {
|
|
75592
75595
|
let n4;
|
|
75593
|
-
let
|
|
75596
|
+
let p13;
|
|
75594
75597
|
let m4;
|
|
75595
75598
|
let r5, w4;
|
|
75596
75599
|
if (!z4 || !z4.istate)
|
|
@@ -75602,21 +75605,21 @@ return ${compiler2.callType("value", tagType)}
|
|
|
75602
75605
|
}
|
|
75603
75606
|
if ((n4 = z4.avail_in) === 0)
|
|
75604
75607
|
return Z_BUF_ERROR3;
|
|
75605
|
-
|
|
75608
|
+
p13 = z4.next_in_index;
|
|
75606
75609
|
m4 = istate.marker;
|
|
75607
75610
|
while (n4 !== 0 && m4 < 4) {
|
|
75608
|
-
if (z4.read_byte(
|
|
75611
|
+
if (z4.read_byte(p13) == mark[m4]) {
|
|
75609
75612
|
m4++;
|
|
75610
|
-
} else if (z4.read_byte(
|
|
75613
|
+
} else if (z4.read_byte(p13) !== 0) {
|
|
75611
75614
|
m4 = 0;
|
|
75612
75615
|
} else {
|
|
75613
75616
|
m4 = 4 - m4;
|
|
75614
75617
|
}
|
|
75615
|
-
|
|
75618
|
+
p13++;
|
|
75616
75619
|
n4--;
|
|
75617
75620
|
}
|
|
75618
|
-
z4.total_in +=
|
|
75619
|
-
z4.next_in_index =
|
|
75621
|
+
z4.total_in += p13 - z4.next_in_index;
|
|
75622
|
+
z4.next_in_index = p13;
|
|
75620
75623
|
z4.avail_in = n4;
|
|
75621
75624
|
istate.marker = m4;
|
|
75622
75625
|
if (m4 != 4) {
|
|
@@ -80284,7 +80287,7 @@ ${key}` : key;
|
|
|
80284
80287
|
static async get(key) {
|
|
80285
80288
|
const keyStr = key.serialize();
|
|
80286
80289
|
const pending = this.preload(key);
|
|
80287
|
-
const
|
|
80290
|
+
const cached2 = Caching.textureAssetCache.getIfPresent(keyStr);
|
|
80288
80291
|
try {
|
|
80289
80292
|
const asset = await pending;
|
|
80290
80293
|
if (asset) {
|
|
@@ -80292,7 +80295,7 @@ ${key}` : key;
|
|
|
80292
80295
|
}
|
|
80293
80296
|
return void 0;
|
|
80294
80297
|
} catch (err2) {
|
|
80295
|
-
if (
|
|
80298
|
+
if (cached2 && Caching.textureAssetCache.getIfPresent(keyStr) === cached2) {
|
|
80296
80299
|
Caching.textureAssetCache.invalidate(keyStr);
|
|
80297
80300
|
}
|
|
80298
80301
|
throw err2;
|
|
@@ -81469,6 +81472,10 @@ ${key}` : key;
|
|
|
81469
81472
|
this.setMatrixAt(index, new Matrix4());
|
|
81470
81473
|
return reference;
|
|
81471
81474
|
}
|
|
81475
|
+
/** Returns the live reference for a raycast hit on this object's instance mesh. */
|
|
81476
|
+
getInstanceReference(mesh, index) {
|
|
81477
|
+
return mesh === this.instanceMesh ? this.instanceReferences.get(index) : void 0;
|
|
81478
|
+
}
|
|
81472
81479
|
isInstanceActive(index, reference) {
|
|
81473
81480
|
return this.instanceReferences.get(index) === reference;
|
|
81474
81481
|
}
|
|
@@ -81551,9 +81558,9 @@ ${key}` : key;
|
|
|
81551
81558
|
}
|
|
81552
81559
|
getRotationAt(index, euler = new Euler()) {
|
|
81553
81560
|
if (!this.isInstanced) throw new MineRenderError("Object is not instanced");
|
|
81554
|
-
const
|
|
81555
|
-
|
|
81556
|
-
return euler;
|
|
81561
|
+
const rotation = new Quaternion();
|
|
81562
|
+
this.getMatrixAt(index).decompose(new Vector3(), rotation, new Vector3());
|
|
81563
|
+
return euler.setFromQuaternion(rotation);
|
|
81557
81564
|
}
|
|
81558
81565
|
setScaleAt(index, scale) {
|
|
81559
81566
|
if (!this.isInstanced) throw new MineRenderError("Object is not instanced");
|
|
@@ -81833,11 +81840,12 @@ ${key}` : key;
|
|
|
81833
81840
|
init_buffer2();
|
|
81834
81841
|
init_process2();
|
|
81835
81842
|
var p10 = prefix("SceneInspector");
|
|
81836
|
-
var help = "<span>Ctrl+Click to Select<br/></span><br/>";
|
|
81843
|
+
var help = "<span>Ctrl/Cmd+Click to Select<br/></span><br/>";
|
|
81837
81844
|
var SceneInspector = class {
|
|
81838
81845
|
constructor(renderer) {
|
|
81839
81846
|
this.renderer = renderer;
|
|
81840
81847
|
this.mouse = new Vector2();
|
|
81848
|
+
this.listeners = new AbortController();
|
|
81841
81849
|
this.objectInfoContainer = document.createElement("div");
|
|
81842
81850
|
this.objectControlsContainer = document.createElement("div");
|
|
81843
81851
|
this.raycaster = new Raycaster();
|
|
@@ -81847,13 +81855,44 @@ ${key}` : key;
|
|
|
81847
81855
|
this.objectInfoContainer.classList.add("minerender-inspector", "minerender-object-info");
|
|
81848
81856
|
this.objectControlsContainer.classList.add("minerender-inspector", "minerender-object-controls");
|
|
81849
81857
|
this.objectInfoContainer.innerHTML = help;
|
|
81850
|
-
|
|
81851
|
-
|
|
81852
|
-
|
|
81858
|
+
const canvas = this.renderer.renderer.domElement;
|
|
81859
|
+
const options = { signal: this.listeners.signal };
|
|
81860
|
+
canvas.addEventListener("pointerdown", (event) => {
|
|
81861
|
+
this.pointer = event.button === 0 && (event.ctrlKey || event.metaKey) ? event : void 0;
|
|
81862
|
+
}, options);
|
|
81863
|
+
canvas.addEventListener("pointermove", (event) => {
|
|
81864
|
+
if (this.pointer?.pointerId === event.pointerId && Math.hypot(event.clientX - this.pointer.clientX, event.clientY - this.pointer.clientY) > 5) {
|
|
81865
|
+
this.pointer = void 0;
|
|
81866
|
+
}
|
|
81867
|
+
}, options);
|
|
81868
|
+
canvas.addEventListener("pointerup", (event) => {
|
|
81869
|
+
const start = this.pointer;
|
|
81870
|
+
this.pointer = void 0;
|
|
81871
|
+
if (start?.pointerId === event.pointerId && Math.hypot(event.clientX - start.clientX, event.clientY - start.clientY) <= 5) {
|
|
81872
|
+
this.onClick(event);
|
|
81873
|
+
}
|
|
81874
|
+
}, options);
|
|
81875
|
+
canvas.addEventListener("pointercancel", () => {
|
|
81876
|
+
this.pointer = void 0;
|
|
81877
|
+
}, options);
|
|
81878
|
+
canvas.addEventListener("pointerleave", () => {
|
|
81879
|
+
this.pointer = void 0;
|
|
81880
|
+
}, options);
|
|
81881
|
+
canvas.addEventListener("contextmenu", (event) => {
|
|
81882
|
+
if (this.pointer?.ctrlKey) event.preventDefault();
|
|
81883
|
+
}, options);
|
|
81884
|
+
}
|
|
81885
|
+
dispose() {
|
|
81886
|
+
this.listeners.abort();
|
|
81887
|
+
this.pointer = void 0;
|
|
81888
|
+
this.selectedObject = void 0;
|
|
81889
|
+
this.objectInfoContainer.remove();
|
|
81890
|
+
this.objectControlsContainer.remove();
|
|
81853
81891
|
}
|
|
81854
81892
|
findMeshChildren(from, out = []) {
|
|
81893
|
+
if (!from.visible) return out;
|
|
81855
81894
|
for (let c4 of from.children) {
|
|
81856
|
-
if (isMesh(c4)) {
|
|
81895
|
+
if (c4.visible && isMesh(c4)) {
|
|
81857
81896
|
out.push(c4);
|
|
81858
81897
|
}
|
|
81859
81898
|
this.findMeshChildren(c4, out);
|
|
@@ -81861,50 +81900,43 @@ ${key}` : key;
|
|
|
81861
81900
|
return out;
|
|
81862
81901
|
}
|
|
81863
81902
|
onClick(event) {
|
|
81864
|
-
|
|
81865
|
-
if (!event.ctrlKey) return;
|
|
81866
|
-
|
|
81867
|
-
|
|
81868
|
-
|
|
81869
|
-
|
|
81870
|
-
|
|
81871
|
-
|
|
81872
|
-
|
|
81873
|
-
|
|
81874
|
-
if (intersects.length > 0) {
|
|
81875
|
-
this.handleRaycasterObjects(intersects);
|
|
81876
|
-
}
|
|
81877
|
-
});
|
|
81903
|
+
const canvas = this.renderer.renderer.domElement;
|
|
81904
|
+
if (event.target !== canvas || event.button !== 0 || !(event.ctrlKey || event.metaKey)) return;
|
|
81905
|
+
const rect = canvas.getBoundingClientRect();
|
|
81906
|
+
const x4 = event.clientX - rect.left, y5 = event.clientY - rect.top;
|
|
81907
|
+
if (rect.width <= 0 || rect.height <= 0 || x4 < 0 || y5 < 0 || x4 >= rect.width || y5 >= rect.height) return;
|
|
81908
|
+
this.mouse.set(x4 / rect.width * 2 - 1, 1 - y5 / rect.height * 2);
|
|
81909
|
+
this.renderer.camera.updateWorldMatrix(true, false);
|
|
81910
|
+
this.renderer.scene.updateMatrixWorld(true);
|
|
81911
|
+
this.raycaster.setFromCamera(this.mouse, this.renderer.camera);
|
|
81912
|
+
this.handleRaycasterObjects(this.raycaster.intersectObjects(this.findMeshChildren(this.renderer.scene), false));
|
|
81878
81913
|
}
|
|
81879
81914
|
appendTo(el) {
|
|
81880
81915
|
el.append(this.objectInfoContainer);
|
|
81881
81916
|
el.append(this.objectControlsContainer);
|
|
81882
81917
|
}
|
|
81883
81918
|
handleRaycasterObjects(intersections) {
|
|
81884
|
-
|
|
81885
|
-
|
|
81886
|
-
|
|
81887
|
-
|
|
81888
|
-
|
|
81889
|
-
|
|
81890
|
-
|
|
81891
|
-
|
|
81892
|
-
|
|
81893
|
-
|
|
81894
|
-
|
|
81895
|
-
targetIntersection = firstIntersection;
|
|
81896
|
-
targetObject = firstObject;
|
|
81919
|
+
const hit = intersections[0];
|
|
81920
|
+
if (!hit) return;
|
|
81921
|
+
const instance = this.getIntersectionInstance(hit);
|
|
81922
|
+
this.selectObject(instance?.instanceable ?? hit.object, hit, instance);
|
|
81923
|
+
}
|
|
81924
|
+
getIntersectionInstance(hit) {
|
|
81925
|
+
if (hit?.instanceId === void 0) return void 0;
|
|
81926
|
+
for (let parent = hit.object.parent; parent; parent = parent.parent) {
|
|
81927
|
+
if (isSceneObject(parent)) {
|
|
81928
|
+
const instance = parent.getInstanceReference(hit.object, hit.instanceId);
|
|
81929
|
+
if (instance) return instance;
|
|
81897
81930
|
}
|
|
81898
|
-
if (!targetIntersection || !targetObject) return;
|
|
81899
|
-
this.selectObject(targetObject, targetIntersection);
|
|
81900
81931
|
}
|
|
81932
|
+
return void 0;
|
|
81901
81933
|
}
|
|
81902
|
-
selectObject(targetObject, targetIntersection) {
|
|
81934
|
+
selectObject(targetObject, targetIntersection, instance = this.getIntersectionInstance(targetIntersection)) {
|
|
81903
81935
|
this.selectedObject = targetObject;
|
|
81904
81936
|
console.log(p10, "selected", targetObject);
|
|
81905
|
-
this.redraw(targetObject, targetIntersection);
|
|
81937
|
+
this.redraw(targetObject, targetIntersection, instance);
|
|
81906
81938
|
}
|
|
81907
|
-
redraw(targetObject, targetIntersection) {
|
|
81939
|
+
redraw(targetObject, targetIntersection, instance) {
|
|
81908
81940
|
this.objectInfoContainer.innerHTML = help;
|
|
81909
81941
|
if (targetIntersection) {
|
|
81910
81942
|
this.addInfoLine("Distance", "D", targetIntersection.distance);
|
|
@@ -81917,8 +81949,8 @@ ${key}` : key;
|
|
|
81917
81949
|
if (isSceneObject(targetObject.parent)) {
|
|
81918
81950
|
}
|
|
81919
81951
|
}
|
|
81920
|
-
|
|
81921
|
-
|
|
81952
|
+
const atlas = "atlas" in targetObject ? targetObject["atlas"] : void 0;
|
|
81953
|
+
if (atlas?.image.canvas) {
|
|
81922
81954
|
const img = atlas.image.canvas;
|
|
81923
81955
|
img.style.width = "100px";
|
|
81924
81956
|
img.style.height = "100px";
|
|
@@ -81927,28 +81959,31 @@ ${key}` : key;
|
|
|
81927
81959
|
this.objectInfoContainer.prepend(img);
|
|
81928
81960
|
}
|
|
81929
81961
|
this.objectControlsContainer.innerHTML = "";
|
|
81930
|
-
this.addControls(targetObject, targetIntersection);
|
|
81962
|
+
this.addControls(targetObject, targetIntersection, instance);
|
|
81931
81963
|
}
|
|
81932
|
-
addControls(object, intersection) {
|
|
81964
|
+
addControls(object, intersection, instance) {
|
|
81933
81965
|
const container = document.createElement("div");
|
|
81934
81966
|
container.append(this.separator("Select Parent/Child"));
|
|
81935
81967
|
if (object.parent) {
|
|
81936
81968
|
container.append(this.buttonControl("Select Parent " + object.parent.constructor.name + " " + object.parent.name, "P", () => {
|
|
81937
|
-
this.selectObject(object.parent, intersection);
|
|
81969
|
+
this.selectObject(object.parent, intersection, instance);
|
|
81938
81970
|
}));
|
|
81939
81971
|
}
|
|
81940
81972
|
if (object.children.length > 0) {
|
|
81941
81973
|
let i4 = 1;
|
|
81942
81974
|
for (let child of object.children) {
|
|
81943
81975
|
container.append(this.buttonControl("Select Child " + child.constructor.name + " " + child.name, "C" + i4++, () => {
|
|
81944
|
-
this.selectObject(child, intersection);
|
|
81976
|
+
this.selectObject(child, intersection, instance);
|
|
81945
81977
|
}));
|
|
81946
81978
|
}
|
|
81947
81979
|
}
|
|
81948
81980
|
container.append(this.separator());
|
|
81949
|
-
|
|
81981
|
+
const selectedInstance = instance && (object === instance.instanceable || object === intersection?.object) ? instance : void 0;
|
|
81982
|
+
if (!selectedInstance) {
|
|
81983
|
+
container.append(this.toggleControl("Visibility", "V", object.visible, (v5) => object.visible = v5));
|
|
81984
|
+
}
|
|
81950
81985
|
container.append(this.separator("Mesh"));
|
|
81951
|
-
this.addObjectControls(object, intersection, container);
|
|
81986
|
+
this.addObjectControls(object, intersection, container, selectedInstance);
|
|
81952
81987
|
container.append(this.separator());
|
|
81953
81988
|
this.objectControlsContainer.append(container);
|
|
81954
81989
|
}
|
|
@@ -81960,78 +81995,26 @@ ${key}` : key;
|
|
|
81960
81995
|
this.objectInfoContainer.append(document.createElement("br"));
|
|
81961
81996
|
return el;
|
|
81962
81997
|
}
|
|
81963
|
-
addObjectControls(target, intersection, container) {
|
|
81998
|
+
addObjectControls(target, intersection, container, instance) {
|
|
81964
81999
|
const posRange = 16 * 16;
|
|
81965
82000
|
const rotRange = 360;
|
|
81966
82001
|
const scaleRange = 4;
|
|
81967
|
-
|
|
81968
|
-
|
|
81969
|
-
|
|
81970
|
-
let pos = scObj.getPositionAt(intersection.instanceId);
|
|
81971
|
-
container.append(this.rangeControl("X Position", "X", -posRange + pos.x, posRange + pos.x, pos.x, 1, (v5) => {
|
|
81972
|
-
pos = scObj.getPositionAt(intersection.instanceId);
|
|
81973
|
-
pos.x = v5;
|
|
81974
|
-
scObj.setPositionAt(intersection.instanceId, pos);
|
|
81975
|
-
}));
|
|
81976
|
-
container.append(this.rangeControl("Y Position", "Y", -posRange + pos.y, posRange + pos.y, pos.y, 1, (v5) => {
|
|
81977
|
-
pos = scObj.getPositionAt(intersection.instanceId);
|
|
81978
|
-
pos.y = v5;
|
|
81979
|
-
scObj.setPositionAt(intersection.instanceId, pos);
|
|
81980
|
-
}));
|
|
81981
|
-
container.append(this.rangeControl("Z Position", "Z", -posRange + pos.z, posRange + pos.z, pos.z, 1, (v5) => {
|
|
81982
|
-
pos = scObj.getPositionAt(intersection.instanceId);
|
|
81983
|
-
pos.z = v5;
|
|
81984
|
-
scObj.setPositionAt(intersection.instanceId, pos);
|
|
81985
|
-
}));
|
|
81986
|
-
container.append(this.separator("Rotation"));
|
|
81987
|
-
let rot = scObj.getRotationAt(intersection.instanceId);
|
|
81988
|
-
container.append(this.rangeControl("X Rotation", "X", 0, rotRange, Math.round(toDegrees(rot.x)), 1, (v5) => {
|
|
81989
|
-
rot = scObj.getRotationAt(intersection.instanceId);
|
|
81990
|
-
rot.x = toRadians(v5);
|
|
81991
|
-
scObj.setRotationAt(intersection.instanceId, rot);
|
|
81992
|
-
}));
|
|
81993
|
-
container.append(this.rangeControl("Y Rotation", "Y", 0, rotRange, Math.round(toDegrees(rot.y)), 1, (v5) => {
|
|
81994
|
-
rot = scObj.getRotationAt(intersection.instanceId);
|
|
81995
|
-
rot.y = toRadians(v5);
|
|
81996
|
-
scObj.setRotationAt(intersection.instanceId, rot);
|
|
81997
|
-
}));
|
|
81998
|
-
container.append(this.rangeControl("Z Rotation", "Z", 0, rotRange, Math.round(toDegrees(rot.z)), 1, (v5) => {
|
|
81999
|
-
rot = scObj.getRotationAt(intersection.instanceId);
|
|
82000
|
-
rot.z = toRadians(v5);
|
|
82001
|
-
scObj.setRotationAt(intersection.instanceId, rot);
|
|
82002
|
-
}));
|
|
82003
|
-
container.append(this.separator("Scale"));
|
|
82004
|
-
let scl = scObj.getScale();
|
|
82005
|
-
container.append(this.rangeControl("X Scale", "X", 0, scaleRange, scl.x, 0.1, (v5) => {
|
|
82006
|
-
scl = scObj.getScaleAt(intersection.instanceId);
|
|
82007
|
-
scl.x = v5;
|
|
82008
|
-
scObj.setScaleAt(intersection.instanceId, scl);
|
|
82009
|
-
}));
|
|
82010
|
-
container.append(this.rangeControl("Y Scale", "Y", 0, scaleRange, scl.y, 0.1, (v5) => {
|
|
82011
|
-
scl = scObj.getScaleAt(intersection.instanceId);
|
|
82012
|
-
scl.y = v5;
|
|
82013
|
-
scObj.setScaleAt(intersection.instanceId, scl);
|
|
82014
|
-
}));
|
|
82015
|
-
container.append(this.rangeControl("Z Scale", "Z", 0, scaleRange, scl.z, 0.1, (v5) => {
|
|
82016
|
-
scl = scObj.getScaleAt(intersection.instanceId);
|
|
82017
|
-
scl.z = v5;
|
|
82018
|
-
scObj.setScaleAt(intersection.instanceId, scl);
|
|
82019
|
-
}));
|
|
82020
|
-
} else if (isTransformable(target)) {
|
|
82021
|
-
const parent = target;
|
|
82002
|
+
const transform = instance ?? (isTransformable(target) ? target : void 0);
|
|
82003
|
+
if (transform) {
|
|
82004
|
+
const parent = transform;
|
|
82022
82005
|
container.append(this.separator("Position"));
|
|
82023
82006
|
let pos = parent.getPosition();
|
|
82024
|
-
container.append(this.rangeControl("X Position", "X", -posRange, posRange, pos.x, 1, (v5) => {
|
|
82007
|
+
container.append(this.rangeControl("X Position", "X", pos.x - posRange, pos.x + posRange, pos.x, 1, (v5) => {
|
|
82025
82008
|
pos = parent.getPosition();
|
|
82026
82009
|
pos.x = v5;
|
|
82027
82010
|
parent.setPosition(pos);
|
|
82028
82011
|
}));
|
|
82029
|
-
container.append(this.rangeControl("Y Position", "Y", -posRange, posRange, pos.y, 1, (v5) => {
|
|
82012
|
+
container.append(this.rangeControl("Y Position", "Y", pos.y - posRange, pos.y + posRange, pos.y, 1, (v5) => {
|
|
82030
82013
|
pos = parent.getPosition();
|
|
82031
82014
|
pos.y = v5;
|
|
82032
82015
|
parent.setPosition(pos);
|
|
82033
82016
|
}));
|
|
82034
|
-
container.append(this.rangeControl("Z Position", "Z", -posRange, posRange, pos.z, 1, (v5) => {
|
|
82017
|
+
container.append(this.rangeControl("Z Position", "Z", pos.z - posRange, pos.z + posRange, pos.z, 1, (v5) => {
|
|
82035
82018
|
pos = parent.getPosition();
|
|
82036
82019
|
pos.z = v5;
|
|
82037
82020
|
parent.setPosition(pos);
|
|
@@ -82120,6 +82103,7 @@ ${key}` : key;
|
|
|
82120
82103
|
toggle.checked = val;
|
|
82121
82104
|
toggle.addEventListener("change", (e6) => {
|
|
82122
82105
|
change(toggle.checked);
|
|
82106
|
+
this.renderer.scene.dirty = true;
|
|
82123
82107
|
});
|
|
82124
82108
|
label.append(toggle);
|
|
82125
82109
|
label.append(document.createElement("br"));
|
|
@@ -82132,7 +82116,6 @@ ${key}` : key;
|
|
|
82132
82116
|
label.setAttribute("title", name2);
|
|
82133
82117
|
labelText.style.width = "18%";
|
|
82134
82118
|
labelText.style.display = "inline-block";
|
|
82135
|
-
labelText.innerText = `${id} (${val})`;
|
|
82136
82119
|
const range = document.createElement("input");
|
|
82137
82120
|
range.setAttribute("type", "range");
|
|
82138
82121
|
range.style.width = "80%";
|
|
@@ -82140,8 +82123,10 @@ ${key}` : key;
|
|
|
82140
82123
|
range.min = `${min}`;
|
|
82141
82124
|
range.step = `${step}`;
|
|
82142
82125
|
range.value = `${val}`;
|
|
82126
|
+
labelText.innerText = `${id} (${range.value})`;
|
|
82143
82127
|
const onChange = () => {
|
|
82144
82128
|
change(parseFloat(range.value));
|
|
82129
|
+
this.renderer.scene.dirty = true;
|
|
82145
82130
|
labelText.innerText = `${id} (${range.value})`;
|
|
82146
82131
|
};
|
|
82147
82132
|
range.addEventListener("input", onChange);
|
|
@@ -82358,6 +82343,95 @@ ${key}` : key;
|
|
|
82358
82343
|
init_buffer2();
|
|
82359
82344
|
init_process2();
|
|
82360
82345
|
|
|
82346
|
+
// src/model/block/BlockStateResolver.ts
|
|
82347
|
+
init_dirname();
|
|
82348
|
+
init_buffer2();
|
|
82349
|
+
init_process2();
|
|
82350
|
+
function matchesCondition(condition, state) {
|
|
82351
|
+
return Object.entries(condition).every(([key, value]) => {
|
|
82352
|
+
if (Array.isArray(value)) {
|
|
82353
|
+
if (key === "OR") return value.some((child) => matchesCondition(child, state));
|
|
82354
|
+
if (key === "AND") return value.every((child) => matchesCondition(child, state));
|
|
82355
|
+
return false;
|
|
82356
|
+
}
|
|
82357
|
+
return typeof value === "string" && state[key] !== void 0 && value.split("|").includes(`${state[key]}`);
|
|
82358
|
+
});
|
|
82359
|
+
}
|
|
82360
|
+
var BlockStateResolver = class {
|
|
82361
|
+
static async defaults(blockState) {
|
|
82362
|
+
const defaults = blockState.key ? await BlockStates.getDefaultState(blockState.key) : void 0;
|
|
82363
|
+
const state = {};
|
|
82364
|
+
if (defaults && Object.keys(defaults).length > 0) {
|
|
82365
|
+
for (const key in defaults) state[key] = defaults[key].default;
|
|
82366
|
+
} else if (blockState.variants) {
|
|
82367
|
+
const variant = Object.keys(blockState.variants)[0];
|
|
82368
|
+
if (variant) {
|
|
82369
|
+
for (const property of variant.split(",")) {
|
|
82370
|
+
const [key, value] = property.split("=");
|
|
82371
|
+
state[key] = value;
|
|
82372
|
+
}
|
|
82373
|
+
}
|
|
82374
|
+
} else if (blockState.multipart) {
|
|
82375
|
+
const condition = blockState.multipart.map((part) => part.when).find((when) => when !== void 0 && Object.values(when).every((value) => typeof value === "string"));
|
|
82376
|
+
for (const [key, value] of Object.entries(condition ?? {})) state[key] = value.split("|")[0];
|
|
82377
|
+
}
|
|
82378
|
+
return state;
|
|
82379
|
+
}
|
|
82380
|
+
static select(blockState, state, choose = this.choose) {
|
|
82381
|
+
return this.matching(blockState, state).map(choose);
|
|
82382
|
+
}
|
|
82383
|
+
static matching(blockState, state) {
|
|
82384
|
+
const out = [];
|
|
82385
|
+
if (blockState.variants) {
|
|
82386
|
+
if (Object.keys(blockState.variants).length === 1 && "" in blockState.variants) {
|
|
82387
|
+
out.push(blockState.variants[""]);
|
|
82388
|
+
} else {
|
|
82389
|
+
for (const variantKey in blockState.variants) {
|
|
82390
|
+
const matches = variantKey.split(",").every((property) => {
|
|
82391
|
+
const [key, value] = property.split("=");
|
|
82392
|
+
return `${state[key]}` === `${value}`;
|
|
82393
|
+
});
|
|
82394
|
+
if (matches) out.push(blockState.variants[variantKey]);
|
|
82395
|
+
}
|
|
82396
|
+
}
|
|
82397
|
+
} else if (blockState.multipart) {
|
|
82398
|
+
for (const part of blockState.multipart) {
|
|
82399
|
+
if (part.apply && (!part.when || matchesCondition(part.when, state))) {
|
|
82400
|
+
out.push(part.apply);
|
|
82401
|
+
}
|
|
82402
|
+
}
|
|
82403
|
+
}
|
|
82404
|
+
return out;
|
|
82405
|
+
}
|
|
82406
|
+
static choose(variants) {
|
|
82407
|
+
if (!Array.isArray(variants)) return variants;
|
|
82408
|
+
if (!variants.length) throw new MineRenderError("Blockstate variant arrays must not be empty");
|
|
82409
|
+
const total = variants.reduce((sum, variant) => {
|
|
82410
|
+
const weight = variant.weight ?? 1;
|
|
82411
|
+
if (!Number.isInteger(weight) || weight < 1) {
|
|
82412
|
+
throw new MineRenderError(`Invalid blockstate variant weight: ${weight}`);
|
|
82413
|
+
}
|
|
82414
|
+
return sum + weight;
|
|
82415
|
+
}, 0);
|
|
82416
|
+
let choice = Math.random() * total;
|
|
82417
|
+
for (const variant of variants) {
|
|
82418
|
+
choice -= variant.weight ?? 1;
|
|
82419
|
+
if (choice < 0) return variant;
|
|
82420
|
+
}
|
|
82421
|
+
return variants[variants.length - 1];
|
|
82422
|
+
}
|
|
82423
|
+
static rotation(variant) {
|
|
82424
|
+
const rotation = new Euler();
|
|
82425
|
+
if (typeof variant.x !== "undefined") {
|
|
82426
|
+
rotation.x = toRadians(clampRotationDegrees(variant.x));
|
|
82427
|
+
}
|
|
82428
|
+
if (typeof variant.y !== "undefined") {
|
|
82429
|
+
rotation.y = toRadians(clampRotationDegrees(typeof variant.x !== "undefined" ? variant.y : 360 - variant.y));
|
|
82430
|
+
}
|
|
82431
|
+
return rotation;
|
|
82432
|
+
}
|
|
82433
|
+
};
|
|
82434
|
+
|
|
82361
82435
|
// src/model/block/BlockTints.ts
|
|
82362
82436
|
init_dirname();
|
|
82363
82437
|
init_buffer2();
|
|
@@ -83142,17 +83216,6 @@ ${key}` : key;
|
|
|
83142
83216
|
|
|
83143
83217
|
// src/model/block/scene/BlockObject.ts
|
|
83144
83218
|
var import_ts_deepmerge6 = __toESM(require_dist());
|
|
83145
|
-
var p13 = prefix("BlockObject");
|
|
83146
|
-
function matchesCondition(condition, state) {
|
|
83147
|
-
return Object.entries(condition).every(([key, value]) => {
|
|
83148
|
-
if (Array.isArray(value)) {
|
|
83149
|
-
if (key === "OR") return value.some((child) => matchesCondition(child, state));
|
|
83150
|
-
if (key === "AND") return value.every((child) => matchesCondition(child, state));
|
|
83151
|
-
return false;
|
|
83152
|
-
}
|
|
83153
|
-
return typeof value === "string" && state[key] !== void 0 && value.split("|").includes(`${state[key]}`);
|
|
83154
|
-
});
|
|
83155
|
-
}
|
|
83156
83219
|
var _BlockObject = class _BlockObject extends SceneObject {
|
|
83157
83220
|
constructor(blockState, options) {
|
|
83158
83221
|
super(options);
|
|
@@ -83171,22 +83234,7 @@ ${key}` : key;
|
|
|
83171
83234
|
}
|
|
83172
83235
|
async init() {
|
|
83173
83236
|
if (this.options.applyDefaultState) {
|
|
83174
|
-
|
|
83175
|
-
if (defaultState && Object.keys(defaultState).length > 0) {
|
|
83176
|
-
const state = {};
|
|
83177
|
-
for (let k4 in defaultState) {
|
|
83178
|
-
state[k4] = defaultState[k4].default;
|
|
83179
|
-
}
|
|
83180
|
-
this._setState(state);
|
|
83181
|
-
} else {
|
|
83182
|
-
if (this.blockState.variants) {
|
|
83183
|
-
this._setState(Object.keys(this.blockState.variants)[0]);
|
|
83184
|
-
} else if (this.blockState.multipart) {
|
|
83185
|
-
const condition = this.blockState.multipart.map((part) => part.when).find((when) => when !== void 0 && Object.values(when).every((value) => typeof value === "string"));
|
|
83186
|
-
const state = Object.fromEntries(Object.entries(condition ?? {}).map(([key, value]) => [key, value.split("|")[0]]));
|
|
83187
|
-
this._setState(state);
|
|
83188
|
-
}
|
|
83189
|
-
}
|
|
83237
|
+
this._setState(await BlockStateResolver.defaults(this.blockState));
|
|
83190
83238
|
}
|
|
83191
83239
|
if (this.options.initialState !== void 0) this._setState(this.options.initialState);
|
|
83192
83240
|
await this.recreateModels();
|
|
@@ -83277,39 +83325,7 @@ ${key}` : key;
|
|
|
83277
83325
|
return ref;
|
|
83278
83326
|
}
|
|
83279
83327
|
async mapStateToVariant(state) {
|
|
83280
|
-
|
|
83281
|
-
if (this.blockState.variants) {
|
|
83282
|
-
if (Object.keys(this.blockState.variants).length === 1 && "" in this.blockState.variants) {
|
|
83283
|
-
out.push(this.getSingleVariant(this.blockState.variants[""]));
|
|
83284
|
-
} else {
|
|
83285
|
-
for (let variantKey in this.blockState.variants) {
|
|
83286
|
-
const split = variantKey.split(",");
|
|
83287
|
-
let matches = true;
|
|
83288
|
-
for (let s4 of split) {
|
|
83289
|
-
const [k4, v5] = s4.split("=");
|
|
83290
|
-
if (`${state[k4]}` !== `${v5}`) {
|
|
83291
|
-
matches = false;
|
|
83292
|
-
break;
|
|
83293
|
-
}
|
|
83294
|
-
}
|
|
83295
|
-
if (matches) {
|
|
83296
|
-
const variants = this.blockState.variants[variantKey];
|
|
83297
|
-
out.push(this.getSingleVariant(variants));
|
|
83298
|
-
}
|
|
83299
|
-
}
|
|
83300
|
-
}
|
|
83301
|
-
} else if (this.blockState.multipart) {
|
|
83302
|
-
for (let part of this.blockState.multipart) {
|
|
83303
|
-
if (!part.apply) {
|
|
83304
|
-
console.debug(p13, "Missing apply for blockState part", part);
|
|
83305
|
-
continue;
|
|
83306
|
-
}
|
|
83307
|
-
if (!part.when || matchesCondition(part.when, state)) {
|
|
83308
|
-
out.push(this.getSingleVariant(part.apply));
|
|
83309
|
-
}
|
|
83310
|
-
}
|
|
83311
|
-
}
|
|
83312
|
-
return out;
|
|
83328
|
+
return BlockStateResolver.select(this.blockState, state, (variants) => this.getSingleVariant(variants));
|
|
83313
83329
|
}
|
|
83314
83330
|
async recreateModels() {
|
|
83315
83331
|
this.clearModels();
|
|
@@ -83320,21 +83336,7 @@ ${key}` : key;
|
|
|
83320
83336
|
}
|
|
83321
83337
|
}
|
|
83322
83338
|
getSingleVariant(variants) {
|
|
83323
|
-
|
|
83324
|
-
if (!variants.length) throw new MineRenderError("Blockstate variant arrays must not be empty");
|
|
83325
|
-
const total = variants.reduce((sum, variant) => {
|
|
83326
|
-
const weight = variant.weight ?? 1;
|
|
83327
|
-
if (!Number.isInteger(weight) || weight < 1) {
|
|
83328
|
-
throw new MineRenderError(`Invalid blockstate variant weight: ${weight}`);
|
|
83329
|
-
}
|
|
83330
|
-
return sum + weight;
|
|
83331
|
-
}, 0);
|
|
83332
|
-
let choice = Math.random() * total;
|
|
83333
|
-
for (const variant of variants) {
|
|
83334
|
-
choice -= variant.weight ?? 1;
|
|
83335
|
-
if (choice < 0) return variant;
|
|
83336
|
-
}
|
|
83337
|
-
return variants[variants.length - 1];
|
|
83339
|
+
return BlockStateResolver.choose(variants);
|
|
83338
83340
|
}
|
|
83339
83341
|
// @deprecated
|
|
83340
83342
|
async createAVariant(variants, instanceInfo) {
|
|
@@ -83342,13 +83344,7 @@ ${key}` : key;
|
|
|
83342
83344
|
await this.createVariant(variant);
|
|
83343
83345
|
}
|
|
83344
83346
|
async createVariant(variant) {
|
|
83345
|
-
const rotation =
|
|
83346
|
-
if (typeof variant.x !== "undefined") {
|
|
83347
|
-
rotation.x = toRadians(clampRotationDegrees(variant.x));
|
|
83348
|
-
}
|
|
83349
|
-
if (typeof variant.y !== "undefined") {
|
|
83350
|
-
rotation.y = toRadians(clampRotationDegrees(typeof variant.x !== "undefined" ? variant.y : 360 - variant.y));
|
|
83351
|
-
}
|
|
83347
|
+
const rotation = BlockStateResolver.rotation(variant);
|
|
83352
83348
|
const modelKey = AssetKey.parse("models", variant.model);
|
|
83353
83349
|
modelKey.root = this.blockState.key?.root;
|
|
83354
83350
|
const model = await Models.getMerged(modelKey);
|
|
@@ -88258,8 +88254,8 @@ uniform float opacity;varying vec2 vUv;void main(){vec4 texel=texture2D(inputBuf
|
|
|
88258
88254
|
[bilinear(1, 1, 1, 0), new Float32Array([1, 1, 1, 0])],
|
|
88259
88255
|
[bilinear(1, 1, 1, 1), new Float32Array([1, 1, 1, 1])]
|
|
88260
88256
|
]);
|
|
88261
|
-
function lerp2(a4, b4,
|
|
88262
|
-
return a4 + (b4 - a4) *
|
|
88257
|
+
function lerp2(a4, b4, p13) {
|
|
88258
|
+
return a4 + (b4 - a4) * p13;
|
|
88263
88259
|
}
|
|
88264
88260
|
function bilinear(e0, e1, e22, e32) {
|
|
88265
88261
|
const a4 = lerp2(e0, e1, 1 - 0.25);
|
|
@@ -89717,11 +89713,102 @@ uniform float opacity;varying vec2 vUv;void main(){vec4 texel=texture2D(inputBuf
|
|
|
89717
89713
|
init_dirname();
|
|
89718
89714
|
init_buffer2();
|
|
89719
89715
|
init_process2();
|
|
89716
|
+
|
|
89717
|
+
// src/world/SectionModels.ts
|
|
89718
|
+
init_dirname();
|
|
89719
|
+
init_buffer2();
|
|
89720
|
+
init_process2();
|
|
89721
|
+
var SectionModel = class extends ModelObject {
|
|
89722
|
+
applyTextures() {
|
|
89723
|
+
}
|
|
89724
|
+
};
|
|
89725
|
+
function cached(map, key, load) {
|
|
89726
|
+
let value = map.get(key);
|
|
89727
|
+
if (!value) {
|
|
89728
|
+
value = load().catch((error) => {
|
|
89729
|
+
map.delete(key);
|
|
89730
|
+
throw error;
|
|
89731
|
+
});
|
|
89732
|
+
map.set(key, value);
|
|
89733
|
+
}
|
|
89734
|
+
return value;
|
|
89735
|
+
}
|
|
89736
|
+
var SectionModels = class {
|
|
89737
|
+
constructor(maxAtlasSize = 2048) {
|
|
89738
|
+
this.maxAtlasSize = maxAtlasSize;
|
|
89739
|
+
this.states = /* @__PURE__ */ new WeakMap();
|
|
89740
|
+
this.models = /* @__PURE__ */ new WeakMap();
|
|
89741
|
+
this.templates = /* @__PURE__ */ new Set();
|
|
89742
|
+
if (!Number.isInteger(maxAtlasSize) || maxAtlasSize < 1) throw new RangeError("maxAtlasSize must be a positive integer");
|
|
89743
|
+
}
|
|
89744
|
+
async get(blockState, properties = {}) {
|
|
89745
|
+
if (!blockState.variants || blockState.multipart) return void 0;
|
|
89746
|
+
let states = this.states.get(blockState);
|
|
89747
|
+
if (!states) this.states.set(blockState, states = /* @__PURE__ */ new Map());
|
|
89748
|
+
const key = JSON.stringify(Object.entries(properties).sort(([a4], [b4]) => a4.localeCompare(b4)));
|
|
89749
|
+
const prepared = await cached(states, key, () => this.prepare(blockState, properties));
|
|
89750
|
+
if (!prepared) return void 0;
|
|
89751
|
+
return prepared.templates.get(BlockStateResolver.choose(prepared.variants));
|
|
89752
|
+
}
|
|
89753
|
+
async prepare(blockState, properties) {
|
|
89754
|
+
const state = { ...await BlockStateResolver.defaults(blockState), ...properties };
|
|
89755
|
+
const groups = BlockStateResolver.matching(blockState, state);
|
|
89756
|
+
if (groups.length !== 1) return void 0;
|
|
89757
|
+
const variants = groups[0];
|
|
89758
|
+
const choices = Array.isArray(variants) ? variants : [variants];
|
|
89759
|
+
if (!choices.length) return void 0;
|
|
89760
|
+
const templates = /* @__PURE__ */ new Map();
|
|
89761
|
+
for (const variant of choices) {
|
|
89762
|
+
const model = await Models.getMerged(AssetKey.parse("models", variant.model));
|
|
89763
|
+
if (!model) return void 0;
|
|
89764
|
+
const atlas = await UVMapper.getAtlas(model);
|
|
89765
|
+
const rotation = BlockStateResolver.rotation(variant);
|
|
89766
|
+
if (!atlas || atlas.hasAnimation || !ModelCulling.isOpaqueFullCube(atlas) || atlas.image.width > this.maxAtlasSize || atlas.image.height > this.maxAtlasSize || ModelCulling.toLocalMask(63, rotation) !== 63) return void 0;
|
|
89767
|
+
const tints = await BlockTints.get(blockState.key, state, model);
|
|
89768
|
+
let models = this.models.get(model);
|
|
89769
|
+
if (!models) this.models.set(model, models = /* @__PURE__ */ new Map());
|
|
89770
|
+
const key = JSON.stringify([rotation.x, rotation.y, rotation.z, variant.uvlock, tints]);
|
|
89771
|
+
const template = await cached(models, key, async () => {
|
|
89772
|
+
const object = new SectionModel(model, {
|
|
89773
|
+
instanceMeshes: false,
|
|
89774
|
+
mergeMeshes: false,
|
|
89775
|
+
tints,
|
|
89776
|
+
uvLockRotation: variant.uvlock && (rotation.x !== 0 || rotation.y !== 0) ? [rotation.x, rotation.y, rotation.z] : void 0
|
|
89777
|
+
});
|
|
89778
|
+
await object.init();
|
|
89779
|
+
const geometry = object.children[0].geometry;
|
|
89780
|
+
geometry.applyMatrix4(new Matrix4().makeRotationFromEuler(rotation));
|
|
89781
|
+
object.clear();
|
|
89782
|
+
const cullFaces = CUBE_FACES.map((face) => {
|
|
89783
|
+
const local = CUBE_FACES.findIndex((name2) => name2 === atlas.model.elements[0].faces[face]?.cullface);
|
|
89784
|
+
if (local < 0) return 0;
|
|
89785
|
+
const normal = new Vector3(...CUBE_FACE_OFFSETS[local]).applyEuler(rotation);
|
|
89786
|
+
const world = CUBE_FACE_OFFSETS.findIndex(([x4, y5, z4]) => Math.abs(normal.x - x4) < 1e-6 && Math.abs(normal.y - y5) < 1e-6 && Math.abs(normal.z - z4) < 1e-6);
|
|
89787
|
+
return 1 << world;
|
|
89788
|
+
});
|
|
89789
|
+
const template2 = { geometry, atlas, cullFaces };
|
|
89790
|
+
this.templates.add(template2);
|
|
89791
|
+
return template2;
|
|
89792
|
+
});
|
|
89793
|
+
templates.set(variant, template);
|
|
89794
|
+
}
|
|
89795
|
+
return { variants, templates };
|
|
89796
|
+
}
|
|
89797
|
+
clear() {
|
|
89798
|
+
for (const template of this.templates) template.geometry.dispose();
|
|
89799
|
+
this.templates.clear();
|
|
89800
|
+
this.states = /* @__PURE__ */ new WeakMap();
|
|
89801
|
+
this.models = /* @__PURE__ */ new WeakMap();
|
|
89802
|
+
}
|
|
89803
|
+
};
|
|
89804
|
+
|
|
89805
|
+
// src/world/MineRenderWorld.ts
|
|
89720
89806
|
var MineRenderWorld = class {
|
|
89721
|
-
constructor(scene) {
|
|
89807
|
+
constructor(scene, options = {}) {
|
|
89722
89808
|
this._chunks = /* @__PURE__ */ new Map();
|
|
89723
89809
|
this.pendingCulling = /* @__PURE__ */ new Map();
|
|
89724
89810
|
this.scene = scene;
|
|
89811
|
+
if (options.sectionMeshing) this.sectionModels = new SectionModels(options.maxAtlasSize);
|
|
89725
89812
|
}
|
|
89726
89813
|
getBlockAt(posOrX, y5, z4) {
|
|
89727
89814
|
if (typeof posOrX == "number") {
|
|
@@ -89831,6 +89918,7 @@ uniform float opacity;varying vec2 vUv;void main(){vec4 texel=texture2D(inputBuf
|
|
|
89831
89918
|
for (const chunk of chunks) {
|
|
89832
89919
|
await chunk.dispose();
|
|
89833
89920
|
}
|
|
89921
|
+
this.sectionModels?.clear();
|
|
89834
89922
|
}
|
|
89835
89923
|
updateCulling(positions) {
|
|
89836
89924
|
for (const pos of positions) {
|
|
@@ -89845,17 +89933,22 @@ uniform float opacity;varying vec2 vUv;void main(){vec4 texel=texture2D(inputBuf
|
|
|
89845
89933
|
while (this.pendingCulling.size) {
|
|
89846
89934
|
const batch = [...this.pendingCulling.values()];
|
|
89847
89935
|
this.pendingCulling.clear();
|
|
89936
|
+
const changed = /* @__PURE__ */ new Set();
|
|
89848
89937
|
for (const pos of batch) {
|
|
89849
|
-
const
|
|
89850
|
-
if (!
|
|
89938
|
+
const chunk = this.getChunkAt(pos);
|
|
89939
|
+
if (!chunk) continue;
|
|
89940
|
+
changed.add(chunk);
|
|
89941
|
+
if (!chunk.getBlockAt(pos)) continue;
|
|
89851
89942
|
let mask = 0;
|
|
89852
89943
|
for (const [face, offset] of CUBE_FACE_OFFSETS.entries()) {
|
|
89853
|
-
|
|
89944
|
+
const neighbor = pos.clone().add(new Vector3(...offset));
|
|
89945
|
+
if (this.getChunkAt(neighbor)?.isOccludingAt(neighbor)) {
|
|
89854
89946
|
mask |= 1 << face;
|
|
89855
89947
|
}
|
|
89856
89948
|
}
|
|
89857
|
-
await
|
|
89949
|
+
await chunk.setCullMaskAt(pos, mask);
|
|
89858
89950
|
}
|
|
89951
|
+
for (const chunk of changed) chunk.rebuildSectionMesh();
|
|
89859
89952
|
}
|
|
89860
89953
|
} finally {
|
|
89861
89954
|
this.culling = void 0;
|
|
@@ -89871,7 +89964,8 @@ uniform float opacity;varying vec2 vUv;void main(){vec4 texel=texture2D(inputBuf
|
|
|
89871
89964
|
Math.floor(pos.x / 16),
|
|
89872
89965
|
Math.floor(pos.y / 16),
|
|
89873
89966
|
Math.floor(pos.z / 16),
|
|
89874
|
-
(positions) => this.updateCulling(positions)
|
|
89967
|
+
(positions) => this.updateCulling(positions),
|
|
89968
|
+
this.sectionModels
|
|
89875
89969
|
);
|
|
89876
89970
|
this._chunks.set(key, chunk);
|
|
89877
89971
|
}
|
|
@@ -89907,12 +90001,120 @@ uniform float opacity;varying vec2 vUv;void main(){vec4 texel=texture2D(inputBuf
|
|
|
89907
90001
|
}
|
|
89908
90002
|
};
|
|
89909
90003
|
|
|
90004
|
+
// src/world/SectionMesh.ts
|
|
90005
|
+
init_dirname();
|
|
90006
|
+
init_buffer2();
|
|
90007
|
+
init_process2();
|
|
90008
|
+
var SectionMesh = class _SectionMesh extends Group {
|
|
90009
|
+
constructor() {
|
|
90010
|
+
super(...arguments);
|
|
90011
|
+
this.ownedMeshes = [];
|
|
90012
|
+
}
|
|
90013
|
+
static build(entries, maxAtlasSize = 2048) {
|
|
90014
|
+
if (!Number.isInteger(maxAtlasSize) || maxAtlasSize < 1) throw new RangeError("Section atlas size must be a positive integer");
|
|
90015
|
+
const visible = entries.filter((entry) => entry.template.cullFaces.some((direction) => !(entry.cullMask & direction)));
|
|
90016
|
+
const atlases = [...new Set(visible.map((entry) => entry.template.atlas))].sort((a4, b4) => b4.image.height - a4.image.height);
|
|
90017
|
+
const pages = [];
|
|
90018
|
+
const locations = /* @__PURE__ */ new Map();
|
|
90019
|
+
for (const atlas of atlases) {
|
|
90020
|
+
const { width, height } = atlas.image;
|
|
90021
|
+
if (width > maxAtlasSize || height > maxAtlasSize) throw new RangeError("Model atlas exceeds the section atlas size limit");
|
|
90022
|
+
let selected;
|
|
90023
|
+
for (const page of pages) {
|
|
90024
|
+
const nextRow = page.x + width > maxAtlasSize;
|
|
90025
|
+
if ((nextRow ? page.y + page.rowHeight : page.y) + height > maxAtlasSize) continue;
|
|
90026
|
+
if (nextRow) {
|
|
90027
|
+
page.y += page.rowHeight;
|
|
90028
|
+
page.x = 0;
|
|
90029
|
+
page.rowHeight = 0;
|
|
90030
|
+
}
|
|
90031
|
+
selected = page;
|
|
90032
|
+
break;
|
|
90033
|
+
}
|
|
90034
|
+
if (!selected) {
|
|
90035
|
+
selected = { placements: [], entries: [], x: 0, y: 0, rowHeight: 0, width: 0, height: 0 };
|
|
90036
|
+
pages.push(selected);
|
|
90037
|
+
}
|
|
90038
|
+
const placement = { atlas, x: selected.x, y: selected.y };
|
|
90039
|
+
selected.placements.push(placement);
|
|
90040
|
+
selected.x += width;
|
|
90041
|
+
selected.rowHeight = Math.max(selected.rowHeight, height);
|
|
90042
|
+
selected.width = Math.max(selected.width, selected.x);
|
|
90043
|
+
selected.height = Math.max(selected.height, selected.y + height);
|
|
90044
|
+
locations.set(atlas, { page: selected, placement });
|
|
90045
|
+
}
|
|
90046
|
+
for (const entry of visible) locations.get(entry.template.atlas).page.entries.push(entry);
|
|
90047
|
+
const section = new _SectionMesh();
|
|
90048
|
+
for (const page of pages) {
|
|
90049
|
+
const canvas = createCanvas(page.width, page.height);
|
|
90050
|
+
const context = canvas.getContext("2d");
|
|
90051
|
+
for (const { atlas, x: x4, y: y5 } of page.placements) {
|
|
90052
|
+
context.drawImage(atlas.image.canvas, x4, y5);
|
|
90053
|
+
}
|
|
90054
|
+
const positions = [], normals = [], uvs = [], colors = [], indices = [];
|
|
90055
|
+
for (const { index, template, cullMask } of page.entries) {
|
|
90056
|
+
const position = template.geometry.getAttribute("position");
|
|
90057
|
+
const normal = template.geometry.getAttribute("normal");
|
|
90058
|
+
const uv = template.geometry.getAttribute("uv");
|
|
90059
|
+
const color2 = template.geometry.getAttribute("color");
|
|
90060
|
+
const sourceIndices = template.geometry.getIndex();
|
|
90061
|
+
const placement = locations.get(template.atlas).placement;
|
|
90062
|
+
const offsetX = index % 16 * 16;
|
|
90063
|
+
const offsetY = Math.floor(index / 256) * 16;
|
|
90064
|
+
const offsetZ = Math.floor(index / 16) % 16 * 16;
|
|
90065
|
+
for (let face = 0; face < 6; face++) {
|
|
90066
|
+
if (cullMask & template.cullFaces[face]) continue;
|
|
90067
|
+
const start = positions.length / 3;
|
|
90068
|
+
for (let corner = 0; corner < 4; corner++) {
|
|
90069
|
+
const vertex2 = face * 4 + corner;
|
|
90070
|
+
positions.push(position.getX(vertex2) + offsetX, position.getY(vertex2) + offsetY, position.getZ(vertex2) + offsetZ);
|
|
90071
|
+
normals.push(normal.getX(vertex2), normal.getY(vertex2), normal.getZ(vertex2));
|
|
90072
|
+
uvs.push(
|
|
90073
|
+
(placement.x + uv.getX(vertex2) * template.atlas.image.width) / page.width,
|
|
90074
|
+
1 - (placement.y + (1 - uv.getY(vertex2)) * template.atlas.image.height) / page.height
|
|
90075
|
+
);
|
|
90076
|
+
colors.push(color2?.getX(vertex2) ?? 1, color2?.getY(vertex2) ?? 1, color2?.getZ(vertex2) ?? 1);
|
|
90077
|
+
}
|
|
90078
|
+
for (let corner = 0; corner < 6; corner++) indices.push(start + sourceIndices.getX(face * 6 + corner) - face * 4);
|
|
90079
|
+
}
|
|
90080
|
+
}
|
|
90081
|
+
const geometry = new BufferGeometry();
|
|
90082
|
+
geometry.setAttribute("position", new Float32BufferAttribute(positions, 3));
|
|
90083
|
+
geometry.setAttribute("normal", new Float32BufferAttribute(normals, 3));
|
|
90084
|
+
geometry.setAttribute("uv", new Float32BufferAttribute(uvs, 2));
|
|
90085
|
+
geometry.setAttribute("color", new Float32BufferAttribute(colors, 3));
|
|
90086
|
+
geometry.setIndex(indices);
|
|
90087
|
+
geometry.computeBoundingBox();
|
|
90088
|
+
geometry.computeBoundingSphere();
|
|
90089
|
+
const material = Materials.createShadedCanvasMaterial(canvas, false);
|
|
90090
|
+
material.vertexColors = true;
|
|
90091
|
+
const texture = material.uniforms?.map?.value ?? material.map;
|
|
90092
|
+
const mesh = new Mesh(geometry, material);
|
|
90093
|
+
section.add(mesh);
|
|
90094
|
+
section.ownedMeshes.push({ mesh, texture });
|
|
90095
|
+
}
|
|
90096
|
+
return section;
|
|
90097
|
+
}
|
|
90098
|
+
dispose() {
|
|
90099
|
+
for (const { mesh, texture } of this.ownedMeshes.splice(0)) {
|
|
90100
|
+
mesh.removeFromParent();
|
|
90101
|
+
mesh.geometry.dispose();
|
|
90102
|
+
mesh.material.dispose();
|
|
90103
|
+
texture?.dispose();
|
|
90104
|
+
}
|
|
90105
|
+
this.removeFromParent();
|
|
90106
|
+
}
|
|
90107
|
+
};
|
|
90108
|
+
|
|
89910
90109
|
// src/world/Chunk.ts
|
|
89911
90110
|
var Chunk = class _Chunk {
|
|
89912
|
-
constructor(scene, x4, y5, z4, onBlocksChanged) {
|
|
90111
|
+
constructor(scene, x4, y5, z4, onBlocksChanged, sectionModels) {
|
|
89913
90112
|
this.onBlocksChanged = onBlocksChanged;
|
|
90113
|
+
this.sectionModels = sectionModels;
|
|
89914
90114
|
this.data = new ChunkData();
|
|
89915
90115
|
this.renderedBlocks = /* @__PURE__ */ new Map();
|
|
90116
|
+
this.sectionBlocks = /* @__PURE__ */ new Map();
|
|
90117
|
+
this.meshDirty = false;
|
|
89916
90118
|
this.scene = scene;
|
|
89917
90119
|
this.x = x4;
|
|
89918
90120
|
this.y = y5;
|
|
@@ -89951,7 +90153,8 @@ uniform float opacity;varying vec2 vUv;void main(){vec4 texel=texture2D(inputBuf
|
|
|
89951
90153
|
const index = _Chunk.chunkPosToBlockIndex(pos);
|
|
89952
90154
|
this.data.set(index, block);
|
|
89953
90155
|
const readBlock = this.data.snapshot(index);
|
|
89954
|
-
this.renderedBlocks.get(index)?.object
|
|
90156
|
+
this.renderedBlocks.get(index)?.object?.removeFromScene();
|
|
90157
|
+
if (this.sectionBlocks.delete(index)) this.meshDirty = true;
|
|
89955
90158
|
this.renderedBlocks.delete(index);
|
|
89956
90159
|
let object;
|
|
89957
90160
|
try {
|
|
@@ -89962,13 +90165,19 @@ uniform float opacity;varying vec2 vUv;void main(){vec4 texel=texture2D(inputBuf
|
|
|
89962
90165
|
this.data.set(index, void 0);
|
|
89963
90166
|
return void 0;
|
|
89964
90167
|
}
|
|
89965
|
-
|
|
89966
|
-
|
|
89967
|
-
|
|
89968
|
-
|
|
89969
|
-
|
|
89970
|
-
|
|
89971
|
-
|
|
90168
|
+
const template = await this.sectionModels?.get(blockState, stored.properties);
|
|
90169
|
+
if (template) {
|
|
90170
|
+
this.sectionBlocks.set(index, { index, template, cullMask: 0 });
|
|
90171
|
+
this.meshDirty = true;
|
|
90172
|
+
} else {
|
|
90173
|
+
object = await this.scene.addBlock(blockState, {
|
|
90174
|
+
mergeMeshes: true,
|
|
90175
|
+
instanceMeshes: true,
|
|
90176
|
+
maxInstanceCount: 2e3,
|
|
90177
|
+
initialState: stored.properties
|
|
90178
|
+
});
|
|
90179
|
+
object.setPosition(MineRenderWorld.worldToScenePosition(worldPos));
|
|
90180
|
+
}
|
|
89972
90181
|
const info = { get block() {
|
|
89973
90182
|
return readBlock();
|
|
89974
90183
|
}, object };
|
|
@@ -89982,11 +90191,43 @@ uniform float opacity;varying vec2 vUv;void main(){vec4 texel=texture2D(inputBuf
|
|
|
89982
90191
|
await onBlocksChanged?.([worldPos]);
|
|
89983
90192
|
}
|
|
89984
90193
|
}
|
|
90194
|
+
isOccludingAt(pos) {
|
|
90195
|
+
const index = _Chunk.chunkPosToBlockIndex(this.worldPosToChunkPos(pos));
|
|
90196
|
+
return this.sectionBlocks.has(index) || (this.renderedBlocks.get(index)?.object?.isOccluding ?? false);
|
|
90197
|
+
}
|
|
90198
|
+
async setCullMaskAt(pos, mask) {
|
|
90199
|
+
const index = _Chunk.chunkPosToBlockIndex(this.worldPosToChunkPos(pos));
|
|
90200
|
+
const entry = this.sectionBlocks.get(index);
|
|
90201
|
+
if (entry) {
|
|
90202
|
+
if (entry.cullMask !== mask) {
|
|
90203
|
+
entry.cullMask = mask;
|
|
90204
|
+
this.meshDirty = true;
|
|
90205
|
+
}
|
|
90206
|
+
} else {
|
|
90207
|
+
await this.renderedBlocks.get(index)?.object?.setCullMask(mask);
|
|
90208
|
+
}
|
|
90209
|
+
}
|
|
90210
|
+
rebuildSectionMesh() {
|
|
90211
|
+
if (!this.meshDirty) return;
|
|
90212
|
+
const next = this.sectionBlocks.size ? SectionMesh.build([...this.sectionBlocks.values()], this.sectionModels.maxAtlasSize) : void 0;
|
|
90213
|
+
this.sectionMesh?.dispose();
|
|
90214
|
+
this.sectionMesh = next;
|
|
90215
|
+
if (next) {
|
|
90216
|
+
next.position.set(this.x * 256, this.y * 256, this.z * 256);
|
|
90217
|
+
this.scene.add(next);
|
|
90218
|
+
}
|
|
90219
|
+
this.scene.dirty = true;
|
|
90220
|
+
this.meshDirty = false;
|
|
90221
|
+
}
|
|
89985
90222
|
async clear(onBlocksChanged = this.onBlocksChanged) {
|
|
89986
90223
|
const positions = [...this.renderedBlocks.keys()].map((index) => this.chunkPosToWorldPos(
|
|
89987
90224
|
new Vector3(index % 16, Math.floor(index / 256), Math.floor(index / 16) % 16)
|
|
89988
90225
|
));
|
|
89989
|
-
for (const info of this.renderedBlocks.values()) info.object
|
|
90226
|
+
for (const info of this.renderedBlocks.values()) info.object?.removeFromScene();
|
|
90227
|
+
this.sectionBlocks.clear();
|
|
90228
|
+
this.sectionMesh?.dispose();
|
|
90229
|
+
this.sectionMesh = void 0;
|
|
90230
|
+
this.meshDirty = false;
|
|
89990
90231
|
this.renderedBlocks.clear();
|
|
89991
90232
|
this.data.clear();
|
|
89992
90233
|
await onBlocksChanged?.(positions);
|